diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000..d7f079a62 --- /dev/null +++ b/.gitignore @@ -0,0 +1,68 @@ +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +env/ +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +*.egg-info/ +.installed.cfg +*.egg + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*,cover +.hypothesis/ +venv/ +.venv/ +.python-version +.pytest_cache + +# Translations +*.mo +*.pot + +# Django stuff: +*.log + +# Sphinx documentation +docs/_build/ + +# PyBuilder +target/ + +#Ipython Notebook +.ipynb_checkpoints + +diff.test diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES new file mode 100644 index 000000000..c5f81e2e9 --- /dev/null +++ b/.openapi-generator/FILES @@ -0,0 +1,1838 @@ +.github/workflows/python.yml +.gitignore +.gitlab-ci.yml +.travis.yml +README.md +authentik_client/__init__.py +authentik_client/api/__init__.py +authentik_client/api/admin_api.py +authentik_client/api/authenticators_api.py +authentik_client/api/core_api.py +authentik_client/api/crypto_api.py +authentik_client/api/endpoints_api.py +authentik_client/api/enterprise_api.py +authentik_client/api/events_api.py +authentik_client/api/flows_api.py +authentik_client/api/lifecycle_api.py +authentik_client/api/managed_api.py +authentik_client/api/oauth2_api.py +authentik_client/api/outposts_api.py +authentik_client/api/policies_api.py +authentik_client/api/propertymappings_api.py +authentik_client/api/providers_api.py +authentik_client/api/rac_api.py +authentik_client/api/rbac_api.py +authentik_client/api/reports_api.py +authentik_client/api/root_api.py +authentik_client/api/schema_api.py +authentik_client/api/sources_api.py +authentik_client/api/ssf_api.py +authentik_client/api/stages_api.py +authentik_client/api/tasks_api.py +authentik_client/api/tenants_api.py +authentik_client/api_client.py +authentik_client/api_response.py +authentik_client/configuration.py +authentik_client/exceptions.py +authentik_client/models/__init__.py +authentik_client/models/access_denied_challenge.py +authentik_client/models/account_lockdown_stage.py +authentik_client/models/account_lockdown_stage_request.py +authentik_client/models/agent_authentication_response.py +authentik_client/models/agent_config.py +authentik_client/models/agent_connector.py +authentik_client/models/agent_connector_request.py +authentik_client/models/agent_psso_device_registration_request.py +authentik_client/models/agent_psso_device_registration_response.py +authentik_client/models/agent_psso_user_registration_request.py +authentik_client/models/agent_token_response.py +authentik_client/models/alg_enum.py +authentik_client/models/app.py +authentik_client/models/app_enum.py +authentik_client/models/apple_challenge_response_request.py +authentik_client/models/apple_independent_secure_enclave.py +authentik_client/models/apple_independent_secure_enclave_request.py +authentik_client/models/apple_login_challenge.py +authentik_client/models/application.py +authentik_client/models/application_entitlement.py +authentik_client/models/application_entitlement_request.py +authentik_client/models/application_request.py +authentik_client/models/auth_type_enum.py +authentik_client/models/authenticated_session.py +authentik_client/models/authenticated_session_asn.py +authentik_client/models/authenticated_session_geo_ip.py +authentik_client/models/authenticated_session_user_agent.py +authentik_client/models/authenticated_session_user_agent_device.py +authentik_client/models/authenticated_session_user_agent_os.py +authentik_client/models/authenticated_session_user_agent_user_agent.py +authentik_client/models/authentication_enum.py +authentik_client/models/authenticator_attachment_enum.py +authentik_client/models/authenticator_duo_challenge.py +authentik_client/models/authenticator_duo_challenge_response_request.py +authentik_client/models/authenticator_duo_stage.py +authentik_client/models/authenticator_duo_stage_device_import_response.py +authentik_client/models/authenticator_duo_stage_manual_device_import_request.py +authentik_client/models/authenticator_duo_stage_request.py +authentik_client/models/authenticator_email_challenge.py +authentik_client/models/authenticator_email_challenge_response_request.py +authentik_client/models/authenticator_email_stage.py +authentik_client/models/authenticator_email_stage_request.py +authentik_client/models/authenticator_endpoint_gdtc_stage.py +authentik_client/models/authenticator_endpoint_gdtc_stage_request.py +authentik_client/models/authenticator_sms_challenge.py +authentik_client/models/authenticator_sms_challenge_response_request.py +authentik_client/models/authenticator_sms_stage.py +authentik_client/models/authenticator_sms_stage_request.py +authentik_client/models/authenticator_static_challenge.py +authentik_client/models/authenticator_static_challenge_response_request.py +authentik_client/models/authenticator_static_stage.py +authentik_client/models/authenticator_static_stage_request.py +authentik_client/models/authenticator_totp_challenge.py +authentik_client/models/authenticator_totp_challenge_response_request.py +authentik_client/models/authenticator_totp_stage.py +authentik_client/models/authenticator_totp_stage_request.py +authentik_client/models/authenticator_validate_stage.py +authentik_client/models/authenticator_validate_stage_request.py +authentik_client/models/authenticator_validation_challenge.py +authentik_client/models/authenticator_validation_challenge_response_request.py +authentik_client/models/authenticator_web_authn_challenge.py +authentik_client/models/authenticator_web_authn_challenge_response_request.py +authentik_client/models/authenticator_web_authn_stage.py +authentik_client/models/authenticator_web_authn_stage_request.py +authentik_client/models/authorization_code_auth_method_enum.py +authentik_client/models/auto_submit_challenge_response_request.py +authentik_client/models/autosubmit_challenge.py +authentik_client/models/backends_enum.py +authentik_client/models/binding_type_enum.py +authentik_client/models/blueprint_file.py +authentik_client/models/blueprint_import_result.py +authentik_client/models/blueprint_instance.py +authentik_client/models/blueprint_instance_request.py +authentik_client/models/blueprint_instance_status_enum.py +authentik_client/models/brand.py +authentik_client/models/brand_request.py +authentik_client/models/bulk_delete_session_response.py +authentik_client/models/cache.py +authentik_client/models/capabilities_enum.py +authentik_client/models/captcha_challenge.py +authentik_client/models/captcha_challenge_response_request.py +authentik_client/models/captcha_stage.py +authentik_client/models/captcha_stage_request.py +authentik_client/models/cert_attribute_enum.py +authentik_client/models/certificate_data.py +authentik_client/models/certificate_generation_request.py +authentik_client/models/certificate_key_pair.py +authentik_client/models/certificate_key_pair_key_type_enum.py +authentik_client/models/certificate_key_pair_request.py +authentik_client/models/challenge_types.py +authentik_client/models/client_type_enum.py +authentik_client/models/compatibility_mode_enum.py +authentik_client/models/config.py +authentik_client/models/connection_token.py +authentik_client/models/connection_token_request.py +authentik_client/models/connector.py +authentik_client/models/consent_challenge.py +authentik_client/models/consent_challenge_response_request.py +authentik_client/models/consent_mode_enum.py +authentik_client/models/consent_permission.py +authentik_client/models/consent_stage.py +authentik_client/models/consent_stage_request.py +authentik_client/models/content_type.py +authentik_client/models/content_type_enum.py +authentik_client/models/contextual_flow_info.py +authentik_client/models/contextual_flow_info_layout_enum.py +authentik_client/models/country_code_enum.py +authentik_client/models/current_brand.py +authentik_client/models/current_brand_flags.py +authentik_client/models/data_export.py +authentik_client/models/delivery_method_enum.py +authentik_client/models/denied_action_enum.py +authentik_client/models/deny_stage.py +authentik_client/models/deny_stage_request.py +authentik_client/models/detailed_country.py +authentik_client/models/device.py +authentik_client/models/device_access_group.py +authentik_client/models/device_access_group_request.py +authentik_client/models/device_challenge.py +authentik_client/models/device_challenge_request.py +authentik_client/models/device_classes_enum.py +authentik_client/models/device_connection.py +authentik_client/models/device_fact_snapshot.py +authentik_client/models/device_facts.py +authentik_client/models/device_facts_os_family.py +authentik_client/models/device_facts_request.py +authentik_client/models/device_group.py +authentik_client/models/device_group_request.py +authentik_client/models/device_summary.py +authentik_client/models/device_user.py +authentik_client/models/device_user_binding.py +authentik_client/models/device_user_binding_request.py +authentik_client/models/device_user_request.py +authentik_client/models/digest_algorithm_enum.py +authentik_client/models/digits_enum.py +authentik_client/models/disk.py +authentik_client/models/disk_request.py +authentik_client/models/docker_service_connection.py +authentik_client/models/docker_service_connection_request.py +authentik_client/models/domain.py +authentik_client/models/domain_request.py +authentik_client/models/dummy_challenge.py +authentik_client/models/dummy_challenge_response_request.py +authentik_client/models/dummy_policy.py +authentik_client/models/dummy_policy_request.py +authentik_client/models/dummy_stage.py +authentik_client/models/dummy_stage_request.py +authentik_client/models/duo_device.py +authentik_client/models/duo_device_enrollment_status.py +authentik_client/models/duo_device_request.py +authentik_client/models/duo_response_enum.py +authentik_client/models/email_challenge.py +authentik_client/models/email_challenge_response_request.py +authentik_client/models/email_device.py +authentik_client/models/email_device_request.py +authentik_client/models/email_stage.py +authentik_client/models/email_stage_request.py +authentik_client/models/endpoint.py +authentik_client/models/endpoint_agent_challenge.py +authentik_client/models/endpoint_agent_challenge_response_request.py +authentik_client/models/endpoint_auth_mode_enum.py +authentik_client/models/endpoint_device.py +authentik_client/models/endpoint_device_details.py +authentik_client/models/endpoint_device_request.py +authentik_client/models/endpoint_request.py +authentik_client/models/endpoint_stage.py +authentik_client/models/endpoint_stage_request.py +authentik_client/models/enroll_request.py +authentik_client/models/enrollment_token.py +authentik_client/models/enrollment_token_request.py +authentik_client/models/error_detail.py +authentik_client/models/error_reporting_config.py +authentik_client/models/event.py +authentik_client/models/event_actions.py +authentik_client/models/event_matcher_policy.py +authentik_client/models/event_matcher_policy_request.py +authentik_client/models/event_request.py +authentik_client/models/event_stats.py +authentik_client/models/event_top_per_user.py +authentik_client/models/event_volume.py +authentik_client/models/events_requested_enum.py +authentik_client/models/expiring_base_grant_model.py +authentik_client/models/expression_policy.py +authentik_client/models/expression_policy_request.py +authentik_client/models/extra_role_object_permission.py +authentik_client/models/file_list.py +authentik_client/models/fleet_connector.py +authentik_client/models/fleet_connector_request.py +authentik_client/models/flow.py +authentik_client/models/flow_challenge_response_request.py +authentik_client/models/flow_designation_enum.py +authentik_client/models/flow_diagram.py +authentik_client/models/flow_error_challenge.py +authentik_client/models/flow_inspection.py +authentik_client/models/flow_inspector_plan.py +authentik_client/models/flow_layout_enum.py +authentik_client/models/flow_request.py +authentik_client/models/flow_set.py +authentik_client/models/flow_stage_binding.py +authentik_client/models/flow_stage_binding_request.py +authentik_client/models/footer_link.py +authentik_client/models/force_binding_enum.py +authentik_client/models/format_enum.py +authentik_client/models/frame_challenge.py +authentik_client/models/frame_challenge_response_request.py +authentik_client/models/generic_error.py +authentik_client/models/geo_ip_policy.py +authentik_client/models/geo_ip_policy_countries_obj_inner.py +authentik_client/models/geo_ip_policy_request.py +authentik_client/models/geoip_binding_enum.py +authentik_client/models/global_task_status.py +authentik_client/models/google_chrome_connector.py +authentik_client/models/google_chrome_connector_request.py +authentik_client/models/google_endpoint_device.py +authentik_client/models/google_endpoint_device_request.py +authentik_client/models/google_workspace_provider.py +authentik_client/models/google_workspace_provider_group.py +authentik_client/models/google_workspace_provider_group_request.py +authentik_client/models/google_workspace_provider_mapping.py +authentik_client/models/google_workspace_provider_mapping_request.py +authentik_client/models/google_workspace_provider_request.py +authentik_client/models/google_workspace_provider_user.py +authentik_client/models/google_workspace_provider_user_request.py +authentik_client/models/grant_types_enum.py +authentik_client/models/group.py +authentik_client/models/group_kerberos_source_connection.py +authentik_client/models/group_kerberos_source_connection_request.py +authentik_client/models/group_ldap_source_connection.py +authentik_client/models/group_ldap_source_connection_request.py +authentik_client/models/group_matching_mode_enum.py +authentik_client/models/group_o_auth_source_connection.py +authentik_client/models/group_o_auth_source_connection_request.py +authentik_client/models/group_plex_source_connection.py +authentik_client/models/group_plex_source_connection_request.py +authentik_client/models/group_request.py +authentik_client/models/group_saml_source_connection.py +authentik_client/models/group_saml_source_connection_request.py +authentik_client/models/group_source_connection.py +authentik_client/models/group_source_connection_request.py +authentik_client/models/group_telegram_source_connection.py +authentik_client/models/group_telegram_source_connection_request.py +authentik_client/models/hardware.py +authentik_client/models/hardware_request.py +authentik_client/models/identification_challenge.py +authentik_client/models/identification_challenge_response_request.py +authentik_client/models/identification_stage.py +authentik_client/models/identification_stage_request.py +authentik_client/models/iframe_logout_challenge.py +authentik_client/models/iframe_logout_challenge_response_request.py +authentik_client/models/impersonation_request.py +authentik_client/models/initial_permissions.py +authentik_client/models/initial_permissions_request.py +authentik_client/models/install_id.py +authentik_client/models/intent_enum.py +authentik_client/models/invalid_response_action_enum.py +authentik_client/models/invitation.py +authentik_client/models/invitation_request.py +authentik_client/models/invitation_send_email_request.py +authentik_client/models/invitation_stage.py +authentik_client/models/invitation_stage_request.py +authentik_client/models/issuer_mode_enum.py +authentik_client/models/kadmin_type_enum.py +authentik_client/models/kerberos_source.py +authentik_client/models/kerberos_source_property_mapping.py +authentik_client/models/kerberos_source_property_mapping_request.py +authentik_client/models/kerberos_source_request.py +authentik_client/models/key_type_enum.py +authentik_client/models/kubernetes_service_connection.py +authentik_client/models/kubernetes_service_connection_request.py +authentik_client/models/lang_enum.py +authentik_client/models/last_task_status_enum.py +authentik_client/models/ldap_check_access.py +authentik_client/models/ldap_debug.py +authentik_client/models/ldap_outpost_config.py +authentik_client/models/ldap_provider.py +authentik_client/models/ldap_provider_request.py +authentik_client/models/ldap_source.py +authentik_client/models/ldap_source_property_mapping.py +authentik_client/models/ldap_source_property_mapping_request.py +authentik_client/models/ldap_source_request.py +authentik_client/models/ldapapi_access_mode.py +authentik_client/models/license.py +authentik_client/models/license_flags_enum.py +authentik_client/models/license_forecast.py +authentik_client/models/license_request.py +authentik_client/models/license_status_enum.py +authentik_client/models/license_summary.py +authentik_client/models/license_summary_status_enum.py +authentik_client/models/lifecycle_iteration.py +authentik_client/models/lifecycle_iteration_request.py +authentik_client/models/lifecycle_iteration_state_enum.py +authentik_client/models/lifecycle_rule.py +authentik_client/models/lifecycle_rule_request.py +authentik_client/models/link.py +authentik_client/models/log_event.py +authentik_client/models/log_level_enum.py +authentik_client/models/login_challenge_types.py +authentik_client/models/login_source.py +authentik_client/models/logout_url.py +authentik_client/models/matching_mode_enum.py +authentik_client/models/mdm_config_request.py +authentik_client/models/mdm_config_response.py +authentik_client/models/metadata.py +authentik_client/models/microsoft_entra_provider.py +authentik_client/models/microsoft_entra_provider_group.py +authentik_client/models/microsoft_entra_provider_group_request.py +authentik_client/models/microsoft_entra_provider_mapping.py +authentik_client/models/microsoft_entra_provider_mapping_request.py +authentik_client/models/microsoft_entra_provider_request.py +authentik_client/models/microsoft_entra_provider_user.py +authentik_client/models/microsoft_entra_provider_user_request.py +authentik_client/models/model_enum.py +authentik_client/models/model_request.py +authentik_client/models/mutual_tls_stage.py +authentik_client/models/mutual_tls_stage_request.py +authentik_client/models/native_logout_challenge.py +authentik_client/models/native_logout_challenge_response_request.py +authentik_client/models/network.py +authentik_client/models/network_binding_enum.py +authentik_client/models/network_interface.py +authentik_client/models/network_interface_request.py +authentik_client/models/network_request.py +authentik_client/models/not_configured_action_enum.py +authentik_client/models/notification.py +authentik_client/models/notification_request.py +authentik_client/models/notification_rule.py +authentik_client/models/notification_rule_request.py +authentik_client/models/notification_transport.py +authentik_client/models/notification_transport_request.py +authentik_client/models/notification_transport_test.py +authentik_client/models/notification_webhook_mapping.py +authentik_client/models/notification_webhook_mapping_request.py +authentik_client/models/o_auth2_provider.py +authentik_client/models/o_auth2_provider_logout_method_enum.py +authentik_client/models/o_auth2_provider_request.py +authentik_client/models/o_auth2_provider_setup_urls.py +authentik_client/models/o_auth_device_code_challenge.py +authentik_client/models/o_auth_device_code_challenge_response_request.py +authentik_client/models/o_auth_device_code_finish_challenge.py +authentik_client/models/o_auth_device_code_finish_challenge_response_request.py +authentik_client/models/o_auth_source.py +authentik_client/models/o_auth_source_property_mapping.py +authentik_client/models/o_auth_source_property_mapping_request.py +authentik_client/models/o_auth_source_request.py +authentik_client/models/open_id_connect_configuration.py +authentik_client/models/operating_system.py +authentik_client/models/operating_system_request.py +authentik_client/models/outgoing_sync_delete_action.py +authentik_client/models/outpost.py +authentik_client/models/outpost_default_config.py +authentik_client/models/outpost_health.py +authentik_client/models/outpost_request.py +authentik_client/models/outpost_type_enum.py +authentik_client/models/paginated_account_lockdown_stage_list.py +authentik_client/models/paginated_agent_connector_list.py +authentik_client/models/paginated_apple_independent_secure_enclave_list.py +authentik_client/models/paginated_application_entitlement_list.py +authentik_client/models/paginated_application_list.py +authentik_client/models/paginated_authenticated_session_list.py +authentik_client/models/paginated_authenticator_duo_stage_list.py +authentik_client/models/paginated_authenticator_email_stage_list.py +authentik_client/models/paginated_authenticator_endpoint_gdtc_stage_list.py +authentik_client/models/paginated_authenticator_sms_stage_list.py +authentik_client/models/paginated_authenticator_static_stage_list.py +authentik_client/models/paginated_authenticator_totp_stage_list.py +authentik_client/models/paginated_authenticator_validate_stage_list.py +authentik_client/models/paginated_authenticator_web_authn_stage_list.py +authentik_client/models/paginated_blueprint_instance_list.py +authentik_client/models/paginated_brand_list.py +authentik_client/models/paginated_captcha_stage_list.py +authentik_client/models/paginated_certificate_key_pair_list.py +authentik_client/models/paginated_connection_token_list.py +authentik_client/models/paginated_connector_list.py +authentik_client/models/paginated_consent_stage_list.py +authentik_client/models/paginated_data_export_list.py +authentik_client/models/paginated_deny_stage_list.py +authentik_client/models/paginated_device_access_group_list.py +authentik_client/models/paginated_device_user_binding_list.py +authentik_client/models/paginated_docker_service_connection_list.py +authentik_client/models/paginated_domain_list.py +authentik_client/models/paginated_dummy_policy_list.py +authentik_client/models/paginated_dummy_stage_list.py +authentik_client/models/paginated_duo_device_list.py +authentik_client/models/paginated_email_device_list.py +authentik_client/models/paginated_email_stage_list.py +authentik_client/models/paginated_endpoint_device_list.py +authentik_client/models/paginated_endpoint_list.py +authentik_client/models/paginated_endpoint_stage_list.py +authentik_client/models/paginated_enrollment_token_list.py +authentik_client/models/paginated_event_list.py +authentik_client/models/paginated_event_matcher_policy_list.py +authentik_client/models/paginated_expiring_base_grant_model_list.py +authentik_client/models/paginated_expression_policy_list.py +authentik_client/models/paginated_extra_role_object_permission_list.py +authentik_client/models/paginated_fleet_connector_list.py +authentik_client/models/paginated_flow_list.py +authentik_client/models/paginated_flow_stage_binding_list.py +authentik_client/models/paginated_geo_ip_policy_list.py +authentik_client/models/paginated_google_chrome_connector_list.py +authentik_client/models/paginated_google_endpoint_device_list.py +authentik_client/models/paginated_google_workspace_provider_group_list.py +authentik_client/models/paginated_google_workspace_provider_list.py +authentik_client/models/paginated_google_workspace_provider_mapping_list.py +authentik_client/models/paginated_google_workspace_provider_user_list.py +authentik_client/models/paginated_group_kerberos_source_connection_list.py +authentik_client/models/paginated_group_ldap_source_connection_list.py +authentik_client/models/paginated_group_list.py +authentik_client/models/paginated_group_o_auth_source_connection_list.py +authentik_client/models/paginated_group_plex_source_connection_list.py +authentik_client/models/paginated_group_saml_source_connection_list.py +authentik_client/models/paginated_group_source_connection_list.py +authentik_client/models/paginated_group_telegram_source_connection_list.py +authentik_client/models/paginated_identification_stage_list.py +authentik_client/models/paginated_initial_permissions_list.py +authentik_client/models/paginated_invitation_list.py +authentik_client/models/paginated_invitation_stage_list.py +authentik_client/models/paginated_kerberos_source_list.py +authentik_client/models/paginated_kerberos_source_property_mapping_list.py +authentik_client/models/paginated_kubernetes_service_connection_list.py +authentik_client/models/paginated_ldap_outpost_config_list.py +authentik_client/models/paginated_ldap_provider_list.py +authentik_client/models/paginated_ldap_source_list.py +authentik_client/models/paginated_ldap_source_property_mapping_list.py +authentik_client/models/paginated_license_list.py +authentik_client/models/paginated_lifecycle_iteration_list.py +authentik_client/models/paginated_lifecycle_rule_list.py +authentik_client/models/paginated_microsoft_entra_provider_group_list.py +authentik_client/models/paginated_microsoft_entra_provider_list.py +authentik_client/models/paginated_microsoft_entra_provider_mapping_list.py +authentik_client/models/paginated_microsoft_entra_provider_user_list.py +authentik_client/models/paginated_mutual_tls_stage_list.py +authentik_client/models/paginated_notification_list.py +authentik_client/models/paginated_notification_rule_list.py +authentik_client/models/paginated_notification_transport_list.py +authentik_client/models/paginated_notification_webhook_mapping_list.py +authentik_client/models/paginated_o_auth2_provider_list.py +authentik_client/models/paginated_o_auth_source_list.py +authentik_client/models/paginated_o_auth_source_property_mapping_list.py +authentik_client/models/paginated_outpost_list.py +authentik_client/models/paginated_password_expiry_policy_list.py +authentik_client/models/paginated_password_policy_list.py +authentik_client/models/paginated_password_stage_list.py +authentik_client/models/paginated_permission_list.py +authentik_client/models/paginated_plex_source_list.py +authentik_client/models/paginated_plex_source_property_mapping_list.py +authentik_client/models/paginated_policy_binding_list.py +authentik_client/models/paginated_policy_list.py +authentik_client/models/paginated_prompt_list.py +authentik_client/models/paginated_prompt_stage_list.py +authentik_client/models/paginated_property_mapping_list.py +authentik_client/models/paginated_provider_list.py +authentik_client/models/paginated_proxy_outpost_config_list.py +authentik_client/models/paginated_proxy_provider_list.py +authentik_client/models/paginated_rac_property_mapping_list.py +authentik_client/models/paginated_rac_provider_list.py +authentik_client/models/paginated_radius_outpost_config_list.py +authentik_client/models/paginated_radius_provider_list.py +authentik_client/models/paginated_radius_provider_property_mapping_list.py +authentik_client/models/paginated_redirect_stage_list.py +authentik_client/models/paginated_reputation_list.py +authentik_client/models/paginated_reputation_policy_list.py +authentik_client/models/paginated_role_assigned_object_permission_list.py +authentik_client/models/paginated_role_list.py +authentik_client/models/paginated_saml_property_mapping_list.py +authentik_client/models/paginated_saml_provider_list.py +authentik_client/models/paginated_saml_source_list.py +authentik_client/models/paginated_saml_source_property_mapping_list.py +authentik_client/models/paginated_schedule_list.py +authentik_client/models/paginated_scim_mapping_list.py +authentik_client/models/paginated_scim_provider_group_list.py +authentik_client/models/paginated_scim_provider_list.py +authentik_client/models/paginated_scim_provider_user_list.py +authentik_client/models/paginated_scim_source_group_list.py +authentik_client/models/paginated_scim_source_list.py +authentik_client/models/paginated_scim_source_property_mapping_list.py +authentik_client/models/paginated_scim_source_user_list.py +authentik_client/models/paginated_scope_mapping_list.py +authentik_client/models/paginated_service_connection_list.py +authentik_client/models/paginated_sms_device_list.py +authentik_client/models/paginated_source_list.py +authentik_client/models/paginated_source_stage_list.py +authentik_client/models/paginated_ssf_provider_list.py +authentik_client/models/paginated_ssf_stream_list.py +authentik_client/models/paginated_stage_list.py +authentik_client/models/paginated_static_device_list.py +authentik_client/models/paginated_task_list.py +authentik_client/models/paginated_telegram_source_list.py +authentik_client/models/paginated_telegram_source_property_mapping_list.py +authentik_client/models/paginated_tenant_list.py +authentik_client/models/paginated_token_list.py +authentik_client/models/paginated_token_model_list.py +authentik_client/models/paginated_totp_device_list.py +authentik_client/models/paginated_unique_password_policy_list.py +authentik_client/models/paginated_user_consent_list.py +authentik_client/models/paginated_user_delete_stage_list.py +authentik_client/models/paginated_user_kerberos_source_connection_list.py +authentik_client/models/paginated_user_ldap_source_connection_list.py +authentik_client/models/paginated_user_list.py +authentik_client/models/paginated_user_login_stage_list.py +authentik_client/models/paginated_user_logout_stage_list.py +authentik_client/models/paginated_user_o_auth_source_connection_list.py +authentik_client/models/paginated_user_plex_source_connection_list.py +authentik_client/models/paginated_user_saml_source_connection_list.py +authentik_client/models/paginated_user_source_connection_list.py +authentik_client/models/paginated_user_telegram_source_connection_list.py +authentik_client/models/paginated_user_write_stage_list.py +authentik_client/models/paginated_web_authn_device_list.py +authentik_client/models/paginated_web_authn_device_type_list.py +authentik_client/models/paginated_ws_federation_provider_list.py +authentik_client/models/pagination.py +authentik_client/models/partial_group.py +authentik_client/models/partial_user.py +authentik_client/models/password_challenge.py +authentik_client/models/password_challenge_response_request.py +authentik_client/models/password_expiry_policy.py +authentik_client/models/password_expiry_policy_request.py +authentik_client/models/password_policy.py +authentik_client/models/password_policy_request.py +authentik_client/models/password_stage.py +authentik_client/models/password_stage_request.py +authentik_client/models/patched_account_lockdown_stage_request.py +authentik_client/models/patched_agent_connector_request.py +authentik_client/models/patched_apple_independent_secure_enclave_request.py +authentik_client/models/patched_application_entitlement_request.py +authentik_client/models/patched_application_request.py +authentik_client/models/patched_authenticator_duo_stage_request.py +authentik_client/models/patched_authenticator_email_stage_request.py +authentik_client/models/patched_authenticator_endpoint_gdtc_stage_request.py +authentik_client/models/patched_authenticator_sms_stage_request.py +authentik_client/models/patched_authenticator_static_stage_request.py +authentik_client/models/patched_authenticator_totp_stage_request.py +authentik_client/models/patched_authenticator_validate_stage_request.py +authentik_client/models/patched_authenticator_web_authn_stage_request.py +authentik_client/models/patched_blueprint_instance_request.py +authentik_client/models/patched_brand_request.py +authentik_client/models/patched_captcha_stage_request.py +authentik_client/models/patched_certificate_key_pair_request.py +authentik_client/models/patched_connection_token_request.py +authentik_client/models/patched_consent_stage_request.py +authentik_client/models/patched_deny_stage_request.py +authentik_client/models/patched_device_access_group_request.py +authentik_client/models/patched_device_user_binding_request.py +authentik_client/models/patched_docker_service_connection_request.py +authentik_client/models/patched_domain_request.py +authentik_client/models/patched_dummy_policy_request.py +authentik_client/models/patched_dummy_stage_request.py +authentik_client/models/patched_duo_device_request.py +authentik_client/models/patched_email_device_request.py +authentik_client/models/patched_email_stage_request.py +authentik_client/models/patched_endpoint_device_request.py +authentik_client/models/patched_endpoint_request.py +authentik_client/models/patched_endpoint_stage_request.py +authentik_client/models/patched_enrollment_token_request.py +authentik_client/models/patched_event_matcher_policy_request.py +authentik_client/models/patched_event_request.py +authentik_client/models/patched_expression_policy_request.py +authentik_client/models/patched_fleet_connector_request.py +authentik_client/models/patched_flow_request.py +authentik_client/models/patched_flow_stage_binding_request.py +authentik_client/models/patched_geo_ip_policy_request.py +authentik_client/models/patched_google_chrome_connector_request.py +authentik_client/models/patched_google_endpoint_device_request.py +authentik_client/models/patched_google_workspace_provider_mapping_request.py +authentik_client/models/patched_google_workspace_provider_request.py +authentik_client/models/patched_group_kerberos_source_connection_request.py +authentik_client/models/patched_group_ldap_source_connection_request.py +authentik_client/models/patched_group_o_auth_source_connection_request.py +authentik_client/models/patched_group_plex_source_connection_request.py +authentik_client/models/patched_group_request.py +authentik_client/models/patched_group_saml_source_connection_request.py +authentik_client/models/patched_group_source_connection_request.py +authentik_client/models/patched_group_telegram_source_connection_request.py +authentik_client/models/patched_identification_stage_request.py +authentik_client/models/patched_initial_permissions_request.py +authentik_client/models/patched_invitation_request.py +authentik_client/models/patched_invitation_stage_request.py +authentik_client/models/patched_kerberos_source_property_mapping_request.py +authentik_client/models/patched_kerberos_source_request.py +authentik_client/models/patched_kubernetes_service_connection_request.py +authentik_client/models/patched_ldap_provider_request.py +authentik_client/models/patched_ldap_source_property_mapping_request.py +authentik_client/models/patched_ldap_source_request.py +authentik_client/models/patched_license_request.py +authentik_client/models/patched_lifecycle_rule_request.py +authentik_client/models/patched_microsoft_entra_provider_mapping_request.py +authentik_client/models/patched_microsoft_entra_provider_request.py +authentik_client/models/patched_mutual_tls_stage_request.py +authentik_client/models/patched_notification_request.py +authentik_client/models/patched_notification_rule_request.py +authentik_client/models/patched_notification_transport_request.py +authentik_client/models/patched_notification_webhook_mapping_request.py +authentik_client/models/patched_o_auth2_provider_request.py +authentik_client/models/patched_o_auth_source_property_mapping_request.py +authentik_client/models/patched_o_auth_source_request.py +authentik_client/models/patched_outpost_request.py +authentik_client/models/patched_password_expiry_policy_request.py +authentik_client/models/patched_password_policy_request.py +authentik_client/models/patched_password_stage_request.py +authentik_client/models/patched_permission_assign_request.py +authentik_client/models/patched_plex_source_property_mapping_request.py +authentik_client/models/patched_plex_source_request.py +authentik_client/models/patched_policy_binding_request.py +authentik_client/models/patched_prompt_request.py +authentik_client/models/patched_prompt_stage_request.py +authentik_client/models/patched_proxy_provider_request.py +authentik_client/models/patched_rac_property_mapping_request.py +authentik_client/models/patched_rac_provider_request.py +authentik_client/models/patched_radius_provider_property_mapping_request.py +authentik_client/models/patched_radius_provider_request.py +authentik_client/models/patched_redirect_stage_request.py +authentik_client/models/patched_reputation_policy_request.py +authentik_client/models/patched_role_request.py +authentik_client/models/patched_saml_property_mapping_request.py +authentik_client/models/patched_saml_provider_request.py +authentik_client/models/patched_saml_source_property_mapping_request.py +authentik_client/models/patched_saml_source_request.py +authentik_client/models/patched_schedule_request.py +authentik_client/models/patched_scim_mapping_request.py +authentik_client/models/patched_scim_provider_request.py +authentik_client/models/patched_scim_source_group_request.py +authentik_client/models/patched_scim_source_property_mapping_request.py +authentik_client/models/patched_scim_source_request.py +authentik_client/models/patched_scim_source_user_request.py +authentik_client/models/patched_scope_mapping_request.py +authentik_client/models/patched_settings_request.py +authentik_client/models/patched_settings_request_flags.py +authentik_client/models/patched_sms_device_request.py +authentik_client/models/patched_source_stage_request.py +authentik_client/models/patched_ssf_provider_request.py +authentik_client/models/patched_static_device_request.py +authentik_client/models/patched_telegram_source_property_mapping_request.py +authentik_client/models/patched_telegram_source_request.py +authentik_client/models/patched_tenant_request.py +authentik_client/models/patched_token_request.py +authentik_client/models/patched_totp_device_request.py +authentik_client/models/patched_unique_password_policy_request.py +authentik_client/models/patched_user_delete_stage_request.py +authentik_client/models/patched_user_kerberos_source_connection_request.py +authentik_client/models/patched_user_ldap_source_connection_request.py +authentik_client/models/patched_user_login_stage_request.py +authentik_client/models/patched_user_logout_stage_request.py +authentik_client/models/patched_user_o_auth_source_connection_request.py +authentik_client/models/patched_user_plex_source_connection_request.py +authentik_client/models/patched_user_request.py +authentik_client/models/patched_user_saml_source_connection_request.py +authentik_client/models/patched_user_source_connection_request.py +authentik_client/models/patched_user_telegram_source_connection_request.py +authentik_client/models/patched_user_write_stage_request.py +authentik_client/models/patched_web_authn_device_request.py +authentik_client/models/patched_ws_federation_provider_request.py +authentik_client/models/permission.py +authentik_client/models/permission_assign_request.py +authentik_client/models/permission_assign_result.py +authentik_client/models/pkce_method_enum.py +authentik_client/models/plex_authentication_challenge.py +authentik_client/models/plex_authentication_challenge_response_request.py +authentik_client/models/plex_source.py +authentik_client/models/plex_source_property_mapping.py +authentik_client/models/plex_source_property_mapping_request.py +authentik_client/models/plex_source_request.py +authentik_client/models/plex_token_redeem_request.py +authentik_client/models/policy.py +authentik_client/models/policy_binding.py +authentik_client/models/policy_binding_request.py +authentik_client/models/policy_engine_mode.py +authentik_client/models/policy_test_request.py +authentik_client/models/policy_test_result.py +authentik_client/models/process.py +authentik_client/models/process_request.py +authentik_client/models/prompt.py +authentik_client/models/prompt_challenge.py +authentik_client/models/prompt_challenge_response_request.py +authentik_client/models/prompt_choice.py +authentik_client/models/prompt_request.py +authentik_client/models/prompt_stage.py +authentik_client/models/prompt_stage_request.py +authentik_client/models/prompt_type_enum.py +authentik_client/models/property_mapping.py +authentik_client/models/property_mapping_preview.py +authentik_client/models/property_mapping_test_request.py +authentik_client/models/property_mapping_test_result.py +authentik_client/models/protocol_enum.py +authentik_client/models/provider.py +authentik_client/models/provider_enum.py +authentik_client/models/provider_model_enum.py +authentik_client/models/provider_type_enum.py +authentik_client/models/proxy_mode.py +authentik_client/models/proxy_outpost_config.py +authentik_client/models/proxy_provider.py +authentik_client/models/proxy_provider_request.py +authentik_client/models/rac_property_mapping.py +authentik_client/models/rac_property_mapping_request.py +authentik_client/models/rac_provider.py +authentik_client/models/rac_provider_request.py +authentik_client/models/radius_check_access.py +authentik_client/models/radius_outpost_config.py +authentik_client/models/radius_provider.py +authentik_client/models/radius_provider_property_mapping.py +authentik_client/models/radius_provider_property_mapping_request.py +authentik_client/models/radius_provider_request.py +authentik_client/models/redirect_challenge.py +authentik_client/models/redirect_challenge_response_request.py +authentik_client/models/redirect_stage.py +authentik_client/models/redirect_stage_mode_enum.py +authentik_client/models/redirect_stage_request.py +authentik_client/models/redirect_uri.py +authentik_client/models/redirect_uri_request.py +authentik_client/models/redirect_uri_type_enum.py +authentik_client/models/related_group.py +authentik_client/models/related_rule.py +authentik_client/models/reputation.py +authentik_client/models/reputation_policy.py +authentik_client/models/reputation_policy_request.py +authentik_client/models/review.py +authentik_client/models/review_request.py +authentik_client/models/reviewer_group.py +authentik_client/models/reviewer_user.py +authentik_client/models/role.py +authentik_client/models/role_assigned_object_permission.py +authentik_client/models/role_model_permission.py +authentik_client/models/role_object_permission.py +authentik_client/models/role_request.py +authentik_client/models/saml_bindings_enum.py +authentik_client/models/saml_logout_methods.py +authentik_client/models/saml_metadata.py +authentik_client/models/saml_name_id_policy_enum.py +authentik_client/models/saml_property_mapping.py +authentik_client/models/saml_property_mapping_request.py +authentik_client/models/saml_provider.py +authentik_client/models/saml_provider_request.py +authentik_client/models/saml_source.py +authentik_client/models/saml_source_property_mapping.py +authentik_client/models/saml_source_property_mapping_request.py +authentik_client/models/saml_source_request.py +authentik_client/models/schedule.py +authentik_client/models/schedule_request.py +authentik_client/models/scim_authentication_mode_enum.py +authentik_client/models/scim_mapping.py +authentik_client/models/scim_mapping_request.py +authentik_client/models/scim_provider.py +authentik_client/models/scim_provider_group.py +authentik_client/models/scim_provider_group_request.py +authentik_client/models/scim_provider_request.py +authentik_client/models/scim_provider_user.py +authentik_client/models/scim_provider_user_request.py +authentik_client/models/scim_source.py +authentik_client/models/scim_source_group.py +authentik_client/models/scim_source_group_request.py +authentik_client/models/scim_source_property_mapping.py +authentik_client/models/scim_source_property_mapping_request.py +authentik_client/models/scim_source_request.py +authentik_client/models/scim_source_user.py +authentik_client/models/scim_source_user_request.py +authentik_client/models/scope_mapping.py +authentik_client/models/scope_mapping_request.py +authentik_client/models/selectable_stage.py +authentik_client/models/service_connection.py +authentik_client/models/service_connection_state.py +authentik_client/models/session_end_challenge.py +authentik_client/models/session_user.py +authentik_client/models/settings.py +authentik_client/models/settings_request.py +authentik_client/models/severity_enum.py +authentik_client/models/shell_challenge.py +authentik_client/models/signature_algorithm_enum.py +authentik_client/models/sms_device.py +authentik_client/models/sms_device_request.py +authentik_client/models/software.py +authentik_client/models/software_request.py +authentik_client/models/source.py +authentik_client/models/source_stage.py +authentik_client/models/source_stage_request.py +authentik_client/models/source_type.py +authentik_client/models/ssf_provider.py +authentik_client/models/ssf_provider_request.py +authentik_client/models/ssf_stream.py +authentik_client/models/ssf_stream_status_enum.py +authentik_client/models/stage.py +authentik_client/models/stage_mode_enum.py +authentik_client/models/stage_prompt.py +authentik_client/models/static_device.py +authentik_client/models/static_device_request.py +authentik_client/models/static_device_token.py +authentik_client/models/sub_mode_enum.py +authentik_client/models/sync_object_model_enum.py +authentik_client/models/sync_object_request.py +authentik_client/models/sync_object_result.py +authentik_client/models/sync_outgoing_trigger_mode_enum.py +authentik_client/models/sync_status.py +authentik_client/models/system_info.py +authentik_client/models/system_info_runtime.py +authentik_client/models/task.py +authentik_client/models/task_aggregated_status_enum.py +authentik_client/models/task_status_enum.py +authentik_client/models/telegram_auth_request.py +authentik_client/models/telegram_challenge_response_request.py +authentik_client/models/telegram_login_challenge.py +authentik_client/models/telegram_source.py +authentik_client/models/telegram_source_property_mapping.py +authentik_client/models/telegram_source_property_mapping_request.py +authentik_client/models/telegram_source_request.py +authentik_client/models/tenant.py +authentik_client/models/tenant_admin_group_request_request.py +authentik_client/models/tenant_recovery_key_request_request.py +authentik_client/models/tenant_recovery_key_response.py +authentik_client/models/tenant_request.py +authentik_client/models/themed_urls.py +authentik_client/models/token.py +authentik_client/models/token_model.py +authentik_client/models/token_request.py +authentik_client/models/token_set_key_request.py +authentik_client/models/token_view.py +authentik_client/models/totp_device.py +authentik_client/models/totp_device_request.py +authentik_client/models/transaction_application_request.py +authentik_client/models/transaction_application_response.py +authentik_client/models/transaction_policy_binding_request.py +authentik_client/models/transport_mode_enum.py +authentik_client/models/type_create.py +authentik_client/models/ui_theme_enum.py +authentik_client/models/unique_password_policy.py +authentik_client/models/unique_password_policy_request.py +authentik_client/models/usage_enum.py +authentik_client/models/used_by.py +authentik_client/models/used_by_action_enum.py +authentik_client/models/user.py +authentik_client/models/user_account_lockdown_request.py +authentik_client/models/user_account_request.py +authentik_client/models/user_account_serializer_for_role_request.py +authentik_client/models/user_attribute_enum.py +authentik_client/models/user_consent.py +authentik_client/models/user_creation_mode_enum.py +authentik_client/models/user_delete_stage.py +authentik_client/models/user_delete_stage_request.py +authentik_client/models/user_fields_enum.py +authentik_client/models/user_kerberos_source_connection.py +authentik_client/models/user_kerberos_source_connection_request.py +authentik_client/models/user_ldap_source_connection.py +authentik_client/models/user_ldap_source_connection_request.py +authentik_client/models/user_login_challenge.py +authentik_client/models/user_login_challenge_response_request.py +authentik_client/models/user_login_stage.py +authentik_client/models/user_login_stage_request.py +authentik_client/models/user_logout_stage.py +authentik_client/models/user_logout_stage_request.py +authentik_client/models/user_matching_mode_enum.py +authentik_client/models/user_o_auth_source_connection.py +authentik_client/models/user_o_auth_source_connection_request.py +authentik_client/models/user_password_hash_set_request.py +authentik_client/models/user_password_set_request.py +authentik_client/models/user_path.py +authentik_client/models/user_plex_source_connection.py +authentik_client/models/user_plex_source_connection_request.py +authentik_client/models/user_recovery_email_request.py +authentik_client/models/user_recovery_link_request.py +authentik_client/models/user_request.py +authentik_client/models/user_saml_source_connection.py +authentik_client/models/user_saml_source_connection_request.py +authentik_client/models/user_self.py +authentik_client/models/user_self_groups.py +authentik_client/models/user_self_roles.py +authentik_client/models/user_service_account_request.py +authentik_client/models/user_service_account_response.py +authentik_client/models/user_setting.py +authentik_client/models/user_source_connection.py +authentik_client/models/user_source_connection_request.py +authentik_client/models/user_telegram_source_connection.py +authentik_client/models/user_telegram_source_connection_request.py +authentik_client/models/user_type_enum.py +authentik_client/models/user_verification_enum.py +authentik_client/models/user_write_stage.py +authentik_client/models/user_write_stage_request.py +authentik_client/models/validation_error.py +authentik_client/models/vendor_enum.py +authentik_client/models/version.py +authentik_client/models/version_history.py +authentik_client/models/web_authn_device.py +authentik_client/models/web_authn_device_request.py +authentik_client/models/web_authn_device_type.py +authentik_client/models/web_authn_hint_enum.py +authentik_client/models/worker.py +authentik_client/models/ws_federation_provider.py +authentik_client/models/ws_federation_provider_request.py +authentik_client/py.typed +authentik_client/rest.py +docs/AccessDeniedChallenge.md +docs/AccountLockdownStage.md +docs/AccountLockdownStageRequest.md +docs/AdminApi.md +docs/AgentAuthenticationResponse.md +docs/AgentConfig.md +docs/AgentConnector.md +docs/AgentConnectorRequest.md +docs/AgentPSSODeviceRegistrationRequest.md +docs/AgentPSSODeviceRegistrationResponse.md +docs/AgentPSSOUserRegistrationRequest.md +docs/AgentTokenResponse.md +docs/AlgEnum.md +docs/App.md +docs/AppEnum.md +docs/AppleChallengeResponseRequest.md +docs/AppleIndependentSecureEnclave.md +docs/AppleIndependentSecureEnclaveRequest.md +docs/AppleLoginChallenge.md +docs/Application.md +docs/ApplicationEntitlement.md +docs/ApplicationEntitlementRequest.md +docs/ApplicationRequest.md +docs/AuthTypeEnum.md +docs/AuthenticatedSession.md +docs/AuthenticatedSessionAsn.md +docs/AuthenticatedSessionGeoIp.md +docs/AuthenticatedSessionUserAgent.md +docs/AuthenticatedSessionUserAgentDevice.md +docs/AuthenticatedSessionUserAgentOs.md +docs/AuthenticatedSessionUserAgentUserAgent.md +docs/AuthenticationEnum.md +docs/AuthenticatorAttachmentEnum.md +docs/AuthenticatorDuoChallenge.md +docs/AuthenticatorDuoChallengeResponseRequest.md +docs/AuthenticatorDuoStage.md +docs/AuthenticatorDuoStageDeviceImportResponse.md +docs/AuthenticatorDuoStageManualDeviceImportRequest.md +docs/AuthenticatorDuoStageRequest.md +docs/AuthenticatorEmailChallenge.md +docs/AuthenticatorEmailChallengeResponseRequest.md +docs/AuthenticatorEmailStage.md +docs/AuthenticatorEmailStageRequest.md +docs/AuthenticatorEndpointGDTCStage.md +docs/AuthenticatorEndpointGDTCStageRequest.md +docs/AuthenticatorSMSChallenge.md +docs/AuthenticatorSMSChallengeResponseRequest.md +docs/AuthenticatorSMSStage.md +docs/AuthenticatorSMSStageRequest.md +docs/AuthenticatorStaticChallenge.md +docs/AuthenticatorStaticChallengeResponseRequest.md +docs/AuthenticatorStaticStage.md +docs/AuthenticatorStaticStageRequest.md +docs/AuthenticatorTOTPChallenge.md +docs/AuthenticatorTOTPChallengeResponseRequest.md +docs/AuthenticatorTOTPStage.md +docs/AuthenticatorTOTPStageRequest.md +docs/AuthenticatorValidateStage.md +docs/AuthenticatorValidateStageRequest.md +docs/AuthenticatorValidationChallenge.md +docs/AuthenticatorValidationChallengeResponseRequest.md +docs/AuthenticatorWebAuthnChallenge.md +docs/AuthenticatorWebAuthnChallengeResponseRequest.md +docs/AuthenticatorWebAuthnStage.md +docs/AuthenticatorWebAuthnStageRequest.md +docs/AuthenticatorsApi.md +docs/AuthorizationCodeAuthMethodEnum.md +docs/AutoSubmitChallengeResponseRequest.md +docs/AutosubmitChallenge.md +docs/BackendsEnum.md +docs/BindingTypeEnum.md +docs/BlueprintFile.md +docs/BlueprintImportResult.md +docs/BlueprintInstance.md +docs/BlueprintInstanceRequest.md +docs/BlueprintInstanceStatusEnum.md +docs/Brand.md +docs/BrandRequest.md +docs/BulkDeleteSessionResponse.md +docs/Cache.md +docs/CapabilitiesEnum.md +docs/CaptchaChallenge.md +docs/CaptchaChallengeResponseRequest.md +docs/CaptchaStage.md +docs/CaptchaStageRequest.md +docs/CertAttributeEnum.md +docs/CertificateData.md +docs/CertificateGenerationRequest.md +docs/CertificateKeyPair.md +docs/CertificateKeyPairKeyTypeEnum.md +docs/CertificateKeyPairRequest.md +docs/ChallengeTypes.md +docs/ClientTypeEnum.md +docs/CompatibilityModeEnum.md +docs/Config.md +docs/ConnectionToken.md +docs/ConnectionTokenRequest.md +docs/Connector.md +docs/ConsentChallenge.md +docs/ConsentChallengeResponseRequest.md +docs/ConsentModeEnum.md +docs/ConsentPermission.md +docs/ConsentStage.md +docs/ConsentStageRequest.md +docs/ContentType.md +docs/ContentTypeEnum.md +docs/ContextualFlowInfo.md +docs/ContextualFlowInfoLayoutEnum.md +docs/CoreApi.md +docs/CountryCodeEnum.md +docs/CryptoApi.md +docs/CurrentBrand.md +docs/CurrentBrandFlags.md +docs/DataExport.md +docs/DeliveryMethodEnum.md +docs/DeniedActionEnum.md +docs/DenyStage.md +docs/DenyStageRequest.md +docs/DetailedCountry.md +docs/Device.md +docs/DeviceAccessGroup.md +docs/DeviceAccessGroupRequest.md +docs/DeviceChallenge.md +docs/DeviceChallengeRequest.md +docs/DeviceClassesEnum.md +docs/DeviceConnection.md +docs/DeviceFactSnapshot.md +docs/DeviceFacts.md +docs/DeviceFactsOSFamily.md +docs/DeviceFactsRequest.md +docs/DeviceGroup.md +docs/DeviceGroupRequest.md +docs/DeviceSummary.md +docs/DeviceUser.md +docs/DeviceUserBinding.md +docs/DeviceUserBindingRequest.md +docs/DeviceUserRequest.md +docs/DigestAlgorithmEnum.md +docs/DigitsEnum.md +docs/Disk.md +docs/DiskRequest.md +docs/DockerServiceConnection.md +docs/DockerServiceConnectionRequest.md +docs/Domain.md +docs/DomainRequest.md +docs/DummyChallenge.md +docs/DummyChallengeResponseRequest.md +docs/DummyPolicy.md +docs/DummyPolicyRequest.md +docs/DummyStage.md +docs/DummyStageRequest.md +docs/DuoDevice.md +docs/DuoDeviceEnrollmentStatus.md +docs/DuoDeviceRequest.md +docs/DuoResponseEnum.md +docs/EmailChallenge.md +docs/EmailChallengeResponseRequest.md +docs/EmailDevice.md +docs/EmailDeviceRequest.md +docs/EmailStage.md +docs/EmailStageRequest.md +docs/Endpoint.md +docs/EndpointAgentChallenge.md +docs/EndpointAgentChallengeResponseRequest.md +docs/EndpointAuthModeEnum.md +docs/EndpointDevice.md +docs/EndpointDeviceDetails.md +docs/EndpointDeviceRequest.md +docs/EndpointRequest.md +docs/EndpointStage.md +docs/EndpointStageRequest.md +docs/EndpointsApi.md +docs/EnrollRequest.md +docs/EnrollmentToken.md +docs/EnrollmentTokenRequest.md +docs/EnterpriseApi.md +docs/ErrorDetail.md +docs/ErrorReportingConfig.md +docs/Event.md +docs/EventActions.md +docs/EventMatcherPolicy.md +docs/EventMatcherPolicyRequest.md +docs/EventRequest.md +docs/EventStats.md +docs/EventTopPerUser.md +docs/EventVolume.md +docs/EventsApi.md +docs/EventsRequestedEnum.md +docs/ExpiringBaseGrantModel.md +docs/ExpressionPolicy.md +docs/ExpressionPolicyRequest.md +docs/ExtraRoleObjectPermission.md +docs/FileList.md +docs/FleetConnector.md +docs/FleetConnectorRequest.md +docs/Flow.md +docs/FlowChallengeResponseRequest.md +docs/FlowDesignationEnum.md +docs/FlowDiagram.md +docs/FlowErrorChallenge.md +docs/FlowInspection.md +docs/FlowInspectorPlan.md +docs/FlowLayoutEnum.md +docs/FlowRequest.md +docs/FlowSet.md +docs/FlowStageBinding.md +docs/FlowStageBindingRequest.md +docs/FlowsApi.md +docs/FooterLink.md +docs/ForceBindingEnum.md +docs/FormatEnum.md +docs/FrameChallenge.md +docs/FrameChallengeResponseRequest.md +docs/GenericError.md +docs/GeoIPPolicy.md +docs/GeoIPPolicyCountriesObjInner.md +docs/GeoIPPolicyRequest.md +docs/GeoipBindingEnum.md +docs/GlobalTaskStatus.md +docs/GoogleChromeConnector.md +docs/GoogleChromeConnectorRequest.md +docs/GoogleEndpointDevice.md +docs/GoogleEndpointDeviceRequest.md +docs/GoogleWorkspaceProvider.md +docs/GoogleWorkspaceProviderGroup.md +docs/GoogleWorkspaceProviderGroupRequest.md +docs/GoogleWorkspaceProviderMapping.md +docs/GoogleWorkspaceProviderMappingRequest.md +docs/GoogleWorkspaceProviderRequest.md +docs/GoogleWorkspaceProviderUser.md +docs/GoogleWorkspaceProviderUserRequest.md +docs/GrantTypesEnum.md +docs/Group.md +docs/GroupKerberosSourceConnection.md +docs/GroupKerberosSourceConnectionRequest.md +docs/GroupLDAPSourceConnection.md +docs/GroupLDAPSourceConnectionRequest.md +docs/GroupMatchingModeEnum.md +docs/GroupOAuthSourceConnection.md +docs/GroupOAuthSourceConnectionRequest.md +docs/GroupPlexSourceConnection.md +docs/GroupPlexSourceConnectionRequest.md +docs/GroupRequest.md +docs/GroupSAMLSourceConnection.md +docs/GroupSAMLSourceConnectionRequest.md +docs/GroupSourceConnection.md +docs/GroupSourceConnectionRequest.md +docs/GroupTelegramSourceConnection.md +docs/GroupTelegramSourceConnectionRequest.md +docs/Hardware.md +docs/HardwareRequest.md +docs/IdentificationChallenge.md +docs/IdentificationChallengeResponseRequest.md +docs/IdentificationStage.md +docs/IdentificationStageRequest.md +docs/IframeLogoutChallenge.md +docs/IframeLogoutChallengeResponseRequest.md +docs/ImpersonationRequest.md +docs/InitialPermissions.md +docs/InitialPermissionsRequest.md +docs/InstallID.md +docs/IntentEnum.md +docs/InvalidResponseActionEnum.md +docs/Invitation.md +docs/InvitationRequest.md +docs/InvitationSendEmailRequest.md +docs/InvitationStage.md +docs/InvitationStageRequest.md +docs/IssuerModeEnum.md +docs/KadminTypeEnum.md +docs/KerberosSource.md +docs/KerberosSourcePropertyMapping.md +docs/KerberosSourcePropertyMappingRequest.md +docs/KerberosSourceRequest.md +docs/KeyTypeEnum.md +docs/KubernetesServiceConnection.md +docs/KubernetesServiceConnectionRequest.md +docs/LDAPAPIAccessMode.md +docs/LDAPCheckAccess.md +docs/LDAPDebug.md +docs/LDAPOutpostConfig.md +docs/LDAPProvider.md +docs/LDAPProviderRequest.md +docs/LDAPSource.md +docs/LDAPSourcePropertyMapping.md +docs/LDAPSourcePropertyMappingRequest.md +docs/LDAPSourceRequest.md +docs/LangEnum.md +docs/LastTaskStatusEnum.md +docs/License.md +docs/LicenseFlagsEnum.md +docs/LicenseForecast.md +docs/LicenseRequest.md +docs/LicenseStatusEnum.md +docs/LicenseSummary.md +docs/LicenseSummaryStatusEnum.md +docs/LifecycleApi.md +docs/LifecycleIteration.md +docs/LifecycleIterationRequest.md +docs/LifecycleIterationStateEnum.md +docs/LifecycleRule.md +docs/LifecycleRuleRequest.md +docs/Link.md +docs/LogEvent.md +docs/LogLevelEnum.md +docs/LoginChallengeTypes.md +docs/LoginSource.md +docs/LogoutURL.md +docs/MDMConfigRequest.md +docs/MDMConfigResponse.md +docs/ManagedApi.md +docs/MatchingModeEnum.md +docs/Metadata.md +docs/MicrosoftEntraProvider.md +docs/MicrosoftEntraProviderGroup.md +docs/MicrosoftEntraProviderGroupRequest.md +docs/MicrosoftEntraProviderMapping.md +docs/MicrosoftEntraProviderMappingRequest.md +docs/MicrosoftEntraProviderRequest.md +docs/MicrosoftEntraProviderUser.md +docs/MicrosoftEntraProviderUserRequest.md +docs/ModelEnum.md +docs/ModelRequest.md +docs/MutualTLSStage.md +docs/MutualTLSStageRequest.md +docs/NativeLogoutChallenge.md +docs/NativeLogoutChallengeResponseRequest.md +docs/Network.md +docs/NetworkBindingEnum.md +docs/NetworkInterface.md +docs/NetworkInterfaceRequest.md +docs/NetworkRequest.md +docs/NotConfiguredActionEnum.md +docs/Notification.md +docs/NotificationRequest.md +docs/NotificationRule.md +docs/NotificationRuleRequest.md +docs/NotificationTransport.md +docs/NotificationTransportRequest.md +docs/NotificationTransportTest.md +docs/NotificationWebhookMapping.md +docs/NotificationWebhookMappingRequest.md +docs/OAuth2Provider.md +docs/OAuth2ProviderLogoutMethodEnum.md +docs/OAuth2ProviderRequest.md +docs/OAuth2ProviderSetupURLs.md +docs/OAuthDeviceCodeChallenge.md +docs/OAuthDeviceCodeChallengeResponseRequest.md +docs/OAuthDeviceCodeFinishChallenge.md +docs/OAuthDeviceCodeFinishChallengeResponseRequest.md +docs/OAuthSource.md +docs/OAuthSourcePropertyMapping.md +docs/OAuthSourcePropertyMappingRequest.md +docs/OAuthSourceRequest.md +docs/Oauth2Api.md +docs/OpenIDConnectConfiguration.md +docs/OperatingSystem.md +docs/OperatingSystemRequest.md +docs/OutgoingSyncDeleteAction.md +docs/Outpost.md +docs/OutpostDefaultConfig.md +docs/OutpostHealth.md +docs/OutpostRequest.md +docs/OutpostTypeEnum.md +docs/OutpostsApi.md +docs/PKCEMethodEnum.md +docs/PaginatedAccountLockdownStageList.md +docs/PaginatedAgentConnectorList.md +docs/PaginatedAppleIndependentSecureEnclaveList.md +docs/PaginatedApplicationEntitlementList.md +docs/PaginatedApplicationList.md +docs/PaginatedAuthenticatedSessionList.md +docs/PaginatedAuthenticatorDuoStageList.md +docs/PaginatedAuthenticatorEmailStageList.md +docs/PaginatedAuthenticatorEndpointGDTCStageList.md +docs/PaginatedAuthenticatorSMSStageList.md +docs/PaginatedAuthenticatorStaticStageList.md +docs/PaginatedAuthenticatorTOTPStageList.md +docs/PaginatedAuthenticatorValidateStageList.md +docs/PaginatedAuthenticatorWebAuthnStageList.md +docs/PaginatedBlueprintInstanceList.md +docs/PaginatedBrandList.md +docs/PaginatedCaptchaStageList.md +docs/PaginatedCertificateKeyPairList.md +docs/PaginatedConnectionTokenList.md +docs/PaginatedConnectorList.md +docs/PaginatedConsentStageList.md +docs/PaginatedDataExportList.md +docs/PaginatedDenyStageList.md +docs/PaginatedDeviceAccessGroupList.md +docs/PaginatedDeviceUserBindingList.md +docs/PaginatedDockerServiceConnectionList.md +docs/PaginatedDomainList.md +docs/PaginatedDummyPolicyList.md +docs/PaginatedDummyStageList.md +docs/PaginatedDuoDeviceList.md +docs/PaginatedEmailDeviceList.md +docs/PaginatedEmailStageList.md +docs/PaginatedEndpointDeviceList.md +docs/PaginatedEndpointList.md +docs/PaginatedEndpointStageList.md +docs/PaginatedEnrollmentTokenList.md +docs/PaginatedEventList.md +docs/PaginatedEventMatcherPolicyList.md +docs/PaginatedExpiringBaseGrantModelList.md +docs/PaginatedExpressionPolicyList.md +docs/PaginatedExtraRoleObjectPermissionList.md +docs/PaginatedFleetConnectorList.md +docs/PaginatedFlowList.md +docs/PaginatedFlowStageBindingList.md +docs/PaginatedGeoIPPolicyList.md +docs/PaginatedGoogleChromeConnectorList.md +docs/PaginatedGoogleEndpointDeviceList.md +docs/PaginatedGoogleWorkspaceProviderGroupList.md +docs/PaginatedGoogleWorkspaceProviderList.md +docs/PaginatedGoogleWorkspaceProviderMappingList.md +docs/PaginatedGoogleWorkspaceProviderUserList.md +docs/PaginatedGroupKerberosSourceConnectionList.md +docs/PaginatedGroupLDAPSourceConnectionList.md +docs/PaginatedGroupList.md +docs/PaginatedGroupOAuthSourceConnectionList.md +docs/PaginatedGroupPlexSourceConnectionList.md +docs/PaginatedGroupSAMLSourceConnectionList.md +docs/PaginatedGroupSourceConnectionList.md +docs/PaginatedGroupTelegramSourceConnectionList.md +docs/PaginatedIdentificationStageList.md +docs/PaginatedInitialPermissionsList.md +docs/PaginatedInvitationList.md +docs/PaginatedInvitationStageList.md +docs/PaginatedKerberosSourceList.md +docs/PaginatedKerberosSourcePropertyMappingList.md +docs/PaginatedKubernetesServiceConnectionList.md +docs/PaginatedLDAPOutpostConfigList.md +docs/PaginatedLDAPProviderList.md +docs/PaginatedLDAPSourceList.md +docs/PaginatedLDAPSourcePropertyMappingList.md +docs/PaginatedLicenseList.md +docs/PaginatedLifecycleIterationList.md +docs/PaginatedLifecycleRuleList.md +docs/PaginatedMicrosoftEntraProviderGroupList.md +docs/PaginatedMicrosoftEntraProviderList.md +docs/PaginatedMicrosoftEntraProviderMappingList.md +docs/PaginatedMicrosoftEntraProviderUserList.md +docs/PaginatedMutualTLSStageList.md +docs/PaginatedNotificationList.md +docs/PaginatedNotificationRuleList.md +docs/PaginatedNotificationTransportList.md +docs/PaginatedNotificationWebhookMappingList.md +docs/PaginatedOAuth2ProviderList.md +docs/PaginatedOAuthSourceList.md +docs/PaginatedOAuthSourcePropertyMappingList.md +docs/PaginatedOutpostList.md +docs/PaginatedPasswordExpiryPolicyList.md +docs/PaginatedPasswordPolicyList.md +docs/PaginatedPasswordStageList.md +docs/PaginatedPermissionList.md +docs/PaginatedPlexSourceList.md +docs/PaginatedPlexSourcePropertyMappingList.md +docs/PaginatedPolicyBindingList.md +docs/PaginatedPolicyList.md +docs/PaginatedPromptList.md +docs/PaginatedPromptStageList.md +docs/PaginatedPropertyMappingList.md +docs/PaginatedProviderList.md +docs/PaginatedProxyOutpostConfigList.md +docs/PaginatedProxyProviderList.md +docs/PaginatedRACPropertyMappingList.md +docs/PaginatedRACProviderList.md +docs/PaginatedRadiusOutpostConfigList.md +docs/PaginatedRadiusProviderList.md +docs/PaginatedRadiusProviderPropertyMappingList.md +docs/PaginatedRedirectStageList.md +docs/PaginatedReputationList.md +docs/PaginatedReputationPolicyList.md +docs/PaginatedRoleAssignedObjectPermissionList.md +docs/PaginatedRoleList.md +docs/PaginatedSAMLPropertyMappingList.md +docs/PaginatedSAMLProviderList.md +docs/PaginatedSAMLSourceList.md +docs/PaginatedSAMLSourcePropertyMappingList.md +docs/PaginatedSCIMMappingList.md +docs/PaginatedSCIMProviderGroupList.md +docs/PaginatedSCIMProviderList.md +docs/PaginatedSCIMProviderUserList.md +docs/PaginatedSCIMSourceGroupList.md +docs/PaginatedSCIMSourceList.md +docs/PaginatedSCIMSourcePropertyMappingList.md +docs/PaginatedSCIMSourceUserList.md +docs/PaginatedSMSDeviceList.md +docs/PaginatedSSFProviderList.md +docs/PaginatedSSFStreamList.md +docs/PaginatedScheduleList.md +docs/PaginatedScopeMappingList.md +docs/PaginatedServiceConnectionList.md +docs/PaginatedSourceList.md +docs/PaginatedSourceStageList.md +docs/PaginatedStageList.md +docs/PaginatedStaticDeviceList.md +docs/PaginatedTOTPDeviceList.md +docs/PaginatedTaskList.md +docs/PaginatedTelegramSourceList.md +docs/PaginatedTelegramSourcePropertyMappingList.md +docs/PaginatedTenantList.md +docs/PaginatedTokenList.md +docs/PaginatedTokenModelList.md +docs/PaginatedUniquePasswordPolicyList.md +docs/PaginatedUserConsentList.md +docs/PaginatedUserDeleteStageList.md +docs/PaginatedUserKerberosSourceConnectionList.md +docs/PaginatedUserLDAPSourceConnectionList.md +docs/PaginatedUserList.md +docs/PaginatedUserLoginStageList.md +docs/PaginatedUserLogoutStageList.md +docs/PaginatedUserOAuthSourceConnectionList.md +docs/PaginatedUserPlexSourceConnectionList.md +docs/PaginatedUserSAMLSourceConnectionList.md +docs/PaginatedUserSourceConnectionList.md +docs/PaginatedUserTelegramSourceConnectionList.md +docs/PaginatedUserWriteStageList.md +docs/PaginatedWSFederationProviderList.md +docs/PaginatedWebAuthnDeviceList.md +docs/PaginatedWebAuthnDeviceTypeList.md +docs/Pagination.md +docs/PartialGroup.md +docs/PartialUser.md +docs/PasswordChallenge.md +docs/PasswordChallengeResponseRequest.md +docs/PasswordExpiryPolicy.md +docs/PasswordExpiryPolicyRequest.md +docs/PasswordPolicy.md +docs/PasswordPolicyRequest.md +docs/PasswordStage.md +docs/PasswordStageRequest.md +docs/PatchedAccountLockdownStageRequest.md +docs/PatchedAgentConnectorRequest.md +docs/PatchedAppleIndependentSecureEnclaveRequest.md +docs/PatchedApplicationEntitlementRequest.md +docs/PatchedApplicationRequest.md +docs/PatchedAuthenticatorDuoStageRequest.md +docs/PatchedAuthenticatorEmailStageRequest.md +docs/PatchedAuthenticatorEndpointGDTCStageRequest.md +docs/PatchedAuthenticatorSMSStageRequest.md +docs/PatchedAuthenticatorStaticStageRequest.md +docs/PatchedAuthenticatorTOTPStageRequest.md +docs/PatchedAuthenticatorValidateStageRequest.md +docs/PatchedAuthenticatorWebAuthnStageRequest.md +docs/PatchedBlueprintInstanceRequest.md +docs/PatchedBrandRequest.md +docs/PatchedCaptchaStageRequest.md +docs/PatchedCertificateKeyPairRequest.md +docs/PatchedConnectionTokenRequest.md +docs/PatchedConsentStageRequest.md +docs/PatchedDenyStageRequest.md +docs/PatchedDeviceAccessGroupRequest.md +docs/PatchedDeviceUserBindingRequest.md +docs/PatchedDockerServiceConnectionRequest.md +docs/PatchedDomainRequest.md +docs/PatchedDummyPolicyRequest.md +docs/PatchedDummyStageRequest.md +docs/PatchedDuoDeviceRequest.md +docs/PatchedEmailDeviceRequest.md +docs/PatchedEmailStageRequest.md +docs/PatchedEndpointDeviceRequest.md +docs/PatchedEndpointRequest.md +docs/PatchedEndpointStageRequest.md +docs/PatchedEnrollmentTokenRequest.md +docs/PatchedEventMatcherPolicyRequest.md +docs/PatchedEventRequest.md +docs/PatchedExpressionPolicyRequest.md +docs/PatchedFleetConnectorRequest.md +docs/PatchedFlowRequest.md +docs/PatchedFlowStageBindingRequest.md +docs/PatchedGeoIPPolicyRequest.md +docs/PatchedGoogleChromeConnectorRequest.md +docs/PatchedGoogleEndpointDeviceRequest.md +docs/PatchedGoogleWorkspaceProviderMappingRequest.md +docs/PatchedGoogleWorkspaceProviderRequest.md +docs/PatchedGroupKerberosSourceConnectionRequest.md +docs/PatchedGroupLDAPSourceConnectionRequest.md +docs/PatchedGroupOAuthSourceConnectionRequest.md +docs/PatchedGroupPlexSourceConnectionRequest.md +docs/PatchedGroupRequest.md +docs/PatchedGroupSAMLSourceConnectionRequest.md +docs/PatchedGroupSourceConnectionRequest.md +docs/PatchedGroupTelegramSourceConnectionRequest.md +docs/PatchedIdentificationStageRequest.md +docs/PatchedInitialPermissionsRequest.md +docs/PatchedInvitationRequest.md +docs/PatchedInvitationStageRequest.md +docs/PatchedKerberosSourcePropertyMappingRequest.md +docs/PatchedKerberosSourceRequest.md +docs/PatchedKubernetesServiceConnectionRequest.md +docs/PatchedLDAPProviderRequest.md +docs/PatchedLDAPSourcePropertyMappingRequest.md +docs/PatchedLDAPSourceRequest.md +docs/PatchedLicenseRequest.md +docs/PatchedLifecycleRuleRequest.md +docs/PatchedMicrosoftEntraProviderMappingRequest.md +docs/PatchedMicrosoftEntraProviderRequest.md +docs/PatchedMutualTLSStageRequest.md +docs/PatchedNotificationRequest.md +docs/PatchedNotificationRuleRequest.md +docs/PatchedNotificationTransportRequest.md +docs/PatchedNotificationWebhookMappingRequest.md +docs/PatchedOAuth2ProviderRequest.md +docs/PatchedOAuthSourcePropertyMappingRequest.md +docs/PatchedOAuthSourceRequest.md +docs/PatchedOutpostRequest.md +docs/PatchedPasswordExpiryPolicyRequest.md +docs/PatchedPasswordPolicyRequest.md +docs/PatchedPasswordStageRequest.md +docs/PatchedPermissionAssignRequest.md +docs/PatchedPlexSourcePropertyMappingRequest.md +docs/PatchedPlexSourceRequest.md +docs/PatchedPolicyBindingRequest.md +docs/PatchedPromptRequest.md +docs/PatchedPromptStageRequest.md +docs/PatchedProxyProviderRequest.md +docs/PatchedRACPropertyMappingRequest.md +docs/PatchedRACProviderRequest.md +docs/PatchedRadiusProviderPropertyMappingRequest.md +docs/PatchedRadiusProviderRequest.md +docs/PatchedRedirectStageRequest.md +docs/PatchedReputationPolicyRequest.md +docs/PatchedRoleRequest.md +docs/PatchedSAMLPropertyMappingRequest.md +docs/PatchedSAMLProviderRequest.md +docs/PatchedSAMLSourcePropertyMappingRequest.md +docs/PatchedSAMLSourceRequest.md +docs/PatchedSCIMMappingRequest.md +docs/PatchedSCIMProviderRequest.md +docs/PatchedSCIMSourceGroupRequest.md +docs/PatchedSCIMSourcePropertyMappingRequest.md +docs/PatchedSCIMSourceRequest.md +docs/PatchedSCIMSourceUserRequest.md +docs/PatchedSMSDeviceRequest.md +docs/PatchedSSFProviderRequest.md +docs/PatchedScheduleRequest.md +docs/PatchedScopeMappingRequest.md +docs/PatchedSettingsRequest.md +docs/PatchedSettingsRequestFlags.md +docs/PatchedSourceStageRequest.md +docs/PatchedStaticDeviceRequest.md +docs/PatchedTOTPDeviceRequest.md +docs/PatchedTelegramSourcePropertyMappingRequest.md +docs/PatchedTelegramSourceRequest.md +docs/PatchedTenantRequest.md +docs/PatchedTokenRequest.md +docs/PatchedUniquePasswordPolicyRequest.md +docs/PatchedUserDeleteStageRequest.md +docs/PatchedUserKerberosSourceConnectionRequest.md +docs/PatchedUserLDAPSourceConnectionRequest.md +docs/PatchedUserLoginStageRequest.md +docs/PatchedUserLogoutStageRequest.md +docs/PatchedUserOAuthSourceConnectionRequest.md +docs/PatchedUserPlexSourceConnectionRequest.md +docs/PatchedUserRequest.md +docs/PatchedUserSAMLSourceConnectionRequest.md +docs/PatchedUserSourceConnectionRequest.md +docs/PatchedUserTelegramSourceConnectionRequest.md +docs/PatchedUserWriteStageRequest.md +docs/PatchedWSFederationProviderRequest.md +docs/PatchedWebAuthnDeviceRequest.md +docs/Permission.md +docs/PermissionAssignRequest.md +docs/PermissionAssignResult.md +docs/PlexAuthenticationChallenge.md +docs/PlexAuthenticationChallengeResponseRequest.md +docs/PlexSource.md +docs/PlexSourcePropertyMapping.md +docs/PlexSourcePropertyMappingRequest.md +docs/PlexSourceRequest.md +docs/PlexTokenRedeemRequest.md +docs/PoliciesApi.md +docs/Policy.md +docs/PolicyBinding.md +docs/PolicyBindingRequest.md +docs/PolicyEngineMode.md +docs/PolicyTestRequest.md +docs/PolicyTestResult.md +docs/Process.md +docs/ProcessRequest.md +docs/Prompt.md +docs/PromptChallenge.md +docs/PromptChallengeResponseRequest.md +docs/PromptChoice.md +docs/PromptRequest.md +docs/PromptStage.md +docs/PromptStageRequest.md +docs/PromptTypeEnum.md +docs/PropertyMapping.md +docs/PropertyMappingPreview.md +docs/PropertyMappingTestRequest.md +docs/PropertyMappingTestResult.md +docs/PropertymappingsApi.md +docs/ProtocolEnum.md +docs/Provider.md +docs/ProviderEnum.md +docs/ProviderModelEnum.md +docs/ProviderTypeEnum.md +docs/ProvidersApi.md +docs/ProxyMode.md +docs/ProxyOutpostConfig.md +docs/ProxyProvider.md +docs/ProxyProviderRequest.md +docs/RACPropertyMapping.md +docs/RACPropertyMappingRequest.md +docs/RACProvider.md +docs/RACProviderRequest.md +docs/RacApi.md +docs/RadiusCheckAccess.md +docs/RadiusOutpostConfig.md +docs/RadiusProvider.md +docs/RadiusProviderPropertyMapping.md +docs/RadiusProviderPropertyMappingRequest.md +docs/RadiusProviderRequest.md +docs/RbacApi.md +docs/RedirectChallenge.md +docs/RedirectChallengeResponseRequest.md +docs/RedirectStage.md +docs/RedirectStageModeEnum.md +docs/RedirectStageRequest.md +docs/RedirectURI.md +docs/RedirectURIRequest.md +docs/RedirectURITypeEnum.md +docs/RelatedGroup.md +docs/RelatedRule.md +docs/ReportsApi.md +docs/Reputation.md +docs/ReputationPolicy.md +docs/ReputationPolicyRequest.md +docs/Review.md +docs/ReviewRequest.md +docs/ReviewerGroup.md +docs/ReviewerUser.md +docs/Role.md +docs/RoleAssignedObjectPermission.md +docs/RoleModelPermission.md +docs/RoleObjectPermission.md +docs/RoleRequest.md +docs/RootApi.md +docs/SAMLBindingsEnum.md +docs/SAMLLogoutMethods.md +docs/SAMLMetadata.md +docs/SAMLNameIDPolicyEnum.md +docs/SAMLPropertyMapping.md +docs/SAMLPropertyMappingRequest.md +docs/SAMLProvider.md +docs/SAMLProviderRequest.md +docs/SAMLSource.md +docs/SAMLSourcePropertyMapping.md +docs/SAMLSourcePropertyMappingRequest.md +docs/SAMLSourceRequest.md +docs/SCIMAuthenticationModeEnum.md +docs/SCIMMapping.md +docs/SCIMMappingRequest.md +docs/SCIMProvider.md +docs/SCIMProviderGroup.md +docs/SCIMProviderGroupRequest.md +docs/SCIMProviderRequest.md +docs/SCIMProviderUser.md +docs/SCIMProviderUserRequest.md +docs/SCIMSource.md +docs/SCIMSourceGroup.md +docs/SCIMSourceGroupRequest.md +docs/SCIMSourcePropertyMapping.md +docs/SCIMSourcePropertyMappingRequest.md +docs/SCIMSourceRequest.md +docs/SCIMSourceUser.md +docs/SCIMSourceUserRequest.md +docs/SMSDevice.md +docs/SMSDeviceRequest.md +docs/SSFProvider.md +docs/SSFProviderRequest.md +docs/SSFStream.md +docs/SSFStreamStatusEnum.md +docs/Schedule.md +docs/ScheduleRequest.md +docs/SchemaApi.md +docs/ScopeMapping.md +docs/ScopeMappingRequest.md +docs/SelectableStage.md +docs/ServiceConnection.md +docs/ServiceConnectionState.md +docs/SessionEndChallenge.md +docs/SessionUser.md +docs/Settings.md +docs/SettingsRequest.md +docs/SeverityEnum.md +docs/ShellChallenge.md +docs/SignatureAlgorithmEnum.md +docs/Software.md +docs/SoftwareRequest.md +docs/Source.md +docs/SourceStage.md +docs/SourceStageRequest.md +docs/SourceType.md +docs/SourcesApi.md +docs/SsfApi.md +docs/Stage.md +docs/StageModeEnum.md +docs/StagePrompt.md +docs/StagesApi.md +docs/StaticDevice.md +docs/StaticDeviceRequest.md +docs/StaticDeviceToken.md +docs/SubModeEnum.md +docs/SyncObjectModelEnum.md +docs/SyncObjectRequest.md +docs/SyncObjectResult.md +docs/SyncOutgoingTriggerModeEnum.md +docs/SyncStatus.md +docs/SystemInfo.md +docs/SystemInfoRuntime.md +docs/TOTPDevice.md +docs/TOTPDeviceRequest.md +docs/Task.md +docs/TaskAggregatedStatusEnum.md +docs/TaskStatusEnum.md +docs/TasksApi.md +docs/TelegramAuthRequest.md +docs/TelegramChallengeResponseRequest.md +docs/TelegramLoginChallenge.md +docs/TelegramSource.md +docs/TelegramSourcePropertyMapping.md +docs/TelegramSourcePropertyMappingRequest.md +docs/TelegramSourceRequest.md +docs/Tenant.md +docs/TenantAdminGroupRequestRequest.md +docs/TenantRecoveryKeyRequestRequest.md +docs/TenantRecoveryKeyResponse.md +docs/TenantRequest.md +docs/TenantsApi.md +docs/ThemedUrls.md +docs/Token.md +docs/TokenModel.md +docs/TokenRequest.md +docs/TokenSetKeyRequest.md +docs/TokenView.md +docs/TransactionApplicationRequest.md +docs/TransactionApplicationResponse.md +docs/TransactionPolicyBindingRequest.md +docs/TransportModeEnum.md +docs/TypeCreate.md +docs/UiThemeEnum.md +docs/UniquePasswordPolicy.md +docs/UniquePasswordPolicyRequest.md +docs/UsageEnum.md +docs/UsedBy.md +docs/UsedByActionEnum.md +docs/User.md +docs/UserAccountLockdownRequest.md +docs/UserAccountRequest.md +docs/UserAccountSerializerForRoleRequest.md +docs/UserAttributeEnum.md +docs/UserConsent.md +docs/UserCreationModeEnum.md +docs/UserDeleteStage.md +docs/UserDeleteStageRequest.md +docs/UserFieldsEnum.md +docs/UserKerberosSourceConnection.md +docs/UserKerberosSourceConnectionRequest.md +docs/UserLDAPSourceConnection.md +docs/UserLDAPSourceConnectionRequest.md +docs/UserLoginChallenge.md +docs/UserLoginChallengeResponseRequest.md +docs/UserLoginStage.md +docs/UserLoginStageRequest.md +docs/UserLogoutStage.md +docs/UserLogoutStageRequest.md +docs/UserMatchingModeEnum.md +docs/UserOAuthSourceConnection.md +docs/UserOAuthSourceConnectionRequest.md +docs/UserPasswordHashSetRequest.md +docs/UserPasswordSetRequest.md +docs/UserPath.md +docs/UserPlexSourceConnection.md +docs/UserPlexSourceConnectionRequest.md +docs/UserRecoveryEmailRequest.md +docs/UserRecoveryLinkRequest.md +docs/UserRequest.md +docs/UserSAMLSourceConnection.md +docs/UserSAMLSourceConnectionRequest.md +docs/UserSelf.md +docs/UserSelfGroups.md +docs/UserSelfRoles.md +docs/UserServiceAccountRequest.md +docs/UserServiceAccountResponse.md +docs/UserSetting.md +docs/UserSourceConnection.md +docs/UserSourceConnectionRequest.md +docs/UserTelegramSourceConnection.md +docs/UserTelegramSourceConnectionRequest.md +docs/UserTypeEnum.md +docs/UserVerificationEnum.md +docs/UserWriteStage.md +docs/UserWriteStageRequest.md +docs/ValidationError.md +docs/VendorEnum.md +docs/Version.md +docs/VersionHistory.md +docs/WSFederationProvider.md +docs/WSFederationProviderRequest.md +docs/WebAuthnDevice.md +docs/WebAuthnDeviceRequest.md +docs/WebAuthnDeviceType.md +docs/WebAuthnHintEnum.md +docs/Worker.md +git_push.sh +pyproject.toml +requirements.txt +setup.cfg +setup.py +test-requirements.txt +test/__init__.py +tox.ini diff --git a/.openapi-generator/VERSION b/.openapi-generator/VERSION new file mode 100644 index 000000000..696eaac5c --- /dev/null +++ b/.openapi-generator/VERSION @@ -0,0 +1 @@ +7.22.0 diff --git a/README.md b/README.md index 75f480d80..a801423ba 100644 --- a/README.md +++ b/README.md @@ -11,4 +11,2153 @@ This repo contains a generated API client to talk with authentik's API from Python. -Checkout a specific tag corresponding to the authentik version you want to use this API client with to see both the code and documentation. +## Overview + +This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project: + +- API version: 2026.5.7 +- Package version: 2026.5.7 +- Generator version: 7.22.0 +- Build package: org.openapitools.codegen.languages.PythonClientCodegen + +## Requirements. + +Python 3.10+ + +## Installation & Usage +### pip install + +If the python package is hosted on a repository, you can install directly using: + +```sh +pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git +``` +(you may need to run `pip` with root permission: `sudo pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git`) + +Then import the package: +```python +import authentik_client +``` + +### Setuptools + +Install via [Setuptools](http://pypi.python.org/pypi/setuptools). + +```sh +python setup.py install --user +``` +(or `sudo python setup.py install` to install the package for all users) + +Then import the package: +```python +import authentik_client +``` + +### Tests + +Execute `pytest` to run the tests. + +## Getting Started + +Please follow the [installation procedure](#installation--usage) and then run the following: + +```python + +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + + try: + api_response = api_instance.admin_apps_list() + print("The response of AdminApi->admin_apps_list:\n") + pprint(api_response) + except ApiException as e: + print("Exception when calling AdminApi->admin_apps_list: %s\n" % e) + +``` + +## Documentation for API Endpoints + +All URIs are relative to */api/v3* + +Class | Method | HTTP request | Description +------------ | ------------- | ------------- | ------------- +*AdminApi* | [**admin_apps_list**](docs/AdminApi.md#admin_apps_list) | **GET** /admin/apps/ | +*AdminApi* | [**admin_file_create**](docs/AdminApi.md#admin_file_create) | **POST** /admin/file/ | +*AdminApi* | [**admin_file_destroy**](docs/AdminApi.md#admin_file_destroy) | **DELETE** /admin/file/ | +*AdminApi* | [**admin_file_list**](docs/AdminApi.md#admin_file_list) | **GET** /admin/file/ | +*AdminApi* | [**admin_file_used_by_list**](docs/AdminApi.md#admin_file_used_by_list) | **GET** /admin/file/used_by/ | +*AdminApi* | [**admin_models_list**](docs/AdminApi.md#admin_models_list) | **GET** /admin/models/ | +*AdminApi* | [**admin_settings_partial_update**](docs/AdminApi.md#admin_settings_partial_update) | **PATCH** /admin/settings/ | +*AdminApi* | [**admin_settings_retrieve**](docs/AdminApi.md#admin_settings_retrieve) | **GET** /admin/settings/ | +*AdminApi* | [**admin_settings_update**](docs/AdminApi.md#admin_settings_update) | **PUT** /admin/settings/ | +*AdminApi* | [**admin_system_create**](docs/AdminApi.md#admin_system_create) | **POST** /admin/system/ | +*AdminApi* | [**admin_system_retrieve**](docs/AdminApi.md#admin_system_retrieve) | **GET** /admin/system/ | +*AdminApi* | [**admin_version_history_list**](docs/AdminApi.md#admin_version_history_list) | **GET** /admin/version/history/ | +*AdminApi* | [**admin_version_history_retrieve**](docs/AdminApi.md#admin_version_history_retrieve) | **GET** /admin/version/history/{id}/ | +*AdminApi* | [**admin_version_retrieve**](docs/AdminApi.md#admin_version_retrieve) | **GET** /admin/version/ | +*AuthenticatorsApi* | [**authenticators_admin_all_list**](docs/AuthenticatorsApi.md#authenticators_admin_all_list) | **GET** /authenticators/admin/all/ | +*AuthenticatorsApi* | [**authenticators_admin_duo_create**](docs/AuthenticatorsApi.md#authenticators_admin_duo_create) | **POST** /authenticators/admin/duo/ | +*AuthenticatorsApi* | [**authenticators_admin_duo_destroy**](docs/AuthenticatorsApi.md#authenticators_admin_duo_destroy) | **DELETE** /authenticators/admin/duo/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_duo_list**](docs/AuthenticatorsApi.md#authenticators_admin_duo_list) | **GET** /authenticators/admin/duo/ | +*AuthenticatorsApi* | [**authenticators_admin_duo_partial_update**](docs/AuthenticatorsApi.md#authenticators_admin_duo_partial_update) | **PATCH** /authenticators/admin/duo/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_duo_retrieve**](docs/AuthenticatorsApi.md#authenticators_admin_duo_retrieve) | **GET** /authenticators/admin/duo/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_duo_update**](docs/AuthenticatorsApi.md#authenticators_admin_duo_update) | **PUT** /authenticators/admin/duo/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_email_create**](docs/AuthenticatorsApi.md#authenticators_admin_email_create) | **POST** /authenticators/admin/email/ | +*AuthenticatorsApi* | [**authenticators_admin_email_destroy**](docs/AuthenticatorsApi.md#authenticators_admin_email_destroy) | **DELETE** /authenticators/admin/email/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_email_list**](docs/AuthenticatorsApi.md#authenticators_admin_email_list) | **GET** /authenticators/admin/email/ | +*AuthenticatorsApi* | [**authenticators_admin_email_partial_update**](docs/AuthenticatorsApi.md#authenticators_admin_email_partial_update) | **PATCH** /authenticators/admin/email/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_email_retrieve**](docs/AuthenticatorsApi.md#authenticators_admin_email_retrieve) | **GET** /authenticators/admin/email/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_email_update**](docs/AuthenticatorsApi.md#authenticators_admin_email_update) | **PUT** /authenticators/admin/email/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_endpoint_create**](docs/AuthenticatorsApi.md#authenticators_admin_endpoint_create) | **POST** /authenticators/admin/endpoint/ | +*AuthenticatorsApi* | [**authenticators_admin_endpoint_destroy**](docs/AuthenticatorsApi.md#authenticators_admin_endpoint_destroy) | **DELETE** /authenticators/admin/endpoint/{uuid}/ | +*AuthenticatorsApi* | [**authenticators_admin_endpoint_list**](docs/AuthenticatorsApi.md#authenticators_admin_endpoint_list) | **GET** /authenticators/admin/endpoint/ | +*AuthenticatorsApi* | [**authenticators_admin_endpoint_partial_update**](docs/AuthenticatorsApi.md#authenticators_admin_endpoint_partial_update) | **PATCH** /authenticators/admin/endpoint/{uuid}/ | +*AuthenticatorsApi* | [**authenticators_admin_endpoint_retrieve**](docs/AuthenticatorsApi.md#authenticators_admin_endpoint_retrieve) | **GET** /authenticators/admin/endpoint/{uuid}/ | +*AuthenticatorsApi* | [**authenticators_admin_endpoint_update**](docs/AuthenticatorsApi.md#authenticators_admin_endpoint_update) | **PUT** /authenticators/admin/endpoint/{uuid}/ | +*AuthenticatorsApi* | [**authenticators_admin_sms_create**](docs/AuthenticatorsApi.md#authenticators_admin_sms_create) | **POST** /authenticators/admin/sms/ | +*AuthenticatorsApi* | [**authenticators_admin_sms_destroy**](docs/AuthenticatorsApi.md#authenticators_admin_sms_destroy) | **DELETE** /authenticators/admin/sms/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_sms_list**](docs/AuthenticatorsApi.md#authenticators_admin_sms_list) | **GET** /authenticators/admin/sms/ | +*AuthenticatorsApi* | [**authenticators_admin_sms_partial_update**](docs/AuthenticatorsApi.md#authenticators_admin_sms_partial_update) | **PATCH** /authenticators/admin/sms/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_sms_retrieve**](docs/AuthenticatorsApi.md#authenticators_admin_sms_retrieve) | **GET** /authenticators/admin/sms/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_sms_update**](docs/AuthenticatorsApi.md#authenticators_admin_sms_update) | **PUT** /authenticators/admin/sms/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_static_create**](docs/AuthenticatorsApi.md#authenticators_admin_static_create) | **POST** /authenticators/admin/static/ | +*AuthenticatorsApi* | [**authenticators_admin_static_destroy**](docs/AuthenticatorsApi.md#authenticators_admin_static_destroy) | **DELETE** /authenticators/admin/static/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_static_list**](docs/AuthenticatorsApi.md#authenticators_admin_static_list) | **GET** /authenticators/admin/static/ | +*AuthenticatorsApi* | [**authenticators_admin_static_partial_update**](docs/AuthenticatorsApi.md#authenticators_admin_static_partial_update) | **PATCH** /authenticators/admin/static/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_static_retrieve**](docs/AuthenticatorsApi.md#authenticators_admin_static_retrieve) | **GET** /authenticators/admin/static/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_static_update**](docs/AuthenticatorsApi.md#authenticators_admin_static_update) | **PUT** /authenticators/admin/static/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_totp_create**](docs/AuthenticatorsApi.md#authenticators_admin_totp_create) | **POST** /authenticators/admin/totp/ | +*AuthenticatorsApi* | [**authenticators_admin_totp_destroy**](docs/AuthenticatorsApi.md#authenticators_admin_totp_destroy) | **DELETE** /authenticators/admin/totp/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_totp_list**](docs/AuthenticatorsApi.md#authenticators_admin_totp_list) | **GET** /authenticators/admin/totp/ | +*AuthenticatorsApi* | [**authenticators_admin_totp_partial_update**](docs/AuthenticatorsApi.md#authenticators_admin_totp_partial_update) | **PATCH** /authenticators/admin/totp/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_totp_retrieve**](docs/AuthenticatorsApi.md#authenticators_admin_totp_retrieve) | **GET** /authenticators/admin/totp/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_totp_update**](docs/AuthenticatorsApi.md#authenticators_admin_totp_update) | **PUT** /authenticators/admin/totp/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_webauthn_create**](docs/AuthenticatorsApi.md#authenticators_admin_webauthn_create) | **POST** /authenticators/admin/webauthn/ | +*AuthenticatorsApi* | [**authenticators_admin_webauthn_destroy**](docs/AuthenticatorsApi.md#authenticators_admin_webauthn_destroy) | **DELETE** /authenticators/admin/webauthn/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_webauthn_list**](docs/AuthenticatorsApi.md#authenticators_admin_webauthn_list) | **GET** /authenticators/admin/webauthn/ | +*AuthenticatorsApi* | [**authenticators_admin_webauthn_partial_update**](docs/AuthenticatorsApi.md#authenticators_admin_webauthn_partial_update) | **PATCH** /authenticators/admin/webauthn/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_webauthn_retrieve**](docs/AuthenticatorsApi.md#authenticators_admin_webauthn_retrieve) | **GET** /authenticators/admin/webauthn/{id}/ | +*AuthenticatorsApi* | [**authenticators_admin_webauthn_update**](docs/AuthenticatorsApi.md#authenticators_admin_webauthn_update) | **PUT** /authenticators/admin/webauthn/{id}/ | +*AuthenticatorsApi* | [**authenticators_all_list**](docs/AuthenticatorsApi.md#authenticators_all_list) | **GET** /authenticators/all/ | +*AuthenticatorsApi* | [**authenticators_duo_destroy**](docs/AuthenticatorsApi.md#authenticators_duo_destroy) | **DELETE** /authenticators/duo/{id}/ | +*AuthenticatorsApi* | [**authenticators_duo_list**](docs/AuthenticatorsApi.md#authenticators_duo_list) | **GET** /authenticators/duo/ | +*AuthenticatorsApi* | [**authenticators_duo_partial_update**](docs/AuthenticatorsApi.md#authenticators_duo_partial_update) | **PATCH** /authenticators/duo/{id}/ | +*AuthenticatorsApi* | [**authenticators_duo_retrieve**](docs/AuthenticatorsApi.md#authenticators_duo_retrieve) | **GET** /authenticators/duo/{id}/ | +*AuthenticatorsApi* | [**authenticators_duo_update**](docs/AuthenticatorsApi.md#authenticators_duo_update) | **PUT** /authenticators/duo/{id}/ | +*AuthenticatorsApi* | [**authenticators_duo_used_by_list**](docs/AuthenticatorsApi.md#authenticators_duo_used_by_list) | **GET** /authenticators/duo/{id}/used_by/ | +*AuthenticatorsApi* | [**authenticators_email_destroy**](docs/AuthenticatorsApi.md#authenticators_email_destroy) | **DELETE** /authenticators/email/{id}/ | +*AuthenticatorsApi* | [**authenticators_email_list**](docs/AuthenticatorsApi.md#authenticators_email_list) | **GET** /authenticators/email/ | +*AuthenticatorsApi* | [**authenticators_email_partial_update**](docs/AuthenticatorsApi.md#authenticators_email_partial_update) | **PATCH** /authenticators/email/{id}/ | +*AuthenticatorsApi* | [**authenticators_email_retrieve**](docs/AuthenticatorsApi.md#authenticators_email_retrieve) | **GET** /authenticators/email/{id}/ | +*AuthenticatorsApi* | [**authenticators_email_update**](docs/AuthenticatorsApi.md#authenticators_email_update) | **PUT** /authenticators/email/{id}/ | +*AuthenticatorsApi* | [**authenticators_email_used_by_list**](docs/AuthenticatorsApi.md#authenticators_email_used_by_list) | **GET** /authenticators/email/{id}/used_by/ | +*AuthenticatorsApi* | [**authenticators_endpoint_list**](docs/AuthenticatorsApi.md#authenticators_endpoint_list) | **GET** /authenticators/endpoint/ | +*AuthenticatorsApi* | [**authenticators_endpoint_retrieve**](docs/AuthenticatorsApi.md#authenticators_endpoint_retrieve) | **GET** /authenticators/endpoint/{uuid}/ | +*AuthenticatorsApi* | [**authenticators_endpoint_used_by_list**](docs/AuthenticatorsApi.md#authenticators_endpoint_used_by_list) | **GET** /authenticators/endpoint/{uuid}/used_by/ | +*AuthenticatorsApi* | [**authenticators_sms_destroy**](docs/AuthenticatorsApi.md#authenticators_sms_destroy) | **DELETE** /authenticators/sms/{id}/ | +*AuthenticatorsApi* | [**authenticators_sms_list**](docs/AuthenticatorsApi.md#authenticators_sms_list) | **GET** /authenticators/sms/ | +*AuthenticatorsApi* | [**authenticators_sms_partial_update**](docs/AuthenticatorsApi.md#authenticators_sms_partial_update) | **PATCH** /authenticators/sms/{id}/ | +*AuthenticatorsApi* | [**authenticators_sms_retrieve**](docs/AuthenticatorsApi.md#authenticators_sms_retrieve) | **GET** /authenticators/sms/{id}/ | +*AuthenticatorsApi* | [**authenticators_sms_update**](docs/AuthenticatorsApi.md#authenticators_sms_update) | **PUT** /authenticators/sms/{id}/ | +*AuthenticatorsApi* | [**authenticators_sms_used_by_list**](docs/AuthenticatorsApi.md#authenticators_sms_used_by_list) | **GET** /authenticators/sms/{id}/used_by/ | +*AuthenticatorsApi* | [**authenticators_static_destroy**](docs/AuthenticatorsApi.md#authenticators_static_destroy) | **DELETE** /authenticators/static/{id}/ | +*AuthenticatorsApi* | [**authenticators_static_list**](docs/AuthenticatorsApi.md#authenticators_static_list) | **GET** /authenticators/static/ | +*AuthenticatorsApi* | [**authenticators_static_partial_update**](docs/AuthenticatorsApi.md#authenticators_static_partial_update) | **PATCH** /authenticators/static/{id}/ | +*AuthenticatorsApi* | [**authenticators_static_retrieve**](docs/AuthenticatorsApi.md#authenticators_static_retrieve) | **GET** /authenticators/static/{id}/ | +*AuthenticatorsApi* | [**authenticators_static_update**](docs/AuthenticatorsApi.md#authenticators_static_update) | **PUT** /authenticators/static/{id}/ | +*AuthenticatorsApi* | [**authenticators_static_used_by_list**](docs/AuthenticatorsApi.md#authenticators_static_used_by_list) | **GET** /authenticators/static/{id}/used_by/ | +*AuthenticatorsApi* | [**authenticators_totp_destroy**](docs/AuthenticatorsApi.md#authenticators_totp_destroy) | **DELETE** /authenticators/totp/{id}/ | +*AuthenticatorsApi* | [**authenticators_totp_list**](docs/AuthenticatorsApi.md#authenticators_totp_list) | **GET** /authenticators/totp/ | +*AuthenticatorsApi* | [**authenticators_totp_partial_update**](docs/AuthenticatorsApi.md#authenticators_totp_partial_update) | **PATCH** /authenticators/totp/{id}/ | +*AuthenticatorsApi* | [**authenticators_totp_retrieve**](docs/AuthenticatorsApi.md#authenticators_totp_retrieve) | **GET** /authenticators/totp/{id}/ | +*AuthenticatorsApi* | [**authenticators_totp_update**](docs/AuthenticatorsApi.md#authenticators_totp_update) | **PUT** /authenticators/totp/{id}/ | +*AuthenticatorsApi* | [**authenticators_totp_used_by_list**](docs/AuthenticatorsApi.md#authenticators_totp_used_by_list) | **GET** /authenticators/totp/{id}/used_by/ | +*AuthenticatorsApi* | [**authenticators_webauthn_destroy**](docs/AuthenticatorsApi.md#authenticators_webauthn_destroy) | **DELETE** /authenticators/webauthn/{id}/ | +*AuthenticatorsApi* | [**authenticators_webauthn_list**](docs/AuthenticatorsApi.md#authenticators_webauthn_list) | **GET** /authenticators/webauthn/ | +*AuthenticatorsApi* | [**authenticators_webauthn_partial_update**](docs/AuthenticatorsApi.md#authenticators_webauthn_partial_update) | **PATCH** /authenticators/webauthn/{id}/ | +*AuthenticatorsApi* | [**authenticators_webauthn_retrieve**](docs/AuthenticatorsApi.md#authenticators_webauthn_retrieve) | **GET** /authenticators/webauthn/{id}/ | +*AuthenticatorsApi* | [**authenticators_webauthn_update**](docs/AuthenticatorsApi.md#authenticators_webauthn_update) | **PUT** /authenticators/webauthn/{id}/ | +*AuthenticatorsApi* | [**authenticators_webauthn_used_by_list**](docs/AuthenticatorsApi.md#authenticators_webauthn_used_by_list) | **GET** /authenticators/webauthn/{id}/used_by/ | +*CoreApi* | [**core_application_entitlements_create**](docs/CoreApi.md#core_application_entitlements_create) | **POST** /core/application_entitlements/ | +*CoreApi* | [**core_application_entitlements_destroy**](docs/CoreApi.md#core_application_entitlements_destroy) | **DELETE** /core/application_entitlements/{pbm_uuid}/ | +*CoreApi* | [**core_application_entitlements_list**](docs/CoreApi.md#core_application_entitlements_list) | **GET** /core/application_entitlements/ | +*CoreApi* | [**core_application_entitlements_partial_update**](docs/CoreApi.md#core_application_entitlements_partial_update) | **PATCH** /core/application_entitlements/{pbm_uuid}/ | +*CoreApi* | [**core_application_entitlements_retrieve**](docs/CoreApi.md#core_application_entitlements_retrieve) | **GET** /core/application_entitlements/{pbm_uuid}/ | +*CoreApi* | [**core_application_entitlements_update**](docs/CoreApi.md#core_application_entitlements_update) | **PUT** /core/application_entitlements/{pbm_uuid}/ | +*CoreApi* | [**core_application_entitlements_used_by_list**](docs/CoreApi.md#core_application_entitlements_used_by_list) | **GET** /core/application_entitlements/{pbm_uuid}/used_by/ | +*CoreApi* | [**core_applications_check_access_retrieve**](docs/CoreApi.md#core_applications_check_access_retrieve) | **GET** /core/applications/{slug}/check_access/ | +*CoreApi* | [**core_applications_create**](docs/CoreApi.md#core_applications_create) | **POST** /core/applications/ | +*CoreApi* | [**core_applications_destroy**](docs/CoreApi.md#core_applications_destroy) | **DELETE** /core/applications/{slug}/ | +*CoreApi* | [**core_applications_list**](docs/CoreApi.md#core_applications_list) | **GET** /core/applications/ | +*CoreApi* | [**core_applications_partial_update**](docs/CoreApi.md#core_applications_partial_update) | **PATCH** /core/applications/{slug}/ | +*CoreApi* | [**core_applications_retrieve**](docs/CoreApi.md#core_applications_retrieve) | **GET** /core/applications/{slug}/ | +*CoreApi* | [**core_applications_update**](docs/CoreApi.md#core_applications_update) | **PUT** /core/applications/{slug}/ | +*CoreApi* | [**core_applications_used_by_list**](docs/CoreApi.md#core_applications_used_by_list) | **GET** /core/applications/{slug}/used_by/ | +*CoreApi* | [**core_authenticated_sessions_bulk_delete_destroy**](docs/CoreApi.md#core_authenticated_sessions_bulk_delete_destroy) | **DELETE** /core/authenticated_sessions/bulk_delete/ | +*CoreApi* | [**core_authenticated_sessions_destroy**](docs/CoreApi.md#core_authenticated_sessions_destroy) | **DELETE** /core/authenticated_sessions/{uuid}/ | +*CoreApi* | [**core_authenticated_sessions_list**](docs/CoreApi.md#core_authenticated_sessions_list) | **GET** /core/authenticated_sessions/ | +*CoreApi* | [**core_authenticated_sessions_retrieve**](docs/CoreApi.md#core_authenticated_sessions_retrieve) | **GET** /core/authenticated_sessions/{uuid}/ | +*CoreApi* | [**core_authenticated_sessions_used_by_list**](docs/CoreApi.md#core_authenticated_sessions_used_by_list) | **GET** /core/authenticated_sessions/{uuid}/used_by/ | +*CoreApi* | [**core_brands_create**](docs/CoreApi.md#core_brands_create) | **POST** /core/brands/ | +*CoreApi* | [**core_brands_current_retrieve**](docs/CoreApi.md#core_brands_current_retrieve) | **GET** /core/brands/current/ | +*CoreApi* | [**core_brands_destroy**](docs/CoreApi.md#core_brands_destroy) | **DELETE** /core/brands/{brand_uuid}/ | +*CoreApi* | [**core_brands_list**](docs/CoreApi.md#core_brands_list) | **GET** /core/brands/ | +*CoreApi* | [**core_brands_partial_update**](docs/CoreApi.md#core_brands_partial_update) | **PATCH** /core/brands/{brand_uuid}/ | +*CoreApi* | [**core_brands_retrieve**](docs/CoreApi.md#core_brands_retrieve) | **GET** /core/brands/{brand_uuid}/ | +*CoreApi* | [**core_brands_update**](docs/CoreApi.md#core_brands_update) | **PUT** /core/brands/{brand_uuid}/ | +*CoreApi* | [**core_brands_used_by_list**](docs/CoreApi.md#core_brands_used_by_list) | **GET** /core/brands/{brand_uuid}/used_by/ | +*CoreApi* | [**core_groups_add_user_create**](docs/CoreApi.md#core_groups_add_user_create) | **POST** /core/groups/{group_uuid}/add_user/ | +*CoreApi* | [**core_groups_create**](docs/CoreApi.md#core_groups_create) | **POST** /core/groups/ | +*CoreApi* | [**core_groups_destroy**](docs/CoreApi.md#core_groups_destroy) | **DELETE** /core/groups/{group_uuid}/ | +*CoreApi* | [**core_groups_list**](docs/CoreApi.md#core_groups_list) | **GET** /core/groups/ | +*CoreApi* | [**core_groups_partial_update**](docs/CoreApi.md#core_groups_partial_update) | **PATCH** /core/groups/{group_uuid}/ | +*CoreApi* | [**core_groups_remove_user_create**](docs/CoreApi.md#core_groups_remove_user_create) | **POST** /core/groups/{group_uuid}/remove_user/ | +*CoreApi* | [**core_groups_retrieve**](docs/CoreApi.md#core_groups_retrieve) | **GET** /core/groups/{group_uuid}/ | +*CoreApi* | [**core_groups_update**](docs/CoreApi.md#core_groups_update) | **PUT** /core/groups/{group_uuid}/ | +*CoreApi* | [**core_groups_used_by_list**](docs/CoreApi.md#core_groups_used_by_list) | **GET** /core/groups/{group_uuid}/used_by/ | +*CoreApi* | [**core_tokens_create**](docs/CoreApi.md#core_tokens_create) | **POST** /core/tokens/ | +*CoreApi* | [**core_tokens_destroy**](docs/CoreApi.md#core_tokens_destroy) | **DELETE** /core/tokens/{identifier}/ | +*CoreApi* | [**core_tokens_list**](docs/CoreApi.md#core_tokens_list) | **GET** /core/tokens/ | +*CoreApi* | [**core_tokens_partial_update**](docs/CoreApi.md#core_tokens_partial_update) | **PATCH** /core/tokens/{identifier}/ | +*CoreApi* | [**core_tokens_retrieve**](docs/CoreApi.md#core_tokens_retrieve) | **GET** /core/tokens/{identifier}/ | +*CoreApi* | [**core_tokens_set_key_create**](docs/CoreApi.md#core_tokens_set_key_create) | **POST** /core/tokens/{identifier}/set_key/ | +*CoreApi* | [**core_tokens_update**](docs/CoreApi.md#core_tokens_update) | **PUT** /core/tokens/{identifier}/ | +*CoreApi* | [**core_tokens_used_by_list**](docs/CoreApi.md#core_tokens_used_by_list) | **GET** /core/tokens/{identifier}/used_by/ | +*CoreApi* | [**core_tokens_view_key_retrieve**](docs/CoreApi.md#core_tokens_view_key_retrieve) | **GET** /core/tokens/{identifier}/view_key/ | +*CoreApi* | [**core_transactional_applications_update**](docs/CoreApi.md#core_transactional_applications_update) | **PUT** /core/transactional/applications/ | +*CoreApi* | [**core_user_consent_destroy**](docs/CoreApi.md#core_user_consent_destroy) | **DELETE** /core/user_consent/{id}/ | +*CoreApi* | [**core_user_consent_list**](docs/CoreApi.md#core_user_consent_list) | **GET** /core/user_consent/ | +*CoreApi* | [**core_user_consent_retrieve**](docs/CoreApi.md#core_user_consent_retrieve) | **GET** /core/user_consent/{id}/ | +*CoreApi* | [**core_user_consent_used_by_list**](docs/CoreApi.md#core_user_consent_used_by_list) | **GET** /core/user_consent/{id}/used_by/ | +*CoreApi* | [**core_users_account_lockdown_create**](docs/CoreApi.md#core_users_account_lockdown_create) | **POST** /core/users/account_lockdown/ | +*CoreApi* | [**core_users_create**](docs/CoreApi.md#core_users_create) | **POST** /core/users/ | +*CoreApi* | [**core_users_destroy**](docs/CoreApi.md#core_users_destroy) | **DELETE** /core/users/{id}/ | +*CoreApi* | [**core_users_export_create**](docs/CoreApi.md#core_users_export_create) | **POST** /core/users/export/ | +*CoreApi* | [**core_users_impersonate_create**](docs/CoreApi.md#core_users_impersonate_create) | **POST** /core/users/{id}/impersonate/ | +*CoreApi* | [**core_users_impersonate_end_retrieve**](docs/CoreApi.md#core_users_impersonate_end_retrieve) | **GET** /core/users/impersonate_end/ | +*CoreApi* | [**core_users_list**](docs/CoreApi.md#core_users_list) | **GET** /core/users/ | +*CoreApi* | [**core_users_me_retrieve**](docs/CoreApi.md#core_users_me_retrieve) | **GET** /core/users/me/ | +*CoreApi* | [**core_users_partial_update**](docs/CoreApi.md#core_users_partial_update) | **PATCH** /core/users/{id}/ | +*CoreApi* | [**core_users_paths_retrieve**](docs/CoreApi.md#core_users_paths_retrieve) | **GET** /core/users/paths/ | +*CoreApi* | [**core_users_recovery_create**](docs/CoreApi.md#core_users_recovery_create) | **POST** /core/users/{id}/recovery/ | +*CoreApi* | [**core_users_recovery_email_create**](docs/CoreApi.md#core_users_recovery_email_create) | **POST** /core/users/{id}/recovery_email/ | +*CoreApi* | [**core_users_retrieve**](docs/CoreApi.md#core_users_retrieve) | **GET** /core/users/{id}/ | +*CoreApi* | [**core_users_service_account_create**](docs/CoreApi.md#core_users_service_account_create) | **POST** /core/users/service_account/ | +*CoreApi* | [**core_users_set_password_create**](docs/CoreApi.md#core_users_set_password_create) | **POST** /core/users/{id}/set_password/ | +*CoreApi* | [**core_users_set_password_hash_create**](docs/CoreApi.md#core_users_set_password_hash_create) | **POST** /core/users/{id}/set_password_hash/ | +*CoreApi* | [**core_users_update**](docs/CoreApi.md#core_users_update) | **PUT** /core/users/{id}/ | +*CoreApi* | [**core_users_used_by_list**](docs/CoreApi.md#core_users_used_by_list) | **GET** /core/users/{id}/used_by/ | +*CryptoApi* | [**crypto_certificatekeypairs_create**](docs/CryptoApi.md#crypto_certificatekeypairs_create) | **POST** /crypto/certificatekeypairs/ | +*CryptoApi* | [**crypto_certificatekeypairs_destroy**](docs/CryptoApi.md#crypto_certificatekeypairs_destroy) | **DELETE** /crypto/certificatekeypairs/{kp_uuid}/ | +*CryptoApi* | [**crypto_certificatekeypairs_generate_create**](docs/CryptoApi.md#crypto_certificatekeypairs_generate_create) | **POST** /crypto/certificatekeypairs/generate/ | +*CryptoApi* | [**crypto_certificatekeypairs_list**](docs/CryptoApi.md#crypto_certificatekeypairs_list) | **GET** /crypto/certificatekeypairs/ | +*CryptoApi* | [**crypto_certificatekeypairs_partial_update**](docs/CryptoApi.md#crypto_certificatekeypairs_partial_update) | **PATCH** /crypto/certificatekeypairs/{kp_uuid}/ | +*CryptoApi* | [**crypto_certificatekeypairs_retrieve**](docs/CryptoApi.md#crypto_certificatekeypairs_retrieve) | **GET** /crypto/certificatekeypairs/{kp_uuid}/ | +*CryptoApi* | [**crypto_certificatekeypairs_update**](docs/CryptoApi.md#crypto_certificatekeypairs_update) | **PUT** /crypto/certificatekeypairs/{kp_uuid}/ | +*CryptoApi* | [**crypto_certificatekeypairs_used_by_list**](docs/CryptoApi.md#crypto_certificatekeypairs_used_by_list) | **GET** /crypto/certificatekeypairs/{kp_uuid}/used_by/ | +*CryptoApi* | [**crypto_certificatekeypairs_view_certificate_retrieve**](docs/CryptoApi.md#crypto_certificatekeypairs_view_certificate_retrieve) | **GET** /crypto/certificatekeypairs/{kp_uuid}/view_certificate/ | +*CryptoApi* | [**crypto_certificatekeypairs_view_private_key_retrieve**](docs/CryptoApi.md#crypto_certificatekeypairs_view_private_key_retrieve) | **GET** /crypto/certificatekeypairs/{kp_uuid}/view_private_key/ | +*EndpointsApi* | [**endpoints_agents_connectors_agent_config_retrieve**](docs/EndpointsApi.md#endpoints_agents_connectors_agent_config_retrieve) | **GET** /endpoints/agents/connectors/agent_config/ | +*EndpointsApi* | [**endpoints_agents_connectors_auth_fed_create**](docs/EndpointsApi.md#endpoints_agents_connectors_auth_fed_create) | **POST** /endpoints/agents/connectors/auth_fed/ | +*EndpointsApi* | [**endpoints_agents_connectors_auth_ia_create**](docs/EndpointsApi.md#endpoints_agents_connectors_auth_ia_create) | **POST** /endpoints/agents/connectors/auth_ia/ | +*EndpointsApi* | [**endpoints_agents_connectors_check_in_create**](docs/EndpointsApi.md#endpoints_agents_connectors_check_in_create) | **POST** /endpoints/agents/connectors/check_in/ | +*EndpointsApi* | [**endpoints_agents_connectors_create**](docs/EndpointsApi.md#endpoints_agents_connectors_create) | **POST** /endpoints/agents/connectors/ | +*EndpointsApi* | [**endpoints_agents_connectors_destroy**](docs/EndpointsApi.md#endpoints_agents_connectors_destroy) | **DELETE** /endpoints/agents/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_agents_connectors_enroll_create**](docs/EndpointsApi.md#endpoints_agents_connectors_enroll_create) | **POST** /endpoints/agents/connectors/enroll/ | +*EndpointsApi* | [**endpoints_agents_connectors_list**](docs/EndpointsApi.md#endpoints_agents_connectors_list) | **GET** /endpoints/agents/connectors/ | +*EndpointsApi* | [**endpoints_agents_connectors_mdm_config_create**](docs/EndpointsApi.md#endpoints_agents_connectors_mdm_config_create) | **POST** /endpoints/agents/connectors/{connector_uuid}/mdm_config/ | +*EndpointsApi* | [**endpoints_agents_connectors_partial_update**](docs/EndpointsApi.md#endpoints_agents_connectors_partial_update) | **PATCH** /endpoints/agents/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_agents_connectors_retrieve**](docs/EndpointsApi.md#endpoints_agents_connectors_retrieve) | **GET** /endpoints/agents/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_agents_connectors_update**](docs/EndpointsApi.md#endpoints_agents_connectors_update) | **PUT** /endpoints/agents/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_agents_connectors_used_by_list**](docs/EndpointsApi.md#endpoints_agents_connectors_used_by_list) | **GET** /endpoints/agents/connectors/{connector_uuid}/used_by/ | +*EndpointsApi* | [**endpoints_agents_enrollment_tokens_create**](docs/EndpointsApi.md#endpoints_agents_enrollment_tokens_create) | **POST** /endpoints/agents/enrollment_tokens/ | +*EndpointsApi* | [**endpoints_agents_enrollment_tokens_destroy**](docs/EndpointsApi.md#endpoints_agents_enrollment_tokens_destroy) | **DELETE** /endpoints/agents/enrollment_tokens/{token_uuid}/ | +*EndpointsApi* | [**endpoints_agents_enrollment_tokens_list**](docs/EndpointsApi.md#endpoints_agents_enrollment_tokens_list) | **GET** /endpoints/agents/enrollment_tokens/ | +*EndpointsApi* | [**endpoints_agents_enrollment_tokens_partial_update**](docs/EndpointsApi.md#endpoints_agents_enrollment_tokens_partial_update) | **PATCH** /endpoints/agents/enrollment_tokens/{token_uuid}/ | +*EndpointsApi* | [**endpoints_agents_enrollment_tokens_retrieve**](docs/EndpointsApi.md#endpoints_agents_enrollment_tokens_retrieve) | **GET** /endpoints/agents/enrollment_tokens/{token_uuid}/ | +*EndpointsApi* | [**endpoints_agents_enrollment_tokens_update**](docs/EndpointsApi.md#endpoints_agents_enrollment_tokens_update) | **PUT** /endpoints/agents/enrollment_tokens/{token_uuid}/ | +*EndpointsApi* | [**endpoints_agents_enrollment_tokens_used_by_list**](docs/EndpointsApi.md#endpoints_agents_enrollment_tokens_used_by_list) | **GET** /endpoints/agents/enrollment_tokens/{token_uuid}/used_by/ | +*EndpointsApi* | [**endpoints_agents_enrollment_tokens_view_key_retrieve**](docs/EndpointsApi.md#endpoints_agents_enrollment_tokens_view_key_retrieve) | **GET** /endpoints/agents/enrollment_tokens/{token_uuid}/view_key/ | +*EndpointsApi* | [**endpoints_agents_psso_ise_create**](docs/EndpointsApi.md#endpoints_agents_psso_ise_create) | **POST** /endpoints/agents/psso/ise/ | +*EndpointsApi* | [**endpoints_agents_psso_ise_destroy**](docs/EndpointsApi.md#endpoints_agents_psso_ise_destroy) | **DELETE** /endpoints/agents/psso/ise/{uuid}/ | +*EndpointsApi* | [**endpoints_agents_psso_ise_list**](docs/EndpointsApi.md#endpoints_agents_psso_ise_list) | **GET** /endpoints/agents/psso/ise/ | +*EndpointsApi* | [**endpoints_agents_psso_ise_partial_update**](docs/EndpointsApi.md#endpoints_agents_psso_ise_partial_update) | **PATCH** /endpoints/agents/psso/ise/{uuid}/ | +*EndpointsApi* | [**endpoints_agents_psso_ise_retrieve**](docs/EndpointsApi.md#endpoints_agents_psso_ise_retrieve) | **GET** /endpoints/agents/psso/ise/{uuid}/ | +*EndpointsApi* | [**endpoints_agents_psso_ise_update**](docs/EndpointsApi.md#endpoints_agents_psso_ise_update) | **PUT** /endpoints/agents/psso/ise/{uuid}/ | +*EndpointsApi* | [**endpoints_agents_psso_ise_used_by_list**](docs/EndpointsApi.md#endpoints_agents_psso_ise_used_by_list) | **GET** /endpoints/agents/psso/ise/{uuid}/used_by/ | +*EndpointsApi* | [**endpoints_agents_psso_register_device_create**](docs/EndpointsApi.md#endpoints_agents_psso_register_device_create) | **POST** /endpoints/agents/psso/register/device/ | +*EndpointsApi* | [**endpoints_agents_psso_register_user_create**](docs/EndpointsApi.md#endpoints_agents_psso_register_user_create) | **POST** /endpoints/agents/psso/register/user/ | +*EndpointsApi* | [**endpoints_connectors_destroy**](docs/EndpointsApi.md#endpoints_connectors_destroy) | **DELETE** /endpoints/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_connectors_list**](docs/EndpointsApi.md#endpoints_connectors_list) | **GET** /endpoints/connectors/ | +*EndpointsApi* | [**endpoints_connectors_retrieve**](docs/EndpointsApi.md#endpoints_connectors_retrieve) | **GET** /endpoints/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_connectors_types_list**](docs/EndpointsApi.md#endpoints_connectors_types_list) | **GET** /endpoints/connectors/types/ | +*EndpointsApi* | [**endpoints_connectors_used_by_list**](docs/EndpointsApi.md#endpoints_connectors_used_by_list) | **GET** /endpoints/connectors/{connector_uuid}/used_by/ | +*EndpointsApi* | [**endpoints_device_access_groups_create**](docs/EndpointsApi.md#endpoints_device_access_groups_create) | **POST** /endpoints/device_access_groups/ | +*EndpointsApi* | [**endpoints_device_access_groups_destroy**](docs/EndpointsApi.md#endpoints_device_access_groups_destroy) | **DELETE** /endpoints/device_access_groups/{pbm_uuid}/ | +*EndpointsApi* | [**endpoints_device_access_groups_list**](docs/EndpointsApi.md#endpoints_device_access_groups_list) | **GET** /endpoints/device_access_groups/ | +*EndpointsApi* | [**endpoints_device_access_groups_partial_update**](docs/EndpointsApi.md#endpoints_device_access_groups_partial_update) | **PATCH** /endpoints/device_access_groups/{pbm_uuid}/ | +*EndpointsApi* | [**endpoints_device_access_groups_retrieve**](docs/EndpointsApi.md#endpoints_device_access_groups_retrieve) | **GET** /endpoints/device_access_groups/{pbm_uuid}/ | +*EndpointsApi* | [**endpoints_device_access_groups_update**](docs/EndpointsApi.md#endpoints_device_access_groups_update) | **PUT** /endpoints/device_access_groups/{pbm_uuid}/ | +*EndpointsApi* | [**endpoints_device_access_groups_used_by_list**](docs/EndpointsApi.md#endpoints_device_access_groups_used_by_list) | **GET** /endpoints/device_access_groups/{pbm_uuid}/used_by/ | +*EndpointsApi* | [**endpoints_device_bindings_create**](docs/EndpointsApi.md#endpoints_device_bindings_create) | **POST** /endpoints/device_bindings/ | +*EndpointsApi* | [**endpoints_device_bindings_destroy**](docs/EndpointsApi.md#endpoints_device_bindings_destroy) | **DELETE** /endpoints/device_bindings/{policy_binding_uuid}/ | +*EndpointsApi* | [**endpoints_device_bindings_list**](docs/EndpointsApi.md#endpoints_device_bindings_list) | **GET** /endpoints/device_bindings/ | +*EndpointsApi* | [**endpoints_device_bindings_partial_update**](docs/EndpointsApi.md#endpoints_device_bindings_partial_update) | **PATCH** /endpoints/device_bindings/{policy_binding_uuid}/ | +*EndpointsApi* | [**endpoints_device_bindings_retrieve**](docs/EndpointsApi.md#endpoints_device_bindings_retrieve) | **GET** /endpoints/device_bindings/{policy_binding_uuid}/ | +*EndpointsApi* | [**endpoints_device_bindings_update**](docs/EndpointsApi.md#endpoints_device_bindings_update) | **PUT** /endpoints/device_bindings/{policy_binding_uuid}/ | +*EndpointsApi* | [**endpoints_device_bindings_used_by_list**](docs/EndpointsApi.md#endpoints_device_bindings_used_by_list) | **GET** /endpoints/device_bindings/{policy_binding_uuid}/used_by/ | +*EndpointsApi* | [**endpoints_devices_destroy**](docs/EndpointsApi.md#endpoints_devices_destroy) | **DELETE** /endpoints/devices/{device_uuid}/ | +*EndpointsApi* | [**endpoints_devices_list**](docs/EndpointsApi.md#endpoints_devices_list) | **GET** /endpoints/devices/ | +*EndpointsApi* | [**endpoints_devices_partial_update**](docs/EndpointsApi.md#endpoints_devices_partial_update) | **PATCH** /endpoints/devices/{device_uuid}/ | +*EndpointsApi* | [**endpoints_devices_retrieve**](docs/EndpointsApi.md#endpoints_devices_retrieve) | **GET** /endpoints/devices/{device_uuid}/ | +*EndpointsApi* | [**endpoints_devices_summary_retrieve**](docs/EndpointsApi.md#endpoints_devices_summary_retrieve) | **GET** /endpoints/devices/summary/ | +*EndpointsApi* | [**endpoints_devices_update**](docs/EndpointsApi.md#endpoints_devices_update) | **PUT** /endpoints/devices/{device_uuid}/ | +*EndpointsApi* | [**endpoints_devices_used_by_list**](docs/EndpointsApi.md#endpoints_devices_used_by_list) | **GET** /endpoints/devices/{device_uuid}/used_by/ | +*EndpointsApi* | [**endpoints_fleet_connectors_create**](docs/EndpointsApi.md#endpoints_fleet_connectors_create) | **POST** /endpoints/fleet/connectors/ | +*EndpointsApi* | [**endpoints_fleet_connectors_destroy**](docs/EndpointsApi.md#endpoints_fleet_connectors_destroy) | **DELETE** /endpoints/fleet/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_fleet_connectors_list**](docs/EndpointsApi.md#endpoints_fleet_connectors_list) | **GET** /endpoints/fleet/connectors/ | +*EndpointsApi* | [**endpoints_fleet_connectors_partial_update**](docs/EndpointsApi.md#endpoints_fleet_connectors_partial_update) | **PATCH** /endpoints/fleet/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_fleet_connectors_retrieve**](docs/EndpointsApi.md#endpoints_fleet_connectors_retrieve) | **GET** /endpoints/fleet/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_fleet_connectors_update**](docs/EndpointsApi.md#endpoints_fleet_connectors_update) | **PUT** /endpoints/fleet/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_fleet_connectors_used_by_list**](docs/EndpointsApi.md#endpoints_fleet_connectors_used_by_list) | **GET** /endpoints/fleet/connectors/{connector_uuid}/used_by/ | +*EndpointsApi* | [**endpoints_google_chrome_connectors_create**](docs/EndpointsApi.md#endpoints_google_chrome_connectors_create) | **POST** /endpoints/google_chrome/connectors/ | +*EndpointsApi* | [**endpoints_google_chrome_connectors_destroy**](docs/EndpointsApi.md#endpoints_google_chrome_connectors_destroy) | **DELETE** /endpoints/google_chrome/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_google_chrome_connectors_list**](docs/EndpointsApi.md#endpoints_google_chrome_connectors_list) | **GET** /endpoints/google_chrome/connectors/ | +*EndpointsApi* | [**endpoints_google_chrome_connectors_partial_update**](docs/EndpointsApi.md#endpoints_google_chrome_connectors_partial_update) | **PATCH** /endpoints/google_chrome/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_google_chrome_connectors_retrieve**](docs/EndpointsApi.md#endpoints_google_chrome_connectors_retrieve) | **GET** /endpoints/google_chrome/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_google_chrome_connectors_update**](docs/EndpointsApi.md#endpoints_google_chrome_connectors_update) | **PUT** /endpoints/google_chrome/connectors/{connector_uuid}/ | +*EndpointsApi* | [**endpoints_google_chrome_connectors_used_by_list**](docs/EndpointsApi.md#endpoints_google_chrome_connectors_used_by_list) | **GET** /endpoints/google_chrome/connectors/{connector_uuid}/used_by/ | +*EnterpriseApi* | [**enterprise_license_create**](docs/EnterpriseApi.md#enterprise_license_create) | **POST** /enterprise/license/ | +*EnterpriseApi* | [**enterprise_license_destroy**](docs/EnterpriseApi.md#enterprise_license_destroy) | **DELETE** /enterprise/license/{license_uuid}/ | +*EnterpriseApi* | [**enterprise_license_forecast_retrieve**](docs/EnterpriseApi.md#enterprise_license_forecast_retrieve) | **GET** /enterprise/license/forecast/ | +*EnterpriseApi* | [**enterprise_license_install_id_retrieve**](docs/EnterpriseApi.md#enterprise_license_install_id_retrieve) | **GET** /enterprise/license/install_id/ | +*EnterpriseApi* | [**enterprise_license_list**](docs/EnterpriseApi.md#enterprise_license_list) | **GET** /enterprise/license/ | +*EnterpriseApi* | [**enterprise_license_partial_update**](docs/EnterpriseApi.md#enterprise_license_partial_update) | **PATCH** /enterprise/license/{license_uuid}/ | +*EnterpriseApi* | [**enterprise_license_retrieve**](docs/EnterpriseApi.md#enterprise_license_retrieve) | **GET** /enterprise/license/{license_uuid}/ | +*EnterpriseApi* | [**enterprise_license_summary_retrieve**](docs/EnterpriseApi.md#enterprise_license_summary_retrieve) | **GET** /enterprise/license/summary/ | +*EnterpriseApi* | [**enterprise_license_update**](docs/EnterpriseApi.md#enterprise_license_update) | **PUT** /enterprise/license/{license_uuid}/ | +*EnterpriseApi* | [**enterprise_license_used_by_list**](docs/EnterpriseApi.md#enterprise_license_used_by_list) | **GET** /enterprise/license/{license_uuid}/used_by/ | +*EventsApi* | [**events_events_actions_list**](docs/EventsApi.md#events_events_actions_list) | **GET** /events/events/actions/ | +*EventsApi* | [**events_events_create**](docs/EventsApi.md#events_events_create) | **POST** /events/events/ | +*EventsApi* | [**events_events_destroy**](docs/EventsApi.md#events_events_destroy) | **DELETE** /events/events/{event_uuid}/ | +*EventsApi* | [**events_events_export_create**](docs/EventsApi.md#events_events_export_create) | **POST** /events/events/export/ | +*EventsApi* | [**events_events_list**](docs/EventsApi.md#events_events_list) | **GET** /events/events/ | +*EventsApi* | [**events_events_partial_update**](docs/EventsApi.md#events_events_partial_update) | **PATCH** /events/events/{event_uuid}/ | +*EventsApi* | [**events_events_retrieve**](docs/EventsApi.md#events_events_retrieve) | **GET** /events/events/{event_uuid}/ | +*EventsApi* | [**events_events_stats_retrieve**](docs/EventsApi.md#events_events_stats_retrieve) | **GET** /events/events/stats/ | +*EventsApi* | [**events_events_top_per_user_list**](docs/EventsApi.md#events_events_top_per_user_list) | **GET** /events/events/top_per_user/ | +*EventsApi* | [**events_events_update**](docs/EventsApi.md#events_events_update) | **PUT** /events/events/{event_uuid}/ | +*EventsApi* | [**events_events_volume_list**](docs/EventsApi.md#events_events_volume_list) | **GET** /events/events/volume/ | +*EventsApi* | [**events_notifications_destroy**](docs/EventsApi.md#events_notifications_destroy) | **DELETE** /events/notifications/{uuid}/ | +*EventsApi* | [**events_notifications_list**](docs/EventsApi.md#events_notifications_list) | **GET** /events/notifications/ | +*EventsApi* | [**events_notifications_mark_all_seen_create**](docs/EventsApi.md#events_notifications_mark_all_seen_create) | **POST** /events/notifications/mark_all_seen/ | +*EventsApi* | [**events_notifications_partial_update**](docs/EventsApi.md#events_notifications_partial_update) | **PATCH** /events/notifications/{uuid}/ | +*EventsApi* | [**events_notifications_retrieve**](docs/EventsApi.md#events_notifications_retrieve) | **GET** /events/notifications/{uuid}/ | +*EventsApi* | [**events_notifications_update**](docs/EventsApi.md#events_notifications_update) | **PUT** /events/notifications/{uuid}/ | +*EventsApi* | [**events_notifications_used_by_list**](docs/EventsApi.md#events_notifications_used_by_list) | **GET** /events/notifications/{uuid}/used_by/ | +*EventsApi* | [**events_rules_create**](docs/EventsApi.md#events_rules_create) | **POST** /events/rules/ | +*EventsApi* | [**events_rules_destroy**](docs/EventsApi.md#events_rules_destroy) | **DELETE** /events/rules/{pbm_uuid}/ | +*EventsApi* | [**events_rules_list**](docs/EventsApi.md#events_rules_list) | **GET** /events/rules/ | +*EventsApi* | [**events_rules_partial_update**](docs/EventsApi.md#events_rules_partial_update) | **PATCH** /events/rules/{pbm_uuid}/ | +*EventsApi* | [**events_rules_retrieve**](docs/EventsApi.md#events_rules_retrieve) | **GET** /events/rules/{pbm_uuid}/ | +*EventsApi* | [**events_rules_update**](docs/EventsApi.md#events_rules_update) | **PUT** /events/rules/{pbm_uuid}/ | +*EventsApi* | [**events_rules_used_by_list**](docs/EventsApi.md#events_rules_used_by_list) | **GET** /events/rules/{pbm_uuid}/used_by/ | +*EventsApi* | [**events_transports_create**](docs/EventsApi.md#events_transports_create) | **POST** /events/transports/ | +*EventsApi* | [**events_transports_destroy**](docs/EventsApi.md#events_transports_destroy) | **DELETE** /events/transports/{uuid}/ | +*EventsApi* | [**events_transports_list**](docs/EventsApi.md#events_transports_list) | **GET** /events/transports/ | +*EventsApi* | [**events_transports_partial_update**](docs/EventsApi.md#events_transports_partial_update) | **PATCH** /events/transports/{uuid}/ | +*EventsApi* | [**events_transports_retrieve**](docs/EventsApi.md#events_transports_retrieve) | **GET** /events/transports/{uuid}/ | +*EventsApi* | [**events_transports_test_create**](docs/EventsApi.md#events_transports_test_create) | **POST** /events/transports/{uuid}/test/ | +*EventsApi* | [**events_transports_update**](docs/EventsApi.md#events_transports_update) | **PUT** /events/transports/{uuid}/ | +*EventsApi* | [**events_transports_used_by_list**](docs/EventsApi.md#events_transports_used_by_list) | **GET** /events/transports/{uuid}/used_by/ | +*FlowsApi* | [**flows_bindings_create**](docs/FlowsApi.md#flows_bindings_create) | **POST** /flows/bindings/ | +*FlowsApi* | [**flows_bindings_destroy**](docs/FlowsApi.md#flows_bindings_destroy) | **DELETE** /flows/bindings/{fsb_uuid}/ | +*FlowsApi* | [**flows_bindings_list**](docs/FlowsApi.md#flows_bindings_list) | **GET** /flows/bindings/ | +*FlowsApi* | [**flows_bindings_partial_update**](docs/FlowsApi.md#flows_bindings_partial_update) | **PATCH** /flows/bindings/{fsb_uuid}/ | +*FlowsApi* | [**flows_bindings_retrieve**](docs/FlowsApi.md#flows_bindings_retrieve) | **GET** /flows/bindings/{fsb_uuid}/ | +*FlowsApi* | [**flows_bindings_update**](docs/FlowsApi.md#flows_bindings_update) | **PUT** /flows/bindings/{fsb_uuid}/ | +*FlowsApi* | [**flows_bindings_used_by_list**](docs/FlowsApi.md#flows_bindings_used_by_list) | **GET** /flows/bindings/{fsb_uuid}/used_by/ | +*FlowsApi* | [**flows_executor_get**](docs/FlowsApi.md#flows_executor_get) | **GET** /flows/executor/{flow_slug}/ | +*FlowsApi* | [**flows_executor_solve**](docs/FlowsApi.md#flows_executor_solve) | **POST** /flows/executor/{flow_slug}/ | +*FlowsApi* | [**flows_inspector_get**](docs/FlowsApi.md#flows_inspector_get) | **GET** /flows/inspector/{flow_slug}/ | +*FlowsApi* | [**flows_instances_cache_clear_create**](docs/FlowsApi.md#flows_instances_cache_clear_create) | **POST** /flows/instances/cache_clear/ | +*FlowsApi* | [**flows_instances_cache_info_retrieve**](docs/FlowsApi.md#flows_instances_cache_info_retrieve) | **GET** /flows/instances/cache_info/ | +*FlowsApi* | [**flows_instances_create**](docs/FlowsApi.md#flows_instances_create) | **POST** /flows/instances/ | +*FlowsApi* | [**flows_instances_destroy**](docs/FlowsApi.md#flows_instances_destroy) | **DELETE** /flows/instances/{slug}/ | +*FlowsApi* | [**flows_instances_diagram_retrieve**](docs/FlowsApi.md#flows_instances_diagram_retrieve) | **GET** /flows/instances/{slug}/diagram/ | +*FlowsApi* | [**flows_instances_execute_retrieve**](docs/FlowsApi.md#flows_instances_execute_retrieve) | **GET** /flows/instances/{slug}/execute/ | +*FlowsApi* | [**flows_instances_export_retrieve**](docs/FlowsApi.md#flows_instances_export_retrieve) | **GET** /flows/instances/{slug}/export/ | +*FlowsApi* | [**flows_instances_list**](docs/FlowsApi.md#flows_instances_list) | **GET** /flows/instances/ | +*FlowsApi* | [**flows_instances_partial_update**](docs/FlowsApi.md#flows_instances_partial_update) | **PATCH** /flows/instances/{slug}/ | +*FlowsApi* | [**flows_instances_retrieve**](docs/FlowsApi.md#flows_instances_retrieve) | **GET** /flows/instances/{slug}/ | +*FlowsApi* | [**flows_instances_update**](docs/FlowsApi.md#flows_instances_update) | **PUT** /flows/instances/{slug}/ | +*FlowsApi* | [**flows_instances_used_by_list**](docs/FlowsApi.md#flows_instances_used_by_list) | **GET** /flows/instances/{slug}/used_by/ | +*LifecycleApi* | [**lifecycle_iterations_create**](docs/LifecycleApi.md#lifecycle_iterations_create) | **POST** /lifecycle/iterations/ | +*LifecycleApi* | [**lifecycle_iterations_list_latest**](docs/LifecycleApi.md#lifecycle_iterations_list_latest) | **GET** /lifecycle/iterations/latest/{content_type}/{object_id}/ | +*LifecycleApi* | [**lifecycle_iterations_list_open**](docs/LifecycleApi.md#lifecycle_iterations_list_open) | **GET** /lifecycle/iterations/open/ | +*LifecycleApi* | [**lifecycle_reviews_create**](docs/LifecycleApi.md#lifecycle_reviews_create) | **POST** /lifecycle/reviews/ | +*LifecycleApi* | [**lifecycle_rules_create**](docs/LifecycleApi.md#lifecycle_rules_create) | **POST** /lifecycle/rules/ | +*LifecycleApi* | [**lifecycle_rules_destroy**](docs/LifecycleApi.md#lifecycle_rules_destroy) | **DELETE** /lifecycle/rules/{id}/ | +*LifecycleApi* | [**lifecycle_rules_list**](docs/LifecycleApi.md#lifecycle_rules_list) | **GET** /lifecycle/rules/ | +*LifecycleApi* | [**lifecycle_rules_partial_update**](docs/LifecycleApi.md#lifecycle_rules_partial_update) | **PATCH** /lifecycle/rules/{id}/ | +*LifecycleApi* | [**lifecycle_rules_retrieve**](docs/LifecycleApi.md#lifecycle_rules_retrieve) | **GET** /lifecycle/rules/{id}/ | +*LifecycleApi* | [**lifecycle_rules_update**](docs/LifecycleApi.md#lifecycle_rules_update) | **PUT** /lifecycle/rules/{id}/ | +*ManagedApi* | [**managed_blueprints_apply_create**](docs/ManagedApi.md#managed_blueprints_apply_create) | **POST** /managed/blueprints/{instance_uuid}/apply/ | +*ManagedApi* | [**managed_blueprints_available_list**](docs/ManagedApi.md#managed_blueprints_available_list) | **GET** /managed/blueprints/available/ | +*ManagedApi* | [**managed_blueprints_create**](docs/ManagedApi.md#managed_blueprints_create) | **POST** /managed/blueprints/ | +*ManagedApi* | [**managed_blueprints_destroy**](docs/ManagedApi.md#managed_blueprints_destroy) | **DELETE** /managed/blueprints/{instance_uuid}/ | +*ManagedApi* | [**managed_blueprints_import_create**](docs/ManagedApi.md#managed_blueprints_import_create) | **POST** /managed/blueprints/import/ | +*ManagedApi* | [**managed_blueprints_list**](docs/ManagedApi.md#managed_blueprints_list) | **GET** /managed/blueprints/ | +*ManagedApi* | [**managed_blueprints_partial_update**](docs/ManagedApi.md#managed_blueprints_partial_update) | **PATCH** /managed/blueprints/{instance_uuid}/ | +*ManagedApi* | [**managed_blueprints_retrieve**](docs/ManagedApi.md#managed_blueprints_retrieve) | **GET** /managed/blueprints/{instance_uuid}/ | +*ManagedApi* | [**managed_blueprints_update**](docs/ManagedApi.md#managed_blueprints_update) | **PUT** /managed/blueprints/{instance_uuid}/ | +*ManagedApi* | [**managed_blueprints_used_by_list**](docs/ManagedApi.md#managed_blueprints_used_by_list) | **GET** /managed/blueprints/{instance_uuid}/used_by/ | +*Oauth2Api* | [**oauth2_access_tokens_destroy**](docs/Oauth2Api.md#oauth2_access_tokens_destroy) | **DELETE** /oauth2/access_tokens/{id}/ | +*Oauth2Api* | [**oauth2_access_tokens_list**](docs/Oauth2Api.md#oauth2_access_tokens_list) | **GET** /oauth2/access_tokens/ | +*Oauth2Api* | [**oauth2_access_tokens_retrieve**](docs/Oauth2Api.md#oauth2_access_tokens_retrieve) | **GET** /oauth2/access_tokens/{id}/ | +*Oauth2Api* | [**oauth2_access_tokens_used_by_list**](docs/Oauth2Api.md#oauth2_access_tokens_used_by_list) | **GET** /oauth2/access_tokens/{id}/used_by/ | +*Oauth2Api* | [**oauth2_authorization_codes_destroy**](docs/Oauth2Api.md#oauth2_authorization_codes_destroy) | **DELETE** /oauth2/authorization_codes/{id}/ | +*Oauth2Api* | [**oauth2_authorization_codes_list**](docs/Oauth2Api.md#oauth2_authorization_codes_list) | **GET** /oauth2/authorization_codes/ | +*Oauth2Api* | [**oauth2_authorization_codes_retrieve**](docs/Oauth2Api.md#oauth2_authorization_codes_retrieve) | **GET** /oauth2/authorization_codes/{id}/ | +*Oauth2Api* | [**oauth2_authorization_codes_used_by_list**](docs/Oauth2Api.md#oauth2_authorization_codes_used_by_list) | **GET** /oauth2/authorization_codes/{id}/used_by/ | +*Oauth2Api* | [**oauth2_refresh_tokens_destroy**](docs/Oauth2Api.md#oauth2_refresh_tokens_destroy) | **DELETE** /oauth2/refresh_tokens/{id}/ | +*Oauth2Api* | [**oauth2_refresh_tokens_list**](docs/Oauth2Api.md#oauth2_refresh_tokens_list) | **GET** /oauth2/refresh_tokens/ | +*Oauth2Api* | [**oauth2_refresh_tokens_retrieve**](docs/Oauth2Api.md#oauth2_refresh_tokens_retrieve) | **GET** /oauth2/refresh_tokens/{id}/ | +*Oauth2Api* | [**oauth2_refresh_tokens_used_by_list**](docs/Oauth2Api.md#oauth2_refresh_tokens_used_by_list) | **GET** /oauth2/refresh_tokens/{id}/used_by/ | +*OutpostsApi* | [**outposts_instances_create**](docs/OutpostsApi.md#outposts_instances_create) | **POST** /outposts/instances/ | +*OutpostsApi* | [**outposts_instances_default_settings_retrieve**](docs/OutpostsApi.md#outposts_instances_default_settings_retrieve) | **GET** /outposts/instances/default_settings/ | +*OutpostsApi* | [**outposts_instances_destroy**](docs/OutpostsApi.md#outposts_instances_destroy) | **DELETE** /outposts/instances/{uuid}/ | +*OutpostsApi* | [**outposts_instances_health_list**](docs/OutpostsApi.md#outposts_instances_health_list) | **GET** /outposts/instances/{uuid}/health/ | +*OutpostsApi* | [**outposts_instances_list**](docs/OutpostsApi.md#outposts_instances_list) | **GET** /outposts/instances/ | +*OutpostsApi* | [**outposts_instances_partial_update**](docs/OutpostsApi.md#outposts_instances_partial_update) | **PATCH** /outposts/instances/{uuid}/ | +*OutpostsApi* | [**outposts_instances_retrieve**](docs/OutpostsApi.md#outposts_instances_retrieve) | **GET** /outposts/instances/{uuid}/ | +*OutpostsApi* | [**outposts_instances_update**](docs/OutpostsApi.md#outposts_instances_update) | **PUT** /outposts/instances/{uuid}/ | +*OutpostsApi* | [**outposts_instances_used_by_list**](docs/OutpostsApi.md#outposts_instances_used_by_list) | **GET** /outposts/instances/{uuid}/used_by/ | +*OutpostsApi* | [**outposts_ldap_access_check**](docs/OutpostsApi.md#outposts_ldap_access_check) | **GET** /outposts/ldap/{id}/check_access/ | +*OutpostsApi* | [**outposts_ldap_list**](docs/OutpostsApi.md#outposts_ldap_list) | **GET** /outposts/ldap/ | +*OutpostsApi* | [**outposts_proxy_list**](docs/OutpostsApi.md#outposts_proxy_list) | **GET** /outposts/proxy/ | +*OutpostsApi* | [**outposts_radius_access_check**](docs/OutpostsApi.md#outposts_radius_access_check) | **GET** /outposts/radius/{id}/check_access/ | +*OutpostsApi* | [**outposts_radius_list**](docs/OutpostsApi.md#outposts_radius_list) | **GET** /outposts/radius/ | +*OutpostsApi* | [**outposts_service_connections_all_destroy**](docs/OutpostsApi.md#outposts_service_connections_all_destroy) | **DELETE** /outposts/service_connections/all/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_all_list**](docs/OutpostsApi.md#outposts_service_connections_all_list) | **GET** /outposts/service_connections/all/ | +*OutpostsApi* | [**outposts_service_connections_all_retrieve**](docs/OutpostsApi.md#outposts_service_connections_all_retrieve) | **GET** /outposts/service_connections/all/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_all_state_retrieve**](docs/OutpostsApi.md#outposts_service_connections_all_state_retrieve) | **GET** /outposts/service_connections/all/{uuid}/state/ | +*OutpostsApi* | [**outposts_service_connections_all_types_list**](docs/OutpostsApi.md#outposts_service_connections_all_types_list) | **GET** /outposts/service_connections/all/types/ | +*OutpostsApi* | [**outposts_service_connections_all_used_by_list**](docs/OutpostsApi.md#outposts_service_connections_all_used_by_list) | **GET** /outposts/service_connections/all/{uuid}/used_by/ | +*OutpostsApi* | [**outposts_service_connections_docker_create**](docs/OutpostsApi.md#outposts_service_connections_docker_create) | **POST** /outposts/service_connections/docker/ | +*OutpostsApi* | [**outposts_service_connections_docker_destroy**](docs/OutpostsApi.md#outposts_service_connections_docker_destroy) | **DELETE** /outposts/service_connections/docker/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_docker_list**](docs/OutpostsApi.md#outposts_service_connections_docker_list) | **GET** /outposts/service_connections/docker/ | +*OutpostsApi* | [**outposts_service_connections_docker_partial_update**](docs/OutpostsApi.md#outposts_service_connections_docker_partial_update) | **PATCH** /outposts/service_connections/docker/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_docker_retrieve**](docs/OutpostsApi.md#outposts_service_connections_docker_retrieve) | **GET** /outposts/service_connections/docker/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_docker_update**](docs/OutpostsApi.md#outposts_service_connections_docker_update) | **PUT** /outposts/service_connections/docker/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_docker_used_by_list**](docs/OutpostsApi.md#outposts_service_connections_docker_used_by_list) | **GET** /outposts/service_connections/docker/{uuid}/used_by/ | +*OutpostsApi* | [**outposts_service_connections_kubernetes_create**](docs/OutpostsApi.md#outposts_service_connections_kubernetes_create) | **POST** /outposts/service_connections/kubernetes/ | +*OutpostsApi* | [**outposts_service_connections_kubernetes_destroy**](docs/OutpostsApi.md#outposts_service_connections_kubernetes_destroy) | **DELETE** /outposts/service_connections/kubernetes/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_kubernetes_list**](docs/OutpostsApi.md#outposts_service_connections_kubernetes_list) | **GET** /outposts/service_connections/kubernetes/ | +*OutpostsApi* | [**outposts_service_connections_kubernetes_partial_update**](docs/OutpostsApi.md#outposts_service_connections_kubernetes_partial_update) | **PATCH** /outposts/service_connections/kubernetes/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_kubernetes_retrieve**](docs/OutpostsApi.md#outposts_service_connections_kubernetes_retrieve) | **GET** /outposts/service_connections/kubernetes/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_kubernetes_update**](docs/OutpostsApi.md#outposts_service_connections_kubernetes_update) | **PUT** /outposts/service_connections/kubernetes/{uuid}/ | +*OutpostsApi* | [**outposts_service_connections_kubernetes_used_by_list**](docs/OutpostsApi.md#outposts_service_connections_kubernetes_used_by_list) | **GET** /outposts/service_connections/kubernetes/{uuid}/used_by/ | +*PoliciesApi* | [**policies_all_cache_clear_create**](docs/PoliciesApi.md#policies_all_cache_clear_create) | **POST** /policies/all/cache_clear/ | +*PoliciesApi* | [**policies_all_cache_info_retrieve**](docs/PoliciesApi.md#policies_all_cache_info_retrieve) | **GET** /policies/all/cache_info/ | +*PoliciesApi* | [**policies_all_destroy**](docs/PoliciesApi.md#policies_all_destroy) | **DELETE** /policies/all/{policy_uuid}/ | +*PoliciesApi* | [**policies_all_list**](docs/PoliciesApi.md#policies_all_list) | **GET** /policies/all/ | +*PoliciesApi* | [**policies_all_retrieve**](docs/PoliciesApi.md#policies_all_retrieve) | **GET** /policies/all/{policy_uuid}/ | +*PoliciesApi* | [**policies_all_test_create**](docs/PoliciesApi.md#policies_all_test_create) | **POST** /policies/all/{policy_uuid}/test/ | +*PoliciesApi* | [**policies_all_types_list**](docs/PoliciesApi.md#policies_all_types_list) | **GET** /policies/all/types/ | +*PoliciesApi* | [**policies_all_used_by_list**](docs/PoliciesApi.md#policies_all_used_by_list) | **GET** /policies/all/{policy_uuid}/used_by/ | +*PoliciesApi* | [**policies_bindings_create**](docs/PoliciesApi.md#policies_bindings_create) | **POST** /policies/bindings/ | +*PoliciesApi* | [**policies_bindings_destroy**](docs/PoliciesApi.md#policies_bindings_destroy) | **DELETE** /policies/bindings/{policy_binding_uuid}/ | +*PoliciesApi* | [**policies_bindings_list**](docs/PoliciesApi.md#policies_bindings_list) | **GET** /policies/bindings/ | +*PoliciesApi* | [**policies_bindings_partial_update**](docs/PoliciesApi.md#policies_bindings_partial_update) | **PATCH** /policies/bindings/{policy_binding_uuid}/ | +*PoliciesApi* | [**policies_bindings_retrieve**](docs/PoliciesApi.md#policies_bindings_retrieve) | **GET** /policies/bindings/{policy_binding_uuid}/ | +*PoliciesApi* | [**policies_bindings_update**](docs/PoliciesApi.md#policies_bindings_update) | **PUT** /policies/bindings/{policy_binding_uuid}/ | +*PoliciesApi* | [**policies_bindings_used_by_list**](docs/PoliciesApi.md#policies_bindings_used_by_list) | **GET** /policies/bindings/{policy_binding_uuid}/used_by/ | +*PoliciesApi* | [**policies_dummy_create**](docs/PoliciesApi.md#policies_dummy_create) | **POST** /policies/dummy/ | +*PoliciesApi* | [**policies_dummy_destroy**](docs/PoliciesApi.md#policies_dummy_destroy) | **DELETE** /policies/dummy/{policy_uuid}/ | +*PoliciesApi* | [**policies_dummy_list**](docs/PoliciesApi.md#policies_dummy_list) | **GET** /policies/dummy/ | +*PoliciesApi* | [**policies_dummy_partial_update**](docs/PoliciesApi.md#policies_dummy_partial_update) | **PATCH** /policies/dummy/{policy_uuid}/ | +*PoliciesApi* | [**policies_dummy_retrieve**](docs/PoliciesApi.md#policies_dummy_retrieve) | **GET** /policies/dummy/{policy_uuid}/ | +*PoliciesApi* | [**policies_dummy_update**](docs/PoliciesApi.md#policies_dummy_update) | **PUT** /policies/dummy/{policy_uuid}/ | +*PoliciesApi* | [**policies_dummy_used_by_list**](docs/PoliciesApi.md#policies_dummy_used_by_list) | **GET** /policies/dummy/{policy_uuid}/used_by/ | +*PoliciesApi* | [**policies_event_matcher_create**](docs/PoliciesApi.md#policies_event_matcher_create) | **POST** /policies/event_matcher/ | +*PoliciesApi* | [**policies_event_matcher_destroy**](docs/PoliciesApi.md#policies_event_matcher_destroy) | **DELETE** /policies/event_matcher/{policy_uuid}/ | +*PoliciesApi* | [**policies_event_matcher_list**](docs/PoliciesApi.md#policies_event_matcher_list) | **GET** /policies/event_matcher/ | +*PoliciesApi* | [**policies_event_matcher_partial_update**](docs/PoliciesApi.md#policies_event_matcher_partial_update) | **PATCH** /policies/event_matcher/{policy_uuid}/ | +*PoliciesApi* | [**policies_event_matcher_retrieve**](docs/PoliciesApi.md#policies_event_matcher_retrieve) | **GET** /policies/event_matcher/{policy_uuid}/ | +*PoliciesApi* | [**policies_event_matcher_update**](docs/PoliciesApi.md#policies_event_matcher_update) | **PUT** /policies/event_matcher/{policy_uuid}/ | +*PoliciesApi* | [**policies_event_matcher_used_by_list**](docs/PoliciesApi.md#policies_event_matcher_used_by_list) | **GET** /policies/event_matcher/{policy_uuid}/used_by/ | +*PoliciesApi* | [**policies_expression_create**](docs/PoliciesApi.md#policies_expression_create) | **POST** /policies/expression/ | +*PoliciesApi* | [**policies_expression_destroy**](docs/PoliciesApi.md#policies_expression_destroy) | **DELETE** /policies/expression/{policy_uuid}/ | +*PoliciesApi* | [**policies_expression_list**](docs/PoliciesApi.md#policies_expression_list) | **GET** /policies/expression/ | +*PoliciesApi* | [**policies_expression_partial_update**](docs/PoliciesApi.md#policies_expression_partial_update) | **PATCH** /policies/expression/{policy_uuid}/ | +*PoliciesApi* | [**policies_expression_retrieve**](docs/PoliciesApi.md#policies_expression_retrieve) | **GET** /policies/expression/{policy_uuid}/ | +*PoliciesApi* | [**policies_expression_update**](docs/PoliciesApi.md#policies_expression_update) | **PUT** /policies/expression/{policy_uuid}/ | +*PoliciesApi* | [**policies_expression_used_by_list**](docs/PoliciesApi.md#policies_expression_used_by_list) | **GET** /policies/expression/{policy_uuid}/used_by/ | +*PoliciesApi* | [**policies_geoip_create**](docs/PoliciesApi.md#policies_geoip_create) | **POST** /policies/geoip/ | +*PoliciesApi* | [**policies_geoip_destroy**](docs/PoliciesApi.md#policies_geoip_destroy) | **DELETE** /policies/geoip/{policy_uuid}/ | +*PoliciesApi* | [**policies_geoip_iso3166_list**](docs/PoliciesApi.md#policies_geoip_iso3166_list) | **GET** /policies/geoip_iso3166/ | +*PoliciesApi* | [**policies_geoip_list**](docs/PoliciesApi.md#policies_geoip_list) | **GET** /policies/geoip/ | +*PoliciesApi* | [**policies_geoip_partial_update**](docs/PoliciesApi.md#policies_geoip_partial_update) | **PATCH** /policies/geoip/{policy_uuid}/ | +*PoliciesApi* | [**policies_geoip_retrieve**](docs/PoliciesApi.md#policies_geoip_retrieve) | **GET** /policies/geoip/{policy_uuid}/ | +*PoliciesApi* | [**policies_geoip_update**](docs/PoliciesApi.md#policies_geoip_update) | **PUT** /policies/geoip/{policy_uuid}/ | +*PoliciesApi* | [**policies_geoip_used_by_list**](docs/PoliciesApi.md#policies_geoip_used_by_list) | **GET** /policies/geoip/{policy_uuid}/used_by/ | +*PoliciesApi* | [**policies_password_create**](docs/PoliciesApi.md#policies_password_create) | **POST** /policies/password/ | +*PoliciesApi* | [**policies_password_destroy**](docs/PoliciesApi.md#policies_password_destroy) | **DELETE** /policies/password/{policy_uuid}/ | +*PoliciesApi* | [**policies_password_expiry_create**](docs/PoliciesApi.md#policies_password_expiry_create) | **POST** /policies/password_expiry/ | +*PoliciesApi* | [**policies_password_expiry_destroy**](docs/PoliciesApi.md#policies_password_expiry_destroy) | **DELETE** /policies/password_expiry/{policy_uuid}/ | +*PoliciesApi* | [**policies_password_expiry_list**](docs/PoliciesApi.md#policies_password_expiry_list) | **GET** /policies/password_expiry/ | +*PoliciesApi* | [**policies_password_expiry_partial_update**](docs/PoliciesApi.md#policies_password_expiry_partial_update) | **PATCH** /policies/password_expiry/{policy_uuid}/ | +*PoliciesApi* | [**policies_password_expiry_retrieve**](docs/PoliciesApi.md#policies_password_expiry_retrieve) | **GET** /policies/password_expiry/{policy_uuid}/ | +*PoliciesApi* | [**policies_password_expiry_update**](docs/PoliciesApi.md#policies_password_expiry_update) | **PUT** /policies/password_expiry/{policy_uuid}/ | +*PoliciesApi* | [**policies_password_expiry_used_by_list**](docs/PoliciesApi.md#policies_password_expiry_used_by_list) | **GET** /policies/password_expiry/{policy_uuid}/used_by/ | +*PoliciesApi* | [**policies_password_list**](docs/PoliciesApi.md#policies_password_list) | **GET** /policies/password/ | +*PoliciesApi* | [**policies_password_partial_update**](docs/PoliciesApi.md#policies_password_partial_update) | **PATCH** /policies/password/{policy_uuid}/ | +*PoliciesApi* | [**policies_password_retrieve**](docs/PoliciesApi.md#policies_password_retrieve) | **GET** /policies/password/{policy_uuid}/ | +*PoliciesApi* | [**policies_password_update**](docs/PoliciesApi.md#policies_password_update) | **PUT** /policies/password/{policy_uuid}/ | +*PoliciesApi* | [**policies_password_used_by_list**](docs/PoliciesApi.md#policies_password_used_by_list) | **GET** /policies/password/{policy_uuid}/used_by/ | +*PoliciesApi* | [**policies_reputation_create**](docs/PoliciesApi.md#policies_reputation_create) | **POST** /policies/reputation/ | +*PoliciesApi* | [**policies_reputation_destroy**](docs/PoliciesApi.md#policies_reputation_destroy) | **DELETE** /policies/reputation/{policy_uuid}/ | +*PoliciesApi* | [**policies_reputation_list**](docs/PoliciesApi.md#policies_reputation_list) | **GET** /policies/reputation/ | +*PoliciesApi* | [**policies_reputation_partial_update**](docs/PoliciesApi.md#policies_reputation_partial_update) | **PATCH** /policies/reputation/{policy_uuid}/ | +*PoliciesApi* | [**policies_reputation_retrieve**](docs/PoliciesApi.md#policies_reputation_retrieve) | **GET** /policies/reputation/{policy_uuid}/ | +*PoliciesApi* | [**policies_reputation_scores_destroy**](docs/PoliciesApi.md#policies_reputation_scores_destroy) | **DELETE** /policies/reputation/scores/{reputation_uuid}/ | +*PoliciesApi* | [**policies_reputation_scores_list**](docs/PoliciesApi.md#policies_reputation_scores_list) | **GET** /policies/reputation/scores/ | +*PoliciesApi* | [**policies_reputation_scores_retrieve**](docs/PoliciesApi.md#policies_reputation_scores_retrieve) | **GET** /policies/reputation/scores/{reputation_uuid}/ | +*PoliciesApi* | [**policies_reputation_scores_used_by_list**](docs/PoliciesApi.md#policies_reputation_scores_used_by_list) | **GET** /policies/reputation/scores/{reputation_uuid}/used_by/ | +*PoliciesApi* | [**policies_reputation_update**](docs/PoliciesApi.md#policies_reputation_update) | **PUT** /policies/reputation/{policy_uuid}/ | +*PoliciesApi* | [**policies_reputation_used_by_list**](docs/PoliciesApi.md#policies_reputation_used_by_list) | **GET** /policies/reputation/{policy_uuid}/used_by/ | +*PoliciesApi* | [**policies_unique_password_create**](docs/PoliciesApi.md#policies_unique_password_create) | **POST** /policies/unique_password/ | +*PoliciesApi* | [**policies_unique_password_destroy**](docs/PoliciesApi.md#policies_unique_password_destroy) | **DELETE** /policies/unique_password/{policy_uuid}/ | +*PoliciesApi* | [**policies_unique_password_list**](docs/PoliciesApi.md#policies_unique_password_list) | **GET** /policies/unique_password/ | +*PoliciesApi* | [**policies_unique_password_partial_update**](docs/PoliciesApi.md#policies_unique_password_partial_update) | **PATCH** /policies/unique_password/{policy_uuid}/ | +*PoliciesApi* | [**policies_unique_password_retrieve**](docs/PoliciesApi.md#policies_unique_password_retrieve) | **GET** /policies/unique_password/{policy_uuid}/ | +*PoliciesApi* | [**policies_unique_password_update**](docs/PoliciesApi.md#policies_unique_password_update) | **PUT** /policies/unique_password/{policy_uuid}/ | +*PoliciesApi* | [**policies_unique_password_used_by_list**](docs/PoliciesApi.md#policies_unique_password_used_by_list) | **GET** /policies/unique_password/{policy_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_all_destroy**](docs/PropertymappingsApi.md#propertymappings_all_destroy) | **DELETE** /propertymappings/all/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_all_list**](docs/PropertymappingsApi.md#propertymappings_all_list) | **GET** /propertymappings/all/ | +*PropertymappingsApi* | [**propertymappings_all_retrieve**](docs/PropertymappingsApi.md#propertymappings_all_retrieve) | **GET** /propertymappings/all/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_all_test_create**](docs/PropertymappingsApi.md#propertymappings_all_test_create) | **POST** /propertymappings/all/{pm_uuid}/test/ | +*PropertymappingsApi* | [**propertymappings_all_types_list**](docs/PropertymappingsApi.md#propertymappings_all_types_list) | **GET** /propertymappings/all/types/ | +*PropertymappingsApi* | [**propertymappings_all_used_by_list**](docs/PropertymappingsApi.md#propertymappings_all_used_by_list) | **GET** /propertymappings/all/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_notification_create**](docs/PropertymappingsApi.md#propertymappings_notification_create) | **POST** /propertymappings/notification/ | +*PropertymappingsApi* | [**propertymappings_notification_destroy**](docs/PropertymappingsApi.md#propertymappings_notification_destroy) | **DELETE** /propertymappings/notification/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_notification_list**](docs/PropertymappingsApi.md#propertymappings_notification_list) | **GET** /propertymappings/notification/ | +*PropertymappingsApi* | [**propertymappings_notification_partial_update**](docs/PropertymappingsApi.md#propertymappings_notification_partial_update) | **PATCH** /propertymappings/notification/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_notification_retrieve**](docs/PropertymappingsApi.md#propertymappings_notification_retrieve) | **GET** /propertymappings/notification/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_notification_update**](docs/PropertymappingsApi.md#propertymappings_notification_update) | **PUT** /propertymappings/notification/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_notification_used_by_list**](docs/PropertymappingsApi.md#propertymappings_notification_used_by_list) | **GET** /propertymappings/notification/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_provider_google_workspace_create**](docs/PropertymappingsApi.md#propertymappings_provider_google_workspace_create) | **POST** /propertymappings/provider/google_workspace/ | +*PropertymappingsApi* | [**propertymappings_provider_google_workspace_destroy**](docs/PropertymappingsApi.md#propertymappings_provider_google_workspace_destroy) | **DELETE** /propertymappings/provider/google_workspace/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_google_workspace_list**](docs/PropertymappingsApi.md#propertymappings_provider_google_workspace_list) | **GET** /propertymappings/provider/google_workspace/ | +*PropertymappingsApi* | [**propertymappings_provider_google_workspace_partial_update**](docs/PropertymappingsApi.md#propertymappings_provider_google_workspace_partial_update) | **PATCH** /propertymappings/provider/google_workspace/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_google_workspace_retrieve**](docs/PropertymappingsApi.md#propertymappings_provider_google_workspace_retrieve) | **GET** /propertymappings/provider/google_workspace/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_google_workspace_update**](docs/PropertymappingsApi.md#propertymappings_provider_google_workspace_update) | **PUT** /propertymappings/provider/google_workspace/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_google_workspace_used_by_list**](docs/PropertymappingsApi.md#propertymappings_provider_google_workspace_used_by_list) | **GET** /propertymappings/provider/google_workspace/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_provider_microsoft_entra_create**](docs/PropertymappingsApi.md#propertymappings_provider_microsoft_entra_create) | **POST** /propertymappings/provider/microsoft_entra/ | +*PropertymappingsApi* | [**propertymappings_provider_microsoft_entra_destroy**](docs/PropertymappingsApi.md#propertymappings_provider_microsoft_entra_destroy) | **DELETE** /propertymappings/provider/microsoft_entra/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_microsoft_entra_list**](docs/PropertymappingsApi.md#propertymappings_provider_microsoft_entra_list) | **GET** /propertymappings/provider/microsoft_entra/ | +*PropertymappingsApi* | [**propertymappings_provider_microsoft_entra_partial_update**](docs/PropertymappingsApi.md#propertymappings_provider_microsoft_entra_partial_update) | **PATCH** /propertymappings/provider/microsoft_entra/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_microsoft_entra_retrieve**](docs/PropertymappingsApi.md#propertymappings_provider_microsoft_entra_retrieve) | **GET** /propertymappings/provider/microsoft_entra/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_microsoft_entra_update**](docs/PropertymappingsApi.md#propertymappings_provider_microsoft_entra_update) | **PUT** /propertymappings/provider/microsoft_entra/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_microsoft_entra_used_by_list**](docs/PropertymappingsApi.md#propertymappings_provider_microsoft_entra_used_by_list) | **GET** /propertymappings/provider/microsoft_entra/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_provider_rac_create**](docs/PropertymappingsApi.md#propertymappings_provider_rac_create) | **POST** /propertymappings/provider/rac/ | +*PropertymappingsApi* | [**propertymappings_provider_rac_destroy**](docs/PropertymappingsApi.md#propertymappings_provider_rac_destroy) | **DELETE** /propertymappings/provider/rac/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_rac_list**](docs/PropertymappingsApi.md#propertymappings_provider_rac_list) | **GET** /propertymappings/provider/rac/ | +*PropertymappingsApi* | [**propertymappings_provider_rac_partial_update**](docs/PropertymappingsApi.md#propertymappings_provider_rac_partial_update) | **PATCH** /propertymappings/provider/rac/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_rac_retrieve**](docs/PropertymappingsApi.md#propertymappings_provider_rac_retrieve) | **GET** /propertymappings/provider/rac/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_rac_update**](docs/PropertymappingsApi.md#propertymappings_provider_rac_update) | **PUT** /propertymappings/provider/rac/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_rac_used_by_list**](docs/PropertymappingsApi.md#propertymappings_provider_rac_used_by_list) | **GET** /propertymappings/provider/rac/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_provider_radius_create**](docs/PropertymappingsApi.md#propertymappings_provider_radius_create) | **POST** /propertymappings/provider/radius/ | +*PropertymappingsApi* | [**propertymappings_provider_radius_destroy**](docs/PropertymappingsApi.md#propertymappings_provider_radius_destroy) | **DELETE** /propertymappings/provider/radius/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_radius_list**](docs/PropertymappingsApi.md#propertymappings_provider_radius_list) | **GET** /propertymappings/provider/radius/ | +*PropertymappingsApi* | [**propertymappings_provider_radius_partial_update**](docs/PropertymappingsApi.md#propertymappings_provider_radius_partial_update) | **PATCH** /propertymappings/provider/radius/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_radius_retrieve**](docs/PropertymappingsApi.md#propertymappings_provider_radius_retrieve) | **GET** /propertymappings/provider/radius/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_radius_update**](docs/PropertymappingsApi.md#propertymappings_provider_radius_update) | **PUT** /propertymappings/provider/radius/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_radius_used_by_list**](docs/PropertymappingsApi.md#propertymappings_provider_radius_used_by_list) | **GET** /propertymappings/provider/radius/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_provider_saml_create**](docs/PropertymappingsApi.md#propertymappings_provider_saml_create) | **POST** /propertymappings/provider/saml/ | +*PropertymappingsApi* | [**propertymappings_provider_saml_destroy**](docs/PropertymappingsApi.md#propertymappings_provider_saml_destroy) | **DELETE** /propertymappings/provider/saml/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_saml_list**](docs/PropertymappingsApi.md#propertymappings_provider_saml_list) | **GET** /propertymappings/provider/saml/ | +*PropertymappingsApi* | [**propertymappings_provider_saml_partial_update**](docs/PropertymappingsApi.md#propertymappings_provider_saml_partial_update) | **PATCH** /propertymappings/provider/saml/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_saml_retrieve**](docs/PropertymappingsApi.md#propertymappings_provider_saml_retrieve) | **GET** /propertymappings/provider/saml/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_saml_update**](docs/PropertymappingsApi.md#propertymappings_provider_saml_update) | **PUT** /propertymappings/provider/saml/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_saml_used_by_list**](docs/PropertymappingsApi.md#propertymappings_provider_saml_used_by_list) | **GET** /propertymappings/provider/saml/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_provider_scim_create**](docs/PropertymappingsApi.md#propertymappings_provider_scim_create) | **POST** /propertymappings/provider/scim/ | +*PropertymappingsApi* | [**propertymappings_provider_scim_destroy**](docs/PropertymappingsApi.md#propertymappings_provider_scim_destroy) | **DELETE** /propertymappings/provider/scim/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_scim_list**](docs/PropertymappingsApi.md#propertymappings_provider_scim_list) | **GET** /propertymappings/provider/scim/ | +*PropertymappingsApi* | [**propertymappings_provider_scim_partial_update**](docs/PropertymappingsApi.md#propertymappings_provider_scim_partial_update) | **PATCH** /propertymappings/provider/scim/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_scim_retrieve**](docs/PropertymappingsApi.md#propertymappings_provider_scim_retrieve) | **GET** /propertymappings/provider/scim/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_scim_update**](docs/PropertymappingsApi.md#propertymappings_provider_scim_update) | **PUT** /propertymappings/provider/scim/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_scim_used_by_list**](docs/PropertymappingsApi.md#propertymappings_provider_scim_used_by_list) | **GET** /propertymappings/provider/scim/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_provider_scope_create**](docs/PropertymappingsApi.md#propertymappings_provider_scope_create) | **POST** /propertymappings/provider/scope/ | +*PropertymappingsApi* | [**propertymappings_provider_scope_destroy**](docs/PropertymappingsApi.md#propertymappings_provider_scope_destroy) | **DELETE** /propertymappings/provider/scope/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_scope_list**](docs/PropertymappingsApi.md#propertymappings_provider_scope_list) | **GET** /propertymappings/provider/scope/ | +*PropertymappingsApi* | [**propertymappings_provider_scope_partial_update**](docs/PropertymappingsApi.md#propertymappings_provider_scope_partial_update) | **PATCH** /propertymappings/provider/scope/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_scope_retrieve**](docs/PropertymappingsApi.md#propertymappings_provider_scope_retrieve) | **GET** /propertymappings/provider/scope/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_scope_update**](docs/PropertymappingsApi.md#propertymappings_provider_scope_update) | **PUT** /propertymappings/provider/scope/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_provider_scope_used_by_list**](docs/PropertymappingsApi.md#propertymappings_provider_scope_used_by_list) | **GET** /propertymappings/provider/scope/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_source_kerberos_create**](docs/PropertymappingsApi.md#propertymappings_source_kerberos_create) | **POST** /propertymappings/source/kerberos/ | +*PropertymappingsApi* | [**propertymappings_source_kerberos_destroy**](docs/PropertymappingsApi.md#propertymappings_source_kerberos_destroy) | **DELETE** /propertymappings/source/kerberos/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_kerberos_list**](docs/PropertymappingsApi.md#propertymappings_source_kerberos_list) | **GET** /propertymappings/source/kerberos/ | +*PropertymappingsApi* | [**propertymappings_source_kerberos_partial_update**](docs/PropertymappingsApi.md#propertymappings_source_kerberos_partial_update) | **PATCH** /propertymappings/source/kerberos/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_kerberos_retrieve**](docs/PropertymappingsApi.md#propertymappings_source_kerberos_retrieve) | **GET** /propertymappings/source/kerberos/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_kerberos_update**](docs/PropertymappingsApi.md#propertymappings_source_kerberos_update) | **PUT** /propertymappings/source/kerberos/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_kerberos_used_by_list**](docs/PropertymappingsApi.md#propertymappings_source_kerberos_used_by_list) | **GET** /propertymappings/source/kerberos/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_source_ldap_create**](docs/PropertymappingsApi.md#propertymappings_source_ldap_create) | **POST** /propertymappings/source/ldap/ | +*PropertymappingsApi* | [**propertymappings_source_ldap_destroy**](docs/PropertymappingsApi.md#propertymappings_source_ldap_destroy) | **DELETE** /propertymappings/source/ldap/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_ldap_list**](docs/PropertymappingsApi.md#propertymappings_source_ldap_list) | **GET** /propertymappings/source/ldap/ | +*PropertymappingsApi* | [**propertymappings_source_ldap_partial_update**](docs/PropertymappingsApi.md#propertymappings_source_ldap_partial_update) | **PATCH** /propertymappings/source/ldap/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_ldap_retrieve**](docs/PropertymappingsApi.md#propertymappings_source_ldap_retrieve) | **GET** /propertymappings/source/ldap/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_ldap_update**](docs/PropertymappingsApi.md#propertymappings_source_ldap_update) | **PUT** /propertymappings/source/ldap/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_ldap_used_by_list**](docs/PropertymappingsApi.md#propertymappings_source_ldap_used_by_list) | **GET** /propertymappings/source/ldap/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_source_oauth_create**](docs/PropertymappingsApi.md#propertymappings_source_oauth_create) | **POST** /propertymappings/source/oauth/ | +*PropertymappingsApi* | [**propertymappings_source_oauth_destroy**](docs/PropertymappingsApi.md#propertymappings_source_oauth_destroy) | **DELETE** /propertymappings/source/oauth/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_oauth_list**](docs/PropertymappingsApi.md#propertymappings_source_oauth_list) | **GET** /propertymappings/source/oauth/ | +*PropertymappingsApi* | [**propertymappings_source_oauth_partial_update**](docs/PropertymappingsApi.md#propertymappings_source_oauth_partial_update) | **PATCH** /propertymappings/source/oauth/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_oauth_retrieve**](docs/PropertymappingsApi.md#propertymappings_source_oauth_retrieve) | **GET** /propertymappings/source/oauth/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_oauth_update**](docs/PropertymappingsApi.md#propertymappings_source_oauth_update) | **PUT** /propertymappings/source/oauth/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_oauth_used_by_list**](docs/PropertymappingsApi.md#propertymappings_source_oauth_used_by_list) | **GET** /propertymappings/source/oauth/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_source_plex_create**](docs/PropertymappingsApi.md#propertymappings_source_plex_create) | **POST** /propertymappings/source/plex/ | +*PropertymappingsApi* | [**propertymappings_source_plex_destroy**](docs/PropertymappingsApi.md#propertymappings_source_plex_destroy) | **DELETE** /propertymappings/source/plex/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_plex_list**](docs/PropertymappingsApi.md#propertymappings_source_plex_list) | **GET** /propertymappings/source/plex/ | +*PropertymappingsApi* | [**propertymappings_source_plex_partial_update**](docs/PropertymappingsApi.md#propertymappings_source_plex_partial_update) | **PATCH** /propertymappings/source/plex/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_plex_retrieve**](docs/PropertymappingsApi.md#propertymappings_source_plex_retrieve) | **GET** /propertymappings/source/plex/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_plex_update**](docs/PropertymappingsApi.md#propertymappings_source_plex_update) | **PUT** /propertymappings/source/plex/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_plex_used_by_list**](docs/PropertymappingsApi.md#propertymappings_source_plex_used_by_list) | **GET** /propertymappings/source/plex/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_source_saml_create**](docs/PropertymappingsApi.md#propertymappings_source_saml_create) | **POST** /propertymappings/source/saml/ | +*PropertymappingsApi* | [**propertymappings_source_saml_destroy**](docs/PropertymappingsApi.md#propertymappings_source_saml_destroy) | **DELETE** /propertymappings/source/saml/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_saml_list**](docs/PropertymappingsApi.md#propertymappings_source_saml_list) | **GET** /propertymappings/source/saml/ | +*PropertymappingsApi* | [**propertymappings_source_saml_partial_update**](docs/PropertymappingsApi.md#propertymappings_source_saml_partial_update) | **PATCH** /propertymappings/source/saml/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_saml_retrieve**](docs/PropertymappingsApi.md#propertymappings_source_saml_retrieve) | **GET** /propertymappings/source/saml/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_saml_update**](docs/PropertymappingsApi.md#propertymappings_source_saml_update) | **PUT** /propertymappings/source/saml/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_saml_used_by_list**](docs/PropertymappingsApi.md#propertymappings_source_saml_used_by_list) | **GET** /propertymappings/source/saml/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_source_scim_create**](docs/PropertymappingsApi.md#propertymappings_source_scim_create) | **POST** /propertymappings/source/scim/ | +*PropertymappingsApi* | [**propertymappings_source_scim_destroy**](docs/PropertymappingsApi.md#propertymappings_source_scim_destroy) | **DELETE** /propertymappings/source/scim/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_scim_list**](docs/PropertymappingsApi.md#propertymappings_source_scim_list) | **GET** /propertymappings/source/scim/ | +*PropertymappingsApi* | [**propertymappings_source_scim_partial_update**](docs/PropertymappingsApi.md#propertymappings_source_scim_partial_update) | **PATCH** /propertymappings/source/scim/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_scim_retrieve**](docs/PropertymappingsApi.md#propertymappings_source_scim_retrieve) | **GET** /propertymappings/source/scim/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_scim_update**](docs/PropertymappingsApi.md#propertymappings_source_scim_update) | **PUT** /propertymappings/source/scim/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_scim_used_by_list**](docs/PropertymappingsApi.md#propertymappings_source_scim_used_by_list) | **GET** /propertymappings/source/scim/{pm_uuid}/used_by/ | +*PropertymappingsApi* | [**propertymappings_source_telegram_create**](docs/PropertymappingsApi.md#propertymappings_source_telegram_create) | **POST** /propertymappings/source/telegram/ | +*PropertymappingsApi* | [**propertymappings_source_telegram_destroy**](docs/PropertymappingsApi.md#propertymappings_source_telegram_destroy) | **DELETE** /propertymappings/source/telegram/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_telegram_list**](docs/PropertymappingsApi.md#propertymappings_source_telegram_list) | **GET** /propertymappings/source/telegram/ | +*PropertymappingsApi* | [**propertymappings_source_telegram_partial_update**](docs/PropertymappingsApi.md#propertymappings_source_telegram_partial_update) | **PATCH** /propertymappings/source/telegram/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_telegram_retrieve**](docs/PropertymappingsApi.md#propertymappings_source_telegram_retrieve) | **GET** /propertymappings/source/telegram/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_telegram_update**](docs/PropertymappingsApi.md#propertymappings_source_telegram_update) | **PUT** /propertymappings/source/telegram/{pm_uuid}/ | +*PropertymappingsApi* | [**propertymappings_source_telegram_used_by_list**](docs/PropertymappingsApi.md#propertymappings_source_telegram_used_by_list) | **GET** /propertymappings/source/telegram/{pm_uuid}/used_by/ | +*ProvidersApi* | [**providers_all_destroy**](docs/ProvidersApi.md#providers_all_destroy) | **DELETE** /providers/all/{id}/ | +*ProvidersApi* | [**providers_all_list**](docs/ProvidersApi.md#providers_all_list) | **GET** /providers/all/ | +*ProvidersApi* | [**providers_all_retrieve**](docs/ProvidersApi.md#providers_all_retrieve) | **GET** /providers/all/{id}/ | +*ProvidersApi* | [**providers_all_types_list**](docs/ProvidersApi.md#providers_all_types_list) | **GET** /providers/all/types/ | +*ProvidersApi* | [**providers_all_used_by_list**](docs/ProvidersApi.md#providers_all_used_by_list) | **GET** /providers/all/{id}/used_by/ | +*ProvidersApi* | [**providers_google_workspace_create**](docs/ProvidersApi.md#providers_google_workspace_create) | **POST** /providers/google_workspace/ | +*ProvidersApi* | [**providers_google_workspace_destroy**](docs/ProvidersApi.md#providers_google_workspace_destroy) | **DELETE** /providers/google_workspace/{id}/ | +*ProvidersApi* | [**providers_google_workspace_groups_create**](docs/ProvidersApi.md#providers_google_workspace_groups_create) | **POST** /providers/google_workspace_groups/ | +*ProvidersApi* | [**providers_google_workspace_groups_destroy**](docs/ProvidersApi.md#providers_google_workspace_groups_destroy) | **DELETE** /providers/google_workspace_groups/{id}/ | +*ProvidersApi* | [**providers_google_workspace_groups_list**](docs/ProvidersApi.md#providers_google_workspace_groups_list) | **GET** /providers/google_workspace_groups/ | +*ProvidersApi* | [**providers_google_workspace_groups_retrieve**](docs/ProvidersApi.md#providers_google_workspace_groups_retrieve) | **GET** /providers/google_workspace_groups/{id}/ | +*ProvidersApi* | [**providers_google_workspace_groups_used_by_list**](docs/ProvidersApi.md#providers_google_workspace_groups_used_by_list) | **GET** /providers/google_workspace_groups/{id}/used_by/ | +*ProvidersApi* | [**providers_google_workspace_list**](docs/ProvidersApi.md#providers_google_workspace_list) | **GET** /providers/google_workspace/ | +*ProvidersApi* | [**providers_google_workspace_partial_update**](docs/ProvidersApi.md#providers_google_workspace_partial_update) | **PATCH** /providers/google_workspace/{id}/ | +*ProvidersApi* | [**providers_google_workspace_retrieve**](docs/ProvidersApi.md#providers_google_workspace_retrieve) | **GET** /providers/google_workspace/{id}/ | +*ProvidersApi* | [**providers_google_workspace_sync_object_create**](docs/ProvidersApi.md#providers_google_workspace_sync_object_create) | **POST** /providers/google_workspace/{id}/sync/object/ | +*ProvidersApi* | [**providers_google_workspace_sync_status_retrieve**](docs/ProvidersApi.md#providers_google_workspace_sync_status_retrieve) | **GET** /providers/google_workspace/{id}/sync/status/ | +*ProvidersApi* | [**providers_google_workspace_update**](docs/ProvidersApi.md#providers_google_workspace_update) | **PUT** /providers/google_workspace/{id}/ | +*ProvidersApi* | [**providers_google_workspace_used_by_list**](docs/ProvidersApi.md#providers_google_workspace_used_by_list) | **GET** /providers/google_workspace/{id}/used_by/ | +*ProvidersApi* | [**providers_google_workspace_users_create**](docs/ProvidersApi.md#providers_google_workspace_users_create) | **POST** /providers/google_workspace_users/ | +*ProvidersApi* | [**providers_google_workspace_users_destroy**](docs/ProvidersApi.md#providers_google_workspace_users_destroy) | **DELETE** /providers/google_workspace_users/{id}/ | +*ProvidersApi* | [**providers_google_workspace_users_list**](docs/ProvidersApi.md#providers_google_workspace_users_list) | **GET** /providers/google_workspace_users/ | +*ProvidersApi* | [**providers_google_workspace_users_retrieve**](docs/ProvidersApi.md#providers_google_workspace_users_retrieve) | **GET** /providers/google_workspace_users/{id}/ | +*ProvidersApi* | [**providers_google_workspace_users_used_by_list**](docs/ProvidersApi.md#providers_google_workspace_users_used_by_list) | **GET** /providers/google_workspace_users/{id}/used_by/ | +*ProvidersApi* | [**providers_ldap_create**](docs/ProvidersApi.md#providers_ldap_create) | **POST** /providers/ldap/ | +*ProvidersApi* | [**providers_ldap_destroy**](docs/ProvidersApi.md#providers_ldap_destroy) | **DELETE** /providers/ldap/{id}/ | +*ProvidersApi* | [**providers_ldap_list**](docs/ProvidersApi.md#providers_ldap_list) | **GET** /providers/ldap/ | +*ProvidersApi* | [**providers_ldap_partial_update**](docs/ProvidersApi.md#providers_ldap_partial_update) | **PATCH** /providers/ldap/{id}/ | +*ProvidersApi* | [**providers_ldap_retrieve**](docs/ProvidersApi.md#providers_ldap_retrieve) | **GET** /providers/ldap/{id}/ | +*ProvidersApi* | [**providers_ldap_update**](docs/ProvidersApi.md#providers_ldap_update) | **PUT** /providers/ldap/{id}/ | +*ProvidersApi* | [**providers_ldap_used_by_list**](docs/ProvidersApi.md#providers_ldap_used_by_list) | **GET** /providers/ldap/{id}/used_by/ | +*ProvidersApi* | [**providers_microsoft_entra_create**](docs/ProvidersApi.md#providers_microsoft_entra_create) | **POST** /providers/microsoft_entra/ | +*ProvidersApi* | [**providers_microsoft_entra_destroy**](docs/ProvidersApi.md#providers_microsoft_entra_destroy) | **DELETE** /providers/microsoft_entra/{id}/ | +*ProvidersApi* | [**providers_microsoft_entra_groups_create**](docs/ProvidersApi.md#providers_microsoft_entra_groups_create) | **POST** /providers/microsoft_entra_groups/ | +*ProvidersApi* | [**providers_microsoft_entra_groups_destroy**](docs/ProvidersApi.md#providers_microsoft_entra_groups_destroy) | **DELETE** /providers/microsoft_entra_groups/{id}/ | +*ProvidersApi* | [**providers_microsoft_entra_groups_list**](docs/ProvidersApi.md#providers_microsoft_entra_groups_list) | **GET** /providers/microsoft_entra_groups/ | +*ProvidersApi* | [**providers_microsoft_entra_groups_retrieve**](docs/ProvidersApi.md#providers_microsoft_entra_groups_retrieve) | **GET** /providers/microsoft_entra_groups/{id}/ | +*ProvidersApi* | [**providers_microsoft_entra_groups_used_by_list**](docs/ProvidersApi.md#providers_microsoft_entra_groups_used_by_list) | **GET** /providers/microsoft_entra_groups/{id}/used_by/ | +*ProvidersApi* | [**providers_microsoft_entra_list**](docs/ProvidersApi.md#providers_microsoft_entra_list) | **GET** /providers/microsoft_entra/ | +*ProvidersApi* | [**providers_microsoft_entra_partial_update**](docs/ProvidersApi.md#providers_microsoft_entra_partial_update) | **PATCH** /providers/microsoft_entra/{id}/ | +*ProvidersApi* | [**providers_microsoft_entra_retrieve**](docs/ProvidersApi.md#providers_microsoft_entra_retrieve) | **GET** /providers/microsoft_entra/{id}/ | +*ProvidersApi* | [**providers_microsoft_entra_sync_object_create**](docs/ProvidersApi.md#providers_microsoft_entra_sync_object_create) | **POST** /providers/microsoft_entra/{id}/sync/object/ | +*ProvidersApi* | [**providers_microsoft_entra_sync_status_retrieve**](docs/ProvidersApi.md#providers_microsoft_entra_sync_status_retrieve) | **GET** /providers/microsoft_entra/{id}/sync/status/ | +*ProvidersApi* | [**providers_microsoft_entra_update**](docs/ProvidersApi.md#providers_microsoft_entra_update) | **PUT** /providers/microsoft_entra/{id}/ | +*ProvidersApi* | [**providers_microsoft_entra_used_by_list**](docs/ProvidersApi.md#providers_microsoft_entra_used_by_list) | **GET** /providers/microsoft_entra/{id}/used_by/ | +*ProvidersApi* | [**providers_microsoft_entra_users_create**](docs/ProvidersApi.md#providers_microsoft_entra_users_create) | **POST** /providers/microsoft_entra_users/ | +*ProvidersApi* | [**providers_microsoft_entra_users_destroy**](docs/ProvidersApi.md#providers_microsoft_entra_users_destroy) | **DELETE** /providers/microsoft_entra_users/{id}/ | +*ProvidersApi* | [**providers_microsoft_entra_users_list**](docs/ProvidersApi.md#providers_microsoft_entra_users_list) | **GET** /providers/microsoft_entra_users/ | +*ProvidersApi* | [**providers_microsoft_entra_users_retrieve**](docs/ProvidersApi.md#providers_microsoft_entra_users_retrieve) | **GET** /providers/microsoft_entra_users/{id}/ | +*ProvidersApi* | [**providers_microsoft_entra_users_used_by_list**](docs/ProvidersApi.md#providers_microsoft_entra_users_used_by_list) | **GET** /providers/microsoft_entra_users/{id}/used_by/ | +*ProvidersApi* | [**providers_oauth2_create**](docs/ProvidersApi.md#providers_oauth2_create) | **POST** /providers/oauth2/ | +*ProvidersApi* | [**providers_oauth2_destroy**](docs/ProvidersApi.md#providers_oauth2_destroy) | **DELETE** /providers/oauth2/{id}/ | +*ProvidersApi* | [**providers_oauth2_list**](docs/ProvidersApi.md#providers_oauth2_list) | **GET** /providers/oauth2/ | +*ProvidersApi* | [**providers_oauth2_partial_update**](docs/ProvidersApi.md#providers_oauth2_partial_update) | **PATCH** /providers/oauth2/{id}/ | +*ProvidersApi* | [**providers_oauth2_preview_user_retrieve**](docs/ProvidersApi.md#providers_oauth2_preview_user_retrieve) | **GET** /providers/oauth2/{id}/preview_user/ | +*ProvidersApi* | [**providers_oauth2_retrieve**](docs/ProvidersApi.md#providers_oauth2_retrieve) | **GET** /providers/oauth2/{id}/ | +*ProvidersApi* | [**providers_oauth2_setup_urls_retrieve**](docs/ProvidersApi.md#providers_oauth2_setup_urls_retrieve) | **GET** /providers/oauth2/{id}/setup_urls/ | +*ProvidersApi* | [**providers_oauth2_update**](docs/ProvidersApi.md#providers_oauth2_update) | **PUT** /providers/oauth2/{id}/ | +*ProvidersApi* | [**providers_oauth2_used_by_list**](docs/ProvidersApi.md#providers_oauth2_used_by_list) | **GET** /providers/oauth2/{id}/used_by/ | +*ProvidersApi* | [**providers_proxy_create**](docs/ProvidersApi.md#providers_proxy_create) | **POST** /providers/proxy/ | +*ProvidersApi* | [**providers_proxy_destroy**](docs/ProvidersApi.md#providers_proxy_destroy) | **DELETE** /providers/proxy/{id}/ | +*ProvidersApi* | [**providers_proxy_list**](docs/ProvidersApi.md#providers_proxy_list) | **GET** /providers/proxy/ | +*ProvidersApi* | [**providers_proxy_partial_update**](docs/ProvidersApi.md#providers_proxy_partial_update) | **PATCH** /providers/proxy/{id}/ | +*ProvidersApi* | [**providers_proxy_retrieve**](docs/ProvidersApi.md#providers_proxy_retrieve) | **GET** /providers/proxy/{id}/ | +*ProvidersApi* | [**providers_proxy_update**](docs/ProvidersApi.md#providers_proxy_update) | **PUT** /providers/proxy/{id}/ | +*ProvidersApi* | [**providers_proxy_used_by_list**](docs/ProvidersApi.md#providers_proxy_used_by_list) | **GET** /providers/proxy/{id}/used_by/ | +*ProvidersApi* | [**providers_rac_create**](docs/ProvidersApi.md#providers_rac_create) | **POST** /providers/rac/ | +*ProvidersApi* | [**providers_rac_destroy**](docs/ProvidersApi.md#providers_rac_destroy) | **DELETE** /providers/rac/{id}/ | +*ProvidersApi* | [**providers_rac_list**](docs/ProvidersApi.md#providers_rac_list) | **GET** /providers/rac/ | +*ProvidersApi* | [**providers_rac_partial_update**](docs/ProvidersApi.md#providers_rac_partial_update) | **PATCH** /providers/rac/{id}/ | +*ProvidersApi* | [**providers_rac_retrieve**](docs/ProvidersApi.md#providers_rac_retrieve) | **GET** /providers/rac/{id}/ | +*ProvidersApi* | [**providers_rac_update**](docs/ProvidersApi.md#providers_rac_update) | **PUT** /providers/rac/{id}/ | +*ProvidersApi* | [**providers_rac_used_by_list**](docs/ProvidersApi.md#providers_rac_used_by_list) | **GET** /providers/rac/{id}/used_by/ | +*ProvidersApi* | [**providers_radius_create**](docs/ProvidersApi.md#providers_radius_create) | **POST** /providers/radius/ | +*ProvidersApi* | [**providers_radius_destroy**](docs/ProvidersApi.md#providers_radius_destroy) | **DELETE** /providers/radius/{id}/ | +*ProvidersApi* | [**providers_radius_list**](docs/ProvidersApi.md#providers_radius_list) | **GET** /providers/radius/ | +*ProvidersApi* | [**providers_radius_partial_update**](docs/ProvidersApi.md#providers_radius_partial_update) | **PATCH** /providers/radius/{id}/ | +*ProvidersApi* | [**providers_radius_retrieve**](docs/ProvidersApi.md#providers_radius_retrieve) | **GET** /providers/radius/{id}/ | +*ProvidersApi* | [**providers_radius_update**](docs/ProvidersApi.md#providers_radius_update) | **PUT** /providers/radius/{id}/ | +*ProvidersApi* | [**providers_radius_used_by_list**](docs/ProvidersApi.md#providers_radius_used_by_list) | **GET** /providers/radius/{id}/used_by/ | +*ProvidersApi* | [**providers_saml_create**](docs/ProvidersApi.md#providers_saml_create) | **POST** /providers/saml/ | +*ProvidersApi* | [**providers_saml_destroy**](docs/ProvidersApi.md#providers_saml_destroy) | **DELETE** /providers/saml/{id}/ | +*ProvidersApi* | [**providers_saml_import_metadata_create**](docs/ProvidersApi.md#providers_saml_import_metadata_create) | **POST** /providers/saml/import_metadata/ | +*ProvidersApi* | [**providers_saml_list**](docs/ProvidersApi.md#providers_saml_list) | **GET** /providers/saml/ | +*ProvidersApi* | [**providers_saml_metadata_retrieve**](docs/ProvidersApi.md#providers_saml_metadata_retrieve) | **GET** /providers/saml/{id}/metadata/ | +*ProvidersApi* | [**providers_saml_partial_update**](docs/ProvidersApi.md#providers_saml_partial_update) | **PATCH** /providers/saml/{id}/ | +*ProvidersApi* | [**providers_saml_preview_user_retrieve**](docs/ProvidersApi.md#providers_saml_preview_user_retrieve) | **GET** /providers/saml/{id}/preview_user/ | +*ProvidersApi* | [**providers_saml_retrieve**](docs/ProvidersApi.md#providers_saml_retrieve) | **GET** /providers/saml/{id}/ | +*ProvidersApi* | [**providers_saml_update**](docs/ProvidersApi.md#providers_saml_update) | **PUT** /providers/saml/{id}/ | +*ProvidersApi* | [**providers_saml_used_by_list**](docs/ProvidersApi.md#providers_saml_used_by_list) | **GET** /providers/saml/{id}/used_by/ | +*ProvidersApi* | [**providers_scim_create**](docs/ProvidersApi.md#providers_scim_create) | **POST** /providers/scim/ | +*ProvidersApi* | [**providers_scim_destroy**](docs/ProvidersApi.md#providers_scim_destroy) | **DELETE** /providers/scim/{id}/ | +*ProvidersApi* | [**providers_scim_groups_create**](docs/ProvidersApi.md#providers_scim_groups_create) | **POST** /providers/scim_groups/ | +*ProvidersApi* | [**providers_scim_groups_destroy**](docs/ProvidersApi.md#providers_scim_groups_destroy) | **DELETE** /providers/scim_groups/{id}/ | +*ProvidersApi* | [**providers_scim_groups_list**](docs/ProvidersApi.md#providers_scim_groups_list) | **GET** /providers/scim_groups/ | +*ProvidersApi* | [**providers_scim_groups_retrieve**](docs/ProvidersApi.md#providers_scim_groups_retrieve) | **GET** /providers/scim_groups/{id}/ | +*ProvidersApi* | [**providers_scim_groups_used_by_list**](docs/ProvidersApi.md#providers_scim_groups_used_by_list) | **GET** /providers/scim_groups/{id}/used_by/ | +*ProvidersApi* | [**providers_scim_list**](docs/ProvidersApi.md#providers_scim_list) | **GET** /providers/scim/ | +*ProvidersApi* | [**providers_scim_partial_update**](docs/ProvidersApi.md#providers_scim_partial_update) | **PATCH** /providers/scim/{id}/ | +*ProvidersApi* | [**providers_scim_retrieve**](docs/ProvidersApi.md#providers_scim_retrieve) | **GET** /providers/scim/{id}/ | +*ProvidersApi* | [**providers_scim_sync_object_create**](docs/ProvidersApi.md#providers_scim_sync_object_create) | **POST** /providers/scim/{id}/sync/object/ | +*ProvidersApi* | [**providers_scim_sync_status_retrieve**](docs/ProvidersApi.md#providers_scim_sync_status_retrieve) | **GET** /providers/scim/{id}/sync/status/ | +*ProvidersApi* | [**providers_scim_update**](docs/ProvidersApi.md#providers_scim_update) | **PUT** /providers/scim/{id}/ | +*ProvidersApi* | [**providers_scim_used_by_list**](docs/ProvidersApi.md#providers_scim_used_by_list) | **GET** /providers/scim/{id}/used_by/ | +*ProvidersApi* | [**providers_scim_users_create**](docs/ProvidersApi.md#providers_scim_users_create) | **POST** /providers/scim_users/ | +*ProvidersApi* | [**providers_scim_users_destroy**](docs/ProvidersApi.md#providers_scim_users_destroy) | **DELETE** /providers/scim_users/{id}/ | +*ProvidersApi* | [**providers_scim_users_list**](docs/ProvidersApi.md#providers_scim_users_list) | **GET** /providers/scim_users/ | +*ProvidersApi* | [**providers_scim_users_retrieve**](docs/ProvidersApi.md#providers_scim_users_retrieve) | **GET** /providers/scim_users/{id}/ | +*ProvidersApi* | [**providers_scim_users_used_by_list**](docs/ProvidersApi.md#providers_scim_users_used_by_list) | **GET** /providers/scim_users/{id}/used_by/ | +*ProvidersApi* | [**providers_ssf_create**](docs/ProvidersApi.md#providers_ssf_create) | **POST** /providers/ssf/ | +*ProvidersApi* | [**providers_ssf_destroy**](docs/ProvidersApi.md#providers_ssf_destroy) | **DELETE** /providers/ssf/{id}/ | +*ProvidersApi* | [**providers_ssf_list**](docs/ProvidersApi.md#providers_ssf_list) | **GET** /providers/ssf/ | +*ProvidersApi* | [**providers_ssf_partial_update**](docs/ProvidersApi.md#providers_ssf_partial_update) | **PATCH** /providers/ssf/{id}/ | +*ProvidersApi* | [**providers_ssf_retrieve**](docs/ProvidersApi.md#providers_ssf_retrieve) | **GET** /providers/ssf/{id}/ | +*ProvidersApi* | [**providers_ssf_update**](docs/ProvidersApi.md#providers_ssf_update) | **PUT** /providers/ssf/{id}/ | +*ProvidersApi* | [**providers_ssf_used_by_list**](docs/ProvidersApi.md#providers_ssf_used_by_list) | **GET** /providers/ssf/{id}/used_by/ | +*ProvidersApi* | [**providers_wsfed_create**](docs/ProvidersApi.md#providers_wsfed_create) | **POST** /providers/wsfed/ | +*ProvidersApi* | [**providers_wsfed_destroy**](docs/ProvidersApi.md#providers_wsfed_destroy) | **DELETE** /providers/wsfed/{id}/ | +*ProvidersApi* | [**providers_wsfed_list**](docs/ProvidersApi.md#providers_wsfed_list) | **GET** /providers/wsfed/ | +*ProvidersApi* | [**providers_wsfed_metadata_retrieve**](docs/ProvidersApi.md#providers_wsfed_metadata_retrieve) | **GET** /providers/wsfed/{id}/metadata/ | +*ProvidersApi* | [**providers_wsfed_partial_update**](docs/ProvidersApi.md#providers_wsfed_partial_update) | **PATCH** /providers/wsfed/{id}/ | +*ProvidersApi* | [**providers_wsfed_preview_user_retrieve**](docs/ProvidersApi.md#providers_wsfed_preview_user_retrieve) | **GET** /providers/wsfed/{id}/preview_user/ | +*ProvidersApi* | [**providers_wsfed_retrieve**](docs/ProvidersApi.md#providers_wsfed_retrieve) | **GET** /providers/wsfed/{id}/ | +*ProvidersApi* | [**providers_wsfed_update**](docs/ProvidersApi.md#providers_wsfed_update) | **PUT** /providers/wsfed/{id}/ | +*ProvidersApi* | [**providers_wsfed_used_by_list**](docs/ProvidersApi.md#providers_wsfed_used_by_list) | **GET** /providers/wsfed/{id}/used_by/ | +*RacApi* | [**rac_connection_tokens_destroy**](docs/RacApi.md#rac_connection_tokens_destroy) | **DELETE** /rac/connection_tokens/{connection_token_uuid}/ | +*RacApi* | [**rac_connection_tokens_list**](docs/RacApi.md#rac_connection_tokens_list) | **GET** /rac/connection_tokens/ | +*RacApi* | [**rac_connection_tokens_partial_update**](docs/RacApi.md#rac_connection_tokens_partial_update) | **PATCH** /rac/connection_tokens/{connection_token_uuid}/ | +*RacApi* | [**rac_connection_tokens_retrieve**](docs/RacApi.md#rac_connection_tokens_retrieve) | **GET** /rac/connection_tokens/{connection_token_uuid}/ | +*RacApi* | [**rac_connection_tokens_update**](docs/RacApi.md#rac_connection_tokens_update) | **PUT** /rac/connection_tokens/{connection_token_uuid}/ | +*RacApi* | [**rac_connection_tokens_used_by_list**](docs/RacApi.md#rac_connection_tokens_used_by_list) | **GET** /rac/connection_tokens/{connection_token_uuid}/used_by/ | +*RacApi* | [**rac_endpoints_create**](docs/RacApi.md#rac_endpoints_create) | **POST** /rac/endpoints/ | +*RacApi* | [**rac_endpoints_destroy**](docs/RacApi.md#rac_endpoints_destroy) | **DELETE** /rac/endpoints/{pbm_uuid}/ | +*RacApi* | [**rac_endpoints_list**](docs/RacApi.md#rac_endpoints_list) | **GET** /rac/endpoints/ | +*RacApi* | [**rac_endpoints_partial_update**](docs/RacApi.md#rac_endpoints_partial_update) | **PATCH** /rac/endpoints/{pbm_uuid}/ | +*RacApi* | [**rac_endpoints_retrieve**](docs/RacApi.md#rac_endpoints_retrieve) | **GET** /rac/endpoints/{pbm_uuid}/ | +*RacApi* | [**rac_endpoints_update**](docs/RacApi.md#rac_endpoints_update) | **PUT** /rac/endpoints/{pbm_uuid}/ | +*RacApi* | [**rac_endpoints_used_by_list**](docs/RacApi.md#rac_endpoints_used_by_list) | **GET** /rac/endpoints/{pbm_uuid}/used_by/ | +*RbacApi* | [**rbac_initial_permissions_create**](docs/RbacApi.md#rbac_initial_permissions_create) | **POST** /rbac/initial_permissions/ | +*RbacApi* | [**rbac_initial_permissions_destroy**](docs/RbacApi.md#rbac_initial_permissions_destroy) | **DELETE** /rbac/initial_permissions/{id}/ | +*RbacApi* | [**rbac_initial_permissions_list**](docs/RbacApi.md#rbac_initial_permissions_list) | **GET** /rbac/initial_permissions/ | +*RbacApi* | [**rbac_initial_permissions_partial_update**](docs/RbacApi.md#rbac_initial_permissions_partial_update) | **PATCH** /rbac/initial_permissions/{id}/ | +*RbacApi* | [**rbac_initial_permissions_retrieve**](docs/RbacApi.md#rbac_initial_permissions_retrieve) | **GET** /rbac/initial_permissions/{id}/ | +*RbacApi* | [**rbac_initial_permissions_update**](docs/RbacApi.md#rbac_initial_permissions_update) | **PUT** /rbac/initial_permissions/{id}/ | +*RbacApi* | [**rbac_initial_permissions_used_by_list**](docs/RbacApi.md#rbac_initial_permissions_used_by_list) | **GET** /rbac/initial_permissions/{id}/used_by/ | +*RbacApi* | [**rbac_permissions_assigned_by_roles_assign**](docs/RbacApi.md#rbac_permissions_assigned_by_roles_assign) | **POST** /rbac/permissions/assigned_by_roles/{uuid}/assign/ | +*RbacApi* | [**rbac_permissions_assigned_by_roles_list**](docs/RbacApi.md#rbac_permissions_assigned_by_roles_list) | **GET** /rbac/permissions/assigned_by_roles/ | +*RbacApi* | [**rbac_permissions_assigned_by_roles_unassign_partial_update**](docs/RbacApi.md#rbac_permissions_assigned_by_roles_unassign_partial_update) | **PATCH** /rbac/permissions/assigned_by_roles/{uuid}/unassign/ | +*RbacApi* | [**rbac_permissions_list**](docs/RbacApi.md#rbac_permissions_list) | **GET** /rbac/permissions/ | +*RbacApi* | [**rbac_permissions_retrieve**](docs/RbacApi.md#rbac_permissions_retrieve) | **GET** /rbac/permissions/{id}/ | +*RbacApi* | [**rbac_permissions_roles_list**](docs/RbacApi.md#rbac_permissions_roles_list) | **GET** /rbac/permissions/roles/ | +*RbacApi* | [**rbac_roles_add_user_create**](docs/RbacApi.md#rbac_roles_add_user_create) | **POST** /rbac/roles/{uuid}/add_user/ | +*RbacApi* | [**rbac_roles_create**](docs/RbacApi.md#rbac_roles_create) | **POST** /rbac/roles/ | +*RbacApi* | [**rbac_roles_destroy**](docs/RbacApi.md#rbac_roles_destroy) | **DELETE** /rbac/roles/{uuid}/ | +*RbacApi* | [**rbac_roles_list**](docs/RbacApi.md#rbac_roles_list) | **GET** /rbac/roles/ | +*RbacApi* | [**rbac_roles_partial_update**](docs/RbacApi.md#rbac_roles_partial_update) | **PATCH** /rbac/roles/{uuid}/ | +*RbacApi* | [**rbac_roles_remove_user_create**](docs/RbacApi.md#rbac_roles_remove_user_create) | **POST** /rbac/roles/{uuid}/remove_user/ | +*RbacApi* | [**rbac_roles_retrieve**](docs/RbacApi.md#rbac_roles_retrieve) | **GET** /rbac/roles/{uuid}/ | +*RbacApi* | [**rbac_roles_update**](docs/RbacApi.md#rbac_roles_update) | **PUT** /rbac/roles/{uuid}/ | +*RbacApi* | [**rbac_roles_used_by_list**](docs/RbacApi.md#rbac_roles_used_by_list) | **GET** /rbac/roles/{uuid}/used_by/ | +*ReportsApi* | [**reports_exports_destroy**](docs/ReportsApi.md#reports_exports_destroy) | **DELETE** /reports/exports/{id}/ | +*ReportsApi* | [**reports_exports_list**](docs/ReportsApi.md#reports_exports_list) | **GET** /reports/exports/ | +*ReportsApi* | [**reports_exports_retrieve**](docs/ReportsApi.md#reports_exports_retrieve) | **GET** /reports/exports/{id}/ | +*RootApi* | [**root_config_retrieve**](docs/RootApi.md#root_config_retrieve) | **GET** /root/config/ | +*SchemaApi* | [**schema_retrieve**](docs/SchemaApi.md#schema_retrieve) | **GET** /schema/ | +*SourcesApi* | [**sources_all_destroy**](docs/SourcesApi.md#sources_all_destroy) | **DELETE** /sources/all/{slug}/ | +*SourcesApi* | [**sources_all_list**](docs/SourcesApi.md#sources_all_list) | **GET** /sources/all/ | +*SourcesApi* | [**sources_all_retrieve**](docs/SourcesApi.md#sources_all_retrieve) | **GET** /sources/all/{slug}/ | +*SourcesApi* | [**sources_all_types_list**](docs/SourcesApi.md#sources_all_types_list) | **GET** /sources/all/types/ | +*SourcesApi* | [**sources_all_used_by_list**](docs/SourcesApi.md#sources_all_used_by_list) | **GET** /sources/all/{slug}/used_by/ | +*SourcesApi* | [**sources_all_user_settings_list**](docs/SourcesApi.md#sources_all_user_settings_list) | **GET** /sources/all/user_settings/ | +*SourcesApi* | [**sources_group_connections_all_destroy**](docs/SourcesApi.md#sources_group_connections_all_destroy) | **DELETE** /sources/group_connections/all/{id}/ | +*SourcesApi* | [**sources_group_connections_all_list**](docs/SourcesApi.md#sources_group_connections_all_list) | **GET** /sources/group_connections/all/ | +*SourcesApi* | [**sources_group_connections_all_partial_update**](docs/SourcesApi.md#sources_group_connections_all_partial_update) | **PATCH** /sources/group_connections/all/{id}/ | +*SourcesApi* | [**sources_group_connections_all_retrieve**](docs/SourcesApi.md#sources_group_connections_all_retrieve) | **GET** /sources/group_connections/all/{id}/ | +*SourcesApi* | [**sources_group_connections_all_update**](docs/SourcesApi.md#sources_group_connections_all_update) | **PUT** /sources/group_connections/all/{id}/ | +*SourcesApi* | [**sources_group_connections_all_used_by_list**](docs/SourcesApi.md#sources_group_connections_all_used_by_list) | **GET** /sources/group_connections/all/{id}/used_by/ | +*SourcesApi* | [**sources_group_connections_kerberos_create**](docs/SourcesApi.md#sources_group_connections_kerberos_create) | **POST** /sources/group_connections/kerberos/ | +*SourcesApi* | [**sources_group_connections_kerberos_destroy**](docs/SourcesApi.md#sources_group_connections_kerberos_destroy) | **DELETE** /sources/group_connections/kerberos/{id}/ | +*SourcesApi* | [**sources_group_connections_kerberos_list**](docs/SourcesApi.md#sources_group_connections_kerberos_list) | **GET** /sources/group_connections/kerberos/ | +*SourcesApi* | [**sources_group_connections_kerberos_partial_update**](docs/SourcesApi.md#sources_group_connections_kerberos_partial_update) | **PATCH** /sources/group_connections/kerberos/{id}/ | +*SourcesApi* | [**sources_group_connections_kerberos_retrieve**](docs/SourcesApi.md#sources_group_connections_kerberos_retrieve) | **GET** /sources/group_connections/kerberos/{id}/ | +*SourcesApi* | [**sources_group_connections_kerberos_update**](docs/SourcesApi.md#sources_group_connections_kerberos_update) | **PUT** /sources/group_connections/kerberos/{id}/ | +*SourcesApi* | [**sources_group_connections_kerberos_used_by_list**](docs/SourcesApi.md#sources_group_connections_kerberos_used_by_list) | **GET** /sources/group_connections/kerberos/{id}/used_by/ | +*SourcesApi* | [**sources_group_connections_ldap_create**](docs/SourcesApi.md#sources_group_connections_ldap_create) | **POST** /sources/group_connections/ldap/ | +*SourcesApi* | [**sources_group_connections_ldap_destroy**](docs/SourcesApi.md#sources_group_connections_ldap_destroy) | **DELETE** /sources/group_connections/ldap/{id}/ | +*SourcesApi* | [**sources_group_connections_ldap_list**](docs/SourcesApi.md#sources_group_connections_ldap_list) | **GET** /sources/group_connections/ldap/ | +*SourcesApi* | [**sources_group_connections_ldap_partial_update**](docs/SourcesApi.md#sources_group_connections_ldap_partial_update) | **PATCH** /sources/group_connections/ldap/{id}/ | +*SourcesApi* | [**sources_group_connections_ldap_retrieve**](docs/SourcesApi.md#sources_group_connections_ldap_retrieve) | **GET** /sources/group_connections/ldap/{id}/ | +*SourcesApi* | [**sources_group_connections_ldap_update**](docs/SourcesApi.md#sources_group_connections_ldap_update) | **PUT** /sources/group_connections/ldap/{id}/ | +*SourcesApi* | [**sources_group_connections_ldap_used_by_list**](docs/SourcesApi.md#sources_group_connections_ldap_used_by_list) | **GET** /sources/group_connections/ldap/{id}/used_by/ | +*SourcesApi* | [**sources_group_connections_oauth_create**](docs/SourcesApi.md#sources_group_connections_oauth_create) | **POST** /sources/group_connections/oauth/ | +*SourcesApi* | [**sources_group_connections_oauth_destroy**](docs/SourcesApi.md#sources_group_connections_oauth_destroy) | **DELETE** /sources/group_connections/oauth/{id}/ | +*SourcesApi* | [**sources_group_connections_oauth_list**](docs/SourcesApi.md#sources_group_connections_oauth_list) | **GET** /sources/group_connections/oauth/ | +*SourcesApi* | [**sources_group_connections_oauth_partial_update**](docs/SourcesApi.md#sources_group_connections_oauth_partial_update) | **PATCH** /sources/group_connections/oauth/{id}/ | +*SourcesApi* | [**sources_group_connections_oauth_retrieve**](docs/SourcesApi.md#sources_group_connections_oauth_retrieve) | **GET** /sources/group_connections/oauth/{id}/ | +*SourcesApi* | [**sources_group_connections_oauth_update**](docs/SourcesApi.md#sources_group_connections_oauth_update) | **PUT** /sources/group_connections/oauth/{id}/ | +*SourcesApi* | [**sources_group_connections_oauth_used_by_list**](docs/SourcesApi.md#sources_group_connections_oauth_used_by_list) | **GET** /sources/group_connections/oauth/{id}/used_by/ | +*SourcesApi* | [**sources_group_connections_plex_create**](docs/SourcesApi.md#sources_group_connections_plex_create) | **POST** /sources/group_connections/plex/ | +*SourcesApi* | [**sources_group_connections_plex_destroy**](docs/SourcesApi.md#sources_group_connections_plex_destroy) | **DELETE** /sources/group_connections/plex/{id}/ | +*SourcesApi* | [**sources_group_connections_plex_list**](docs/SourcesApi.md#sources_group_connections_plex_list) | **GET** /sources/group_connections/plex/ | +*SourcesApi* | [**sources_group_connections_plex_partial_update**](docs/SourcesApi.md#sources_group_connections_plex_partial_update) | **PATCH** /sources/group_connections/plex/{id}/ | +*SourcesApi* | [**sources_group_connections_plex_retrieve**](docs/SourcesApi.md#sources_group_connections_plex_retrieve) | **GET** /sources/group_connections/plex/{id}/ | +*SourcesApi* | [**sources_group_connections_plex_update**](docs/SourcesApi.md#sources_group_connections_plex_update) | **PUT** /sources/group_connections/plex/{id}/ | +*SourcesApi* | [**sources_group_connections_plex_used_by_list**](docs/SourcesApi.md#sources_group_connections_plex_used_by_list) | **GET** /sources/group_connections/plex/{id}/used_by/ | +*SourcesApi* | [**sources_group_connections_saml_create**](docs/SourcesApi.md#sources_group_connections_saml_create) | **POST** /sources/group_connections/saml/ | +*SourcesApi* | [**sources_group_connections_saml_destroy**](docs/SourcesApi.md#sources_group_connections_saml_destroy) | **DELETE** /sources/group_connections/saml/{id}/ | +*SourcesApi* | [**sources_group_connections_saml_list**](docs/SourcesApi.md#sources_group_connections_saml_list) | **GET** /sources/group_connections/saml/ | +*SourcesApi* | [**sources_group_connections_saml_partial_update**](docs/SourcesApi.md#sources_group_connections_saml_partial_update) | **PATCH** /sources/group_connections/saml/{id}/ | +*SourcesApi* | [**sources_group_connections_saml_retrieve**](docs/SourcesApi.md#sources_group_connections_saml_retrieve) | **GET** /sources/group_connections/saml/{id}/ | +*SourcesApi* | [**sources_group_connections_saml_update**](docs/SourcesApi.md#sources_group_connections_saml_update) | **PUT** /sources/group_connections/saml/{id}/ | +*SourcesApi* | [**sources_group_connections_saml_used_by_list**](docs/SourcesApi.md#sources_group_connections_saml_used_by_list) | **GET** /sources/group_connections/saml/{id}/used_by/ | +*SourcesApi* | [**sources_group_connections_telegram_create**](docs/SourcesApi.md#sources_group_connections_telegram_create) | **POST** /sources/group_connections/telegram/ | +*SourcesApi* | [**sources_group_connections_telegram_destroy**](docs/SourcesApi.md#sources_group_connections_telegram_destroy) | **DELETE** /sources/group_connections/telegram/{id}/ | +*SourcesApi* | [**sources_group_connections_telegram_list**](docs/SourcesApi.md#sources_group_connections_telegram_list) | **GET** /sources/group_connections/telegram/ | +*SourcesApi* | [**sources_group_connections_telegram_partial_update**](docs/SourcesApi.md#sources_group_connections_telegram_partial_update) | **PATCH** /sources/group_connections/telegram/{id}/ | +*SourcesApi* | [**sources_group_connections_telegram_retrieve**](docs/SourcesApi.md#sources_group_connections_telegram_retrieve) | **GET** /sources/group_connections/telegram/{id}/ | +*SourcesApi* | [**sources_group_connections_telegram_update**](docs/SourcesApi.md#sources_group_connections_telegram_update) | **PUT** /sources/group_connections/telegram/{id}/ | +*SourcesApi* | [**sources_group_connections_telegram_used_by_list**](docs/SourcesApi.md#sources_group_connections_telegram_used_by_list) | **GET** /sources/group_connections/telegram/{id}/used_by/ | +*SourcesApi* | [**sources_kerberos_create**](docs/SourcesApi.md#sources_kerberos_create) | **POST** /sources/kerberos/ | +*SourcesApi* | [**sources_kerberos_destroy**](docs/SourcesApi.md#sources_kerberos_destroy) | **DELETE** /sources/kerberos/{slug}/ | +*SourcesApi* | [**sources_kerberos_list**](docs/SourcesApi.md#sources_kerberos_list) | **GET** /sources/kerberos/ | +*SourcesApi* | [**sources_kerberos_partial_update**](docs/SourcesApi.md#sources_kerberos_partial_update) | **PATCH** /sources/kerberos/{slug}/ | +*SourcesApi* | [**sources_kerberos_retrieve**](docs/SourcesApi.md#sources_kerberos_retrieve) | **GET** /sources/kerberos/{slug}/ | +*SourcesApi* | [**sources_kerberos_sync_status_retrieve**](docs/SourcesApi.md#sources_kerberos_sync_status_retrieve) | **GET** /sources/kerberos/{slug}/sync/status/ | +*SourcesApi* | [**sources_kerberos_update**](docs/SourcesApi.md#sources_kerberos_update) | **PUT** /sources/kerberos/{slug}/ | +*SourcesApi* | [**sources_kerberos_used_by_list**](docs/SourcesApi.md#sources_kerberos_used_by_list) | **GET** /sources/kerberos/{slug}/used_by/ | +*SourcesApi* | [**sources_ldap_create**](docs/SourcesApi.md#sources_ldap_create) | **POST** /sources/ldap/ | +*SourcesApi* | [**sources_ldap_debug_retrieve**](docs/SourcesApi.md#sources_ldap_debug_retrieve) | **GET** /sources/ldap/{slug}/debug/ | +*SourcesApi* | [**sources_ldap_destroy**](docs/SourcesApi.md#sources_ldap_destroy) | **DELETE** /sources/ldap/{slug}/ | +*SourcesApi* | [**sources_ldap_list**](docs/SourcesApi.md#sources_ldap_list) | **GET** /sources/ldap/ | +*SourcesApi* | [**sources_ldap_partial_update**](docs/SourcesApi.md#sources_ldap_partial_update) | **PATCH** /sources/ldap/{slug}/ | +*SourcesApi* | [**sources_ldap_retrieve**](docs/SourcesApi.md#sources_ldap_retrieve) | **GET** /sources/ldap/{slug}/ | +*SourcesApi* | [**sources_ldap_sync_status_retrieve**](docs/SourcesApi.md#sources_ldap_sync_status_retrieve) | **GET** /sources/ldap/{slug}/sync/status/ | +*SourcesApi* | [**sources_ldap_update**](docs/SourcesApi.md#sources_ldap_update) | **PUT** /sources/ldap/{slug}/ | +*SourcesApi* | [**sources_ldap_used_by_list**](docs/SourcesApi.md#sources_ldap_used_by_list) | **GET** /sources/ldap/{slug}/used_by/ | +*SourcesApi* | [**sources_oauth_create**](docs/SourcesApi.md#sources_oauth_create) | **POST** /sources/oauth/ | +*SourcesApi* | [**sources_oauth_destroy**](docs/SourcesApi.md#sources_oauth_destroy) | **DELETE** /sources/oauth/{slug}/ | +*SourcesApi* | [**sources_oauth_list**](docs/SourcesApi.md#sources_oauth_list) | **GET** /sources/oauth/ | +*SourcesApi* | [**sources_oauth_partial_update**](docs/SourcesApi.md#sources_oauth_partial_update) | **PATCH** /sources/oauth/{slug}/ | +*SourcesApi* | [**sources_oauth_retrieve**](docs/SourcesApi.md#sources_oauth_retrieve) | **GET** /sources/oauth/{slug}/ | +*SourcesApi* | [**sources_oauth_source_types_list**](docs/SourcesApi.md#sources_oauth_source_types_list) | **GET** /sources/oauth/source_types/ | +*SourcesApi* | [**sources_oauth_update**](docs/SourcesApi.md#sources_oauth_update) | **PUT** /sources/oauth/{slug}/ | +*SourcesApi* | [**sources_oauth_used_by_list**](docs/SourcesApi.md#sources_oauth_used_by_list) | **GET** /sources/oauth/{slug}/used_by/ | +*SourcesApi* | [**sources_plex_create**](docs/SourcesApi.md#sources_plex_create) | **POST** /sources/plex/ | +*SourcesApi* | [**sources_plex_destroy**](docs/SourcesApi.md#sources_plex_destroy) | **DELETE** /sources/plex/{slug}/ | +*SourcesApi* | [**sources_plex_list**](docs/SourcesApi.md#sources_plex_list) | **GET** /sources/plex/ | +*SourcesApi* | [**sources_plex_partial_update**](docs/SourcesApi.md#sources_plex_partial_update) | **PATCH** /sources/plex/{slug}/ | +*SourcesApi* | [**sources_plex_redeem_token_authenticated_create**](docs/SourcesApi.md#sources_plex_redeem_token_authenticated_create) | **POST** /sources/plex/redeem_token_authenticated/ | +*SourcesApi* | [**sources_plex_redeem_token_create**](docs/SourcesApi.md#sources_plex_redeem_token_create) | **POST** /sources/plex/redeem_token/ | +*SourcesApi* | [**sources_plex_retrieve**](docs/SourcesApi.md#sources_plex_retrieve) | **GET** /sources/plex/{slug}/ | +*SourcesApi* | [**sources_plex_update**](docs/SourcesApi.md#sources_plex_update) | **PUT** /sources/plex/{slug}/ | +*SourcesApi* | [**sources_plex_used_by_list**](docs/SourcesApi.md#sources_plex_used_by_list) | **GET** /sources/plex/{slug}/used_by/ | +*SourcesApi* | [**sources_saml_create**](docs/SourcesApi.md#sources_saml_create) | **POST** /sources/saml/ | +*SourcesApi* | [**sources_saml_destroy**](docs/SourcesApi.md#sources_saml_destroy) | **DELETE** /sources/saml/{slug}/ | +*SourcesApi* | [**sources_saml_list**](docs/SourcesApi.md#sources_saml_list) | **GET** /sources/saml/ | +*SourcesApi* | [**sources_saml_metadata_retrieve**](docs/SourcesApi.md#sources_saml_metadata_retrieve) | **GET** /sources/saml/{slug}/metadata/ | +*SourcesApi* | [**sources_saml_partial_update**](docs/SourcesApi.md#sources_saml_partial_update) | **PATCH** /sources/saml/{slug}/ | +*SourcesApi* | [**sources_saml_retrieve**](docs/SourcesApi.md#sources_saml_retrieve) | **GET** /sources/saml/{slug}/ | +*SourcesApi* | [**sources_saml_update**](docs/SourcesApi.md#sources_saml_update) | **PUT** /sources/saml/{slug}/ | +*SourcesApi* | [**sources_saml_used_by_list**](docs/SourcesApi.md#sources_saml_used_by_list) | **GET** /sources/saml/{slug}/used_by/ | +*SourcesApi* | [**sources_scim_create**](docs/SourcesApi.md#sources_scim_create) | **POST** /sources/scim/ | +*SourcesApi* | [**sources_scim_destroy**](docs/SourcesApi.md#sources_scim_destroy) | **DELETE** /sources/scim/{slug}/ | +*SourcesApi* | [**sources_scim_groups_create**](docs/SourcesApi.md#sources_scim_groups_create) | **POST** /sources/scim_groups/ | +*SourcesApi* | [**sources_scim_groups_destroy**](docs/SourcesApi.md#sources_scim_groups_destroy) | **DELETE** /sources/scim_groups/{id}/ | +*SourcesApi* | [**sources_scim_groups_list**](docs/SourcesApi.md#sources_scim_groups_list) | **GET** /sources/scim_groups/ | +*SourcesApi* | [**sources_scim_groups_partial_update**](docs/SourcesApi.md#sources_scim_groups_partial_update) | **PATCH** /sources/scim_groups/{id}/ | +*SourcesApi* | [**sources_scim_groups_retrieve**](docs/SourcesApi.md#sources_scim_groups_retrieve) | **GET** /sources/scim_groups/{id}/ | +*SourcesApi* | [**sources_scim_groups_update**](docs/SourcesApi.md#sources_scim_groups_update) | **PUT** /sources/scim_groups/{id}/ | +*SourcesApi* | [**sources_scim_groups_used_by_list**](docs/SourcesApi.md#sources_scim_groups_used_by_list) | **GET** /sources/scim_groups/{id}/used_by/ | +*SourcesApi* | [**sources_scim_list**](docs/SourcesApi.md#sources_scim_list) | **GET** /sources/scim/ | +*SourcesApi* | [**sources_scim_partial_update**](docs/SourcesApi.md#sources_scim_partial_update) | **PATCH** /sources/scim/{slug}/ | +*SourcesApi* | [**sources_scim_retrieve**](docs/SourcesApi.md#sources_scim_retrieve) | **GET** /sources/scim/{slug}/ | +*SourcesApi* | [**sources_scim_update**](docs/SourcesApi.md#sources_scim_update) | **PUT** /sources/scim/{slug}/ | +*SourcesApi* | [**sources_scim_used_by_list**](docs/SourcesApi.md#sources_scim_used_by_list) | **GET** /sources/scim/{slug}/used_by/ | +*SourcesApi* | [**sources_scim_users_create**](docs/SourcesApi.md#sources_scim_users_create) | **POST** /sources/scim_users/ | +*SourcesApi* | [**sources_scim_users_destroy**](docs/SourcesApi.md#sources_scim_users_destroy) | **DELETE** /sources/scim_users/{id}/ | +*SourcesApi* | [**sources_scim_users_list**](docs/SourcesApi.md#sources_scim_users_list) | **GET** /sources/scim_users/ | +*SourcesApi* | [**sources_scim_users_partial_update**](docs/SourcesApi.md#sources_scim_users_partial_update) | **PATCH** /sources/scim_users/{id}/ | +*SourcesApi* | [**sources_scim_users_retrieve**](docs/SourcesApi.md#sources_scim_users_retrieve) | **GET** /sources/scim_users/{id}/ | +*SourcesApi* | [**sources_scim_users_update**](docs/SourcesApi.md#sources_scim_users_update) | **PUT** /sources/scim_users/{id}/ | +*SourcesApi* | [**sources_scim_users_used_by_list**](docs/SourcesApi.md#sources_scim_users_used_by_list) | **GET** /sources/scim_users/{id}/used_by/ | +*SourcesApi* | [**sources_telegram_connect_user_create**](docs/SourcesApi.md#sources_telegram_connect_user_create) | **POST** /sources/telegram/{slug}/connect_user/ | +*SourcesApi* | [**sources_telegram_create**](docs/SourcesApi.md#sources_telegram_create) | **POST** /sources/telegram/ | +*SourcesApi* | [**sources_telegram_destroy**](docs/SourcesApi.md#sources_telegram_destroy) | **DELETE** /sources/telegram/{slug}/ | +*SourcesApi* | [**sources_telegram_list**](docs/SourcesApi.md#sources_telegram_list) | **GET** /sources/telegram/ | +*SourcesApi* | [**sources_telegram_partial_update**](docs/SourcesApi.md#sources_telegram_partial_update) | **PATCH** /sources/telegram/{slug}/ | +*SourcesApi* | [**sources_telegram_retrieve**](docs/SourcesApi.md#sources_telegram_retrieve) | **GET** /sources/telegram/{slug}/ | +*SourcesApi* | [**sources_telegram_update**](docs/SourcesApi.md#sources_telegram_update) | **PUT** /sources/telegram/{slug}/ | +*SourcesApi* | [**sources_telegram_used_by_list**](docs/SourcesApi.md#sources_telegram_used_by_list) | **GET** /sources/telegram/{slug}/used_by/ | +*SourcesApi* | [**sources_user_connections_all_destroy**](docs/SourcesApi.md#sources_user_connections_all_destroy) | **DELETE** /sources/user_connections/all/{id}/ | +*SourcesApi* | [**sources_user_connections_all_list**](docs/SourcesApi.md#sources_user_connections_all_list) | **GET** /sources/user_connections/all/ | +*SourcesApi* | [**sources_user_connections_all_partial_update**](docs/SourcesApi.md#sources_user_connections_all_partial_update) | **PATCH** /sources/user_connections/all/{id}/ | +*SourcesApi* | [**sources_user_connections_all_retrieve**](docs/SourcesApi.md#sources_user_connections_all_retrieve) | **GET** /sources/user_connections/all/{id}/ | +*SourcesApi* | [**sources_user_connections_all_update**](docs/SourcesApi.md#sources_user_connections_all_update) | **PUT** /sources/user_connections/all/{id}/ | +*SourcesApi* | [**sources_user_connections_all_used_by_list**](docs/SourcesApi.md#sources_user_connections_all_used_by_list) | **GET** /sources/user_connections/all/{id}/used_by/ | +*SourcesApi* | [**sources_user_connections_kerberos_create**](docs/SourcesApi.md#sources_user_connections_kerberos_create) | **POST** /sources/user_connections/kerberos/ | +*SourcesApi* | [**sources_user_connections_kerberos_destroy**](docs/SourcesApi.md#sources_user_connections_kerberos_destroy) | **DELETE** /sources/user_connections/kerberos/{id}/ | +*SourcesApi* | [**sources_user_connections_kerberos_list**](docs/SourcesApi.md#sources_user_connections_kerberos_list) | **GET** /sources/user_connections/kerberos/ | +*SourcesApi* | [**sources_user_connections_kerberos_partial_update**](docs/SourcesApi.md#sources_user_connections_kerberos_partial_update) | **PATCH** /sources/user_connections/kerberos/{id}/ | +*SourcesApi* | [**sources_user_connections_kerberos_retrieve**](docs/SourcesApi.md#sources_user_connections_kerberos_retrieve) | **GET** /sources/user_connections/kerberos/{id}/ | +*SourcesApi* | [**sources_user_connections_kerberos_update**](docs/SourcesApi.md#sources_user_connections_kerberos_update) | **PUT** /sources/user_connections/kerberos/{id}/ | +*SourcesApi* | [**sources_user_connections_kerberos_used_by_list**](docs/SourcesApi.md#sources_user_connections_kerberos_used_by_list) | **GET** /sources/user_connections/kerberos/{id}/used_by/ | +*SourcesApi* | [**sources_user_connections_ldap_create**](docs/SourcesApi.md#sources_user_connections_ldap_create) | **POST** /sources/user_connections/ldap/ | +*SourcesApi* | [**sources_user_connections_ldap_destroy**](docs/SourcesApi.md#sources_user_connections_ldap_destroy) | **DELETE** /sources/user_connections/ldap/{id}/ | +*SourcesApi* | [**sources_user_connections_ldap_list**](docs/SourcesApi.md#sources_user_connections_ldap_list) | **GET** /sources/user_connections/ldap/ | +*SourcesApi* | [**sources_user_connections_ldap_partial_update**](docs/SourcesApi.md#sources_user_connections_ldap_partial_update) | **PATCH** /sources/user_connections/ldap/{id}/ | +*SourcesApi* | [**sources_user_connections_ldap_retrieve**](docs/SourcesApi.md#sources_user_connections_ldap_retrieve) | **GET** /sources/user_connections/ldap/{id}/ | +*SourcesApi* | [**sources_user_connections_ldap_update**](docs/SourcesApi.md#sources_user_connections_ldap_update) | **PUT** /sources/user_connections/ldap/{id}/ | +*SourcesApi* | [**sources_user_connections_ldap_used_by_list**](docs/SourcesApi.md#sources_user_connections_ldap_used_by_list) | **GET** /sources/user_connections/ldap/{id}/used_by/ | +*SourcesApi* | [**sources_user_connections_oauth_create**](docs/SourcesApi.md#sources_user_connections_oauth_create) | **POST** /sources/user_connections/oauth/ | +*SourcesApi* | [**sources_user_connections_oauth_destroy**](docs/SourcesApi.md#sources_user_connections_oauth_destroy) | **DELETE** /sources/user_connections/oauth/{id}/ | +*SourcesApi* | [**sources_user_connections_oauth_list**](docs/SourcesApi.md#sources_user_connections_oauth_list) | **GET** /sources/user_connections/oauth/ | +*SourcesApi* | [**sources_user_connections_oauth_partial_update**](docs/SourcesApi.md#sources_user_connections_oauth_partial_update) | **PATCH** /sources/user_connections/oauth/{id}/ | +*SourcesApi* | [**sources_user_connections_oauth_retrieve**](docs/SourcesApi.md#sources_user_connections_oauth_retrieve) | **GET** /sources/user_connections/oauth/{id}/ | +*SourcesApi* | [**sources_user_connections_oauth_update**](docs/SourcesApi.md#sources_user_connections_oauth_update) | **PUT** /sources/user_connections/oauth/{id}/ | +*SourcesApi* | [**sources_user_connections_oauth_used_by_list**](docs/SourcesApi.md#sources_user_connections_oauth_used_by_list) | **GET** /sources/user_connections/oauth/{id}/used_by/ | +*SourcesApi* | [**sources_user_connections_plex_create**](docs/SourcesApi.md#sources_user_connections_plex_create) | **POST** /sources/user_connections/plex/ | +*SourcesApi* | [**sources_user_connections_plex_destroy**](docs/SourcesApi.md#sources_user_connections_plex_destroy) | **DELETE** /sources/user_connections/plex/{id}/ | +*SourcesApi* | [**sources_user_connections_plex_list**](docs/SourcesApi.md#sources_user_connections_plex_list) | **GET** /sources/user_connections/plex/ | +*SourcesApi* | [**sources_user_connections_plex_partial_update**](docs/SourcesApi.md#sources_user_connections_plex_partial_update) | **PATCH** /sources/user_connections/plex/{id}/ | +*SourcesApi* | [**sources_user_connections_plex_retrieve**](docs/SourcesApi.md#sources_user_connections_plex_retrieve) | **GET** /sources/user_connections/plex/{id}/ | +*SourcesApi* | [**sources_user_connections_plex_update**](docs/SourcesApi.md#sources_user_connections_plex_update) | **PUT** /sources/user_connections/plex/{id}/ | +*SourcesApi* | [**sources_user_connections_plex_used_by_list**](docs/SourcesApi.md#sources_user_connections_plex_used_by_list) | **GET** /sources/user_connections/plex/{id}/used_by/ | +*SourcesApi* | [**sources_user_connections_saml_create**](docs/SourcesApi.md#sources_user_connections_saml_create) | **POST** /sources/user_connections/saml/ | +*SourcesApi* | [**sources_user_connections_saml_destroy**](docs/SourcesApi.md#sources_user_connections_saml_destroy) | **DELETE** /sources/user_connections/saml/{id}/ | +*SourcesApi* | [**sources_user_connections_saml_list**](docs/SourcesApi.md#sources_user_connections_saml_list) | **GET** /sources/user_connections/saml/ | +*SourcesApi* | [**sources_user_connections_saml_partial_update**](docs/SourcesApi.md#sources_user_connections_saml_partial_update) | **PATCH** /sources/user_connections/saml/{id}/ | +*SourcesApi* | [**sources_user_connections_saml_retrieve**](docs/SourcesApi.md#sources_user_connections_saml_retrieve) | **GET** /sources/user_connections/saml/{id}/ | +*SourcesApi* | [**sources_user_connections_saml_update**](docs/SourcesApi.md#sources_user_connections_saml_update) | **PUT** /sources/user_connections/saml/{id}/ | +*SourcesApi* | [**sources_user_connections_saml_used_by_list**](docs/SourcesApi.md#sources_user_connections_saml_used_by_list) | **GET** /sources/user_connections/saml/{id}/used_by/ | +*SourcesApi* | [**sources_user_connections_telegram_create**](docs/SourcesApi.md#sources_user_connections_telegram_create) | **POST** /sources/user_connections/telegram/ | +*SourcesApi* | [**sources_user_connections_telegram_destroy**](docs/SourcesApi.md#sources_user_connections_telegram_destroy) | **DELETE** /sources/user_connections/telegram/{id}/ | +*SourcesApi* | [**sources_user_connections_telegram_list**](docs/SourcesApi.md#sources_user_connections_telegram_list) | **GET** /sources/user_connections/telegram/ | +*SourcesApi* | [**sources_user_connections_telegram_partial_update**](docs/SourcesApi.md#sources_user_connections_telegram_partial_update) | **PATCH** /sources/user_connections/telegram/{id}/ | +*SourcesApi* | [**sources_user_connections_telegram_retrieve**](docs/SourcesApi.md#sources_user_connections_telegram_retrieve) | **GET** /sources/user_connections/telegram/{id}/ | +*SourcesApi* | [**sources_user_connections_telegram_update**](docs/SourcesApi.md#sources_user_connections_telegram_update) | **PUT** /sources/user_connections/telegram/{id}/ | +*SourcesApi* | [**sources_user_connections_telegram_used_by_list**](docs/SourcesApi.md#sources_user_connections_telegram_used_by_list) | **GET** /sources/user_connections/telegram/{id}/used_by/ | +*SsfApi* | [**ssf_streams_destroy**](docs/SsfApi.md#ssf_streams_destroy) | **DELETE** /ssf/streams/{uuid}/ | +*SsfApi* | [**ssf_streams_list**](docs/SsfApi.md#ssf_streams_list) | **GET** /ssf/streams/ | +*SsfApi* | [**ssf_streams_retrieve**](docs/SsfApi.md#ssf_streams_retrieve) | **GET** /ssf/streams/{uuid}/ | +*StagesApi* | [**stages_account_lockdown_create**](docs/StagesApi.md#stages_account_lockdown_create) | **POST** /stages/account_lockdown/ | +*StagesApi* | [**stages_account_lockdown_destroy**](docs/StagesApi.md#stages_account_lockdown_destroy) | **DELETE** /stages/account_lockdown/{stage_uuid}/ | +*StagesApi* | [**stages_account_lockdown_list**](docs/StagesApi.md#stages_account_lockdown_list) | **GET** /stages/account_lockdown/ | +*StagesApi* | [**stages_account_lockdown_partial_update**](docs/StagesApi.md#stages_account_lockdown_partial_update) | **PATCH** /stages/account_lockdown/{stage_uuid}/ | +*StagesApi* | [**stages_account_lockdown_retrieve**](docs/StagesApi.md#stages_account_lockdown_retrieve) | **GET** /stages/account_lockdown/{stage_uuid}/ | +*StagesApi* | [**stages_account_lockdown_update**](docs/StagesApi.md#stages_account_lockdown_update) | **PUT** /stages/account_lockdown/{stage_uuid}/ | +*StagesApi* | [**stages_account_lockdown_used_by_list**](docs/StagesApi.md#stages_account_lockdown_used_by_list) | **GET** /stages/account_lockdown/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_all_destroy**](docs/StagesApi.md#stages_all_destroy) | **DELETE** /stages/all/{stage_uuid}/ | +*StagesApi* | [**stages_all_list**](docs/StagesApi.md#stages_all_list) | **GET** /stages/all/ | +*StagesApi* | [**stages_all_retrieve**](docs/StagesApi.md#stages_all_retrieve) | **GET** /stages/all/{stage_uuid}/ | +*StagesApi* | [**stages_all_types_list**](docs/StagesApi.md#stages_all_types_list) | **GET** /stages/all/types/ | +*StagesApi* | [**stages_all_used_by_list**](docs/StagesApi.md#stages_all_used_by_list) | **GET** /stages/all/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_all_user_settings_list**](docs/StagesApi.md#stages_all_user_settings_list) | **GET** /stages/all/user_settings/ | +*StagesApi* | [**stages_authenticator_duo_create**](docs/StagesApi.md#stages_authenticator_duo_create) | **POST** /stages/authenticator/duo/ | +*StagesApi* | [**stages_authenticator_duo_destroy**](docs/StagesApi.md#stages_authenticator_duo_destroy) | **DELETE** /stages/authenticator/duo/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_duo_enrollment_status_create**](docs/StagesApi.md#stages_authenticator_duo_enrollment_status_create) | **POST** /stages/authenticator/duo/{stage_uuid}/enrollment_status/ | +*StagesApi* | [**stages_authenticator_duo_import_device_manual_create**](docs/StagesApi.md#stages_authenticator_duo_import_device_manual_create) | **POST** /stages/authenticator/duo/{stage_uuid}/import_device_manual/ | +*StagesApi* | [**stages_authenticator_duo_import_devices_automatic_create**](docs/StagesApi.md#stages_authenticator_duo_import_devices_automatic_create) | **POST** /stages/authenticator/duo/{stage_uuid}/import_devices_automatic/ | +*StagesApi* | [**stages_authenticator_duo_list**](docs/StagesApi.md#stages_authenticator_duo_list) | **GET** /stages/authenticator/duo/ | +*StagesApi* | [**stages_authenticator_duo_partial_update**](docs/StagesApi.md#stages_authenticator_duo_partial_update) | **PATCH** /stages/authenticator/duo/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_duo_retrieve**](docs/StagesApi.md#stages_authenticator_duo_retrieve) | **GET** /stages/authenticator/duo/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_duo_update**](docs/StagesApi.md#stages_authenticator_duo_update) | **PUT** /stages/authenticator/duo/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_duo_used_by_list**](docs/StagesApi.md#stages_authenticator_duo_used_by_list) | **GET** /stages/authenticator/duo/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_authenticator_email_create**](docs/StagesApi.md#stages_authenticator_email_create) | **POST** /stages/authenticator/email/ | +*StagesApi* | [**stages_authenticator_email_destroy**](docs/StagesApi.md#stages_authenticator_email_destroy) | **DELETE** /stages/authenticator/email/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_email_list**](docs/StagesApi.md#stages_authenticator_email_list) | **GET** /stages/authenticator/email/ | +*StagesApi* | [**stages_authenticator_email_partial_update**](docs/StagesApi.md#stages_authenticator_email_partial_update) | **PATCH** /stages/authenticator/email/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_email_retrieve**](docs/StagesApi.md#stages_authenticator_email_retrieve) | **GET** /stages/authenticator/email/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_email_update**](docs/StagesApi.md#stages_authenticator_email_update) | **PUT** /stages/authenticator/email/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_email_used_by_list**](docs/StagesApi.md#stages_authenticator_email_used_by_list) | **GET** /stages/authenticator/email/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_authenticator_endpoint_gdtc_create**](docs/StagesApi.md#stages_authenticator_endpoint_gdtc_create) | **POST** /stages/authenticator/endpoint_gdtc/ | +*StagesApi* | [**stages_authenticator_endpoint_gdtc_destroy**](docs/StagesApi.md#stages_authenticator_endpoint_gdtc_destroy) | **DELETE** /stages/authenticator/endpoint_gdtc/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_endpoint_gdtc_list**](docs/StagesApi.md#stages_authenticator_endpoint_gdtc_list) | **GET** /stages/authenticator/endpoint_gdtc/ | +*StagesApi* | [**stages_authenticator_endpoint_gdtc_partial_update**](docs/StagesApi.md#stages_authenticator_endpoint_gdtc_partial_update) | **PATCH** /stages/authenticator/endpoint_gdtc/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_endpoint_gdtc_retrieve**](docs/StagesApi.md#stages_authenticator_endpoint_gdtc_retrieve) | **GET** /stages/authenticator/endpoint_gdtc/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_endpoint_gdtc_update**](docs/StagesApi.md#stages_authenticator_endpoint_gdtc_update) | **PUT** /stages/authenticator/endpoint_gdtc/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_endpoint_gdtc_used_by_list**](docs/StagesApi.md#stages_authenticator_endpoint_gdtc_used_by_list) | **GET** /stages/authenticator/endpoint_gdtc/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_authenticator_sms_create**](docs/StagesApi.md#stages_authenticator_sms_create) | **POST** /stages/authenticator/sms/ | +*StagesApi* | [**stages_authenticator_sms_destroy**](docs/StagesApi.md#stages_authenticator_sms_destroy) | **DELETE** /stages/authenticator/sms/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_sms_list**](docs/StagesApi.md#stages_authenticator_sms_list) | **GET** /stages/authenticator/sms/ | +*StagesApi* | [**stages_authenticator_sms_partial_update**](docs/StagesApi.md#stages_authenticator_sms_partial_update) | **PATCH** /stages/authenticator/sms/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_sms_retrieve**](docs/StagesApi.md#stages_authenticator_sms_retrieve) | **GET** /stages/authenticator/sms/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_sms_update**](docs/StagesApi.md#stages_authenticator_sms_update) | **PUT** /stages/authenticator/sms/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_sms_used_by_list**](docs/StagesApi.md#stages_authenticator_sms_used_by_list) | **GET** /stages/authenticator/sms/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_authenticator_static_create**](docs/StagesApi.md#stages_authenticator_static_create) | **POST** /stages/authenticator/static/ | +*StagesApi* | [**stages_authenticator_static_destroy**](docs/StagesApi.md#stages_authenticator_static_destroy) | **DELETE** /stages/authenticator/static/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_static_list**](docs/StagesApi.md#stages_authenticator_static_list) | **GET** /stages/authenticator/static/ | +*StagesApi* | [**stages_authenticator_static_partial_update**](docs/StagesApi.md#stages_authenticator_static_partial_update) | **PATCH** /stages/authenticator/static/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_static_retrieve**](docs/StagesApi.md#stages_authenticator_static_retrieve) | **GET** /stages/authenticator/static/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_static_update**](docs/StagesApi.md#stages_authenticator_static_update) | **PUT** /stages/authenticator/static/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_static_used_by_list**](docs/StagesApi.md#stages_authenticator_static_used_by_list) | **GET** /stages/authenticator/static/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_authenticator_totp_create**](docs/StagesApi.md#stages_authenticator_totp_create) | **POST** /stages/authenticator/totp/ | +*StagesApi* | [**stages_authenticator_totp_destroy**](docs/StagesApi.md#stages_authenticator_totp_destroy) | **DELETE** /stages/authenticator/totp/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_totp_list**](docs/StagesApi.md#stages_authenticator_totp_list) | **GET** /stages/authenticator/totp/ | +*StagesApi* | [**stages_authenticator_totp_partial_update**](docs/StagesApi.md#stages_authenticator_totp_partial_update) | **PATCH** /stages/authenticator/totp/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_totp_retrieve**](docs/StagesApi.md#stages_authenticator_totp_retrieve) | **GET** /stages/authenticator/totp/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_totp_update**](docs/StagesApi.md#stages_authenticator_totp_update) | **PUT** /stages/authenticator/totp/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_totp_used_by_list**](docs/StagesApi.md#stages_authenticator_totp_used_by_list) | **GET** /stages/authenticator/totp/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_authenticator_validate_create**](docs/StagesApi.md#stages_authenticator_validate_create) | **POST** /stages/authenticator/validate/ | +*StagesApi* | [**stages_authenticator_validate_destroy**](docs/StagesApi.md#stages_authenticator_validate_destroy) | **DELETE** /stages/authenticator/validate/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_validate_list**](docs/StagesApi.md#stages_authenticator_validate_list) | **GET** /stages/authenticator/validate/ | +*StagesApi* | [**stages_authenticator_validate_partial_update**](docs/StagesApi.md#stages_authenticator_validate_partial_update) | **PATCH** /stages/authenticator/validate/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_validate_retrieve**](docs/StagesApi.md#stages_authenticator_validate_retrieve) | **GET** /stages/authenticator/validate/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_validate_update**](docs/StagesApi.md#stages_authenticator_validate_update) | **PUT** /stages/authenticator/validate/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_validate_used_by_list**](docs/StagesApi.md#stages_authenticator_validate_used_by_list) | **GET** /stages/authenticator/validate/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_authenticator_webauthn_create**](docs/StagesApi.md#stages_authenticator_webauthn_create) | **POST** /stages/authenticator/webauthn/ | +*StagesApi* | [**stages_authenticator_webauthn_destroy**](docs/StagesApi.md#stages_authenticator_webauthn_destroy) | **DELETE** /stages/authenticator/webauthn/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_webauthn_device_types_list**](docs/StagesApi.md#stages_authenticator_webauthn_device_types_list) | **GET** /stages/authenticator/webauthn_device_types/ | +*StagesApi* | [**stages_authenticator_webauthn_device_types_retrieve**](docs/StagesApi.md#stages_authenticator_webauthn_device_types_retrieve) | **GET** /stages/authenticator/webauthn_device_types/{aaguid}/ | +*StagesApi* | [**stages_authenticator_webauthn_list**](docs/StagesApi.md#stages_authenticator_webauthn_list) | **GET** /stages/authenticator/webauthn/ | +*StagesApi* | [**stages_authenticator_webauthn_partial_update**](docs/StagesApi.md#stages_authenticator_webauthn_partial_update) | **PATCH** /stages/authenticator/webauthn/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_webauthn_retrieve**](docs/StagesApi.md#stages_authenticator_webauthn_retrieve) | **GET** /stages/authenticator/webauthn/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_webauthn_update**](docs/StagesApi.md#stages_authenticator_webauthn_update) | **PUT** /stages/authenticator/webauthn/{stage_uuid}/ | +*StagesApi* | [**stages_authenticator_webauthn_used_by_list**](docs/StagesApi.md#stages_authenticator_webauthn_used_by_list) | **GET** /stages/authenticator/webauthn/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_captcha_create**](docs/StagesApi.md#stages_captcha_create) | **POST** /stages/captcha/ | +*StagesApi* | [**stages_captcha_destroy**](docs/StagesApi.md#stages_captcha_destroy) | **DELETE** /stages/captcha/{stage_uuid}/ | +*StagesApi* | [**stages_captcha_list**](docs/StagesApi.md#stages_captcha_list) | **GET** /stages/captcha/ | +*StagesApi* | [**stages_captcha_partial_update**](docs/StagesApi.md#stages_captcha_partial_update) | **PATCH** /stages/captcha/{stage_uuid}/ | +*StagesApi* | [**stages_captcha_retrieve**](docs/StagesApi.md#stages_captcha_retrieve) | **GET** /stages/captcha/{stage_uuid}/ | +*StagesApi* | [**stages_captcha_update**](docs/StagesApi.md#stages_captcha_update) | **PUT** /stages/captcha/{stage_uuid}/ | +*StagesApi* | [**stages_captcha_used_by_list**](docs/StagesApi.md#stages_captcha_used_by_list) | **GET** /stages/captcha/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_consent_create**](docs/StagesApi.md#stages_consent_create) | **POST** /stages/consent/ | +*StagesApi* | [**stages_consent_destroy**](docs/StagesApi.md#stages_consent_destroy) | **DELETE** /stages/consent/{stage_uuid}/ | +*StagesApi* | [**stages_consent_list**](docs/StagesApi.md#stages_consent_list) | **GET** /stages/consent/ | +*StagesApi* | [**stages_consent_partial_update**](docs/StagesApi.md#stages_consent_partial_update) | **PATCH** /stages/consent/{stage_uuid}/ | +*StagesApi* | [**stages_consent_retrieve**](docs/StagesApi.md#stages_consent_retrieve) | **GET** /stages/consent/{stage_uuid}/ | +*StagesApi* | [**stages_consent_update**](docs/StagesApi.md#stages_consent_update) | **PUT** /stages/consent/{stage_uuid}/ | +*StagesApi* | [**stages_consent_used_by_list**](docs/StagesApi.md#stages_consent_used_by_list) | **GET** /stages/consent/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_deny_create**](docs/StagesApi.md#stages_deny_create) | **POST** /stages/deny/ | +*StagesApi* | [**stages_deny_destroy**](docs/StagesApi.md#stages_deny_destroy) | **DELETE** /stages/deny/{stage_uuid}/ | +*StagesApi* | [**stages_deny_list**](docs/StagesApi.md#stages_deny_list) | **GET** /stages/deny/ | +*StagesApi* | [**stages_deny_partial_update**](docs/StagesApi.md#stages_deny_partial_update) | **PATCH** /stages/deny/{stage_uuid}/ | +*StagesApi* | [**stages_deny_retrieve**](docs/StagesApi.md#stages_deny_retrieve) | **GET** /stages/deny/{stage_uuid}/ | +*StagesApi* | [**stages_deny_update**](docs/StagesApi.md#stages_deny_update) | **PUT** /stages/deny/{stage_uuid}/ | +*StagesApi* | [**stages_deny_used_by_list**](docs/StagesApi.md#stages_deny_used_by_list) | **GET** /stages/deny/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_dummy_create**](docs/StagesApi.md#stages_dummy_create) | **POST** /stages/dummy/ | +*StagesApi* | [**stages_dummy_destroy**](docs/StagesApi.md#stages_dummy_destroy) | **DELETE** /stages/dummy/{stage_uuid}/ | +*StagesApi* | [**stages_dummy_list**](docs/StagesApi.md#stages_dummy_list) | **GET** /stages/dummy/ | +*StagesApi* | [**stages_dummy_partial_update**](docs/StagesApi.md#stages_dummy_partial_update) | **PATCH** /stages/dummy/{stage_uuid}/ | +*StagesApi* | [**stages_dummy_retrieve**](docs/StagesApi.md#stages_dummy_retrieve) | **GET** /stages/dummy/{stage_uuid}/ | +*StagesApi* | [**stages_dummy_update**](docs/StagesApi.md#stages_dummy_update) | **PUT** /stages/dummy/{stage_uuid}/ | +*StagesApi* | [**stages_dummy_used_by_list**](docs/StagesApi.md#stages_dummy_used_by_list) | **GET** /stages/dummy/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_email_create**](docs/StagesApi.md#stages_email_create) | **POST** /stages/email/ | +*StagesApi* | [**stages_email_destroy**](docs/StagesApi.md#stages_email_destroy) | **DELETE** /stages/email/{stage_uuid}/ | +*StagesApi* | [**stages_email_list**](docs/StagesApi.md#stages_email_list) | **GET** /stages/email/ | +*StagesApi* | [**stages_email_partial_update**](docs/StagesApi.md#stages_email_partial_update) | **PATCH** /stages/email/{stage_uuid}/ | +*StagesApi* | [**stages_email_retrieve**](docs/StagesApi.md#stages_email_retrieve) | **GET** /stages/email/{stage_uuid}/ | +*StagesApi* | [**stages_email_templates_list**](docs/StagesApi.md#stages_email_templates_list) | **GET** /stages/email/templates/ | +*StagesApi* | [**stages_email_update**](docs/StagesApi.md#stages_email_update) | **PUT** /stages/email/{stage_uuid}/ | +*StagesApi* | [**stages_email_used_by_list**](docs/StagesApi.md#stages_email_used_by_list) | **GET** /stages/email/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_endpoints_create**](docs/StagesApi.md#stages_endpoints_create) | **POST** /stages/endpoints/ | +*StagesApi* | [**stages_endpoints_destroy**](docs/StagesApi.md#stages_endpoints_destroy) | **DELETE** /stages/endpoints/{stage_uuid}/ | +*StagesApi* | [**stages_endpoints_list**](docs/StagesApi.md#stages_endpoints_list) | **GET** /stages/endpoints/ | +*StagesApi* | [**stages_endpoints_partial_update**](docs/StagesApi.md#stages_endpoints_partial_update) | **PATCH** /stages/endpoints/{stage_uuid}/ | +*StagesApi* | [**stages_endpoints_retrieve**](docs/StagesApi.md#stages_endpoints_retrieve) | **GET** /stages/endpoints/{stage_uuid}/ | +*StagesApi* | [**stages_endpoints_update**](docs/StagesApi.md#stages_endpoints_update) | **PUT** /stages/endpoints/{stage_uuid}/ | +*StagesApi* | [**stages_endpoints_used_by_list**](docs/StagesApi.md#stages_endpoints_used_by_list) | **GET** /stages/endpoints/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_identification_create**](docs/StagesApi.md#stages_identification_create) | **POST** /stages/identification/ | +*StagesApi* | [**stages_identification_destroy**](docs/StagesApi.md#stages_identification_destroy) | **DELETE** /stages/identification/{stage_uuid}/ | +*StagesApi* | [**stages_identification_list**](docs/StagesApi.md#stages_identification_list) | **GET** /stages/identification/ | +*StagesApi* | [**stages_identification_partial_update**](docs/StagesApi.md#stages_identification_partial_update) | **PATCH** /stages/identification/{stage_uuid}/ | +*StagesApi* | [**stages_identification_retrieve**](docs/StagesApi.md#stages_identification_retrieve) | **GET** /stages/identification/{stage_uuid}/ | +*StagesApi* | [**stages_identification_update**](docs/StagesApi.md#stages_identification_update) | **PUT** /stages/identification/{stage_uuid}/ | +*StagesApi* | [**stages_identification_used_by_list**](docs/StagesApi.md#stages_identification_used_by_list) | **GET** /stages/identification/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_invitation_invitations_create**](docs/StagesApi.md#stages_invitation_invitations_create) | **POST** /stages/invitation/invitations/ | +*StagesApi* | [**stages_invitation_invitations_destroy**](docs/StagesApi.md#stages_invitation_invitations_destroy) | **DELETE** /stages/invitation/invitations/{invite_uuid}/ | +*StagesApi* | [**stages_invitation_invitations_list**](docs/StagesApi.md#stages_invitation_invitations_list) | **GET** /stages/invitation/invitations/ | +*StagesApi* | [**stages_invitation_invitations_partial_update**](docs/StagesApi.md#stages_invitation_invitations_partial_update) | **PATCH** /stages/invitation/invitations/{invite_uuid}/ | +*StagesApi* | [**stages_invitation_invitations_retrieve**](docs/StagesApi.md#stages_invitation_invitations_retrieve) | **GET** /stages/invitation/invitations/{invite_uuid}/ | +*StagesApi* | [**stages_invitation_invitations_send_email_create**](docs/StagesApi.md#stages_invitation_invitations_send_email_create) | **POST** /stages/invitation/invitations/{invite_uuid}/send_email/ | +*StagesApi* | [**stages_invitation_invitations_update**](docs/StagesApi.md#stages_invitation_invitations_update) | **PUT** /stages/invitation/invitations/{invite_uuid}/ | +*StagesApi* | [**stages_invitation_invitations_used_by_list**](docs/StagesApi.md#stages_invitation_invitations_used_by_list) | **GET** /stages/invitation/invitations/{invite_uuid}/used_by/ | +*StagesApi* | [**stages_invitation_stages_create**](docs/StagesApi.md#stages_invitation_stages_create) | **POST** /stages/invitation/stages/ | +*StagesApi* | [**stages_invitation_stages_destroy**](docs/StagesApi.md#stages_invitation_stages_destroy) | **DELETE** /stages/invitation/stages/{stage_uuid}/ | +*StagesApi* | [**stages_invitation_stages_list**](docs/StagesApi.md#stages_invitation_stages_list) | **GET** /stages/invitation/stages/ | +*StagesApi* | [**stages_invitation_stages_partial_update**](docs/StagesApi.md#stages_invitation_stages_partial_update) | **PATCH** /stages/invitation/stages/{stage_uuid}/ | +*StagesApi* | [**stages_invitation_stages_retrieve**](docs/StagesApi.md#stages_invitation_stages_retrieve) | **GET** /stages/invitation/stages/{stage_uuid}/ | +*StagesApi* | [**stages_invitation_stages_update**](docs/StagesApi.md#stages_invitation_stages_update) | **PUT** /stages/invitation/stages/{stage_uuid}/ | +*StagesApi* | [**stages_invitation_stages_used_by_list**](docs/StagesApi.md#stages_invitation_stages_used_by_list) | **GET** /stages/invitation/stages/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_mtls_create**](docs/StagesApi.md#stages_mtls_create) | **POST** /stages/mtls/ | +*StagesApi* | [**stages_mtls_destroy**](docs/StagesApi.md#stages_mtls_destroy) | **DELETE** /stages/mtls/{stage_uuid}/ | +*StagesApi* | [**stages_mtls_list**](docs/StagesApi.md#stages_mtls_list) | **GET** /stages/mtls/ | +*StagesApi* | [**stages_mtls_partial_update**](docs/StagesApi.md#stages_mtls_partial_update) | **PATCH** /stages/mtls/{stage_uuid}/ | +*StagesApi* | [**stages_mtls_retrieve**](docs/StagesApi.md#stages_mtls_retrieve) | **GET** /stages/mtls/{stage_uuid}/ | +*StagesApi* | [**stages_mtls_update**](docs/StagesApi.md#stages_mtls_update) | **PUT** /stages/mtls/{stage_uuid}/ | +*StagesApi* | [**stages_mtls_used_by_list**](docs/StagesApi.md#stages_mtls_used_by_list) | **GET** /stages/mtls/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_password_create**](docs/StagesApi.md#stages_password_create) | **POST** /stages/password/ | +*StagesApi* | [**stages_password_destroy**](docs/StagesApi.md#stages_password_destroy) | **DELETE** /stages/password/{stage_uuid}/ | +*StagesApi* | [**stages_password_list**](docs/StagesApi.md#stages_password_list) | **GET** /stages/password/ | +*StagesApi* | [**stages_password_partial_update**](docs/StagesApi.md#stages_password_partial_update) | **PATCH** /stages/password/{stage_uuid}/ | +*StagesApi* | [**stages_password_retrieve**](docs/StagesApi.md#stages_password_retrieve) | **GET** /stages/password/{stage_uuid}/ | +*StagesApi* | [**stages_password_update**](docs/StagesApi.md#stages_password_update) | **PUT** /stages/password/{stage_uuid}/ | +*StagesApi* | [**stages_password_used_by_list**](docs/StagesApi.md#stages_password_used_by_list) | **GET** /stages/password/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_prompt_prompts_create**](docs/StagesApi.md#stages_prompt_prompts_create) | **POST** /stages/prompt/prompts/ | +*StagesApi* | [**stages_prompt_prompts_destroy**](docs/StagesApi.md#stages_prompt_prompts_destroy) | **DELETE** /stages/prompt/prompts/{prompt_uuid}/ | +*StagesApi* | [**stages_prompt_prompts_list**](docs/StagesApi.md#stages_prompt_prompts_list) | **GET** /stages/prompt/prompts/ | +*StagesApi* | [**stages_prompt_prompts_partial_update**](docs/StagesApi.md#stages_prompt_prompts_partial_update) | **PATCH** /stages/prompt/prompts/{prompt_uuid}/ | +*StagesApi* | [**stages_prompt_prompts_preview_create**](docs/StagesApi.md#stages_prompt_prompts_preview_create) | **POST** /stages/prompt/prompts/preview/ | +*StagesApi* | [**stages_prompt_prompts_retrieve**](docs/StagesApi.md#stages_prompt_prompts_retrieve) | **GET** /stages/prompt/prompts/{prompt_uuid}/ | +*StagesApi* | [**stages_prompt_prompts_update**](docs/StagesApi.md#stages_prompt_prompts_update) | **PUT** /stages/prompt/prompts/{prompt_uuid}/ | +*StagesApi* | [**stages_prompt_prompts_used_by_list**](docs/StagesApi.md#stages_prompt_prompts_used_by_list) | **GET** /stages/prompt/prompts/{prompt_uuid}/used_by/ | +*StagesApi* | [**stages_prompt_stages_create**](docs/StagesApi.md#stages_prompt_stages_create) | **POST** /stages/prompt/stages/ | +*StagesApi* | [**stages_prompt_stages_destroy**](docs/StagesApi.md#stages_prompt_stages_destroy) | **DELETE** /stages/prompt/stages/{stage_uuid}/ | +*StagesApi* | [**stages_prompt_stages_list**](docs/StagesApi.md#stages_prompt_stages_list) | **GET** /stages/prompt/stages/ | +*StagesApi* | [**stages_prompt_stages_partial_update**](docs/StagesApi.md#stages_prompt_stages_partial_update) | **PATCH** /stages/prompt/stages/{stage_uuid}/ | +*StagesApi* | [**stages_prompt_stages_retrieve**](docs/StagesApi.md#stages_prompt_stages_retrieve) | **GET** /stages/prompt/stages/{stage_uuid}/ | +*StagesApi* | [**stages_prompt_stages_update**](docs/StagesApi.md#stages_prompt_stages_update) | **PUT** /stages/prompt/stages/{stage_uuid}/ | +*StagesApi* | [**stages_prompt_stages_used_by_list**](docs/StagesApi.md#stages_prompt_stages_used_by_list) | **GET** /stages/prompt/stages/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_redirect_create**](docs/StagesApi.md#stages_redirect_create) | **POST** /stages/redirect/ | +*StagesApi* | [**stages_redirect_destroy**](docs/StagesApi.md#stages_redirect_destroy) | **DELETE** /stages/redirect/{stage_uuid}/ | +*StagesApi* | [**stages_redirect_list**](docs/StagesApi.md#stages_redirect_list) | **GET** /stages/redirect/ | +*StagesApi* | [**stages_redirect_partial_update**](docs/StagesApi.md#stages_redirect_partial_update) | **PATCH** /stages/redirect/{stage_uuid}/ | +*StagesApi* | [**stages_redirect_retrieve**](docs/StagesApi.md#stages_redirect_retrieve) | **GET** /stages/redirect/{stage_uuid}/ | +*StagesApi* | [**stages_redirect_update**](docs/StagesApi.md#stages_redirect_update) | **PUT** /stages/redirect/{stage_uuid}/ | +*StagesApi* | [**stages_redirect_used_by_list**](docs/StagesApi.md#stages_redirect_used_by_list) | **GET** /stages/redirect/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_source_create**](docs/StagesApi.md#stages_source_create) | **POST** /stages/source/ | +*StagesApi* | [**stages_source_destroy**](docs/StagesApi.md#stages_source_destroy) | **DELETE** /stages/source/{stage_uuid}/ | +*StagesApi* | [**stages_source_list**](docs/StagesApi.md#stages_source_list) | **GET** /stages/source/ | +*StagesApi* | [**stages_source_partial_update**](docs/StagesApi.md#stages_source_partial_update) | **PATCH** /stages/source/{stage_uuid}/ | +*StagesApi* | [**stages_source_retrieve**](docs/StagesApi.md#stages_source_retrieve) | **GET** /stages/source/{stage_uuid}/ | +*StagesApi* | [**stages_source_update**](docs/StagesApi.md#stages_source_update) | **PUT** /stages/source/{stage_uuid}/ | +*StagesApi* | [**stages_source_used_by_list**](docs/StagesApi.md#stages_source_used_by_list) | **GET** /stages/source/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_user_delete_create**](docs/StagesApi.md#stages_user_delete_create) | **POST** /stages/user_delete/ | +*StagesApi* | [**stages_user_delete_destroy**](docs/StagesApi.md#stages_user_delete_destroy) | **DELETE** /stages/user_delete/{stage_uuid}/ | +*StagesApi* | [**stages_user_delete_list**](docs/StagesApi.md#stages_user_delete_list) | **GET** /stages/user_delete/ | +*StagesApi* | [**stages_user_delete_partial_update**](docs/StagesApi.md#stages_user_delete_partial_update) | **PATCH** /stages/user_delete/{stage_uuid}/ | +*StagesApi* | [**stages_user_delete_retrieve**](docs/StagesApi.md#stages_user_delete_retrieve) | **GET** /stages/user_delete/{stage_uuid}/ | +*StagesApi* | [**stages_user_delete_update**](docs/StagesApi.md#stages_user_delete_update) | **PUT** /stages/user_delete/{stage_uuid}/ | +*StagesApi* | [**stages_user_delete_used_by_list**](docs/StagesApi.md#stages_user_delete_used_by_list) | **GET** /stages/user_delete/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_user_login_create**](docs/StagesApi.md#stages_user_login_create) | **POST** /stages/user_login/ | +*StagesApi* | [**stages_user_login_destroy**](docs/StagesApi.md#stages_user_login_destroy) | **DELETE** /stages/user_login/{stage_uuid}/ | +*StagesApi* | [**stages_user_login_list**](docs/StagesApi.md#stages_user_login_list) | **GET** /stages/user_login/ | +*StagesApi* | [**stages_user_login_partial_update**](docs/StagesApi.md#stages_user_login_partial_update) | **PATCH** /stages/user_login/{stage_uuid}/ | +*StagesApi* | [**stages_user_login_retrieve**](docs/StagesApi.md#stages_user_login_retrieve) | **GET** /stages/user_login/{stage_uuid}/ | +*StagesApi* | [**stages_user_login_update**](docs/StagesApi.md#stages_user_login_update) | **PUT** /stages/user_login/{stage_uuid}/ | +*StagesApi* | [**stages_user_login_used_by_list**](docs/StagesApi.md#stages_user_login_used_by_list) | **GET** /stages/user_login/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_user_logout_create**](docs/StagesApi.md#stages_user_logout_create) | **POST** /stages/user_logout/ | +*StagesApi* | [**stages_user_logout_destroy**](docs/StagesApi.md#stages_user_logout_destroy) | **DELETE** /stages/user_logout/{stage_uuid}/ | +*StagesApi* | [**stages_user_logout_list**](docs/StagesApi.md#stages_user_logout_list) | **GET** /stages/user_logout/ | +*StagesApi* | [**stages_user_logout_partial_update**](docs/StagesApi.md#stages_user_logout_partial_update) | **PATCH** /stages/user_logout/{stage_uuid}/ | +*StagesApi* | [**stages_user_logout_retrieve**](docs/StagesApi.md#stages_user_logout_retrieve) | **GET** /stages/user_logout/{stage_uuid}/ | +*StagesApi* | [**stages_user_logout_update**](docs/StagesApi.md#stages_user_logout_update) | **PUT** /stages/user_logout/{stage_uuid}/ | +*StagesApi* | [**stages_user_logout_used_by_list**](docs/StagesApi.md#stages_user_logout_used_by_list) | **GET** /stages/user_logout/{stage_uuid}/used_by/ | +*StagesApi* | [**stages_user_write_create**](docs/StagesApi.md#stages_user_write_create) | **POST** /stages/user_write/ | +*StagesApi* | [**stages_user_write_destroy**](docs/StagesApi.md#stages_user_write_destroy) | **DELETE** /stages/user_write/{stage_uuid}/ | +*StagesApi* | [**stages_user_write_list**](docs/StagesApi.md#stages_user_write_list) | **GET** /stages/user_write/ | +*StagesApi* | [**stages_user_write_partial_update**](docs/StagesApi.md#stages_user_write_partial_update) | **PATCH** /stages/user_write/{stage_uuid}/ | +*StagesApi* | [**stages_user_write_retrieve**](docs/StagesApi.md#stages_user_write_retrieve) | **GET** /stages/user_write/{stage_uuid}/ | +*StagesApi* | [**stages_user_write_update**](docs/StagesApi.md#stages_user_write_update) | **PUT** /stages/user_write/{stage_uuid}/ | +*StagesApi* | [**stages_user_write_used_by_list**](docs/StagesApi.md#stages_user_write_used_by_list) | **GET** /stages/user_write/{stage_uuid}/used_by/ | +*TasksApi* | [**tasks_schedules_list**](docs/TasksApi.md#tasks_schedules_list) | **GET** /tasks/schedules/ | +*TasksApi* | [**tasks_schedules_partial_update**](docs/TasksApi.md#tasks_schedules_partial_update) | **PATCH** /tasks/schedules/{id}/ | +*TasksApi* | [**tasks_schedules_retrieve**](docs/TasksApi.md#tasks_schedules_retrieve) | **GET** /tasks/schedules/{id}/ | +*TasksApi* | [**tasks_schedules_send_create**](docs/TasksApi.md#tasks_schedules_send_create) | **POST** /tasks/schedules/{id}/send/ | +*TasksApi* | [**tasks_schedules_update**](docs/TasksApi.md#tasks_schedules_update) | **PUT** /tasks/schedules/{id}/ | +*TasksApi* | [**tasks_tasks_list**](docs/TasksApi.md#tasks_tasks_list) | **GET** /tasks/tasks/ | +*TasksApi* | [**tasks_tasks_retrieve**](docs/TasksApi.md#tasks_tasks_retrieve) | **GET** /tasks/tasks/{message_id}/ | +*TasksApi* | [**tasks_tasks_retry_create**](docs/TasksApi.md#tasks_tasks_retry_create) | **POST** /tasks/tasks/{message_id}/retry/ | +*TasksApi* | [**tasks_tasks_status_retrieve**](docs/TasksApi.md#tasks_tasks_status_retrieve) | **GET** /tasks/tasks/status/ | +*TasksApi* | [**tasks_workers_list**](docs/TasksApi.md#tasks_workers_list) | **GET** /tasks/workers/ | +*TenantsApi* | [**tenants_domains_create**](docs/TenantsApi.md#tenants_domains_create) | **POST** /tenants/domains/ | +*TenantsApi* | [**tenants_domains_destroy**](docs/TenantsApi.md#tenants_domains_destroy) | **DELETE** /tenants/domains/{id}/ | +*TenantsApi* | [**tenants_domains_list**](docs/TenantsApi.md#tenants_domains_list) | **GET** /tenants/domains/ | +*TenantsApi* | [**tenants_domains_partial_update**](docs/TenantsApi.md#tenants_domains_partial_update) | **PATCH** /tenants/domains/{id}/ | +*TenantsApi* | [**tenants_domains_retrieve**](docs/TenantsApi.md#tenants_domains_retrieve) | **GET** /tenants/domains/{id}/ | +*TenantsApi* | [**tenants_domains_update**](docs/TenantsApi.md#tenants_domains_update) | **PUT** /tenants/domains/{id}/ | +*TenantsApi* | [**tenants_tenants_create**](docs/TenantsApi.md#tenants_tenants_create) | **POST** /tenants/tenants/ | +*TenantsApi* | [**tenants_tenants_create_admin_group_create**](docs/TenantsApi.md#tenants_tenants_create_admin_group_create) | **POST** /tenants/tenants/{tenant_uuid}/create_admin_group/ | +*TenantsApi* | [**tenants_tenants_create_recovery_key_create**](docs/TenantsApi.md#tenants_tenants_create_recovery_key_create) | **POST** /tenants/tenants/{tenant_uuid}/create_recovery_key/ | +*TenantsApi* | [**tenants_tenants_destroy**](docs/TenantsApi.md#tenants_tenants_destroy) | **DELETE** /tenants/tenants/{tenant_uuid}/ | +*TenantsApi* | [**tenants_tenants_list**](docs/TenantsApi.md#tenants_tenants_list) | **GET** /tenants/tenants/ | +*TenantsApi* | [**tenants_tenants_partial_update**](docs/TenantsApi.md#tenants_tenants_partial_update) | **PATCH** /tenants/tenants/{tenant_uuid}/ | +*TenantsApi* | [**tenants_tenants_retrieve**](docs/TenantsApi.md#tenants_tenants_retrieve) | **GET** /tenants/tenants/{tenant_uuid}/ | +*TenantsApi* | [**tenants_tenants_update**](docs/TenantsApi.md#tenants_tenants_update) | **PUT** /tenants/tenants/{tenant_uuid}/ | + + +## Documentation For Models + + - [AccessDeniedChallenge](docs/AccessDeniedChallenge.md) + - [AccountLockdownStage](docs/AccountLockdownStage.md) + - [AccountLockdownStageRequest](docs/AccountLockdownStageRequest.md) + - [AgentAuthenticationResponse](docs/AgentAuthenticationResponse.md) + - [AgentConfig](docs/AgentConfig.md) + - [AgentConnector](docs/AgentConnector.md) + - [AgentConnectorRequest](docs/AgentConnectorRequest.md) + - [AgentPSSODeviceRegistrationRequest](docs/AgentPSSODeviceRegistrationRequest.md) + - [AgentPSSODeviceRegistrationResponse](docs/AgentPSSODeviceRegistrationResponse.md) + - [AgentPSSOUserRegistrationRequest](docs/AgentPSSOUserRegistrationRequest.md) + - [AgentTokenResponse](docs/AgentTokenResponse.md) + - [AlgEnum](docs/AlgEnum.md) + - [App](docs/App.md) + - [AppEnum](docs/AppEnum.md) + - [AppleChallengeResponseRequest](docs/AppleChallengeResponseRequest.md) + - [AppleIndependentSecureEnclave](docs/AppleIndependentSecureEnclave.md) + - [AppleIndependentSecureEnclaveRequest](docs/AppleIndependentSecureEnclaveRequest.md) + - [AppleLoginChallenge](docs/AppleLoginChallenge.md) + - [Application](docs/Application.md) + - [ApplicationEntitlement](docs/ApplicationEntitlement.md) + - [ApplicationEntitlementRequest](docs/ApplicationEntitlementRequest.md) + - [ApplicationRequest](docs/ApplicationRequest.md) + - [AuthTypeEnum](docs/AuthTypeEnum.md) + - [AuthenticatedSession](docs/AuthenticatedSession.md) + - [AuthenticatedSessionAsn](docs/AuthenticatedSessionAsn.md) + - [AuthenticatedSessionGeoIp](docs/AuthenticatedSessionGeoIp.md) + - [AuthenticatedSessionUserAgent](docs/AuthenticatedSessionUserAgent.md) + - [AuthenticatedSessionUserAgentDevice](docs/AuthenticatedSessionUserAgentDevice.md) + - [AuthenticatedSessionUserAgentOs](docs/AuthenticatedSessionUserAgentOs.md) + - [AuthenticatedSessionUserAgentUserAgent](docs/AuthenticatedSessionUserAgentUserAgent.md) + - [AuthenticationEnum](docs/AuthenticationEnum.md) + - [AuthenticatorAttachmentEnum](docs/AuthenticatorAttachmentEnum.md) + - [AuthenticatorDuoChallenge](docs/AuthenticatorDuoChallenge.md) + - [AuthenticatorDuoChallengeResponseRequest](docs/AuthenticatorDuoChallengeResponseRequest.md) + - [AuthenticatorDuoStage](docs/AuthenticatorDuoStage.md) + - [AuthenticatorDuoStageDeviceImportResponse](docs/AuthenticatorDuoStageDeviceImportResponse.md) + - [AuthenticatorDuoStageManualDeviceImportRequest](docs/AuthenticatorDuoStageManualDeviceImportRequest.md) + - [AuthenticatorDuoStageRequest](docs/AuthenticatorDuoStageRequest.md) + - [AuthenticatorEmailChallenge](docs/AuthenticatorEmailChallenge.md) + - [AuthenticatorEmailChallengeResponseRequest](docs/AuthenticatorEmailChallengeResponseRequest.md) + - [AuthenticatorEmailStage](docs/AuthenticatorEmailStage.md) + - [AuthenticatorEmailStageRequest](docs/AuthenticatorEmailStageRequest.md) + - [AuthenticatorEndpointGDTCStage](docs/AuthenticatorEndpointGDTCStage.md) + - [AuthenticatorEndpointGDTCStageRequest](docs/AuthenticatorEndpointGDTCStageRequest.md) + - [AuthenticatorSMSChallenge](docs/AuthenticatorSMSChallenge.md) + - [AuthenticatorSMSChallengeResponseRequest](docs/AuthenticatorSMSChallengeResponseRequest.md) + - [AuthenticatorSMSStage](docs/AuthenticatorSMSStage.md) + - [AuthenticatorSMSStageRequest](docs/AuthenticatorSMSStageRequest.md) + - [AuthenticatorStaticChallenge](docs/AuthenticatorStaticChallenge.md) + - [AuthenticatorStaticChallengeResponseRequest](docs/AuthenticatorStaticChallengeResponseRequest.md) + - [AuthenticatorStaticStage](docs/AuthenticatorStaticStage.md) + - [AuthenticatorStaticStageRequest](docs/AuthenticatorStaticStageRequest.md) + - [AuthenticatorTOTPChallenge](docs/AuthenticatorTOTPChallenge.md) + - [AuthenticatorTOTPChallengeResponseRequest](docs/AuthenticatorTOTPChallengeResponseRequest.md) + - [AuthenticatorTOTPStage](docs/AuthenticatorTOTPStage.md) + - [AuthenticatorTOTPStageRequest](docs/AuthenticatorTOTPStageRequest.md) + - [AuthenticatorValidateStage](docs/AuthenticatorValidateStage.md) + - [AuthenticatorValidateStageRequest](docs/AuthenticatorValidateStageRequest.md) + - [AuthenticatorValidationChallenge](docs/AuthenticatorValidationChallenge.md) + - [AuthenticatorValidationChallengeResponseRequest](docs/AuthenticatorValidationChallengeResponseRequest.md) + - [AuthenticatorWebAuthnChallenge](docs/AuthenticatorWebAuthnChallenge.md) + - [AuthenticatorWebAuthnChallengeResponseRequest](docs/AuthenticatorWebAuthnChallengeResponseRequest.md) + - [AuthenticatorWebAuthnStage](docs/AuthenticatorWebAuthnStage.md) + - [AuthenticatorWebAuthnStageRequest](docs/AuthenticatorWebAuthnStageRequest.md) + - [AuthorizationCodeAuthMethodEnum](docs/AuthorizationCodeAuthMethodEnum.md) + - [AutoSubmitChallengeResponseRequest](docs/AutoSubmitChallengeResponseRequest.md) + - [AutosubmitChallenge](docs/AutosubmitChallenge.md) + - [BackendsEnum](docs/BackendsEnum.md) + - [BindingTypeEnum](docs/BindingTypeEnum.md) + - [BlueprintFile](docs/BlueprintFile.md) + - [BlueprintImportResult](docs/BlueprintImportResult.md) + - [BlueprintInstance](docs/BlueprintInstance.md) + - [BlueprintInstanceRequest](docs/BlueprintInstanceRequest.md) + - [BlueprintInstanceStatusEnum](docs/BlueprintInstanceStatusEnum.md) + - [Brand](docs/Brand.md) + - [BrandRequest](docs/BrandRequest.md) + - [BulkDeleteSessionResponse](docs/BulkDeleteSessionResponse.md) + - [Cache](docs/Cache.md) + - [CapabilitiesEnum](docs/CapabilitiesEnum.md) + - [CaptchaChallenge](docs/CaptchaChallenge.md) + - [CaptchaChallengeResponseRequest](docs/CaptchaChallengeResponseRequest.md) + - [CaptchaStage](docs/CaptchaStage.md) + - [CaptchaStageRequest](docs/CaptchaStageRequest.md) + - [CertAttributeEnum](docs/CertAttributeEnum.md) + - [CertificateData](docs/CertificateData.md) + - [CertificateGenerationRequest](docs/CertificateGenerationRequest.md) + - [CertificateKeyPair](docs/CertificateKeyPair.md) + - [CertificateKeyPairKeyTypeEnum](docs/CertificateKeyPairKeyTypeEnum.md) + - [CertificateKeyPairRequest](docs/CertificateKeyPairRequest.md) + - [ChallengeTypes](docs/ChallengeTypes.md) + - [ClientTypeEnum](docs/ClientTypeEnum.md) + - [CompatibilityModeEnum](docs/CompatibilityModeEnum.md) + - [Config](docs/Config.md) + - [ConnectionToken](docs/ConnectionToken.md) + - [ConnectionTokenRequest](docs/ConnectionTokenRequest.md) + - [Connector](docs/Connector.md) + - [ConsentChallenge](docs/ConsentChallenge.md) + - [ConsentChallengeResponseRequest](docs/ConsentChallengeResponseRequest.md) + - [ConsentModeEnum](docs/ConsentModeEnum.md) + - [ConsentPermission](docs/ConsentPermission.md) + - [ConsentStage](docs/ConsentStage.md) + - [ConsentStageRequest](docs/ConsentStageRequest.md) + - [ContentType](docs/ContentType.md) + - [ContentTypeEnum](docs/ContentTypeEnum.md) + - [ContextualFlowInfo](docs/ContextualFlowInfo.md) + - [ContextualFlowInfoLayoutEnum](docs/ContextualFlowInfoLayoutEnum.md) + - [CountryCodeEnum](docs/CountryCodeEnum.md) + - [CurrentBrand](docs/CurrentBrand.md) + - [CurrentBrandFlags](docs/CurrentBrandFlags.md) + - [DataExport](docs/DataExport.md) + - [DeliveryMethodEnum](docs/DeliveryMethodEnum.md) + - [DeniedActionEnum](docs/DeniedActionEnum.md) + - [DenyStage](docs/DenyStage.md) + - [DenyStageRequest](docs/DenyStageRequest.md) + - [DetailedCountry](docs/DetailedCountry.md) + - [Device](docs/Device.md) + - [DeviceAccessGroup](docs/DeviceAccessGroup.md) + - [DeviceAccessGroupRequest](docs/DeviceAccessGroupRequest.md) + - [DeviceChallenge](docs/DeviceChallenge.md) + - [DeviceChallengeRequest](docs/DeviceChallengeRequest.md) + - [DeviceClassesEnum](docs/DeviceClassesEnum.md) + - [DeviceConnection](docs/DeviceConnection.md) + - [DeviceFactSnapshot](docs/DeviceFactSnapshot.md) + - [DeviceFacts](docs/DeviceFacts.md) + - [DeviceFactsOSFamily](docs/DeviceFactsOSFamily.md) + - [DeviceFactsRequest](docs/DeviceFactsRequest.md) + - [DeviceGroup](docs/DeviceGroup.md) + - [DeviceGroupRequest](docs/DeviceGroupRequest.md) + - [DeviceSummary](docs/DeviceSummary.md) + - [DeviceUser](docs/DeviceUser.md) + - [DeviceUserBinding](docs/DeviceUserBinding.md) + - [DeviceUserBindingRequest](docs/DeviceUserBindingRequest.md) + - [DeviceUserRequest](docs/DeviceUserRequest.md) + - [DigestAlgorithmEnum](docs/DigestAlgorithmEnum.md) + - [DigitsEnum](docs/DigitsEnum.md) + - [Disk](docs/Disk.md) + - [DiskRequest](docs/DiskRequest.md) + - [DockerServiceConnection](docs/DockerServiceConnection.md) + - [DockerServiceConnectionRequest](docs/DockerServiceConnectionRequest.md) + - [Domain](docs/Domain.md) + - [DomainRequest](docs/DomainRequest.md) + - [DummyChallenge](docs/DummyChallenge.md) + - [DummyChallengeResponseRequest](docs/DummyChallengeResponseRequest.md) + - [DummyPolicy](docs/DummyPolicy.md) + - [DummyPolicyRequest](docs/DummyPolicyRequest.md) + - [DummyStage](docs/DummyStage.md) + - [DummyStageRequest](docs/DummyStageRequest.md) + - [DuoDevice](docs/DuoDevice.md) + - [DuoDeviceEnrollmentStatus](docs/DuoDeviceEnrollmentStatus.md) + - [DuoDeviceRequest](docs/DuoDeviceRequest.md) + - [DuoResponseEnum](docs/DuoResponseEnum.md) + - [EmailChallenge](docs/EmailChallenge.md) + - [EmailChallengeResponseRequest](docs/EmailChallengeResponseRequest.md) + - [EmailDevice](docs/EmailDevice.md) + - [EmailDeviceRequest](docs/EmailDeviceRequest.md) + - [EmailStage](docs/EmailStage.md) + - [EmailStageRequest](docs/EmailStageRequest.md) + - [Endpoint](docs/Endpoint.md) + - [EndpointAgentChallenge](docs/EndpointAgentChallenge.md) + - [EndpointAgentChallengeResponseRequest](docs/EndpointAgentChallengeResponseRequest.md) + - [EndpointAuthModeEnum](docs/EndpointAuthModeEnum.md) + - [EndpointDevice](docs/EndpointDevice.md) + - [EndpointDeviceDetails](docs/EndpointDeviceDetails.md) + - [EndpointDeviceRequest](docs/EndpointDeviceRequest.md) + - [EndpointRequest](docs/EndpointRequest.md) + - [EndpointStage](docs/EndpointStage.md) + - [EndpointStageRequest](docs/EndpointStageRequest.md) + - [EnrollRequest](docs/EnrollRequest.md) + - [EnrollmentToken](docs/EnrollmentToken.md) + - [EnrollmentTokenRequest](docs/EnrollmentTokenRequest.md) + - [ErrorDetail](docs/ErrorDetail.md) + - [ErrorReportingConfig](docs/ErrorReportingConfig.md) + - [Event](docs/Event.md) + - [EventActions](docs/EventActions.md) + - [EventMatcherPolicy](docs/EventMatcherPolicy.md) + - [EventMatcherPolicyRequest](docs/EventMatcherPolicyRequest.md) + - [EventRequest](docs/EventRequest.md) + - [EventStats](docs/EventStats.md) + - [EventTopPerUser](docs/EventTopPerUser.md) + - [EventVolume](docs/EventVolume.md) + - [EventsRequestedEnum](docs/EventsRequestedEnum.md) + - [ExpiringBaseGrantModel](docs/ExpiringBaseGrantModel.md) + - [ExpressionPolicy](docs/ExpressionPolicy.md) + - [ExpressionPolicyRequest](docs/ExpressionPolicyRequest.md) + - [ExtraRoleObjectPermission](docs/ExtraRoleObjectPermission.md) + - [FileList](docs/FileList.md) + - [FleetConnector](docs/FleetConnector.md) + - [FleetConnectorRequest](docs/FleetConnectorRequest.md) + - [Flow](docs/Flow.md) + - [FlowChallengeResponseRequest](docs/FlowChallengeResponseRequest.md) + - [FlowDesignationEnum](docs/FlowDesignationEnum.md) + - [FlowDiagram](docs/FlowDiagram.md) + - [FlowErrorChallenge](docs/FlowErrorChallenge.md) + - [FlowInspection](docs/FlowInspection.md) + - [FlowInspectorPlan](docs/FlowInspectorPlan.md) + - [FlowLayoutEnum](docs/FlowLayoutEnum.md) + - [FlowRequest](docs/FlowRequest.md) + - [FlowSet](docs/FlowSet.md) + - [FlowStageBinding](docs/FlowStageBinding.md) + - [FlowStageBindingRequest](docs/FlowStageBindingRequest.md) + - [FooterLink](docs/FooterLink.md) + - [ForceBindingEnum](docs/ForceBindingEnum.md) + - [FormatEnum](docs/FormatEnum.md) + - [FrameChallenge](docs/FrameChallenge.md) + - [FrameChallengeResponseRequest](docs/FrameChallengeResponseRequest.md) + - [GenericError](docs/GenericError.md) + - [GeoIPPolicy](docs/GeoIPPolicy.md) + - [GeoIPPolicyCountriesObjInner](docs/GeoIPPolicyCountriesObjInner.md) + - [GeoIPPolicyRequest](docs/GeoIPPolicyRequest.md) + - [GeoipBindingEnum](docs/GeoipBindingEnum.md) + - [GlobalTaskStatus](docs/GlobalTaskStatus.md) + - [GoogleChromeConnector](docs/GoogleChromeConnector.md) + - [GoogleChromeConnectorRequest](docs/GoogleChromeConnectorRequest.md) + - [GoogleEndpointDevice](docs/GoogleEndpointDevice.md) + - [GoogleEndpointDeviceRequest](docs/GoogleEndpointDeviceRequest.md) + - [GoogleWorkspaceProvider](docs/GoogleWorkspaceProvider.md) + - [GoogleWorkspaceProviderGroup](docs/GoogleWorkspaceProviderGroup.md) + - [GoogleWorkspaceProviderGroupRequest](docs/GoogleWorkspaceProviderGroupRequest.md) + - [GoogleWorkspaceProviderMapping](docs/GoogleWorkspaceProviderMapping.md) + - [GoogleWorkspaceProviderMappingRequest](docs/GoogleWorkspaceProviderMappingRequest.md) + - [GoogleWorkspaceProviderRequest](docs/GoogleWorkspaceProviderRequest.md) + - [GoogleWorkspaceProviderUser](docs/GoogleWorkspaceProviderUser.md) + - [GoogleWorkspaceProviderUserRequest](docs/GoogleWorkspaceProviderUserRequest.md) + - [GrantTypesEnum](docs/GrantTypesEnum.md) + - [Group](docs/Group.md) + - [GroupKerberosSourceConnection](docs/GroupKerberosSourceConnection.md) + - [GroupKerberosSourceConnectionRequest](docs/GroupKerberosSourceConnectionRequest.md) + - [GroupLDAPSourceConnection](docs/GroupLDAPSourceConnection.md) + - [GroupLDAPSourceConnectionRequest](docs/GroupLDAPSourceConnectionRequest.md) + - [GroupMatchingModeEnum](docs/GroupMatchingModeEnum.md) + - [GroupOAuthSourceConnection](docs/GroupOAuthSourceConnection.md) + - [GroupOAuthSourceConnectionRequest](docs/GroupOAuthSourceConnectionRequest.md) + - [GroupPlexSourceConnection](docs/GroupPlexSourceConnection.md) + - [GroupPlexSourceConnectionRequest](docs/GroupPlexSourceConnectionRequest.md) + - [GroupRequest](docs/GroupRequest.md) + - [GroupSAMLSourceConnection](docs/GroupSAMLSourceConnection.md) + - [GroupSAMLSourceConnectionRequest](docs/GroupSAMLSourceConnectionRequest.md) + - [GroupSourceConnection](docs/GroupSourceConnection.md) + - [GroupSourceConnectionRequest](docs/GroupSourceConnectionRequest.md) + - [GroupTelegramSourceConnection](docs/GroupTelegramSourceConnection.md) + - [GroupTelegramSourceConnectionRequest](docs/GroupTelegramSourceConnectionRequest.md) + - [Hardware](docs/Hardware.md) + - [HardwareRequest](docs/HardwareRequest.md) + - [IdentificationChallenge](docs/IdentificationChallenge.md) + - [IdentificationChallengeResponseRequest](docs/IdentificationChallengeResponseRequest.md) + - [IdentificationStage](docs/IdentificationStage.md) + - [IdentificationStageRequest](docs/IdentificationStageRequest.md) + - [IframeLogoutChallenge](docs/IframeLogoutChallenge.md) + - [IframeLogoutChallengeResponseRequest](docs/IframeLogoutChallengeResponseRequest.md) + - [ImpersonationRequest](docs/ImpersonationRequest.md) + - [InitialPermissions](docs/InitialPermissions.md) + - [InitialPermissionsRequest](docs/InitialPermissionsRequest.md) + - [InstallID](docs/InstallID.md) + - [IntentEnum](docs/IntentEnum.md) + - [InvalidResponseActionEnum](docs/InvalidResponseActionEnum.md) + - [Invitation](docs/Invitation.md) + - [InvitationRequest](docs/InvitationRequest.md) + - [InvitationSendEmailRequest](docs/InvitationSendEmailRequest.md) + - [InvitationStage](docs/InvitationStage.md) + - [InvitationStageRequest](docs/InvitationStageRequest.md) + - [IssuerModeEnum](docs/IssuerModeEnum.md) + - [KadminTypeEnum](docs/KadminTypeEnum.md) + - [KerberosSource](docs/KerberosSource.md) + - [KerberosSourcePropertyMapping](docs/KerberosSourcePropertyMapping.md) + - [KerberosSourcePropertyMappingRequest](docs/KerberosSourcePropertyMappingRequest.md) + - [KerberosSourceRequest](docs/KerberosSourceRequest.md) + - [KeyTypeEnum](docs/KeyTypeEnum.md) + - [KubernetesServiceConnection](docs/KubernetesServiceConnection.md) + - [KubernetesServiceConnectionRequest](docs/KubernetesServiceConnectionRequest.md) + - [LDAPAPIAccessMode](docs/LDAPAPIAccessMode.md) + - [LDAPCheckAccess](docs/LDAPCheckAccess.md) + - [LDAPDebug](docs/LDAPDebug.md) + - [LDAPOutpostConfig](docs/LDAPOutpostConfig.md) + - [LDAPProvider](docs/LDAPProvider.md) + - [LDAPProviderRequest](docs/LDAPProviderRequest.md) + - [LDAPSource](docs/LDAPSource.md) + - [LDAPSourcePropertyMapping](docs/LDAPSourcePropertyMapping.md) + - [LDAPSourcePropertyMappingRequest](docs/LDAPSourcePropertyMappingRequest.md) + - [LDAPSourceRequest](docs/LDAPSourceRequest.md) + - [LangEnum](docs/LangEnum.md) + - [LastTaskStatusEnum](docs/LastTaskStatusEnum.md) + - [License](docs/License.md) + - [LicenseFlagsEnum](docs/LicenseFlagsEnum.md) + - [LicenseForecast](docs/LicenseForecast.md) + - [LicenseRequest](docs/LicenseRequest.md) + - [LicenseStatusEnum](docs/LicenseStatusEnum.md) + - [LicenseSummary](docs/LicenseSummary.md) + - [LicenseSummaryStatusEnum](docs/LicenseSummaryStatusEnum.md) + - [LifecycleIteration](docs/LifecycleIteration.md) + - [LifecycleIterationRequest](docs/LifecycleIterationRequest.md) + - [LifecycleIterationStateEnum](docs/LifecycleIterationStateEnum.md) + - [LifecycleRule](docs/LifecycleRule.md) + - [LifecycleRuleRequest](docs/LifecycleRuleRequest.md) + - [Link](docs/Link.md) + - [LogEvent](docs/LogEvent.md) + - [LogLevelEnum](docs/LogLevelEnum.md) + - [LoginChallengeTypes](docs/LoginChallengeTypes.md) + - [LoginSource](docs/LoginSource.md) + - [LogoutURL](docs/LogoutURL.md) + - [MDMConfigRequest](docs/MDMConfigRequest.md) + - [MDMConfigResponse](docs/MDMConfigResponse.md) + - [MatchingModeEnum](docs/MatchingModeEnum.md) + - [Metadata](docs/Metadata.md) + - [MicrosoftEntraProvider](docs/MicrosoftEntraProvider.md) + - [MicrosoftEntraProviderGroup](docs/MicrosoftEntraProviderGroup.md) + - [MicrosoftEntraProviderGroupRequest](docs/MicrosoftEntraProviderGroupRequest.md) + - [MicrosoftEntraProviderMapping](docs/MicrosoftEntraProviderMapping.md) + - [MicrosoftEntraProviderMappingRequest](docs/MicrosoftEntraProviderMappingRequest.md) + - [MicrosoftEntraProviderRequest](docs/MicrosoftEntraProviderRequest.md) + - [MicrosoftEntraProviderUser](docs/MicrosoftEntraProviderUser.md) + - [MicrosoftEntraProviderUserRequest](docs/MicrosoftEntraProviderUserRequest.md) + - [ModelEnum](docs/ModelEnum.md) + - [ModelRequest](docs/ModelRequest.md) + - [MutualTLSStage](docs/MutualTLSStage.md) + - [MutualTLSStageRequest](docs/MutualTLSStageRequest.md) + - [NativeLogoutChallenge](docs/NativeLogoutChallenge.md) + - [NativeLogoutChallengeResponseRequest](docs/NativeLogoutChallengeResponseRequest.md) + - [Network](docs/Network.md) + - [NetworkBindingEnum](docs/NetworkBindingEnum.md) + - [NetworkInterface](docs/NetworkInterface.md) + - [NetworkInterfaceRequest](docs/NetworkInterfaceRequest.md) + - [NetworkRequest](docs/NetworkRequest.md) + - [NotConfiguredActionEnum](docs/NotConfiguredActionEnum.md) + - [Notification](docs/Notification.md) + - [NotificationRequest](docs/NotificationRequest.md) + - [NotificationRule](docs/NotificationRule.md) + - [NotificationRuleRequest](docs/NotificationRuleRequest.md) + - [NotificationTransport](docs/NotificationTransport.md) + - [NotificationTransportRequest](docs/NotificationTransportRequest.md) + - [NotificationTransportTest](docs/NotificationTransportTest.md) + - [NotificationWebhookMapping](docs/NotificationWebhookMapping.md) + - [NotificationWebhookMappingRequest](docs/NotificationWebhookMappingRequest.md) + - [OAuth2Provider](docs/OAuth2Provider.md) + - [OAuth2ProviderLogoutMethodEnum](docs/OAuth2ProviderLogoutMethodEnum.md) + - [OAuth2ProviderRequest](docs/OAuth2ProviderRequest.md) + - [OAuth2ProviderSetupURLs](docs/OAuth2ProviderSetupURLs.md) + - [OAuthDeviceCodeChallenge](docs/OAuthDeviceCodeChallenge.md) + - [OAuthDeviceCodeChallengeResponseRequest](docs/OAuthDeviceCodeChallengeResponseRequest.md) + - [OAuthDeviceCodeFinishChallenge](docs/OAuthDeviceCodeFinishChallenge.md) + - [OAuthDeviceCodeFinishChallengeResponseRequest](docs/OAuthDeviceCodeFinishChallengeResponseRequest.md) + - [OAuthSource](docs/OAuthSource.md) + - [OAuthSourcePropertyMapping](docs/OAuthSourcePropertyMapping.md) + - [OAuthSourcePropertyMappingRequest](docs/OAuthSourcePropertyMappingRequest.md) + - [OAuthSourceRequest](docs/OAuthSourceRequest.md) + - [OpenIDConnectConfiguration](docs/OpenIDConnectConfiguration.md) + - [OperatingSystem](docs/OperatingSystem.md) + - [OperatingSystemRequest](docs/OperatingSystemRequest.md) + - [OutgoingSyncDeleteAction](docs/OutgoingSyncDeleteAction.md) + - [Outpost](docs/Outpost.md) + - [OutpostDefaultConfig](docs/OutpostDefaultConfig.md) + - [OutpostHealth](docs/OutpostHealth.md) + - [OutpostRequest](docs/OutpostRequest.md) + - [OutpostTypeEnum](docs/OutpostTypeEnum.md) + - [PKCEMethodEnum](docs/PKCEMethodEnum.md) + - [PaginatedAccountLockdownStageList](docs/PaginatedAccountLockdownStageList.md) + - [PaginatedAgentConnectorList](docs/PaginatedAgentConnectorList.md) + - [PaginatedAppleIndependentSecureEnclaveList](docs/PaginatedAppleIndependentSecureEnclaveList.md) + - [PaginatedApplicationEntitlementList](docs/PaginatedApplicationEntitlementList.md) + - [PaginatedApplicationList](docs/PaginatedApplicationList.md) + - [PaginatedAuthenticatedSessionList](docs/PaginatedAuthenticatedSessionList.md) + - [PaginatedAuthenticatorDuoStageList](docs/PaginatedAuthenticatorDuoStageList.md) + - [PaginatedAuthenticatorEmailStageList](docs/PaginatedAuthenticatorEmailStageList.md) + - [PaginatedAuthenticatorEndpointGDTCStageList](docs/PaginatedAuthenticatorEndpointGDTCStageList.md) + - [PaginatedAuthenticatorSMSStageList](docs/PaginatedAuthenticatorSMSStageList.md) + - [PaginatedAuthenticatorStaticStageList](docs/PaginatedAuthenticatorStaticStageList.md) + - [PaginatedAuthenticatorTOTPStageList](docs/PaginatedAuthenticatorTOTPStageList.md) + - [PaginatedAuthenticatorValidateStageList](docs/PaginatedAuthenticatorValidateStageList.md) + - [PaginatedAuthenticatorWebAuthnStageList](docs/PaginatedAuthenticatorWebAuthnStageList.md) + - [PaginatedBlueprintInstanceList](docs/PaginatedBlueprintInstanceList.md) + - [PaginatedBrandList](docs/PaginatedBrandList.md) + - [PaginatedCaptchaStageList](docs/PaginatedCaptchaStageList.md) + - [PaginatedCertificateKeyPairList](docs/PaginatedCertificateKeyPairList.md) + - [PaginatedConnectionTokenList](docs/PaginatedConnectionTokenList.md) + - [PaginatedConnectorList](docs/PaginatedConnectorList.md) + - [PaginatedConsentStageList](docs/PaginatedConsentStageList.md) + - [PaginatedDataExportList](docs/PaginatedDataExportList.md) + - [PaginatedDenyStageList](docs/PaginatedDenyStageList.md) + - [PaginatedDeviceAccessGroupList](docs/PaginatedDeviceAccessGroupList.md) + - [PaginatedDeviceUserBindingList](docs/PaginatedDeviceUserBindingList.md) + - [PaginatedDockerServiceConnectionList](docs/PaginatedDockerServiceConnectionList.md) + - [PaginatedDomainList](docs/PaginatedDomainList.md) + - [PaginatedDummyPolicyList](docs/PaginatedDummyPolicyList.md) + - [PaginatedDummyStageList](docs/PaginatedDummyStageList.md) + - [PaginatedDuoDeviceList](docs/PaginatedDuoDeviceList.md) + - [PaginatedEmailDeviceList](docs/PaginatedEmailDeviceList.md) + - [PaginatedEmailStageList](docs/PaginatedEmailStageList.md) + - [PaginatedEndpointDeviceList](docs/PaginatedEndpointDeviceList.md) + - [PaginatedEndpointList](docs/PaginatedEndpointList.md) + - [PaginatedEndpointStageList](docs/PaginatedEndpointStageList.md) + - [PaginatedEnrollmentTokenList](docs/PaginatedEnrollmentTokenList.md) + - [PaginatedEventList](docs/PaginatedEventList.md) + - [PaginatedEventMatcherPolicyList](docs/PaginatedEventMatcherPolicyList.md) + - [PaginatedExpiringBaseGrantModelList](docs/PaginatedExpiringBaseGrantModelList.md) + - [PaginatedExpressionPolicyList](docs/PaginatedExpressionPolicyList.md) + - [PaginatedExtraRoleObjectPermissionList](docs/PaginatedExtraRoleObjectPermissionList.md) + - [PaginatedFleetConnectorList](docs/PaginatedFleetConnectorList.md) + - [PaginatedFlowList](docs/PaginatedFlowList.md) + - [PaginatedFlowStageBindingList](docs/PaginatedFlowStageBindingList.md) + - [PaginatedGeoIPPolicyList](docs/PaginatedGeoIPPolicyList.md) + - [PaginatedGoogleChromeConnectorList](docs/PaginatedGoogleChromeConnectorList.md) + - [PaginatedGoogleEndpointDeviceList](docs/PaginatedGoogleEndpointDeviceList.md) + - [PaginatedGoogleWorkspaceProviderGroupList](docs/PaginatedGoogleWorkspaceProviderGroupList.md) + - [PaginatedGoogleWorkspaceProviderList](docs/PaginatedGoogleWorkspaceProviderList.md) + - [PaginatedGoogleWorkspaceProviderMappingList](docs/PaginatedGoogleWorkspaceProviderMappingList.md) + - [PaginatedGoogleWorkspaceProviderUserList](docs/PaginatedGoogleWorkspaceProviderUserList.md) + - [PaginatedGroupKerberosSourceConnectionList](docs/PaginatedGroupKerberosSourceConnectionList.md) + - [PaginatedGroupLDAPSourceConnectionList](docs/PaginatedGroupLDAPSourceConnectionList.md) + - [PaginatedGroupList](docs/PaginatedGroupList.md) + - [PaginatedGroupOAuthSourceConnectionList](docs/PaginatedGroupOAuthSourceConnectionList.md) + - [PaginatedGroupPlexSourceConnectionList](docs/PaginatedGroupPlexSourceConnectionList.md) + - [PaginatedGroupSAMLSourceConnectionList](docs/PaginatedGroupSAMLSourceConnectionList.md) + - [PaginatedGroupSourceConnectionList](docs/PaginatedGroupSourceConnectionList.md) + - [PaginatedGroupTelegramSourceConnectionList](docs/PaginatedGroupTelegramSourceConnectionList.md) + - [PaginatedIdentificationStageList](docs/PaginatedIdentificationStageList.md) + - [PaginatedInitialPermissionsList](docs/PaginatedInitialPermissionsList.md) + - [PaginatedInvitationList](docs/PaginatedInvitationList.md) + - [PaginatedInvitationStageList](docs/PaginatedInvitationStageList.md) + - [PaginatedKerberosSourceList](docs/PaginatedKerberosSourceList.md) + - [PaginatedKerberosSourcePropertyMappingList](docs/PaginatedKerberosSourcePropertyMappingList.md) + - [PaginatedKubernetesServiceConnectionList](docs/PaginatedKubernetesServiceConnectionList.md) + - [PaginatedLDAPOutpostConfigList](docs/PaginatedLDAPOutpostConfigList.md) + - [PaginatedLDAPProviderList](docs/PaginatedLDAPProviderList.md) + - [PaginatedLDAPSourceList](docs/PaginatedLDAPSourceList.md) + - [PaginatedLDAPSourcePropertyMappingList](docs/PaginatedLDAPSourcePropertyMappingList.md) + - [PaginatedLicenseList](docs/PaginatedLicenseList.md) + - [PaginatedLifecycleIterationList](docs/PaginatedLifecycleIterationList.md) + - [PaginatedLifecycleRuleList](docs/PaginatedLifecycleRuleList.md) + - [PaginatedMicrosoftEntraProviderGroupList](docs/PaginatedMicrosoftEntraProviderGroupList.md) + - [PaginatedMicrosoftEntraProviderList](docs/PaginatedMicrosoftEntraProviderList.md) + - [PaginatedMicrosoftEntraProviderMappingList](docs/PaginatedMicrosoftEntraProviderMappingList.md) + - [PaginatedMicrosoftEntraProviderUserList](docs/PaginatedMicrosoftEntraProviderUserList.md) + - [PaginatedMutualTLSStageList](docs/PaginatedMutualTLSStageList.md) + - [PaginatedNotificationList](docs/PaginatedNotificationList.md) + - [PaginatedNotificationRuleList](docs/PaginatedNotificationRuleList.md) + - [PaginatedNotificationTransportList](docs/PaginatedNotificationTransportList.md) + - [PaginatedNotificationWebhookMappingList](docs/PaginatedNotificationWebhookMappingList.md) + - [PaginatedOAuth2ProviderList](docs/PaginatedOAuth2ProviderList.md) + - [PaginatedOAuthSourceList](docs/PaginatedOAuthSourceList.md) + - [PaginatedOAuthSourcePropertyMappingList](docs/PaginatedOAuthSourcePropertyMappingList.md) + - [PaginatedOutpostList](docs/PaginatedOutpostList.md) + - [PaginatedPasswordExpiryPolicyList](docs/PaginatedPasswordExpiryPolicyList.md) + - [PaginatedPasswordPolicyList](docs/PaginatedPasswordPolicyList.md) + - [PaginatedPasswordStageList](docs/PaginatedPasswordStageList.md) + - [PaginatedPermissionList](docs/PaginatedPermissionList.md) + - [PaginatedPlexSourceList](docs/PaginatedPlexSourceList.md) + - [PaginatedPlexSourcePropertyMappingList](docs/PaginatedPlexSourcePropertyMappingList.md) + - [PaginatedPolicyBindingList](docs/PaginatedPolicyBindingList.md) + - [PaginatedPolicyList](docs/PaginatedPolicyList.md) + - [PaginatedPromptList](docs/PaginatedPromptList.md) + - [PaginatedPromptStageList](docs/PaginatedPromptStageList.md) + - [PaginatedPropertyMappingList](docs/PaginatedPropertyMappingList.md) + - [PaginatedProviderList](docs/PaginatedProviderList.md) + - [PaginatedProxyOutpostConfigList](docs/PaginatedProxyOutpostConfigList.md) + - [PaginatedProxyProviderList](docs/PaginatedProxyProviderList.md) + - [PaginatedRACPropertyMappingList](docs/PaginatedRACPropertyMappingList.md) + - [PaginatedRACProviderList](docs/PaginatedRACProviderList.md) + - [PaginatedRadiusOutpostConfigList](docs/PaginatedRadiusOutpostConfigList.md) + - [PaginatedRadiusProviderList](docs/PaginatedRadiusProviderList.md) + - [PaginatedRadiusProviderPropertyMappingList](docs/PaginatedRadiusProviderPropertyMappingList.md) + - [PaginatedRedirectStageList](docs/PaginatedRedirectStageList.md) + - [PaginatedReputationList](docs/PaginatedReputationList.md) + - [PaginatedReputationPolicyList](docs/PaginatedReputationPolicyList.md) + - [PaginatedRoleAssignedObjectPermissionList](docs/PaginatedRoleAssignedObjectPermissionList.md) + - [PaginatedRoleList](docs/PaginatedRoleList.md) + - [PaginatedSAMLPropertyMappingList](docs/PaginatedSAMLPropertyMappingList.md) + - [PaginatedSAMLProviderList](docs/PaginatedSAMLProviderList.md) + - [PaginatedSAMLSourceList](docs/PaginatedSAMLSourceList.md) + - [PaginatedSAMLSourcePropertyMappingList](docs/PaginatedSAMLSourcePropertyMappingList.md) + - [PaginatedSCIMMappingList](docs/PaginatedSCIMMappingList.md) + - [PaginatedSCIMProviderGroupList](docs/PaginatedSCIMProviderGroupList.md) + - [PaginatedSCIMProviderList](docs/PaginatedSCIMProviderList.md) + - [PaginatedSCIMProviderUserList](docs/PaginatedSCIMProviderUserList.md) + - [PaginatedSCIMSourceGroupList](docs/PaginatedSCIMSourceGroupList.md) + - [PaginatedSCIMSourceList](docs/PaginatedSCIMSourceList.md) + - [PaginatedSCIMSourcePropertyMappingList](docs/PaginatedSCIMSourcePropertyMappingList.md) + - [PaginatedSCIMSourceUserList](docs/PaginatedSCIMSourceUserList.md) + - [PaginatedSMSDeviceList](docs/PaginatedSMSDeviceList.md) + - [PaginatedSSFProviderList](docs/PaginatedSSFProviderList.md) + - [PaginatedSSFStreamList](docs/PaginatedSSFStreamList.md) + - [PaginatedScheduleList](docs/PaginatedScheduleList.md) + - [PaginatedScopeMappingList](docs/PaginatedScopeMappingList.md) + - [PaginatedServiceConnectionList](docs/PaginatedServiceConnectionList.md) + - [PaginatedSourceList](docs/PaginatedSourceList.md) + - [PaginatedSourceStageList](docs/PaginatedSourceStageList.md) + - [PaginatedStageList](docs/PaginatedStageList.md) + - [PaginatedStaticDeviceList](docs/PaginatedStaticDeviceList.md) + - [PaginatedTOTPDeviceList](docs/PaginatedTOTPDeviceList.md) + - [PaginatedTaskList](docs/PaginatedTaskList.md) + - [PaginatedTelegramSourceList](docs/PaginatedTelegramSourceList.md) + - [PaginatedTelegramSourcePropertyMappingList](docs/PaginatedTelegramSourcePropertyMappingList.md) + - [PaginatedTenantList](docs/PaginatedTenantList.md) + - [PaginatedTokenList](docs/PaginatedTokenList.md) + - [PaginatedTokenModelList](docs/PaginatedTokenModelList.md) + - [PaginatedUniquePasswordPolicyList](docs/PaginatedUniquePasswordPolicyList.md) + - [PaginatedUserConsentList](docs/PaginatedUserConsentList.md) + - [PaginatedUserDeleteStageList](docs/PaginatedUserDeleteStageList.md) + - [PaginatedUserKerberosSourceConnectionList](docs/PaginatedUserKerberosSourceConnectionList.md) + - [PaginatedUserLDAPSourceConnectionList](docs/PaginatedUserLDAPSourceConnectionList.md) + - [PaginatedUserList](docs/PaginatedUserList.md) + - [PaginatedUserLoginStageList](docs/PaginatedUserLoginStageList.md) + - [PaginatedUserLogoutStageList](docs/PaginatedUserLogoutStageList.md) + - [PaginatedUserOAuthSourceConnectionList](docs/PaginatedUserOAuthSourceConnectionList.md) + - [PaginatedUserPlexSourceConnectionList](docs/PaginatedUserPlexSourceConnectionList.md) + - [PaginatedUserSAMLSourceConnectionList](docs/PaginatedUserSAMLSourceConnectionList.md) + - [PaginatedUserSourceConnectionList](docs/PaginatedUserSourceConnectionList.md) + - [PaginatedUserTelegramSourceConnectionList](docs/PaginatedUserTelegramSourceConnectionList.md) + - [PaginatedUserWriteStageList](docs/PaginatedUserWriteStageList.md) + - [PaginatedWSFederationProviderList](docs/PaginatedWSFederationProviderList.md) + - [PaginatedWebAuthnDeviceList](docs/PaginatedWebAuthnDeviceList.md) + - [PaginatedWebAuthnDeviceTypeList](docs/PaginatedWebAuthnDeviceTypeList.md) + - [Pagination](docs/Pagination.md) + - [PartialGroup](docs/PartialGroup.md) + - [PartialUser](docs/PartialUser.md) + - [PasswordChallenge](docs/PasswordChallenge.md) + - [PasswordChallengeResponseRequest](docs/PasswordChallengeResponseRequest.md) + - [PasswordExpiryPolicy](docs/PasswordExpiryPolicy.md) + - [PasswordExpiryPolicyRequest](docs/PasswordExpiryPolicyRequest.md) + - [PasswordPolicy](docs/PasswordPolicy.md) + - [PasswordPolicyRequest](docs/PasswordPolicyRequest.md) + - [PasswordStage](docs/PasswordStage.md) + - [PasswordStageRequest](docs/PasswordStageRequest.md) + - [PatchedAccountLockdownStageRequest](docs/PatchedAccountLockdownStageRequest.md) + - [PatchedAgentConnectorRequest](docs/PatchedAgentConnectorRequest.md) + - [PatchedAppleIndependentSecureEnclaveRequest](docs/PatchedAppleIndependentSecureEnclaveRequest.md) + - [PatchedApplicationEntitlementRequest](docs/PatchedApplicationEntitlementRequest.md) + - [PatchedApplicationRequest](docs/PatchedApplicationRequest.md) + - [PatchedAuthenticatorDuoStageRequest](docs/PatchedAuthenticatorDuoStageRequest.md) + - [PatchedAuthenticatorEmailStageRequest](docs/PatchedAuthenticatorEmailStageRequest.md) + - [PatchedAuthenticatorEndpointGDTCStageRequest](docs/PatchedAuthenticatorEndpointGDTCStageRequest.md) + - [PatchedAuthenticatorSMSStageRequest](docs/PatchedAuthenticatorSMSStageRequest.md) + - [PatchedAuthenticatorStaticStageRequest](docs/PatchedAuthenticatorStaticStageRequest.md) + - [PatchedAuthenticatorTOTPStageRequest](docs/PatchedAuthenticatorTOTPStageRequest.md) + - [PatchedAuthenticatorValidateStageRequest](docs/PatchedAuthenticatorValidateStageRequest.md) + - [PatchedAuthenticatorWebAuthnStageRequest](docs/PatchedAuthenticatorWebAuthnStageRequest.md) + - [PatchedBlueprintInstanceRequest](docs/PatchedBlueprintInstanceRequest.md) + - [PatchedBrandRequest](docs/PatchedBrandRequest.md) + - [PatchedCaptchaStageRequest](docs/PatchedCaptchaStageRequest.md) + - [PatchedCertificateKeyPairRequest](docs/PatchedCertificateKeyPairRequest.md) + - [PatchedConnectionTokenRequest](docs/PatchedConnectionTokenRequest.md) + - [PatchedConsentStageRequest](docs/PatchedConsentStageRequest.md) + - [PatchedDenyStageRequest](docs/PatchedDenyStageRequest.md) + - [PatchedDeviceAccessGroupRequest](docs/PatchedDeviceAccessGroupRequest.md) + - [PatchedDeviceUserBindingRequest](docs/PatchedDeviceUserBindingRequest.md) + - [PatchedDockerServiceConnectionRequest](docs/PatchedDockerServiceConnectionRequest.md) + - [PatchedDomainRequest](docs/PatchedDomainRequest.md) + - [PatchedDummyPolicyRequest](docs/PatchedDummyPolicyRequest.md) + - [PatchedDummyStageRequest](docs/PatchedDummyStageRequest.md) + - [PatchedDuoDeviceRequest](docs/PatchedDuoDeviceRequest.md) + - [PatchedEmailDeviceRequest](docs/PatchedEmailDeviceRequest.md) + - [PatchedEmailStageRequest](docs/PatchedEmailStageRequest.md) + - [PatchedEndpointDeviceRequest](docs/PatchedEndpointDeviceRequest.md) + - [PatchedEndpointRequest](docs/PatchedEndpointRequest.md) + - [PatchedEndpointStageRequest](docs/PatchedEndpointStageRequest.md) + - [PatchedEnrollmentTokenRequest](docs/PatchedEnrollmentTokenRequest.md) + - [PatchedEventMatcherPolicyRequest](docs/PatchedEventMatcherPolicyRequest.md) + - [PatchedEventRequest](docs/PatchedEventRequest.md) + - [PatchedExpressionPolicyRequest](docs/PatchedExpressionPolicyRequest.md) + - [PatchedFleetConnectorRequest](docs/PatchedFleetConnectorRequest.md) + - [PatchedFlowRequest](docs/PatchedFlowRequest.md) + - [PatchedFlowStageBindingRequest](docs/PatchedFlowStageBindingRequest.md) + - [PatchedGeoIPPolicyRequest](docs/PatchedGeoIPPolicyRequest.md) + - [PatchedGoogleChromeConnectorRequest](docs/PatchedGoogleChromeConnectorRequest.md) + - [PatchedGoogleEndpointDeviceRequest](docs/PatchedGoogleEndpointDeviceRequest.md) + - [PatchedGoogleWorkspaceProviderMappingRequest](docs/PatchedGoogleWorkspaceProviderMappingRequest.md) + - [PatchedGoogleWorkspaceProviderRequest](docs/PatchedGoogleWorkspaceProviderRequest.md) + - [PatchedGroupKerberosSourceConnectionRequest](docs/PatchedGroupKerberosSourceConnectionRequest.md) + - [PatchedGroupLDAPSourceConnectionRequest](docs/PatchedGroupLDAPSourceConnectionRequest.md) + - [PatchedGroupOAuthSourceConnectionRequest](docs/PatchedGroupOAuthSourceConnectionRequest.md) + - [PatchedGroupPlexSourceConnectionRequest](docs/PatchedGroupPlexSourceConnectionRequest.md) + - [PatchedGroupRequest](docs/PatchedGroupRequest.md) + - [PatchedGroupSAMLSourceConnectionRequest](docs/PatchedGroupSAMLSourceConnectionRequest.md) + - [PatchedGroupSourceConnectionRequest](docs/PatchedGroupSourceConnectionRequest.md) + - [PatchedGroupTelegramSourceConnectionRequest](docs/PatchedGroupTelegramSourceConnectionRequest.md) + - [PatchedIdentificationStageRequest](docs/PatchedIdentificationStageRequest.md) + - [PatchedInitialPermissionsRequest](docs/PatchedInitialPermissionsRequest.md) + - [PatchedInvitationRequest](docs/PatchedInvitationRequest.md) + - [PatchedInvitationStageRequest](docs/PatchedInvitationStageRequest.md) + - [PatchedKerberosSourcePropertyMappingRequest](docs/PatchedKerberosSourcePropertyMappingRequest.md) + - [PatchedKerberosSourceRequest](docs/PatchedKerberosSourceRequest.md) + - [PatchedKubernetesServiceConnectionRequest](docs/PatchedKubernetesServiceConnectionRequest.md) + - [PatchedLDAPProviderRequest](docs/PatchedLDAPProviderRequest.md) + - [PatchedLDAPSourcePropertyMappingRequest](docs/PatchedLDAPSourcePropertyMappingRequest.md) + - [PatchedLDAPSourceRequest](docs/PatchedLDAPSourceRequest.md) + - [PatchedLicenseRequest](docs/PatchedLicenseRequest.md) + - [PatchedLifecycleRuleRequest](docs/PatchedLifecycleRuleRequest.md) + - [PatchedMicrosoftEntraProviderMappingRequest](docs/PatchedMicrosoftEntraProviderMappingRequest.md) + - [PatchedMicrosoftEntraProviderRequest](docs/PatchedMicrosoftEntraProviderRequest.md) + - [PatchedMutualTLSStageRequest](docs/PatchedMutualTLSStageRequest.md) + - [PatchedNotificationRequest](docs/PatchedNotificationRequest.md) + - [PatchedNotificationRuleRequest](docs/PatchedNotificationRuleRequest.md) + - [PatchedNotificationTransportRequest](docs/PatchedNotificationTransportRequest.md) + - [PatchedNotificationWebhookMappingRequest](docs/PatchedNotificationWebhookMappingRequest.md) + - [PatchedOAuth2ProviderRequest](docs/PatchedOAuth2ProviderRequest.md) + - [PatchedOAuthSourcePropertyMappingRequest](docs/PatchedOAuthSourcePropertyMappingRequest.md) + - [PatchedOAuthSourceRequest](docs/PatchedOAuthSourceRequest.md) + - [PatchedOutpostRequest](docs/PatchedOutpostRequest.md) + - [PatchedPasswordExpiryPolicyRequest](docs/PatchedPasswordExpiryPolicyRequest.md) + - [PatchedPasswordPolicyRequest](docs/PatchedPasswordPolicyRequest.md) + - [PatchedPasswordStageRequest](docs/PatchedPasswordStageRequest.md) + - [PatchedPermissionAssignRequest](docs/PatchedPermissionAssignRequest.md) + - [PatchedPlexSourcePropertyMappingRequest](docs/PatchedPlexSourcePropertyMappingRequest.md) + - [PatchedPlexSourceRequest](docs/PatchedPlexSourceRequest.md) + - [PatchedPolicyBindingRequest](docs/PatchedPolicyBindingRequest.md) + - [PatchedPromptRequest](docs/PatchedPromptRequest.md) + - [PatchedPromptStageRequest](docs/PatchedPromptStageRequest.md) + - [PatchedProxyProviderRequest](docs/PatchedProxyProviderRequest.md) + - [PatchedRACPropertyMappingRequest](docs/PatchedRACPropertyMappingRequest.md) + - [PatchedRACProviderRequest](docs/PatchedRACProviderRequest.md) + - [PatchedRadiusProviderPropertyMappingRequest](docs/PatchedRadiusProviderPropertyMappingRequest.md) + - [PatchedRadiusProviderRequest](docs/PatchedRadiusProviderRequest.md) + - [PatchedRedirectStageRequest](docs/PatchedRedirectStageRequest.md) + - [PatchedReputationPolicyRequest](docs/PatchedReputationPolicyRequest.md) + - [PatchedRoleRequest](docs/PatchedRoleRequest.md) + - [PatchedSAMLPropertyMappingRequest](docs/PatchedSAMLPropertyMappingRequest.md) + - [PatchedSAMLProviderRequest](docs/PatchedSAMLProviderRequest.md) + - [PatchedSAMLSourcePropertyMappingRequest](docs/PatchedSAMLSourcePropertyMappingRequest.md) + - [PatchedSAMLSourceRequest](docs/PatchedSAMLSourceRequest.md) + - [PatchedSCIMMappingRequest](docs/PatchedSCIMMappingRequest.md) + - [PatchedSCIMProviderRequest](docs/PatchedSCIMProviderRequest.md) + - [PatchedSCIMSourceGroupRequest](docs/PatchedSCIMSourceGroupRequest.md) + - [PatchedSCIMSourcePropertyMappingRequest](docs/PatchedSCIMSourcePropertyMappingRequest.md) + - [PatchedSCIMSourceRequest](docs/PatchedSCIMSourceRequest.md) + - [PatchedSCIMSourceUserRequest](docs/PatchedSCIMSourceUserRequest.md) + - [PatchedSMSDeviceRequest](docs/PatchedSMSDeviceRequest.md) + - [PatchedSSFProviderRequest](docs/PatchedSSFProviderRequest.md) + - [PatchedScheduleRequest](docs/PatchedScheduleRequest.md) + - [PatchedScopeMappingRequest](docs/PatchedScopeMappingRequest.md) + - [PatchedSettingsRequest](docs/PatchedSettingsRequest.md) + - [PatchedSettingsRequestFlags](docs/PatchedSettingsRequestFlags.md) + - [PatchedSourceStageRequest](docs/PatchedSourceStageRequest.md) + - [PatchedStaticDeviceRequest](docs/PatchedStaticDeviceRequest.md) + - [PatchedTOTPDeviceRequest](docs/PatchedTOTPDeviceRequest.md) + - [PatchedTelegramSourcePropertyMappingRequest](docs/PatchedTelegramSourcePropertyMappingRequest.md) + - [PatchedTelegramSourceRequest](docs/PatchedTelegramSourceRequest.md) + - [PatchedTenantRequest](docs/PatchedTenantRequest.md) + - [PatchedTokenRequest](docs/PatchedTokenRequest.md) + - [PatchedUniquePasswordPolicyRequest](docs/PatchedUniquePasswordPolicyRequest.md) + - [PatchedUserDeleteStageRequest](docs/PatchedUserDeleteStageRequest.md) + - [PatchedUserKerberosSourceConnectionRequest](docs/PatchedUserKerberosSourceConnectionRequest.md) + - [PatchedUserLDAPSourceConnectionRequest](docs/PatchedUserLDAPSourceConnectionRequest.md) + - [PatchedUserLoginStageRequest](docs/PatchedUserLoginStageRequest.md) + - [PatchedUserLogoutStageRequest](docs/PatchedUserLogoutStageRequest.md) + - [PatchedUserOAuthSourceConnectionRequest](docs/PatchedUserOAuthSourceConnectionRequest.md) + - [PatchedUserPlexSourceConnectionRequest](docs/PatchedUserPlexSourceConnectionRequest.md) + - [PatchedUserRequest](docs/PatchedUserRequest.md) + - [PatchedUserSAMLSourceConnectionRequest](docs/PatchedUserSAMLSourceConnectionRequest.md) + - [PatchedUserSourceConnectionRequest](docs/PatchedUserSourceConnectionRequest.md) + - [PatchedUserTelegramSourceConnectionRequest](docs/PatchedUserTelegramSourceConnectionRequest.md) + - [PatchedUserWriteStageRequest](docs/PatchedUserWriteStageRequest.md) + - [PatchedWSFederationProviderRequest](docs/PatchedWSFederationProviderRequest.md) + - [PatchedWebAuthnDeviceRequest](docs/PatchedWebAuthnDeviceRequest.md) + - [Permission](docs/Permission.md) + - [PermissionAssignRequest](docs/PermissionAssignRequest.md) + - [PermissionAssignResult](docs/PermissionAssignResult.md) + - [PlexAuthenticationChallenge](docs/PlexAuthenticationChallenge.md) + - [PlexAuthenticationChallengeResponseRequest](docs/PlexAuthenticationChallengeResponseRequest.md) + - [PlexSource](docs/PlexSource.md) + - [PlexSourcePropertyMapping](docs/PlexSourcePropertyMapping.md) + - [PlexSourcePropertyMappingRequest](docs/PlexSourcePropertyMappingRequest.md) + - [PlexSourceRequest](docs/PlexSourceRequest.md) + - [PlexTokenRedeemRequest](docs/PlexTokenRedeemRequest.md) + - [Policy](docs/Policy.md) + - [PolicyBinding](docs/PolicyBinding.md) + - [PolicyBindingRequest](docs/PolicyBindingRequest.md) + - [PolicyEngineMode](docs/PolicyEngineMode.md) + - [PolicyTestRequest](docs/PolicyTestRequest.md) + - [PolicyTestResult](docs/PolicyTestResult.md) + - [Process](docs/Process.md) + - [ProcessRequest](docs/ProcessRequest.md) + - [Prompt](docs/Prompt.md) + - [PromptChallenge](docs/PromptChallenge.md) + - [PromptChallengeResponseRequest](docs/PromptChallengeResponseRequest.md) + - [PromptChoice](docs/PromptChoice.md) + - [PromptRequest](docs/PromptRequest.md) + - [PromptStage](docs/PromptStage.md) + - [PromptStageRequest](docs/PromptStageRequest.md) + - [PromptTypeEnum](docs/PromptTypeEnum.md) + - [PropertyMapping](docs/PropertyMapping.md) + - [PropertyMappingPreview](docs/PropertyMappingPreview.md) + - [PropertyMappingTestRequest](docs/PropertyMappingTestRequest.md) + - [PropertyMappingTestResult](docs/PropertyMappingTestResult.md) + - [ProtocolEnum](docs/ProtocolEnum.md) + - [Provider](docs/Provider.md) + - [ProviderEnum](docs/ProviderEnum.md) + - [ProviderModelEnum](docs/ProviderModelEnum.md) + - [ProviderTypeEnum](docs/ProviderTypeEnum.md) + - [ProxyMode](docs/ProxyMode.md) + - [ProxyOutpostConfig](docs/ProxyOutpostConfig.md) + - [ProxyProvider](docs/ProxyProvider.md) + - [ProxyProviderRequest](docs/ProxyProviderRequest.md) + - [RACPropertyMapping](docs/RACPropertyMapping.md) + - [RACPropertyMappingRequest](docs/RACPropertyMappingRequest.md) + - [RACProvider](docs/RACProvider.md) + - [RACProviderRequest](docs/RACProviderRequest.md) + - [RadiusCheckAccess](docs/RadiusCheckAccess.md) + - [RadiusOutpostConfig](docs/RadiusOutpostConfig.md) + - [RadiusProvider](docs/RadiusProvider.md) + - [RadiusProviderPropertyMapping](docs/RadiusProviderPropertyMapping.md) + - [RadiusProviderPropertyMappingRequest](docs/RadiusProviderPropertyMappingRequest.md) + - [RadiusProviderRequest](docs/RadiusProviderRequest.md) + - [RedirectChallenge](docs/RedirectChallenge.md) + - [RedirectChallengeResponseRequest](docs/RedirectChallengeResponseRequest.md) + - [RedirectStage](docs/RedirectStage.md) + - [RedirectStageModeEnum](docs/RedirectStageModeEnum.md) + - [RedirectStageRequest](docs/RedirectStageRequest.md) + - [RedirectURI](docs/RedirectURI.md) + - [RedirectURIRequest](docs/RedirectURIRequest.md) + - [RedirectURITypeEnum](docs/RedirectURITypeEnum.md) + - [RelatedGroup](docs/RelatedGroup.md) + - [RelatedRule](docs/RelatedRule.md) + - [Reputation](docs/Reputation.md) + - [ReputationPolicy](docs/ReputationPolicy.md) + - [ReputationPolicyRequest](docs/ReputationPolicyRequest.md) + - [Review](docs/Review.md) + - [ReviewRequest](docs/ReviewRequest.md) + - [ReviewerGroup](docs/ReviewerGroup.md) + - [ReviewerUser](docs/ReviewerUser.md) + - [Role](docs/Role.md) + - [RoleAssignedObjectPermission](docs/RoleAssignedObjectPermission.md) + - [RoleModelPermission](docs/RoleModelPermission.md) + - [RoleObjectPermission](docs/RoleObjectPermission.md) + - [RoleRequest](docs/RoleRequest.md) + - [SAMLBindingsEnum](docs/SAMLBindingsEnum.md) + - [SAMLLogoutMethods](docs/SAMLLogoutMethods.md) + - [SAMLMetadata](docs/SAMLMetadata.md) + - [SAMLNameIDPolicyEnum](docs/SAMLNameIDPolicyEnum.md) + - [SAMLPropertyMapping](docs/SAMLPropertyMapping.md) + - [SAMLPropertyMappingRequest](docs/SAMLPropertyMappingRequest.md) + - [SAMLProvider](docs/SAMLProvider.md) + - [SAMLProviderRequest](docs/SAMLProviderRequest.md) + - [SAMLSource](docs/SAMLSource.md) + - [SAMLSourcePropertyMapping](docs/SAMLSourcePropertyMapping.md) + - [SAMLSourcePropertyMappingRequest](docs/SAMLSourcePropertyMappingRequest.md) + - [SAMLSourceRequest](docs/SAMLSourceRequest.md) + - [SCIMAuthenticationModeEnum](docs/SCIMAuthenticationModeEnum.md) + - [SCIMMapping](docs/SCIMMapping.md) + - [SCIMMappingRequest](docs/SCIMMappingRequest.md) + - [SCIMProvider](docs/SCIMProvider.md) + - [SCIMProviderGroup](docs/SCIMProviderGroup.md) + - [SCIMProviderGroupRequest](docs/SCIMProviderGroupRequest.md) + - [SCIMProviderRequest](docs/SCIMProviderRequest.md) + - [SCIMProviderUser](docs/SCIMProviderUser.md) + - [SCIMProviderUserRequest](docs/SCIMProviderUserRequest.md) + - [SCIMSource](docs/SCIMSource.md) + - [SCIMSourceGroup](docs/SCIMSourceGroup.md) + - [SCIMSourceGroupRequest](docs/SCIMSourceGroupRequest.md) + - [SCIMSourcePropertyMapping](docs/SCIMSourcePropertyMapping.md) + - [SCIMSourcePropertyMappingRequest](docs/SCIMSourcePropertyMappingRequest.md) + - [SCIMSourceRequest](docs/SCIMSourceRequest.md) + - [SCIMSourceUser](docs/SCIMSourceUser.md) + - [SCIMSourceUserRequest](docs/SCIMSourceUserRequest.md) + - [SMSDevice](docs/SMSDevice.md) + - [SMSDeviceRequest](docs/SMSDeviceRequest.md) + - [SSFProvider](docs/SSFProvider.md) + - [SSFProviderRequest](docs/SSFProviderRequest.md) + - [SSFStream](docs/SSFStream.md) + - [SSFStreamStatusEnum](docs/SSFStreamStatusEnum.md) + - [Schedule](docs/Schedule.md) + - [ScheduleRequest](docs/ScheduleRequest.md) + - [ScopeMapping](docs/ScopeMapping.md) + - [ScopeMappingRequest](docs/ScopeMappingRequest.md) + - [SelectableStage](docs/SelectableStage.md) + - [ServiceConnection](docs/ServiceConnection.md) + - [ServiceConnectionState](docs/ServiceConnectionState.md) + - [SessionEndChallenge](docs/SessionEndChallenge.md) + - [SessionUser](docs/SessionUser.md) + - [Settings](docs/Settings.md) + - [SettingsRequest](docs/SettingsRequest.md) + - [SeverityEnum](docs/SeverityEnum.md) + - [ShellChallenge](docs/ShellChallenge.md) + - [SignatureAlgorithmEnum](docs/SignatureAlgorithmEnum.md) + - [Software](docs/Software.md) + - [SoftwareRequest](docs/SoftwareRequest.md) + - [Source](docs/Source.md) + - [SourceStage](docs/SourceStage.md) + - [SourceStageRequest](docs/SourceStageRequest.md) + - [SourceType](docs/SourceType.md) + - [Stage](docs/Stage.md) + - [StageModeEnum](docs/StageModeEnum.md) + - [StagePrompt](docs/StagePrompt.md) + - [StaticDevice](docs/StaticDevice.md) + - [StaticDeviceRequest](docs/StaticDeviceRequest.md) + - [StaticDeviceToken](docs/StaticDeviceToken.md) + - [SubModeEnum](docs/SubModeEnum.md) + - [SyncObjectModelEnum](docs/SyncObjectModelEnum.md) + - [SyncObjectRequest](docs/SyncObjectRequest.md) + - [SyncObjectResult](docs/SyncObjectResult.md) + - [SyncOutgoingTriggerModeEnum](docs/SyncOutgoingTriggerModeEnum.md) + - [SyncStatus](docs/SyncStatus.md) + - [SystemInfo](docs/SystemInfo.md) + - [SystemInfoRuntime](docs/SystemInfoRuntime.md) + - [TOTPDevice](docs/TOTPDevice.md) + - [TOTPDeviceRequest](docs/TOTPDeviceRequest.md) + - [Task](docs/Task.md) + - [TaskAggregatedStatusEnum](docs/TaskAggregatedStatusEnum.md) + - [TaskStatusEnum](docs/TaskStatusEnum.md) + - [TelegramAuthRequest](docs/TelegramAuthRequest.md) + - [TelegramChallengeResponseRequest](docs/TelegramChallengeResponseRequest.md) + - [TelegramLoginChallenge](docs/TelegramLoginChallenge.md) + - [TelegramSource](docs/TelegramSource.md) + - [TelegramSourcePropertyMapping](docs/TelegramSourcePropertyMapping.md) + - [TelegramSourcePropertyMappingRequest](docs/TelegramSourcePropertyMappingRequest.md) + - [TelegramSourceRequest](docs/TelegramSourceRequest.md) + - [Tenant](docs/Tenant.md) + - [TenantAdminGroupRequestRequest](docs/TenantAdminGroupRequestRequest.md) + - [TenantRecoveryKeyRequestRequest](docs/TenantRecoveryKeyRequestRequest.md) + - [TenantRecoveryKeyResponse](docs/TenantRecoveryKeyResponse.md) + - [TenantRequest](docs/TenantRequest.md) + - [ThemedUrls](docs/ThemedUrls.md) + - [Token](docs/Token.md) + - [TokenModel](docs/TokenModel.md) + - [TokenRequest](docs/TokenRequest.md) + - [TokenSetKeyRequest](docs/TokenSetKeyRequest.md) + - [TokenView](docs/TokenView.md) + - [TransactionApplicationRequest](docs/TransactionApplicationRequest.md) + - [TransactionApplicationResponse](docs/TransactionApplicationResponse.md) + - [TransactionPolicyBindingRequest](docs/TransactionPolicyBindingRequest.md) + - [TransportModeEnum](docs/TransportModeEnum.md) + - [TypeCreate](docs/TypeCreate.md) + - [UiThemeEnum](docs/UiThemeEnum.md) + - [UniquePasswordPolicy](docs/UniquePasswordPolicy.md) + - [UniquePasswordPolicyRequest](docs/UniquePasswordPolicyRequest.md) + - [UsageEnum](docs/UsageEnum.md) + - [UsedBy](docs/UsedBy.md) + - [UsedByActionEnum](docs/UsedByActionEnum.md) + - [User](docs/User.md) + - [UserAccountLockdownRequest](docs/UserAccountLockdownRequest.md) + - [UserAccountRequest](docs/UserAccountRequest.md) + - [UserAccountSerializerForRoleRequest](docs/UserAccountSerializerForRoleRequest.md) + - [UserAttributeEnum](docs/UserAttributeEnum.md) + - [UserConsent](docs/UserConsent.md) + - [UserCreationModeEnum](docs/UserCreationModeEnum.md) + - [UserDeleteStage](docs/UserDeleteStage.md) + - [UserDeleteStageRequest](docs/UserDeleteStageRequest.md) + - [UserFieldsEnum](docs/UserFieldsEnum.md) + - [UserKerberosSourceConnection](docs/UserKerberosSourceConnection.md) + - [UserKerberosSourceConnectionRequest](docs/UserKerberosSourceConnectionRequest.md) + - [UserLDAPSourceConnection](docs/UserLDAPSourceConnection.md) + - [UserLDAPSourceConnectionRequest](docs/UserLDAPSourceConnectionRequest.md) + - [UserLoginChallenge](docs/UserLoginChallenge.md) + - [UserLoginChallengeResponseRequest](docs/UserLoginChallengeResponseRequest.md) + - [UserLoginStage](docs/UserLoginStage.md) + - [UserLoginStageRequest](docs/UserLoginStageRequest.md) + - [UserLogoutStage](docs/UserLogoutStage.md) + - [UserLogoutStageRequest](docs/UserLogoutStageRequest.md) + - [UserMatchingModeEnum](docs/UserMatchingModeEnum.md) + - [UserOAuthSourceConnection](docs/UserOAuthSourceConnection.md) + - [UserOAuthSourceConnectionRequest](docs/UserOAuthSourceConnectionRequest.md) + - [UserPasswordHashSetRequest](docs/UserPasswordHashSetRequest.md) + - [UserPasswordSetRequest](docs/UserPasswordSetRequest.md) + - [UserPath](docs/UserPath.md) + - [UserPlexSourceConnection](docs/UserPlexSourceConnection.md) + - [UserPlexSourceConnectionRequest](docs/UserPlexSourceConnectionRequest.md) + - [UserRecoveryEmailRequest](docs/UserRecoveryEmailRequest.md) + - [UserRecoveryLinkRequest](docs/UserRecoveryLinkRequest.md) + - [UserRequest](docs/UserRequest.md) + - [UserSAMLSourceConnection](docs/UserSAMLSourceConnection.md) + - [UserSAMLSourceConnectionRequest](docs/UserSAMLSourceConnectionRequest.md) + - [UserSelf](docs/UserSelf.md) + - [UserSelfGroups](docs/UserSelfGroups.md) + - [UserSelfRoles](docs/UserSelfRoles.md) + - [UserServiceAccountRequest](docs/UserServiceAccountRequest.md) + - [UserServiceAccountResponse](docs/UserServiceAccountResponse.md) + - [UserSetting](docs/UserSetting.md) + - [UserSourceConnection](docs/UserSourceConnection.md) + - [UserSourceConnectionRequest](docs/UserSourceConnectionRequest.md) + - [UserTelegramSourceConnection](docs/UserTelegramSourceConnection.md) + - [UserTelegramSourceConnectionRequest](docs/UserTelegramSourceConnectionRequest.md) + - [UserTypeEnum](docs/UserTypeEnum.md) + - [UserVerificationEnum](docs/UserVerificationEnum.md) + - [UserWriteStage](docs/UserWriteStage.md) + - [UserWriteStageRequest](docs/UserWriteStageRequest.md) + - [ValidationError](docs/ValidationError.md) + - [VendorEnum](docs/VendorEnum.md) + - [Version](docs/Version.md) + - [VersionHistory](docs/VersionHistory.md) + - [WSFederationProvider](docs/WSFederationProvider.md) + - [WSFederationProviderRequest](docs/WSFederationProviderRequest.md) + - [WebAuthnDevice](docs/WebAuthnDevice.md) + - [WebAuthnDeviceRequest](docs/WebAuthnDeviceRequest.md) + - [WebAuthnDeviceType](docs/WebAuthnDeviceType.md) + - [WebAuthnHintEnum](docs/WebAuthnHintEnum.md) + - [Worker](docs/Worker.md) + + + +## Documentation For Authorization + + +Authentication schemes defined for the API: + +### authentik + +- **Type**: Bearer authentication + + +### authentik_device_auth + + + +### authentik_device_enroll + +- **Type**: Bearer authentication + + +### authentik_device_federation + +- **Type**: Bearer authentication + + +## Author + +hello@goauthentik.io + diff --git a/authentik_client/__init__.py b/authentik_client/__init__.py new file mode 100644 index 000000000..619815d31 --- /dev/null +++ b/authentik_client/__init__.py @@ -0,0 +1,1863 @@ +# coding: utf-8 + +# flake8: noqa + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +__version__ = "2026.5.7" + +# Define package exports +__all__ = [ + "AdminApi", + "AuthenticatorsApi", + "CoreApi", + "CryptoApi", + "EndpointsApi", + "EnterpriseApi", + "EventsApi", + "FlowsApi", + "LifecycleApi", + "ManagedApi", + "Oauth2Api", + "OutpostsApi", + "PoliciesApi", + "PropertymappingsApi", + "ProvidersApi", + "RacApi", + "RbacApi", + "ReportsApi", + "RootApi", + "SchemaApi", + "SourcesApi", + "SsfApi", + "StagesApi", + "TasksApi", + "TenantsApi", + "ApiResponse", + "ApiClient", + "Configuration", + "OpenApiException", + "ApiTypeError", + "ApiValueError", + "ApiKeyError", + "ApiAttributeError", + "ApiException", + "AccessDeniedChallenge", + "AccountLockdownStage", + "AccountLockdownStageRequest", + "AgentAuthenticationResponse", + "AgentConfig", + "AgentConnector", + "AgentConnectorRequest", + "AgentPSSODeviceRegistrationRequest", + "AgentPSSODeviceRegistrationResponse", + "AgentPSSOUserRegistrationRequest", + "AgentTokenResponse", + "AlgEnum", + "App", + "AppEnum", + "AppleChallengeResponseRequest", + "AppleIndependentSecureEnclave", + "AppleIndependentSecureEnclaveRequest", + "AppleLoginChallenge", + "Application", + "ApplicationEntitlement", + "ApplicationEntitlementRequest", + "ApplicationRequest", + "AuthTypeEnum", + "AuthenticatedSession", + "AuthenticatedSessionAsn", + "AuthenticatedSessionGeoIp", + "AuthenticatedSessionUserAgent", + "AuthenticatedSessionUserAgentDevice", + "AuthenticatedSessionUserAgentOs", + "AuthenticatedSessionUserAgentUserAgent", + "AuthenticationEnum", + "AuthenticatorAttachmentEnum", + "AuthenticatorDuoChallenge", + "AuthenticatorDuoChallengeResponseRequest", + "AuthenticatorDuoStage", + "AuthenticatorDuoStageDeviceImportResponse", + "AuthenticatorDuoStageManualDeviceImportRequest", + "AuthenticatorDuoStageRequest", + "AuthenticatorEmailChallenge", + "AuthenticatorEmailChallengeResponseRequest", + "AuthenticatorEmailStage", + "AuthenticatorEmailStageRequest", + "AuthenticatorEndpointGDTCStage", + "AuthenticatorEndpointGDTCStageRequest", + "AuthenticatorSMSChallenge", + "AuthenticatorSMSChallengeResponseRequest", + "AuthenticatorSMSStage", + "AuthenticatorSMSStageRequest", + "AuthenticatorStaticChallenge", + "AuthenticatorStaticChallengeResponseRequest", + "AuthenticatorStaticStage", + "AuthenticatorStaticStageRequest", + "AuthenticatorTOTPChallenge", + "AuthenticatorTOTPChallengeResponseRequest", + "AuthenticatorTOTPStage", + "AuthenticatorTOTPStageRequest", + "AuthenticatorValidateStage", + "AuthenticatorValidateStageRequest", + "AuthenticatorValidationChallenge", + "AuthenticatorValidationChallengeResponseRequest", + "AuthenticatorWebAuthnChallenge", + "AuthenticatorWebAuthnChallengeResponseRequest", + "AuthenticatorWebAuthnStage", + "AuthenticatorWebAuthnStageRequest", + "AuthorizationCodeAuthMethodEnum", + "AutoSubmitChallengeResponseRequest", + "AutosubmitChallenge", + "BackendsEnum", + "BindingTypeEnum", + "BlueprintFile", + "BlueprintImportResult", + "BlueprintInstance", + "BlueprintInstanceRequest", + "BlueprintInstanceStatusEnum", + "Brand", + "BrandRequest", + "BulkDeleteSessionResponse", + "Cache", + "CapabilitiesEnum", + "CaptchaChallenge", + "CaptchaChallengeResponseRequest", + "CaptchaStage", + "CaptchaStageRequest", + "CertAttributeEnum", + "CertificateData", + "CertificateGenerationRequest", + "CertificateKeyPair", + "CertificateKeyPairKeyTypeEnum", + "CertificateKeyPairRequest", + "ChallengeTypes", + "ClientTypeEnum", + "CompatibilityModeEnum", + "Config", + "ConnectionToken", + "ConnectionTokenRequest", + "Connector", + "ConsentChallenge", + "ConsentChallengeResponseRequest", + "ConsentModeEnum", + "ConsentPermission", + "ConsentStage", + "ConsentStageRequest", + "ContentType", + "ContentTypeEnum", + "ContextualFlowInfo", + "ContextualFlowInfoLayoutEnum", + "CountryCodeEnum", + "CurrentBrand", + "CurrentBrandFlags", + "DataExport", + "DeliveryMethodEnum", + "DeniedActionEnum", + "DenyStage", + "DenyStageRequest", + "DetailedCountry", + "Device", + "DeviceAccessGroup", + "DeviceAccessGroupRequest", + "DeviceChallenge", + "DeviceChallengeRequest", + "DeviceClassesEnum", + "DeviceConnection", + "DeviceFactSnapshot", + "DeviceFacts", + "DeviceFactsOSFamily", + "DeviceFactsRequest", + "DeviceGroup", + "DeviceGroupRequest", + "DeviceSummary", + "DeviceUser", + "DeviceUserBinding", + "DeviceUserBindingRequest", + "DeviceUserRequest", + "DigestAlgorithmEnum", + "DigitsEnum", + "Disk", + "DiskRequest", + "DockerServiceConnection", + "DockerServiceConnectionRequest", + "Domain", + "DomainRequest", + "DummyChallenge", + "DummyChallengeResponseRequest", + "DummyPolicy", + "DummyPolicyRequest", + "DummyStage", + "DummyStageRequest", + "DuoDevice", + "DuoDeviceEnrollmentStatus", + "DuoDeviceRequest", + "DuoResponseEnum", + "EmailChallenge", + "EmailChallengeResponseRequest", + "EmailDevice", + "EmailDeviceRequest", + "EmailStage", + "EmailStageRequest", + "Endpoint", + "EndpointAgentChallenge", + "EndpointAgentChallengeResponseRequest", + "EndpointAuthModeEnum", + "EndpointDevice", + "EndpointDeviceDetails", + "EndpointDeviceRequest", + "EndpointRequest", + "EndpointStage", + "EndpointStageRequest", + "EnrollRequest", + "EnrollmentToken", + "EnrollmentTokenRequest", + "ErrorDetail", + "ErrorReportingConfig", + "Event", + "EventActions", + "EventMatcherPolicy", + "EventMatcherPolicyRequest", + "EventRequest", + "EventStats", + "EventTopPerUser", + "EventVolume", + "EventsRequestedEnum", + "ExpiringBaseGrantModel", + "ExpressionPolicy", + "ExpressionPolicyRequest", + "ExtraRoleObjectPermission", + "FileList", + "FleetConnector", + "FleetConnectorRequest", + "Flow", + "FlowChallengeResponseRequest", + "FlowDesignationEnum", + "FlowDiagram", + "FlowErrorChallenge", + "FlowInspection", + "FlowInspectorPlan", + "FlowLayoutEnum", + "FlowRequest", + "FlowSet", + "FlowStageBinding", + "FlowStageBindingRequest", + "FooterLink", + "ForceBindingEnum", + "FormatEnum", + "FrameChallenge", + "FrameChallengeResponseRequest", + "GenericError", + "GeoIPPolicy", + "GeoIPPolicyCountriesObjInner", + "GeoIPPolicyRequest", + "GeoipBindingEnum", + "GlobalTaskStatus", + "GoogleChromeConnector", + "GoogleChromeConnectorRequest", + "GoogleEndpointDevice", + "GoogleEndpointDeviceRequest", + "GoogleWorkspaceProvider", + "GoogleWorkspaceProviderGroup", + "GoogleWorkspaceProviderGroupRequest", + "GoogleWorkspaceProviderMapping", + "GoogleWorkspaceProviderMappingRequest", + "GoogleWorkspaceProviderRequest", + "GoogleWorkspaceProviderUser", + "GoogleWorkspaceProviderUserRequest", + "GrantTypesEnum", + "Group", + "GroupKerberosSourceConnection", + "GroupKerberosSourceConnectionRequest", + "GroupLDAPSourceConnection", + "GroupLDAPSourceConnectionRequest", + "GroupMatchingModeEnum", + "GroupOAuthSourceConnection", + "GroupOAuthSourceConnectionRequest", + "GroupPlexSourceConnection", + "GroupPlexSourceConnectionRequest", + "GroupRequest", + "GroupSAMLSourceConnection", + "GroupSAMLSourceConnectionRequest", + "GroupSourceConnection", + "GroupSourceConnectionRequest", + "GroupTelegramSourceConnection", + "GroupTelegramSourceConnectionRequest", + "Hardware", + "HardwareRequest", + "IdentificationChallenge", + "IdentificationChallengeResponseRequest", + "IdentificationStage", + "IdentificationStageRequest", + "IframeLogoutChallenge", + "IframeLogoutChallengeResponseRequest", + "ImpersonationRequest", + "InitialPermissions", + "InitialPermissionsRequest", + "InstallID", + "IntentEnum", + "InvalidResponseActionEnum", + "Invitation", + "InvitationRequest", + "InvitationSendEmailRequest", + "InvitationStage", + "InvitationStageRequest", + "IssuerModeEnum", + "KadminTypeEnum", + "KerberosSource", + "KerberosSourcePropertyMapping", + "KerberosSourcePropertyMappingRequest", + "KerberosSourceRequest", + "KeyTypeEnum", + "KubernetesServiceConnection", + "KubernetesServiceConnectionRequest", + "LDAPAPIAccessMode", + "LDAPCheckAccess", + "LDAPDebug", + "LDAPOutpostConfig", + "LDAPProvider", + "LDAPProviderRequest", + "LDAPSource", + "LDAPSourcePropertyMapping", + "LDAPSourcePropertyMappingRequest", + "LDAPSourceRequest", + "LangEnum", + "LastTaskStatusEnum", + "License", + "LicenseFlagsEnum", + "LicenseForecast", + "LicenseRequest", + "LicenseStatusEnum", + "LicenseSummary", + "LicenseSummaryStatusEnum", + "LifecycleIteration", + "LifecycleIterationRequest", + "LifecycleIterationStateEnum", + "LifecycleRule", + "LifecycleRuleRequest", + "Link", + "LogEvent", + "LogLevelEnum", + "LoginChallengeTypes", + "LoginSource", + "LogoutURL", + "MDMConfigRequest", + "MDMConfigResponse", + "MatchingModeEnum", + "Metadata", + "MicrosoftEntraProvider", + "MicrosoftEntraProviderGroup", + "MicrosoftEntraProviderGroupRequest", + "MicrosoftEntraProviderMapping", + "MicrosoftEntraProviderMappingRequest", + "MicrosoftEntraProviderRequest", + "MicrosoftEntraProviderUser", + "MicrosoftEntraProviderUserRequest", + "ModelEnum", + "ModelRequest", + "MutualTLSStage", + "MutualTLSStageRequest", + "NativeLogoutChallenge", + "NativeLogoutChallengeResponseRequest", + "Network", + "NetworkBindingEnum", + "NetworkInterface", + "NetworkInterfaceRequest", + "NetworkRequest", + "NotConfiguredActionEnum", + "Notification", + "NotificationRequest", + "NotificationRule", + "NotificationRuleRequest", + "NotificationTransport", + "NotificationTransportRequest", + "NotificationTransportTest", + "NotificationWebhookMapping", + "NotificationWebhookMappingRequest", + "OAuth2Provider", + "OAuth2ProviderLogoutMethodEnum", + "OAuth2ProviderRequest", + "OAuth2ProviderSetupURLs", + "OAuthDeviceCodeChallenge", + "OAuthDeviceCodeChallengeResponseRequest", + "OAuthDeviceCodeFinishChallenge", + "OAuthDeviceCodeFinishChallengeResponseRequest", + "OAuthSource", + "OAuthSourcePropertyMapping", + "OAuthSourcePropertyMappingRequest", + "OAuthSourceRequest", + "OpenIDConnectConfiguration", + "OperatingSystem", + "OperatingSystemRequest", + "OutgoingSyncDeleteAction", + "Outpost", + "OutpostDefaultConfig", + "OutpostHealth", + "OutpostRequest", + "OutpostTypeEnum", + "PKCEMethodEnum", + "PaginatedAccountLockdownStageList", + "PaginatedAgentConnectorList", + "PaginatedAppleIndependentSecureEnclaveList", + "PaginatedApplicationEntitlementList", + "PaginatedApplicationList", + "PaginatedAuthenticatedSessionList", + "PaginatedAuthenticatorDuoStageList", + "PaginatedAuthenticatorEmailStageList", + "PaginatedAuthenticatorEndpointGDTCStageList", + "PaginatedAuthenticatorSMSStageList", + "PaginatedAuthenticatorStaticStageList", + "PaginatedAuthenticatorTOTPStageList", + "PaginatedAuthenticatorValidateStageList", + "PaginatedAuthenticatorWebAuthnStageList", + "PaginatedBlueprintInstanceList", + "PaginatedBrandList", + "PaginatedCaptchaStageList", + "PaginatedCertificateKeyPairList", + "PaginatedConnectionTokenList", + "PaginatedConnectorList", + "PaginatedConsentStageList", + "PaginatedDataExportList", + "PaginatedDenyStageList", + "PaginatedDeviceAccessGroupList", + "PaginatedDeviceUserBindingList", + "PaginatedDockerServiceConnectionList", + "PaginatedDomainList", + "PaginatedDummyPolicyList", + "PaginatedDummyStageList", + "PaginatedDuoDeviceList", + "PaginatedEmailDeviceList", + "PaginatedEmailStageList", + "PaginatedEndpointDeviceList", + "PaginatedEndpointList", + "PaginatedEndpointStageList", + "PaginatedEnrollmentTokenList", + "PaginatedEventList", + "PaginatedEventMatcherPolicyList", + "PaginatedExpiringBaseGrantModelList", + "PaginatedExpressionPolicyList", + "PaginatedExtraRoleObjectPermissionList", + "PaginatedFleetConnectorList", + "PaginatedFlowList", + "PaginatedFlowStageBindingList", + "PaginatedGeoIPPolicyList", + "PaginatedGoogleChromeConnectorList", + "PaginatedGoogleEndpointDeviceList", + "PaginatedGoogleWorkspaceProviderGroupList", + "PaginatedGoogleWorkspaceProviderList", + "PaginatedGoogleWorkspaceProviderMappingList", + "PaginatedGoogleWorkspaceProviderUserList", + "PaginatedGroupKerberosSourceConnectionList", + "PaginatedGroupLDAPSourceConnectionList", + "PaginatedGroupList", + "PaginatedGroupOAuthSourceConnectionList", + "PaginatedGroupPlexSourceConnectionList", + "PaginatedGroupSAMLSourceConnectionList", + "PaginatedGroupSourceConnectionList", + "PaginatedGroupTelegramSourceConnectionList", + "PaginatedIdentificationStageList", + "PaginatedInitialPermissionsList", + "PaginatedInvitationList", + "PaginatedInvitationStageList", + "PaginatedKerberosSourceList", + "PaginatedKerberosSourcePropertyMappingList", + "PaginatedKubernetesServiceConnectionList", + "PaginatedLDAPOutpostConfigList", + "PaginatedLDAPProviderList", + "PaginatedLDAPSourceList", + "PaginatedLDAPSourcePropertyMappingList", + "PaginatedLicenseList", + "PaginatedLifecycleIterationList", + "PaginatedLifecycleRuleList", + "PaginatedMicrosoftEntraProviderGroupList", + "PaginatedMicrosoftEntraProviderList", + "PaginatedMicrosoftEntraProviderMappingList", + "PaginatedMicrosoftEntraProviderUserList", + "PaginatedMutualTLSStageList", + "PaginatedNotificationList", + "PaginatedNotificationRuleList", + "PaginatedNotificationTransportList", + "PaginatedNotificationWebhookMappingList", + "PaginatedOAuth2ProviderList", + "PaginatedOAuthSourceList", + "PaginatedOAuthSourcePropertyMappingList", + "PaginatedOutpostList", + "PaginatedPasswordExpiryPolicyList", + "PaginatedPasswordPolicyList", + "PaginatedPasswordStageList", + "PaginatedPermissionList", + "PaginatedPlexSourceList", + "PaginatedPlexSourcePropertyMappingList", + "PaginatedPolicyBindingList", + "PaginatedPolicyList", + "PaginatedPromptList", + "PaginatedPromptStageList", + "PaginatedPropertyMappingList", + "PaginatedProviderList", + "PaginatedProxyOutpostConfigList", + "PaginatedProxyProviderList", + "PaginatedRACPropertyMappingList", + "PaginatedRACProviderList", + "PaginatedRadiusOutpostConfigList", + "PaginatedRadiusProviderList", + "PaginatedRadiusProviderPropertyMappingList", + "PaginatedRedirectStageList", + "PaginatedReputationList", + "PaginatedReputationPolicyList", + "PaginatedRoleAssignedObjectPermissionList", + "PaginatedRoleList", + "PaginatedSAMLPropertyMappingList", + "PaginatedSAMLProviderList", + "PaginatedSAMLSourceList", + "PaginatedSAMLSourcePropertyMappingList", + "PaginatedSCIMMappingList", + "PaginatedSCIMProviderGroupList", + "PaginatedSCIMProviderList", + "PaginatedSCIMProviderUserList", + "PaginatedSCIMSourceGroupList", + "PaginatedSCIMSourceList", + "PaginatedSCIMSourcePropertyMappingList", + "PaginatedSCIMSourceUserList", + "PaginatedSMSDeviceList", + "PaginatedSSFProviderList", + "PaginatedSSFStreamList", + "PaginatedScheduleList", + "PaginatedScopeMappingList", + "PaginatedServiceConnectionList", + "PaginatedSourceList", + "PaginatedSourceStageList", + "PaginatedStageList", + "PaginatedStaticDeviceList", + "PaginatedTOTPDeviceList", + "PaginatedTaskList", + "PaginatedTelegramSourceList", + "PaginatedTelegramSourcePropertyMappingList", + "PaginatedTenantList", + "PaginatedTokenList", + "PaginatedTokenModelList", + "PaginatedUniquePasswordPolicyList", + "PaginatedUserConsentList", + "PaginatedUserDeleteStageList", + "PaginatedUserKerberosSourceConnectionList", + "PaginatedUserLDAPSourceConnectionList", + "PaginatedUserList", + "PaginatedUserLoginStageList", + "PaginatedUserLogoutStageList", + "PaginatedUserOAuthSourceConnectionList", + "PaginatedUserPlexSourceConnectionList", + "PaginatedUserSAMLSourceConnectionList", + "PaginatedUserSourceConnectionList", + "PaginatedUserTelegramSourceConnectionList", + "PaginatedUserWriteStageList", + "PaginatedWSFederationProviderList", + "PaginatedWebAuthnDeviceList", + "PaginatedWebAuthnDeviceTypeList", + "Pagination", + "PartialGroup", + "PartialUser", + "PasswordChallenge", + "PasswordChallengeResponseRequest", + "PasswordExpiryPolicy", + "PasswordExpiryPolicyRequest", + "PasswordPolicy", + "PasswordPolicyRequest", + "PasswordStage", + "PasswordStageRequest", + "PatchedAccountLockdownStageRequest", + "PatchedAgentConnectorRequest", + "PatchedAppleIndependentSecureEnclaveRequest", + "PatchedApplicationEntitlementRequest", + "PatchedApplicationRequest", + "PatchedAuthenticatorDuoStageRequest", + "PatchedAuthenticatorEmailStageRequest", + "PatchedAuthenticatorEndpointGDTCStageRequest", + "PatchedAuthenticatorSMSStageRequest", + "PatchedAuthenticatorStaticStageRequest", + "PatchedAuthenticatorTOTPStageRequest", + "PatchedAuthenticatorValidateStageRequest", + "PatchedAuthenticatorWebAuthnStageRequest", + "PatchedBlueprintInstanceRequest", + "PatchedBrandRequest", + "PatchedCaptchaStageRequest", + "PatchedCertificateKeyPairRequest", + "PatchedConnectionTokenRequest", + "PatchedConsentStageRequest", + "PatchedDenyStageRequest", + "PatchedDeviceAccessGroupRequest", + "PatchedDeviceUserBindingRequest", + "PatchedDockerServiceConnectionRequest", + "PatchedDomainRequest", + "PatchedDummyPolicyRequest", + "PatchedDummyStageRequest", + "PatchedDuoDeviceRequest", + "PatchedEmailDeviceRequest", + "PatchedEmailStageRequest", + "PatchedEndpointDeviceRequest", + "PatchedEndpointRequest", + "PatchedEndpointStageRequest", + "PatchedEnrollmentTokenRequest", + "PatchedEventMatcherPolicyRequest", + "PatchedEventRequest", + "PatchedExpressionPolicyRequest", + "PatchedFleetConnectorRequest", + "PatchedFlowRequest", + "PatchedFlowStageBindingRequest", + "PatchedGeoIPPolicyRequest", + "PatchedGoogleChromeConnectorRequest", + "PatchedGoogleEndpointDeviceRequest", + "PatchedGoogleWorkspaceProviderMappingRequest", + "PatchedGoogleWorkspaceProviderRequest", + "PatchedGroupKerberosSourceConnectionRequest", + "PatchedGroupLDAPSourceConnectionRequest", + "PatchedGroupOAuthSourceConnectionRequest", + "PatchedGroupPlexSourceConnectionRequest", + "PatchedGroupRequest", + "PatchedGroupSAMLSourceConnectionRequest", + "PatchedGroupSourceConnectionRequest", + "PatchedGroupTelegramSourceConnectionRequest", + "PatchedIdentificationStageRequest", + "PatchedInitialPermissionsRequest", + "PatchedInvitationRequest", + "PatchedInvitationStageRequest", + "PatchedKerberosSourcePropertyMappingRequest", + "PatchedKerberosSourceRequest", + "PatchedKubernetesServiceConnectionRequest", + "PatchedLDAPProviderRequest", + "PatchedLDAPSourcePropertyMappingRequest", + "PatchedLDAPSourceRequest", + "PatchedLicenseRequest", + "PatchedLifecycleRuleRequest", + "PatchedMicrosoftEntraProviderMappingRequest", + "PatchedMicrosoftEntraProviderRequest", + "PatchedMutualTLSStageRequest", + "PatchedNotificationRequest", + "PatchedNotificationRuleRequest", + "PatchedNotificationTransportRequest", + "PatchedNotificationWebhookMappingRequest", + "PatchedOAuth2ProviderRequest", + "PatchedOAuthSourcePropertyMappingRequest", + "PatchedOAuthSourceRequest", + "PatchedOutpostRequest", + "PatchedPasswordExpiryPolicyRequest", + "PatchedPasswordPolicyRequest", + "PatchedPasswordStageRequest", + "PatchedPermissionAssignRequest", + "PatchedPlexSourcePropertyMappingRequest", + "PatchedPlexSourceRequest", + "PatchedPolicyBindingRequest", + "PatchedPromptRequest", + "PatchedPromptStageRequest", + "PatchedProxyProviderRequest", + "PatchedRACPropertyMappingRequest", + "PatchedRACProviderRequest", + "PatchedRadiusProviderPropertyMappingRequest", + "PatchedRadiusProviderRequest", + "PatchedRedirectStageRequest", + "PatchedReputationPolicyRequest", + "PatchedRoleRequest", + "PatchedSAMLPropertyMappingRequest", + "PatchedSAMLProviderRequest", + "PatchedSAMLSourcePropertyMappingRequest", + "PatchedSAMLSourceRequest", + "PatchedSCIMMappingRequest", + "PatchedSCIMProviderRequest", + "PatchedSCIMSourceGroupRequest", + "PatchedSCIMSourcePropertyMappingRequest", + "PatchedSCIMSourceRequest", + "PatchedSCIMSourceUserRequest", + "PatchedSMSDeviceRequest", + "PatchedSSFProviderRequest", + "PatchedScheduleRequest", + "PatchedScopeMappingRequest", + "PatchedSettingsRequest", + "PatchedSettingsRequestFlags", + "PatchedSourceStageRequest", + "PatchedStaticDeviceRequest", + "PatchedTOTPDeviceRequest", + "PatchedTelegramSourcePropertyMappingRequest", + "PatchedTelegramSourceRequest", + "PatchedTenantRequest", + "PatchedTokenRequest", + "PatchedUniquePasswordPolicyRequest", + "PatchedUserDeleteStageRequest", + "PatchedUserKerberosSourceConnectionRequest", + "PatchedUserLDAPSourceConnectionRequest", + "PatchedUserLoginStageRequest", + "PatchedUserLogoutStageRequest", + "PatchedUserOAuthSourceConnectionRequest", + "PatchedUserPlexSourceConnectionRequest", + "PatchedUserRequest", + "PatchedUserSAMLSourceConnectionRequest", + "PatchedUserSourceConnectionRequest", + "PatchedUserTelegramSourceConnectionRequest", + "PatchedUserWriteStageRequest", + "PatchedWSFederationProviderRequest", + "PatchedWebAuthnDeviceRequest", + "Permission", + "PermissionAssignRequest", + "PermissionAssignResult", + "PlexAuthenticationChallenge", + "PlexAuthenticationChallengeResponseRequest", + "PlexSource", + "PlexSourcePropertyMapping", + "PlexSourcePropertyMappingRequest", + "PlexSourceRequest", + "PlexTokenRedeemRequest", + "Policy", + "PolicyBinding", + "PolicyBindingRequest", + "PolicyEngineMode", + "PolicyTestRequest", + "PolicyTestResult", + "Process", + "ProcessRequest", + "Prompt", + "PromptChallenge", + "PromptChallengeResponseRequest", + "PromptChoice", + "PromptRequest", + "PromptStage", + "PromptStageRequest", + "PromptTypeEnum", + "PropertyMapping", + "PropertyMappingPreview", + "PropertyMappingTestRequest", + "PropertyMappingTestResult", + "ProtocolEnum", + "Provider", + "ProviderEnum", + "ProviderModelEnum", + "ProviderTypeEnum", + "ProxyMode", + "ProxyOutpostConfig", + "ProxyProvider", + "ProxyProviderRequest", + "RACPropertyMapping", + "RACPropertyMappingRequest", + "RACProvider", + "RACProviderRequest", + "RadiusCheckAccess", + "RadiusOutpostConfig", + "RadiusProvider", + "RadiusProviderPropertyMapping", + "RadiusProviderPropertyMappingRequest", + "RadiusProviderRequest", + "RedirectChallenge", + "RedirectChallengeResponseRequest", + "RedirectStage", + "RedirectStageModeEnum", + "RedirectStageRequest", + "RedirectURI", + "RedirectURIRequest", + "RedirectURITypeEnum", + "RelatedGroup", + "RelatedRule", + "Reputation", + "ReputationPolicy", + "ReputationPolicyRequest", + "Review", + "ReviewRequest", + "ReviewerGroup", + "ReviewerUser", + "Role", + "RoleAssignedObjectPermission", + "RoleModelPermission", + "RoleObjectPermission", + "RoleRequest", + "SAMLBindingsEnum", + "SAMLLogoutMethods", + "SAMLMetadata", + "SAMLNameIDPolicyEnum", + "SAMLPropertyMapping", + "SAMLPropertyMappingRequest", + "SAMLProvider", + "SAMLProviderRequest", + "SAMLSource", + "SAMLSourcePropertyMapping", + "SAMLSourcePropertyMappingRequest", + "SAMLSourceRequest", + "SCIMAuthenticationModeEnum", + "SCIMMapping", + "SCIMMappingRequest", + "SCIMProvider", + "SCIMProviderGroup", + "SCIMProviderGroupRequest", + "SCIMProviderRequest", + "SCIMProviderUser", + "SCIMProviderUserRequest", + "SCIMSource", + "SCIMSourceGroup", + "SCIMSourceGroupRequest", + "SCIMSourcePropertyMapping", + "SCIMSourcePropertyMappingRequest", + "SCIMSourceRequest", + "SCIMSourceUser", + "SCIMSourceUserRequest", + "SMSDevice", + "SMSDeviceRequest", + "SSFProvider", + "SSFProviderRequest", + "SSFStream", + "SSFStreamStatusEnum", + "Schedule", + "ScheduleRequest", + "ScopeMapping", + "ScopeMappingRequest", + "SelectableStage", + "ServiceConnection", + "ServiceConnectionState", + "SessionEndChallenge", + "SessionUser", + "Settings", + "SettingsRequest", + "SeverityEnum", + "ShellChallenge", + "SignatureAlgorithmEnum", + "Software", + "SoftwareRequest", + "Source", + "SourceStage", + "SourceStageRequest", + "SourceType", + "Stage", + "StageModeEnum", + "StagePrompt", + "StaticDevice", + "StaticDeviceRequest", + "StaticDeviceToken", + "SubModeEnum", + "SyncObjectModelEnum", + "SyncObjectRequest", + "SyncObjectResult", + "SyncOutgoingTriggerModeEnum", + "SyncStatus", + "SystemInfo", + "SystemInfoRuntime", + "TOTPDevice", + "TOTPDeviceRequest", + "Task", + "TaskAggregatedStatusEnum", + "TaskStatusEnum", + "TelegramAuthRequest", + "TelegramChallengeResponseRequest", + "TelegramLoginChallenge", + "TelegramSource", + "TelegramSourcePropertyMapping", + "TelegramSourcePropertyMappingRequest", + "TelegramSourceRequest", + "Tenant", + "TenantAdminGroupRequestRequest", + "TenantRecoveryKeyRequestRequest", + "TenantRecoveryKeyResponse", + "TenantRequest", + "ThemedUrls", + "Token", + "TokenModel", + "TokenRequest", + "TokenSetKeyRequest", + "TokenView", + "TransactionApplicationRequest", + "TransactionApplicationResponse", + "TransactionPolicyBindingRequest", + "TransportModeEnum", + "TypeCreate", + "UiThemeEnum", + "UniquePasswordPolicy", + "UniquePasswordPolicyRequest", + "UsageEnum", + "UsedBy", + "UsedByActionEnum", + "User", + "UserAccountLockdownRequest", + "UserAccountRequest", + "UserAccountSerializerForRoleRequest", + "UserAttributeEnum", + "UserConsent", + "UserCreationModeEnum", + "UserDeleteStage", + "UserDeleteStageRequest", + "UserFieldsEnum", + "UserKerberosSourceConnection", + "UserKerberosSourceConnectionRequest", + "UserLDAPSourceConnection", + "UserLDAPSourceConnectionRequest", + "UserLoginChallenge", + "UserLoginChallengeResponseRequest", + "UserLoginStage", + "UserLoginStageRequest", + "UserLogoutStage", + "UserLogoutStageRequest", + "UserMatchingModeEnum", + "UserOAuthSourceConnection", + "UserOAuthSourceConnectionRequest", + "UserPasswordHashSetRequest", + "UserPasswordSetRequest", + "UserPath", + "UserPlexSourceConnection", + "UserPlexSourceConnectionRequest", + "UserRecoveryEmailRequest", + "UserRecoveryLinkRequest", + "UserRequest", + "UserSAMLSourceConnection", + "UserSAMLSourceConnectionRequest", + "UserSelf", + "UserSelfGroups", + "UserSelfRoles", + "UserServiceAccountRequest", + "UserServiceAccountResponse", + "UserSetting", + "UserSourceConnection", + "UserSourceConnectionRequest", + "UserTelegramSourceConnection", + "UserTelegramSourceConnectionRequest", + "UserTypeEnum", + "UserVerificationEnum", + "UserWriteStage", + "UserWriteStageRequest", + "ValidationError", + "VendorEnum", + "Version", + "VersionHistory", + "WSFederationProvider", + "WSFederationProviderRequest", + "WebAuthnDevice", + "WebAuthnDeviceRequest", + "WebAuthnDeviceType", + "WebAuthnHintEnum", + "Worker", +] + +# import apis into sdk package +from authentik_client.api.admin_api import AdminApi as AdminApi +from authentik_client.api.authenticators_api import AuthenticatorsApi as AuthenticatorsApi +from authentik_client.api.core_api import CoreApi as CoreApi +from authentik_client.api.crypto_api import CryptoApi as CryptoApi +from authentik_client.api.endpoints_api import EndpointsApi as EndpointsApi +from authentik_client.api.enterprise_api import EnterpriseApi as EnterpriseApi +from authentik_client.api.events_api import EventsApi as EventsApi +from authentik_client.api.flows_api import FlowsApi as FlowsApi +from authentik_client.api.lifecycle_api import LifecycleApi as LifecycleApi +from authentik_client.api.managed_api import ManagedApi as ManagedApi +from authentik_client.api.oauth2_api import Oauth2Api as Oauth2Api +from authentik_client.api.outposts_api import OutpostsApi as OutpostsApi +from authentik_client.api.policies_api import PoliciesApi as PoliciesApi +from authentik_client.api.propertymappings_api import PropertymappingsApi as PropertymappingsApi +from authentik_client.api.providers_api import ProvidersApi as ProvidersApi +from authentik_client.api.rac_api import RacApi as RacApi +from authentik_client.api.rbac_api import RbacApi as RbacApi +from authentik_client.api.reports_api import ReportsApi as ReportsApi +from authentik_client.api.root_api import RootApi as RootApi +from authentik_client.api.schema_api import SchemaApi as SchemaApi +from authentik_client.api.sources_api import SourcesApi as SourcesApi +from authentik_client.api.ssf_api import SsfApi as SsfApi +from authentik_client.api.stages_api import StagesApi as StagesApi +from authentik_client.api.tasks_api import TasksApi as TasksApi +from authentik_client.api.tenants_api import TenantsApi as TenantsApi + +# import ApiClient +from authentik_client.api_response import ApiResponse as ApiResponse +from authentik_client.api_client import ApiClient as ApiClient +from authentik_client.configuration import Configuration as Configuration +from authentik_client.exceptions import OpenApiException as OpenApiException +from authentik_client.exceptions import ApiTypeError as ApiTypeError +from authentik_client.exceptions import ApiValueError as ApiValueError +from authentik_client.exceptions import ApiKeyError as ApiKeyError +from authentik_client.exceptions import ApiAttributeError as ApiAttributeError +from authentik_client.exceptions import ApiException as ApiException + +# import models into sdk package +from authentik_client.models.access_denied_challenge import AccessDeniedChallenge as AccessDeniedChallenge +from authentik_client.models.account_lockdown_stage import AccountLockdownStage as AccountLockdownStage +from authentik_client.models.account_lockdown_stage_request import AccountLockdownStageRequest as AccountLockdownStageRequest +from authentik_client.models.agent_authentication_response import AgentAuthenticationResponse as AgentAuthenticationResponse +from authentik_client.models.agent_config import AgentConfig as AgentConfig +from authentik_client.models.agent_connector import AgentConnector as AgentConnector +from authentik_client.models.agent_connector_request import AgentConnectorRequest as AgentConnectorRequest +from authentik_client.models.agent_psso_device_registration_request import AgentPSSODeviceRegistrationRequest as AgentPSSODeviceRegistrationRequest +from authentik_client.models.agent_psso_device_registration_response import AgentPSSODeviceRegistrationResponse as AgentPSSODeviceRegistrationResponse +from authentik_client.models.agent_psso_user_registration_request import AgentPSSOUserRegistrationRequest as AgentPSSOUserRegistrationRequest +from authentik_client.models.agent_token_response import AgentTokenResponse as AgentTokenResponse +from authentik_client.models.alg_enum import AlgEnum as AlgEnum +from authentik_client.models.app import App as App +from authentik_client.models.app_enum import AppEnum as AppEnum +from authentik_client.models.apple_challenge_response_request import AppleChallengeResponseRequest as AppleChallengeResponseRequest +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave as AppleIndependentSecureEnclave +from authentik_client.models.apple_independent_secure_enclave_request import AppleIndependentSecureEnclaveRequest as AppleIndependentSecureEnclaveRequest +from authentik_client.models.apple_login_challenge import AppleLoginChallenge as AppleLoginChallenge +from authentik_client.models.application import Application as Application +from authentik_client.models.application_entitlement import ApplicationEntitlement as ApplicationEntitlement +from authentik_client.models.application_entitlement_request import ApplicationEntitlementRequest as ApplicationEntitlementRequest +from authentik_client.models.application_request import ApplicationRequest as ApplicationRequest +from authentik_client.models.auth_type_enum import AuthTypeEnum as AuthTypeEnum +from authentik_client.models.authenticated_session import AuthenticatedSession as AuthenticatedSession +from authentik_client.models.authenticated_session_asn import AuthenticatedSessionAsn as AuthenticatedSessionAsn +from authentik_client.models.authenticated_session_geo_ip import AuthenticatedSessionGeoIp as AuthenticatedSessionGeoIp +from authentik_client.models.authenticated_session_user_agent import AuthenticatedSessionUserAgent as AuthenticatedSessionUserAgent +from authentik_client.models.authenticated_session_user_agent_device import AuthenticatedSessionUserAgentDevice as AuthenticatedSessionUserAgentDevice +from authentik_client.models.authenticated_session_user_agent_os import AuthenticatedSessionUserAgentOs as AuthenticatedSessionUserAgentOs +from authentik_client.models.authenticated_session_user_agent_user_agent import AuthenticatedSessionUserAgentUserAgent as AuthenticatedSessionUserAgentUserAgent +from authentik_client.models.authentication_enum import AuthenticationEnum as AuthenticationEnum +from authentik_client.models.authenticator_attachment_enum import AuthenticatorAttachmentEnum as AuthenticatorAttachmentEnum +from authentik_client.models.authenticator_duo_challenge import AuthenticatorDuoChallenge as AuthenticatorDuoChallenge +from authentik_client.models.authenticator_duo_challenge_response_request import AuthenticatorDuoChallengeResponseRequest as AuthenticatorDuoChallengeResponseRequest +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage as AuthenticatorDuoStage +from authentik_client.models.authenticator_duo_stage_device_import_response import AuthenticatorDuoStageDeviceImportResponse as AuthenticatorDuoStageDeviceImportResponse +from authentik_client.models.authenticator_duo_stage_manual_device_import_request import AuthenticatorDuoStageManualDeviceImportRequest as AuthenticatorDuoStageManualDeviceImportRequest +from authentik_client.models.authenticator_duo_stage_request import AuthenticatorDuoStageRequest as AuthenticatorDuoStageRequest +from authentik_client.models.authenticator_email_challenge import AuthenticatorEmailChallenge as AuthenticatorEmailChallenge +from authentik_client.models.authenticator_email_challenge_response_request import AuthenticatorEmailChallengeResponseRequest as AuthenticatorEmailChallengeResponseRequest +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage as AuthenticatorEmailStage +from authentik_client.models.authenticator_email_stage_request import AuthenticatorEmailStageRequest as AuthenticatorEmailStageRequest +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage as AuthenticatorEndpointGDTCStage +from authentik_client.models.authenticator_endpoint_gdtc_stage_request import AuthenticatorEndpointGDTCStageRequest as AuthenticatorEndpointGDTCStageRequest +from authentik_client.models.authenticator_sms_challenge import AuthenticatorSMSChallenge as AuthenticatorSMSChallenge +from authentik_client.models.authenticator_sms_challenge_response_request import AuthenticatorSMSChallengeResponseRequest as AuthenticatorSMSChallengeResponseRequest +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage as AuthenticatorSMSStage +from authentik_client.models.authenticator_sms_stage_request import AuthenticatorSMSStageRequest as AuthenticatorSMSStageRequest +from authentik_client.models.authenticator_static_challenge import AuthenticatorStaticChallenge as AuthenticatorStaticChallenge +from authentik_client.models.authenticator_static_challenge_response_request import AuthenticatorStaticChallengeResponseRequest as AuthenticatorStaticChallengeResponseRequest +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage as AuthenticatorStaticStage +from authentik_client.models.authenticator_static_stage_request import AuthenticatorStaticStageRequest as AuthenticatorStaticStageRequest +from authentik_client.models.authenticator_totp_challenge import AuthenticatorTOTPChallenge as AuthenticatorTOTPChallenge +from authentik_client.models.authenticator_totp_challenge_response_request import AuthenticatorTOTPChallengeResponseRequest as AuthenticatorTOTPChallengeResponseRequest +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage as AuthenticatorTOTPStage +from authentik_client.models.authenticator_totp_stage_request import AuthenticatorTOTPStageRequest as AuthenticatorTOTPStageRequest +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage as AuthenticatorValidateStage +from authentik_client.models.authenticator_validate_stage_request import AuthenticatorValidateStageRequest as AuthenticatorValidateStageRequest +from authentik_client.models.authenticator_validation_challenge import AuthenticatorValidationChallenge as AuthenticatorValidationChallenge +from authentik_client.models.authenticator_validation_challenge_response_request import AuthenticatorValidationChallengeResponseRequest as AuthenticatorValidationChallengeResponseRequest +from authentik_client.models.authenticator_web_authn_challenge import AuthenticatorWebAuthnChallenge as AuthenticatorWebAuthnChallenge +from authentik_client.models.authenticator_web_authn_challenge_response_request import AuthenticatorWebAuthnChallengeResponseRequest as AuthenticatorWebAuthnChallengeResponseRequest +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage as AuthenticatorWebAuthnStage +from authentik_client.models.authenticator_web_authn_stage_request import AuthenticatorWebAuthnStageRequest as AuthenticatorWebAuthnStageRequest +from authentik_client.models.authorization_code_auth_method_enum import AuthorizationCodeAuthMethodEnum as AuthorizationCodeAuthMethodEnum +from authentik_client.models.auto_submit_challenge_response_request import AutoSubmitChallengeResponseRequest as AutoSubmitChallengeResponseRequest +from authentik_client.models.autosubmit_challenge import AutosubmitChallenge as AutosubmitChallenge +from authentik_client.models.backends_enum import BackendsEnum as BackendsEnum +from authentik_client.models.binding_type_enum import BindingTypeEnum as BindingTypeEnum +from authentik_client.models.blueprint_file import BlueprintFile as BlueprintFile +from authentik_client.models.blueprint_import_result import BlueprintImportResult as BlueprintImportResult +from authentik_client.models.blueprint_instance import BlueprintInstance as BlueprintInstance +from authentik_client.models.blueprint_instance_request import BlueprintInstanceRequest as BlueprintInstanceRequest +from authentik_client.models.blueprint_instance_status_enum import BlueprintInstanceStatusEnum as BlueprintInstanceStatusEnum +from authentik_client.models.brand import Brand as Brand +from authentik_client.models.brand_request import BrandRequest as BrandRequest +from authentik_client.models.bulk_delete_session_response import BulkDeleteSessionResponse as BulkDeleteSessionResponse +from authentik_client.models.cache import Cache as Cache +from authentik_client.models.capabilities_enum import CapabilitiesEnum as CapabilitiesEnum +from authentik_client.models.captcha_challenge import CaptchaChallenge as CaptchaChallenge +from authentik_client.models.captcha_challenge_response_request import CaptchaChallengeResponseRequest as CaptchaChallengeResponseRequest +from authentik_client.models.captcha_stage import CaptchaStage as CaptchaStage +from authentik_client.models.captcha_stage_request import CaptchaStageRequest as CaptchaStageRequest +from authentik_client.models.cert_attribute_enum import CertAttributeEnum as CertAttributeEnum +from authentik_client.models.certificate_data import CertificateData as CertificateData +from authentik_client.models.certificate_generation_request import CertificateGenerationRequest as CertificateGenerationRequest +from authentik_client.models.certificate_key_pair import CertificateKeyPair as CertificateKeyPair +from authentik_client.models.certificate_key_pair_key_type_enum import CertificateKeyPairKeyTypeEnum as CertificateKeyPairKeyTypeEnum +from authentik_client.models.certificate_key_pair_request import CertificateKeyPairRequest as CertificateKeyPairRequest +from authentik_client.models.challenge_types import ChallengeTypes as ChallengeTypes +from authentik_client.models.client_type_enum import ClientTypeEnum as ClientTypeEnum +from authentik_client.models.compatibility_mode_enum import CompatibilityModeEnum as CompatibilityModeEnum +from authentik_client.models.config import Config as Config +from authentik_client.models.connection_token import ConnectionToken as ConnectionToken +from authentik_client.models.connection_token_request import ConnectionTokenRequest as ConnectionTokenRequest +from authentik_client.models.connector import Connector as Connector +from authentik_client.models.consent_challenge import ConsentChallenge as ConsentChallenge +from authentik_client.models.consent_challenge_response_request import ConsentChallengeResponseRequest as ConsentChallengeResponseRequest +from authentik_client.models.consent_mode_enum import ConsentModeEnum as ConsentModeEnum +from authentik_client.models.consent_permission import ConsentPermission as ConsentPermission +from authentik_client.models.consent_stage import ConsentStage as ConsentStage +from authentik_client.models.consent_stage_request import ConsentStageRequest as ConsentStageRequest +from authentik_client.models.content_type import ContentType as ContentType +from authentik_client.models.content_type_enum import ContentTypeEnum as ContentTypeEnum +from authentik_client.models.contextual_flow_info import ContextualFlowInfo as ContextualFlowInfo +from authentik_client.models.contextual_flow_info_layout_enum import ContextualFlowInfoLayoutEnum as ContextualFlowInfoLayoutEnum +from authentik_client.models.country_code_enum import CountryCodeEnum as CountryCodeEnum +from authentik_client.models.current_brand import CurrentBrand as CurrentBrand +from authentik_client.models.current_brand_flags import CurrentBrandFlags as CurrentBrandFlags +from authentik_client.models.data_export import DataExport as DataExport +from authentik_client.models.delivery_method_enum import DeliveryMethodEnum as DeliveryMethodEnum +from authentik_client.models.denied_action_enum import DeniedActionEnum as DeniedActionEnum +from authentik_client.models.deny_stage import DenyStage as DenyStage +from authentik_client.models.deny_stage_request import DenyStageRequest as DenyStageRequest +from authentik_client.models.detailed_country import DetailedCountry as DetailedCountry +from authentik_client.models.device import Device as Device +from authentik_client.models.device_access_group import DeviceAccessGroup as DeviceAccessGroup +from authentik_client.models.device_access_group_request import DeviceAccessGroupRequest as DeviceAccessGroupRequest +from authentik_client.models.device_challenge import DeviceChallenge as DeviceChallenge +from authentik_client.models.device_challenge_request import DeviceChallengeRequest as DeviceChallengeRequest +from authentik_client.models.device_classes_enum import DeviceClassesEnum as DeviceClassesEnum +from authentik_client.models.device_connection import DeviceConnection as DeviceConnection +from authentik_client.models.device_fact_snapshot import DeviceFactSnapshot as DeviceFactSnapshot +from authentik_client.models.device_facts import DeviceFacts as DeviceFacts +from authentik_client.models.device_facts_os_family import DeviceFactsOSFamily as DeviceFactsOSFamily +from authentik_client.models.device_facts_request import DeviceFactsRequest as DeviceFactsRequest +from authentik_client.models.device_group import DeviceGroup as DeviceGroup +from authentik_client.models.device_group_request import DeviceGroupRequest as DeviceGroupRequest +from authentik_client.models.device_summary import DeviceSummary as DeviceSummary +from authentik_client.models.device_user import DeviceUser as DeviceUser +from authentik_client.models.device_user_binding import DeviceUserBinding as DeviceUserBinding +from authentik_client.models.device_user_binding_request import DeviceUserBindingRequest as DeviceUserBindingRequest +from authentik_client.models.device_user_request import DeviceUserRequest as DeviceUserRequest +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum as DigestAlgorithmEnum +from authentik_client.models.digits_enum import DigitsEnum as DigitsEnum +from authentik_client.models.disk import Disk as Disk +from authentik_client.models.disk_request import DiskRequest as DiskRequest +from authentik_client.models.docker_service_connection import DockerServiceConnection as DockerServiceConnection +from authentik_client.models.docker_service_connection_request import DockerServiceConnectionRequest as DockerServiceConnectionRequest +from authentik_client.models.domain import Domain as Domain +from authentik_client.models.domain_request import DomainRequest as DomainRequest +from authentik_client.models.dummy_challenge import DummyChallenge as DummyChallenge +from authentik_client.models.dummy_challenge_response_request import DummyChallengeResponseRequest as DummyChallengeResponseRequest +from authentik_client.models.dummy_policy import DummyPolicy as DummyPolicy +from authentik_client.models.dummy_policy_request import DummyPolicyRequest as DummyPolicyRequest +from authentik_client.models.dummy_stage import DummyStage as DummyStage +from authentik_client.models.dummy_stage_request import DummyStageRequest as DummyStageRequest +from authentik_client.models.duo_device import DuoDevice as DuoDevice +from authentik_client.models.duo_device_enrollment_status import DuoDeviceEnrollmentStatus as DuoDeviceEnrollmentStatus +from authentik_client.models.duo_device_request import DuoDeviceRequest as DuoDeviceRequest +from authentik_client.models.duo_response_enum import DuoResponseEnum as DuoResponseEnum +from authentik_client.models.email_challenge import EmailChallenge as EmailChallenge +from authentik_client.models.email_challenge_response_request import EmailChallengeResponseRequest as EmailChallengeResponseRequest +from authentik_client.models.email_device import EmailDevice as EmailDevice +from authentik_client.models.email_device_request import EmailDeviceRequest as EmailDeviceRequest +from authentik_client.models.email_stage import EmailStage as EmailStage +from authentik_client.models.email_stage_request import EmailStageRequest as EmailStageRequest +from authentik_client.models.endpoint import Endpoint as Endpoint +from authentik_client.models.endpoint_agent_challenge import EndpointAgentChallenge as EndpointAgentChallenge +from authentik_client.models.endpoint_agent_challenge_response_request import EndpointAgentChallengeResponseRequest as EndpointAgentChallengeResponseRequest +from authentik_client.models.endpoint_auth_mode_enum import EndpointAuthModeEnum as EndpointAuthModeEnum +from authentik_client.models.endpoint_device import EndpointDevice as EndpointDevice +from authentik_client.models.endpoint_device_details import EndpointDeviceDetails as EndpointDeviceDetails +from authentik_client.models.endpoint_device_request import EndpointDeviceRequest as EndpointDeviceRequest +from authentik_client.models.endpoint_request import EndpointRequest as EndpointRequest +from authentik_client.models.endpoint_stage import EndpointStage as EndpointStage +from authentik_client.models.endpoint_stage_request import EndpointStageRequest as EndpointStageRequest +from authentik_client.models.enroll_request import EnrollRequest as EnrollRequest +from authentik_client.models.enrollment_token import EnrollmentToken as EnrollmentToken +from authentik_client.models.enrollment_token_request import EnrollmentTokenRequest as EnrollmentTokenRequest +from authentik_client.models.error_detail import ErrorDetail as ErrorDetail +from authentik_client.models.error_reporting_config import ErrorReportingConfig as ErrorReportingConfig +from authentik_client.models.event import Event as Event +from authentik_client.models.event_actions import EventActions as EventActions +from authentik_client.models.event_matcher_policy import EventMatcherPolicy as EventMatcherPolicy +from authentik_client.models.event_matcher_policy_request import EventMatcherPolicyRequest as EventMatcherPolicyRequest +from authentik_client.models.event_request import EventRequest as EventRequest +from authentik_client.models.event_stats import EventStats as EventStats +from authentik_client.models.event_top_per_user import EventTopPerUser as EventTopPerUser +from authentik_client.models.event_volume import EventVolume as EventVolume +from authentik_client.models.events_requested_enum import EventsRequestedEnum as EventsRequestedEnum +from authentik_client.models.expiring_base_grant_model import ExpiringBaseGrantModel as ExpiringBaseGrantModel +from authentik_client.models.expression_policy import ExpressionPolicy as ExpressionPolicy +from authentik_client.models.expression_policy_request import ExpressionPolicyRequest as ExpressionPolicyRequest +from authentik_client.models.extra_role_object_permission import ExtraRoleObjectPermission as ExtraRoleObjectPermission +from authentik_client.models.file_list import FileList as FileList +from authentik_client.models.fleet_connector import FleetConnector as FleetConnector +from authentik_client.models.fleet_connector_request import FleetConnectorRequest as FleetConnectorRequest +from authentik_client.models.flow import Flow as Flow +from authentik_client.models.flow_challenge_response_request import FlowChallengeResponseRequest as FlowChallengeResponseRequest +from authentik_client.models.flow_designation_enum import FlowDesignationEnum as FlowDesignationEnum +from authentik_client.models.flow_diagram import FlowDiagram as FlowDiagram +from authentik_client.models.flow_error_challenge import FlowErrorChallenge as FlowErrorChallenge +from authentik_client.models.flow_inspection import FlowInspection as FlowInspection +from authentik_client.models.flow_inspector_plan import FlowInspectorPlan as FlowInspectorPlan +from authentik_client.models.flow_layout_enum import FlowLayoutEnum as FlowLayoutEnum +from authentik_client.models.flow_request import FlowRequest as FlowRequest +from authentik_client.models.flow_set import FlowSet as FlowSet +from authentik_client.models.flow_stage_binding import FlowStageBinding as FlowStageBinding +from authentik_client.models.flow_stage_binding_request import FlowStageBindingRequest as FlowStageBindingRequest +from authentik_client.models.footer_link import FooterLink as FooterLink +from authentik_client.models.force_binding_enum import ForceBindingEnum as ForceBindingEnum +from authentik_client.models.format_enum import FormatEnum as FormatEnum +from authentik_client.models.frame_challenge import FrameChallenge as FrameChallenge +from authentik_client.models.frame_challenge_response_request import FrameChallengeResponseRequest as FrameChallengeResponseRequest +from authentik_client.models.generic_error import GenericError as GenericError +from authentik_client.models.geo_ip_policy import GeoIPPolicy as GeoIPPolicy +from authentik_client.models.geo_ip_policy_countries_obj_inner import GeoIPPolicyCountriesObjInner as GeoIPPolicyCountriesObjInner +from authentik_client.models.geo_ip_policy_request import GeoIPPolicyRequest as GeoIPPolicyRequest +from authentik_client.models.geoip_binding_enum import GeoipBindingEnum as GeoipBindingEnum +from authentik_client.models.global_task_status import GlobalTaskStatus as GlobalTaskStatus +from authentik_client.models.google_chrome_connector import GoogleChromeConnector as GoogleChromeConnector +from authentik_client.models.google_chrome_connector_request import GoogleChromeConnectorRequest as GoogleChromeConnectorRequest +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice as GoogleEndpointDevice +from authentik_client.models.google_endpoint_device_request import GoogleEndpointDeviceRequest as GoogleEndpointDeviceRequest +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider as GoogleWorkspaceProvider +from authentik_client.models.google_workspace_provider_group import GoogleWorkspaceProviderGroup as GoogleWorkspaceProviderGroup +from authentik_client.models.google_workspace_provider_group_request import GoogleWorkspaceProviderGroupRequest as GoogleWorkspaceProviderGroupRequest +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping as GoogleWorkspaceProviderMapping +from authentik_client.models.google_workspace_provider_mapping_request import GoogleWorkspaceProviderMappingRequest as GoogleWorkspaceProviderMappingRequest +from authentik_client.models.google_workspace_provider_request import GoogleWorkspaceProviderRequest as GoogleWorkspaceProviderRequest +from authentik_client.models.google_workspace_provider_user import GoogleWorkspaceProviderUser as GoogleWorkspaceProviderUser +from authentik_client.models.google_workspace_provider_user_request import GoogleWorkspaceProviderUserRequest as GoogleWorkspaceProviderUserRequest +from authentik_client.models.grant_types_enum import GrantTypesEnum as GrantTypesEnum +from authentik_client.models.group import Group as Group +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection as GroupKerberosSourceConnection +from authentik_client.models.group_kerberos_source_connection_request import GroupKerberosSourceConnectionRequest as GroupKerberosSourceConnectionRequest +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection as GroupLDAPSourceConnection +from authentik_client.models.group_ldap_source_connection_request import GroupLDAPSourceConnectionRequest as GroupLDAPSourceConnectionRequest +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum as GroupMatchingModeEnum +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection as GroupOAuthSourceConnection +from authentik_client.models.group_o_auth_source_connection_request import GroupOAuthSourceConnectionRequest as GroupOAuthSourceConnectionRequest +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection as GroupPlexSourceConnection +from authentik_client.models.group_plex_source_connection_request import GroupPlexSourceConnectionRequest as GroupPlexSourceConnectionRequest +from authentik_client.models.group_request import GroupRequest as GroupRequest +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection as GroupSAMLSourceConnection +from authentik_client.models.group_saml_source_connection_request import GroupSAMLSourceConnectionRequest as GroupSAMLSourceConnectionRequest +from authentik_client.models.group_source_connection import GroupSourceConnection as GroupSourceConnection +from authentik_client.models.group_source_connection_request import GroupSourceConnectionRequest as GroupSourceConnectionRequest +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection as GroupTelegramSourceConnection +from authentik_client.models.group_telegram_source_connection_request import GroupTelegramSourceConnectionRequest as GroupTelegramSourceConnectionRequest +from authentik_client.models.hardware import Hardware as Hardware +from authentik_client.models.hardware_request import HardwareRequest as HardwareRequest +from authentik_client.models.identification_challenge import IdentificationChallenge as IdentificationChallenge +from authentik_client.models.identification_challenge_response_request import IdentificationChallengeResponseRequest as IdentificationChallengeResponseRequest +from authentik_client.models.identification_stage import IdentificationStage as IdentificationStage +from authentik_client.models.identification_stage_request import IdentificationStageRequest as IdentificationStageRequest +from authentik_client.models.iframe_logout_challenge import IframeLogoutChallenge as IframeLogoutChallenge +from authentik_client.models.iframe_logout_challenge_response_request import IframeLogoutChallengeResponseRequest as IframeLogoutChallengeResponseRequest +from authentik_client.models.impersonation_request import ImpersonationRequest as ImpersonationRequest +from authentik_client.models.initial_permissions import InitialPermissions as InitialPermissions +from authentik_client.models.initial_permissions_request import InitialPermissionsRequest as InitialPermissionsRequest +from authentik_client.models.install_id import InstallID as InstallID +from authentik_client.models.intent_enum import IntentEnum as IntentEnum +from authentik_client.models.invalid_response_action_enum import InvalidResponseActionEnum as InvalidResponseActionEnum +from authentik_client.models.invitation import Invitation as Invitation +from authentik_client.models.invitation_request import InvitationRequest as InvitationRequest +from authentik_client.models.invitation_send_email_request import InvitationSendEmailRequest as InvitationSendEmailRequest +from authentik_client.models.invitation_stage import InvitationStage as InvitationStage +from authentik_client.models.invitation_stage_request import InvitationStageRequest as InvitationStageRequest +from authentik_client.models.issuer_mode_enum import IssuerModeEnum as IssuerModeEnum +from authentik_client.models.kadmin_type_enum import KadminTypeEnum as KadminTypeEnum +from authentik_client.models.kerberos_source import KerberosSource as KerberosSource +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping as KerberosSourcePropertyMapping +from authentik_client.models.kerberos_source_property_mapping_request import KerberosSourcePropertyMappingRequest as KerberosSourcePropertyMappingRequest +from authentik_client.models.kerberos_source_request import KerberosSourceRequest as KerberosSourceRequest +from authentik_client.models.key_type_enum import KeyTypeEnum as KeyTypeEnum +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection as KubernetesServiceConnection +from authentik_client.models.kubernetes_service_connection_request import KubernetesServiceConnectionRequest as KubernetesServiceConnectionRequest +from authentik_client.models.ldapapi_access_mode import LDAPAPIAccessMode as LDAPAPIAccessMode +from authentik_client.models.ldap_check_access import LDAPCheckAccess as LDAPCheckAccess +from authentik_client.models.ldap_debug import LDAPDebug as LDAPDebug +from authentik_client.models.ldap_outpost_config import LDAPOutpostConfig as LDAPOutpostConfig +from authentik_client.models.ldap_provider import LDAPProvider as LDAPProvider +from authentik_client.models.ldap_provider_request import LDAPProviderRequest as LDAPProviderRequest +from authentik_client.models.ldap_source import LDAPSource as LDAPSource +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping as LDAPSourcePropertyMapping +from authentik_client.models.ldap_source_property_mapping_request import LDAPSourcePropertyMappingRequest as LDAPSourcePropertyMappingRequest +from authentik_client.models.ldap_source_request import LDAPSourceRequest as LDAPSourceRequest +from authentik_client.models.lang_enum import LangEnum as LangEnum +from authentik_client.models.last_task_status_enum import LastTaskStatusEnum as LastTaskStatusEnum +from authentik_client.models.license import License as License +from authentik_client.models.license_flags_enum import LicenseFlagsEnum as LicenseFlagsEnum +from authentik_client.models.license_forecast import LicenseForecast as LicenseForecast +from authentik_client.models.license_request import LicenseRequest as LicenseRequest +from authentik_client.models.license_status_enum import LicenseStatusEnum as LicenseStatusEnum +from authentik_client.models.license_summary import LicenseSummary as LicenseSummary +from authentik_client.models.license_summary_status_enum import LicenseSummaryStatusEnum as LicenseSummaryStatusEnum +from authentik_client.models.lifecycle_iteration import LifecycleIteration as LifecycleIteration +from authentik_client.models.lifecycle_iteration_request import LifecycleIterationRequest as LifecycleIterationRequest +from authentik_client.models.lifecycle_iteration_state_enum import LifecycleIterationStateEnum as LifecycleIterationStateEnum +from authentik_client.models.lifecycle_rule import LifecycleRule as LifecycleRule +from authentik_client.models.lifecycle_rule_request import LifecycleRuleRequest as LifecycleRuleRequest +from authentik_client.models.link import Link as Link +from authentik_client.models.log_event import LogEvent as LogEvent +from authentik_client.models.log_level_enum import LogLevelEnum as LogLevelEnum +from authentik_client.models.login_challenge_types import LoginChallengeTypes as LoginChallengeTypes +from authentik_client.models.login_source import LoginSource as LoginSource +from authentik_client.models.logout_url import LogoutURL as LogoutURL +from authentik_client.models.mdm_config_request import MDMConfigRequest as MDMConfigRequest +from authentik_client.models.mdm_config_response import MDMConfigResponse as MDMConfigResponse +from authentik_client.models.matching_mode_enum import MatchingModeEnum as MatchingModeEnum +from authentik_client.models.metadata import Metadata as Metadata +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider as MicrosoftEntraProvider +from authentik_client.models.microsoft_entra_provider_group import MicrosoftEntraProviderGroup as MicrosoftEntraProviderGroup +from authentik_client.models.microsoft_entra_provider_group_request import MicrosoftEntraProviderGroupRequest as MicrosoftEntraProviderGroupRequest +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping as MicrosoftEntraProviderMapping +from authentik_client.models.microsoft_entra_provider_mapping_request import MicrosoftEntraProviderMappingRequest as MicrosoftEntraProviderMappingRequest +from authentik_client.models.microsoft_entra_provider_request import MicrosoftEntraProviderRequest as MicrosoftEntraProviderRequest +from authentik_client.models.microsoft_entra_provider_user import MicrosoftEntraProviderUser as MicrosoftEntraProviderUser +from authentik_client.models.microsoft_entra_provider_user_request import MicrosoftEntraProviderUserRequest as MicrosoftEntraProviderUserRequest +from authentik_client.models.model_enum import ModelEnum as ModelEnum +from authentik_client.models.model_request import ModelRequest as ModelRequest +from authentik_client.models.mutual_tls_stage import MutualTLSStage as MutualTLSStage +from authentik_client.models.mutual_tls_stage_request import MutualTLSStageRequest as MutualTLSStageRequest +from authentik_client.models.native_logout_challenge import NativeLogoutChallenge as NativeLogoutChallenge +from authentik_client.models.native_logout_challenge_response_request import NativeLogoutChallengeResponseRequest as NativeLogoutChallengeResponseRequest +from authentik_client.models.network import Network as Network +from authentik_client.models.network_binding_enum import NetworkBindingEnum as NetworkBindingEnum +from authentik_client.models.network_interface import NetworkInterface as NetworkInterface +from authentik_client.models.network_interface_request import NetworkInterfaceRequest as NetworkInterfaceRequest +from authentik_client.models.network_request import NetworkRequest as NetworkRequest +from authentik_client.models.not_configured_action_enum import NotConfiguredActionEnum as NotConfiguredActionEnum +from authentik_client.models.notification import Notification as Notification +from authentik_client.models.notification_request import NotificationRequest as NotificationRequest +from authentik_client.models.notification_rule import NotificationRule as NotificationRule +from authentik_client.models.notification_rule_request import NotificationRuleRequest as NotificationRuleRequest +from authentik_client.models.notification_transport import NotificationTransport as NotificationTransport +from authentik_client.models.notification_transport_request import NotificationTransportRequest as NotificationTransportRequest +from authentik_client.models.notification_transport_test import NotificationTransportTest as NotificationTransportTest +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping as NotificationWebhookMapping +from authentik_client.models.notification_webhook_mapping_request import NotificationWebhookMappingRequest as NotificationWebhookMappingRequest +from authentik_client.models.o_auth2_provider import OAuth2Provider as OAuth2Provider +from authentik_client.models.o_auth2_provider_logout_method_enum import OAuth2ProviderLogoutMethodEnum as OAuth2ProviderLogoutMethodEnum +from authentik_client.models.o_auth2_provider_request import OAuth2ProviderRequest as OAuth2ProviderRequest +from authentik_client.models.o_auth2_provider_setup_urls import OAuth2ProviderSetupURLs as OAuth2ProviderSetupURLs +from authentik_client.models.o_auth_device_code_challenge import OAuthDeviceCodeChallenge as OAuthDeviceCodeChallenge +from authentik_client.models.o_auth_device_code_challenge_response_request import OAuthDeviceCodeChallengeResponseRequest as OAuthDeviceCodeChallengeResponseRequest +from authentik_client.models.o_auth_device_code_finish_challenge import OAuthDeviceCodeFinishChallenge as OAuthDeviceCodeFinishChallenge +from authentik_client.models.o_auth_device_code_finish_challenge_response_request import OAuthDeviceCodeFinishChallengeResponseRequest as OAuthDeviceCodeFinishChallengeResponseRequest +from authentik_client.models.o_auth_source import OAuthSource as OAuthSource +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping as OAuthSourcePropertyMapping +from authentik_client.models.o_auth_source_property_mapping_request import OAuthSourcePropertyMappingRequest as OAuthSourcePropertyMappingRequest +from authentik_client.models.o_auth_source_request import OAuthSourceRequest as OAuthSourceRequest +from authentik_client.models.open_id_connect_configuration import OpenIDConnectConfiguration as OpenIDConnectConfiguration +from authentik_client.models.operating_system import OperatingSystem as OperatingSystem +from authentik_client.models.operating_system_request import OperatingSystemRequest as OperatingSystemRequest +from authentik_client.models.outgoing_sync_delete_action import OutgoingSyncDeleteAction as OutgoingSyncDeleteAction +from authentik_client.models.outpost import Outpost as Outpost +from authentik_client.models.outpost_default_config import OutpostDefaultConfig as OutpostDefaultConfig +from authentik_client.models.outpost_health import OutpostHealth as OutpostHealth +from authentik_client.models.outpost_request import OutpostRequest as OutpostRequest +from authentik_client.models.outpost_type_enum import OutpostTypeEnum as OutpostTypeEnum +from authentik_client.models.pkce_method_enum import PKCEMethodEnum as PKCEMethodEnum +from authentik_client.models.paginated_account_lockdown_stage_list import PaginatedAccountLockdownStageList as PaginatedAccountLockdownStageList +from authentik_client.models.paginated_agent_connector_list import PaginatedAgentConnectorList as PaginatedAgentConnectorList +from authentik_client.models.paginated_apple_independent_secure_enclave_list import PaginatedAppleIndependentSecureEnclaveList as PaginatedAppleIndependentSecureEnclaveList +from authentik_client.models.paginated_application_entitlement_list import PaginatedApplicationEntitlementList as PaginatedApplicationEntitlementList +from authentik_client.models.paginated_application_list import PaginatedApplicationList as PaginatedApplicationList +from authentik_client.models.paginated_authenticated_session_list import PaginatedAuthenticatedSessionList as PaginatedAuthenticatedSessionList +from authentik_client.models.paginated_authenticator_duo_stage_list import PaginatedAuthenticatorDuoStageList as PaginatedAuthenticatorDuoStageList +from authentik_client.models.paginated_authenticator_email_stage_list import PaginatedAuthenticatorEmailStageList as PaginatedAuthenticatorEmailStageList +from authentik_client.models.paginated_authenticator_endpoint_gdtc_stage_list import PaginatedAuthenticatorEndpointGDTCStageList as PaginatedAuthenticatorEndpointGDTCStageList +from authentik_client.models.paginated_authenticator_sms_stage_list import PaginatedAuthenticatorSMSStageList as PaginatedAuthenticatorSMSStageList +from authentik_client.models.paginated_authenticator_static_stage_list import PaginatedAuthenticatorStaticStageList as PaginatedAuthenticatorStaticStageList +from authentik_client.models.paginated_authenticator_totp_stage_list import PaginatedAuthenticatorTOTPStageList as PaginatedAuthenticatorTOTPStageList +from authentik_client.models.paginated_authenticator_validate_stage_list import PaginatedAuthenticatorValidateStageList as PaginatedAuthenticatorValidateStageList +from authentik_client.models.paginated_authenticator_web_authn_stage_list import PaginatedAuthenticatorWebAuthnStageList as PaginatedAuthenticatorWebAuthnStageList +from authentik_client.models.paginated_blueprint_instance_list import PaginatedBlueprintInstanceList as PaginatedBlueprintInstanceList +from authentik_client.models.paginated_brand_list import PaginatedBrandList as PaginatedBrandList +from authentik_client.models.paginated_captcha_stage_list import PaginatedCaptchaStageList as PaginatedCaptchaStageList +from authentik_client.models.paginated_certificate_key_pair_list import PaginatedCertificateKeyPairList as PaginatedCertificateKeyPairList +from authentik_client.models.paginated_connection_token_list import PaginatedConnectionTokenList as PaginatedConnectionTokenList +from authentik_client.models.paginated_connector_list import PaginatedConnectorList as PaginatedConnectorList +from authentik_client.models.paginated_consent_stage_list import PaginatedConsentStageList as PaginatedConsentStageList +from authentik_client.models.paginated_data_export_list import PaginatedDataExportList as PaginatedDataExportList +from authentik_client.models.paginated_deny_stage_list import PaginatedDenyStageList as PaginatedDenyStageList +from authentik_client.models.paginated_device_access_group_list import PaginatedDeviceAccessGroupList as PaginatedDeviceAccessGroupList +from authentik_client.models.paginated_device_user_binding_list import PaginatedDeviceUserBindingList as PaginatedDeviceUserBindingList +from authentik_client.models.paginated_docker_service_connection_list import PaginatedDockerServiceConnectionList as PaginatedDockerServiceConnectionList +from authentik_client.models.paginated_domain_list import PaginatedDomainList as PaginatedDomainList +from authentik_client.models.paginated_dummy_policy_list import PaginatedDummyPolicyList as PaginatedDummyPolicyList +from authentik_client.models.paginated_dummy_stage_list import PaginatedDummyStageList as PaginatedDummyStageList +from authentik_client.models.paginated_duo_device_list import PaginatedDuoDeviceList as PaginatedDuoDeviceList +from authentik_client.models.paginated_email_device_list import PaginatedEmailDeviceList as PaginatedEmailDeviceList +from authentik_client.models.paginated_email_stage_list import PaginatedEmailStageList as PaginatedEmailStageList +from authentik_client.models.paginated_endpoint_device_list import PaginatedEndpointDeviceList as PaginatedEndpointDeviceList +from authentik_client.models.paginated_endpoint_list import PaginatedEndpointList as PaginatedEndpointList +from authentik_client.models.paginated_endpoint_stage_list import PaginatedEndpointStageList as PaginatedEndpointStageList +from authentik_client.models.paginated_enrollment_token_list import PaginatedEnrollmentTokenList as PaginatedEnrollmentTokenList +from authentik_client.models.paginated_event_list import PaginatedEventList as PaginatedEventList +from authentik_client.models.paginated_event_matcher_policy_list import PaginatedEventMatcherPolicyList as PaginatedEventMatcherPolicyList +from authentik_client.models.paginated_expiring_base_grant_model_list import PaginatedExpiringBaseGrantModelList as PaginatedExpiringBaseGrantModelList +from authentik_client.models.paginated_expression_policy_list import PaginatedExpressionPolicyList as PaginatedExpressionPolicyList +from authentik_client.models.paginated_extra_role_object_permission_list import PaginatedExtraRoleObjectPermissionList as PaginatedExtraRoleObjectPermissionList +from authentik_client.models.paginated_fleet_connector_list import PaginatedFleetConnectorList as PaginatedFleetConnectorList +from authentik_client.models.paginated_flow_list import PaginatedFlowList as PaginatedFlowList +from authentik_client.models.paginated_flow_stage_binding_list import PaginatedFlowStageBindingList as PaginatedFlowStageBindingList +from authentik_client.models.paginated_geo_ip_policy_list import PaginatedGeoIPPolicyList as PaginatedGeoIPPolicyList +from authentik_client.models.paginated_google_chrome_connector_list import PaginatedGoogleChromeConnectorList as PaginatedGoogleChromeConnectorList +from authentik_client.models.paginated_google_endpoint_device_list import PaginatedGoogleEndpointDeviceList as PaginatedGoogleEndpointDeviceList +from authentik_client.models.paginated_google_workspace_provider_group_list import PaginatedGoogleWorkspaceProviderGroupList as PaginatedGoogleWorkspaceProviderGroupList +from authentik_client.models.paginated_google_workspace_provider_list import PaginatedGoogleWorkspaceProviderList as PaginatedGoogleWorkspaceProviderList +from authentik_client.models.paginated_google_workspace_provider_mapping_list import PaginatedGoogleWorkspaceProviderMappingList as PaginatedGoogleWorkspaceProviderMappingList +from authentik_client.models.paginated_google_workspace_provider_user_list import PaginatedGoogleWorkspaceProviderUserList as PaginatedGoogleWorkspaceProviderUserList +from authentik_client.models.paginated_group_kerberos_source_connection_list import PaginatedGroupKerberosSourceConnectionList as PaginatedGroupKerberosSourceConnectionList +from authentik_client.models.paginated_group_ldap_source_connection_list import PaginatedGroupLDAPSourceConnectionList as PaginatedGroupLDAPSourceConnectionList +from authentik_client.models.paginated_group_list import PaginatedGroupList as PaginatedGroupList +from authentik_client.models.paginated_group_o_auth_source_connection_list import PaginatedGroupOAuthSourceConnectionList as PaginatedGroupOAuthSourceConnectionList +from authentik_client.models.paginated_group_plex_source_connection_list import PaginatedGroupPlexSourceConnectionList as PaginatedGroupPlexSourceConnectionList +from authentik_client.models.paginated_group_saml_source_connection_list import PaginatedGroupSAMLSourceConnectionList as PaginatedGroupSAMLSourceConnectionList +from authentik_client.models.paginated_group_source_connection_list import PaginatedGroupSourceConnectionList as PaginatedGroupSourceConnectionList +from authentik_client.models.paginated_group_telegram_source_connection_list import PaginatedGroupTelegramSourceConnectionList as PaginatedGroupTelegramSourceConnectionList +from authentik_client.models.paginated_identification_stage_list import PaginatedIdentificationStageList as PaginatedIdentificationStageList +from authentik_client.models.paginated_initial_permissions_list import PaginatedInitialPermissionsList as PaginatedInitialPermissionsList +from authentik_client.models.paginated_invitation_list import PaginatedInvitationList as PaginatedInvitationList +from authentik_client.models.paginated_invitation_stage_list import PaginatedInvitationStageList as PaginatedInvitationStageList +from authentik_client.models.paginated_kerberos_source_list import PaginatedKerberosSourceList as PaginatedKerberosSourceList +from authentik_client.models.paginated_kerberos_source_property_mapping_list import PaginatedKerberosSourcePropertyMappingList as PaginatedKerberosSourcePropertyMappingList +from authentik_client.models.paginated_kubernetes_service_connection_list import PaginatedKubernetesServiceConnectionList as PaginatedKubernetesServiceConnectionList +from authentik_client.models.paginated_ldap_outpost_config_list import PaginatedLDAPOutpostConfigList as PaginatedLDAPOutpostConfigList +from authentik_client.models.paginated_ldap_provider_list import PaginatedLDAPProviderList as PaginatedLDAPProviderList +from authentik_client.models.paginated_ldap_source_list import PaginatedLDAPSourceList as PaginatedLDAPSourceList +from authentik_client.models.paginated_ldap_source_property_mapping_list import PaginatedLDAPSourcePropertyMappingList as PaginatedLDAPSourcePropertyMappingList +from authentik_client.models.paginated_license_list import PaginatedLicenseList as PaginatedLicenseList +from authentik_client.models.paginated_lifecycle_iteration_list import PaginatedLifecycleIterationList as PaginatedLifecycleIterationList +from authentik_client.models.paginated_lifecycle_rule_list import PaginatedLifecycleRuleList as PaginatedLifecycleRuleList +from authentik_client.models.paginated_microsoft_entra_provider_group_list import PaginatedMicrosoftEntraProviderGroupList as PaginatedMicrosoftEntraProviderGroupList +from authentik_client.models.paginated_microsoft_entra_provider_list import PaginatedMicrosoftEntraProviderList as PaginatedMicrosoftEntraProviderList +from authentik_client.models.paginated_microsoft_entra_provider_mapping_list import PaginatedMicrosoftEntraProviderMappingList as PaginatedMicrosoftEntraProviderMappingList +from authentik_client.models.paginated_microsoft_entra_provider_user_list import PaginatedMicrosoftEntraProviderUserList as PaginatedMicrosoftEntraProviderUserList +from authentik_client.models.paginated_mutual_tls_stage_list import PaginatedMutualTLSStageList as PaginatedMutualTLSStageList +from authentik_client.models.paginated_notification_list import PaginatedNotificationList as PaginatedNotificationList +from authentik_client.models.paginated_notification_rule_list import PaginatedNotificationRuleList as PaginatedNotificationRuleList +from authentik_client.models.paginated_notification_transport_list import PaginatedNotificationTransportList as PaginatedNotificationTransportList +from authentik_client.models.paginated_notification_webhook_mapping_list import PaginatedNotificationWebhookMappingList as PaginatedNotificationWebhookMappingList +from authentik_client.models.paginated_o_auth2_provider_list import PaginatedOAuth2ProviderList as PaginatedOAuth2ProviderList +from authentik_client.models.paginated_o_auth_source_list import PaginatedOAuthSourceList as PaginatedOAuthSourceList +from authentik_client.models.paginated_o_auth_source_property_mapping_list import PaginatedOAuthSourcePropertyMappingList as PaginatedOAuthSourcePropertyMappingList +from authentik_client.models.paginated_outpost_list import PaginatedOutpostList as PaginatedOutpostList +from authentik_client.models.paginated_password_expiry_policy_list import PaginatedPasswordExpiryPolicyList as PaginatedPasswordExpiryPolicyList +from authentik_client.models.paginated_password_policy_list import PaginatedPasswordPolicyList as PaginatedPasswordPolicyList +from authentik_client.models.paginated_password_stage_list import PaginatedPasswordStageList as PaginatedPasswordStageList +from authentik_client.models.paginated_permission_list import PaginatedPermissionList as PaginatedPermissionList +from authentik_client.models.paginated_plex_source_list import PaginatedPlexSourceList as PaginatedPlexSourceList +from authentik_client.models.paginated_plex_source_property_mapping_list import PaginatedPlexSourcePropertyMappingList as PaginatedPlexSourcePropertyMappingList +from authentik_client.models.paginated_policy_binding_list import PaginatedPolicyBindingList as PaginatedPolicyBindingList +from authentik_client.models.paginated_policy_list import PaginatedPolicyList as PaginatedPolicyList +from authentik_client.models.paginated_prompt_list import PaginatedPromptList as PaginatedPromptList +from authentik_client.models.paginated_prompt_stage_list import PaginatedPromptStageList as PaginatedPromptStageList +from authentik_client.models.paginated_property_mapping_list import PaginatedPropertyMappingList as PaginatedPropertyMappingList +from authentik_client.models.paginated_provider_list import PaginatedProviderList as PaginatedProviderList +from authentik_client.models.paginated_proxy_outpost_config_list import PaginatedProxyOutpostConfigList as PaginatedProxyOutpostConfigList +from authentik_client.models.paginated_proxy_provider_list import PaginatedProxyProviderList as PaginatedProxyProviderList +from authentik_client.models.paginated_rac_property_mapping_list import PaginatedRACPropertyMappingList as PaginatedRACPropertyMappingList +from authentik_client.models.paginated_rac_provider_list import PaginatedRACProviderList as PaginatedRACProviderList +from authentik_client.models.paginated_radius_outpost_config_list import PaginatedRadiusOutpostConfigList as PaginatedRadiusOutpostConfigList +from authentik_client.models.paginated_radius_provider_list import PaginatedRadiusProviderList as PaginatedRadiusProviderList +from authentik_client.models.paginated_radius_provider_property_mapping_list import PaginatedRadiusProviderPropertyMappingList as PaginatedRadiusProviderPropertyMappingList +from authentik_client.models.paginated_redirect_stage_list import PaginatedRedirectStageList as PaginatedRedirectStageList +from authentik_client.models.paginated_reputation_list import PaginatedReputationList as PaginatedReputationList +from authentik_client.models.paginated_reputation_policy_list import PaginatedReputationPolicyList as PaginatedReputationPolicyList +from authentik_client.models.paginated_role_assigned_object_permission_list import PaginatedRoleAssignedObjectPermissionList as PaginatedRoleAssignedObjectPermissionList +from authentik_client.models.paginated_role_list import PaginatedRoleList as PaginatedRoleList +from authentik_client.models.paginated_saml_property_mapping_list import PaginatedSAMLPropertyMappingList as PaginatedSAMLPropertyMappingList +from authentik_client.models.paginated_saml_provider_list import PaginatedSAMLProviderList as PaginatedSAMLProviderList +from authentik_client.models.paginated_saml_source_list import PaginatedSAMLSourceList as PaginatedSAMLSourceList +from authentik_client.models.paginated_saml_source_property_mapping_list import PaginatedSAMLSourcePropertyMappingList as PaginatedSAMLSourcePropertyMappingList +from authentik_client.models.paginated_scim_mapping_list import PaginatedSCIMMappingList as PaginatedSCIMMappingList +from authentik_client.models.paginated_scim_provider_group_list import PaginatedSCIMProviderGroupList as PaginatedSCIMProviderGroupList +from authentik_client.models.paginated_scim_provider_list import PaginatedSCIMProviderList as PaginatedSCIMProviderList +from authentik_client.models.paginated_scim_provider_user_list import PaginatedSCIMProviderUserList as PaginatedSCIMProviderUserList +from authentik_client.models.paginated_scim_source_group_list import PaginatedSCIMSourceGroupList as PaginatedSCIMSourceGroupList +from authentik_client.models.paginated_scim_source_list import PaginatedSCIMSourceList as PaginatedSCIMSourceList +from authentik_client.models.paginated_scim_source_property_mapping_list import PaginatedSCIMSourcePropertyMappingList as PaginatedSCIMSourcePropertyMappingList +from authentik_client.models.paginated_scim_source_user_list import PaginatedSCIMSourceUserList as PaginatedSCIMSourceUserList +from authentik_client.models.paginated_sms_device_list import PaginatedSMSDeviceList as PaginatedSMSDeviceList +from authentik_client.models.paginated_ssf_provider_list import PaginatedSSFProviderList as PaginatedSSFProviderList +from authentik_client.models.paginated_ssf_stream_list import PaginatedSSFStreamList as PaginatedSSFStreamList +from authentik_client.models.paginated_schedule_list import PaginatedScheduleList as PaginatedScheduleList +from authentik_client.models.paginated_scope_mapping_list import PaginatedScopeMappingList as PaginatedScopeMappingList +from authentik_client.models.paginated_service_connection_list import PaginatedServiceConnectionList as PaginatedServiceConnectionList +from authentik_client.models.paginated_source_list import PaginatedSourceList as PaginatedSourceList +from authentik_client.models.paginated_source_stage_list import PaginatedSourceStageList as PaginatedSourceStageList +from authentik_client.models.paginated_stage_list import PaginatedStageList as PaginatedStageList +from authentik_client.models.paginated_static_device_list import PaginatedStaticDeviceList as PaginatedStaticDeviceList +from authentik_client.models.paginated_totp_device_list import PaginatedTOTPDeviceList as PaginatedTOTPDeviceList +from authentik_client.models.paginated_task_list import PaginatedTaskList as PaginatedTaskList +from authentik_client.models.paginated_telegram_source_list import PaginatedTelegramSourceList as PaginatedTelegramSourceList +from authentik_client.models.paginated_telegram_source_property_mapping_list import PaginatedTelegramSourcePropertyMappingList as PaginatedTelegramSourcePropertyMappingList +from authentik_client.models.paginated_tenant_list import PaginatedTenantList as PaginatedTenantList +from authentik_client.models.paginated_token_list import PaginatedTokenList as PaginatedTokenList +from authentik_client.models.paginated_token_model_list import PaginatedTokenModelList as PaginatedTokenModelList +from authentik_client.models.paginated_unique_password_policy_list import PaginatedUniquePasswordPolicyList as PaginatedUniquePasswordPolicyList +from authentik_client.models.paginated_user_consent_list import PaginatedUserConsentList as PaginatedUserConsentList +from authentik_client.models.paginated_user_delete_stage_list import PaginatedUserDeleteStageList as PaginatedUserDeleteStageList +from authentik_client.models.paginated_user_kerberos_source_connection_list import PaginatedUserKerberosSourceConnectionList as PaginatedUserKerberosSourceConnectionList +from authentik_client.models.paginated_user_ldap_source_connection_list import PaginatedUserLDAPSourceConnectionList as PaginatedUserLDAPSourceConnectionList +from authentik_client.models.paginated_user_list import PaginatedUserList as PaginatedUserList +from authentik_client.models.paginated_user_login_stage_list import PaginatedUserLoginStageList as PaginatedUserLoginStageList +from authentik_client.models.paginated_user_logout_stage_list import PaginatedUserLogoutStageList as PaginatedUserLogoutStageList +from authentik_client.models.paginated_user_o_auth_source_connection_list import PaginatedUserOAuthSourceConnectionList as PaginatedUserOAuthSourceConnectionList +from authentik_client.models.paginated_user_plex_source_connection_list import PaginatedUserPlexSourceConnectionList as PaginatedUserPlexSourceConnectionList +from authentik_client.models.paginated_user_saml_source_connection_list import PaginatedUserSAMLSourceConnectionList as PaginatedUserSAMLSourceConnectionList +from authentik_client.models.paginated_user_source_connection_list import PaginatedUserSourceConnectionList as PaginatedUserSourceConnectionList +from authentik_client.models.paginated_user_telegram_source_connection_list import PaginatedUserTelegramSourceConnectionList as PaginatedUserTelegramSourceConnectionList +from authentik_client.models.paginated_user_write_stage_list import PaginatedUserWriteStageList as PaginatedUserWriteStageList +from authentik_client.models.paginated_ws_federation_provider_list import PaginatedWSFederationProviderList as PaginatedWSFederationProviderList +from authentik_client.models.paginated_web_authn_device_list import PaginatedWebAuthnDeviceList as PaginatedWebAuthnDeviceList +from authentik_client.models.paginated_web_authn_device_type_list import PaginatedWebAuthnDeviceTypeList as PaginatedWebAuthnDeviceTypeList +from authentik_client.models.pagination import Pagination as Pagination +from authentik_client.models.partial_group import PartialGroup as PartialGroup +from authentik_client.models.partial_user import PartialUser as PartialUser +from authentik_client.models.password_challenge import PasswordChallenge as PasswordChallenge +from authentik_client.models.password_challenge_response_request import PasswordChallengeResponseRequest as PasswordChallengeResponseRequest +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy as PasswordExpiryPolicy +from authentik_client.models.password_expiry_policy_request import PasswordExpiryPolicyRequest as PasswordExpiryPolicyRequest +from authentik_client.models.password_policy import PasswordPolicy as PasswordPolicy +from authentik_client.models.password_policy_request import PasswordPolicyRequest as PasswordPolicyRequest +from authentik_client.models.password_stage import PasswordStage as PasswordStage +from authentik_client.models.password_stage_request import PasswordStageRequest as PasswordStageRequest +from authentik_client.models.patched_account_lockdown_stage_request import PatchedAccountLockdownStageRequest as PatchedAccountLockdownStageRequest +from authentik_client.models.patched_agent_connector_request import PatchedAgentConnectorRequest as PatchedAgentConnectorRequest +from authentik_client.models.patched_apple_independent_secure_enclave_request import PatchedAppleIndependentSecureEnclaveRequest as PatchedAppleIndependentSecureEnclaveRequest +from authentik_client.models.patched_application_entitlement_request import PatchedApplicationEntitlementRequest as PatchedApplicationEntitlementRequest +from authentik_client.models.patched_application_request import PatchedApplicationRequest as PatchedApplicationRequest +from authentik_client.models.patched_authenticator_duo_stage_request import PatchedAuthenticatorDuoStageRequest as PatchedAuthenticatorDuoStageRequest +from authentik_client.models.patched_authenticator_email_stage_request import PatchedAuthenticatorEmailStageRequest as PatchedAuthenticatorEmailStageRequest +from authentik_client.models.patched_authenticator_endpoint_gdtc_stage_request import PatchedAuthenticatorEndpointGDTCStageRequest as PatchedAuthenticatorEndpointGDTCStageRequest +from authentik_client.models.patched_authenticator_sms_stage_request import PatchedAuthenticatorSMSStageRequest as PatchedAuthenticatorSMSStageRequest +from authentik_client.models.patched_authenticator_static_stage_request import PatchedAuthenticatorStaticStageRequest as PatchedAuthenticatorStaticStageRequest +from authentik_client.models.patched_authenticator_totp_stage_request import PatchedAuthenticatorTOTPStageRequest as PatchedAuthenticatorTOTPStageRequest +from authentik_client.models.patched_authenticator_validate_stage_request import PatchedAuthenticatorValidateStageRequest as PatchedAuthenticatorValidateStageRequest +from authentik_client.models.patched_authenticator_web_authn_stage_request import PatchedAuthenticatorWebAuthnStageRequest as PatchedAuthenticatorWebAuthnStageRequest +from authentik_client.models.patched_blueprint_instance_request import PatchedBlueprintInstanceRequest as PatchedBlueprintInstanceRequest +from authentik_client.models.patched_brand_request import PatchedBrandRequest as PatchedBrandRequest +from authentik_client.models.patched_captcha_stage_request import PatchedCaptchaStageRequest as PatchedCaptchaStageRequest +from authentik_client.models.patched_certificate_key_pair_request import PatchedCertificateKeyPairRequest as PatchedCertificateKeyPairRequest +from authentik_client.models.patched_connection_token_request import PatchedConnectionTokenRequest as PatchedConnectionTokenRequest +from authentik_client.models.patched_consent_stage_request import PatchedConsentStageRequest as PatchedConsentStageRequest +from authentik_client.models.patched_deny_stage_request import PatchedDenyStageRequest as PatchedDenyStageRequest +from authentik_client.models.patched_device_access_group_request import PatchedDeviceAccessGroupRequest as PatchedDeviceAccessGroupRequest +from authentik_client.models.patched_device_user_binding_request import PatchedDeviceUserBindingRequest as PatchedDeviceUserBindingRequest +from authentik_client.models.patched_docker_service_connection_request import PatchedDockerServiceConnectionRequest as PatchedDockerServiceConnectionRequest +from authentik_client.models.patched_domain_request import PatchedDomainRequest as PatchedDomainRequest +from authentik_client.models.patched_dummy_policy_request import PatchedDummyPolicyRequest as PatchedDummyPolicyRequest +from authentik_client.models.patched_dummy_stage_request import PatchedDummyStageRequest as PatchedDummyStageRequest +from authentik_client.models.patched_duo_device_request import PatchedDuoDeviceRequest as PatchedDuoDeviceRequest +from authentik_client.models.patched_email_device_request import PatchedEmailDeviceRequest as PatchedEmailDeviceRequest +from authentik_client.models.patched_email_stage_request import PatchedEmailStageRequest as PatchedEmailStageRequest +from authentik_client.models.patched_endpoint_device_request import PatchedEndpointDeviceRequest as PatchedEndpointDeviceRequest +from authentik_client.models.patched_endpoint_request import PatchedEndpointRequest as PatchedEndpointRequest +from authentik_client.models.patched_endpoint_stage_request import PatchedEndpointStageRequest as PatchedEndpointStageRequest +from authentik_client.models.patched_enrollment_token_request import PatchedEnrollmentTokenRequest as PatchedEnrollmentTokenRequest +from authentik_client.models.patched_event_matcher_policy_request import PatchedEventMatcherPolicyRequest as PatchedEventMatcherPolicyRequest +from authentik_client.models.patched_event_request import PatchedEventRequest as PatchedEventRequest +from authentik_client.models.patched_expression_policy_request import PatchedExpressionPolicyRequest as PatchedExpressionPolicyRequest +from authentik_client.models.patched_fleet_connector_request import PatchedFleetConnectorRequest as PatchedFleetConnectorRequest +from authentik_client.models.patched_flow_request import PatchedFlowRequest as PatchedFlowRequest +from authentik_client.models.patched_flow_stage_binding_request import PatchedFlowStageBindingRequest as PatchedFlowStageBindingRequest +from authentik_client.models.patched_geo_ip_policy_request import PatchedGeoIPPolicyRequest as PatchedGeoIPPolicyRequest +from authentik_client.models.patched_google_chrome_connector_request import PatchedGoogleChromeConnectorRequest as PatchedGoogleChromeConnectorRequest +from authentik_client.models.patched_google_endpoint_device_request import PatchedGoogleEndpointDeviceRequest as PatchedGoogleEndpointDeviceRequest +from authentik_client.models.patched_google_workspace_provider_mapping_request import PatchedGoogleWorkspaceProviderMappingRequest as PatchedGoogleWorkspaceProviderMappingRequest +from authentik_client.models.patched_google_workspace_provider_request import PatchedGoogleWorkspaceProviderRequest as PatchedGoogleWorkspaceProviderRequest +from authentik_client.models.patched_group_kerberos_source_connection_request import PatchedGroupKerberosSourceConnectionRequest as PatchedGroupKerberosSourceConnectionRequest +from authentik_client.models.patched_group_ldap_source_connection_request import PatchedGroupLDAPSourceConnectionRequest as PatchedGroupLDAPSourceConnectionRequest +from authentik_client.models.patched_group_o_auth_source_connection_request import PatchedGroupOAuthSourceConnectionRequest as PatchedGroupOAuthSourceConnectionRequest +from authentik_client.models.patched_group_plex_source_connection_request import PatchedGroupPlexSourceConnectionRequest as PatchedGroupPlexSourceConnectionRequest +from authentik_client.models.patched_group_request import PatchedGroupRequest as PatchedGroupRequest +from authentik_client.models.patched_group_saml_source_connection_request import PatchedGroupSAMLSourceConnectionRequest as PatchedGroupSAMLSourceConnectionRequest +from authentik_client.models.patched_group_source_connection_request import PatchedGroupSourceConnectionRequest as PatchedGroupSourceConnectionRequest +from authentik_client.models.patched_group_telegram_source_connection_request import PatchedGroupTelegramSourceConnectionRequest as PatchedGroupTelegramSourceConnectionRequest +from authentik_client.models.patched_identification_stage_request import PatchedIdentificationStageRequest as PatchedIdentificationStageRequest +from authentik_client.models.patched_initial_permissions_request import PatchedInitialPermissionsRequest as PatchedInitialPermissionsRequest +from authentik_client.models.patched_invitation_request import PatchedInvitationRequest as PatchedInvitationRequest +from authentik_client.models.patched_invitation_stage_request import PatchedInvitationStageRequest as PatchedInvitationStageRequest +from authentik_client.models.patched_kerberos_source_property_mapping_request import PatchedKerberosSourcePropertyMappingRequest as PatchedKerberosSourcePropertyMappingRequest +from authentik_client.models.patched_kerberos_source_request import PatchedKerberosSourceRequest as PatchedKerberosSourceRequest +from authentik_client.models.patched_kubernetes_service_connection_request import PatchedKubernetesServiceConnectionRequest as PatchedKubernetesServiceConnectionRequest +from authentik_client.models.patched_ldap_provider_request import PatchedLDAPProviderRequest as PatchedLDAPProviderRequest +from authentik_client.models.patched_ldap_source_property_mapping_request import PatchedLDAPSourcePropertyMappingRequest as PatchedLDAPSourcePropertyMappingRequest +from authentik_client.models.patched_ldap_source_request import PatchedLDAPSourceRequest as PatchedLDAPSourceRequest +from authentik_client.models.patched_license_request import PatchedLicenseRequest as PatchedLicenseRequest +from authentik_client.models.patched_lifecycle_rule_request import PatchedLifecycleRuleRequest as PatchedLifecycleRuleRequest +from authentik_client.models.patched_microsoft_entra_provider_mapping_request import PatchedMicrosoftEntraProviderMappingRequest as PatchedMicrosoftEntraProviderMappingRequest +from authentik_client.models.patched_microsoft_entra_provider_request import PatchedMicrosoftEntraProviderRequest as PatchedMicrosoftEntraProviderRequest +from authentik_client.models.patched_mutual_tls_stage_request import PatchedMutualTLSStageRequest as PatchedMutualTLSStageRequest +from authentik_client.models.patched_notification_request import PatchedNotificationRequest as PatchedNotificationRequest +from authentik_client.models.patched_notification_rule_request import PatchedNotificationRuleRequest as PatchedNotificationRuleRequest +from authentik_client.models.patched_notification_transport_request import PatchedNotificationTransportRequest as PatchedNotificationTransportRequest +from authentik_client.models.patched_notification_webhook_mapping_request import PatchedNotificationWebhookMappingRequest as PatchedNotificationWebhookMappingRequest +from authentik_client.models.patched_o_auth2_provider_request import PatchedOAuth2ProviderRequest as PatchedOAuth2ProviderRequest +from authentik_client.models.patched_o_auth_source_property_mapping_request import PatchedOAuthSourcePropertyMappingRequest as PatchedOAuthSourcePropertyMappingRequest +from authentik_client.models.patched_o_auth_source_request import PatchedOAuthSourceRequest as PatchedOAuthSourceRequest +from authentik_client.models.patched_outpost_request import PatchedOutpostRequest as PatchedOutpostRequest +from authentik_client.models.patched_password_expiry_policy_request import PatchedPasswordExpiryPolicyRequest as PatchedPasswordExpiryPolicyRequest +from authentik_client.models.patched_password_policy_request import PatchedPasswordPolicyRequest as PatchedPasswordPolicyRequest +from authentik_client.models.patched_password_stage_request import PatchedPasswordStageRequest as PatchedPasswordStageRequest +from authentik_client.models.patched_permission_assign_request import PatchedPermissionAssignRequest as PatchedPermissionAssignRequest +from authentik_client.models.patched_plex_source_property_mapping_request import PatchedPlexSourcePropertyMappingRequest as PatchedPlexSourcePropertyMappingRequest +from authentik_client.models.patched_plex_source_request import PatchedPlexSourceRequest as PatchedPlexSourceRequest +from authentik_client.models.patched_policy_binding_request import PatchedPolicyBindingRequest as PatchedPolicyBindingRequest +from authentik_client.models.patched_prompt_request import PatchedPromptRequest as PatchedPromptRequest +from authentik_client.models.patched_prompt_stage_request import PatchedPromptStageRequest as PatchedPromptStageRequest +from authentik_client.models.patched_proxy_provider_request import PatchedProxyProviderRequest as PatchedProxyProviderRequest +from authentik_client.models.patched_rac_property_mapping_request import PatchedRACPropertyMappingRequest as PatchedRACPropertyMappingRequest +from authentik_client.models.patched_rac_provider_request import PatchedRACProviderRequest as PatchedRACProviderRequest +from authentik_client.models.patched_radius_provider_property_mapping_request import PatchedRadiusProviderPropertyMappingRequest as PatchedRadiusProviderPropertyMappingRequest +from authentik_client.models.patched_radius_provider_request import PatchedRadiusProviderRequest as PatchedRadiusProviderRequest +from authentik_client.models.patched_redirect_stage_request import PatchedRedirectStageRequest as PatchedRedirectStageRequest +from authentik_client.models.patched_reputation_policy_request import PatchedReputationPolicyRequest as PatchedReputationPolicyRequest +from authentik_client.models.patched_role_request import PatchedRoleRequest as PatchedRoleRequest +from authentik_client.models.patched_saml_property_mapping_request import PatchedSAMLPropertyMappingRequest as PatchedSAMLPropertyMappingRequest +from authentik_client.models.patched_saml_provider_request import PatchedSAMLProviderRequest as PatchedSAMLProviderRequest +from authentik_client.models.patched_saml_source_property_mapping_request import PatchedSAMLSourcePropertyMappingRequest as PatchedSAMLSourcePropertyMappingRequest +from authentik_client.models.patched_saml_source_request import PatchedSAMLSourceRequest as PatchedSAMLSourceRequest +from authentik_client.models.patched_scim_mapping_request import PatchedSCIMMappingRequest as PatchedSCIMMappingRequest +from authentik_client.models.patched_scim_provider_request import PatchedSCIMProviderRequest as PatchedSCIMProviderRequest +from authentik_client.models.patched_scim_source_group_request import PatchedSCIMSourceGroupRequest as PatchedSCIMSourceGroupRequest +from authentik_client.models.patched_scim_source_property_mapping_request import PatchedSCIMSourcePropertyMappingRequest as PatchedSCIMSourcePropertyMappingRequest +from authentik_client.models.patched_scim_source_request import PatchedSCIMSourceRequest as PatchedSCIMSourceRequest +from authentik_client.models.patched_scim_source_user_request import PatchedSCIMSourceUserRequest as PatchedSCIMSourceUserRequest +from authentik_client.models.patched_sms_device_request import PatchedSMSDeviceRequest as PatchedSMSDeviceRequest +from authentik_client.models.patched_ssf_provider_request import PatchedSSFProviderRequest as PatchedSSFProviderRequest +from authentik_client.models.patched_schedule_request import PatchedScheduleRequest as PatchedScheduleRequest +from authentik_client.models.patched_scope_mapping_request import PatchedScopeMappingRequest as PatchedScopeMappingRequest +from authentik_client.models.patched_settings_request import PatchedSettingsRequest as PatchedSettingsRequest +from authentik_client.models.patched_settings_request_flags import PatchedSettingsRequestFlags as PatchedSettingsRequestFlags +from authentik_client.models.patched_source_stage_request import PatchedSourceStageRequest as PatchedSourceStageRequest +from authentik_client.models.patched_static_device_request import PatchedStaticDeviceRequest as PatchedStaticDeviceRequest +from authentik_client.models.patched_totp_device_request import PatchedTOTPDeviceRequest as PatchedTOTPDeviceRequest +from authentik_client.models.patched_telegram_source_property_mapping_request import PatchedTelegramSourcePropertyMappingRequest as PatchedTelegramSourcePropertyMappingRequest +from authentik_client.models.patched_telegram_source_request import PatchedTelegramSourceRequest as PatchedTelegramSourceRequest +from authentik_client.models.patched_tenant_request import PatchedTenantRequest as PatchedTenantRequest +from authentik_client.models.patched_token_request import PatchedTokenRequest as PatchedTokenRequest +from authentik_client.models.patched_unique_password_policy_request import PatchedUniquePasswordPolicyRequest as PatchedUniquePasswordPolicyRequest +from authentik_client.models.patched_user_delete_stage_request import PatchedUserDeleteStageRequest as PatchedUserDeleteStageRequest +from authentik_client.models.patched_user_kerberos_source_connection_request import PatchedUserKerberosSourceConnectionRequest as PatchedUserKerberosSourceConnectionRequest +from authentik_client.models.patched_user_ldap_source_connection_request import PatchedUserLDAPSourceConnectionRequest as PatchedUserLDAPSourceConnectionRequest +from authentik_client.models.patched_user_login_stage_request import PatchedUserLoginStageRequest as PatchedUserLoginStageRequest +from authentik_client.models.patched_user_logout_stage_request import PatchedUserLogoutStageRequest as PatchedUserLogoutStageRequest +from authentik_client.models.patched_user_o_auth_source_connection_request import PatchedUserOAuthSourceConnectionRequest as PatchedUserOAuthSourceConnectionRequest +from authentik_client.models.patched_user_plex_source_connection_request import PatchedUserPlexSourceConnectionRequest as PatchedUserPlexSourceConnectionRequest +from authentik_client.models.patched_user_request import PatchedUserRequest as PatchedUserRequest +from authentik_client.models.patched_user_saml_source_connection_request import PatchedUserSAMLSourceConnectionRequest as PatchedUserSAMLSourceConnectionRequest +from authentik_client.models.patched_user_source_connection_request import PatchedUserSourceConnectionRequest as PatchedUserSourceConnectionRequest +from authentik_client.models.patched_user_telegram_source_connection_request import PatchedUserTelegramSourceConnectionRequest as PatchedUserTelegramSourceConnectionRequest +from authentik_client.models.patched_user_write_stage_request import PatchedUserWriteStageRequest as PatchedUserWriteStageRequest +from authentik_client.models.patched_ws_federation_provider_request import PatchedWSFederationProviderRequest as PatchedWSFederationProviderRequest +from authentik_client.models.patched_web_authn_device_request import PatchedWebAuthnDeviceRequest as PatchedWebAuthnDeviceRequest +from authentik_client.models.permission import Permission as Permission +from authentik_client.models.permission_assign_request import PermissionAssignRequest as PermissionAssignRequest +from authentik_client.models.permission_assign_result import PermissionAssignResult as PermissionAssignResult +from authentik_client.models.plex_authentication_challenge import PlexAuthenticationChallenge as PlexAuthenticationChallenge +from authentik_client.models.plex_authentication_challenge_response_request import PlexAuthenticationChallengeResponseRequest as PlexAuthenticationChallengeResponseRequest +from authentik_client.models.plex_source import PlexSource as PlexSource +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping as PlexSourcePropertyMapping +from authentik_client.models.plex_source_property_mapping_request import PlexSourcePropertyMappingRequest as PlexSourcePropertyMappingRequest +from authentik_client.models.plex_source_request import PlexSourceRequest as PlexSourceRequest +from authentik_client.models.plex_token_redeem_request import PlexTokenRedeemRequest as PlexTokenRedeemRequest +from authentik_client.models.policy import Policy as Policy +from authentik_client.models.policy_binding import PolicyBinding as PolicyBinding +from authentik_client.models.policy_binding_request import PolicyBindingRequest as PolicyBindingRequest +from authentik_client.models.policy_engine_mode import PolicyEngineMode as PolicyEngineMode +from authentik_client.models.policy_test_request import PolicyTestRequest as PolicyTestRequest +from authentik_client.models.policy_test_result import PolicyTestResult as PolicyTestResult +from authentik_client.models.process import Process as Process +from authentik_client.models.process_request import ProcessRequest as ProcessRequest +from authentik_client.models.prompt import Prompt as Prompt +from authentik_client.models.prompt_challenge import PromptChallenge as PromptChallenge +from authentik_client.models.prompt_challenge_response_request import PromptChallengeResponseRequest as PromptChallengeResponseRequest +from authentik_client.models.prompt_choice import PromptChoice as PromptChoice +from authentik_client.models.prompt_request import PromptRequest as PromptRequest +from authentik_client.models.prompt_stage import PromptStage as PromptStage +from authentik_client.models.prompt_stage_request import PromptStageRequest as PromptStageRequest +from authentik_client.models.prompt_type_enum import PromptTypeEnum as PromptTypeEnum +from authentik_client.models.property_mapping import PropertyMapping as PropertyMapping +from authentik_client.models.property_mapping_preview import PropertyMappingPreview as PropertyMappingPreview +from authentik_client.models.property_mapping_test_request import PropertyMappingTestRequest as PropertyMappingTestRequest +from authentik_client.models.property_mapping_test_result import PropertyMappingTestResult as PropertyMappingTestResult +from authentik_client.models.protocol_enum import ProtocolEnum as ProtocolEnum +from authentik_client.models.provider import Provider as Provider +from authentik_client.models.provider_enum import ProviderEnum as ProviderEnum +from authentik_client.models.provider_model_enum import ProviderModelEnum as ProviderModelEnum +from authentik_client.models.provider_type_enum import ProviderTypeEnum as ProviderTypeEnum +from authentik_client.models.proxy_mode import ProxyMode as ProxyMode +from authentik_client.models.proxy_outpost_config import ProxyOutpostConfig as ProxyOutpostConfig +from authentik_client.models.proxy_provider import ProxyProvider as ProxyProvider +from authentik_client.models.proxy_provider_request import ProxyProviderRequest as ProxyProviderRequest +from authentik_client.models.rac_property_mapping import RACPropertyMapping as RACPropertyMapping +from authentik_client.models.rac_property_mapping_request import RACPropertyMappingRequest as RACPropertyMappingRequest +from authentik_client.models.rac_provider import RACProvider as RACProvider +from authentik_client.models.rac_provider_request import RACProviderRequest as RACProviderRequest +from authentik_client.models.radius_check_access import RadiusCheckAccess as RadiusCheckAccess +from authentik_client.models.radius_outpost_config import RadiusOutpostConfig as RadiusOutpostConfig +from authentik_client.models.radius_provider import RadiusProvider as RadiusProvider +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping as RadiusProviderPropertyMapping +from authentik_client.models.radius_provider_property_mapping_request import RadiusProviderPropertyMappingRequest as RadiusProviderPropertyMappingRequest +from authentik_client.models.radius_provider_request import RadiusProviderRequest as RadiusProviderRequest +from authentik_client.models.redirect_challenge import RedirectChallenge as RedirectChallenge +from authentik_client.models.redirect_challenge_response_request import RedirectChallengeResponseRequest as RedirectChallengeResponseRequest +from authentik_client.models.redirect_stage import RedirectStage as RedirectStage +from authentik_client.models.redirect_stage_mode_enum import RedirectStageModeEnum as RedirectStageModeEnum +from authentik_client.models.redirect_stage_request import RedirectStageRequest as RedirectStageRequest +from authentik_client.models.redirect_uri import RedirectURI as RedirectURI +from authentik_client.models.redirect_uri_request import RedirectURIRequest as RedirectURIRequest +from authentik_client.models.redirect_uri_type_enum import RedirectURITypeEnum as RedirectURITypeEnum +from authentik_client.models.related_group import RelatedGroup as RelatedGroup +from authentik_client.models.related_rule import RelatedRule as RelatedRule +from authentik_client.models.reputation import Reputation as Reputation +from authentik_client.models.reputation_policy import ReputationPolicy as ReputationPolicy +from authentik_client.models.reputation_policy_request import ReputationPolicyRequest as ReputationPolicyRequest +from authentik_client.models.review import Review as Review +from authentik_client.models.review_request import ReviewRequest as ReviewRequest +from authentik_client.models.reviewer_group import ReviewerGroup as ReviewerGroup +from authentik_client.models.reviewer_user import ReviewerUser as ReviewerUser +from authentik_client.models.role import Role as Role +from authentik_client.models.role_assigned_object_permission import RoleAssignedObjectPermission as RoleAssignedObjectPermission +from authentik_client.models.role_model_permission import RoleModelPermission as RoleModelPermission +from authentik_client.models.role_object_permission import RoleObjectPermission as RoleObjectPermission +from authentik_client.models.role_request import RoleRequest as RoleRequest +from authentik_client.models.saml_bindings_enum import SAMLBindingsEnum as SAMLBindingsEnum +from authentik_client.models.saml_logout_methods import SAMLLogoutMethods as SAMLLogoutMethods +from authentik_client.models.saml_metadata import SAMLMetadata as SAMLMetadata +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum as SAMLNameIDPolicyEnum +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping as SAMLPropertyMapping +from authentik_client.models.saml_property_mapping_request import SAMLPropertyMappingRequest as SAMLPropertyMappingRequest +from authentik_client.models.saml_provider import SAMLProvider as SAMLProvider +from authentik_client.models.saml_provider_request import SAMLProviderRequest as SAMLProviderRequest +from authentik_client.models.saml_source import SAMLSource as SAMLSource +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping as SAMLSourcePropertyMapping +from authentik_client.models.saml_source_property_mapping_request import SAMLSourcePropertyMappingRequest as SAMLSourcePropertyMappingRequest +from authentik_client.models.saml_source_request import SAMLSourceRequest as SAMLSourceRequest +from authentik_client.models.scim_authentication_mode_enum import SCIMAuthenticationModeEnum as SCIMAuthenticationModeEnum +from authentik_client.models.scim_mapping import SCIMMapping as SCIMMapping +from authentik_client.models.scim_mapping_request import SCIMMappingRequest as SCIMMappingRequest +from authentik_client.models.scim_provider import SCIMProvider as SCIMProvider +from authentik_client.models.scim_provider_group import SCIMProviderGroup as SCIMProviderGroup +from authentik_client.models.scim_provider_group_request import SCIMProviderGroupRequest as SCIMProviderGroupRequest +from authentik_client.models.scim_provider_request import SCIMProviderRequest as SCIMProviderRequest +from authentik_client.models.scim_provider_user import SCIMProviderUser as SCIMProviderUser +from authentik_client.models.scim_provider_user_request import SCIMProviderUserRequest as SCIMProviderUserRequest +from authentik_client.models.scim_source import SCIMSource as SCIMSource +from authentik_client.models.scim_source_group import SCIMSourceGroup as SCIMSourceGroup +from authentik_client.models.scim_source_group_request import SCIMSourceGroupRequest as SCIMSourceGroupRequest +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping as SCIMSourcePropertyMapping +from authentik_client.models.scim_source_property_mapping_request import SCIMSourcePropertyMappingRequest as SCIMSourcePropertyMappingRequest +from authentik_client.models.scim_source_request import SCIMSourceRequest as SCIMSourceRequest +from authentik_client.models.scim_source_user import SCIMSourceUser as SCIMSourceUser +from authentik_client.models.scim_source_user_request import SCIMSourceUserRequest as SCIMSourceUserRequest +from authentik_client.models.sms_device import SMSDevice as SMSDevice +from authentik_client.models.sms_device_request import SMSDeviceRequest as SMSDeviceRequest +from authentik_client.models.ssf_provider import SSFProvider as SSFProvider +from authentik_client.models.ssf_provider_request import SSFProviderRequest as SSFProviderRequest +from authentik_client.models.ssf_stream import SSFStream as SSFStream +from authentik_client.models.ssf_stream_status_enum import SSFStreamStatusEnum as SSFStreamStatusEnum +from authentik_client.models.schedule import Schedule as Schedule +from authentik_client.models.schedule_request import ScheduleRequest as ScheduleRequest +from authentik_client.models.scope_mapping import ScopeMapping as ScopeMapping +from authentik_client.models.scope_mapping_request import ScopeMappingRequest as ScopeMappingRequest +from authentik_client.models.selectable_stage import SelectableStage as SelectableStage +from authentik_client.models.service_connection import ServiceConnection as ServiceConnection +from authentik_client.models.service_connection_state import ServiceConnectionState as ServiceConnectionState +from authentik_client.models.session_end_challenge import SessionEndChallenge as SessionEndChallenge +from authentik_client.models.session_user import SessionUser as SessionUser +from authentik_client.models.settings import Settings as Settings +from authentik_client.models.settings_request import SettingsRequest as SettingsRequest +from authentik_client.models.severity_enum import SeverityEnum as SeverityEnum +from authentik_client.models.shell_challenge import ShellChallenge as ShellChallenge +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum as SignatureAlgorithmEnum +from authentik_client.models.software import Software as Software +from authentik_client.models.software_request import SoftwareRequest as SoftwareRequest +from authentik_client.models.source import Source as Source +from authentik_client.models.source_stage import SourceStage as SourceStage +from authentik_client.models.source_stage_request import SourceStageRequest as SourceStageRequest +from authentik_client.models.source_type import SourceType as SourceType +from authentik_client.models.stage import Stage as Stage +from authentik_client.models.stage_mode_enum import StageModeEnum as StageModeEnum +from authentik_client.models.stage_prompt import StagePrompt as StagePrompt +from authentik_client.models.static_device import StaticDevice as StaticDevice +from authentik_client.models.static_device_request import StaticDeviceRequest as StaticDeviceRequest +from authentik_client.models.static_device_token import StaticDeviceToken as StaticDeviceToken +from authentik_client.models.sub_mode_enum import SubModeEnum as SubModeEnum +from authentik_client.models.sync_object_model_enum import SyncObjectModelEnum as SyncObjectModelEnum +from authentik_client.models.sync_object_request import SyncObjectRequest as SyncObjectRequest +from authentik_client.models.sync_object_result import SyncObjectResult as SyncObjectResult +from authentik_client.models.sync_outgoing_trigger_mode_enum import SyncOutgoingTriggerModeEnum as SyncOutgoingTriggerModeEnum +from authentik_client.models.sync_status import SyncStatus as SyncStatus +from authentik_client.models.system_info import SystemInfo as SystemInfo +from authentik_client.models.system_info_runtime import SystemInfoRuntime as SystemInfoRuntime +from authentik_client.models.totp_device import TOTPDevice as TOTPDevice +from authentik_client.models.totp_device_request import TOTPDeviceRequest as TOTPDeviceRequest +from authentik_client.models.task import Task as Task +from authentik_client.models.task_aggregated_status_enum import TaskAggregatedStatusEnum as TaskAggregatedStatusEnum +from authentik_client.models.task_status_enum import TaskStatusEnum as TaskStatusEnum +from authentik_client.models.telegram_auth_request import TelegramAuthRequest as TelegramAuthRequest +from authentik_client.models.telegram_challenge_response_request import TelegramChallengeResponseRequest as TelegramChallengeResponseRequest +from authentik_client.models.telegram_login_challenge import TelegramLoginChallenge as TelegramLoginChallenge +from authentik_client.models.telegram_source import TelegramSource as TelegramSource +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping as TelegramSourcePropertyMapping +from authentik_client.models.telegram_source_property_mapping_request import TelegramSourcePropertyMappingRequest as TelegramSourcePropertyMappingRequest +from authentik_client.models.telegram_source_request import TelegramSourceRequest as TelegramSourceRequest +from authentik_client.models.tenant import Tenant as Tenant +from authentik_client.models.tenant_admin_group_request_request import TenantAdminGroupRequestRequest as TenantAdminGroupRequestRequest +from authentik_client.models.tenant_recovery_key_request_request import TenantRecoveryKeyRequestRequest as TenantRecoveryKeyRequestRequest +from authentik_client.models.tenant_recovery_key_response import TenantRecoveryKeyResponse as TenantRecoveryKeyResponse +from authentik_client.models.tenant_request import TenantRequest as TenantRequest +from authentik_client.models.themed_urls import ThemedUrls as ThemedUrls +from authentik_client.models.token import Token as Token +from authentik_client.models.token_model import TokenModel as TokenModel +from authentik_client.models.token_request import TokenRequest as TokenRequest +from authentik_client.models.token_set_key_request import TokenSetKeyRequest as TokenSetKeyRequest +from authentik_client.models.token_view import TokenView as TokenView +from authentik_client.models.transaction_application_request import TransactionApplicationRequest as TransactionApplicationRequest +from authentik_client.models.transaction_application_response import TransactionApplicationResponse as TransactionApplicationResponse +from authentik_client.models.transaction_policy_binding_request import TransactionPolicyBindingRequest as TransactionPolicyBindingRequest +from authentik_client.models.transport_mode_enum import TransportModeEnum as TransportModeEnum +from authentik_client.models.type_create import TypeCreate as TypeCreate +from authentik_client.models.ui_theme_enum import UiThemeEnum as UiThemeEnum +from authentik_client.models.unique_password_policy import UniquePasswordPolicy as UniquePasswordPolicy +from authentik_client.models.unique_password_policy_request import UniquePasswordPolicyRequest as UniquePasswordPolicyRequest +from authentik_client.models.usage_enum import UsageEnum as UsageEnum +from authentik_client.models.used_by import UsedBy as UsedBy +from authentik_client.models.used_by_action_enum import UsedByActionEnum as UsedByActionEnum +from authentik_client.models.user import User as User +from authentik_client.models.user_account_lockdown_request import UserAccountLockdownRequest as UserAccountLockdownRequest +from authentik_client.models.user_account_request import UserAccountRequest as UserAccountRequest +from authentik_client.models.user_account_serializer_for_role_request import UserAccountSerializerForRoleRequest as UserAccountSerializerForRoleRequest +from authentik_client.models.user_attribute_enum import UserAttributeEnum as UserAttributeEnum +from authentik_client.models.user_consent import UserConsent as UserConsent +from authentik_client.models.user_creation_mode_enum import UserCreationModeEnum as UserCreationModeEnum +from authentik_client.models.user_delete_stage import UserDeleteStage as UserDeleteStage +from authentik_client.models.user_delete_stage_request import UserDeleteStageRequest as UserDeleteStageRequest +from authentik_client.models.user_fields_enum import UserFieldsEnum as UserFieldsEnum +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection as UserKerberosSourceConnection +from authentik_client.models.user_kerberos_source_connection_request import UserKerberosSourceConnectionRequest as UserKerberosSourceConnectionRequest +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection as UserLDAPSourceConnection +from authentik_client.models.user_ldap_source_connection_request import UserLDAPSourceConnectionRequest as UserLDAPSourceConnectionRequest +from authentik_client.models.user_login_challenge import UserLoginChallenge as UserLoginChallenge +from authentik_client.models.user_login_challenge_response_request import UserLoginChallengeResponseRequest as UserLoginChallengeResponseRequest +from authentik_client.models.user_login_stage import UserLoginStage as UserLoginStage +from authentik_client.models.user_login_stage_request import UserLoginStageRequest as UserLoginStageRequest +from authentik_client.models.user_logout_stage import UserLogoutStage as UserLogoutStage +from authentik_client.models.user_logout_stage_request import UserLogoutStageRequest as UserLogoutStageRequest +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum as UserMatchingModeEnum +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection as UserOAuthSourceConnection +from authentik_client.models.user_o_auth_source_connection_request import UserOAuthSourceConnectionRequest as UserOAuthSourceConnectionRequest +from authentik_client.models.user_password_hash_set_request import UserPasswordHashSetRequest as UserPasswordHashSetRequest +from authentik_client.models.user_password_set_request import UserPasswordSetRequest as UserPasswordSetRequest +from authentik_client.models.user_path import UserPath as UserPath +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection as UserPlexSourceConnection +from authentik_client.models.user_plex_source_connection_request import UserPlexSourceConnectionRequest as UserPlexSourceConnectionRequest +from authentik_client.models.user_recovery_email_request import UserRecoveryEmailRequest as UserRecoveryEmailRequest +from authentik_client.models.user_recovery_link_request import UserRecoveryLinkRequest as UserRecoveryLinkRequest +from authentik_client.models.user_request import UserRequest as UserRequest +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection as UserSAMLSourceConnection +from authentik_client.models.user_saml_source_connection_request import UserSAMLSourceConnectionRequest as UserSAMLSourceConnectionRequest +from authentik_client.models.user_self import UserSelf as UserSelf +from authentik_client.models.user_self_groups import UserSelfGroups as UserSelfGroups +from authentik_client.models.user_self_roles import UserSelfRoles as UserSelfRoles +from authentik_client.models.user_service_account_request import UserServiceAccountRequest as UserServiceAccountRequest +from authentik_client.models.user_service_account_response import UserServiceAccountResponse as UserServiceAccountResponse +from authentik_client.models.user_setting import UserSetting as UserSetting +from authentik_client.models.user_source_connection import UserSourceConnection as UserSourceConnection +from authentik_client.models.user_source_connection_request import UserSourceConnectionRequest as UserSourceConnectionRequest +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection as UserTelegramSourceConnection +from authentik_client.models.user_telegram_source_connection_request import UserTelegramSourceConnectionRequest as UserTelegramSourceConnectionRequest +from authentik_client.models.user_type_enum import UserTypeEnum as UserTypeEnum +from authentik_client.models.user_verification_enum import UserVerificationEnum as UserVerificationEnum +from authentik_client.models.user_write_stage import UserWriteStage as UserWriteStage +from authentik_client.models.user_write_stage_request import UserWriteStageRequest as UserWriteStageRequest +from authentik_client.models.validation_error import ValidationError as ValidationError +from authentik_client.models.vendor_enum import VendorEnum as VendorEnum +from authentik_client.models.version import Version as Version +from authentik_client.models.version_history import VersionHistory as VersionHistory +from authentik_client.models.ws_federation_provider import WSFederationProvider as WSFederationProvider +from authentik_client.models.ws_federation_provider_request import WSFederationProviderRequest as WSFederationProviderRequest +from authentik_client.models.web_authn_device import WebAuthnDevice as WebAuthnDevice +from authentik_client.models.web_authn_device_request import WebAuthnDeviceRequest as WebAuthnDeviceRequest +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType as WebAuthnDeviceType +from authentik_client.models.web_authn_hint_enum import WebAuthnHintEnum as WebAuthnHintEnum +from authentik_client.models.worker import Worker as Worker + diff --git a/authentik_client/api/__init__.py b/authentik_client/api/__init__.py new file mode 100644 index 000000000..3f63f4abf --- /dev/null +++ b/authentik_client/api/__init__.py @@ -0,0 +1,29 @@ +# flake8: noqa + +# import apis into api package +from authentik_client.api.admin_api import AdminApi +from authentik_client.api.authenticators_api import AuthenticatorsApi +from authentik_client.api.core_api import CoreApi +from authentik_client.api.crypto_api import CryptoApi +from authentik_client.api.endpoints_api import EndpointsApi +from authentik_client.api.enterprise_api import EnterpriseApi +from authentik_client.api.events_api import EventsApi +from authentik_client.api.flows_api import FlowsApi +from authentik_client.api.lifecycle_api import LifecycleApi +from authentik_client.api.managed_api import ManagedApi +from authentik_client.api.oauth2_api import Oauth2Api +from authentik_client.api.outposts_api import OutpostsApi +from authentik_client.api.policies_api import PoliciesApi +from authentik_client.api.propertymappings_api import PropertymappingsApi +from authentik_client.api.providers_api import ProvidersApi +from authentik_client.api.rac_api import RacApi +from authentik_client.api.rbac_api import RbacApi +from authentik_client.api.reports_api import ReportsApi +from authentik_client.api.root_api import RootApi +from authentik_client.api.schema_api import SchemaApi +from authentik_client.api.sources_api import SourcesApi +from authentik_client.api.ssf_api import SsfApi +from authentik_client.api.stages_api import StagesApi +from authentik_client.api.tasks_api import TasksApi +from authentik_client.api.tenants_api import TenantsApi + diff --git a/authentik_client/api/admin_api.py b/authentik_client/api/admin_api.py new file mode 100644 index 000000000..94d2eda72 --- /dev/null +++ b/authentik_client/api/admin_api.py @@ -0,0 +1,3871 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictBytes, StrictInt, StrictStr +from typing import Any, List, Optional, Tuple, Union +from typing_extensions import Annotated +from authentik_client.models.app import App +from authentik_client.models.file_list import FileList +from authentik_client.models.patched_settings_request import PatchedSettingsRequest +from authentik_client.models.settings import Settings +from authentik_client.models.settings_request import SettingsRequest +from authentik_client.models.system_info import SystemInfo +from authentik_client.models.used_by import UsedBy +from authentik_client.models.version import Version +from authentik_client.models.version_history import VersionHistory + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class AdminApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def admin_apps_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[App]: + """admin_apps_list + + Read-only view list all installed apps + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_apps_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[App]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_apps_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[App]]: + """admin_apps_list + + Read-only view list all installed apps + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_apps_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[App]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_apps_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_apps_list + + Read-only view list all installed apps + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_apps_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[App]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_apps_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/admin/apps/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_file_create( + self, + file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], + name: Optional[StrictStr] = None, + usage: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """admin_file_create + + Upload file to storage backend. + + :param file: (required) + :type file: bytes + :param name: + :type name: str + :param usage: + :type usage: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_create_serialize( + file=file, + name=name, + usage=usage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_file_create_with_http_info( + self, + file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], + name: Optional[StrictStr] = None, + usage: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """admin_file_create + + Upload file to storage backend. + + :param file: (required) + :type file: bytes + :param name: + :type name: str + :param usage: + :type usage: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_create_serialize( + file=file, + name=name, + usage=usage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_file_create_without_preload_content( + self, + file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], + name: Optional[StrictStr] = None, + usage: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_file_create + + Upload file to storage backend. + + :param file: (required) + :type file: bytes + :param name: + :type name: str + :param usage: + :type usage: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_create_serialize( + file=file, + name=name, + usage=usage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_file_create_serialize( + self, + file, + name, + usage, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + if file is not None: + _files['file'] = file + if name is not None: + _form_params.append(('name', name)) + if usage is not None: + _form_params.append(('usage', usage)) + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'multipart/form-data' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/admin/file/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_file_destroy( + self, + name: Optional[StrictStr] = None, + usage: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """admin_file_destroy + + Delete file from storage backend. + + :param name: + :type name: str + :param usage: + :type usage: UsageEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_destroy_serialize( + name=name, + usage=usage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_file_destroy_with_http_info( + self, + name: Optional[StrictStr] = None, + usage: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """admin_file_destroy + + Delete file from storage backend. + + :param name: + :type name: str + :param usage: + :type usage: UsageEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_destroy_serialize( + name=name, + usage=usage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_file_destroy_without_preload_content( + self, + name: Optional[StrictStr] = None, + usage: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_file_destroy + + Delete file from storage backend. + + :param name: + :type name: str + :param usage: + :type usage: UsageEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_destroy_serialize( + name=name, + usage=usage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_file_destroy_serialize( + self, + name, + usage, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if usage is not None: + + _query_params.append(('usage', usage.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/admin/file/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_file_list( + self, + manageable_only: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + usage: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[FileList]: + """admin_file_list + + List files from storage backend. + + :param manageable_only: + :type manageable_only: bool + :param search: A search term. + :type search: str + :param usage: + :type usage: UsageEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_list_serialize( + manageable_only=manageable_only, + search=search, + usage=usage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[FileList]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_file_list_with_http_info( + self, + manageable_only: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + usage: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[FileList]]: + """admin_file_list + + List files from storage backend. + + :param manageable_only: + :type manageable_only: bool + :param search: A search term. + :type search: str + :param usage: + :type usage: UsageEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_list_serialize( + manageable_only=manageable_only, + search=search, + usage=usage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[FileList]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_file_list_without_preload_content( + self, + manageable_only: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + usage: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_file_list + + List files from storage backend. + + :param manageable_only: + :type manageable_only: bool + :param search: A search term. + :type search: str + :param usage: + :type usage: UsageEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_list_serialize( + manageable_only=manageable_only, + search=search, + usage=usage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[FileList]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_file_list_serialize( + self, + manageable_only, + search, + usage, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if manageable_only is not None: + + _query_params.append(('manageable_only', manageable_only)) + + if search is not None: + + _query_params.append(('search', search)) + + if usage is not None: + + _query_params.append(('usage', usage.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/admin/file/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_file_used_by_list( + self, + name: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """admin_file_used_by_list + + + :param name: + :type name: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_used_by_list_serialize( + name=name, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_file_used_by_list_with_http_info( + self, + name: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """admin_file_used_by_list + + + :param name: + :type name: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_used_by_list_serialize( + name=name, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_file_used_by_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_file_used_by_list + + + :param name: + :type name: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_file_used_by_list_serialize( + name=name, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_file_used_by_list_serialize( + self, + name, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/admin/file/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_models_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[App]: + """admin_models_list + + Read-only view list all installed models + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_models_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[App]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_models_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[App]]: + """admin_models_list + + Read-only view list all installed models + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_models_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[App]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_models_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_models_list + + Read-only view list all installed models + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_models_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[App]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_models_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/admin/models/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_settings_partial_update( + self, + patched_settings_request: Optional[PatchedSettingsRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Settings: + """admin_settings_partial_update + + Settings view + + :param patched_settings_request: + :type patched_settings_request: PatchedSettingsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_settings_partial_update_serialize( + patched_settings_request=patched_settings_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Settings", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_settings_partial_update_with_http_info( + self, + patched_settings_request: Optional[PatchedSettingsRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Settings]: + """admin_settings_partial_update + + Settings view + + :param patched_settings_request: + :type patched_settings_request: PatchedSettingsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_settings_partial_update_serialize( + patched_settings_request=patched_settings_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Settings", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_settings_partial_update_without_preload_content( + self, + patched_settings_request: Optional[PatchedSettingsRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_settings_partial_update + + Settings view + + :param patched_settings_request: + :type patched_settings_request: PatchedSettingsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_settings_partial_update_serialize( + patched_settings_request=patched_settings_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Settings", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_settings_partial_update_serialize( + self, + patched_settings_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_settings_request is not None: + _body_params = patched_settings_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/admin/settings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_settings_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Settings: + """admin_settings_retrieve + + Settings view + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_settings_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Settings", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_settings_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Settings]: + """admin_settings_retrieve + + Settings view + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_settings_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Settings", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_settings_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_settings_retrieve + + Settings view + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_settings_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Settings", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_settings_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/admin/settings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_settings_update( + self, + settings_request: SettingsRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Settings: + """admin_settings_update + + Settings view + + :param settings_request: (required) + :type settings_request: SettingsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_settings_update_serialize( + settings_request=settings_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Settings", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_settings_update_with_http_info( + self, + settings_request: SettingsRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Settings]: + """admin_settings_update + + Settings view + + :param settings_request: (required) + :type settings_request: SettingsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_settings_update_serialize( + settings_request=settings_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Settings", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_settings_update_without_preload_content( + self, + settings_request: SettingsRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_settings_update + + Settings view + + :param settings_request: (required) + :type settings_request: SettingsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_settings_update_serialize( + settings_request=settings_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Settings", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_settings_update_serialize( + self, + settings_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if settings_request is not None: + _body_params = settings_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/admin/settings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_system_create( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SystemInfo: + """admin_system_create + + Get system information. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_system_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SystemInfo", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_system_create_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SystemInfo]: + """admin_system_create + + Get system information. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_system_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SystemInfo", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_system_create_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_system_create + + Get system information. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_system_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SystemInfo", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_system_create_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/admin/system/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_system_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SystemInfo: + """admin_system_retrieve + + Get system information. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_system_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SystemInfo", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_system_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SystemInfo]: + """admin_system_retrieve + + Get system information. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_system_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SystemInfo", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_system_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_system_retrieve + + Get system information. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_system_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SystemInfo", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_system_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/admin/system/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_version_history_list( + self, + build: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + version: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[VersionHistory]: + """admin_version_history_list + + VersionHistory Viewset + + :param build: + :type build: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param version: + :type version: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_version_history_list_serialize( + build=build, + ordering=ordering, + search=search, + version=version, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[VersionHistory]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_version_history_list_with_http_info( + self, + build: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + version: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[VersionHistory]]: + """admin_version_history_list + + VersionHistory Viewset + + :param build: + :type build: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param version: + :type version: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_version_history_list_serialize( + build=build, + ordering=ordering, + search=search, + version=version, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[VersionHistory]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_version_history_list_without_preload_content( + self, + build: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + version: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_version_history_list + + VersionHistory Viewset + + :param build: + :type build: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param version: + :type version: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_version_history_list_serialize( + build=build, + ordering=ordering, + search=search, + version=version, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[VersionHistory]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_version_history_list_serialize( + self, + build, + ordering, + search, + version, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if build is not None: + + _query_params.append(('build', build)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if search is not None: + + _query_params.append(('search', search)) + + if version is not None: + + _query_params.append(('version', version)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/admin/version/history/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_version_history_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Version history.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> VersionHistory: + """admin_version_history_retrieve + + VersionHistory Viewset + + :param id: A unique integer value identifying this Version history. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_version_history_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "VersionHistory", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_version_history_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Version history.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[VersionHistory]: + """admin_version_history_retrieve + + VersionHistory Viewset + + :param id: A unique integer value identifying this Version history. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_version_history_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "VersionHistory", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_version_history_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Version history.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_version_history_retrieve + + VersionHistory Viewset + + :param id: A unique integer value identifying this Version history. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_version_history_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "VersionHistory", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_version_history_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/admin/version/history/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def admin_version_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Version: + """admin_version_retrieve + + Get running and latest version. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_version_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Version", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def admin_version_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Version]: + """admin_version_retrieve + + Get running and latest version. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_version_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Version", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def admin_version_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """admin_version_retrieve + + Get running and latest version. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._admin_version_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Version", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _admin_version_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/admin/version/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/authenticators_api.py b/authentik_client/api/authenticators_api.py new file mode 100644 index 000000000..97cb9f873 --- /dev/null +++ b/authentik_client/api/authenticators_api.py @@ -0,0 +1,24016 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.device import Device +from authentik_client.models.duo_device import DuoDevice +from authentik_client.models.duo_device_request import DuoDeviceRequest +from authentik_client.models.email_device import EmailDevice +from authentik_client.models.email_device_request import EmailDeviceRequest +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice +from authentik_client.models.google_endpoint_device_request import GoogleEndpointDeviceRequest +from authentik_client.models.paginated_duo_device_list import PaginatedDuoDeviceList +from authentik_client.models.paginated_email_device_list import PaginatedEmailDeviceList +from authentik_client.models.paginated_google_endpoint_device_list import PaginatedGoogleEndpointDeviceList +from authentik_client.models.paginated_sms_device_list import PaginatedSMSDeviceList +from authentik_client.models.paginated_static_device_list import PaginatedStaticDeviceList +from authentik_client.models.paginated_totp_device_list import PaginatedTOTPDeviceList +from authentik_client.models.paginated_web_authn_device_list import PaginatedWebAuthnDeviceList +from authentik_client.models.patched_duo_device_request import PatchedDuoDeviceRequest +from authentik_client.models.patched_email_device_request import PatchedEmailDeviceRequest +from authentik_client.models.patched_google_endpoint_device_request import PatchedGoogleEndpointDeviceRequest +from authentik_client.models.patched_sms_device_request import PatchedSMSDeviceRequest +from authentik_client.models.patched_static_device_request import PatchedStaticDeviceRequest +from authentik_client.models.patched_totp_device_request import PatchedTOTPDeviceRequest +from authentik_client.models.patched_web_authn_device_request import PatchedWebAuthnDeviceRequest +from authentik_client.models.sms_device import SMSDevice +from authentik_client.models.sms_device_request import SMSDeviceRequest +from authentik_client.models.static_device import StaticDevice +from authentik_client.models.static_device_request import StaticDeviceRequest +from authentik_client.models.totp_device import TOTPDevice +from authentik_client.models.totp_device_request import TOTPDeviceRequest +from authentik_client.models.used_by import UsedBy +from authentik_client.models.web_authn_device import WebAuthnDevice +from authentik_client.models.web_authn_device_request import WebAuthnDeviceRequest + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class AuthenticatorsApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def authenticators_admin_all_list( + self, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[Device]: + """authenticators_admin_all_list + + Get all devices for current user + + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_all_list_serialize( + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[Device]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_all_list_with_http_info( + self, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[Device]]: + """authenticators_admin_all_list + + Get all devices for current user + + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_all_list_serialize( + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[Device]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_all_list_without_preload_content( + self, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_all_list + + Get all devices for current user + + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_all_list_serialize( + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[Device]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_all_list_serialize( + self, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_duo_create( + self, + duo_device_request: DuoDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DuoDevice: + """authenticators_admin_duo_create + + Viewset for Duo authenticator devices (for admins) + + :param duo_device_request: (required) + :type duo_device_request: DuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_create_serialize( + duo_device_request=duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_duo_create_with_http_info( + self, + duo_device_request: DuoDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DuoDevice]: + """authenticators_admin_duo_create + + Viewset for Duo authenticator devices (for admins) + + :param duo_device_request: (required) + :type duo_device_request: DuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_create_serialize( + duo_device_request=duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_duo_create_without_preload_content( + self, + duo_device_request: DuoDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_duo_create + + Viewset for Duo authenticator devices (for admins) + + :param duo_device_request: (required) + :type duo_device_request: DuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_create_serialize( + duo_device_request=duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_duo_create_serialize( + self, + duo_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if duo_device_request is not None: + _body_params = duo_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/authenticators/admin/duo/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_duo_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_admin_duo_destroy + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_duo_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_admin_duo_destroy + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_duo_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_duo_destroy + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_duo_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/admin/duo/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_duo_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDuoDeviceList: + """authenticators_admin_duo_list + + Viewset for Duo authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDuoDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_duo_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDuoDeviceList]: + """authenticators_admin_duo_list + + Viewset for Duo authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDuoDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_duo_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_duo_list + + Viewset for Duo authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDuoDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_duo_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/duo/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_duo_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + patched_duo_device_request: Optional[PatchedDuoDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DuoDevice: + """authenticators_admin_duo_partial_update + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param patched_duo_device_request: + :type patched_duo_device_request: PatchedDuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_partial_update_serialize( + id=id, + patched_duo_device_request=patched_duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_duo_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + patched_duo_device_request: Optional[PatchedDuoDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DuoDevice]: + """authenticators_admin_duo_partial_update + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param patched_duo_device_request: + :type patched_duo_device_request: PatchedDuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_partial_update_serialize( + id=id, + patched_duo_device_request=patched_duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_duo_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + patched_duo_device_request: Optional[PatchedDuoDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_duo_partial_update + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param patched_duo_device_request: + :type patched_duo_device_request: PatchedDuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_partial_update_serialize( + id=id, + patched_duo_device_request=patched_duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_duo_partial_update_serialize( + self, + id, + patched_duo_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_duo_device_request is not None: + _body_params = patched_duo_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/admin/duo/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_duo_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DuoDevice: + """authenticators_admin_duo_retrieve + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_duo_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DuoDevice]: + """authenticators_admin_duo_retrieve + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_duo_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_duo_retrieve + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_duo_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/duo/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_duo_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + duo_device_request: DuoDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DuoDevice: + """authenticators_admin_duo_update + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param duo_device_request: (required) + :type duo_device_request: DuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_update_serialize( + id=id, + duo_device_request=duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_duo_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + duo_device_request: DuoDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DuoDevice]: + """authenticators_admin_duo_update + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param duo_device_request: (required) + :type duo_device_request: DuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_update_serialize( + id=id, + duo_device_request=duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_duo_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + duo_device_request: DuoDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_duo_update + + Viewset for Duo authenticator devices (for admins) + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param duo_device_request: (required) + :type duo_device_request: DuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_duo_update_serialize( + id=id, + duo_device_request=duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_duo_update_serialize( + self, + id, + duo_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if duo_device_request is not None: + _body_params = duo_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/admin/duo/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_email_create( + self, + email_device_request: EmailDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailDevice: + """authenticators_admin_email_create + + Viewset for email authenticator devices (for admins) + + :param email_device_request: (required) + :type email_device_request: EmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_create_serialize( + email_device_request=email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_email_create_with_http_info( + self, + email_device_request: EmailDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailDevice]: + """authenticators_admin_email_create + + Viewset for email authenticator devices (for admins) + + :param email_device_request: (required) + :type email_device_request: EmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_create_serialize( + email_device_request=email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_email_create_without_preload_content( + self, + email_device_request: EmailDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_email_create + + Viewset for email authenticator devices (for admins) + + :param email_device_request: (required) + :type email_device_request: EmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_create_serialize( + email_device_request=email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_email_create_serialize( + self, + email_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if email_device_request is not None: + _body_params = email_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/authenticators/admin/email/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_email_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_admin_email_destroy + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_email_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_admin_email_destroy + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_email_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_email_destroy + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_email_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/admin/email/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_email_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedEmailDeviceList: + """authenticators_admin_email_list + + Viewset for email authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEmailDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_email_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedEmailDeviceList]: + """authenticators_admin_email_list + + Viewset for email authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEmailDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_email_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_email_list + + Viewset for email authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEmailDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_email_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/email/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_email_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + patched_email_device_request: Optional[PatchedEmailDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailDevice: + """authenticators_admin_email_partial_update + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param patched_email_device_request: + :type patched_email_device_request: PatchedEmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_partial_update_serialize( + id=id, + patched_email_device_request=patched_email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_email_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + patched_email_device_request: Optional[PatchedEmailDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailDevice]: + """authenticators_admin_email_partial_update + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param patched_email_device_request: + :type patched_email_device_request: PatchedEmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_partial_update_serialize( + id=id, + patched_email_device_request=patched_email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_email_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + patched_email_device_request: Optional[PatchedEmailDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_email_partial_update + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param patched_email_device_request: + :type patched_email_device_request: PatchedEmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_partial_update_serialize( + id=id, + patched_email_device_request=patched_email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_email_partial_update_serialize( + self, + id, + patched_email_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_email_device_request is not None: + _body_params = patched_email_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/admin/email/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_email_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailDevice: + """authenticators_admin_email_retrieve + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_email_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailDevice]: + """authenticators_admin_email_retrieve + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_email_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_email_retrieve + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_email_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/email/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_email_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + email_device_request: EmailDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailDevice: + """authenticators_admin_email_update + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param email_device_request: (required) + :type email_device_request: EmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_update_serialize( + id=id, + email_device_request=email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_email_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + email_device_request: EmailDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailDevice]: + """authenticators_admin_email_update + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param email_device_request: (required) + :type email_device_request: EmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_update_serialize( + id=id, + email_device_request=email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_email_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + email_device_request: EmailDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_email_update + + Viewset for email authenticator devices (for admins) + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param email_device_request: (required) + :type email_device_request: EmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_email_update_serialize( + id=id, + email_device_request=email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_email_update_serialize( + self, + id, + email_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if email_device_request is not None: + _body_params = email_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/admin/email/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_endpoint_create( + self, + google_endpoint_device_request: GoogleEndpointDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleEndpointDevice: + """authenticators_admin_endpoint_create + + Viewset for Endpoint authenticator devices (for admins) + + :param google_endpoint_device_request: (required) + :type google_endpoint_device_request: GoogleEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_create_serialize( + google_endpoint_device_request=google_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_endpoint_create_with_http_info( + self, + google_endpoint_device_request: GoogleEndpointDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleEndpointDevice]: + """authenticators_admin_endpoint_create + + Viewset for Endpoint authenticator devices (for admins) + + :param google_endpoint_device_request: (required) + :type google_endpoint_device_request: GoogleEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_create_serialize( + google_endpoint_device_request=google_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_endpoint_create_without_preload_content( + self, + google_endpoint_device_request: GoogleEndpointDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_endpoint_create + + Viewset for Endpoint authenticator devices (for admins) + + :param google_endpoint_device_request: (required) + :type google_endpoint_device_request: GoogleEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_create_serialize( + google_endpoint_device_request=google_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_endpoint_create_serialize( + self, + google_endpoint_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_endpoint_device_request is not None: + _body_params = google_endpoint_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/authenticators/admin/endpoint/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_endpoint_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_admin_endpoint_destroy + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_endpoint_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_admin_endpoint_destroy + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_endpoint_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_endpoint_destroy + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_endpoint_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/admin/endpoint/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_endpoint_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGoogleEndpointDeviceList: + """authenticators_admin_endpoint_list + + Viewset for Endpoint authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleEndpointDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_endpoint_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGoogleEndpointDeviceList]: + """authenticators_admin_endpoint_list + + Viewset for Endpoint authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleEndpointDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_endpoint_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_endpoint_list + + Viewset for Endpoint authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleEndpointDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_endpoint_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/endpoint/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_endpoint_partial_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + patched_google_endpoint_device_request: Optional[PatchedGoogleEndpointDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleEndpointDevice: + """authenticators_admin_endpoint_partial_update + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param patched_google_endpoint_device_request: + :type patched_google_endpoint_device_request: PatchedGoogleEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_partial_update_serialize( + uuid=uuid, + patched_google_endpoint_device_request=patched_google_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_endpoint_partial_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + patched_google_endpoint_device_request: Optional[PatchedGoogleEndpointDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleEndpointDevice]: + """authenticators_admin_endpoint_partial_update + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param patched_google_endpoint_device_request: + :type patched_google_endpoint_device_request: PatchedGoogleEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_partial_update_serialize( + uuid=uuid, + patched_google_endpoint_device_request=patched_google_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_endpoint_partial_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + patched_google_endpoint_device_request: Optional[PatchedGoogleEndpointDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_endpoint_partial_update + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param patched_google_endpoint_device_request: + :type patched_google_endpoint_device_request: PatchedGoogleEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_partial_update_serialize( + uuid=uuid, + patched_google_endpoint_device_request=patched_google_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_endpoint_partial_update_serialize( + self, + uuid, + patched_google_endpoint_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_google_endpoint_device_request is not None: + _body_params = patched_google_endpoint_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/admin/endpoint/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_endpoint_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleEndpointDevice: + """authenticators_admin_endpoint_retrieve + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_endpoint_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleEndpointDevice]: + """authenticators_admin_endpoint_retrieve + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_endpoint_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_endpoint_retrieve + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_endpoint_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/endpoint/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_endpoint_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + google_endpoint_device_request: GoogleEndpointDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleEndpointDevice: + """authenticators_admin_endpoint_update + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param google_endpoint_device_request: (required) + :type google_endpoint_device_request: GoogleEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_update_serialize( + uuid=uuid, + google_endpoint_device_request=google_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_endpoint_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + google_endpoint_device_request: GoogleEndpointDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleEndpointDevice]: + """authenticators_admin_endpoint_update + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param google_endpoint_device_request: (required) + :type google_endpoint_device_request: GoogleEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_update_serialize( + uuid=uuid, + google_endpoint_device_request=google_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_endpoint_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + google_endpoint_device_request: GoogleEndpointDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_endpoint_update + + Viewset for Endpoint authenticator devices (for admins) + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param google_endpoint_device_request: (required) + :type google_endpoint_device_request: GoogleEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_endpoint_update_serialize( + uuid=uuid, + google_endpoint_device_request=google_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_endpoint_update_serialize( + self, + uuid, + google_endpoint_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_endpoint_device_request is not None: + _body_params = google_endpoint_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/admin/endpoint/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_sms_create( + self, + sms_device_request: SMSDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SMSDevice: + """authenticators_admin_sms_create + + Viewset for sms authenticator devices (for admins) + + :param sms_device_request: (required) + :type sms_device_request: SMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_create_serialize( + sms_device_request=sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_sms_create_with_http_info( + self, + sms_device_request: SMSDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SMSDevice]: + """authenticators_admin_sms_create + + Viewset for sms authenticator devices (for admins) + + :param sms_device_request: (required) + :type sms_device_request: SMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_create_serialize( + sms_device_request=sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_sms_create_without_preload_content( + self, + sms_device_request: SMSDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_sms_create + + Viewset for sms authenticator devices (for admins) + + :param sms_device_request: (required) + :type sms_device_request: SMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_create_serialize( + sms_device_request=sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_sms_create_serialize( + self, + sms_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if sms_device_request is not None: + _body_params = sms_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/authenticators/admin/sms/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_sms_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_admin_sms_destroy + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_sms_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_admin_sms_destroy + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_sms_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_sms_destroy + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_sms_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/admin/sms/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_sms_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSMSDeviceList: + """authenticators_admin_sms_list + + Viewset for sms authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSMSDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_sms_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSMSDeviceList]: + """authenticators_admin_sms_list + + Viewset for sms authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSMSDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_sms_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_sms_list + + Viewset for sms authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSMSDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_sms_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/sms/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_sms_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + patched_sms_device_request: Optional[PatchedSMSDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SMSDevice: + """authenticators_admin_sms_partial_update + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param patched_sms_device_request: + :type patched_sms_device_request: PatchedSMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_partial_update_serialize( + id=id, + patched_sms_device_request=patched_sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_sms_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + patched_sms_device_request: Optional[PatchedSMSDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SMSDevice]: + """authenticators_admin_sms_partial_update + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param patched_sms_device_request: + :type patched_sms_device_request: PatchedSMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_partial_update_serialize( + id=id, + patched_sms_device_request=patched_sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_sms_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + patched_sms_device_request: Optional[PatchedSMSDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_sms_partial_update + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param patched_sms_device_request: + :type patched_sms_device_request: PatchedSMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_partial_update_serialize( + id=id, + patched_sms_device_request=patched_sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_sms_partial_update_serialize( + self, + id, + patched_sms_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_sms_device_request is not None: + _body_params = patched_sms_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/admin/sms/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_sms_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SMSDevice: + """authenticators_admin_sms_retrieve + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_sms_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SMSDevice]: + """authenticators_admin_sms_retrieve + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_sms_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_sms_retrieve + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_sms_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/sms/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_sms_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + sms_device_request: SMSDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SMSDevice: + """authenticators_admin_sms_update + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param sms_device_request: (required) + :type sms_device_request: SMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_update_serialize( + id=id, + sms_device_request=sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_sms_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + sms_device_request: SMSDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SMSDevice]: + """authenticators_admin_sms_update + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param sms_device_request: (required) + :type sms_device_request: SMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_update_serialize( + id=id, + sms_device_request=sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_sms_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + sms_device_request: SMSDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_sms_update + + Viewset for sms authenticator devices (for admins) + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param sms_device_request: (required) + :type sms_device_request: SMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_sms_update_serialize( + id=id, + sms_device_request=sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_sms_update_serialize( + self, + id, + sms_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if sms_device_request is not None: + _body_params = sms_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/admin/sms/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_static_create( + self, + static_device_request: StaticDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> StaticDevice: + """authenticators_admin_static_create + + Viewset for static authenticator devices (for admins) + + :param static_device_request: (required) + :type static_device_request: StaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_create_serialize( + static_device_request=static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_static_create_with_http_info( + self, + static_device_request: StaticDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[StaticDevice]: + """authenticators_admin_static_create + + Viewset for static authenticator devices (for admins) + + :param static_device_request: (required) + :type static_device_request: StaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_create_serialize( + static_device_request=static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_static_create_without_preload_content( + self, + static_device_request: StaticDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_static_create + + Viewset for static authenticator devices (for admins) + + :param static_device_request: (required) + :type static_device_request: StaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_create_serialize( + static_device_request=static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_static_create_serialize( + self, + static_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if static_device_request is not None: + _body_params = static_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/authenticators/admin/static/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_static_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_admin_static_destroy + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_static_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_admin_static_destroy + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_static_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_static_destroy + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_static_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/admin/static/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_static_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedStaticDeviceList: + """authenticators_admin_static_list + + Viewset for static authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedStaticDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_static_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedStaticDeviceList]: + """authenticators_admin_static_list + + Viewset for static authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedStaticDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_static_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_static_list + + Viewset for static authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedStaticDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_static_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/static/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_static_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + patched_static_device_request: Optional[PatchedStaticDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> StaticDevice: + """authenticators_admin_static_partial_update + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param patched_static_device_request: + :type patched_static_device_request: PatchedStaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_partial_update_serialize( + id=id, + patched_static_device_request=patched_static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_static_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + patched_static_device_request: Optional[PatchedStaticDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[StaticDevice]: + """authenticators_admin_static_partial_update + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param patched_static_device_request: + :type patched_static_device_request: PatchedStaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_partial_update_serialize( + id=id, + patched_static_device_request=patched_static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_static_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + patched_static_device_request: Optional[PatchedStaticDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_static_partial_update + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param patched_static_device_request: + :type patched_static_device_request: PatchedStaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_partial_update_serialize( + id=id, + patched_static_device_request=patched_static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_static_partial_update_serialize( + self, + id, + patched_static_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_static_device_request is not None: + _body_params = patched_static_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/admin/static/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_static_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> StaticDevice: + """authenticators_admin_static_retrieve + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_static_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[StaticDevice]: + """authenticators_admin_static_retrieve + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_static_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_static_retrieve + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_static_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/static/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_static_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + static_device_request: StaticDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> StaticDevice: + """authenticators_admin_static_update + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param static_device_request: (required) + :type static_device_request: StaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_update_serialize( + id=id, + static_device_request=static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_static_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + static_device_request: StaticDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[StaticDevice]: + """authenticators_admin_static_update + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param static_device_request: (required) + :type static_device_request: StaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_update_serialize( + id=id, + static_device_request=static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_static_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + static_device_request: StaticDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_static_update + + Viewset for static authenticator devices (for admins) + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param static_device_request: (required) + :type static_device_request: StaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_static_update_serialize( + id=id, + static_device_request=static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_static_update_serialize( + self, + id, + static_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if static_device_request is not None: + _body_params = static_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/admin/static/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_totp_create( + self, + totp_device_request: TOTPDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TOTPDevice: + """authenticators_admin_totp_create + + Viewset for totp authenticator devices (for admins) + + :param totp_device_request: (required) + :type totp_device_request: TOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_create_serialize( + totp_device_request=totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_totp_create_with_http_info( + self, + totp_device_request: TOTPDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TOTPDevice]: + """authenticators_admin_totp_create + + Viewset for totp authenticator devices (for admins) + + :param totp_device_request: (required) + :type totp_device_request: TOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_create_serialize( + totp_device_request=totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_totp_create_without_preload_content( + self, + totp_device_request: TOTPDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_totp_create + + Viewset for totp authenticator devices (for admins) + + :param totp_device_request: (required) + :type totp_device_request: TOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_create_serialize( + totp_device_request=totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_totp_create_serialize( + self, + totp_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if totp_device_request is not None: + _body_params = totp_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/authenticators/admin/totp/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_totp_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_admin_totp_destroy + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_totp_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_admin_totp_destroy + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_totp_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_totp_destroy + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_totp_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/admin/totp/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_totp_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedTOTPDeviceList: + """authenticators_admin_totp_list + + Viewset for totp authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTOTPDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_totp_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedTOTPDeviceList]: + """authenticators_admin_totp_list + + Viewset for totp authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTOTPDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_totp_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_totp_list + + Viewset for totp authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTOTPDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_totp_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/totp/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_totp_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + patched_totp_device_request: Optional[PatchedTOTPDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TOTPDevice: + """authenticators_admin_totp_partial_update + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param patched_totp_device_request: + :type patched_totp_device_request: PatchedTOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_partial_update_serialize( + id=id, + patched_totp_device_request=patched_totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_totp_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + patched_totp_device_request: Optional[PatchedTOTPDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TOTPDevice]: + """authenticators_admin_totp_partial_update + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param patched_totp_device_request: + :type patched_totp_device_request: PatchedTOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_partial_update_serialize( + id=id, + patched_totp_device_request=patched_totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_totp_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + patched_totp_device_request: Optional[PatchedTOTPDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_totp_partial_update + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param patched_totp_device_request: + :type patched_totp_device_request: PatchedTOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_partial_update_serialize( + id=id, + patched_totp_device_request=patched_totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_totp_partial_update_serialize( + self, + id, + patched_totp_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_totp_device_request is not None: + _body_params = patched_totp_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/admin/totp/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_totp_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TOTPDevice: + """authenticators_admin_totp_retrieve + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_totp_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TOTPDevice]: + """authenticators_admin_totp_retrieve + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_totp_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_totp_retrieve + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_totp_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/totp/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_totp_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + totp_device_request: TOTPDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TOTPDevice: + """authenticators_admin_totp_update + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param totp_device_request: (required) + :type totp_device_request: TOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_update_serialize( + id=id, + totp_device_request=totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_totp_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + totp_device_request: TOTPDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TOTPDevice]: + """authenticators_admin_totp_update + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param totp_device_request: (required) + :type totp_device_request: TOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_update_serialize( + id=id, + totp_device_request=totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_totp_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + totp_device_request: TOTPDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_totp_update + + Viewset for totp authenticator devices (for admins) + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param totp_device_request: (required) + :type totp_device_request: TOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_totp_update_serialize( + id=id, + totp_device_request=totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_totp_update_serialize( + self, + id, + totp_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if totp_device_request is not None: + _body_params = totp_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/admin/totp/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_webauthn_create( + self, + web_authn_device_request: WebAuthnDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WebAuthnDevice: + """authenticators_admin_webauthn_create + + Viewset for WebAuthn authenticator devices (for admins) + + :param web_authn_device_request: (required) + :type web_authn_device_request: WebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_create_serialize( + web_authn_device_request=web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_webauthn_create_with_http_info( + self, + web_authn_device_request: WebAuthnDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WebAuthnDevice]: + """authenticators_admin_webauthn_create + + Viewset for WebAuthn authenticator devices (for admins) + + :param web_authn_device_request: (required) + :type web_authn_device_request: WebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_create_serialize( + web_authn_device_request=web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_webauthn_create_without_preload_content( + self, + web_authn_device_request: WebAuthnDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_webauthn_create + + Viewset for WebAuthn authenticator devices (for admins) + + :param web_authn_device_request: (required) + :type web_authn_device_request: WebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_create_serialize( + web_authn_device_request=web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_webauthn_create_serialize( + self, + web_authn_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if web_authn_device_request is not None: + _body_params = web_authn_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/authenticators/admin/webauthn/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_webauthn_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_admin_webauthn_destroy + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_webauthn_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_admin_webauthn_destroy + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_webauthn_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_webauthn_destroy + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_webauthn_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/admin/webauthn/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_webauthn_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedWebAuthnDeviceList: + """authenticators_admin_webauthn_list + + Viewset for WebAuthn authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWebAuthnDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_webauthn_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedWebAuthnDeviceList]: + """authenticators_admin_webauthn_list + + Viewset for WebAuthn authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWebAuthnDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_webauthn_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_webauthn_list + + Viewset for WebAuthn authenticator devices (for admins) + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWebAuthnDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_webauthn_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/webauthn/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_webauthn_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + patched_web_authn_device_request: Optional[PatchedWebAuthnDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WebAuthnDevice: + """authenticators_admin_webauthn_partial_update + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param patched_web_authn_device_request: + :type patched_web_authn_device_request: PatchedWebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_partial_update_serialize( + id=id, + patched_web_authn_device_request=patched_web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_webauthn_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + patched_web_authn_device_request: Optional[PatchedWebAuthnDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WebAuthnDevice]: + """authenticators_admin_webauthn_partial_update + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param patched_web_authn_device_request: + :type patched_web_authn_device_request: PatchedWebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_partial_update_serialize( + id=id, + patched_web_authn_device_request=patched_web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_webauthn_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + patched_web_authn_device_request: Optional[PatchedWebAuthnDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_webauthn_partial_update + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param patched_web_authn_device_request: + :type patched_web_authn_device_request: PatchedWebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_partial_update_serialize( + id=id, + patched_web_authn_device_request=patched_web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_webauthn_partial_update_serialize( + self, + id, + patched_web_authn_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_web_authn_device_request is not None: + _body_params = patched_web_authn_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/admin/webauthn/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_webauthn_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WebAuthnDevice: + """authenticators_admin_webauthn_retrieve + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_webauthn_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WebAuthnDevice]: + """authenticators_admin_webauthn_retrieve + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_webauthn_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_webauthn_retrieve + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_webauthn_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/admin/webauthn/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_admin_webauthn_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + web_authn_device_request: WebAuthnDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WebAuthnDevice: + """authenticators_admin_webauthn_update + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param web_authn_device_request: (required) + :type web_authn_device_request: WebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_update_serialize( + id=id, + web_authn_device_request=web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_admin_webauthn_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + web_authn_device_request: WebAuthnDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WebAuthnDevice]: + """authenticators_admin_webauthn_update + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param web_authn_device_request: (required) + :type web_authn_device_request: WebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_update_serialize( + id=id, + web_authn_device_request=web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_admin_webauthn_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + web_authn_device_request: WebAuthnDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_admin_webauthn_update + + Viewset for WebAuthn authenticator devices (for admins) + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param web_authn_device_request: (required) + :type web_authn_device_request: WebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_admin_webauthn_update_serialize( + id=id, + web_authn_device_request=web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_admin_webauthn_update_serialize( + self, + id, + web_authn_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if web_authn_device_request is not None: + _body_params = web_authn_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/admin/webauthn/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_all_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[Device]: + """authenticators_all_list + + Get all devices for current user + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_all_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[Device]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_all_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[Device]]: + """authenticators_all_list + + Get all devices for current user + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_all_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[Device]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_all_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_all_list + + Get all devices for current user + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_all_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[Device]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_all_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_duo_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_duo_destroy + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_duo_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_duo_destroy + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_duo_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_duo_destroy + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_duo_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/duo/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_duo_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDuoDeviceList: + """authenticators_duo_list + + Viewset for Duo authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDuoDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_duo_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDuoDeviceList]: + """authenticators_duo_list + + Viewset for Duo authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDuoDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_duo_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_duo_list + + Viewset for Duo authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDuoDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_duo_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/duo/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_duo_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + patched_duo_device_request: Optional[PatchedDuoDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DuoDevice: + """authenticators_duo_partial_update + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param patched_duo_device_request: + :type patched_duo_device_request: PatchedDuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_partial_update_serialize( + id=id, + patched_duo_device_request=patched_duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_duo_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + patched_duo_device_request: Optional[PatchedDuoDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DuoDevice]: + """authenticators_duo_partial_update + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param patched_duo_device_request: + :type patched_duo_device_request: PatchedDuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_partial_update_serialize( + id=id, + patched_duo_device_request=patched_duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_duo_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + patched_duo_device_request: Optional[PatchedDuoDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_duo_partial_update + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param patched_duo_device_request: + :type patched_duo_device_request: PatchedDuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_partial_update_serialize( + id=id, + patched_duo_device_request=patched_duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_duo_partial_update_serialize( + self, + id, + patched_duo_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_duo_device_request is not None: + _body_params = patched_duo_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/duo/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_duo_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DuoDevice: + """authenticators_duo_retrieve + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_duo_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DuoDevice]: + """authenticators_duo_retrieve + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_duo_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_duo_retrieve + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_duo_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/duo/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_duo_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + duo_device_request: DuoDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DuoDevice: + """authenticators_duo_update + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param duo_device_request: (required) + :type duo_device_request: DuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_update_serialize( + id=id, + duo_device_request=duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_duo_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + duo_device_request: DuoDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DuoDevice]: + """authenticators_duo_update + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param duo_device_request: (required) + :type duo_device_request: DuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_update_serialize( + id=id, + duo_device_request=duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_duo_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + duo_device_request: DuoDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_duo_update + + Viewset for Duo authenticator devices + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param duo_device_request: (required) + :type duo_device_request: DuoDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_update_serialize( + id=id, + duo_device_request=duo_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_duo_update_serialize( + self, + id, + duo_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if duo_device_request is not None: + _body_params = duo_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/duo/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_duo_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """authenticators_duo_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_duo_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """authenticators_duo_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_duo_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Duo Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_duo_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Duo Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_duo_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_duo_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/duo/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_email_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_email_destroy + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_email_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_email_destroy + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_email_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_email_destroy + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_email_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/email/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_email_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedEmailDeviceList: + """authenticators_email_list + + Viewset for email authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEmailDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_email_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedEmailDeviceList]: + """authenticators_email_list + + Viewset for email authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEmailDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_email_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_email_list + + Viewset for email authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEmailDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_email_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/email/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_email_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + patched_email_device_request: Optional[PatchedEmailDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailDevice: + """authenticators_email_partial_update + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param patched_email_device_request: + :type patched_email_device_request: PatchedEmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_partial_update_serialize( + id=id, + patched_email_device_request=patched_email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_email_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + patched_email_device_request: Optional[PatchedEmailDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailDevice]: + """authenticators_email_partial_update + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param patched_email_device_request: + :type patched_email_device_request: PatchedEmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_partial_update_serialize( + id=id, + patched_email_device_request=patched_email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_email_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + patched_email_device_request: Optional[PatchedEmailDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_email_partial_update + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param patched_email_device_request: + :type patched_email_device_request: PatchedEmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_partial_update_serialize( + id=id, + patched_email_device_request=patched_email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_email_partial_update_serialize( + self, + id, + patched_email_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_email_device_request is not None: + _body_params = patched_email_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/email/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_email_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailDevice: + """authenticators_email_retrieve + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_email_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailDevice]: + """authenticators_email_retrieve + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_email_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_email_retrieve + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_email_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/email/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_email_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + email_device_request: EmailDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailDevice: + """authenticators_email_update + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param email_device_request: (required) + :type email_device_request: EmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_update_serialize( + id=id, + email_device_request=email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_email_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + email_device_request: EmailDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailDevice]: + """authenticators_email_update + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param email_device_request: (required) + :type email_device_request: EmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_update_serialize( + id=id, + email_device_request=email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_email_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + email_device_request: EmailDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_email_update + + Viewset for email authenticator devices + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param email_device_request: (required) + :type email_device_request: EmailDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_update_serialize( + id=id, + email_device_request=email_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_email_update_serialize( + self, + id, + email_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if email_device_request is not None: + _body_params = email_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/email/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_email_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """authenticators_email_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_email_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """authenticators_email_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_email_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Email Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_email_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Email Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_email_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_email_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/email/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_endpoint_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGoogleEndpointDeviceList: + """authenticators_endpoint_list + + Viewset for Endpoint authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_endpoint_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleEndpointDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_endpoint_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGoogleEndpointDeviceList]: + """authenticators_endpoint_list + + Viewset for Endpoint authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_endpoint_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleEndpointDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_endpoint_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_endpoint_list + + Viewset for Endpoint authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_endpoint_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleEndpointDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_endpoint_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/endpoint/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_endpoint_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleEndpointDevice: + """authenticators_endpoint_retrieve + + Viewset for Endpoint authenticator devices + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_endpoint_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_endpoint_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleEndpointDevice]: + """authenticators_endpoint_retrieve + + Viewset for Endpoint authenticator devices + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_endpoint_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_endpoint_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_endpoint_retrieve + + Viewset for Endpoint authenticator devices + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_endpoint_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleEndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_endpoint_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/endpoint/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_endpoint_used_by_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """authenticators_endpoint_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_endpoint_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_endpoint_used_by_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """authenticators_endpoint_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_endpoint_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_endpoint_used_by_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_endpoint_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Endpoint Device. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_endpoint_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_endpoint_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/endpoint/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_sms_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_sms_destroy + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_sms_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_sms_destroy + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_sms_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_sms_destroy + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_sms_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/sms/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_sms_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSMSDeviceList: + """authenticators_sms_list + + Viewset for sms authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSMSDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_sms_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSMSDeviceList]: + """authenticators_sms_list + + Viewset for sms authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSMSDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_sms_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_sms_list + + Viewset for sms authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSMSDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_sms_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/sms/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_sms_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + patched_sms_device_request: Optional[PatchedSMSDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SMSDevice: + """authenticators_sms_partial_update + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param patched_sms_device_request: + :type patched_sms_device_request: PatchedSMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_partial_update_serialize( + id=id, + patched_sms_device_request=patched_sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_sms_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + patched_sms_device_request: Optional[PatchedSMSDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SMSDevice]: + """authenticators_sms_partial_update + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param patched_sms_device_request: + :type patched_sms_device_request: PatchedSMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_partial_update_serialize( + id=id, + patched_sms_device_request=patched_sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_sms_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + patched_sms_device_request: Optional[PatchedSMSDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_sms_partial_update + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param patched_sms_device_request: + :type patched_sms_device_request: PatchedSMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_partial_update_serialize( + id=id, + patched_sms_device_request=patched_sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_sms_partial_update_serialize( + self, + id, + patched_sms_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_sms_device_request is not None: + _body_params = patched_sms_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/sms/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_sms_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SMSDevice: + """authenticators_sms_retrieve + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_sms_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SMSDevice]: + """authenticators_sms_retrieve + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_sms_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_sms_retrieve + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_sms_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/sms/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_sms_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + sms_device_request: SMSDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SMSDevice: + """authenticators_sms_update + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param sms_device_request: (required) + :type sms_device_request: SMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_update_serialize( + id=id, + sms_device_request=sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_sms_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + sms_device_request: SMSDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SMSDevice]: + """authenticators_sms_update + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param sms_device_request: (required) + :type sms_device_request: SMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_update_serialize( + id=id, + sms_device_request=sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_sms_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + sms_device_request: SMSDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_sms_update + + Viewset for sms authenticator devices + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param sms_device_request: (required) + :type sms_device_request: SMSDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_update_serialize( + id=id, + sms_device_request=sms_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SMSDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_sms_update_serialize( + self, + id, + sms_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if sms_device_request is not None: + _body_params = sms_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/sms/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_sms_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """authenticators_sms_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_sms_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """authenticators_sms_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_sms_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SMS Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_sms_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this SMS Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_sms_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_sms_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/sms/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_static_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_static_destroy + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_static_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_static_destroy + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_static_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_static_destroy + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_static_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/static/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_static_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedStaticDeviceList: + """authenticators_static_list + + Viewset for static authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedStaticDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_static_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedStaticDeviceList]: + """authenticators_static_list + + Viewset for static authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedStaticDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_static_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_static_list + + Viewset for static authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedStaticDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_static_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/static/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_static_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + patched_static_device_request: Optional[PatchedStaticDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> StaticDevice: + """authenticators_static_partial_update + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param patched_static_device_request: + :type patched_static_device_request: PatchedStaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_partial_update_serialize( + id=id, + patched_static_device_request=patched_static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_static_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + patched_static_device_request: Optional[PatchedStaticDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[StaticDevice]: + """authenticators_static_partial_update + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param patched_static_device_request: + :type patched_static_device_request: PatchedStaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_partial_update_serialize( + id=id, + patched_static_device_request=patched_static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_static_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + patched_static_device_request: Optional[PatchedStaticDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_static_partial_update + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param patched_static_device_request: + :type patched_static_device_request: PatchedStaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_partial_update_serialize( + id=id, + patched_static_device_request=patched_static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_static_partial_update_serialize( + self, + id, + patched_static_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_static_device_request is not None: + _body_params = patched_static_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/static/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_static_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> StaticDevice: + """authenticators_static_retrieve + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_static_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[StaticDevice]: + """authenticators_static_retrieve + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_static_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_static_retrieve + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_static_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/static/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_static_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + static_device_request: StaticDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> StaticDevice: + """authenticators_static_update + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param static_device_request: (required) + :type static_device_request: StaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_update_serialize( + id=id, + static_device_request=static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_static_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + static_device_request: StaticDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[StaticDevice]: + """authenticators_static_update + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param static_device_request: (required) + :type static_device_request: StaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_update_serialize( + id=id, + static_device_request=static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_static_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + static_device_request: StaticDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_static_update + + Viewset for static authenticator devices + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param static_device_request: (required) + :type static_device_request: StaticDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_update_serialize( + id=id, + static_device_request=static_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "StaticDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_static_update_serialize( + self, + id, + static_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if static_device_request is not None: + _body_params = static_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/static/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_static_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """authenticators_static_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_static_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """authenticators_static_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_static_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Static Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_static_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Static Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_static_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_static_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/static/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_totp_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_totp_destroy + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_totp_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_totp_destroy + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_totp_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_totp_destroy + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_totp_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/totp/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_totp_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedTOTPDeviceList: + """authenticators_totp_list + + Viewset for totp authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTOTPDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_totp_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedTOTPDeviceList]: + """authenticators_totp_list + + Viewset for totp authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTOTPDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_totp_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_totp_list + + Viewset for totp authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTOTPDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_totp_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/totp/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_totp_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + patched_totp_device_request: Optional[PatchedTOTPDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TOTPDevice: + """authenticators_totp_partial_update + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param patched_totp_device_request: + :type patched_totp_device_request: PatchedTOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_partial_update_serialize( + id=id, + patched_totp_device_request=patched_totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_totp_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + patched_totp_device_request: Optional[PatchedTOTPDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TOTPDevice]: + """authenticators_totp_partial_update + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param patched_totp_device_request: + :type patched_totp_device_request: PatchedTOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_partial_update_serialize( + id=id, + patched_totp_device_request=patched_totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_totp_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + patched_totp_device_request: Optional[PatchedTOTPDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_totp_partial_update + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param patched_totp_device_request: + :type patched_totp_device_request: PatchedTOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_partial_update_serialize( + id=id, + patched_totp_device_request=patched_totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_totp_partial_update_serialize( + self, + id, + patched_totp_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_totp_device_request is not None: + _body_params = patched_totp_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/totp/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_totp_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TOTPDevice: + """authenticators_totp_retrieve + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_totp_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TOTPDevice]: + """authenticators_totp_retrieve + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_totp_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_totp_retrieve + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_totp_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/totp/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_totp_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + totp_device_request: TOTPDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TOTPDevice: + """authenticators_totp_update + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param totp_device_request: (required) + :type totp_device_request: TOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_update_serialize( + id=id, + totp_device_request=totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_totp_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + totp_device_request: TOTPDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TOTPDevice]: + """authenticators_totp_update + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param totp_device_request: (required) + :type totp_device_request: TOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_update_serialize( + id=id, + totp_device_request=totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_totp_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + totp_device_request: TOTPDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_totp_update + + Viewset for totp authenticator devices + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param totp_device_request: (required) + :type totp_device_request: TOTPDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_update_serialize( + id=id, + totp_device_request=totp_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TOTPDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_totp_update_serialize( + self, + id, + totp_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if totp_device_request is not None: + _body_params = totp_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/totp/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_totp_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """authenticators_totp_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_totp_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """authenticators_totp_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_totp_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this TOTP Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_totp_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this TOTP Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_totp_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_totp_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/totp/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_webauthn_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """authenticators_webauthn_destroy + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_webauthn_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """authenticators_webauthn_destroy + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_webauthn_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_webauthn_destroy + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_webauthn_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/authenticators/webauthn/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_webauthn_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedWebAuthnDeviceList: + """authenticators_webauthn_list + + Viewset for WebAuthn authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWebAuthnDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_webauthn_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedWebAuthnDeviceList]: + """authenticators_webauthn_list + + Viewset for WebAuthn authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWebAuthnDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_webauthn_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_webauthn_list + + Viewset for WebAuthn authenticator devices + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWebAuthnDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_webauthn_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/webauthn/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_webauthn_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + patched_web_authn_device_request: Optional[PatchedWebAuthnDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WebAuthnDevice: + """authenticators_webauthn_partial_update + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param patched_web_authn_device_request: + :type patched_web_authn_device_request: PatchedWebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_partial_update_serialize( + id=id, + patched_web_authn_device_request=patched_web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_webauthn_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + patched_web_authn_device_request: Optional[PatchedWebAuthnDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WebAuthnDevice]: + """authenticators_webauthn_partial_update + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param patched_web_authn_device_request: + :type patched_web_authn_device_request: PatchedWebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_partial_update_serialize( + id=id, + patched_web_authn_device_request=patched_web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_webauthn_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + patched_web_authn_device_request: Optional[PatchedWebAuthnDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_webauthn_partial_update + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param patched_web_authn_device_request: + :type patched_web_authn_device_request: PatchedWebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_partial_update_serialize( + id=id, + patched_web_authn_device_request=patched_web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_webauthn_partial_update_serialize( + self, + id, + patched_web_authn_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_web_authn_device_request is not None: + _body_params = patched_web_authn_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/authenticators/webauthn/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_webauthn_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WebAuthnDevice: + """authenticators_webauthn_retrieve + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_webauthn_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WebAuthnDevice]: + """authenticators_webauthn_retrieve + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_webauthn_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_webauthn_retrieve + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_webauthn_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/webauthn/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_webauthn_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + web_authn_device_request: WebAuthnDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WebAuthnDevice: + """authenticators_webauthn_update + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param web_authn_device_request: (required) + :type web_authn_device_request: WebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_update_serialize( + id=id, + web_authn_device_request=web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_webauthn_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + web_authn_device_request: WebAuthnDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WebAuthnDevice]: + """authenticators_webauthn_update + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param web_authn_device_request: (required) + :type web_authn_device_request: WebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_update_serialize( + id=id, + web_authn_device_request=web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_webauthn_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + web_authn_device_request: WebAuthnDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_webauthn_update + + Viewset for WebAuthn authenticator devices + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param web_authn_device_request: (required) + :type web_authn_device_request: WebAuthnDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_update_serialize( + id=id, + web_authn_device_request=web_authn_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_webauthn_update_serialize( + self, + id, + web_authn_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if web_authn_device_request is not None: + _body_params = web_authn_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/authenticators/webauthn/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def authenticators_webauthn_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """authenticators_webauthn_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def authenticators_webauthn_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """authenticators_webauthn_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def authenticators_webauthn_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WebAuthn Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """authenticators_webauthn_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this WebAuthn Device. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._authenticators_webauthn_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _authenticators_webauthn_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/authenticators/webauthn/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/core_api.py b/authentik_client/api/core_api.py new file mode 100644 index 000000000..09930949f --- /dev/null +++ b/authentik_client/api/core_api.py @@ -0,0 +1,21585 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from datetime import datetime +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.application import Application +from authentik_client.models.application_entitlement import ApplicationEntitlement +from authentik_client.models.application_entitlement_request import ApplicationEntitlementRequest +from authentik_client.models.application_request import ApplicationRequest +from authentik_client.models.authenticated_session import AuthenticatedSession +from authentik_client.models.brand import Brand +from authentik_client.models.brand_request import BrandRequest +from authentik_client.models.bulk_delete_session_response import BulkDeleteSessionResponse +from authentik_client.models.current_brand import CurrentBrand +from authentik_client.models.data_export import DataExport +from authentik_client.models.group import Group +from authentik_client.models.group_request import GroupRequest +from authentik_client.models.impersonation_request import ImpersonationRequest +from authentik_client.models.intent_enum import IntentEnum +from authentik_client.models.link import Link +from authentik_client.models.paginated_application_entitlement_list import PaginatedApplicationEntitlementList +from authentik_client.models.paginated_application_list import PaginatedApplicationList +from authentik_client.models.paginated_authenticated_session_list import PaginatedAuthenticatedSessionList +from authentik_client.models.paginated_brand_list import PaginatedBrandList +from authentik_client.models.paginated_group_list import PaginatedGroupList +from authentik_client.models.paginated_token_list import PaginatedTokenList +from authentik_client.models.paginated_user_consent_list import PaginatedUserConsentList +from authentik_client.models.paginated_user_list import PaginatedUserList +from authentik_client.models.patched_application_entitlement_request import PatchedApplicationEntitlementRequest +from authentik_client.models.patched_application_request import PatchedApplicationRequest +from authentik_client.models.patched_brand_request import PatchedBrandRequest +from authentik_client.models.patched_group_request import PatchedGroupRequest +from authentik_client.models.patched_token_request import PatchedTokenRequest +from authentik_client.models.patched_user_request import PatchedUserRequest +from authentik_client.models.policy_test_result import PolicyTestResult +from authentik_client.models.session_user import SessionUser +from authentik_client.models.token import Token +from authentik_client.models.token_request import TokenRequest +from authentik_client.models.token_set_key_request import TokenSetKeyRequest +from authentik_client.models.token_view import TokenView +from authentik_client.models.transaction_application_request import TransactionApplicationRequest +from authentik_client.models.transaction_application_response import TransactionApplicationResponse +from authentik_client.models.used_by import UsedBy +from authentik_client.models.user import User +from authentik_client.models.user_account_lockdown_request import UserAccountLockdownRequest +from authentik_client.models.user_account_request import UserAccountRequest +from authentik_client.models.user_consent import UserConsent +from authentik_client.models.user_password_hash_set_request import UserPasswordHashSetRequest +from authentik_client.models.user_password_set_request import UserPasswordSetRequest +from authentik_client.models.user_path import UserPath +from authentik_client.models.user_recovery_email_request import UserRecoveryEmailRequest +from authentik_client.models.user_recovery_link_request import UserRecoveryLinkRequest +from authentik_client.models.user_request import UserRequest +from authentik_client.models.user_service_account_request import UserServiceAccountRequest +from authentik_client.models.user_service_account_response import UserServiceAccountResponse +from authentik_client.models.user_type_enum import UserTypeEnum + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class CoreApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def core_application_entitlements_create( + self, + application_entitlement_request: ApplicationEntitlementRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApplicationEntitlement: + """core_application_entitlements_create + + ApplicationEntitlement Viewset + + :param application_entitlement_request: (required) + :type application_entitlement_request: ApplicationEntitlementRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_create_serialize( + application_entitlement_request=application_entitlement_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_application_entitlements_create_with_http_info( + self, + application_entitlement_request: ApplicationEntitlementRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ApplicationEntitlement]: + """core_application_entitlements_create + + ApplicationEntitlement Viewset + + :param application_entitlement_request: (required) + :type application_entitlement_request: ApplicationEntitlementRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_create_serialize( + application_entitlement_request=application_entitlement_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_application_entitlements_create_without_preload_content( + self, + application_entitlement_request: ApplicationEntitlementRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_application_entitlements_create + + ApplicationEntitlement Viewset + + :param application_entitlement_request: (required) + :type application_entitlement_request: ApplicationEntitlementRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_create_serialize( + application_entitlement_request=application_entitlement_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_application_entitlements_create_serialize( + self, + application_entitlement_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if application_entitlement_request is not None: + _body_params = application_entitlement_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/application_entitlements/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_application_entitlements_destroy( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_application_entitlements_destroy + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_application_entitlements_destroy_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_application_entitlements_destroy + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_application_entitlements_destroy_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_application_entitlements_destroy + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_application_entitlements_destroy_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/core/application_entitlements/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_application_entitlements_list( + self, + app: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedApplicationEntitlementList: + """core_application_entitlements_list + + ApplicationEntitlement Viewset + + :param app: + :type app: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_list_serialize( + app=app, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedApplicationEntitlementList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_application_entitlements_list_with_http_info( + self, + app: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedApplicationEntitlementList]: + """core_application_entitlements_list + + ApplicationEntitlement Viewset + + :param app: + :type app: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_list_serialize( + app=app, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedApplicationEntitlementList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_application_entitlements_list_without_preload_content( + self, + app: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_application_entitlements_list + + ApplicationEntitlement Viewset + + :param app: + :type app: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_list_serialize( + app=app, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedApplicationEntitlementList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_application_entitlements_list_serialize( + self, + app, + name, + ordering, + page, + page_size, + pbm_uuid, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if app is not None: + + _query_params.append(('app', app)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/application_entitlements/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_application_entitlements_partial_update( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + patched_application_entitlement_request: Optional[PatchedApplicationEntitlementRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApplicationEntitlement: + """core_application_entitlements_partial_update + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param patched_application_entitlement_request: + :type patched_application_entitlement_request: PatchedApplicationEntitlementRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_application_entitlement_request=patched_application_entitlement_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_application_entitlements_partial_update_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + patched_application_entitlement_request: Optional[PatchedApplicationEntitlementRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ApplicationEntitlement]: + """core_application_entitlements_partial_update + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param patched_application_entitlement_request: + :type patched_application_entitlement_request: PatchedApplicationEntitlementRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_application_entitlement_request=patched_application_entitlement_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_application_entitlements_partial_update_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + patched_application_entitlement_request: Optional[PatchedApplicationEntitlementRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_application_entitlements_partial_update + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param patched_application_entitlement_request: + :type patched_application_entitlement_request: PatchedApplicationEntitlementRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_application_entitlement_request=patched_application_entitlement_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_application_entitlements_partial_update_serialize( + self, + pbm_uuid, + patched_application_entitlement_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_application_entitlement_request is not None: + _body_params = patched_application_entitlement_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/core/application_entitlements/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_application_entitlements_retrieve( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApplicationEntitlement: + """core_application_entitlements_retrieve + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_application_entitlements_retrieve_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ApplicationEntitlement]: + """core_application_entitlements_retrieve + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_application_entitlements_retrieve_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_application_entitlements_retrieve + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_application_entitlements_retrieve_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/application_entitlements/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_application_entitlements_update( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + application_entitlement_request: ApplicationEntitlementRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApplicationEntitlement: + """core_application_entitlements_update + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param application_entitlement_request: (required) + :type application_entitlement_request: ApplicationEntitlementRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_update_serialize( + pbm_uuid=pbm_uuid, + application_entitlement_request=application_entitlement_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_application_entitlements_update_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + application_entitlement_request: ApplicationEntitlementRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ApplicationEntitlement]: + """core_application_entitlements_update + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param application_entitlement_request: (required) + :type application_entitlement_request: ApplicationEntitlementRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_update_serialize( + pbm_uuid=pbm_uuid, + application_entitlement_request=application_entitlement_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_application_entitlements_update_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + application_entitlement_request: ApplicationEntitlementRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_application_entitlements_update + + ApplicationEntitlement Viewset + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param application_entitlement_request: (required) + :type application_entitlement_request: ApplicationEntitlementRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_update_serialize( + pbm_uuid=pbm_uuid, + application_entitlement_request=application_entitlement_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ApplicationEntitlement", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_application_entitlements_update_serialize( + self, + pbm_uuid, + application_entitlement_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if application_entitlement_request is not None: + _body_params = application_entitlement_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/core/application_entitlements/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_application_entitlements_used_by_list( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """core_application_entitlements_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_application_entitlements_used_by_list_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """core_application_entitlements_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_application_entitlements_used_by_list_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Application Entitlement.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_application_entitlements_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this Application Entitlement. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_application_entitlements_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_application_entitlements_used_by_list_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/application_entitlements/{pbm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_applications_check_access_retrieve( + self, + slug: StrictStr, + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PolicyTestResult: + """core_applications_check_access_retrieve + + Check access to a single application by slug + + :param slug: (required) + :type slug: str + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_check_access_retrieve_serialize( + slug=slug, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyTestResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_applications_check_access_retrieve_with_http_info( + self, + slug: StrictStr, + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PolicyTestResult]: + """core_applications_check_access_retrieve + + Check access to a single application by slug + + :param slug: (required) + :type slug: str + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_check_access_retrieve_serialize( + slug=slug, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyTestResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_applications_check_access_retrieve_without_preload_content( + self, + slug: StrictStr, + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_applications_check_access_retrieve + + Check access to a single application by slug + + :param slug: (required) + :type slug: str + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_check_access_retrieve_serialize( + slug=slug, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyTestResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_applications_check_access_retrieve_serialize( + self, + slug, + for_user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + if for_user is not None: + + _query_params.append(('for_user', for_user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/applications/{slug}/check_access/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_applications_create( + self, + application_request: ApplicationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Application: + """core_applications_create + + Application Viewset + + :param application_request: (required) + :type application_request: ApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_create_serialize( + application_request=application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_applications_create_with_http_info( + self, + application_request: ApplicationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Application]: + """core_applications_create + + Application Viewset + + :param application_request: (required) + :type application_request: ApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_create_serialize( + application_request=application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_applications_create_without_preload_content( + self, + application_request: ApplicationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_applications_create + + Application Viewset + + :param application_request: (required) + :type application_request: ApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_create_serialize( + application_request=application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_applications_create_serialize( + self, + application_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if application_request is not None: + _body_params = application_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/applications/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_applications_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_applications_destroy + + Application Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_applications_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_applications_destroy + + Application Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_applications_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_applications_destroy + + Application Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_applications_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/core/applications/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_applications_list( + self, + for_user: Optional[StrictInt] = None, + group: Optional[StrictStr] = None, + meta_description: Optional[StrictStr] = None, + meta_launch_url: Optional[StrictStr] = None, + meta_publisher: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + only_with_launch_url: Optional[StrictBool] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + superuser_full_list: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedApplicationList: + """core_applications_list + + Custom list method that checks Policy based access instead of guardian + + :param for_user: + :type for_user: int + :param group: + :type group: str + :param meta_description: + :type meta_description: str + :param meta_launch_url: + :type meta_launch_url: str + :param meta_publisher: + :type meta_publisher: str + :param name: + :type name: str + :param only_with_launch_url: + :type only_with_launch_url: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param superuser_full_list: + :type superuser_full_list: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_list_serialize( + for_user=for_user, + group=group, + meta_description=meta_description, + meta_launch_url=meta_launch_url, + meta_publisher=meta_publisher, + name=name, + only_with_launch_url=only_with_launch_url, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + slug=slug, + superuser_full_list=superuser_full_list, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedApplicationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_applications_list_with_http_info( + self, + for_user: Optional[StrictInt] = None, + group: Optional[StrictStr] = None, + meta_description: Optional[StrictStr] = None, + meta_launch_url: Optional[StrictStr] = None, + meta_publisher: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + only_with_launch_url: Optional[StrictBool] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + superuser_full_list: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedApplicationList]: + """core_applications_list + + Custom list method that checks Policy based access instead of guardian + + :param for_user: + :type for_user: int + :param group: + :type group: str + :param meta_description: + :type meta_description: str + :param meta_launch_url: + :type meta_launch_url: str + :param meta_publisher: + :type meta_publisher: str + :param name: + :type name: str + :param only_with_launch_url: + :type only_with_launch_url: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param superuser_full_list: + :type superuser_full_list: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_list_serialize( + for_user=for_user, + group=group, + meta_description=meta_description, + meta_launch_url=meta_launch_url, + meta_publisher=meta_publisher, + name=name, + only_with_launch_url=only_with_launch_url, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + slug=slug, + superuser_full_list=superuser_full_list, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedApplicationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_applications_list_without_preload_content( + self, + for_user: Optional[StrictInt] = None, + group: Optional[StrictStr] = None, + meta_description: Optional[StrictStr] = None, + meta_launch_url: Optional[StrictStr] = None, + meta_publisher: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + only_with_launch_url: Optional[StrictBool] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + superuser_full_list: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_applications_list + + Custom list method that checks Policy based access instead of guardian + + :param for_user: + :type for_user: int + :param group: + :type group: str + :param meta_description: + :type meta_description: str + :param meta_launch_url: + :type meta_launch_url: str + :param meta_publisher: + :type meta_publisher: str + :param name: + :type name: str + :param only_with_launch_url: + :type only_with_launch_url: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param superuser_full_list: + :type superuser_full_list: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_list_serialize( + for_user=for_user, + group=group, + meta_description=meta_description, + meta_launch_url=meta_launch_url, + meta_publisher=meta_publisher, + name=name, + only_with_launch_url=only_with_launch_url, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + slug=slug, + superuser_full_list=superuser_full_list, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedApplicationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_applications_list_serialize( + self, + for_user, + group, + meta_description, + meta_launch_url, + meta_publisher, + name, + only_with_launch_url, + ordering, + page, + page_size, + search, + slug, + superuser_full_list, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if for_user is not None: + + _query_params.append(('for_user', for_user)) + + if group is not None: + + _query_params.append(('group', group)) + + if meta_description is not None: + + _query_params.append(('meta_description', meta_description)) + + if meta_launch_url is not None: + + _query_params.append(('meta_launch_url', meta_launch_url)) + + if meta_publisher is not None: + + _query_params.append(('meta_publisher', meta_publisher)) + + if name is not None: + + _query_params.append(('name', name)) + + if only_with_launch_url is not None: + + _query_params.append(('only_with_launch_url', only_with_launch_url)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + if superuser_full_list is not None: + + _query_params.append(('superuser_full_list', superuser_full_list)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/applications/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_applications_partial_update( + self, + slug: StrictStr, + patched_application_request: Optional[PatchedApplicationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Application: + """core_applications_partial_update + + Application Viewset + + :param slug: (required) + :type slug: str + :param patched_application_request: + :type patched_application_request: PatchedApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_partial_update_serialize( + slug=slug, + patched_application_request=patched_application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_applications_partial_update_with_http_info( + self, + slug: StrictStr, + patched_application_request: Optional[PatchedApplicationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Application]: + """core_applications_partial_update + + Application Viewset + + :param slug: (required) + :type slug: str + :param patched_application_request: + :type patched_application_request: PatchedApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_partial_update_serialize( + slug=slug, + patched_application_request=patched_application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_applications_partial_update_without_preload_content( + self, + slug: StrictStr, + patched_application_request: Optional[PatchedApplicationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_applications_partial_update + + Application Viewset + + :param slug: (required) + :type slug: str + :param patched_application_request: + :type patched_application_request: PatchedApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_partial_update_serialize( + slug=slug, + patched_application_request=patched_application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_applications_partial_update_serialize( + self, + slug, + patched_application_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_application_request is not None: + _body_params = patched_application_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/core/applications/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_applications_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Application: + """core_applications_retrieve + + Application Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_applications_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Application]: + """core_applications_retrieve + + Application Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_applications_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_applications_retrieve + + Application Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_applications_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/applications/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_applications_update( + self, + slug: StrictStr, + application_request: ApplicationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Application: + """core_applications_update + + Application Viewset + + :param slug: (required) + :type slug: str + :param application_request: (required) + :type application_request: ApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_update_serialize( + slug=slug, + application_request=application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_applications_update_with_http_info( + self, + slug: StrictStr, + application_request: ApplicationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Application]: + """core_applications_update + + Application Viewset + + :param slug: (required) + :type slug: str + :param application_request: (required) + :type application_request: ApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_update_serialize( + slug=slug, + application_request=application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_applications_update_without_preload_content( + self, + slug: StrictStr, + application_request: ApplicationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_applications_update + + Application Viewset + + :param slug: (required) + :type slug: str + :param application_request: (required) + :type application_request: ApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_update_serialize( + slug=slug, + application_request=application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Application", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_applications_update_serialize( + self, + slug, + application_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if application_request is not None: + _body_params = application_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/core/applications/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_applications_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """core_applications_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_applications_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """core_applications_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_applications_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_applications_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_applications_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_applications_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/applications/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_authenticated_sessions_bulk_delete_destroy( + self, + user_pks: Annotated[List[StrictInt], Field(description="List of user IDs to revoke all sessions for")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> BulkDeleteSessionResponse: + """core_authenticated_sessions_bulk_delete_destroy + + Bulk revoke all sessions for multiple users + + :param user_pks: List of user IDs to revoke all sessions for (required) + :type user_pks: List[int] + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_bulk_delete_destroy_serialize( + user_pks=user_pks, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BulkDeleteSessionResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_authenticated_sessions_bulk_delete_destroy_with_http_info( + self, + user_pks: Annotated[List[StrictInt], Field(description="List of user IDs to revoke all sessions for")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[BulkDeleteSessionResponse]: + """core_authenticated_sessions_bulk_delete_destroy + + Bulk revoke all sessions for multiple users + + :param user_pks: List of user IDs to revoke all sessions for (required) + :type user_pks: List[int] + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_bulk_delete_destroy_serialize( + user_pks=user_pks, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BulkDeleteSessionResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_authenticated_sessions_bulk_delete_destroy_without_preload_content( + self, + user_pks: Annotated[List[StrictInt], Field(description="List of user IDs to revoke all sessions for")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_authenticated_sessions_bulk_delete_destroy + + Bulk revoke all sessions for multiple users + + :param user_pks: List of user IDs to revoke all sessions for (required) + :type user_pks: List[int] + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_bulk_delete_destroy_serialize( + user_pks=user_pks, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BulkDeleteSessionResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_authenticated_sessions_bulk_delete_destroy_serialize( + self, + user_pks, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'user_pks': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if user_pks is not None: + + _query_params.append(('user_pks', user_pks)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/core/authenticated_sessions/bulk_delete/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_authenticated_sessions_destroy( + self, + uuid: UUID, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_authenticated_sessions_destroy + + AuthenticatedSession Viewset + + :param uuid: (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_authenticated_sessions_destroy_with_http_info( + self, + uuid: UUID, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_authenticated_sessions_destroy + + AuthenticatedSession Viewset + + :param uuid: (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_authenticated_sessions_destroy_without_preload_content( + self, + uuid: UUID, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_authenticated_sessions_destroy + + AuthenticatedSession Viewset + + :param uuid: (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_authenticated_sessions_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/core/authenticated_sessions/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_authenticated_sessions_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session__last_ip: Optional[StrictStr] = None, + session__last_user_agent: Optional[StrictStr] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAuthenticatedSessionList: + """core_authenticated_sessions_list + + AuthenticatedSession Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param session__last_ip: + :type session__last_ip: str + :param session__last_user_agent: + :type session__last_user_agent: str + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + session__last_ip=session__last_ip, + session__last_user_agent=session__last_user_agent, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatedSessionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_authenticated_sessions_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session__last_ip: Optional[StrictStr] = None, + session__last_user_agent: Optional[StrictStr] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAuthenticatedSessionList]: + """core_authenticated_sessions_list + + AuthenticatedSession Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param session__last_ip: + :type session__last_ip: str + :param session__last_user_agent: + :type session__last_user_agent: str + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + session__last_ip=session__last_ip, + session__last_user_agent=session__last_user_agent, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatedSessionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_authenticated_sessions_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session__last_ip: Optional[StrictStr] = None, + session__last_user_agent: Optional[StrictStr] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_authenticated_sessions_list + + AuthenticatedSession Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param session__last_ip: + :type session__last_ip: str + :param session__last_user_agent: + :type session__last_user_agent: str + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + session__last_ip=session__last_ip, + session__last_user_agent=session__last_user_agent, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatedSessionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_authenticated_sessions_list_serialize( + self, + ordering, + page, + page_size, + search, + session__last_ip, + session__last_user_agent, + user__username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if session__last_ip is not None: + + _query_params.append(('session__last_ip', session__last_ip)) + + if session__last_user_agent is not None: + + _query_params.append(('session__last_user_agent', session__last_user_agent)) + + if user__username is not None: + + _query_params.append(('user__username', user__username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/authenticated_sessions/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_authenticated_sessions_retrieve( + self, + uuid: UUID, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatedSession: + """core_authenticated_sessions_retrieve + + AuthenticatedSession Viewset + + :param uuid: (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatedSession", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_authenticated_sessions_retrieve_with_http_info( + self, + uuid: UUID, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatedSession]: + """core_authenticated_sessions_retrieve + + AuthenticatedSession Viewset + + :param uuid: (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatedSession", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_authenticated_sessions_retrieve_without_preload_content( + self, + uuid: UUID, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_authenticated_sessions_retrieve + + AuthenticatedSession Viewset + + :param uuid: (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatedSession", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_authenticated_sessions_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/authenticated_sessions/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_authenticated_sessions_used_by_list( + self, + uuid: UUID, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """core_authenticated_sessions_used_by_list + + Get a list of all objects that use this object + + :param uuid: (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_authenticated_sessions_used_by_list_with_http_info( + self, + uuid: UUID, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """core_authenticated_sessions_used_by_list + + Get a list of all objects that use this object + + :param uuid: (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_authenticated_sessions_used_by_list_without_preload_content( + self, + uuid: UUID, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_authenticated_sessions_used_by_list + + Get a list of all objects that use this object + + :param uuid: (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_authenticated_sessions_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_authenticated_sessions_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/authenticated_sessions/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_brands_create( + self, + brand_request: BrandRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Brand: + """core_brands_create + + Brand Viewset + + :param brand_request: (required) + :type brand_request: BrandRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_create_serialize( + brand_request=brand_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_brands_create_with_http_info( + self, + brand_request: BrandRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Brand]: + """core_brands_create + + Brand Viewset + + :param brand_request: (required) + :type brand_request: BrandRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_create_serialize( + brand_request=brand_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_brands_create_without_preload_content( + self, + brand_request: BrandRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_brands_create + + Brand Viewset + + :param brand_request: (required) + :type brand_request: BrandRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_create_serialize( + brand_request=brand_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_brands_create_serialize( + self, + brand_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if brand_request is not None: + _body_params = brand_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/brands/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_brands_current_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CurrentBrand: + """core_brands_current_retrieve + + Get current brand + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_current_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CurrentBrand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_brands_current_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CurrentBrand]: + """core_brands_current_retrieve + + Get current brand + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_current_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CurrentBrand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_brands_current_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_brands_current_retrieve + + Get current brand + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_current_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CurrentBrand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_brands_current_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/brands/current/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_brands_destroy( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_brands_destroy + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_destroy_serialize( + brand_uuid=brand_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_brands_destroy_with_http_info( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_brands_destroy + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_destroy_serialize( + brand_uuid=brand_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_brands_destroy_without_preload_content( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_brands_destroy + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_destroy_serialize( + brand_uuid=brand_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_brands_destroy_serialize( + self, + brand_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if brand_uuid is not None: + _path_params['brand_uuid'] = brand_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/core/brands/{brand_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_brands_list( + self, + brand_uuid: Optional[UUID] = None, + branding_default_flow_background: Optional[StrictStr] = None, + branding_favicon: Optional[StrictStr] = None, + branding_logo: Optional[StrictStr] = None, + branding_title: Optional[StrictStr] = None, + client_certificates: Optional[List[UUID]] = None, + default: Optional[StrictBool] = None, + domain: Optional[StrictStr] = None, + flow_authentication: Optional[UUID] = None, + flow_device_code: Optional[UUID] = None, + flow_invalidation: Optional[UUID] = None, + flow_lockdown: Optional[UUID] = None, + flow_recovery: Optional[UUID] = None, + flow_unenrollment: Optional[UUID] = None, + flow_user_settings: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + web_certificate: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedBrandList: + """core_brands_list + + Brand Viewset + + :param brand_uuid: + :type brand_uuid: UUID + :param branding_default_flow_background: + :type branding_default_flow_background: str + :param branding_favicon: + :type branding_favicon: str + :param branding_logo: + :type branding_logo: str + :param branding_title: + :type branding_title: str + :param client_certificates: + :type client_certificates: List[UUID] + :param default: + :type default: bool + :param domain: + :type domain: str + :param flow_authentication: + :type flow_authentication: UUID + :param flow_device_code: + :type flow_device_code: UUID + :param flow_invalidation: + :type flow_invalidation: UUID + :param flow_lockdown: + :type flow_lockdown: UUID + :param flow_recovery: + :type flow_recovery: UUID + :param flow_unenrollment: + :type flow_unenrollment: UUID + :param flow_user_settings: + :type flow_user_settings: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param web_certificate: + :type web_certificate: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_list_serialize( + brand_uuid=brand_uuid, + branding_default_flow_background=branding_default_flow_background, + branding_favicon=branding_favicon, + branding_logo=branding_logo, + branding_title=branding_title, + client_certificates=client_certificates, + default=default, + domain=domain, + flow_authentication=flow_authentication, + flow_device_code=flow_device_code, + flow_invalidation=flow_invalidation, + flow_lockdown=flow_lockdown, + flow_recovery=flow_recovery, + flow_unenrollment=flow_unenrollment, + flow_user_settings=flow_user_settings, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + web_certificate=web_certificate, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedBrandList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_brands_list_with_http_info( + self, + brand_uuid: Optional[UUID] = None, + branding_default_flow_background: Optional[StrictStr] = None, + branding_favicon: Optional[StrictStr] = None, + branding_logo: Optional[StrictStr] = None, + branding_title: Optional[StrictStr] = None, + client_certificates: Optional[List[UUID]] = None, + default: Optional[StrictBool] = None, + domain: Optional[StrictStr] = None, + flow_authentication: Optional[UUID] = None, + flow_device_code: Optional[UUID] = None, + flow_invalidation: Optional[UUID] = None, + flow_lockdown: Optional[UUID] = None, + flow_recovery: Optional[UUID] = None, + flow_unenrollment: Optional[UUID] = None, + flow_user_settings: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + web_certificate: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedBrandList]: + """core_brands_list + + Brand Viewset + + :param brand_uuid: + :type brand_uuid: UUID + :param branding_default_flow_background: + :type branding_default_flow_background: str + :param branding_favicon: + :type branding_favicon: str + :param branding_logo: + :type branding_logo: str + :param branding_title: + :type branding_title: str + :param client_certificates: + :type client_certificates: List[UUID] + :param default: + :type default: bool + :param domain: + :type domain: str + :param flow_authentication: + :type flow_authentication: UUID + :param flow_device_code: + :type flow_device_code: UUID + :param flow_invalidation: + :type flow_invalidation: UUID + :param flow_lockdown: + :type flow_lockdown: UUID + :param flow_recovery: + :type flow_recovery: UUID + :param flow_unenrollment: + :type flow_unenrollment: UUID + :param flow_user_settings: + :type flow_user_settings: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param web_certificate: + :type web_certificate: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_list_serialize( + brand_uuid=brand_uuid, + branding_default_flow_background=branding_default_flow_background, + branding_favicon=branding_favicon, + branding_logo=branding_logo, + branding_title=branding_title, + client_certificates=client_certificates, + default=default, + domain=domain, + flow_authentication=flow_authentication, + flow_device_code=flow_device_code, + flow_invalidation=flow_invalidation, + flow_lockdown=flow_lockdown, + flow_recovery=flow_recovery, + flow_unenrollment=flow_unenrollment, + flow_user_settings=flow_user_settings, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + web_certificate=web_certificate, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedBrandList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_brands_list_without_preload_content( + self, + brand_uuid: Optional[UUID] = None, + branding_default_flow_background: Optional[StrictStr] = None, + branding_favicon: Optional[StrictStr] = None, + branding_logo: Optional[StrictStr] = None, + branding_title: Optional[StrictStr] = None, + client_certificates: Optional[List[UUID]] = None, + default: Optional[StrictBool] = None, + domain: Optional[StrictStr] = None, + flow_authentication: Optional[UUID] = None, + flow_device_code: Optional[UUID] = None, + flow_invalidation: Optional[UUID] = None, + flow_lockdown: Optional[UUID] = None, + flow_recovery: Optional[UUID] = None, + flow_unenrollment: Optional[UUID] = None, + flow_user_settings: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + web_certificate: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_brands_list + + Brand Viewset + + :param brand_uuid: + :type brand_uuid: UUID + :param branding_default_flow_background: + :type branding_default_flow_background: str + :param branding_favicon: + :type branding_favicon: str + :param branding_logo: + :type branding_logo: str + :param branding_title: + :type branding_title: str + :param client_certificates: + :type client_certificates: List[UUID] + :param default: + :type default: bool + :param domain: + :type domain: str + :param flow_authentication: + :type flow_authentication: UUID + :param flow_device_code: + :type flow_device_code: UUID + :param flow_invalidation: + :type flow_invalidation: UUID + :param flow_lockdown: + :type flow_lockdown: UUID + :param flow_recovery: + :type flow_recovery: UUID + :param flow_unenrollment: + :type flow_unenrollment: UUID + :param flow_user_settings: + :type flow_user_settings: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param web_certificate: + :type web_certificate: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_list_serialize( + brand_uuid=brand_uuid, + branding_default_flow_background=branding_default_flow_background, + branding_favicon=branding_favicon, + branding_logo=branding_logo, + branding_title=branding_title, + client_certificates=client_certificates, + default=default, + domain=domain, + flow_authentication=flow_authentication, + flow_device_code=flow_device_code, + flow_invalidation=flow_invalidation, + flow_lockdown=flow_lockdown, + flow_recovery=flow_recovery, + flow_unenrollment=flow_unenrollment, + flow_user_settings=flow_user_settings, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + web_certificate=web_certificate, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedBrandList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_brands_list_serialize( + self, + brand_uuid, + branding_default_flow_background, + branding_favicon, + branding_logo, + branding_title, + client_certificates, + default, + domain, + flow_authentication, + flow_device_code, + flow_invalidation, + flow_lockdown, + flow_recovery, + flow_unenrollment, + flow_user_settings, + ordering, + page, + page_size, + search, + web_certificate, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'client_certificates': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if brand_uuid is not None: + + _query_params.append(('brand_uuid', brand_uuid)) + + if branding_default_flow_background is not None: + + _query_params.append(('branding_default_flow_background', branding_default_flow_background)) + + if branding_favicon is not None: + + _query_params.append(('branding_favicon', branding_favicon)) + + if branding_logo is not None: + + _query_params.append(('branding_logo', branding_logo)) + + if branding_title is not None: + + _query_params.append(('branding_title', branding_title)) + + if client_certificates is not None: + + _query_params.append(('client_certificates', client_certificates)) + + if default is not None: + + _query_params.append(('default', default)) + + if domain is not None: + + _query_params.append(('domain', domain)) + + if flow_authentication is not None: + + _query_params.append(('flow_authentication', flow_authentication)) + + if flow_device_code is not None: + + _query_params.append(('flow_device_code', flow_device_code)) + + if flow_invalidation is not None: + + _query_params.append(('flow_invalidation', flow_invalidation)) + + if flow_lockdown is not None: + + _query_params.append(('flow_lockdown', flow_lockdown)) + + if flow_recovery is not None: + + _query_params.append(('flow_recovery', flow_recovery)) + + if flow_unenrollment is not None: + + _query_params.append(('flow_unenrollment', flow_unenrollment)) + + if flow_user_settings is not None: + + _query_params.append(('flow_user_settings', flow_user_settings)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if web_certificate is not None: + + _query_params.append(('web_certificate', web_certificate)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/brands/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_brands_partial_update( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + patched_brand_request: Optional[PatchedBrandRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Brand: + """core_brands_partial_update + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param patched_brand_request: + :type patched_brand_request: PatchedBrandRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_partial_update_serialize( + brand_uuid=brand_uuid, + patched_brand_request=patched_brand_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_brands_partial_update_with_http_info( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + patched_brand_request: Optional[PatchedBrandRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Brand]: + """core_brands_partial_update + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param patched_brand_request: + :type patched_brand_request: PatchedBrandRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_partial_update_serialize( + brand_uuid=brand_uuid, + patched_brand_request=patched_brand_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_brands_partial_update_without_preload_content( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + patched_brand_request: Optional[PatchedBrandRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_brands_partial_update + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param patched_brand_request: + :type patched_brand_request: PatchedBrandRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_partial_update_serialize( + brand_uuid=brand_uuid, + patched_brand_request=patched_brand_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_brands_partial_update_serialize( + self, + brand_uuid, + patched_brand_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if brand_uuid is not None: + _path_params['brand_uuid'] = brand_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_brand_request is not None: + _body_params = patched_brand_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/core/brands/{brand_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_brands_retrieve( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Brand: + """core_brands_retrieve + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_retrieve_serialize( + brand_uuid=brand_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_brands_retrieve_with_http_info( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Brand]: + """core_brands_retrieve + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_retrieve_serialize( + brand_uuid=brand_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_brands_retrieve_without_preload_content( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_brands_retrieve + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_retrieve_serialize( + brand_uuid=brand_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_brands_retrieve_serialize( + self, + brand_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if brand_uuid is not None: + _path_params['brand_uuid'] = brand_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/brands/{brand_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_brands_update( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + brand_request: BrandRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Brand: + """core_brands_update + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param brand_request: (required) + :type brand_request: BrandRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_update_serialize( + brand_uuid=brand_uuid, + brand_request=brand_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_brands_update_with_http_info( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + brand_request: BrandRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Brand]: + """core_brands_update + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param brand_request: (required) + :type brand_request: BrandRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_update_serialize( + brand_uuid=brand_uuid, + brand_request=brand_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_brands_update_without_preload_content( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + brand_request: BrandRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_brands_update + + Brand Viewset + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param brand_request: (required) + :type brand_request: BrandRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_update_serialize( + brand_uuid=brand_uuid, + brand_request=brand_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Brand", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_brands_update_serialize( + self, + brand_uuid, + brand_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if brand_uuid is not None: + _path_params['brand_uuid'] = brand_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if brand_request is not None: + _body_params = brand_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/core/brands/{brand_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_brands_used_by_list( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """core_brands_used_by_list + + Get a list of all objects that use this object + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_used_by_list_serialize( + brand_uuid=brand_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_brands_used_by_list_with_http_info( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """core_brands_used_by_list + + Get a list of all objects that use this object + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_used_by_list_serialize( + brand_uuid=brand_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_brands_used_by_list_without_preload_content( + self, + brand_uuid: Annotated[UUID, Field(description="A UUID string identifying this Brand.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_brands_used_by_list + + Get a list of all objects that use this object + + :param brand_uuid: A UUID string identifying this Brand. (required) + :type brand_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_brands_used_by_list_serialize( + brand_uuid=brand_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_brands_used_by_list_serialize( + self, + brand_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if brand_uuid is not None: + _path_params['brand_uuid'] = brand_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/brands/{brand_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_groups_add_user_create( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + user_account_request: UserAccountRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_groups_add_user_create + + Add user to group + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param user_account_request: (required) + :type user_account_request: UserAccountRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_add_user_create_serialize( + group_uuid=group_uuid, + user_account_request=user_account_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_groups_add_user_create_with_http_info( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + user_account_request: UserAccountRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_groups_add_user_create + + Add user to group + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param user_account_request: (required) + :type user_account_request: UserAccountRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_add_user_create_serialize( + group_uuid=group_uuid, + user_account_request=user_account_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_groups_add_user_create_without_preload_content( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + user_account_request: UserAccountRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_groups_add_user_create + + Add user to group + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param user_account_request: (required) + :type user_account_request: UserAccountRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_add_user_create_serialize( + group_uuid=group_uuid, + user_account_request=user_account_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_groups_add_user_create_serialize( + self, + group_uuid, + user_account_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if group_uuid is not None: + _path_params['group_uuid'] = group_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_account_request is not None: + _body_params = user_account_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/groups/{group_uuid}/add_user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_groups_create( + self, + group_request: GroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Group: + """core_groups_create + + Group Viewset + + :param group_request: (required) + :type group_request: GroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_create_serialize( + group_request=group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_groups_create_with_http_info( + self, + group_request: GroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Group]: + """core_groups_create + + Group Viewset + + :param group_request: (required) + :type group_request: GroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_create_serialize( + group_request=group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_groups_create_without_preload_content( + self, + group_request: GroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_groups_create + + Group Viewset + + :param group_request: (required) + :type group_request: GroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_create_serialize( + group_request=group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_groups_create_serialize( + self, + group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_request is not None: + _body_params = group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_groups_destroy( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_groups_destroy + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_destroy_serialize( + group_uuid=group_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_groups_destroy_with_http_info( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_groups_destroy + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_destroy_serialize( + group_uuid=group_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_groups_destroy_without_preload_content( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_groups_destroy + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_destroy_serialize( + group_uuid=group_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_groups_destroy_serialize( + self, + group_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if group_uuid is not None: + _path_params['group_uuid'] = group_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/core/groups/{group_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_groups_list( + self, + attributes: Annotated[Optional[StrictStr], Field(description="Attributes")] = None, + include_children: Optional[StrictBool] = None, + include_inherited_roles: Optional[StrictBool] = None, + include_parents: Optional[StrictBool] = None, + include_users: Optional[StrictBool] = None, + is_superuser: Optional[StrictBool] = None, + members_by_pk: Optional[List[StrictInt]] = None, + members_by_username: Annotated[Optional[List[StrictStr]], Field(description="Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.")] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGroupList: + """core_groups_list + + Group Viewset + + :param attributes: Attributes + :type attributes: str + :param include_children: + :type include_children: bool + :param include_inherited_roles: + :type include_inherited_roles: bool + :param include_parents: + :type include_parents: bool + :param include_users: + :type include_users: bool + :param is_superuser: + :type is_superuser: bool + :param members_by_pk: + :type members_by_pk: List[int] + :param members_by_username: Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only. + :type members_by_username: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_list_serialize( + attributes=attributes, + include_children=include_children, + include_inherited_roles=include_inherited_roles, + include_parents=include_parents, + include_users=include_users, + is_superuser=is_superuser, + members_by_pk=members_by_pk, + members_by_username=members_by_username, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_groups_list_with_http_info( + self, + attributes: Annotated[Optional[StrictStr], Field(description="Attributes")] = None, + include_children: Optional[StrictBool] = None, + include_inherited_roles: Optional[StrictBool] = None, + include_parents: Optional[StrictBool] = None, + include_users: Optional[StrictBool] = None, + is_superuser: Optional[StrictBool] = None, + members_by_pk: Optional[List[StrictInt]] = None, + members_by_username: Annotated[Optional[List[StrictStr]], Field(description="Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.")] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGroupList]: + """core_groups_list + + Group Viewset + + :param attributes: Attributes + :type attributes: str + :param include_children: + :type include_children: bool + :param include_inherited_roles: + :type include_inherited_roles: bool + :param include_parents: + :type include_parents: bool + :param include_users: + :type include_users: bool + :param is_superuser: + :type is_superuser: bool + :param members_by_pk: + :type members_by_pk: List[int] + :param members_by_username: Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only. + :type members_by_username: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_list_serialize( + attributes=attributes, + include_children=include_children, + include_inherited_roles=include_inherited_roles, + include_parents=include_parents, + include_users=include_users, + is_superuser=is_superuser, + members_by_pk=members_by_pk, + members_by_username=members_by_username, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_groups_list_without_preload_content( + self, + attributes: Annotated[Optional[StrictStr], Field(description="Attributes")] = None, + include_children: Optional[StrictBool] = None, + include_inherited_roles: Optional[StrictBool] = None, + include_parents: Optional[StrictBool] = None, + include_users: Optional[StrictBool] = None, + is_superuser: Optional[StrictBool] = None, + members_by_pk: Optional[List[StrictInt]] = None, + members_by_username: Annotated[Optional[List[StrictStr]], Field(description="Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.")] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_groups_list + + Group Viewset + + :param attributes: Attributes + :type attributes: str + :param include_children: + :type include_children: bool + :param include_inherited_roles: + :type include_inherited_roles: bool + :param include_parents: + :type include_parents: bool + :param include_users: + :type include_users: bool + :param is_superuser: + :type is_superuser: bool + :param members_by_pk: + :type members_by_pk: List[int] + :param members_by_username: Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only. + :type members_by_username: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_list_serialize( + attributes=attributes, + include_children=include_children, + include_inherited_roles=include_inherited_roles, + include_parents=include_parents, + include_users=include_users, + is_superuser=is_superuser, + members_by_pk=members_by_pk, + members_by_username=members_by_username, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_groups_list_serialize( + self, + attributes, + include_children, + include_inherited_roles, + include_parents, + include_users, + is_superuser, + members_by_pk, + members_by_username, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'members_by_pk': 'multi', + 'members_by_username': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if attributes is not None: + + _query_params.append(('attributes', attributes)) + + if include_children is not None: + + _query_params.append(('include_children', include_children)) + + if include_inherited_roles is not None: + + _query_params.append(('include_inherited_roles', include_inherited_roles)) + + if include_parents is not None: + + _query_params.append(('include_parents', include_parents)) + + if include_users is not None: + + _query_params.append(('include_users', include_users)) + + if is_superuser is not None: + + _query_params.append(('is_superuser', is_superuser)) + + if members_by_pk is not None: + + _query_params.append(('members_by_pk', members_by_pk)) + + if members_by_username is not None: + + _query_params.append(('members_by_username', members_by_username)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_groups_partial_update( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + patched_group_request: Optional[PatchedGroupRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Group: + """core_groups_partial_update + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param patched_group_request: + :type patched_group_request: PatchedGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_partial_update_serialize( + group_uuid=group_uuid, + patched_group_request=patched_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_groups_partial_update_with_http_info( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + patched_group_request: Optional[PatchedGroupRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Group]: + """core_groups_partial_update + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param patched_group_request: + :type patched_group_request: PatchedGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_partial_update_serialize( + group_uuid=group_uuid, + patched_group_request=patched_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_groups_partial_update_without_preload_content( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + patched_group_request: Optional[PatchedGroupRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_groups_partial_update + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param patched_group_request: + :type patched_group_request: PatchedGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_partial_update_serialize( + group_uuid=group_uuid, + patched_group_request=patched_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_groups_partial_update_serialize( + self, + group_uuid, + patched_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if group_uuid is not None: + _path_params['group_uuid'] = group_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_group_request is not None: + _body_params = patched_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/core/groups/{group_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_groups_remove_user_create( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + user_account_request: UserAccountRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_groups_remove_user_create + + Remove user from group + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param user_account_request: (required) + :type user_account_request: UserAccountRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_remove_user_create_serialize( + group_uuid=group_uuid, + user_account_request=user_account_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_groups_remove_user_create_with_http_info( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + user_account_request: UserAccountRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_groups_remove_user_create + + Remove user from group + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param user_account_request: (required) + :type user_account_request: UserAccountRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_remove_user_create_serialize( + group_uuid=group_uuid, + user_account_request=user_account_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_groups_remove_user_create_without_preload_content( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + user_account_request: UserAccountRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_groups_remove_user_create + + Remove user from group + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param user_account_request: (required) + :type user_account_request: UserAccountRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_remove_user_create_serialize( + group_uuid=group_uuid, + user_account_request=user_account_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_groups_remove_user_create_serialize( + self, + group_uuid, + user_account_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if group_uuid is not None: + _path_params['group_uuid'] = group_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_account_request is not None: + _body_params = user_account_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/groups/{group_uuid}/remove_user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_groups_retrieve( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + include_children: Optional[StrictBool] = None, + include_inherited_roles: Optional[StrictBool] = None, + include_parents: Optional[StrictBool] = None, + include_users: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Group: + """core_groups_retrieve + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param include_children: + :type include_children: bool + :param include_inherited_roles: + :type include_inherited_roles: bool + :param include_parents: + :type include_parents: bool + :param include_users: + :type include_users: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_retrieve_serialize( + group_uuid=group_uuid, + include_children=include_children, + include_inherited_roles=include_inherited_roles, + include_parents=include_parents, + include_users=include_users, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_groups_retrieve_with_http_info( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + include_children: Optional[StrictBool] = None, + include_inherited_roles: Optional[StrictBool] = None, + include_parents: Optional[StrictBool] = None, + include_users: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Group]: + """core_groups_retrieve + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param include_children: + :type include_children: bool + :param include_inherited_roles: + :type include_inherited_roles: bool + :param include_parents: + :type include_parents: bool + :param include_users: + :type include_users: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_retrieve_serialize( + group_uuid=group_uuid, + include_children=include_children, + include_inherited_roles=include_inherited_roles, + include_parents=include_parents, + include_users=include_users, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_groups_retrieve_without_preload_content( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + include_children: Optional[StrictBool] = None, + include_inherited_roles: Optional[StrictBool] = None, + include_parents: Optional[StrictBool] = None, + include_users: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_groups_retrieve + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param include_children: + :type include_children: bool + :param include_inherited_roles: + :type include_inherited_roles: bool + :param include_parents: + :type include_parents: bool + :param include_users: + :type include_users: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_retrieve_serialize( + group_uuid=group_uuid, + include_children=include_children, + include_inherited_roles=include_inherited_roles, + include_parents=include_parents, + include_users=include_users, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_groups_retrieve_serialize( + self, + group_uuid, + include_children, + include_inherited_roles, + include_parents, + include_users, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if group_uuid is not None: + _path_params['group_uuid'] = group_uuid + # process the query parameters + if include_children is not None: + + _query_params.append(('include_children', include_children)) + + if include_inherited_roles is not None: + + _query_params.append(('include_inherited_roles', include_inherited_roles)) + + if include_parents is not None: + + _query_params.append(('include_parents', include_parents)) + + if include_users is not None: + + _query_params.append(('include_users', include_users)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/groups/{group_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_groups_update( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + group_request: GroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Group: + """core_groups_update + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param group_request: (required) + :type group_request: GroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_update_serialize( + group_uuid=group_uuid, + group_request=group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_groups_update_with_http_info( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + group_request: GroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Group]: + """core_groups_update + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param group_request: (required) + :type group_request: GroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_update_serialize( + group_uuid=group_uuid, + group_request=group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_groups_update_without_preload_content( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + group_request: GroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_groups_update + + Group Viewset + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param group_request: (required) + :type group_request: GroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_update_serialize( + group_uuid=group_uuid, + group_request=group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Group", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_groups_update_serialize( + self, + group_uuid, + group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if group_uuid is not None: + _path_params['group_uuid'] = group_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_request is not None: + _body_params = group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/core/groups/{group_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_groups_used_by_list( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """core_groups_used_by_list + + Get a list of all objects that use this object + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_used_by_list_serialize( + group_uuid=group_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_groups_used_by_list_with_http_info( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """core_groups_used_by_list + + Get a list of all objects that use this object + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_used_by_list_serialize( + group_uuid=group_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_groups_used_by_list_without_preload_content( + self, + group_uuid: Annotated[UUID, Field(description="A UUID string identifying this Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_groups_used_by_list + + Get a list of all objects that use this object + + :param group_uuid: A UUID string identifying this Group. (required) + :type group_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_groups_used_by_list_serialize( + group_uuid=group_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_groups_used_by_list_serialize( + self, + group_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if group_uuid is not None: + _path_params['group_uuid'] = group_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/groups/{group_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_tokens_create( + self, + token_request: TokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Token: + """core_tokens_create + + Token Viewset + + :param token_request: (required) + :type token_request: TokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_create_serialize( + token_request=token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_tokens_create_with_http_info( + self, + token_request: TokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Token]: + """core_tokens_create + + Token Viewset + + :param token_request: (required) + :type token_request: TokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_create_serialize( + token_request=token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_tokens_create_without_preload_content( + self, + token_request: TokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_tokens_create + + Token Viewset + + :param token_request: (required) + :type token_request: TokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_create_serialize( + token_request=token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_tokens_create_serialize( + self, + token_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if token_request is not None: + _body_params = token_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/tokens/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_tokens_destroy( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_tokens_destroy + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_destroy_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_tokens_destroy_with_http_info( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_tokens_destroy + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_destroy_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_tokens_destroy_without_preload_content( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_tokens_destroy + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_destroy_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_tokens_destroy_serialize( + self, + identifier, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if identifier is not None: + _path_params['identifier'] = identifier + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/core/tokens/{identifier}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_tokens_list( + self, + description: Optional[StrictStr] = None, + expires: Optional[datetime] = None, + expiring: Optional[StrictBool] = None, + identifier: Optional[StrictStr] = None, + intent: Optional[IntentEnum] = None, + managed: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedTokenList: + """core_tokens_list + + Token Viewset + + :param description: + :type description: str + :param expires: + :type expires: datetime + :param expiring: + :type expiring: bool + :param identifier: + :type identifier: str + :param intent: + :type intent: IntentEnum + :param managed: + :type managed: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_list_serialize( + description=description, + expires=expires, + expiring=expiring, + identifier=identifier, + intent=intent, + managed=managed, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTokenList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_tokens_list_with_http_info( + self, + description: Optional[StrictStr] = None, + expires: Optional[datetime] = None, + expiring: Optional[StrictBool] = None, + identifier: Optional[StrictStr] = None, + intent: Optional[IntentEnum] = None, + managed: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedTokenList]: + """core_tokens_list + + Token Viewset + + :param description: + :type description: str + :param expires: + :type expires: datetime + :param expiring: + :type expiring: bool + :param identifier: + :type identifier: str + :param intent: + :type intent: IntentEnum + :param managed: + :type managed: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_list_serialize( + description=description, + expires=expires, + expiring=expiring, + identifier=identifier, + intent=intent, + managed=managed, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTokenList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_tokens_list_without_preload_content( + self, + description: Optional[StrictStr] = None, + expires: Optional[datetime] = None, + expiring: Optional[StrictBool] = None, + identifier: Optional[StrictStr] = None, + intent: Optional[IntentEnum] = None, + managed: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_tokens_list + + Token Viewset + + :param description: + :type description: str + :param expires: + :type expires: datetime + :param expiring: + :type expiring: bool + :param identifier: + :type identifier: str + :param intent: + :type intent: IntentEnum + :param managed: + :type managed: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_list_serialize( + description=description, + expires=expires, + expiring=expiring, + identifier=identifier, + intent=intent, + managed=managed, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTokenList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_tokens_list_serialize( + self, + description, + expires, + expiring, + identifier, + intent, + managed, + ordering, + page, + page_size, + search, + user__username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if description is not None: + + _query_params.append(('description', description)) + + if expires is not None: + if isinstance(expires, datetime): + _query_params.append( + ( + 'expires', + expires.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('expires', expires)) + + if expiring is not None: + + _query_params.append(('expiring', expiring)) + + if identifier is not None: + + _query_params.append(('identifier', identifier)) + + if intent is not None: + + _query_params.append(('intent', intent.value)) + + if managed is not None: + + _query_params.append(('managed', managed)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if user__username is not None: + + _query_params.append(('user__username', user__username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/tokens/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_tokens_partial_update( + self, + identifier: StrictStr, + patched_token_request: Optional[PatchedTokenRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Token: + """core_tokens_partial_update + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param patched_token_request: + :type patched_token_request: PatchedTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_partial_update_serialize( + identifier=identifier, + patched_token_request=patched_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_tokens_partial_update_with_http_info( + self, + identifier: StrictStr, + patched_token_request: Optional[PatchedTokenRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Token]: + """core_tokens_partial_update + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param patched_token_request: + :type patched_token_request: PatchedTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_partial_update_serialize( + identifier=identifier, + patched_token_request=patched_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_tokens_partial_update_without_preload_content( + self, + identifier: StrictStr, + patched_token_request: Optional[PatchedTokenRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_tokens_partial_update + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param patched_token_request: + :type patched_token_request: PatchedTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_partial_update_serialize( + identifier=identifier, + patched_token_request=patched_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_tokens_partial_update_serialize( + self, + identifier, + patched_token_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if identifier is not None: + _path_params['identifier'] = identifier + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_token_request is not None: + _body_params = patched_token_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/core/tokens/{identifier}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_tokens_retrieve( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Token: + """core_tokens_retrieve + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_retrieve_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_tokens_retrieve_with_http_info( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Token]: + """core_tokens_retrieve + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_retrieve_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_tokens_retrieve_without_preload_content( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_tokens_retrieve + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_retrieve_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_tokens_retrieve_serialize( + self, + identifier, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if identifier is not None: + _path_params['identifier'] = identifier + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/tokens/{identifier}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_tokens_set_key_create( + self, + identifier: StrictStr, + token_set_key_request: TokenSetKeyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_tokens_set_key_create + + Set token key. Action is logged as event. `authentik_core.set_token_key` permission is required. + + :param identifier: (required) + :type identifier: str + :param token_set_key_request: (required) + :type token_set_key_request: TokenSetKeyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_set_key_create_serialize( + identifier=identifier, + token_set_key_request=token_set_key_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_tokens_set_key_create_with_http_info( + self, + identifier: StrictStr, + token_set_key_request: TokenSetKeyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_tokens_set_key_create + + Set token key. Action is logged as event. `authentik_core.set_token_key` permission is required. + + :param identifier: (required) + :type identifier: str + :param token_set_key_request: (required) + :type token_set_key_request: TokenSetKeyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_set_key_create_serialize( + identifier=identifier, + token_set_key_request=token_set_key_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_tokens_set_key_create_without_preload_content( + self, + identifier: StrictStr, + token_set_key_request: TokenSetKeyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_tokens_set_key_create + + Set token key. Action is logged as event. `authentik_core.set_token_key` permission is required. + + :param identifier: (required) + :type identifier: str + :param token_set_key_request: (required) + :type token_set_key_request: TokenSetKeyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_set_key_create_serialize( + identifier=identifier, + token_set_key_request=token_set_key_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_tokens_set_key_create_serialize( + self, + identifier, + token_set_key_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if identifier is not None: + _path_params['identifier'] = identifier + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if token_set_key_request is not None: + _body_params = token_set_key_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/tokens/{identifier}/set_key/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_tokens_update( + self, + identifier: StrictStr, + token_request: TokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Token: + """core_tokens_update + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param token_request: (required) + :type token_request: TokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_update_serialize( + identifier=identifier, + token_request=token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_tokens_update_with_http_info( + self, + identifier: StrictStr, + token_request: TokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Token]: + """core_tokens_update + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param token_request: (required) + :type token_request: TokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_update_serialize( + identifier=identifier, + token_request=token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_tokens_update_without_preload_content( + self, + identifier: StrictStr, + token_request: TokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_tokens_update + + Token Viewset + + :param identifier: (required) + :type identifier: str + :param token_request: (required) + :type token_request: TokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_update_serialize( + identifier=identifier, + token_request=token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Token", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_tokens_update_serialize( + self, + identifier, + token_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if identifier is not None: + _path_params['identifier'] = identifier + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if token_request is not None: + _body_params = token_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/core/tokens/{identifier}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_tokens_used_by_list( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """core_tokens_used_by_list + + Get a list of all objects that use this object + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_used_by_list_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_tokens_used_by_list_with_http_info( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """core_tokens_used_by_list + + Get a list of all objects that use this object + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_used_by_list_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_tokens_used_by_list_without_preload_content( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_tokens_used_by_list + + Get a list of all objects that use this object + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_used_by_list_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_tokens_used_by_list_serialize( + self, + identifier, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if identifier is not None: + _path_params['identifier'] = identifier + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/tokens/{identifier}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_tokens_view_key_retrieve( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TokenView: + """core_tokens_view_key_retrieve + + Return token key and log access + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_view_key_retrieve_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenView", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_tokens_view_key_retrieve_with_http_info( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TokenView]: + """core_tokens_view_key_retrieve + + Return token key and log access + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_view_key_retrieve_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenView", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_tokens_view_key_retrieve_without_preload_content( + self, + identifier: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_tokens_view_key_retrieve + + Return token key and log access + + :param identifier: (required) + :type identifier: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_tokens_view_key_retrieve_serialize( + identifier=identifier, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenView", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_tokens_view_key_retrieve_serialize( + self, + identifier, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if identifier is not None: + _path_params['identifier'] = identifier + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/tokens/{identifier}/view_key/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_transactional_applications_update( + self, + transaction_application_request: TransactionApplicationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TransactionApplicationResponse: + """core_transactional_applications_update + + Convert data into a blueprint, validate it and apply it + + :param transaction_application_request: (required) + :type transaction_application_request: TransactionApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_transactional_applications_update_serialize( + transaction_application_request=transaction_application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TransactionApplicationResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_transactional_applications_update_with_http_info( + self, + transaction_application_request: TransactionApplicationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TransactionApplicationResponse]: + """core_transactional_applications_update + + Convert data into a blueprint, validate it and apply it + + :param transaction_application_request: (required) + :type transaction_application_request: TransactionApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_transactional_applications_update_serialize( + transaction_application_request=transaction_application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TransactionApplicationResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_transactional_applications_update_without_preload_content( + self, + transaction_application_request: TransactionApplicationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_transactional_applications_update + + Convert data into a blueprint, validate it and apply it + + :param transaction_application_request: (required) + :type transaction_application_request: TransactionApplicationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_transactional_applications_update_serialize( + transaction_application_request=transaction_application_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TransactionApplicationResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_transactional_applications_update_serialize( + self, + transaction_application_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if transaction_application_request is not None: + _body_params = transaction_application_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/core/transactional/applications/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_user_consent_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Consent.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_user_consent_destroy + + UserConsent Viewset + + :param id: A unique integer value identifying this User Consent. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_user_consent_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Consent.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_user_consent_destroy + + UserConsent Viewset + + :param id: A unique integer value identifying this User Consent. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_user_consent_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Consent.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_user_consent_destroy + + UserConsent Viewset + + :param id: A unique integer value identifying this User Consent. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_user_consent_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/core/user_consent/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_user_consent_list( + self, + application: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserConsentList: + """core_user_consent_list + + UserConsent Viewset + + :param application: + :type application: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_list_serialize( + application=application, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserConsentList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_user_consent_list_with_http_info( + self, + application: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserConsentList]: + """core_user_consent_list + + UserConsent Viewset + + :param application: + :type application: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_list_serialize( + application=application, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserConsentList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_user_consent_list_without_preload_content( + self, + application: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_user_consent_list + + UserConsent Viewset + + :param application: + :type application: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_list_serialize( + application=application, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserConsentList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_user_consent_list_serialize( + self, + application, + ordering, + page, + page_size, + search, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if application is not None: + + _query_params.append(('application', application)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/user_consent/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_user_consent_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Consent.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserConsent: + """core_user_consent_retrieve + + UserConsent Viewset + + :param id: A unique integer value identifying this User Consent. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserConsent", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_user_consent_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Consent.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserConsent]: + """core_user_consent_retrieve + + UserConsent Viewset + + :param id: A unique integer value identifying this User Consent. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserConsent", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_user_consent_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Consent.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_user_consent_retrieve + + UserConsent Viewset + + :param id: A unique integer value identifying this User Consent. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserConsent", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_user_consent_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/user_consent/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_user_consent_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Consent.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """core_user_consent_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Consent. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_user_consent_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Consent.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """core_user_consent_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Consent. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_user_consent_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Consent.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_user_consent_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Consent. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_user_consent_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_user_consent_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/user_consent/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_account_lockdown_create( + self, + user_account_lockdown_request: Optional[UserAccountLockdownRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Link: + """core_users_account_lockdown_create + + Choose the target account, then return a flow link. + + :param user_account_lockdown_request: + :type user_account_lockdown_request: UserAccountLockdownRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_account_lockdown_create_serialize( + user_account_lockdown_request=user_account_lockdown_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Link", + '400': None, + '403': None, + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_account_lockdown_create_with_http_info( + self, + user_account_lockdown_request: Optional[UserAccountLockdownRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Link]: + """core_users_account_lockdown_create + + Choose the target account, then return a flow link. + + :param user_account_lockdown_request: + :type user_account_lockdown_request: UserAccountLockdownRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_account_lockdown_create_serialize( + user_account_lockdown_request=user_account_lockdown_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Link", + '400': None, + '403': None, + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_account_lockdown_create_without_preload_content( + self, + user_account_lockdown_request: Optional[UserAccountLockdownRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_account_lockdown_create + + Choose the target account, then return a flow link. + + :param user_account_lockdown_request: + :type user_account_lockdown_request: UserAccountLockdownRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_account_lockdown_create_serialize( + user_account_lockdown_request=user_account_lockdown_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Link", + '400': None, + '403': None, + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_account_lockdown_create_serialize( + self, + user_account_lockdown_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_account_lockdown_request is not None: + _body_params = user_account_lockdown_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/users/account_lockdown/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_create( + self, + user_request: UserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> User: + """core_users_create + + User Viewset + + :param user_request: (required) + :type user_request: UserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_create_serialize( + user_request=user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_create_with_http_info( + self, + user_request: UserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[User]: + """core_users_create + + User Viewset + + :param user_request: (required) + :type user_request: UserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_create_serialize( + user_request=user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_create_without_preload_content( + self, + user_request: UserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_create + + User Viewset + + :param user_request: (required) + :type user_request: UserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_create_serialize( + user_request=user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_create_serialize( + self, + user_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_request is not None: + _body_params = user_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_users_destroy + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_users_destroy + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_destroy + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/core/users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_export_create( + self, + attributes: Annotated[Optional[StrictStr], Field(description="Attributes")] = None, + date_joined: Optional[datetime] = None, + date_joined__gt: Optional[datetime] = None, + date_joined__lt: Optional[datetime] = None, + email: Optional[StrictStr] = None, + groups_by_name: Optional[List[StrictStr]] = None, + groups_by_pk: Optional[List[UUID]] = None, + is_active: Optional[StrictBool] = None, + is_superuser: Optional[StrictBool] = None, + last_login: Optional[datetime] = None, + last_login__gt: Optional[datetime] = None, + last_login__isnull: Optional[StrictBool] = None, + last_login__lt: Optional[datetime] = None, + last_updated: Optional[datetime] = None, + last_updated__gt: Optional[datetime] = None, + last_updated__lt: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + path: Optional[StrictStr] = None, + path_startswith: Optional[StrictStr] = None, + roles_by_name: Optional[List[StrictStr]] = None, + roles_by_pk: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + type: Optional[List[UserTypeEnum]] = None, + username: Optional[StrictStr] = None, + uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DataExport: + """core_users_export_create + + Create a data export for this data type. Note that the export is generated asynchronously: this method returns a `DataExport` object that will initially have `completed=false` as well as the permanent URL to that object in the `Location` header. You can poll that URL until `completed=true`, at which point the `file_url` property will contain a URL to download + + :param attributes: Attributes + :type attributes: str + :param date_joined: + :type date_joined: datetime + :param date_joined__gt: + :type date_joined__gt: datetime + :param date_joined__lt: + :type date_joined__lt: datetime + :param email: + :type email: str + :param groups_by_name: + :type groups_by_name: List[str] + :param groups_by_pk: + :type groups_by_pk: List[UUID] + :param is_active: + :type is_active: bool + :param is_superuser: + :type is_superuser: bool + :param last_login: + :type last_login: datetime + :param last_login__gt: + :type last_login__gt: datetime + :param last_login__isnull: + :type last_login__isnull: bool + :param last_login__lt: + :type last_login__lt: datetime + :param last_updated: + :type last_updated: datetime + :param last_updated__gt: + :type last_updated__gt: datetime + :param last_updated__lt: + :type last_updated__lt: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param path: + :type path: str + :param path_startswith: + :type path_startswith: str + :param roles_by_name: + :type roles_by_name: List[str] + :param roles_by_pk: + :type roles_by_pk: List[UUID] + :param search: A search term. + :type search: str + :param type: + :type type: List[UserTypeEnum] + :param username: + :type username: str + :param uuid: + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_export_create_serialize( + attributes=attributes, + date_joined=date_joined, + date_joined__gt=date_joined__gt, + date_joined__lt=date_joined__lt, + email=email, + groups_by_name=groups_by_name, + groups_by_pk=groups_by_pk, + is_active=is_active, + is_superuser=is_superuser, + last_login=last_login, + last_login__gt=last_login__gt, + last_login__isnull=last_login__isnull, + last_login__lt=last_login__lt, + last_updated=last_updated, + last_updated__gt=last_updated__gt, + last_updated__lt=last_updated__lt, + name=name, + ordering=ordering, + path=path, + path_startswith=path_startswith, + roles_by_name=roles_by_name, + roles_by_pk=roles_by_pk, + search=search, + type=type, + username=username, + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DataExport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_export_create_with_http_info( + self, + attributes: Annotated[Optional[StrictStr], Field(description="Attributes")] = None, + date_joined: Optional[datetime] = None, + date_joined__gt: Optional[datetime] = None, + date_joined__lt: Optional[datetime] = None, + email: Optional[StrictStr] = None, + groups_by_name: Optional[List[StrictStr]] = None, + groups_by_pk: Optional[List[UUID]] = None, + is_active: Optional[StrictBool] = None, + is_superuser: Optional[StrictBool] = None, + last_login: Optional[datetime] = None, + last_login__gt: Optional[datetime] = None, + last_login__isnull: Optional[StrictBool] = None, + last_login__lt: Optional[datetime] = None, + last_updated: Optional[datetime] = None, + last_updated__gt: Optional[datetime] = None, + last_updated__lt: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + path: Optional[StrictStr] = None, + path_startswith: Optional[StrictStr] = None, + roles_by_name: Optional[List[StrictStr]] = None, + roles_by_pk: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + type: Optional[List[UserTypeEnum]] = None, + username: Optional[StrictStr] = None, + uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DataExport]: + """core_users_export_create + + Create a data export for this data type. Note that the export is generated asynchronously: this method returns a `DataExport` object that will initially have `completed=false` as well as the permanent URL to that object in the `Location` header. You can poll that URL until `completed=true`, at which point the `file_url` property will contain a URL to download + + :param attributes: Attributes + :type attributes: str + :param date_joined: + :type date_joined: datetime + :param date_joined__gt: + :type date_joined__gt: datetime + :param date_joined__lt: + :type date_joined__lt: datetime + :param email: + :type email: str + :param groups_by_name: + :type groups_by_name: List[str] + :param groups_by_pk: + :type groups_by_pk: List[UUID] + :param is_active: + :type is_active: bool + :param is_superuser: + :type is_superuser: bool + :param last_login: + :type last_login: datetime + :param last_login__gt: + :type last_login__gt: datetime + :param last_login__isnull: + :type last_login__isnull: bool + :param last_login__lt: + :type last_login__lt: datetime + :param last_updated: + :type last_updated: datetime + :param last_updated__gt: + :type last_updated__gt: datetime + :param last_updated__lt: + :type last_updated__lt: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param path: + :type path: str + :param path_startswith: + :type path_startswith: str + :param roles_by_name: + :type roles_by_name: List[str] + :param roles_by_pk: + :type roles_by_pk: List[UUID] + :param search: A search term. + :type search: str + :param type: + :type type: List[UserTypeEnum] + :param username: + :type username: str + :param uuid: + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_export_create_serialize( + attributes=attributes, + date_joined=date_joined, + date_joined__gt=date_joined__gt, + date_joined__lt=date_joined__lt, + email=email, + groups_by_name=groups_by_name, + groups_by_pk=groups_by_pk, + is_active=is_active, + is_superuser=is_superuser, + last_login=last_login, + last_login__gt=last_login__gt, + last_login__isnull=last_login__isnull, + last_login__lt=last_login__lt, + last_updated=last_updated, + last_updated__gt=last_updated__gt, + last_updated__lt=last_updated__lt, + name=name, + ordering=ordering, + path=path, + path_startswith=path_startswith, + roles_by_name=roles_by_name, + roles_by_pk=roles_by_pk, + search=search, + type=type, + username=username, + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DataExport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_export_create_without_preload_content( + self, + attributes: Annotated[Optional[StrictStr], Field(description="Attributes")] = None, + date_joined: Optional[datetime] = None, + date_joined__gt: Optional[datetime] = None, + date_joined__lt: Optional[datetime] = None, + email: Optional[StrictStr] = None, + groups_by_name: Optional[List[StrictStr]] = None, + groups_by_pk: Optional[List[UUID]] = None, + is_active: Optional[StrictBool] = None, + is_superuser: Optional[StrictBool] = None, + last_login: Optional[datetime] = None, + last_login__gt: Optional[datetime] = None, + last_login__isnull: Optional[StrictBool] = None, + last_login__lt: Optional[datetime] = None, + last_updated: Optional[datetime] = None, + last_updated__gt: Optional[datetime] = None, + last_updated__lt: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + path: Optional[StrictStr] = None, + path_startswith: Optional[StrictStr] = None, + roles_by_name: Optional[List[StrictStr]] = None, + roles_by_pk: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + type: Optional[List[UserTypeEnum]] = None, + username: Optional[StrictStr] = None, + uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_export_create + + Create a data export for this data type. Note that the export is generated asynchronously: this method returns a `DataExport` object that will initially have `completed=false` as well as the permanent URL to that object in the `Location` header. You can poll that URL until `completed=true`, at which point the `file_url` property will contain a URL to download + + :param attributes: Attributes + :type attributes: str + :param date_joined: + :type date_joined: datetime + :param date_joined__gt: + :type date_joined__gt: datetime + :param date_joined__lt: + :type date_joined__lt: datetime + :param email: + :type email: str + :param groups_by_name: + :type groups_by_name: List[str] + :param groups_by_pk: + :type groups_by_pk: List[UUID] + :param is_active: + :type is_active: bool + :param is_superuser: + :type is_superuser: bool + :param last_login: + :type last_login: datetime + :param last_login__gt: + :type last_login__gt: datetime + :param last_login__isnull: + :type last_login__isnull: bool + :param last_login__lt: + :type last_login__lt: datetime + :param last_updated: + :type last_updated: datetime + :param last_updated__gt: + :type last_updated__gt: datetime + :param last_updated__lt: + :type last_updated__lt: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param path: + :type path: str + :param path_startswith: + :type path_startswith: str + :param roles_by_name: + :type roles_by_name: List[str] + :param roles_by_pk: + :type roles_by_pk: List[UUID] + :param search: A search term. + :type search: str + :param type: + :type type: List[UserTypeEnum] + :param username: + :type username: str + :param uuid: + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_export_create_serialize( + attributes=attributes, + date_joined=date_joined, + date_joined__gt=date_joined__gt, + date_joined__lt=date_joined__lt, + email=email, + groups_by_name=groups_by_name, + groups_by_pk=groups_by_pk, + is_active=is_active, + is_superuser=is_superuser, + last_login=last_login, + last_login__gt=last_login__gt, + last_login__isnull=last_login__isnull, + last_login__lt=last_login__lt, + last_updated=last_updated, + last_updated__gt=last_updated__gt, + last_updated__lt=last_updated__lt, + name=name, + ordering=ordering, + path=path, + path_startswith=path_startswith, + roles_by_name=roles_by_name, + roles_by_pk=roles_by_pk, + search=search, + type=type, + username=username, + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DataExport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_export_create_serialize( + self, + attributes, + date_joined, + date_joined__gt, + date_joined__lt, + email, + groups_by_name, + groups_by_pk, + is_active, + is_superuser, + last_login, + last_login__gt, + last_login__isnull, + last_login__lt, + last_updated, + last_updated__gt, + last_updated__lt, + name, + ordering, + path, + path_startswith, + roles_by_name, + roles_by_pk, + search, + type, + username, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'groups_by_name': 'multi', + 'groups_by_pk': 'multi', + 'roles_by_name': 'multi', + 'roles_by_pk': 'multi', + 'type': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if attributes is not None: + + _query_params.append(('attributes', attributes)) + + if date_joined is not None: + if isinstance(date_joined, datetime): + _query_params.append( + ( + 'date_joined', + date_joined.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('date_joined', date_joined)) + + if date_joined__gt is not None: + if isinstance(date_joined__gt, datetime): + _query_params.append( + ( + 'date_joined__gt', + date_joined__gt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('date_joined__gt', date_joined__gt)) + + if date_joined__lt is not None: + if isinstance(date_joined__lt, datetime): + _query_params.append( + ( + 'date_joined__lt', + date_joined__lt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('date_joined__lt', date_joined__lt)) + + if email is not None: + + _query_params.append(('email', email)) + + if groups_by_name is not None: + + _query_params.append(('groups_by_name', groups_by_name)) + + if groups_by_pk is not None: + + _query_params.append(('groups_by_pk', groups_by_pk)) + + if is_active is not None: + + _query_params.append(('is_active', is_active)) + + if is_superuser is not None: + + _query_params.append(('is_superuser', is_superuser)) + + if last_login is not None: + if isinstance(last_login, datetime): + _query_params.append( + ( + 'last_login', + last_login.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_login', last_login)) + + if last_login__gt is not None: + if isinstance(last_login__gt, datetime): + _query_params.append( + ( + 'last_login__gt', + last_login__gt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_login__gt', last_login__gt)) + + if last_login__isnull is not None: + + _query_params.append(('last_login__isnull', last_login__isnull)) + + if last_login__lt is not None: + if isinstance(last_login__lt, datetime): + _query_params.append( + ( + 'last_login__lt', + last_login__lt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_login__lt', last_login__lt)) + + if last_updated is not None: + if isinstance(last_updated, datetime): + _query_params.append( + ( + 'last_updated', + last_updated.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated', last_updated)) + + if last_updated__gt is not None: + if isinstance(last_updated__gt, datetime): + _query_params.append( + ( + 'last_updated__gt', + last_updated__gt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated__gt', last_updated__gt)) + + if last_updated__lt is not None: + if isinstance(last_updated__lt, datetime): + _query_params.append( + ( + 'last_updated__lt', + last_updated__lt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated__lt', last_updated__lt)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if path is not None: + + _query_params.append(('path', path)) + + if path_startswith is not None: + + _query_params.append(('path_startswith', path_startswith)) + + if roles_by_name is not None: + + _query_params.append(('roles_by_name', roles_by_name)) + + if roles_by_pk is not None: + + _query_params.append(('roles_by_pk', roles_by_pk)) + + if search is not None: + + _query_params.append(('search', search)) + + if type is not None: + + _query_params.append(('type', type)) + + if username is not None: + + _query_params.append(('username', username)) + + if uuid is not None: + + _query_params.append(('uuid', uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/users/export/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_impersonate_create( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + impersonation_request: ImpersonationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_users_impersonate_create + + Impersonate a user + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param impersonation_request: (required) + :type impersonation_request: ImpersonationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_impersonate_create_serialize( + id=id, + impersonation_request=impersonation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_impersonate_create_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + impersonation_request: ImpersonationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_users_impersonate_create + + Impersonate a user + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param impersonation_request: (required) + :type impersonation_request: ImpersonationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_impersonate_create_serialize( + id=id, + impersonation_request=impersonation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_impersonate_create_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + impersonation_request: ImpersonationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_impersonate_create + + Impersonate a user + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param impersonation_request: (required) + :type impersonation_request: ImpersonationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_impersonate_create_serialize( + id=id, + impersonation_request=impersonation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_impersonate_create_serialize( + self, + id, + impersonation_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if impersonation_request is not None: + _body_params = impersonation_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/users/{id}/impersonate/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_impersonate_end_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_users_impersonate_end_retrieve + + End Impersonation a user + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_impersonate_end_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_impersonate_end_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_users_impersonate_end_retrieve + + End Impersonation a user + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_impersonate_end_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_impersonate_end_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_impersonate_end_retrieve + + End Impersonation a user + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_impersonate_end_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_impersonate_end_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/users/impersonate_end/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_list( + self, + attributes: Annotated[Optional[StrictStr], Field(description="Attributes")] = None, + date_joined: Optional[datetime] = None, + date_joined__gt: Optional[datetime] = None, + date_joined__lt: Optional[datetime] = None, + email: Optional[StrictStr] = None, + groups_by_name: Optional[List[StrictStr]] = None, + groups_by_pk: Optional[List[UUID]] = None, + include_groups: Optional[StrictBool] = None, + include_roles: Optional[StrictBool] = None, + is_active: Optional[StrictBool] = None, + is_superuser: Optional[StrictBool] = None, + last_login: Optional[datetime] = None, + last_login__gt: Optional[datetime] = None, + last_login__isnull: Optional[StrictBool] = None, + last_login__lt: Optional[datetime] = None, + last_updated: Optional[datetime] = None, + last_updated__gt: Optional[datetime] = None, + last_updated__lt: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + path: Optional[StrictStr] = None, + path_startswith: Optional[StrictStr] = None, + roles_by_name: Optional[List[StrictStr]] = None, + roles_by_pk: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + type: Optional[List[UserTypeEnum]] = None, + username: Optional[StrictStr] = None, + uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserList: + """core_users_list + + User Viewset + + :param attributes: Attributes + :type attributes: str + :param date_joined: + :type date_joined: datetime + :param date_joined__gt: + :type date_joined__gt: datetime + :param date_joined__lt: + :type date_joined__lt: datetime + :param email: + :type email: str + :param groups_by_name: + :type groups_by_name: List[str] + :param groups_by_pk: + :type groups_by_pk: List[UUID] + :param include_groups: + :type include_groups: bool + :param include_roles: + :type include_roles: bool + :param is_active: + :type is_active: bool + :param is_superuser: + :type is_superuser: bool + :param last_login: + :type last_login: datetime + :param last_login__gt: + :type last_login__gt: datetime + :param last_login__isnull: + :type last_login__isnull: bool + :param last_login__lt: + :type last_login__lt: datetime + :param last_updated: + :type last_updated: datetime + :param last_updated__gt: + :type last_updated__gt: datetime + :param last_updated__lt: + :type last_updated__lt: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param path: + :type path: str + :param path_startswith: + :type path_startswith: str + :param roles_by_name: + :type roles_by_name: List[str] + :param roles_by_pk: + :type roles_by_pk: List[UUID] + :param search: A search term. + :type search: str + :param type: + :type type: List[UserTypeEnum] + :param username: + :type username: str + :param uuid: + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_list_serialize( + attributes=attributes, + date_joined=date_joined, + date_joined__gt=date_joined__gt, + date_joined__lt=date_joined__lt, + email=email, + groups_by_name=groups_by_name, + groups_by_pk=groups_by_pk, + include_groups=include_groups, + include_roles=include_roles, + is_active=is_active, + is_superuser=is_superuser, + last_login=last_login, + last_login__gt=last_login__gt, + last_login__isnull=last_login__isnull, + last_login__lt=last_login__lt, + last_updated=last_updated, + last_updated__gt=last_updated__gt, + last_updated__lt=last_updated__lt, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + path=path, + path_startswith=path_startswith, + roles_by_name=roles_by_name, + roles_by_pk=roles_by_pk, + search=search, + type=type, + username=username, + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_list_with_http_info( + self, + attributes: Annotated[Optional[StrictStr], Field(description="Attributes")] = None, + date_joined: Optional[datetime] = None, + date_joined__gt: Optional[datetime] = None, + date_joined__lt: Optional[datetime] = None, + email: Optional[StrictStr] = None, + groups_by_name: Optional[List[StrictStr]] = None, + groups_by_pk: Optional[List[UUID]] = None, + include_groups: Optional[StrictBool] = None, + include_roles: Optional[StrictBool] = None, + is_active: Optional[StrictBool] = None, + is_superuser: Optional[StrictBool] = None, + last_login: Optional[datetime] = None, + last_login__gt: Optional[datetime] = None, + last_login__isnull: Optional[StrictBool] = None, + last_login__lt: Optional[datetime] = None, + last_updated: Optional[datetime] = None, + last_updated__gt: Optional[datetime] = None, + last_updated__lt: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + path: Optional[StrictStr] = None, + path_startswith: Optional[StrictStr] = None, + roles_by_name: Optional[List[StrictStr]] = None, + roles_by_pk: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + type: Optional[List[UserTypeEnum]] = None, + username: Optional[StrictStr] = None, + uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserList]: + """core_users_list + + User Viewset + + :param attributes: Attributes + :type attributes: str + :param date_joined: + :type date_joined: datetime + :param date_joined__gt: + :type date_joined__gt: datetime + :param date_joined__lt: + :type date_joined__lt: datetime + :param email: + :type email: str + :param groups_by_name: + :type groups_by_name: List[str] + :param groups_by_pk: + :type groups_by_pk: List[UUID] + :param include_groups: + :type include_groups: bool + :param include_roles: + :type include_roles: bool + :param is_active: + :type is_active: bool + :param is_superuser: + :type is_superuser: bool + :param last_login: + :type last_login: datetime + :param last_login__gt: + :type last_login__gt: datetime + :param last_login__isnull: + :type last_login__isnull: bool + :param last_login__lt: + :type last_login__lt: datetime + :param last_updated: + :type last_updated: datetime + :param last_updated__gt: + :type last_updated__gt: datetime + :param last_updated__lt: + :type last_updated__lt: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param path: + :type path: str + :param path_startswith: + :type path_startswith: str + :param roles_by_name: + :type roles_by_name: List[str] + :param roles_by_pk: + :type roles_by_pk: List[UUID] + :param search: A search term. + :type search: str + :param type: + :type type: List[UserTypeEnum] + :param username: + :type username: str + :param uuid: + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_list_serialize( + attributes=attributes, + date_joined=date_joined, + date_joined__gt=date_joined__gt, + date_joined__lt=date_joined__lt, + email=email, + groups_by_name=groups_by_name, + groups_by_pk=groups_by_pk, + include_groups=include_groups, + include_roles=include_roles, + is_active=is_active, + is_superuser=is_superuser, + last_login=last_login, + last_login__gt=last_login__gt, + last_login__isnull=last_login__isnull, + last_login__lt=last_login__lt, + last_updated=last_updated, + last_updated__gt=last_updated__gt, + last_updated__lt=last_updated__lt, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + path=path, + path_startswith=path_startswith, + roles_by_name=roles_by_name, + roles_by_pk=roles_by_pk, + search=search, + type=type, + username=username, + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_list_without_preload_content( + self, + attributes: Annotated[Optional[StrictStr], Field(description="Attributes")] = None, + date_joined: Optional[datetime] = None, + date_joined__gt: Optional[datetime] = None, + date_joined__lt: Optional[datetime] = None, + email: Optional[StrictStr] = None, + groups_by_name: Optional[List[StrictStr]] = None, + groups_by_pk: Optional[List[UUID]] = None, + include_groups: Optional[StrictBool] = None, + include_roles: Optional[StrictBool] = None, + is_active: Optional[StrictBool] = None, + is_superuser: Optional[StrictBool] = None, + last_login: Optional[datetime] = None, + last_login__gt: Optional[datetime] = None, + last_login__isnull: Optional[StrictBool] = None, + last_login__lt: Optional[datetime] = None, + last_updated: Optional[datetime] = None, + last_updated__gt: Optional[datetime] = None, + last_updated__lt: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + path: Optional[StrictStr] = None, + path_startswith: Optional[StrictStr] = None, + roles_by_name: Optional[List[StrictStr]] = None, + roles_by_pk: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + type: Optional[List[UserTypeEnum]] = None, + username: Optional[StrictStr] = None, + uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_list + + User Viewset + + :param attributes: Attributes + :type attributes: str + :param date_joined: + :type date_joined: datetime + :param date_joined__gt: + :type date_joined__gt: datetime + :param date_joined__lt: + :type date_joined__lt: datetime + :param email: + :type email: str + :param groups_by_name: + :type groups_by_name: List[str] + :param groups_by_pk: + :type groups_by_pk: List[UUID] + :param include_groups: + :type include_groups: bool + :param include_roles: + :type include_roles: bool + :param is_active: + :type is_active: bool + :param is_superuser: + :type is_superuser: bool + :param last_login: + :type last_login: datetime + :param last_login__gt: + :type last_login__gt: datetime + :param last_login__isnull: + :type last_login__isnull: bool + :param last_login__lt: + :type last_login__lt: datetime + :param last_updated: + :type last_updated: datetime + :param last_updated__gt: + :type last_updated__gt: datetime + :param last_updated__lt: + :type last_updated__lt: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param path: + :type path: str + :param path_startswith: + :type path_startswith: str + :param roles_by_name: + :type roles_by_name: List[str] + :param roles_by_pk: + :type roles_by_pk: List[UUID] + :param search: A search term. + :type search: str + :param type: + :type type: List[UserTypeEnum] + :param username: + :type username: str + :param uuid: + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_list_serialize( + attributes=attributes, + date_joined=date_joined, + date_joined__gt=date_joined__gt, + date_joined__lt=date_joined__lt, + email=email, + groups_by_name=groups_by_name, + groups_by_pk=groups_by_pk, + include_groups=include_groups, + include_roles=include_roles, + is_active=is_active, + is_superuser=is_superuser, + last_login=last_login, + last_login__gt=last_login__gt, + last_login__isnull=last_login__isnull, + last_login__lt=last_login__lt, + last_updated=last_updated, + last_updated__gt=last_updated__gt, + last_updated__lt=last_updated__lt, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + path=path, + path_startswith=path_startswith, + roles_by_name=roles_by_name, + roles_by_pk=roles_by_pk, + search=search, + type=type, + username=username, + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_list_serialize( + self, + attributes, + date_joined, + date_joined__gt, + date_joined__lt, + email, + groups_by_name, + groups_by_pk, + include_groups, + include_roles, + is_active, + is_superuser, + last_login, + last_login__gt, + last_login__isnull, + last_login__lt, + last_updated, + last_updated__gt, + last_updated__lt, + name, + ordering, + page, + page_size, + path, + path_startswith, + roles_by_name, + roles_by_pk, + search, + type, + username, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'groups_by_name': 'multi', + 'groups_by_pk': 'multi', + 'roles_by_name': 'multi', + 'roles_by_pk': 'multi', + 'type': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if attributes is not None: + + _query_params.append(('attributes', attributes)) + + if date_joined is not None: + if isinstance(date_joined, datetime): + _query_params.append( + ( + 'date_joined', + date_joined.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('date_joined', date_joined)) + + if date_joined__gt is not None: + if isinstance(date_joined__gt, datetime): + _query_params.append( + ( + 'date_joined__gt', + date_joined__gt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('date_joined__gt', date_joined__gt)) + + if date_joined__lt is not None: + if isinstance(date_joined__lt, datetime): + _query_params.append( + ( + 'date_joined__lt', + date_joined__lt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('date_joined__lt', date_joined__lt)) + + if email is not None: + + _query_params.append(('email', email)) + + if groups_by_name is not None: + + _query_params.append(('groups_by_name', groups_by_name)) + + if groups_by_pk is not None: + + _query_params.append(('groups_by_pk', groups_by_pk)) + + if include_groups is not None: + + _query_params.append(('include_groups', include_groups)) + + if include_roles is not None: + + _query_params.append(('include_roles', include_roles)) + + if is_active is not None: + + _query_params.append(('is_active', is_active)) + + if is_superuser is not None: + + _query_params.append(('is_superuser', is_superuser)) + + if last_login is not None: + if isinstance(last_login, datetime): + _query_params.append( + ( + 'last_login', + last_login.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_login', last_login)) + + if last_login__gt is not None: + if isinstance(last_login__gt, datetime): + _query_params.append( + ( + 'last_login__gt', + last_login__gt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_login__gt', last_login__gt)) + + if last_login__isnull is not None: + + _query_params.append(('last_login__isnull', last_login__isnull)) + + if last_login__lt is not None: + if isinstance(last_login__lt, datetime): + _query_params.append( + ( + 'last_login__lt', + last_login__lt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_login__lt', last_login__lt)) + + if last_updated is not None: + if isinstance(last_updated, datetime): + _query_params.append( + ( + 'last_updated', + last_updated.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated', last_updated)) + + if last_updated__gt is not None: + if isinstance(last_updated__gt, datetime): + _query_params.append( + ( + 'last_updated__gt', + last_updated__gt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated__gt', last_updated__gt)) + + if last_updated__lt is not None: + if isinstance(last_updated__lt, datetime): + _query_params.append( + ( + 'last_updated__lt', + last_updated__lt.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated__lt', last_updated__lt)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if path is not None: + + _query_params.append(('path', path)) + + if path_startswith is not None: + + _query_params.append(('path_startswith', path_startswith)) + + if roles_by_name is not None: + + _query_params.append(('roles_by_name', roles_by_name)) + + if roles_by_pk is not None: + + _query_params.append(('roles_by_pk', roles_by_pk)) + + if search is not None: + + _query_params.append(('search', search)) + + if type is not None: + + _query_params.append(('type', type)) + + if username is not None: + + _query_params.append(('username', username)) + + if uuid is not None: + + _query_params.append(('uuid', uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_me_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SessionUser: + """core_users_me_retrieve + + Get information about current user + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_me_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SessionUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_me_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SessionUser]: + """core_users_me_retrieve + + Get information about current user + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_me_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SessionUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_me_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_me_retrieve + + Get information about current user + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_me_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SessionUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_me_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/users/me/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + patched_user_request: Optional[PatchedUserRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> User: + """core_users_partial_update + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param patched_user_request: + :type patched_user_request: PatchedUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_partial_update_serialize( + id=id, + patched_user_request=patched_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + patched_user_request: Optional[PatchedUserRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[User]: + """core_users_partial_update + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param patched_user_request: + :type patched_user_request: PatchedUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_partial_update_serialize( + id=id, + patched_user_request=patched_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + patched_user_request: Optional[PatchedUserRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_partial_update + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param patched_user_request: + :type patched_user_request: PatchedUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_partial_update_serialize( + id=id, + patched_user_request=patched_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_partial_update_serialize( + self, + id, + patched_user_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_request is not None: + _body_params = patched_user_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/core/users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_paths_retrieve( + self, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserPath: + """core_users_paths_retrieve + + Get all user paths + + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_paths_retrieve_serialize( + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPath", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_paths_retrieve_with_http_info( + self, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserPath]: + """core_users_paths_retrieve + + Get all user paths + + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_paths_retrieve_serialize( + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPath", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_paths_retrieve_without_preload_content( + self, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_paths_retrieve + + Get all user paths + + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_paths_retrieve_serialize( + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPath", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_paths_retrieve_serialize( + self, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/users/paths/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_recovery_create( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_recovery_link_request: Optional[UserRecoveryLinkRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Link: + """core_users_recovery_create + + Create a temporary link that a user can use to recover their account + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_recovery_link_request: + :type user_recovery_link_request: UserRecoveryLinkRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_recovery_create_serialize( + id=id, + user_recovery_link_request=user_recovery_link_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Link", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_recovery_create_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_recovery_link_request: Optional[UserRecoveryLinkRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Link]: + """core_users_recovery_create + + Create a temporary link that a user can use to recover their account + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_recovery_link_request: + :type user_recovery_link_request: UserRecoveryLinkRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_recovery_create_serialize( + id=id, + user_recovery_link_request=user_recovery_link_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Link", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_recovery_create_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_recovery_link_request: Optional[UserRecoveryLinkRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_recovery_create + + Create a temporary link that a user can use to recover their account + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_recovery_link_request: + :type user_recovery_link_request: UserRecoveryLinkRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_recovery_create_serialize( + id=id, + user_recovery_link_request=user_recovery_link_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Link", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_recovery_create_serialize( + self, + id, + user_recovery_link_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_recovery_link_request is not None: + _body_params = user_recovery_link_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/users/{id}/recovery/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_recovery_email_create( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_recovery_email_request: UserRecoveryEmailRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_users_recovery_email_create + + Send an email with a temporary link that a user can use to recover their account + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_recovery_email_request: (required) + :type user_recovery_email_request: UserRecoveryEmailRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_recovery_email_create_serialize( + id=id, + user_recovery_email_request=user_recovery_email_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_recovery_email_create_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_recovery_email_request: UserRecoveryEmailRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_users_recovery_email_create + + Send an email with a temporary link that a user can use to recover their account + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_recovery_email_request: (required) + :type user_recovery_email_request: UserRecoveryEmailRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_recovery_email_create_serialize( + id=id, + user_recovery_email_request=user_recovery_email_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_recovery_email_create_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_recovery_email_request: UserRecoveryEmailRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_recovery_email_create + + Send an email with a temporary link that a user can use to recover their account + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_recovery_email_request: (required) + :type user_recovery_email_request: UserRecoveryEmailRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_recovery_email_create_serialize( + id=id, + user_recovery_email_request=user_recovery_email_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_recovery_email_create_serialize( + self, + id, + user_recovery_email_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_recovery_email_request is not None: + _body_params = user_recovery_email_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/users/{id}/recovery_email/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> User: + """core_users_retrieve + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[User]: + """core_users_retrieve + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_retrieve + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_service_account_create( + self, + user_service_account_request: UserServiceAccountRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserServiceAccountResponse: + """core_users_service_account_create + + Create a new user account that is marked as a service account + + :param user_service_account_request: (required) + :type user_service_account_request: UserServiceAccountRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_service_account_create_serialize( + user_service_account_request=user_service_account_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserServiceAccountResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_service_account_create_with_http_info( + self, + user_service_account_request: UserServiceAccountRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserServiceAccountResponse]: + """core_users_service_account_create + + Create a new user account that is marked as a service account + + :param user_service_account_request: (required) + :type user_service_account_request: UserServiceAccountRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_service_account_create_serialize( + user_service_account_request=user_service_account_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserServiceAccountResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_service_account_create_without_preload_content( + self, + user_service_account_request: UserServiceAccountRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_service_account_create + + Create a new user account that is marked as a service account + + :param user_service_account_request: (required) + :type user_service_account_request: UserServiceAccountRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_service_account_create_serialize( + user_service_account_request=user_service_account_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserServiceAccountResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_service_account_create_serialize( + self, + user_service_account_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_service_account_request is not None: + _body_params = user_service_account_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/users/service_account/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_set_password_create( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_password_set_request: UserPasswordSetRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_users_set_password_create + + Set password for user + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_password_set_request: (required) + :type user_password_set_request: UserPasswordSetRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_set_password_create_serialize( + id=id, + user_password_set_request=user_password_set_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_set_password_create_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_password_set_request: UserPasswordSetRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_users_set_password_create + + Set password for user + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_password_set_request: (required) + :type user_password_set_request: UserPasswordSetRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_set_password_create_serialize( + id=id, + user_password_set_request=user_password_set_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_set_password_create_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_password_set_request: UserPasswordSetRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_set_password_create + + Set password for user + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_password_set_request: (required) + :type user_password_set_request: UserPasswordSetRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_set_password_create_serialize( + id=id, + user_password_set_request=user_password_set_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_set_password_create_serialize( + self, + id, + user_password_set_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_password_set_request is not None: + _body_params = user_password_set_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/users/{id}/set_password/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_set_password_hash_create( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_password_hash_set_request: UserPasswordHashSetRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """core_users_set_password_hash_create + + Set a user's password from a pre-hashed Django password value. Submit the Django password hash in the shared ``password`` request field. This updates authentik's local password verifier only. It does not attempt to propagate the password change to LDAP or Kerberos because no raw password is available from the request payload. + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_password_hash_set_request: (required) + :type user_password_hash_set_request: UserPasswordHashSetRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_set_password_hash_create_serialize( + id=id, + user_password_hash_set_request=user_password_hash_set_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_set_password_hash_create_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_password_hash_set_request: UserPasswordHashSetRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """core_users_set_password_hash_create + + Set a user's password from a pre-hashed Django password value. Submit the Django password hash in the shared ``password`` request field. This updates authentik's local password verifier only. It does not attempt to propagate the password change to LDAP or Kerberos because no raw password is available from the request payload. + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_password_hash_set_request: (required) + :type user_password_hash_set_request: UserPasswordHashSetRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_set_password_hash_create_serialize( + id=id, + user_password_hash_set_request=user_password_hash_set_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_set_password_hash_create_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_password_hash_set_request: UserPasswordHashSetRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_set_password_hash_create + + Set a user's password from a pre-hashed Django password value. Submit the Django password hash in the shared ``password`` request field. This updates authentik's local password verifier only. It does not attempt to propagate the password change to LDAP or Kerberos because no raw password is available from the request payload. + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_password_hash_set_request: (required) + :type user_password_hash_set_request: UserPasswordHashSetRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_set_password_hash_create_serialize( + id=id, + user_password_hash_set_request=user_password_hash_set_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_set_password_hash_create_serialize( + self, + id, + user_password_hash_set_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_password_hash_set_request is not None: + _body_params = user_password_hash_set_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/core/users/{id}/set_password_hash/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_request: UserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> User: + """core_users_update + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_request: (required) + :type user_request: UserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_update_serialize( + id=id, + user_request=user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_request: UserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[User]: + """core_users_update + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_request: (required) + :type user_request: UserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_update_serialize( + id=id, + user_request=user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + user_request: UserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_update + + User Viewset + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param user_request: (required) + :type user_request: UserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_update_serialize( + id=id, + user_request=user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "User", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_update_serialize( + self, + id, + user_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_request is not None: + _body_params = user_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/core/users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def core_users_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """core_users_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def core_users_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """core_users_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def core_users_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """core_users_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._core_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _core_users_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik', + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/core/users/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/crypto_api.py b/authentik_client/api/crypto_api.py new file mode 100644 index 000000000..680f58e92 --- /dev/null +++ b/authentik_client/api/crypto_api.py @@ -0,0 +1,2955 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.certificate_data import CertificateData +from authentik_client.models.certificate_generation_request import CertificateGenerationRequest +from authentik_client.models.certificate_key_pair import CertificateKeyPair +from authentik_client.models.certificate_key_pair_request import CertificateKeyPairRequest +from authentik_client.models.key_type_enum import KeyTypeEnum +from authentik_client.models.paginated_certificate_key_pair_list import PaginatedCertificateKeyPairList +from authentik_client.models.patched_certificate_key_pair_request import PatchedCertificateKeyPairRequest +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class CryptoApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def crypto_certificatekeypairs_create( + self, + certificate_key_pair_request: CertificateKeyPairRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CertificateKeyPair: + """crypto_certificatekeypairs_create + + CertificateKeyPair Viewset + + :param certificate_key_pair_request: (required) + :type certificate_key_pair_request: CertificateKeyPairRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_create_serialize( + certificate_key_pair_request=certificate_key_pair_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_create_with_http_info( + self, + certificate_key_pair_request: CertificateKeyPairRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CertificateKeyPair]: + """crypto_certificatekeypairs_create + + CertificateKeyPair Viewset + + :param certificate_key_pair_request: (required) + :type certificate_key_pair_request: CertificateKeyPairRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_create_serialize( + certificate_key_pair_request=certificate_key_pair_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_create_without_preload_content( + self, + certificate_key_pair_request: CertificateKeyPairRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_create + + CertificateKeyPair Viewset + + :param certificate_key_pair_request: (required) + :type certificate_key_pair_request: CertificateKeyPairRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_create_serialize( + certificate_key_pair_request=certificate_key_pair_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_create_serialize( + self, + certificate_key_pair_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if certificate_key_pair_request is not None: + _body_params = certificate_key_pair_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/crypto/certificatekeypairs/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def crypto_certificatekeypairs_destroy( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """crypto_certificatekeypairs_destroy + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_destroy_serialize( + kp_uuid=kp_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_destroy_with_http_info( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """crypto_certificatekeypairs_destroy + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_destroy_serialize( + kp_uuid=kp_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_destroy_without_preload_content( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_destroy + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_destroy_serialize( + kp_uuid=kp_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_destroy_serialize( + self, + kp_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if kp_uuid is not None: + _path_params['kp_uuid'] = kp_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/crypto/certificatekeypairs/{kp_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def crypto_certificatekeypairs_generate_create( + self, + certificate_generation_request: CertificateGenerationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CertificateKeyPair: + """crypto_certificatekeypairs_generate_create + + Generate a new, self-signed certificate-key pair + + :param certificate_generation_request: (required) + :type certificate_generation_request: CertificateGenerationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_generate_create_serialize( + certificate_generation_request=certificate_generation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_generate_create_with_http_info( + self, + certificate_generation_request: CertificateGenerationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CertificateKeyPair]: + """crypto_certificatekeypairs_generate_create + + Generate a new, self-signed certificate-key pair + + :param certificate_generation_request: (required) + :type certificate_generation_request: CertificateGenerationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_generate_create_serialize( + certificate_generation_request=certificate_generation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_generate_create_without_preload_content( + self, + certificate_generation_request: CertificateGenerationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_generate_create + + Generate a new, self-signed certificate-key pair + + :param certificate_generation_request: (required) + :type certificate_generation_request: CertificateGenerationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_generate_create_serialize( + certificate_generation_request=certificate_generation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_generate_create_serialize( + self, + certificate_generation_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if certificate_generation_request is not None: + _body_params = certificate_generation_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/crypto/certificatekeypairs/generate/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def crypto_certificatekeypairs_list( + self, + has_key: Annotated[Optional[StrictBool], Field(description="Only return certificate-key pairs with keys")] = None, + key_type: Optional[List[KeyTypeEnum]] = None, + managed: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedCertificateKeyPairList: + """crypto_certificatekeypairs_list + + CertificateKeyPair Viewset + + :param has_key: Only return certificate-key pairs with keys + :type has_key: bool + :param key_type: + :type key_type: List[KeyTypeEnum] + :param managed: + :type managed: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_list_serialize( + has_key=has_key, + key_type=key_type, + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedCertificateKeyPairList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_list_with_http_info( + self, + has_key: Annotated[Optional[StrictBool], Field(description="Only return certificate-key pairs with keys")] = None, + key_type: Optional[List[KeyTypeEnum]] = None, + managed: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedCertificateKeyPairList]: + """crypto_certificatekeypairs_list + + CertificateKeyPair Viewset + + :param has_key: Only return certificate-key pairs with keys + :type has_key: bool + :param key_type: + :type key_type: List[KeyTypeEnum] + :param managed: + :type managed: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_list_serialize( + has_key=has_key, + key_type=key_type, + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedCertificateKeyPairList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_list_without_preload_content( + self, + has_key: Annotated[Optional[StrictBool], Field(description="Only return certificate-key pairs with keys")] = None, + key_type: Optional[List[KeyTypeEnum]] = None, + managed: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_list + + CertificateKeyPair Viewset + + :param has_key: Only return certificate-key pairs with keys + :type has_key: bool + :param key_type: + :type key_type: List[KeyTypeEnum] + :param managed: + :type managed: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_list_serialize( + has_key=has_key, + key_type=key_type, + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedCertificateKeyPairList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_list_serialize( + self, + has_key, + key_type, + managed, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'key_type': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if has_key is not None: + + _query_params.append(('has_key', has_key)) + + if key_type is not None: + + _query_params.append(('key_type', key_type)) + + if managed is not None: + + _query_params.append(('managed', managed)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/crypto/certificatekeypairs/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def crypto_certificatekeypairs_partial_update( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + patched_certificate_key_pair_request: Optional[PatchedCertificateKeyPairRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CertificateKeyPair: + """crypto_certificatekeypairs_partial_update + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param patched_certificate_key_pair_request: + :type patched_certificate_key_pair_request: PatchedCertificateKeyPairRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_partial_update_serialize( + kp_uuid=kp_uuid, + patched_certificate_key_pair_request=patched_certificate_key_pair_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_partial_update_with_http_info( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + patched_certificate_key_pair_request: Optional[PatchedCertificateKeyPairRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CertificateKeyPair]: + """crypto_certificatekeypairs_partial_update + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param patched_certificate_key_pair_request: + :type patched_certificate_key_pair_request: PatchedCertificateKeyPairRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_partial_update_serialize( + kp_uuid=kp_uuid, + patched_certificate_key_pair_request=patched_certificate_key_pair_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_partial_update_without_preload_content( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + patched_certificate_key_pair_request: Optional[PatchedCertificateKeyPairRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_partial_update + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param patched_certificate_key_pair_request: + :type patched_certificate_key_pair_request: PatchedCertificateKeyPairRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_partial_update_serialize( + kp_uuid=kp_uuid, + patched_certificate_key_pair_request=patched_certificate_key_pair_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_partial_update_serialize( + self, + kp_uuid, + patched_certificate_key_pair_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if kp_uuid is not None: + _path_params['kp_uuid'] = kp_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_certificate_key_pair_request is not None: + _body_params = patched_certificate_key_pair_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/crypto/certificatekeypairs/{kp_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def crypto_certificatekeypairs_retrieve( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CertificateKeyPair: + """crypto_certificatekeypairs_retrieve + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_retrieve_serialize( + kp_uuid=kp_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_retrieve_with_http_info( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CertificateKeyPair]: + """crypto_certificatekeypairs_retrieve + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_retrieve_serialize( + kp_uuid=kp_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_retrieve_without_preload_content( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_retrieve + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_retrieve_serialize( + kp_uuid=kp_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_retrieve_serialize( + self, + kp_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if kp_uuid is not None: + _path_params['kp_uuid'] = kp_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/crypto/certificatekeypairs/{kp_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def crypto_certificatekeypairs_update( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + certificate_key_pair_request: CertificateKeyPairRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CertificateKeyPair: + """crypto_certificatekeypairs_update + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param certificate_key_pair_request: (required) + :type certificate_key_pair_request: CertificateKeyPairRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_update_serialize( + kp_uuid=kp_uuid, + certificate_key_pair_request=certificate_key_pair_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_update_with_http_info( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + certificate_key_pair_request: CertificateKeyPairRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CertificateKeyPair]: + """crypto_certificatekeypairs_update + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param certificate_key_pair_request: (required) + :type certificate_key_pair_request: CertificateKeyPairRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_update_serialize( + kp_uuid=kp_uuid, + certificate_key_pair_request=certificate_key_pair_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_update_without_preload_content( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + certificate_key_pair_request: CertificateKeyPairRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_update + + CertificateKeyPair Viewset + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param certificate_key_pair_request: (required) + :type certificate_key_pair_request: CertificateKeyPairRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_update_serialize( + kp_uuid=kp_uuid, + certificate_key_pair_request=certificate_key_pair_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateKeyPair", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_update_serialize( + self, + kp_uuid, + certificate_key_pair_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if kp_uuid is not None: + _path_params['kp_uuid'] = kp_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if certificate_key_pair_request is not None: + _body_params = certificate_key_pair_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/crypto/certificatekeypairs/{kp_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def crypto_certificatekeypairs_used_by_list( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """crypto_certificatekeypairs_used_by_list + + Get a list of all objects that use this object + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_used_by_list_serialize( + kp_uuid=kp_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_used_by_list_with_http_info( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """crypto_certificatekeypairs_used_by_list + + Get a list of all objects that use this object + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_used_by_list_serialize( + kp_uuid=kp_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_used_by_list_without_preload_content( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_used_by_list + + Get a list of all objects that use this object + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_used_by_list_serialize( + kp_uuid=kp_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_used_by_list_serialize( + self, + kp_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if kp_uuid is not None: + _path_params['kp_uuid'] = kp_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/crypto/certificatekeypairs/{kp_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def crypto_certificatekeypairs_view_certificate_retrieve( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + download: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CertificateData: + """crypto_certificatekeypairs_view_certificate_retrieve + + Return certificate-key pairs certificate and log access + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param download: + :type download: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_view_certificate_retrieve_serialize( + kp_uuid=kp_uuid, + download=download, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateData", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_view_certificate_retrieve_with_http_info( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + download: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CertificateData]: + """crypto_certificatekeypairs_view_certificate_retrieve + + Return certificate-key pairs certificate and log access + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param download: + :type download: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_view_certificate_retrieve_serialize( + kp_uuid=kp_uuid, + download=download, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateData", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_view_certificate_retrieve_without_preload_content( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + download: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_view_certificate_retrieve + + Return certificate-key pairs certificate and log access + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param download: + :type download: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_view_certificate_retrieve_serialize( + kp_uuid=kp_uuid, + download=download, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateData", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_view_certificate_retrieve_serialize( + self, + kp_uuid, + download, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if kp_uuid is not None: + _path_params['kp_uuid'] = kp_uuid + # process the query parameters + if download is not None: + + _query_params.append(('download', download)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/crypto/certificatekeypairs/{kp_uuid}/view_certificate/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def crypto_certificatekeypairs_view_private_key_retrieve( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + download: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CertificateData: + """crypto_certificatekeypairs_view_private_key_retrieve + + Return certificate-key pairs private key and log access + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param download: + :type download: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_view_private_key_retrieve_serialize( + kp_uuid=kp_uuid, + download=download, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateData", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def crypto_certificatekeypairs_view_private_key_retrieve_with_http_info( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + download: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CertificateData]: + """crypto_certificatekeypairs_view_private_key_retrieve + + Return certificate-key pairs private key and log access + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param download: + :type download: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_view_private_key_retrieve_serialize( + kp_uuid=kp_uuid, + download=download, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateData", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def crypto_certificatekeypairs_view_private_key_retrieve_without_preload_content( + self, + kp_uuid: Annotated[UUID, Field(description="A UUID string identifying this Certificate-Key Pair.")], + download: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """crypto_certificatekeypairs_view_private_key_retrieve + + Return certificate-key pairs private key and log access + + :param kp_uuid: A UUID string identifying this Certificate-Key Pair. (required) + :type kp_uuid: UUID + :param download: + :type download: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._crypto_certificatekeypairs_view_private_key_retrieve_serialize( + kp_uuid=kp_uuid, + download=download, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CertificateData", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _crypto_certificatekeypairs_view_private_key_retrieve_serialize( + self, + kp_uuid, + download, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if kp_uuid is not None: + _path_params['kp_uuid'] = kp_uuid + # process the query parameters + if download is not None: + + _query_params.append(('download', download)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/crypto/certificatekeypairs/{kp_uuid}/view_private_key/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/endpoints_api.py b/authentik_client/api/endpoints_api.py new file mode 100644 index 000000000..bf177fc83 --- /dev/null +++ b/authentik_client/api/endpoints_api.py @@ -0,0 +1,20141 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.agent_authentication_response import AgentAuthenticationResponse +from authentik_client.models.agent_config import AgentConfig +from authentik_client.models.agent_connector import AgentConnector +from authentik_client.models.agent_connector_request import AgentConnectorRequest +from authentik_client.models.agent_psso_device_registration_request import AgentPSSODeviceRegistrationRequest +from authentik_client.models.agent_psso_device_registration_response import AgentPSSODeviceRegistrationResponse +from authentik_client.models.agent_psso_user_registration_request import AgentPSSOUserRegistrationRequest +from authentik_client.models.agent_token_response import AgentTokenResponse +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave +from authentik_client.models.apple_independent_secure_enclave_request import AppleIndependentSecureEnclaveRequest +from authentik_client.models.connector import Connector +from authentik_client.models.device_access_group import DeviceAccessGroup +from authentik_client.models.device_access_group_request import DeviceAccessGroupRequest +from authentik_client.models.device_facts_request import DeviceFactsRequest +from authentik_client.models.device_summary import DeviceSummary +from authentik_client.models.device_user_binding import DeviceUserBinding +from authentik_client.models.device_user_binding_request import DeviceUserBindingRequest +from authentik_client.models.endpoint_device import EndpointDevice +from authentik_client.models.endpoint_device_details import EndpointDeviceDetails +from authentik_client.models.endpoint_device_request import EndpointDeviceRequest +from authentik_client.models.enroll_request import EnrollRequest +from authentik_client.models.enrollment_token import EnrollmentToken +from authentik_client.models.enrollment_token_request import EnrollmentTokenRequest +from authentik_client.models.fleet_connector import FleetConnector +from authentik_client.models.fleet_connector_request import FleetConnectorRequest +from authentik_client.models.google_chrome_connector import GoogleChromeConnector +from authentik_client.models.google_chrome_connector_request import GoogleChromeConnectorRequest +from authentik_client.models.mdm_config_request import MDMConfigRequest +from authentik_client.models.mdm_config_response import MDMConfigResponse +from authentik_client.models.paginated_agent_connector_list import PaginatedAgentConnectorList +from authentik_client.models.paginated_apple_independent_secure_enclave_list import PaginatedAppleIndependentSecureEnclaveList +from authentik_client.models.paginated_connector_list import PaginatedConnectorList +from authentik_client.models.paginated_device_access_group_list import PaginatedDeviceAccessGroupList +from authentik_client.models.paginated_device_user_binding_list import PaginatedDeviceUserBindingList +from authentik_client.models.paginated_endpoint_device_list import PaginatedEndpointDeviceList +from authentik_client.models.paginated_enrollment_token_list import PaginatedEnrollmentTokenList +from authentik_client.models.paginated_fleet_connector_list import PaginatedFleetConnectorList +from authentik_client.models.paginated_google_chrome_connector_list import PaginatedGoogleChromeConnectorList +from authentik_client.models.patched_agent_connector_request import PatchedAgentConnectorRequest +from authentik_client.models.patched_apple_independent_secure_enclave_request import PatchedAppleIndependentSecureEnclaveRequest +from authentik_client.models.patched_device_access_group_request import PatchedDeviceAccessGroupRequest +from authentik_client.models.patched_device_user_binding_request import PatchedDeviceUserBindingRequest +from authentik_client.models.patched_endpoint_device_request import PatchedEndpointDeviceRequest +from authentik_client.models.patched_enrollment_token_request import PatchedEnrollmentTokenRequest +from authentik_client.models.patched_fleet_connector_request import PatchedFleetConnectorRequest +from authentik_client.models.patched_google_chrome_connector_request import PatchedGoogleChromeConnectorRequest +from authentik_client.models.token_view import TokenView +from authentik_client.models.type_create import TypeCreate +from authentik_client.models.used_by import UsedBy +from authentik_client.models.user_self import UserSelf + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class EndpointsApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def endpoints_agents_connectors_agent_config_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AgentConfig: + """endpoints_agents_connectors_agent_config_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_agent_config_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConfig", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_agent_config_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AgentConfig]: + """endpoints_agents_connectors_agent_config_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_agent_config_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConfig", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_agent_config_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_agent_config_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_agent_config_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConfig", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_agent_config_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/connectors/agent_config/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_auth_fed_create( + self, + device: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AgentTokenResponse: + """endpoints_agents_connectors_auth_fed_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device: (required) + :type device: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_auth_fed_create_serialize( + device=device, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentTokenResponse", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_auth_fed_create_with_http_info( + self, + device: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AgentTokenResponse]: + """endpoints_agents_connectors_auth_fed_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device: (required) + :type device: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_auth_fed_create_serialize( + device=device, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentTokenResponse", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_auth_fed_create_without_preload_content( + self, + device: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_auth_fed_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device: (required) + :type device: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_auth_fed_create_serialize( + device=device, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentTokenResponse", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_auth_fed_create_serialize( + self, + device, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if device is not None: + + _query_params.append(('device', device)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik_device_federation' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/connectors/auth_fed/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_auth_ia_create( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AgentAuthenticationResponse: + """endpoints_agents_connectors_auth_ia_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_auth_ia_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentAuthenticationResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_auth_ia_create_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AgentAuthenticationResponse]: + """endpoints_agents_connectors_auth_ia_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_auth_ia_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentAuthenticationResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_auth_ia_create_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_auth_ia_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_auth_ia_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentAuthenticationResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_auth_ia_create_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/connectors/auth_ia/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_check_in_create( + self, + device_facts_request: Optional[DeviceFactsRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_agents_connectors_check_in_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_facts_request: + :type device_facts_request: DeviceFactsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_check_in_create_serialize( + device_facts_request=device_facts_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_check_in_create_with_http_info( + self, + device_facts_request: Optional[DeviceFactsRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_agents_connectors_check_in_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_facts_request: + :type device_facts_request: DeviceFactsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_check_in_create_serialize( + device_facts_request=device_facts_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_check_in_create_without_preload_content( + self, + device_facts_request: Optional[DeviceFactsRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_check_in_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_facts_request: + :type device_facts_request: DeviceFactsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_check_in_create_serialize( + device_facts_request=device_facts_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_check_in_create_serialize( + self, + device_facts_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if device_facts_request is not None: + _body_params = device_facts_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/connectors/check_in/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_create( + self, + agent_connector_request: AgentConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AgentConnector: + """endpoints_agents_connectors_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param agent_connector_request: (required) + :type agent_connector_request: AgentConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_create_serialize( + agent_connector_request=agent_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_create_with_http_info( + self, + agent_connector_request: AgentConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AgentConnector]: + """endpoints_agents_connectors_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param agent_connector_request: (required) + :type agent_connector_request: AgentConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_create_serialize( + agent_connector_request=agent_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_create_without_preload_content( + self, + agent_connector_request: AgentConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param agent_connector_request: (required) + :type agent_connector_request: AgentConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_create_serialize( + agent_connector_request=agent_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_create_serialize( + self, + agent_connector_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if agent_connector_request is not None: + _body_params = agent_connector_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/connectors/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_destroy( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_agents_connectors_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_destroy_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_agents_connectors_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_destroy_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_destroy_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/endpoints/agents/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_enroll_create( + self, + enroll_request: EnrollRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AgentTokenResponse: + """endpoints_agents_connectors_enroll_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param enroll_request: (required) + :type enroll_request: EnrollRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_enroll_create_serialize( + enroll_request=enroll_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentTokenResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_enroll_create_with_http_info( + self, + enroll_request: EnrollRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AgentTokenResponse]: + """endpoints_agents_connectors_enroll_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param enroll_request: (required) + :type enroll_request: EnrollRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_enroll_create_serialize( + enroll_request=enroll_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentTokenResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_enroll_create_without_preload_content( + self, + enroll_request: EnrollRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_enroll_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param enroll_request: (required) + :type enroll_request: EnrollRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_enroll_create_serialize( + enroll_request=enroll_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentTokenResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_enroll_create_serialize( + self, + enroll_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if enroll_request is not None: + _body_params = enroll_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik_device_enroll' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/connectors/enroll/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_list( + self, + enabled: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAgentConnectorList: + """endpoints_agents_connectors_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param enabled: + :type enabled: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_list_serialize( + enabled=enabled, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAgentConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_list_with_http_info( + self, + enabled: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAgentConnectorList]: + """endpoints_agents_connectors_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param enabled: + :type enabled: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_list_serialize( + enabled=enabled, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAgentConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_list_without_preload_content( + self, + enabled: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param enabled: + :type enabled: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_list_serialize( + enabled=enabled, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAgentConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_list_serialize( + self, + enabled, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if enabled is not None: + + _query_params.append(('enabled', enabled)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/connectors/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_mdm_config_create( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + mdm_config_request: MDMConfigRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MDMConfigResponse: + """endpoints_agents_connectors_mdm_config_create + + Generate configuration for MDM systems to deploy authentik Agent + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param mdm_config_request: (required) + :type mdm_config_request: MDMConfigRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_mdm_config_create_serialize( + connector_uuid=connector_uuid, + mdm_config_request=mdm_config_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MDMConfigResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_mdm_config_create_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + mdm_config_request: MDMConfigRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MDMConfigResponse]: + """endpoints_agents_connectors_mdm_config_create + + Generate configuration for MDM systems to deploy authentik Agent + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param mdm_config_request: (required) + :type mdm_config_request: MDMConfigRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_mdm_config_create_serialize( + connector_uuid=connector_uuid, + mdm_config_request=mdm_config_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MDMConfigResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_mdm_config_create_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + mdm_config_request: MDMConfigRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_mdm_config_create + + Generate configuration for MDM systems to deploy authentik Agent + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param mdm_config_request: (required) + :type mdm_config_request: MDMConfigRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_mdm_config_create_serialize( + connector_uuid=connector_uuid, + mdm_config_request=mdm_config_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MDMConfigResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_mdm_config_create_serialize( + self, + connector_uuid, + mdm_config_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if mdm_config_request is not None: + _body_params = mdm_config_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/connectors/{connector_uuid}/mdm_config/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_partial_update( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + patched_agent_connector_request: Optional[PatchedAgentConnectorRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AgentConnector: + """endpoints_agents_connectors_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param patched_agent_connector_request: + :type patched_agent_connector_request: PatchedAgentConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_partial_update_serialize( + connector_uuid=connector_uuid, + patched_agent_connector_request=patched_agent_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_partial_update_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + patched_agent_connector_request: Optional[PatchedAgentConnectorRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AgentConnector]: + """endpoints_agents_connectors_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param patched_agent_connector_request: + :type patched_agent_connector_request: PatchedAgentConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_partial_update_serialize( + connector_uuid=connector_uuid, + patched_agent_connector_request=patched_agent_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_partial_update_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + patched_agent_connector_request: Optional[PatchedAgentConnectorRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param patched_agent_connector_request: + :type patched_agent_connector_request: PatchedAgentConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_partial_update_serialize( + connector_uuid=connector_uuid, + patched_agent_connector_request=patched_agent_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_partial_update_serialize( + self, + connector_uuid, + patched_agent_connector_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_agent_connector_request is not None: + _body_params = patched_agent_connector_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/endpoints/agents/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_retrieve( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AgentConnector: + """endpoints_agents_connectors_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_retrieve_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AgentConnector]: + """endpoints_agents_connectors_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_retrieve_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_retrieve_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_update( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + agent_connector_request: AgentConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AgentConnector: + """endpoints_agents_connectors_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param agent_connector_request: (required) + :type agent_connector_request: AgentConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_update_serialize( + connector_uuid=connector_uuid, + agent_connector_request=agent_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_update_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + agent_connector_request: AgentConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AgentConnector]: + """endpoints_agents_connectors_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param agent_connector_request: (required) + :type agent_connector_request: AgentConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_update_serialize( + connector_uuid=connector_uuid, + agent_connector_request=agent_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_update_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + agent_connector_request: AgentConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param agent_connector_request: (required) + :type agent_connector_request: AgentConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_update_serialize( + connector_uuid=connector_uuid, + agent_connector_request=agent_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_update_serialize( + self, + connector_uuid, + agent_connector_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if agent_connector_request is not None: + _body_params = agent_connector_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/endpoints/agents/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_connectors_used_by_list( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """endpoints_agents_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_connectors_used_by_list_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """endpoints_agents_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_connectors_used_by_list_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Agent Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this Agent Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_connectors_used_by_list_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/connectors/{connector_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_enrollment_tokens_create( + self, + enrollment_token_request: EnrollmentTokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EnrollmentToken: + """endpoints_agents_enrollment_tokens_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param enrollment_token_request: (required) + :type enrollment_token_request: EnrollmentTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_create_serialize( + enrollment_token_request=enrollment_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_enrollment_tokens_create_with_http_info( + self, + enrollment_token_request: EnrollmentTokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EnrollmentToken]: + """endpoints_agents_enrollment_tokens_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param enrollment_token_request: (required) + :type enrollment_token_request: EnrollmentTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_create_serialize( + enrollment_token_request=enrollment_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_enrollment_tokens_create_without_preload_content( + self, + enrollment_token_request: EnrollmentTokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_enrollment_tokens_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param enrollment_token_request: (required) + :type enrollment_token_request: EnrollmentTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_create_serialize( + enrollment_token_request=enrollment_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_enrollment_tokens_create_serialize( + self, + enrollment_token_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if enrollment_token_request is not None: + _body_params = enrollment_token_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/enrollment_tokens/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_enrollment_tokens_destroy( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_agents_enrollment_tokens_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_destroy_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_enrollment_tokens_destroy_with_http_info( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_agents_enrollment_tokens_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_destroy_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_enrollment_tokens_destroy_without_preload_content( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_enrollment_tokens_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_destroy_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_enrollment_tokens_destroy_serialize( + self, + token_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if token_uuid is not None: + _path_params['token_uuid'] = token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/endpoints/agents/enrollment_tokens/{token_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_enrollment_tokens_list( + self, + connector: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + token_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedEnrollmentTokenList: + """endpoints_agents_enrollment_tokens_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector: + :type connector: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param token_uuid: + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_list_serialize( + connector=connector, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEnrollmentTokenList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_enrollment_tokens_list_with_http_info( + self, + connector: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + token_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedEnrollmentTokenList]: + """endpoints_agents_enrollment_tokens_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector: + :type connector: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param token_uuid: + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_list_serialize( + connector=connector, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEnrollmentTokenList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_enrollment_tokens_list_without_preload_content( + self, + connector: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + token_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_enrollment_tokens_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param connector: + :type connector: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param token_uuid: + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_list_serialize( + connector=connector, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEnrollmentTokenList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_enrollment_tokens_list_serialize( + self, + connector, + ordering, + page, + page_size, + search, + token_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if connector is not None: + + _query_params.append(('connector', connector)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if token_uuid is not None: + + _query_params.append(('token_uuid', token_uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/enrollment_tokens/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_enrollment_tokens_partial_update( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + patched_enrollment_token_request: Optional[PatchedEnrollmentTokenRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EnrollmentToken: + """endpoints_agents_enrollment_tokens_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param patched_enrollment_token_request: + :type patched_enrollment_token_request: PatchedEnrollmentTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_partial_update_serialize( + token_uuid=token_uuid, + patched_enrollment_token_request=patched_enrollment_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_enrollment_tokens_partial_update_with_http_info( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + patched_enrollment_token_request: Optional[PatchedEnrollmentTokenRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EnrollmentToken]: + """endpoints_agents_enrollment_tokens_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param patched_enrollment_token_request: + :type patched_enrollment_token_request: PatchedEnrollmentTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_partial_update_serialize( + token_uuid=token_uuid, + patched_enrollment_token_request=patched_enrollment_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_enrollment_tokens_partial_update_without_preload_content( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + patched_enrollment_token_request: Optional[PatchedEnrollmentTokenRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_enrollment_tokens_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param patched_enrollment_token_request: + :type patched_enrollment_token_request: PatchedEnrollmentTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_partial_update_serialize( + token_uuid=token_uuid, + patched_enrollment_token_request=patched_enrollment_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_enrollment_tokens_partial_update_serialize( + self, + token_uuid, + patched_enrollment_token_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if token_uuid is not None: + _path_params['token_uuid'] = token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_enrollment_token_request is not None: + _body_params = patched_enrollment_token_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/endpoints/agents/enrollment_tokens/{token_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_enrollment_tokens_retrieve( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EnrollmentToken: + """endpoints_agents_enrollment_tokens_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_retrieve_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_enrollment_tokens_retrieve_with_http_info( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EnrollmentToken]: + """endpoints_agents_enrollment_tokens_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_retrieve_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_enrollment_tokens_retrieve_without_preload_content( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_enrollment_tokens_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_retrieve_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_enrollment_tokens_retrieve_serialize( + self, + token_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if token_uuid is not None: + _path_params['token_uuid'] = token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/enrollment_tokens/{token_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_enrollment_tokens_update( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + enrollment_token_request: EnrollmentTokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EnrollmentToken: + """endpoints_agents_enrollment_tokens_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param enrollment_token_request: (required) + :type enrollment_token_request: EnrollmentTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_update_serialize( + token_uuid=token_uuid, + enrollment_token_request=enrollment_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_enrollment_tokens_update_with_http_info( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + enrollment_token_request: EnrollmentTokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EnrollmentToken]: + """endpoints_agents_enrollment_tokens_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param enrollment_token_request: (required) + :type enrollment_token_request: EnrollmentTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_update_serialize( + token_uuid=token_uuid, + enrollment_token_request=enrollment_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_enrollment_tokens_update_without_preload_content( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + enrollment_token_request: EnrollmentTokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_enrollment_tokens_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param enrollment_token_request: (required) + :type enrollment_token_request: EnrollmentTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_update_serialize( + token_uuid=token_uuid, + enrollment_token_request=enrollment_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EnrollmentToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_enrollment_tokens_update_serialize( + self, + token_uuid, + enrollment_token_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if token_uuid is not None: + _path_params['token_uuid'] = token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if enrollment_token_request is not None: + _body_params = enrollment_token_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/endpoints/agents/enrollment_tokens/{token_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_enrollment_tokens_used_by_list( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """endpoints_agents_enrollment_tokens_used_by_list + + Get a list of all objects that use this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_used_by_list_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_enrollment_tokens_used_by_list_with_http_info( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """endpoints_agents_enrollment_tokens_used_by_list + + Get a list of all objects that use this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_used_by_list_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_enrollment_tokens_used_by_list_without_preload_content( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_enrollment_tokens_used_by_list + + Get a list of all objects that use this object + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_used_by_list_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_enrollment_tokens_used_by_list_serialize( + self, + token_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if token_uuid is not None: + _path_params['token_uuid'] = token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/enrollment_tokens/{token_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_enrollment_tokens_view_key_retrieve( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TokenView: + """endpoints_agents_enrollment_tokens_view_key_retrieve + + Return token key and log access + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_view_key_retrieve_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenView", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_enrollment_tokens_view_key_retrieve_with_http_info( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TokenView]: + """endpoints_agents_enrollment_tokens_view_key_retrieve + + Return token key and log access + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_view_key_retrieve_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenView", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_enrollment_tokens_view_key_retrieve_without_preload_content( + self, + token_uuid: Annotated[UUID, Field(description="A UUID string identifying this Enrollment Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_enrollment_tokens_view_key_retrieve + + Return token key and log access + + :param token_uuid: A UUID string identifying this Enrollment Token. (required) + :type token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_enrollment_tokens_view_key_retrieve_serialize( + token_uuid=token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenView", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_enrollment_tokens_view_key_retrieve_serialize( + self, + token_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if token_uuid is not None: + _path_params['token_uuid'] = token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/enrollment_tokens/{token_uuid}/view_key/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_psso_ise_create( + self, + apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AppleIndependentSecureEnclave: + """endpoints_agents_psso_ise_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param apple_independent_secure_enclave_request: (required) + :type apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_create_serialize( + apple_independent_secure_enclave_request=apple_independent_secure_enclave_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_psso_ise_create_with_http_info( + self, + apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AppleIndependentSecureEnclave]: + """endpoints_agents_psso_ise_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param apple_independent_secure_enclave_request: (required) + :type apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_create_serialize( + apple_independent_secure_enclave_request=apple_independent_secure_enclave_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_psso_ise_create_without_preload_content( + self, + apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_psso_ise_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param apple_independent_secure_enclave_request: (required) + :type apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_create_serialize( + apple_independent_secure_enclave_request=apple_independent_secure_enclave_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_psso_ise_create_serialize( + self, + apple_independent_secure_enclave_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if apple_independent_secure_enclave_request is not None: + _body_params = apple_independent_secure_enclave_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/psso/ise/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_psso_ise_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_agents_psso_ise_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_psso_ise_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_agents_psso_ise_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_psso_ise_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_psso_ise_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_psso_ise_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/endpoints/agents/psso/ise/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_psso_ise_list( + self, + apple_enclave_key_id: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAppleIndependentSecureEnclaveList: + """endpoints_agents_psso_ise_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param apple_enclave_key_id: + :type apple_enclave_key_id: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_list_serialize( + apple_enclave_key_id=apple_enclave_key_id, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAppleIndependentSecureEnclaveList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_psso_ise_list_with_http_info( + self, + apple_enclave_key_id: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAppleIndependentSecureEnclaveList]: + """endpoints_agents_psso_ise_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param apple_enclave_key_id: + :type apple_enclave_key_id: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_list_serialize( + apple_enclave_key_id=apple_enclave_key_id, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAppleIndependentSecureEnclaveList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_psso_ise_list_without_preload_content( + self, + apple_enclave_key_id: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_psso_ise_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param apple_enclave_key_id: + :type apple_enclave_key_id: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_list_serialize( + apple_enclave_key_id=apple_enclave_key_id, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAppleIndependentSecureEnclaveList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_psso_ise_list_serialize( + self, + apple_enclave_key_id, + ordering, + page, + page_size, + search, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if apple_enclave_key_id is not None: + + _query_params.append(('apple_enclave_key_id', apple_enclave_key_id)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/psso/ise/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_psso_ise_partial_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + patched_apple_independent_secure_enclave_request: Optional[PatchedAppleIndependentSecureEnclaveRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AppleIndependentSecureEnclave: + """endpoints_agents_psso_ise_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param patched_apple_independent_secure_enclave_request: + :type patched_apple_independent_secure_enclave_request: PatchedAppleIndependentSecureEnclaveRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_partial_update_serialize( + uuid=uuid, + patched_apple_independent_secure_enclave_request=patched_apple_independent_secure_enclave_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_psso_ise_partial_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + patched_apple_independent_secure_enclave_request: Optional[PatchedAppleIndependentSecureEnclaveRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AppleIndependentSecureEnclave]: + """endpoints_agents_psso_ise_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param patched_apple_independent_secure_enclave_request: + :type patched_apple_independent_secure_enclave_request: PatchedAppleIndependentSecureEnclaveRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_partial_update_serialize( + uuid=uuid, + patched_apple_independent_secure_enclave_request=patched_apple_independent_secure_enclave_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_psso_ise_partial_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + patched_apple_independent_secure_enclave_request: Optional[PatchedAppleIndependentSecureEnclaveRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_psso_ise_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param patched_apple_independent_secure_enclave_request: + :type patched_apple_independent_secure_enclave_request: PatchedAppleIndependentSecureEnclaveRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_partial_update_serialize( + uuid=uuid, + patched_apple_independent_secure_enclave_request=patched_apple_independent_secure_enclave_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_psso_ise_partial_update_serialize( + self, + uuid, + patched_apple_independent_secure_enclave_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_apple_independent_secure_enclave_request is not None: + _body_params = patched_apple_independent_secure_enclave_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/endpoints/agents/psso/ise/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_psso_ise_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AppleIndependentSecureEnclave: + """endpoints_agents_psso_ise_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_psso_ise_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AppleIndependentSecureEnclave]: + """endpoints_agents_psso_ise_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_psso_ise_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_psso_ise_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_psso_ise_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/psso/ise/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_psso_ise_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AppleIndependentSecureEnclave: + """endpoints_agents_psso_ise_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param apple_independent_secure_enclave_request: (required) + :type apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_update_serialize( + uuid=uuid, + apple_independent_secure_enclave_request=apple_independent_secure_enclave_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_psso_ise_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AppleIndependentSecureEnclave]: + """endpoints_agents_psso_ise_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param apple_independent_secure_enclave_request: (required) + :type apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_update_serialize( + uuid=uuid, + apple_independent_secure_enclave_request=apple_independent_secure_enclave_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_psso_ise_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_psso_ise_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param apple_independent_secure_enclave_request: (required) + :type apple_independent_secure_enclave_request: AppleIndependentSecureEnclaveRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_update_serialize( + uuid=uuid, + apple_independent_secure_enclave_request=apple_independent_secure_enclave_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AppleIndependentSecureEnclave", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_psso_ise_update_serialize( + self, + uuid, + apple_independent_secure_enclave_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if apple_independent_secure_enclave_request is not None: + _body_params = apple_independent_secure_enclave_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/endpoints/agents/psso/ise/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_psso_ise_used_by_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """endpoints_agents_psso_ise_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_psso_ise_used_by_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """endpoints_agents_psso_ise_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_psso_ise_used_by_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Apple Independent Secure Enclave.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_psso_ise_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Apple Independent Secure Enclave. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_ise_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_psso_ise_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/agents/psso/ise/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_psso_register_device_create( + self, + agent_psso_device_registration_request: AgentPSSODeviceRegistrationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AgentPSSODeviceRegistrationResponse: + """endpoints_agents_psso_register_device_create + + + :param agent_psso_device_registration_request: (required) + :type agent_psso_device_registration_request: AgentPSSODeviceRegistrationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_register_device_create_serialize( + agent_psso_device_registration_request=agent_psso_device_registration_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentPSSODeviceRegistrationResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_psso_register_device_create_with_http_info( + self, + agent_psso_device_registration_request: AgentPSSODeviceRegistrationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AgentPSSODeviceRegistrationResponse]: + """endpoints_agents_psso_register_device_create + + + :param agent_psso_device_registration_request: (required) + :type agent_psso_device_registration_request: AgentPSSODeviceRegistrationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_register_device_create_serialize( + agent_psso_device_registration_request=agent_psso_device_registration_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentPSSODeviceRegistrationResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_psso_register_device_create_without_preload_content( + self, + agent_psso_device_registration_request: AgentPSSODeviceRegistrationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_psso_register_device_create + + + :param agent_psso_device_registration_request: (required) + :type agent_psso_device_registration_request: AgentPSSODeviceRegistrationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_register_device_create_serialize( + agent_psso_device_registration_request=agent_psso_device_registration_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AgentPSSODeviceRegistrationResponse", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_psso_register_device_create_serialize( + self, + agent_psso_device_registration_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if agent_psso_device_registration_request is not None: + _body_params = agent_psso_device_registration_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/psso/register/device/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_agents_psso_register_user_create( + self, + agent_psso_user_registration_request: AgentPSSOUserRegistrationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserSelf: + """endpoints_agents_psso_register_user_create + + + :param agent_psso_user_registration_request: (required) + :type agent_psso_user_registration_request: AgentPSSOUserRegistrationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_register_user_create_serialize( + agent_psso_user_registration_request=agent_psso_user_registration_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSelf", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_agents_psso_register_user_create_with_http_info( + self, + agent_psso_user_registration_request: AgentPSSOUserRegistrationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserSelf]: + """endpoints_agents_psso_register_user_create + + + :param agent_psso_user_registration_request: (required) + :type agent_psso_user_registration_request: AgentPSSOUserRegistrationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_register_user_create_serialize( + agent_psso_user_registration_request=agent_psso_user_registration_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSelf", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_agents_psso_register_user_create_without_preload_content( + self, + agent_psso_user_registration_request: AgentPSSOUserRegistrationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_agents_psso_register_user_create + + + :param agent_psso_user_registration_request: (required) + :type agent_psso_user_registration_request: AgentPSSOUserRegistrationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_agents_psso_register_user_create_serialize( + agent_psso_user_registration_request=agent_psso_user_registration_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSelf", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_agents_psso_register_user_create_serialize( + self, + agent_psso_user_registration_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if agent_psso_user_registration_request is not None: + _body_params = agent_psso_user_registration_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik_device_auth' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/agents/psso/register/user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_connectors_destroy( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_connectors_destroy + + Connector Viewset + + :param connector_uuid: A UUID string identifying this connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_connectors_destroy_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_connectors_destroy + + Connector Viewset + + :param connector_uuid: A UUID string identifying this connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_connectors_destroy_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_connectors_destroy + + Connector Viewset + + :param connector_uuid: A UUID string identifying this connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_connectors_destroy_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/endpoints/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_connectors_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedConnectorList: + """endpoints_connectors_list + + Connector Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_connectors_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedConnectorList]: + """endpoints_connectors_list + + Connector Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_connectors_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_connectors_list + + Connector Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_connectors_list_serialize( + self, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/connectors/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_connectors_retrieve( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Connector: + """endpoints_connectors_retrieve + + Connector Viewset + + :param connector_uuid: A UUID string identifying this connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Connector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_connectors_retrieve_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Connector]: + """endpoints_connectors_retrieve + + Connector Viewset + + :param connector_uuid: A UUID string identifying this connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Connector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_connectors_retrieve_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_connectors_retrieve + + Connector Viewset + + :param connector_uuid: A UUID string identifying this connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Connector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_connectors_retrieve_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_connectors_types_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[TypeCreate]: + """endpoints_connectors_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_connectors_types_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[TypeCreate]]: + """endpoints_connectors_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_connectors_types_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_connectors_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_connectors_types_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/connectors/types/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_connectors_used_by_list( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """endpoints_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_connectors_used_by_list_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """endpoints_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_connectors_used_by_list_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_connectors_used_by_list_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/connectors/{connector_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_access_groups_create( + self, + device_access_group_request: DeviceAccessGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DeviceAccessGroup: + """endpoints_device_access_groups_create + + DeviceAccessGroup Viewset + + :param device_access_group_request: (required) + :type device_access_group_request: DeviceAccessGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_create_serialize( + device_access_group_request=device_access_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_access_groups_create_with_http_info( + self, + device_access_group_request: DeviceAccessGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DeviceAccessGroup]: + """endpoints_device_access_groups_create + + DeviceAccessGroup Viewset + + :param device_access_group_request: (required) + :type device_access_group_request: DeviceAccessGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_create_serialize( + device_access_group_request=device_access_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_access_groups_create_without_preload_content( + self, + device_access_group_request: DeviceAccessGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_access_groups_create + + DeviceAccessGroup Viewset + + :param device_access_group_request: (required) + :type device_access_group_request: DeviceAccessGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_create_serialize( + device_access_group_request=device_access_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_access_groups_create_serialize( + self, + device_access_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if device_access_group_request is not None: + _body_params = device_access_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/device_access_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_access_groups_destroy( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_device_access_groups_destroy + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_access_groups_destroy_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_device_access_groups_destroy + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_access_groups_destroy_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_access_groups_destroy + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_access_groups_destroy_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/endpoints/device_access_groups/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_access_groups_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDeviceAccessGroupList: + """endpoints_device_access_groups_list + + DeviceAccessGroup Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDeviceAccessGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_access_groups_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDeviceAccessGroupList]: + """endpoints_device_access_groups_list + + DeviceAccessGroup Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDeviceAccessGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_access_groups_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_access_groups_list + + DeviceAccessGroup Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDeviceAccessGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_access_groups_list_serialize( + self, + name, + ordering, + page, + page_size, + pbm_uuid, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/device_access_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_access_groups_partial_update( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + patched_device_access_group_request: Optional[PatchedDeviceAccessGroupRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DeviceAccessGroup: + """endpoints_device_access_groups_partial_update + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param patched_device_access_group_request: + :type patched_device_access_group_request: PatchedDeviceAccessGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_device_access_group_request=patched_device_access_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_access_groups_partial_update_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + patched_device_access_group_request: Optional[PatchedDeviceAccessGroupRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DeviceAccessGroup]: + """endpoints_device_access_groups_partial_update + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param patched_device_access_group_request: + :type patched_device_access_group_request: PatchedDeviceAccessGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_device_access_group_request=patched_device_access_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_access_groups_partial_update_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + patched_device_access_group_request: Optional[PatchedDeviceAccessGroupRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_access_groups_partial_update + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param patched_device_access_group_request: + :type patched_device_access_group_request: PatchedDeviceAccessGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_device_access_group_request=patched_device_access_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_access_groups_partial_update_serialize( + self, + pbm_uuid, + patched_device_access_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_device_access_group_request is not None: + _body_params = patched_device_access_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/endpoints/device_access_groups/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_access_groups_retrieve( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DeviceAccessGroup: + """endpoints_device_access_groups_retrieve + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_access_groups_retrieve_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DeviceAccessGroup]: + """endpoints_device_access_groups_retrieve + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_access_groups_retrieve_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_access_groups_retrieve + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_access_groups_retrieve_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/device_access_groups/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_access_groups_update( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + device_access_group_request: DeviceAccessGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DeviceAccessGroup: + """endpoints_device_access_groups_update + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param device_access_group_request: (required) + :type device_access_group_request: DeviceAccessGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_update_serialize( + pbm_uuid=pbm_uuid, + device_access_group_request=device_access_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_access_groups_update_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + device_access_group_request: DeviceAccessGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DeviceAccessGroup]: + """endpoints_device_access_groups_update + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param device_access_group_request: (required) + :type device_access_group_request: DeviceAccessGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_update_serialize( + pbm_uuid=pbm_uuid, + device_access_group_request=device_access_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_access_groups_update_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + device_access_group_request: DeviceAccessGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_access_groups_update + + DeviceAccessGroup Viewset + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param device_access_group_request: (required) + :type device_access_group_request: DeviceAccessGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_update_serialize( + pbm_uuid=pbm_uuid, + device_access_group_request=device_access_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceAccessGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_access_groups_update_serialize( + self, + pbm_uuid, + device_access_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if device_access_group_request is not None: + _body_params = device_access_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/endpoints/device_access_groups/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_access_groups_used_by_list( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """endpoints_device_access_groups_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_access_groups_used_by_list_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """endpoints_device_access_groups_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_access_groups_used_by_list_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device access group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_access_groups_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this Device access group. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_access_groups_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_access_groups_used_by_list_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/device_access_groups/{pbm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_bindings_create( + self, + device_user_binding_request: DeviceUserBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DeviceUserBinding: + """endpoints_device_bindings_create + + PolicyBinding Viewset + + :param device_user_binding_request: (required) + :type device_user_binding_request: DeviceUserBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_create_serialize( + device_user_binding_request=device_user_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_bindings_create_with_http_info( + self, + device_user_binding_request: DeviceUserBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DeviceUserBinding]: + """endpoints_device_bindings_create + + PolicyBinding Viewset + + :param device_user_binding_request: (required) + :type device_user_binding_request: DeviceUserBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_create_serialize( + device_user_binding_request=device_user_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_bindings_create_without_preload_content( + self, + device_user_binding_request: DeviceUserBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_bindings_create + + PolicyBinding Viewset + + :param device_user_binding_request: (required) + :type device_user_binding_request: DeviceUserBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_create_serialize( + device_user_binding_request=device_user_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_bindings_create_serialize( + self, + device_user_binding_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if device_user_binding_request is not None: + _body_params = device_user_binding_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/device_bindings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_bindings_destroy( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_device_bindings_destroy + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_destroy_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_bindings_destroy_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_device_bindings_destroy + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_destroy_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_bindings_destroy_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_bindings_destroy + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_destroy_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_bindings_destroy_serialize( + self, + policy_binding_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/endpoints/device_bindings/{policy_binding_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_bindings_list( + self, + enabled: Optional[StrictBool] = None, + order: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy: Optional[UUID] = None, + policy__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + target: Optional[UUID] = None, + target_in: Optional[List[UUID]] = None, + timeout: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDeviceUserBindingList: + """endpoints_device_bindings_list + + PolicyBinding Viewset + + :param enabled: + :type enabled: bool + :param order: + :type order: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy: + :type policy: UUID + :param policy__isnull: + :type policy__isnull: bool + :param search: A search term. + :type search: str + :param target: + :type target: UUID + :param target_in: + :type target_in: List[UUID] + :param timeout: + :type timeout: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_list_serialize( + enabled=enabled, + order=order, + ordering=ordering, + page=page, + page_size=page_size, + policy=policy, + policy__isnull=policy__isnull, + search=search, + target=target, + target_in=target_in, + timeout=timeout, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDeviceUserBindingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_bindings_list_with_http_info( + self, + enabled: Optional[StrictBool] = None, + order: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy: Optional[UUID] = None, + policy__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + target: Optional[UUID] = None, + target_in: Optional[List[UUID]] = None, + timeout: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDeviceUserBindingList]: + """endpoints_device_bindings_list + + PolicyBinding Viewset + + :param enabled: + :type enabled: bool + :param order: + :type order: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy: + :type policy: UUID + :param policy__isnull: + :type policy__isnull: bool + :param search: A search term. + :type search: str + :param target: + :type target: UUID + :param target_in: + :type target_in: List[UUID] + :param timeout: + :type timeout: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_list_serialize( + enabled=enabled, + order=order, + ordering=ordering, + page=page, + page_size=page_size, + policy=policy, + policy__isnull=policy__isnull, + search=search, + target=target, + target_in=target_in, + timeout=timeout, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDeviceUserBindingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_bindings_list_without_preload_content( + self, + enabled: Optional[StrictBool] = None, + order: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy: Optional[UUID] = None, + policy__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + target: Optional[UUID] = None, + target_in: Optional[List[UUID]] = None, + timeout: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_bindings_list + + PolicyBinding Viewset + + :param enabled: + :type enabled: bool + :param order: + :type order: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy: + :type policy: UUID + :param policy__isnull: + :type policy__isnull: bool + :param search: A search term. + :type search: str + :param target: + :type target: UUID + :param target_in: + :type target_in: List[UUID] + :param timeout: + :type timeout: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_list_serialize( + enabled=enabled, + order=order, + ordering=ordering, + page=page, + page_size=page_size, + policy=policy, + policy__isnull=policy__isnull, + search=search, + target=target, + target_in=target_in, + timeout=timeout, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDeviceUserBindingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_bindings_list_serialize( + self, + enabled, + order, + ordering, + page, + page_size, + policy, + policy__isnull, + search, + target, + target_in, + timeout, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'target_in': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if enabled is not None: + + _query_params.append(('enabled', enabled)) + + if order is not None: + + _query_params.append(('order', order)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if policy is not None: + + _query_params.append(('policy', policy)) + + if policy__isnull is not None: + + _query_params.append(('policy__isnull', policy__isnull)) + + if search is not None: + + _query_params.append(('search', search)) + + if target is not None: + + _query_params.append(('target', target)) + + if target_in is not None: + + _query_params.append(('target_in', target_in)) + + if timeout is not None: + + _query_params.append(('timeout', timeout)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/device_bindings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_bindings_partial_update( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + patched_device_user_binding_request: Optional[PatchedDeviceUserBindingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DeviceUserBinding: + """endpoints_device_bindings_partial_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param patched_device_user_binding_request: + :type patched_device_user_binding_request: PatchedDeviceUserBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_partial_update_serialize( + policy_binding_uuid=policy_binding_uuid, + patched_device_user_binding_request=patched_device_user_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_bindings_partial_update_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + patched_device_user_binding_request: Optional[PatchedDeviceUserBindingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DeviceUserBinding]: + """endpoints_device_bindings_partial_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param patched_device_user_binding_request: + :type patched_device_user_binding_request: PatchedDeviceUserBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_partial_update_serialize( + policy_binding_uuid=policy_binding_uuid, + patched_device_user_binding_request=patched_device_user_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_bindings_partial_update_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + patched_device_user_binding_request: Optional[PatchedDeviceUserBindingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_bindings_partial_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param patched_device_user_binding_request: + :type patched_device_user_binding_request: PatchedDeviceUserBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_partial_update_serialize( + policy_binding_uuid=policy_binding_uuid, + patched_device_user_binding_request=patched_device_user_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_bindings_partial_update_serialize( + self, + policy_binding_uuid, + patched_device_user_binding_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_device_user_binding_request is not None: + _body_params = patched_device_user_binding_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/endpoints/device_bindings/{policy_binding_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_bindings_retrieve( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DeviceUserBinding: + """endpoints_device_bindings_retrieve + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_retrieve_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_bindings_retrieve_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DeviceUserBinding]: + """endpoints_device_bindings_retrieve + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_retrieve_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_bindings_retrieve_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_bindings_retrieve + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_retrieve_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_bindings_retrieve_serialize( + self, + policy_binding_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/device_bindings/{policy_binding_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_bindings_update( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + device_user_binding_request: DeviceUserBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DeviceUserBinding: + """endpoints_device_bindings_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param device_user_binding_request: (required) + :type device_user_binding_request: DeviceUserBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_update_serialize( + policy_binding_uuid=policy_binding_uuid, + device_user_binding_request=device_user_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_bindings_update_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + device_user_binding_request: DeviceUserBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DeviceUserBinding]: + """endpoints_device_bindings_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param device_user_binding_request: (required) + :type device_user_binding_request: DeviceUserBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_update_serialize( + policy_binding_uuid=policy_binding_uuid, + device_user_binding_request=device_user_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_bindings_update_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + device_user_binding_request: DeviceUserBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_bindings_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param device_user_binding_request: (required) + :type device_user_binding_request: DeviceUserBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_update_serialize( + policy_binding_uuid=policy_binding_uuid, + device_user_binding_request=device_user_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceUserBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_bindings_update_serialize( + self, + policy_binding_uuid, + device_user_binding_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if device_user_binding_request is not None: + _body_params = device_user_binding_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/endpoints/device_bindings/{policy_binding_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_device_bindings_used_by_list( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """endpoints_device_bindings_used_by_list + + Get a list of all objects that use this object + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_used_by_list_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_device_bindings_used_by_list_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """endpoints_device_bindings_used_by_list + + Get a list of all objects that use this object + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_used_by_list_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_device_bindings_used_by_list_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device User binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_device_bindings_used_by_list + + Get a list of all objects that use this object + + :param policy_binding_uuid: A UUID string identifying this Device User binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_device_bindings_used_by_list_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_device_bindings_used_by_list_serialize( + self, + policy_binding_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/device_bindings/{policy_binding_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_devices_destroy( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_devices_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_destroy_serialize( + device_uuid=device_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_devices_destroy_with_http_info( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_devices_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_destroy_serialize( + device_uuid=device_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_devices_destroy_without_preload_content( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_devices_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_destroy_serialize( + device_uuid=device_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_devices_destroy_serialize( + self, + device_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if device_uuid is not None: + _path_params['device_uuid'] = device_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/endpoints/devices/{device_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_devices_list( + self, + identifier: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedEndpointDeviceList: + """endpoints_devices_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param identifier: + :type identifier: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_list_serialize( + identifier=identifier, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEndpointDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_devices_list_with_http_info( + self, + identifier: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedEndpointDeviceList]: + """endpoints_devices_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param identifier: + :type identifier: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_list_serialize( + identifier=identifier, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEndpointDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_devices_list_without_preload_content( + self, + identifier: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_devices_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param identifier: + :type identifier: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_list_serialize( + identifier=identifier, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEndpointDeviceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_devices_list_serialize( + self, + identifier, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if identifier is not None: + + _query_params.append(('identifier', identifier)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/devices/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_devices_partial_update( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + patched_endpoint_device_request: Optional[PatchedEndpointDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EndpointDevice: + """endpoints_devices_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param patched_endpoint_device_request: + :type patched_endpoint_device_request: PatchedEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_partial_update_serialize( + device_uuid=device_uuid, + patched_endpoint_device_request=patched_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_devices_partial_update_with_http_info( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + patched_endpoint_device_request: Optional[PatchedEndpointDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EndpointDevice]: + """endpoints_devices_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param patched_endpoint_device_request: + :type patched_endpoint_device_request: PatchedEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_partial_update_serialize( + device_uuid=device_uuid, + patched_endpoint_device_request=patched_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_devices_partial_update_without_preload_content( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + patched_endpoint_device_request: Optional[PatchedEndpointDeviceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_devices_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param patched_endpoint_device_request: + :type patched_endpoint_device_request: PatchedEndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_partial_update_serialize( + device_uuid=device_uuid, + patched_endpoint_device_request=patched_endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_devices_partial_update_serialize( + self, + device_uuid, + patched_endpoint_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if device_uuid is not None: + _path_params['device_uuid'] = device_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_endpoint_device_request is not None: + _body_params = patched_endpoint_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/endpoints/devices/{device_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_devices_retrieve( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EndpointDeviceDetails: + """endpoints_devices_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_retrieve_serialize( + device_uuid=device_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointDeviceDetails", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_devices_retrieve_with_http_info( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EndpointDeviceDetails]: + """endpoints_devices_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_retrieve_serialize( + device_uuid=device_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointDeviceDetails", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_devices_retrieve_without_preload_content( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_devices_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_retrieve_serialize( + device_uuid=device_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointDeviceDetails", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_devices_retrieve_serialize( + self, + device_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if device_uuid is not None: + _path_params['device_uuid'] = device_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/devices/{device_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_devices_summary_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DeviceSummary: + """endpoints_devices_summary_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_summary_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceSummary", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_devices_summary_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DeviceSummary]: + """endpoints_devices_summary_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_summary_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceSummary", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_devices_summary_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_devices_summary_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_summary_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DeviceSummary", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_devices_summary_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/devices/summary/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_devices_update( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + endpoint_device_request: EndpointDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EndpointDevice: + """endpoints_devices_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param endpoint_device_request: (required) + :type endpoint_device_request: EndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_update_serialize( + device_uuid=device_uuid, + endpoint_device_request=endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_devices_update_with_http_info( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + endpoint_device_request: EndpointDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EndpointDevice]: + """endpoints_devices_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param endpoint_device_request: (required) + :type endpoint_device_request: EndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_update_serialize( + device_uuid=device_uuid, + endpoint_device_request=endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_devices_update_without_preload_content( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + endpoint_device_request: EndpointDeviceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_devices_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param endpoint_device_request: (required) + :type endpoint_device_request: EndpointDeviceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_update_serialize( + device_uuid=device_uuid, + endpoint_device_request=endpoint_device_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointDevice", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_devices_update_serialize( + self, + device_uuid, + endpoint_device_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if device_uuid is not None: + _path_params['device_uuid'] = device_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if endpoint_device_request is not None: + _body_params = endpoint_device_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/endpoints/devices/{device_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_devices_used_by_list( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """endpoints_devices_used_by_list + + Get a list of all objects that use this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_used_by_list_serialize( + device_uuid=device_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_devices_used_by_list_with_http_info( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """endpoints_devices_used_by_list + + Get a list of all objects that use this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_used_by_list_serialize( + device_uuid=device_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_devices_used_by_list_without_preload_content( + self, + device_uuid: Annotated[UUID, Field(description="A UUID string identifying this Device.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_devices_used_by_list + + Get a list of all objects that use this object + + :param device_uuid: A UUID string identifying this Device. (required) + :type device_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_devices_used_by_list_serialize( + device_uuid=device_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_devices_used_by_list_serialize( + self, + device_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if device_uuid is not None: + _path_params['device_uuid'] = device_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/devices/{device_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_fleet_connectors_create( + self, + fleet_connector_request: FleetConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FleetConnector: + """endpoints_fleet_connectors_create + + FleetConnector Viewset + + :param fleet_connector_request: (required) + :type fleet_connector_request: FleetConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_create_serialize( + fleet_connector_request=fleet_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_fleet_connectors_create_with_http_info( + self, + fleet_connector_request: FleetConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FleetConnector]: + """endpoints_fleet_connectors_create + + FleetConnector Viewset + + :param fleet_connector_request: (required) + :type fleet_connector_request: FleetConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_create_serialize( + fleet_connector_request=fleet_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_fleet_connectors_create_without_preload_content( + self, + fleet_connector_request: FleetConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_fleet_connectors_create + + FleetConnector Viewset + + :param fleet_connector_request: (required) + :type fleet_connector_request: FleetConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_create_serialize( + fleet_connector_request=fleet_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_fleet_connectors_create_serialize( + self, + fleet_connector_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if fleet_connector_request is not None: + _body_params = fleet_connector_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/fleet/connectors/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_fleet_connectors_destroy( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_fleet_connectors_destroy + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_fleet_connectors_destroy_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_fleet_connectors_destroy + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_fleet_connectors_destroy_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_fleet_connectors_destroy + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_fleet_connectors_destroy_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/endpoints/fleet/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_fleet_connectors_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedFleetConnectorList: + """endpoints_fleet_connectors_list + + FleetConnector Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedFleetConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_fleet_connectors_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedFleetConnectorList]: + """endpoints_fleet_connectors_list + + FleetConnector Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedFleetConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_fleet_connectors_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_fleet_connectors_list + + FleetConnector Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedFleetConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_fleet_connectors_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/fleet/connectors/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_fleet_connectors_partial_update( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + patched_fleet_connector_request: Optional[PatchedFleetConnectorRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FleetConnector: + """endpoints_fleet_connectors_partial_update + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param patched_fleet_connector_request: + :type patched_fleet_connector_request: PatchedFleetConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_partial_update_serialize( + connector_uuid=connector_uuid, + patched_fleet_connector_request=patched_fleet_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_fleet_connectors_partial_update_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + patched_fleet_connector_request: Optional[PatchedFleetConnectorRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FleetConnector]: + """endpoints_fleet_connectors_partial_update + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param patched_fleet_connector_request: + :type patched_fleet_connector_request: PatchedFleetConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_partial_update_serialize( + connector_uuid=connector_uuid, + patched_fleet_connector_request=patched_fleet_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_fleet_connectors_partial_update_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + patched_fleet_connector_request: Optional[PatchedFleetConnectorRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_fleet_connectors_partial_update + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param patched_fleet_connector_request: + :type patched_fleet_connector_request: PatchedFleetConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_partial_update_serialize( + connector_uuid=connector_uuid, + patched_fleet_connector_request=patched_fleet_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_fleet_connectors_partial_update_serialize( + self, + connector_uuid, + patched_fleet_connector_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_fleet_connector_request is not None: + _body_params = patched_fleet_connector_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/endpoints/fleet/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_fleet_connectors_retrieve( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FleetConnector: + """endpoints_fleet_connectors_retrieve + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_fleet_connectors_retrieve_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FleetConnector]: + """endpoints_fleet_connectors_retrieve + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_fleet_connectors_retrieve_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_fleet_connectors_retrieve + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_fleet_connectors_retrieve_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/fleet/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_fleet_connectors_update( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + fleet_connector_request: FleetConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FleetConnector: + """endpoints_fleet_connectors_update + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param fleet_connector_request: (required) + :type fleet_connector_request: FleetConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_update_serialize( + connector_uuid=connector_uuid, + fleet_connector_request=fleet_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_fleet_connectors_update_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + fleet_connector_request: FleetConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FleetConnector]: + """endpoints_fleet_connectors_update + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param fleet_connector_request: (required) + :type fleet_connector_request: FleetConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_update_serialize( + connector_uuid=connector_uuid, + fleet_connector_request=fleet_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_fleet_connectors_update_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + fleet_connector_request: FleetConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_fleet_connectors_update + + FleetConnector Viewset + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param fleet_connector_request: (required) + :type fleet_connector_request: FleetConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_update_serialize( + connector_uuid=connector_uuid, + fleet_connector_request=fleet_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FleetConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_fleet_connectors_update_serialize( + self, + connector_uuid, + fleet_connector_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if fleet_connector_request is not None: + _body_params = fleet_connector_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/endpoints/fleet/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_fleet_connectors_used_by_list( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """endpoints_fleet_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_fleet_connectors_used_by_list_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """endpoints_fleet_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_fleet_connectors_used_by_list_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Fleet Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_fleet_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this Fleet Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_fleet_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_fleet_connectors_used_by_list_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/fleet/connectors/{connector_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_google_chrome_connectors_create( + self, + google_chrome_connector_request: GoogleChromeConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleChromeConnector: + """endpoints_google_chrome_connectors_create + + GoogleChromeConnector Viewset + + :param google_chrome_connector_request: (required) + :type google_chrome_connector_request: GoogleChromeConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_create_serialize( + google_chrome_connector_request=google_chrome_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_google_chrome_connectors_create_with_http_info( + self, + google_chrome_connector_request: GoogleChromeConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleChromeConnector]: + """endpoints_google_chrome_connectors_create + + GoogleChromeConnector Viewset + + :param google_chrome_connector_request: (required) + :type google_chrome_connector_request: GoogleChromeConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_create_serialize( + google_chrome_connector_request=google_chrome_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_google_chrome_connectors_create_without_preload_content( + self, + google_chrome_connector_request: GoogleChromeConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_google_chrome_connectors_create + + GoogleChromeConnector Viewset + + :param google_chrome_connector_request: (required) + :type google_chrome_connector_request: GoogleChromeConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_create_serialize( + google_chrome_connector_request=google_chrome_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_google_chrome_connectors_create_serialize( + self, + google_chrome_connector_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_chrome_connector_request is not None: + _body_params = google_chrome_connector_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/endpoints/google_chrome/connectors/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_google_chrome_connectors_destroy( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """endpoints_google_chrome_connectors_destroy + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_google_chrome_connectors_destroy_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """endpoints_google_chrome_connectors_destroy + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_google_chrome_connectors_destroy_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_google_chrome_connectors_destroy + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_destroy_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_google_chrome_connectors_destroy_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/endpoints/google_chrome/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_google_chrome_connectors_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGoogleChromeConnectorList: + """endpoints_google_chrome_connectors_list + + GoogleChromeConnector Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleChromeConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_google_chrome_connectors_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGoogleChromeConnectorList]: + """endpoints_google_chrome_connectors_list + + GoogleChromeConnector Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleChromeConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_google_chrome_connectors_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_google_chrome_connectors_list + + GoogleChromeConnector Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleChromeConnectorList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_google_chrome_connectors_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/google_chrome/connectors/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_google_chrome_connectors_partial_update( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + patched_google_chrome_connector_request: Optional[PatchedGoogleChromeConnectorRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleChromeConnector: + """endpoints_google_chrome_connectors_partial_update + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param patched_google_chrome_connector_request: + :type patched_google_chrome_connector_request: PatchedGoogleChromeConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_partial_update_serialize( + connector_uuid=connector_uuid, + patched_google_chrome_connector_request=patched_google_chrome_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_google_chrome_connectors_partial_update_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + patched_google_chrome_connector_request: Optional[PatchedGoogleChromeConnectorRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleChromeConnector]: + """endpoints_google_chrome_connectors_partial_update + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param patched_google_chrome_connector_request: + :type patched_google_chrome_connector_request: PatchedGoogleChromeConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_partial_update_serialize( + connector_uuid=connector_uuid, + patched_google_chrome_connector_request=patched_google_chrome_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_google_chrome_connectors_partial_update_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + patched_google_chrome_connector_request: Optional[PatchedGoogleChromeConnectorRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_google_chrome_connectors_partial_update + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param patched_google_chrome_connector_request: + :type patched_google_chrome_connector_request: PatchedGoogleChromeConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_partial_update_serialize( + connector_uuid=connector_uuid, + patched_google_chrome_connector_request=patched_google_chrome_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_google_chrome_connectors_partial_update_serialize( + self, + connector_uuid, + patched_google_chrome_connector_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_google_chrome_connector_request is not None: + _body_params = patched_google_chrome_connector_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/endpoints/google_chrome/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_google_chrome_connectors_retrieve( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleChromeConnector: + """endpoints_google_chrome_connectors_retrieve + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_google_chrome_connectors_retrieve_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleChromeConnector]: + """endpoints_google_chrome_connectors_retrieve + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_google_chrome_connectors_retrieve_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_google_chrome_connectors_retrieve + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_retrieve_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_google_chrome_connectors_retrieve_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/google_chrome/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_google_chrome_connectors_update( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + google_chrome_connector_request: GoogleChromeConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleChromeConnector: + """endpoints_google_chrome_connectors_update + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param google_chrome_connector_request: (required) + :type google_chrome_connector_request: GoogleChromeConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_update_serialize( + connector_uuid=connector_uuid, + google_chrome_connector_request=google_chrome_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_google_chrome_connectors_update_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + google_chrome_connector_request: GoogleChromeConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleChromeConnector]: + """endpoints_google_chrome_connectors_update + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param google_chrome_connector_request: (required) + :type google_chrome_connector_request: GoogleChromeConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_update_serialize( + connector_uuid=connector_uuid, + google_chrome_connector_request=google_chrome_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_google_chrome_connectors_update_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + google_chrome_connector_request: GoogleChromeConnectorRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_google_chrome_connectors_update + + GoogleChromeConnector Viewset + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param google_chrome_connector_request: (required) + :type google_chrome_connector_request: GoogleChromeConnectorRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_update_serialize( + connector_uuid=connector_uuid, + google_chrome_connector_request=google_chrome_connector_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleChromeConnector", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_google_chrome_connectors_update_serialize( + self, + connector_uuid, + google_chrome_connector_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_chrome_connector_request is not None: + _body_params = google_chrome_connector_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/endpoints/google_chrome/connectors/{connector_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def endpoints_google_chrome_connectors_used_by_list( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """endpoints_google_chrome_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def endpoints_google_chrome_connectors_used_by_list_with_http_info( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """endpoints_google_chrome_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def endpoints_google_chrome_connectors_used_by_list_without_preload_content( + self, + connector_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Device Trust Connector.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """endpoints_google_chrome_connectors_used_by_list + + Get a list of all objects that use this object + + :param connector_uuid: A UUID string identifying this Google Device Trust Connector. (required) + :type connector_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._endpoints_google_chrome_connectors_used_by_list_serialize( + connector_uuid=connector_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _endpoints_google_chrome_connectors_used_by_list_serialize( + self, + connector_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connector_uuid is not None: + _path_params['connector_uuid'] = connector_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/endpoints/google_chrome/connectors/{connector_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/enterprise_api.py b/authentik_client/api/enterprise_api.py new file mode 100644 index 000000000..2e01c7767 --- /dev/null +++ b/authentik_client/api/enterprise_api.py @@ -0,0 +1,2828 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.install_id import InstallID +from authentik_client.models.license import License +from authentik_client.models.license_forecast import LicenseForecast +from authentik_client.models.license_request import LicenseRequest +from authentik_client.models.license_summary import LicenseSummary +from authentik_client.models.paginated_license_list import PaginatedLicenseList +from authentik_client.models.patched_license_request import PatchedLicenseRequest +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class EnterpriseApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def enterprise_license_create( + self, + license_request: LicenseRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> License: + """enterprise_license_create + + License Viewset + + :param license_request: (required) + :type license_request: LicenseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_create_serialize( + license_request=license_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_create_with_http_info( + self, + license_request: LicenseRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[License]: + """enterprise_license_create + + License Viewset + + :param license_request: (required) + :type license_request: LicenseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_create_serialize( + license_request=license_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_create_without_preload_content( + self, + license_request: LicenseRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_create + + License Viewset + + :param license_request: (required) + :type license_request: LicenseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_create_serialize( + license_request=license_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_create_serialize( + self, + license_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if license_request is not None: + _body_params = license_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/enterprise/license/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def enterprise_license_destroy( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """enterprise_license_destroy + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_destroy_serialize( + license_uuid=license_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_destroy_with_http_info( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """enterprise_license_destroy + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_destroy_serialize( + license_uuid=license_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_destroy_without_preload_content( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_destroy + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_destroy_serialize( + license_uuid=license_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_destroy_serialize( + self, + license_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if license_uuid is not None: + _path_params['license_uuid'] = license_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/enterprise/license/{license_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def enterprise_license_forecast_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LicenseForecast: + """enterprise_license_forecast_retrieve + + Forecast how many users will be required in a year + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_forecast_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LicenseForecast", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_forecast_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LicenseForecast]: + """enterprise_license_forecast_retrieve + + Forecast how many users will be required in a year + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_forecast_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LicenseForecast", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_forecast_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_forecast_retrieve + + Forecast how many users will be required in a year + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_forecast_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LicenseForecast", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_forecast_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/enterprise/license/forecast/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def enterprise_license_install_id_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> InstallID: + """enterprise_license_install_id_retrieve + + Get install_id + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_install_id_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InstallID", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_install_id_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[InstallID]: + """enterprise_license_install_id_retrieve + + Get install_id + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_install_id_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InstallID", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_install_id_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_install_id_retrieve + + Get install_id + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_install_id_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InstallID", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_install_id_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/enterprise/license/install_id/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def enterprise_license_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedLicenseList: + """enterprise_license_list + + License Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLicenseList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedLicenseList]: + """enterprise_license_list + + License Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLicenseList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_list + + License Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLicenseList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/enterprise/license/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def enterprise_license_partial_update( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + patched_license_request: Optional[PatchedLicenseRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> License: + """enterprise_license_partial_update + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param patched_license_request: + :type patched_license_request: PatchedLicenseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_partial_update_serialize( + license_uuid=license_uuid, + patched_license_request=patched_license_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_partial_update_with_http_info( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + patched_license_request: Optional[PatchedLicenseRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[License]: + """enterprise_license_partial_update + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param patched_license_request: + :type patched_license_request: PatchedLicenseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_partial_update_serialize( + license_uuid=license_uuid, + patched_license_request=patched_license_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_partial_update_without_preload_content( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + patched_license_request: Optional[PatchedLicenseRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_partial_update + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param patched_license_request: + :type patched_license_request: PatchedLicenseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_partial_update_serialize( + license_uuid=license_uuid, + patched_license_request=patched_license_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_partial_update_serialize( + self, + license_uuid, + patched_license_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if license_uuid is not None: + _path_params['license_uuid'] = license_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_license_request is not None: + _body_params = patched_license_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/enterprise/license/{license_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def enterprise_license_retrieve( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> License: + """enterprise_license_retrieve + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_retrieve_serialize( + license_uuid=license_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_retrieve_with_http_info( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[License]: + """enterprise_license_retrieve + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_retrieve_serialize( + license_uuid=license_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_retrieve_without_preload_content( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_retrieve + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_retrieve_serialize( + license_uuid=license_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_retrieve_serialize( + self, + license_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if license_uuid is not None: + _path_params['license_uuid'] = license_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/enterprise/license/{license_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def enterprise_license_summary_retrieve( + self, + cached: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LicenseSummary: + """enterprise_license_summary_retrieve + + Get the total license status + + :param cached: + :type cached: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_summary_retrieve_serialize( + cached=cached, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LicenseSummary", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_summary_retrieve_with_http_info( + self, + cached: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LicenseSummary]: + """enterprise_license_summary_retrieve + + Get the total license status + + :param cached: + :type cached: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_summary_retrieve_serialize( + cached=cached, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LicenseSummary", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_summary_retrieve_without_preload_content( + self, + cached: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_summary_retrieve + + Get the total license status + + :param cached: + :type cached: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_summary_retrieve_serialize( + cached=cached, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LicenseSummary", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_summary_retrieve_serialize( + self, + cached, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if cached is not None: + + _query_params.append(('cached', cached)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/enterprise/license/summary/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def enterprise_license_update( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + license_request: LicenseRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> License: + """enterprise_license_update + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param license_request: (required) + :type license_request: LicenseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_update_serialize( + license_uuid=license_uuid, + license_request=license_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_update_with_http_info( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + license_request: LicenseRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[License]: + """enterprise_license_update + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param license_request: (required) + :type license_request: LicenseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_update_serialize( + license_uuid=license_uuid, + license_request=license_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_update_without_preload_content( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + license_request: LicenseRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_update + + License Viewset + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param license_request: (required) + :type license_request: LicenseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_update_serialize( + license_uuid=license_uuid, + license_request=license_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "License", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_update_serialize( + self, + license_uuid, + license_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if license_uuid is not None: + _path_params['license_uuid'] = license_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if license_request is not None: + _body_params = license_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/enterprise/license/{license_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def enterprise_license_used_by_list( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """enterprise_license_used_by_list + + Get a list of all objects that use this object + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_used_by_list_serialize( + license_uuid=license_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def enterprise_license_used_by_list_with_http_info( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """enterprise_license_used_by_list + + Get a list of all objects that use this object + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_used_by_list_serialize( + license_uuid=license_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def enterprise_license_used_by_list_without_preload_content( + self, + license_uuid: Annotated[UUID, Field(description="A UUID string identifying this License.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """enterprise_license_used_by_list + + Get a list of all objects that use this object + + :param license_uuid: A UUID string identifying this License. (required) + :type license_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._enterprise_license_used_by_list_serialize( + license_uuid=license_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _enterprise_license_used_by_list_serialize( + self, + license_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if license_uuid is not None: + _path_params['license_uuid'] = license_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/enterprise/license/{license_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/events_api.py b/authentik_client/api/events_api.py new file mode 100644 index 000000000..813c38e8a --- /dev/null +++ b/authentik_client/api/events_api.py @@ -0,0 +1,10350 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from datetime import datetime +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import Any, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.data_export import DataExport +from authentik_client.models.event import Event +from authentik_client.models.event_actions import EventActions +from authentik_client.models.event_request import EventRequest +from authentik_client.models.event_stats import EventStats +from authentik_client.models.event_top_per_user import EventTopPerUser +from authentik_client.models.event_volume import EventVolume +from authentik_client.models.notification import Notification +from authentik_client.models.notification_request import NotificationRequest +from authentik_client.models.notification_rule import NotificationRule +from authentik_client.models.notification_rule_request import NotificationRuleRequest +from authentik_client.models.notification_transport import NotificationTransport +from authentik_client.models.notification_transport_request import NotificationTransportRequest +from authentik_client.models.notification_transport_test import NotificationTransportTest +from authentik_client.models.paginated_event_list import PaginatedEventList +from authentik_client.models.paginated_notification_list import PaginatedNotificationList +from authentik_client.models.paginated_notification_rule_list import PaginatedNotificationRuleList +from authentik_client.models.paginated_notification_transport_list import PaginatedNotificationTransportList +from authentik_client.models.patched_event_request import PatchedEventRequest +from authentik_client.models.patched_notification_request import PatchedNotificationRequest +from authentik_client.models.patched_notification_rule_request import PatchedNotificationRuleRequest +from authentik_client.models.patched_notification_transport_request import PatchedNotificationTransportRequest +from authentik_client.models.severity_enum import SeverityEnum +from authentik_client.models.transport_mode_enum import TransportModeEnum +from authentik_client.models.type_create import TypeCreate +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class EventsApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def events_events_actions_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[TypeCreate]: + """events_events_actions_list + + Get all actions + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_actions_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_actions_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[TypeCreate]]: + """events_events_actions_list + + Get all actions + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_actions_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_actions_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_actions_list + + Get all actions + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_actions_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_actions_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/events/actions/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_create( + self, + event_request: EventRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Event: + """events_events_create + + Event Read-Only Viewset + + :param event_request: (required) + :type event_request: EventRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_create_serialize( + event_request=event_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_create_with_http_info( + self, + event_request: EventRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Event]: + """events_events_create + + Event Read-Only Viewset + + :param event_request: (required) + :type event_request: EventRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_create_serialize( + event_request=event_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_create_without_preload_content( + self, + event_request: EventRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_create + + Event Read-Only Viewset + + :param event_request: (required) + :type event_request: EventRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_create_serialize( + event_request=event_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_create_serialize( + self, + event_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if event_request is not None: + _body_params = event_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/events/events/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_destroy( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """events_events_destroy + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_destroy_serialize( + event_uuid=event_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_destroy_with_http_info( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """events_events_destroy + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_destroy_serialize( + event_uuid=event_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_destroy_without_preload_content( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_destroy + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_destroy_serialize( + event_uuid=event_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_destroy_serialize( + self, + event_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if event_uuid is not None: + _path_params['event_uuid'] = event_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/events/events/{event_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_export_create( + self, + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DataExport: + """events_events_export_create + + Create a data export for this data type. Note that the export is generated asynchronously: this method returns a `DataExport` object that will initially have `completed=false` as well as the permanent URL to that object in the `Location` header. You can poll that URL until `completed=true`, at which point the `file_url` property will contain a URL to download + + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_export_create_serialize( + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + ordering=ordering, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DataExport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_export_create_with_http_info( + self, + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DataExport]: + """events_events_export_create + + Create a data export for this data type. Note that the export is generated asynchronously: this method returns a `DataExport` object that will initially have `completed=false` as well as the permanent URL to that object in the `Location` header. You can poll that URL until `completed=true`, at which point the `file_url` property will contain a URL to download + + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_export_create_serialize( + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + ordering=ordering, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DataExport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_export_create_without_preload_content( + self, + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_export_create + + Create a data export for this data type. Note that the export is generated asynchronously: this method returns a `DataExport` object that will initially have `completed=false` as well as the permanent URL to that object in the `Location` header. You can poll that URL until `completed=true`, at which point the `file_url` property will contain a URL to download + + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_export_create_serialize( + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + ordering=ordering, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DataExport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_export_create_serialize( + self, + action, + actions, + brand_name, + client_ip, + context_authorized_app, + context_device, + context_model_app, + context_model_name, + context_model_pk, + ordering, + search, + username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'actions': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if action is not None: + + _query_params.append(('action', action)) + + if actions is not None: + + _query_params.append(('actions', actions)) + + if brand_name is not None: + + _query_params.append(('brand_name', brand_name)) + + if client_ip is not None: + + _query_params.append(('client_ip', client_ip)) + + if context_authorized_app is not None: + + _query_params.append(('context_authorized_app', context_authorized_app)) + + if context_device is not None: + + _query_params.append(('context_device', context_device)) + + if context_model_app is not None: + + _query_params.append(('context_model_app', context_model_app)) + + if context_model_name is not None: + + _query_params.append(('context_model_name', context_model_name)) + + if context_model_pk is not None: + + _query_params.append(('context_model_pk', context_model_pk)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if search is not None: + + _query_params.append(('search', search)) + + if username is not None: + + _query_params.append(('username', username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/events/events/export/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_list( + self, + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedEventList: + """events_events_list + + Event Read-Only Viewset + + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_list_serialize( + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEventList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_list_with_http_info( + self, + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedEventList]: + """events_events_list + + Event Read-Only Viewset + + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_list_serialize( + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEventList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_list_without_preload_content( + self, + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_list + + Event Read-Only Viewset + + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_list_serialize( + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEventList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_list_serialize( + self, + action, + actions, + brand_name, + client_ip, + context_authorized_app, + context_device, + context_model_app, + context_model_name, + context_model_pk, + ordering, + page, + page_size, + search, + username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'actions': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if action is not None: + + _query_params.append(('action', action)) + + if actions is not None: + + _query_params.append(('actions', actions)) + + if brand_name is not None: + + _query_params.append(('brand_name', brand_name)) + + if client_ip is not None: + + _query_params.append(('client_ip', client_ip)) + + if context_authorized_app is not None: + + _query_params.append(('context_authorized_app', context_authorized_app)) + + if context_device is not None: + + _query_params.append(('context_device', context_device)) + + if context_model_app is not None: + + _query_params.append(('context_model_app', context_model_app)) + + if context_model_name is not None: + + _query_params.append(('context_model_name', context_model_name)) + + if context_model_pk is not None: + + _query_params.append(('context_model_pk', context_model_pk)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if username is not None: + + _query_params.append(('username', username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/events/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_partial_update( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + patched_event_request: Optional[PatchedEventRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Event: + """events_events_partial_update + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param patched_event_request: + :type patched_event_request: PatchedEventRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_partial_update_serialize( + event_uuid=event_uuid, + patched_event_request=patched_event_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_partial_update_with_http_info( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + patched_event_request: Optional[PatchedEventRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Event]: + """events_events_partial_update + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param patched_event_request: + :type patched_event_request: PatchedEventRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_partial_update_serialize( + event_uuid=event_uuid, + patched_event_request=patched_event_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_partial_update_without_preload_content( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + patched_event_request: Optional[PatchedEventRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_partial_update + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param patched_event_request: + :type patched_event_request: PatchedEventRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_partial_update_serialize( + event_uuid=event_uuid, + patched_event_request=patched_event_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_partial_update_serialize( + self, + event_uuid, + patched_event_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if event_uuid is not None: + _path_params['event_uuid'] = event_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_event_request is not None: + _body_params = patched_event_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/events/events/{event_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_retrieve( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Event: + """events_events_retrieve + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_retrieve_serialize( + event_uuid=event_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_retrieve_with_http_info( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Event]: + """events_events_retrieve + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_retrieve_serialize( + event_uuid=event_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_retrieve_without_preload_content( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_retrieve + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_retrieve_serialize( + event_uuid=event_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_retrieve_serialize( + self, + event_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if event_uuid is not None: + _path_params['event_uuid'] = event_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/events/{event_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_stats_retrieve( + self, + count_steps: Annotated[List[Annotated[str, Field(min_length=1, strict=True)]], Field(description="Timedelta, format of 'weeks=3;days=2;hours=3,seconds=2'")], + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EventStats: + """events_events_stats_retrieve + + Get event stats for specified filters and count steps + + :param count_steps: Timedelta, format of 'weeks=3;days=2;hours=3,seconds=2' (required) + :type count_steps: List[str] + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_stats_retrieve_serialize( + count_steps=count_steps, + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + ordering=ordering, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventStats", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_stats_retrieve_with_http_info( + self, + count_steps: Annotated[List[Annotated[str, Field(min_length=1, strict=True)]], Field(description="Timedelta, format of 'weeks=3;days=2;hours=3,seconds=2'")], + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EventStats]: + """events_events_stats_retrieve + + Get event stats for specified filters and count steps + + :param count_steps: Timedelta, format of 'weeks=3;days=2;hours=3,seconds=2' (required) + :type count_steps: List[str] + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_stats_retrieve_serialize( + count_steps=count_steps, + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + ordering=ordering, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventStats", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_stats_retrieve_without_preload_content( + self, + count_steps: Annotated[List[Annotated[str, Field(min_length=1, strict=True)]], Field(description="Timedelta, format of 'weeks=3;days=2;hours=3,seconds=2'")], + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_stats_retrieve + + Get event stats for specified filters and count steps + + :param count_steps: Timedelta, format of 'weeks=3;days=2;hours=3,seconds=2' (required) + :type count_steps: List[str] + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_stats_retrieve_serialize( + count_steps=count_steps, + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + ordering=ordering, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventStats", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_stats_retrieve_serialize( + self, + count_steps, + action, + actions, + brand_name, + client_ip, + context_authorized_app, + context_device, + context_model_app, + context_model_name, + context_model_pk, + ordering, + search, + username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'count_steps': 'multi', + 'actions': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if action is not None: + + _query_params.append(('action', action)) + + if actions is not None: + + _query_params.append(('actions', actions)) + + if brand_name is not None: + + _query_params.append(('brand_name', brand_name)) + + if client_ip is not None: + + _query_params.append(('client_ip', client_ip)) + + if context_authorized_app is not None: + + _query_params.append(('context_authorized_app', context_authorized_app)) + + if context_device is not None: + + _query_params.append(('context_device', context_device)) + + if context_model_app is not None: + + _query_params.append(('context_model_app', context_model_app)) + + if context_model_name is not None: + + _query_params.append(('context_model_name', context_model_name)) + + if context_model_pk is not None: + + _query_params.append(('context_model_pk', context_model_pk)) + + if count_steps is not None: + + _query_params.append(('count_steps', count_steps)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if search is not None: + + _query_params.append(('search', search)) + + if username is not None: + + _query_params.append(('username', username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/events/stats/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_top_per_user_list( + self, + action: Optional[StrictStr] = None, + top_n: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[EventTopPerUser]: + """events_events_top_per_user_list + + Get the top_n events grouped by user count + + :param action: + :type action: str + :param top_n: + :type top_n: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_top_per_user_list_serialize( + action=action, + top_n=top_n, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[EventTopPerUser]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_top_per_user_list_with_http_info( + self, + action: Optional[StrictStr] = None, + top_n: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[EventTopPerUser]]: + """events_events_top_per_user_list + + Get the top_n events grouped by user count + + :param action: + :type action: str + :param top_n: + :type top_n: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_top_per_user_list_serialize( + action=action, + top_n=top_n, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[EventTopPerUser]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_top_per_user_list_without_preload_content( + self, + action: Optional[StrictStr] = None, + top_n: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_top_per_user_list + + Get the top_n events grouped by user count + + :param action: + :type action: str + :param top_n: + :type top_n: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_top_per_user_list_serialize( + action=action, + top_n=top_n, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[EventTopPerUser]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_top_per_user_list_serialize( + self, + action, + top_n, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if action is not None: + + _query_params.append(('action', action)) + + if top_n is not None: + + _query_params.append(('top_n', top_n)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/events/top_per_user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_update( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + event_request: EventRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Event: + """events_events_update + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param event_request: (required) + :type event_request: EventRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_update_serialize( + event_uuid=event_uuid, + event_request=event_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_update_with_http_info( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + event_request: EventRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Event]: + """events_events_update + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param event_request: (required) + :type event_request: EventRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_update_serialize( + event_uuid=event_uuid, + event_request=event_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_update_without_preload_content( + self, + event_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event.")], + event_request: EventRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_update + + Event Read-Only Viewset + + :param event_uuid: A UUID string identifying this Event. (required) + :type event_uuid: UUID + :param event_request: (required) + :type event_request: EventRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_update_serialize( + event_uuid=event_uuid, + event_request=event_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Event", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_update_serialize( + self, + event_uuid, + event_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if event_uuid is not None: + _path_params['event_uuid'] = event_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if event_request is not None: + _body_params = event_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/events/events/{event_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_events_volume_list( + self, + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + history_days: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[EventVolume]: + """events_events_volume_list + + Get event volume for specified filters and timeframe + + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param history_days: + :type history_days: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_volume_list_serialize( + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + history_days=history_days, + ordering=ordering, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[EventVolume]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_events_volume_list_with_http_info( + self, + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + history_days: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[EventVolume]]: + """events_events_volume_list + + Get event volume for specified filters and timeframe + + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param history_days: + :type history_days: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_volume_list_serialize( + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + history_days=history_days, + ordering=ordering, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[EventVolume]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_events_volume_list_without_preload_content( + self, + action: Optional[StrictStr] = None, + actions: Optional[List[EventActions]] = None, + brand_name: Annotated[Optional[StrictStr], Field(description="Brand name")] = None, + client_ip: Optional[StrictStr] = None, + context_authorized_app: Annotated[Optional[StrictStr], Field(description="Context Authorized application")] = None, + context_device: Annotated[Optional[StrictStr], Field(description="Context Device Primary Key")] = None, + context_model_app: Annotated[Optional[StrictStr], Field(description="Context Model App")] = None, + context_model_name: Annotated[Optional[StrictStr], Field(description="Context Model Name")] = None, + context_model_pk: Annotated[Optional[StrictStr], Field(description="Context Model Primary Key")] = None, + history_days: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + username: Annotated[Optional[StrictStr], Field(description="Username")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_events_volume_list + + Get event volume for specified filters and timeframe + + :param action: + :type action: str + :param actions: + :type actions: List[EventActions] + :param brand_name: Brand name + :type brand_name: str + :param client_ip: + :type client_ip: str + :param context_authorized_app: Context Authorized application + :type context_authorized_app: str + :param context_device: Context Device Primary Key + :type context_device: str + :param context_model_app: Context Model App + :type context_model_app: str + :param context_model_name: Context Model Name + :type context_model_name: str + :param context_model_pk: Context Model Primary Key + :type context_model_pk: str + :param history_days: + :type history_days: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param username: Username + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_events_volume_list_serialize( + action=action, + actions=actions, + brand_name=brand_name, + client_ip=client_ip, + context_authorized_app=context_authorized_app, + context_device=context_device, + context_model_app=context_model_app, + context_model_name=context_model_name, + context_model_pk=context_model_pk, + history_days=history_days, + ordering=ordering, + search=search, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[EventVolume]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_events_volume_list_serialize( + self, + action, + actions, + brand_name, + client_ip, + context_authorized_app, + context_device, + context_model_app, + context_model_name, + context_model_pk, + history_days, + ordering, + search, + username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'actions': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if action is not None: + + _query_params.append(('action', action)) + + if actions is not None: + + _query_params.append(('actions', actions)) + + if brand_name is not None: + + _query_params.append(('brand_name', brand_name)) + + if client_ip is not None: + + _query_params.append(('client_ip', client_ip)) + + if context_authorized_app is not None: + + _query_params.append(('context_authorized_app', context_authorized_app)) + + if context_device is not None: + + _query_params.append(('context_device', context_device)) + + if context_model_app is not None: + + _query_params.append(('context_model_app', context_model_app)) + + if context_model_name is not None: + + _query_params.append(('context_model_name', context_model_name)) + + if context_model_pk is not None: + + _query_params.append(('context_model_pk', context_model_pk)) + + if history_days is not None: + + _query_params.append(('history_days', history_days)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if search is not None: + + _query_params.append(('search', search)) + + if username is not None: + + _query_params.append(('username', username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/events/volume/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_notifications_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """events_notifications_destroy + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_notifications_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """events_notifications_destroy + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_notifications_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_notifications_destroy + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_notifications_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/events/notifications/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_notifications_list( + self, + body: Optional[StrictStr] = None, + created: Optional[datetime] = None, + event: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + seen: Optional[StrictBool] = None, + severity: Optional[SeverityEnum] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedNotificationList: + """events_notifications_list + + Notification Viewset + + :param body: + :type body: str + :param created: + :type created: datetime + :param event: + :type event: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param seen: + :type seen: bool + :param severity: + :type severity: SeverityEnum + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_list_serialize( + body=body, + created=created, + event=event, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + seen=seen, + severity=severity, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_notifications_list_with_http_info( + self, + body: Optional[StrictStr] = None, + created: Optional[datetime] = None, + event: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + seen: Optional[StrictBool] = None, + severity: Optional[SeverityEnum] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedNotificationList]: + """events_notifications_list + + Notification Viewset + + :param body: + :type body: str + :param created: + :type created: datetime + :param event: + :type event: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param seen: + :type seen: bool + :param severity: + :type severity: SeverityEnum + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_list_serialize( + body=body, + created=created, + event=event, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + seen=seen, + severity=severity, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_notifications_list_without_preload_content( + self, + body: Optional[StrictStr] = None, + created: Optional[datetime] = None, + event: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + seen: Optional[StrictBool] = None, + severity: Optional[SeverityEnum] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_notifications_list + + Notification Viewset + + :param body: + :type body: str + :param created: + :type created: datetime + :param event: + :type event: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param seen: + :type seen: bool + :param severity: + :type severity: SeverityEnum + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_list_serialize( + body=body, + created=created, + event=event, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + seen=seen, + severity=severity, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_notifications_list_serialize( + self, + body, + created, + event, + ordering, + page, + page_size, + search, + seen, + severity, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if body is not None: + + _query_params.append(('body', body)) + + if created is not None: + if isinstance(created, datetime): + _query_params.append( + ( + 'created', + created.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('created', created)) + + if event is not None: + + _query_params.append(('event', event)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if seen is not None: + + _query_params.append(('seen', seen)) + + if severity is not None: + + _query_params.append(('severity', severity.value)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/notifications/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_notifications_mark_all_seen_create( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """events_notifications_mark_all_seen_create + + Mark all the user's notifications as seen + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_mark_all_seen_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_notifications_mark_all_seen_create_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """events_notifications_mark_all_seen_create + + Mark all the user's notifications as seen + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_mark_all_seen_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_notifications_mark_all_seen_create_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_notifications_mark_all_seen_create + + Mark all the user's notifications as seen + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_mark_all_seen_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_notifications_mark_all_seen_create_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/events/notifications/mark_all_seen/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_notifications_partial_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + patched_notification_request: Optional[PatchedNotificationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Notification: + """events_notifications_partial_update + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param patched_notification_request: + :type patched_notification_request: PatchedNotificationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_partial_update_serialize( + uuid=uuid, + patched_notification_request=patched_notification_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Notification", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_notifications_partial_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + patched_notification_request: Optional[PatchedNotificationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Notification]: + """events_notifications_partial_update + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param patched_notification_request: + :type patched_notification_request: PatchedNotificationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_partial_update_serialize( + uuid=uuid, + patched_notification_request=patched_notification_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Notification", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_notifications_partial_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + patched_notification_request: Optional[PatchedNotificationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_notifications_partial_update + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param patched_notification_request: + :type patched_notification_request: PatchedNotificationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_partial_update_serialize( + uuid=uuid, + patched_notification_request=patched_notification_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Notification", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_notifications_partial_update_serialize( + self, + uuid, + patched_notification_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_notification_request is not None: + _body_params = patched_notification_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/events/notifications/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_notifications_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Notification: + """events_notifications_retrieve + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Notification", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_notifications_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Notification]: + """events_notifications_retrieve + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Notification", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_notifications_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_notifications_retrieve + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Notification", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_notifications_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/notifications/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_notifications_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + notification_request: Optional[NotificationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Notification: + """events_notifications_update + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param notification_request: + :type notification_request: NotificationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_update_serialize( + uuid=uuid, + notification_request=notification_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Notification", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_notifications_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + notification_request: Optional[NotificationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Notification]: + """events_notifications_update + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param notification_request: + :type notification_request: NotificationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_update_serialize( + uuid=uuid, + notification_request=notification_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Notification", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_notifications_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + notification_request: Optional[NotificationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_notifications_update + + Notification Viewset + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param notification_request: + :type notification_request: NotificationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_update_serialize( + uuid=uuid, + notification_request=notification_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Notification", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_notifications_update_serialize( + self, + uuid, + notification_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if notification_request is not None: + _body_params = notification_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/events/notifications/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_notifications_used_by_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """events_notifications_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_notifications_used_by_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """events_notifications_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_notifications_used_by_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_notifications_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Notification. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_notifications_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_notifications_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/notifications/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_rules_create( + self, + notification_rule_request: NotificationRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationRule: + """events_rules_create + + NotificationRule Viewset + + :param notification_rule_request: (required) + :type notification_rule_request: NotificationRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_create_serialize( + notification_rule_request=notification_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_rules_create_with_http_info( + self, + notification_rule_request: NotificationRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationRule]: + """events_rules_create + + NotificationRule Viewset + + :param notification_rule_request: (required) + :type notification_rule_request: NotificationRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_create_serialize( + notification_rule_request=notification_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_rules_create_without_preload_content( + self, + notification_rule_request: NotificationRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_rules_create + + NotificationRule Viewset + + :param notification_rule_request: (required) + :type notification_rule_request: NotificationRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_create_serialize( + notification_rule_request=notification_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_rules_create_serialize( + self, + notification_rule_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if notification_rule_request is not None: + _body_params = notification_rule_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/events/rules/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_rules_destroy( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """events_rules_destroy + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_rules_destroy_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """events_rules_destroy + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_rules_destroy_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_rules_destroy + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_rules_destroy_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/events/rules/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_rules_list( + self, + destination_group__name: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + severity: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedNotificationRuleList: + """events_rules_list + + NotificationRule Viewset + + :param destination_group__name: + :type destination_group__name: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param severity: + :type severity: SeverityEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_list_serialize( + destination_group__name=destination_group__name, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + severity=severity, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationRuleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_rules_list_with_http_info( + self, + destination_group__name: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + severity: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedNotificationRuleList]: + """events_rules_list + + NotificationRule Viewset + + :param destination_group__name: + :type destination_group__name: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param severity: + :type severity: SeverityEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_list_serialize( + destination_group__name=destination_group__name, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + severity=severity, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationRuleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_rules_list_without_preload_content( + self, + destination_group__name: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + severity: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_rules_list + + NotificationRule Viewset + + :param destination_group__name: + :type destination_group__name: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param severity: + :type severity: SeverityEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_list_serialize( + destination_group__name=destination_group__name, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + severity=severity, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationRuleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_rules_list_serialize( + self, + destination_group__name, + name, + ordering, + page, + page_size, + search, + severity, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if destination_group__name is not None: + + _query_params.append(('destination_group__name', destination_group__name)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if severity is not None: + + _query_params.append(('severity', severity.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/rules/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_rules_partial_update( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + patched_notification_rule_request: Optional[PatchedNotificationRuleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationRule: + """events_rules_partial_update + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param patched_notification_rule_request: + :type patched_notification_rule_request: PatchedNotificationRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_notification_rule_request=patched_notification_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_rules_partial_update_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + patched_notification_rule_request: Optional[PatchedNotificationRuleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationRule]: + """events_rules_partial_update + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param patched_notification_rule_request: + :type patched_notification_rule_request: PatchedNotificationRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_notification_rule_request=patched_notification_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_rules_partial_update_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + patched_notification_rule_request: Optional[PatchedNotificationRuleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_rules_partial_update + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param patched_notification_rule_request: + :type patched_notification_rule_request: PatchedNotificationRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_notification_rule_request=patched_notification_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_rules_partial_update_serialize( + self, + pbm_uuid, + patched_notification_rule_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_notification_rule_request is not None: + _body_params = patched_notification_rule_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/events/rules/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_rules_retrieve( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationRule: + """events_rules_retrieve + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_rules_retrieve_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationRule]: + """events_rules_retrieve + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_rules_retrieve_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_rules_retrieve + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_rules_retrieve_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/rules/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_rules_update( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + notification_rule_request: NotificationRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationRule: + """events_rules_update + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param notification_rule_request: (required) + :type notification_rule_request: NotificationRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_update_serialize( + pbm_uuid=pbm_uuid, + notification_rule_request=notification_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_rules_update_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + notification_rule_request: NotificationRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationRule]: + """events_rules_update + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param notification_rule_request: (required) + :type notification_rule_request: NotificationRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_update_serialize( + pbm_uuid=pbm_uuid, + notification_rule_request=notification_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_rules_update_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + notification_rule_request: NotificationRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_rules_update + + NotificationRule Viewset + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param notification_rule_request: (required) + :type notification_rule_request: NotificationRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_update_serialize( + pbm_uuid=pbm_uuid, + notification_rule_request=notification_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_rules_update_serialize( + self, + pbm_uuid, + notification_rule_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if notification_rule_request is not None: + _body_params = notification_rule_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/events/rules/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_rules_used_by_list( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """events_rules_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_rules_used_by_list_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """events_rules_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_rules_used_by_list_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_rules_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this Notification Rule. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_rules_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_rules_used_by_list_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/rules/{pbm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_transports_create( + self, + notification_transport_request: NotificationTransportRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationTransport: + """events_transports_create + + NotificationTransport Viewset + + :param notification_transport_request: (required) + :type notification_transport_request: NotificationTransportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_create_serialize( + notification_transport_request=notification_transport_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_transports_create_with_http_info( + self, + notification_transport_request: NotificationTransportRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationTransport]: + """events_transports_create + + NotificationTransport Viewset + + :param notification_transport_request: (required) + :type notification_transport_request: NotificationTransportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_create_serialize( + notification_transport_request=notification_transport_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_transports_create_without_preload_content( + self, + notification_transport_request: NotificationTransportRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_transports_create + + NotificationTransport Viewset + + :param notification_transport_request: (required) + :type notification_transport_request: NotificationTransportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_create_serialize( + notification_transport_request=notification_transport_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_transports_create_serialize( + self, + notification_transport_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if notification_transport_request is not None: + _body_params = notification_transport_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/events/transports/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_transports_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """events_transports_destroy + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_transports_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """events_transports_destroy + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_transports_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_transports_destroy + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_transports_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/events/transports/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_transports_list( + self, + mode: Optional[TransportModeEnum] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + send_once: Optional[StrictBool] = None, + webhook_url: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedNotificationTransportList: + """events_transports_list + + NotificationTransport Viewset + + :param mode: + :type mode: TransportModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param send_once: + :type send_once: bool + :param webhook_url: + :type webhook_url: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_list_serialize( + mode=mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + send_once=send_once, + webhook_url=webhook_url, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationTransportList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_transports_list_with_http_info( + self, + mode: Optional[TransportModeEnum] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + send_once: Optional[StrictBool] = None, + webhook_url: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedNotificationTransportList]: + """events_transports_list + + NotificationTransport Viewset + + :param mode: + :type mode: TransportModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param send_once: + :type send_once: bool + :param webhook_url: + :type webhook_url: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_list_serialize( + mode=mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + send_once=send_once, + webhook_url=webhook_url, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationTransportList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_transports_list_without_preload_content( + self, + mode: Optional[TransportModeEnum] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + send_once: Optional[StrictBool] = None, + webhook_url: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_transports_list + + NotificationTransport Viewset + + :param mode: + :type mode: TransportModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param send_once: + :type send_once: bool + :param webhook_url: + :type webhook_url: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_list_serialize( + mode=mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + send_once=send_once, + webhook_url=webhook_url, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationTransportList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_transports_list_serialize( + self, + mode, + name, + ordering, + page, + page_size, + search, + send_once, + webhook_url, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if mode is not None: + + _query_params.append(('mode', mode.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if send_once is not None: + + _query_params.append(('send_once', send_once)) + + if webhook_url is not None: + + _query_params.append(('webhook_url', webhook_url)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/transports/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_transports_partial_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + patched_notification_transport_request: Optional[PatchedNotificationTransportRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationTransport: + """events_transports_partial_update + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param patched_notification_transport_request: + :type patched_notification_transport_request: PatchedNotificationTransportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_partial_update_serialize( + uuid=uuid, + patched_notification_transport_request=patched_notification_transport_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_transports_partial_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + patched_notification_transport_request: Optional[PatchedNotificationTransportRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationTransport]: + """events_transports_partial_update + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param patched_notification_transport_request: + :type patched_notification_transport_request: PatchedNotificationTransportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_partial_update_serialize( + uuid=uuid, + patched_notification_transport_request=patched_notification_transport_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_transports_partial_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + patched_notification_transport_request: Optional[PatchedNotificationTransportRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_transports_partial_update + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param patched_notification_transport_request: + :type patched_notification_transport_request: PatchedNotificationTransportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_partial_update_serialize( + uuid=uuid, + patched_notification_transport_request=patched_notification_transport_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_transports_partial_update_serialize( + self, + uuid, + patched_notification_transport_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_notification_transport_request is not None: + _body_params = patched_notification_transport_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/events/transports/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_transports_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationTransport: + """events_transports_retrieve + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_transports_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationTransport]: + """events_transports_retrieve + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_transports_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_transports_retrieve + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_transports_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/transports/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_transports_test_create( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationTransportTest: + """events_transports_test_create + + Send example notification using selected transport. Requires Modify permissions. + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_test_create_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransportTest", + '500': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_transports_test_create_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationTransportTest]: + """events_transports_test_create + + Send example notification using selected transport. Requires Modify permissions. + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_test_create_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransportTest", + '500': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_transports_test_create_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_transports_test_create + + Send example notification using selected transport. Requires Modify permissions. + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_test_create_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransportTest", + '500': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_transports_test_create_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/events/transports/{uuid}/test/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_transports_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + notification_transport_request: NotificationTransportRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationTransport: + """events_transports_update + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param notification_transport_request: (required) + :type notification_transport_request: NotificationTransportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_update_serialize( + uuid=uuid, + notification_transport_request=notification_transport_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_transports_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + notification_transport_request: NotificationTransportRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationTransport]: + """events_transports_update + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param notification_transport_request: (required) + :type notification_transport_request: NotificationTransportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_update_serialize( + uuid=uuid, + notification_transport_request=notification_transport_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_transports_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + notification_transport_request: NotificationTransportRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_transports_update + + NotificationTransport Viewset + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param notification_transport_request: (required) + :type notification_transport_request: NotificationTransportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_update_serialize( + uuid=uuid, + notification_transport_request=notification_transport_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationTransport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_transports_update_serialize( + self, + uuid, + notification_transport_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if notification_transport_request is not None: + _body_params = notification_transport_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/events/transports/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def events_transports_used_by_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """events_transports_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def events_transports_used_by_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """events_transports_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def events_transports_used_by_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Notification Transport.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """events_transports_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Notification Transport. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._events_transports_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _events_transports_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/events/transports/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/flows_api.py b/authentik_client/api/flows_api.py new file mode 100644 index 000000000..79528f785 --- /dev/null +++ b/authentik_client/api/flows_api.py @@ -0,0 +1,6461 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictBytes, StrictInt, StrictStr +from typing import Any, List, Optional, Tuple, Union +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.cache import Cache +from authentik_client.models.challenge_types import ChallengeTypes +from authentik_client.models.flow import Flow +from authentik_client.models.flow_challenge_response_request import FlowChallengeResponseRequest +from authentik_client.models.flow_diagram import FlowDiagram +from authentik_client.models.flow_inspection import FlowInspection +from authentik_client.models.flow_request import FlowRequest +from authentik_client.models.flow_stage_binding import FlowStageBinding +from authentik_client.models.flow_stage_binding_request import FlowStageBindingRequest +from authentik_client.models.link import Link +from authentik_client.models.paginated_flow_list import PaginatedFlowList +from authentik_client.models.paginated_flow_stage_binding_list import PaginatedFlowStageBindingList +from authentik_client.models.patched_flow_request import PatchedFlowRequest +from authentik_client.models.patched_flow_stage_binding_request import PatchedFlowStageBindingRequest +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class FlowsApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def flows_bindings_create( + self, + flow_stage_binding_request: FlowStageBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FlowStageBinding: + """flows_bindings_create + + FlowStageBinding Viewset + + :param flow_stage_binding_request: (required) + :type flow_stage_binding_request: FlowStageBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_create_serialize( + flow_stage_binding_request=flow_stage_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_bindings_create_with_http_info( + self, + flow_stage_binding_request: FlowStageBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FlowStageBinding]: + """flows_bindings_create + + FlowStageBinding Viewset + + :param flow_stage_binding_request: (required) + :type flow_stage_binding_request: FlowStageBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_create_serialize( + flow_stage_binding_request=flow_stage_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_bindings_create_without_preload_content( + self, + flow_stage_binding_request: FlowStageBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_bindings_create + + FlowStageBinding Viewset + + :param flow_stage_binding_request: (required) + :type flow_stage_binding_request: FlowStageBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_create_serialize( + flow_stage_binding_request=flow_stage_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_bindings_create_serialize( + self, + flow_stage_binding_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if flow_stage_binding_request is not None: + _body_params = flow_stage_binding_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/flows/bindings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_bindings_destroy( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """flows_bindings_destroy + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_destroy_serialize( + fsb_uuid=fsb_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_bindings_destroy_with_http_info( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """flows_bindings_destroy + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_destroy_serialize( + fsb_uuid=fsb_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_bindings_destroy_without_preload_content( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_bindings_destroy + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_destroy_serialize( + fsb_uuid=fsb_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_bindings_destroy_serialize( + self, + fsb_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if fsb_uuid is not None: + _path_params['fsb_uuid'] = fsb_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/flows/bindings/{fsb_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_bindings_list( + self, + evaluate_on_plan: Optional[StrictBool] = None, + fsb_uuid: Optional[UUID] = None, + invalid_response_action: Optional[Any] = None, + order: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policies: Optional[List[UUID]] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + re_evaluate_policies: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage: Optional[UUID] = None, + target: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedFlowStageBindingList: + """flows_bindings_list + + FlowStageBinding Viewset + + :param evaluate_on_plan: + :type evaluate_on_plan: bool + :param fsb_uuid: + :type fsb_uuid: UUID + :param invalid_response_action: + :type invalid_response_action: InvalidResponseActionEnum + :param order: + :type order: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policies: + :type policies: List[UUID] + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param re_evaluate_policies: + :type re_evaluate_policies: bool + :param search: A search term. + :type search: str + :param stage: + :type stage: UUID + :param target: + :type target: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_list_serialize( + evaluate_on_plan=evaluate_on_plan, + fsb_uuid=fsb_uuid, + invalid_response_action=invalid_response_action, + order=order, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policies=policies, + policy_engine_mode=policy_engine_mode, + re_evaluate_policies=re_evaluate_policies, + search=search, + stage=stage, + target=target, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedFlowStageBindingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_bindings_list_with_http_info( + self, + evaluate_on_plan: Optional[StrictBool] = None, + fsb_uuid: Optional[UUID] = None, + invalid_response_action: Optional[Any] = None, + order: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policies: Optional[List[UUID]] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + re_evaluate_policies: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage: Optional[UUID] = None, + target: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedFlowStageBindingList]: + """flows_bindings_list + + FlowStageBinding Viewset + + :param evaluate_on_plan: + :type evaluate_on_plan: bool + :param fsb_uuid: + :type fsb_uuid: UUID + :param invalid_response_action: + :type invalid_response_action: InvalidResponseActionEnum + :param order: + :type order: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policies: + :type policies: List[UUID] + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param re_evaluate_policies: + :type re_evaluate_policies: bool + :param search: A search term. + :type search: str + :param stage: + :type stage: UUID + :param target: + :type target: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_list_serialize( + evaluate_on_plan=evaluate_on_plan, + fsb_uuid=fsb_uuid, + invalid_response_action=invalid_response_action, + order=order, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policies=policies, + policy_engine_mode=policy_engine_mode, + re_evaluate_policies=re_evaluate_policies, + search=search, + stage=stage, + target=target, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedFlowStageBindingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_bindings_list_without_preload_content( + self, + evaluate_on_plan: Optional[StrictBool] = None, + fsb_uuid: Optional[UUID] = None, + invalid_response_action: Optional[Any] = None, + order: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policies: Optional[List[UUID]] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + re_evaluate_policies: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage: Optional[UUID] = None, + target: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_bindings_list + + FlowStageBinding Viewset + + :param evaluate_on_plan: + :type evaluate_on_plan: bool + :param fsb_uuid: + :type fsb_uuid: UUID + :param invalid_response_action: + :type invalid_response_action: InvalidResponseActionEnum + :param order: + :type order: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policies: + :type policies: List[UUID] + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param re_evaluate_policies: + :type re_evaluate_policies: bool + :param search: A search term. + :type search: str + :param stage: + :type stage: UUID + :param target: + :type target: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_list_serialize( + evaluate_on_plan=evaluate_on_plan, + fsb_uuid=fsb_uuid, + invalid_response_action=invalid_response_action, + order=order, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policies=policies, + policy_engine_mode=policy_engine_mode, + re_evaluate_policies=re_evaluate_policies, + search=search, + stage=stage, + target=target, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedFlowStageBindingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_bindings_list_serialize( + self, + evaluate_on_plan, + fsb_uuid, + invalid_response_action, + order, + ordering, + page, + page_size, + pbm_uuid, + policies, + policy_engine_mode, + re_evaluate_policies, + search, + stage, + target, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'policies': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if evaluate_on_plan is not None: + + _query_params.append(('evaluate_on_plan', evaluate_on_plan)) + + if fsb_uuid is not None: + + _query_params.append(('fsb_uuid', fsb_uuid)) + + if invalid_response_action is not None: + + _query_params.append(('invalid_response_action', invalid_response_action.value)) + + if order is not None: + + _query_params.append(('order', order)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if policies is not None: + + _query_params.append(('policies', policies)) + + if policy_engine_mode is not None: + + _query_params.append(('policy_engine_mode', policy_engine_mode.value)) + + if re_evaluate_policies is not None: + + _query_params.append(('re_evaluate_policies', re_evaluate_policies)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage is not None: + + _query_params.append(('stage', stage)) + + if target is not None: + + _query_params.append(('target', target)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/bindings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_bindings_partial_update( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + patched_flow_stage_binding_request: Optional[PatchedFlowStageBindingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FlowStageBinding: + """flows_bindings_partial_update + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param patched_flow_stage_binding_request: + :type patched_flow_stage_binding_request: PatchedFlowStageBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_partial_update_serialize( + fsb_uuid=fsb_uuid, + patched_flow_stage_binding_request=patched_flow_stage_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_bindings_partial_update_with_http_info( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + patched_flow_stage_binding_request: Optional[PatchedFlowStageBindingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FlowStageBinding]: + """flows_bindings_partial_update + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param patched_flow_stage_binding_request: + :type patched_flow_stage_binding_request: PatchedFlowStageBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_partial_update_serialize( + fsb_uuid=fsb_uuid, + patched_flow_stage_binding_request=patched_flow_stage_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_bindings_partial_update_without_preload_content( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + patched_flow_stage_binding_request: Optional[PatchedFlowStageBindingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_bindings_partial_update + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param patched_flow_stage_binding_request: + :type patched_flow_stage_binding_request: PatchedFlowStageBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_partial_update_serialize( + fsb_uuid=fsb_uuid, + patched_flow_stage_binding_request=patched_flow_stage_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_bindings_partial_update_serialize( + self, + fsb_uuid, + patched_flow_stage_binding_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if fsb_uuid is not None: + _path_params['fsb_uuid'] = fsb_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_flow_stage_binding_request is not None: + _body_params = patched_flow_stage_binding_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/flows/bindings/{fsb_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_bindings_retrieve( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FlowStageBinding: + """flows_bindings_retrieve + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_retrieve_serialize( + fsb_uuid=fsb_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_bindings_retrieve_with_http_info( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FlowStageBinding]: + """flows_bindings_retrieve + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_retrieve_serialize( + fsb_uuid=fsb_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_bindings_retrieve_without_preload_content( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_bindings_retrieve + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_retrieve_serialize( + fsb_uuid=fsb_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_bindings_retrieve_serialize( + self, + fsb_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if fsb_uuid is not None: + _path_params['fsb_uuid'] = fsb_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/bindings/{fsb_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_bindings_update( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + flow_stage_binding_request: FlowStageBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FlowStageBinding: + """flows_bindings_update + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param flow_stage_binding_request: (required) + :type flow_stage_binding_request: FlowStageBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_update_serialize( + fsb_uuid=fsb_uuid, + flow_stage_binding_request=flow_stage_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_bindings_update_with_http_info( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + flow_stage_binding_request: FlowStageBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FlowStageBinding]: + """flows_bindings_update + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param flow_stage_binding_request: (required) + :type flow_stage_binding_request: FlowStageBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_update_serialize( + fsb_uuid=fsb_uuid, + flow_stage_binding_request=flow_stage_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_bindings_update_without_preload_content( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + flow_stage_binding_request: FlowStageBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_bindings_update + + FlowStageBinding Viewset + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param flow_stage_binding_request: (required) + :type flow_stage_binding_request: FlowStageBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_update_serialize( + fsb_uuid=fsb_uuid, + flow_stage_binding_request=flow_stage_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowStageBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_bindings_update_serialize( + self, + fsb_uuid, + flow_stage_binding_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if fsb_uuid is not None: + _path_params['fsb_uuid'] = fsb_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if flow_stage_binding_request is not None: + _body_params = flow_stage_binding_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/flows/bindings/{fsb_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_bindings_used_by_list( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """flows_bindings_used_by_list + + Get a list of all objects that use this object + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_used_by_list_serialize( + fsb_uuid=fsb_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_bindings_used_by_list_with_http_info( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """flows_bindings_used_by_list + + Get a list of all objects that use this object + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_used_by_list_serialize( + fsb_uuid=fsb_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_bindings_used_by_list_without_preload_content( + self, + fsb_uuid: Annotated[UUID, Field(description="A UUID string identifying this Flow Stage Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_bindings_used_by_list + + Get a list of all objects that use this object + + :param fsb_uuid: A UUID string identifying this Flow Stage Binding. (required) + :type fsb_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_bindings_used_by_list_serialize( + fsb_uuid=fsb_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_bindings_used_by_list_serialize( + self, + fsb_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if fsb_uuid is not None: + _path_params['fsb_uuid'] = fsb_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/bindings/{fsb_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_executor_get( + self, + flow_slug: StrictStr, + query: Annotated[StrictStr, Field(description="Querystring as received")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ChallengeTypes: + """flows_executor_get + + Get the next pending challenge from the currently active flow. + + :param flow_slug: (required) + :type flow_slug: str + :param query: Querystring as received (required) + :type query: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_executor_get_serialize( + flow_slug=flow_slug, + query=query, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ChallengeTypes", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_executor_get_with_http_info( + self, + flow_slug: StrictStr, + query: Annotated[StrictStr, Field(description="Querystring as received")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ChallengeTypes]: + """flows_executor_get + + Get the next pending challenge from the currently active flow. + + :param flow_slug: (required) + :type flow_slug: str + :param query: Querystring as received (required) + :type query: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_executor_get_serialize( + flow_slug=flow_slug, + query=query, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ChallengeTypes", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_executor_get_without_preload_content( + self, + flow_slug: StrictStr, + query: Annotated[StrictStr, Field(description="Querystring as received")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_executor_get + + Get the next pending challenge from the currently active flow. + + :param flow_slug: (required) + :type flow_slug: str + :param query: Querystring as received (required) + :type query: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_executor_get_serialize( + flow_slug=flow_slug, + query=query, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ChallengeTypes", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_executor_get_serialize( + self, + flow_slug, + query, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if flow_slug is not None: + _path_params['flow_slug'] = flow_slug + # process the query parameters + if query is not None: + + _query_params.append(('query', query)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/executor/{flow_slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_executor_solve( + self, + flow_slug: StrictStr, + query: Annotated[StrictStr, Field(description="Querystring as received")], + flow_challenge_response_request: Optional[FlowChallengeResponseRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ChallengeTypes: + """flows_executor_solve + + Solve the previously retrieved challenge and advanced to the next stage. + + :param flow_slug: (required) + :type flow_slug: str + :param query: Querystring as received (required) + :type query: str + :param flow_challenge_response_request: + :type flow_challenge_response_request: FlowChallengeResponseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_executor_solve_serialize( + flow_slug=flow_slug, + query=query, + flow_challenge_response_request=flow_challenge_response_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ChallengeTypes", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_executor_solve_with_http_info( + self, + flow_slug: StrictStr, + query: Annotated[StrictStr, Field(description="Querystring as received")], + flow_challenge_response_request: Optional[FlowChallengeResponseRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ChallengeTypes]: + """flows_executor_solve + + Solve the previously retrieved challenge and advanced to the next stage. + + :param flow_slug: (required) + :type flow_slug: str + :param query: Querystring as received (required) + :type query: str + :param flow_challenge_response_request: + :type flow_challenge_response_request: FlowChallengeResponseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_executor_solve_serialize( + flow_slug=flow_slug, + query=query, + flow_challenge_response_request=flow_challenge_response_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ChallengeTypes", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_executor_solve_without_preload_content( + self, + flow_slug: StrictStr, + query: Annotated[StrictStr, Field(description="Querystring as received")], + flow_challenge_response_request: Optional[FlowChallengeResponseRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_executor_solve + + Solve the previously retrieved challenge and advanced to the next stage. + + :param flow_slug: (required) + :type flow_slug: str + :param query: Querystring as received (required) + :type query: str + :param flow_challenge_response_request: + :type flow_challenge_response_request: FlowChallengeResponseRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_executor_solve_serialize( + flow_slug=flow_slug, + query=query, + flow_challenge_response_request=flow_challenge_response_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ChallengeTypes", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_executor_solve_serialize( + self, + flow_slug, + query, + flow_challenge_response_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if flow_slug is not None: + _path_params['flow_slug'] = flow_slug + # process the query parameters + if query is not None: + + _query_params.append(('query', query)) + + # process the header parameters + # process the form parameters + # process the body parameter + if flow_challenge_response_request is not None: + _body_params = flow_challenge_response_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/flows/executor/{flow_slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_inspector_get( + self, + flow_slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FlowInspection: + """flows_inspector_get + + Get current flow state and record it + + :param flow_slug: (required) + :type flow_slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_inspector_get_serialize( + flow_slug=flow_slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowInspection", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_inspector_get_with_http_info( + self, + flow_slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FlowInspection]: + """flows_inspector_get + + Get current flow state and record it + + :param flow_slug: (required) + :type flow_slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_inspector_get_serialize( + flow_slug=flow_slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowInspection", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_inspector_get_without_preload_content( + self, + flow_slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_inspector_get + + Get current flow state and record it + + :param flow_slug: (required) + :type flow_slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_inspector_get_serialize( + flow_slug=flow_slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowInspection", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_inspector_get_serialize( + self, + flow_slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if flow_slug is not None: + _path_params['flow_slug'] = flow_slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/inspector/{flow_slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_cache_clear_create( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """flows_instances_cache_clear_create + + Clear flow cache + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_cache_clear_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_cache_clear_create_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """flows_instances_cache_clear_create + + Clear flow cache + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_cache_clear_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_cache_clear_create_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_cache_clear_create + + Clear flow cache + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_cache_clear_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_cache_clear_create_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/flows/instances/cache_clear/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_cache_info_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Cache: + """flows_instances_cache_info_retrieve + + Info about cached flows + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_cache_info_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Cache", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_cache_info_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Cache]: + """flows_instances_cache_info_retrieve + + Info about cached flows + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_cache_info_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Cache", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_cache_info_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_cache_info_retrieve + + Info about cached flows + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_cache_info_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Cache", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_cache_info_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/instances/cache_info/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_create( + self, + flow_request: FlowRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Flow: + """flows_instances_create + + Flow Viewset + + :param flow_request: (required) + :type flow_request: FlowRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_create_serialize( + flow_request=flow_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_create_with_http_info( + self, + flow_request: FlowRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Flow]: + """flows_instances_create + + Flow Viewset + + :param flow_request: (required) + :type flow_request: FlowRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_create_serialize( + flow_request=flow_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_create_without_preload_content( + self, + flow_request: FlowRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_create + + Flow Viewset + + :param flow_request: (required) + :type flow_request: FlowRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_create_serialize( + flow_request=flow_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_create_serialize( + self, + flow_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if flow_request is not None: + _body_params = flow_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/flows/instances/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """flows_instances_destroy + + Flow Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """flows_instances_destroy + + Flow Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_destroy + + Flow Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/flows/instances/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_diagram_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> FlowDiagram: + """flows_instances_diagram_retrieve + + Return diagram for flow with slug `slug`, in the format used by flowchart.js + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_diagram_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowDiagram", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_diagram_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[FlowDiagram]: + """flows_instances_diagram_retrieve + + Return diagram for flow with slug `slug`, in the format used by flowchart.js + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_diagram_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowDiagram", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_diagram_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_diagram_retrieve + + Return diagram for flow with slug `slug`, in the format used by flowchart.js + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_diagram_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "FlowDiagram", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_diagram_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/instances/{slug}/diagram/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_execute_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Link: + """flows_instances_execute_retrieve + + Execute flow for current user + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_execute_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Link", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_execute_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Link]: + """flows_instances_execute_retrieve + + Execute flow for current user + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_execute_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Link", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_execute_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_execute_retrieve + + Execute flow for current user + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_execute_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Link", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_execute_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/instances/{slug}/execute/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_export_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> bytes: + """flows_instances_export_retrieve + + Export flow to .yaml file + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_export_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "bytes", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_export_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[bytes]: + """flows_instances_export_retrieve + + Export flow to .yaml file + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_export_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "bytes", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_export_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_export_retrieve + + Export flow to .yaml file + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_export_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "bytes", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_export_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/instances/{slug}/export/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_list( + self, + denied_action: Optional[Any] = None, + designation: Optional[Any] = None, + flow_uuid: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedFlowList: + """flows_instances_list + + Flow Viewset + + :param denied_action: + :type denied_action: DeniedActionEnum + :param designation: + :type designation: FlowDesignationEnum + :param flow_uuid: + :type flow_uuid: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_list_serialize( + denied_action=denied_action, + designation=designation, + flow_uuid=flow_uuid, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedFlowList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_list_with_http_info( + self, + denied_action: Optional[Any] = None, + designation: Optional[Any] = None, + flow_uuid: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedFlowList]: + """flows_instances_list + + Flow Viewset + + :param denied_action: + :type denied_action: DeniedActionEnum + :param designation: + :type designation: FlowDesignationEnum + :param flow_uuid: + :type flow_uuid: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_list_serialize( + denied_action=denied_action, + designation=designation, + flow_uuid=flow_uuid, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedFlowList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_list_without_preload_content( + self, + denied_action: Optional[Any] = None, + designation: Optional[Any] = None, + flow_uuid: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_list + + Flow Viewset + + :param denied_action: + :type denied_action: DeniedActionEnum + :param designation: + :type designation: FlowDesignationEnum + :param flow_uuid: + :type flow_uuid: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_list_serialize( + denied_action=denied_action, + designation=designation, + flow_uuid=flow_uuid, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedFlowList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_list_serialize( + self, + denied_action, + designation, + flow_uuid, + name, + ordering, + page, + page_size, + search, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if denied_action is not None: + + _query_params.append(('denied_action', denied_action.value)) + + if designation is not None: + + _query_params.append(('designation', designation.value)) + + if flow_uuid is not None: + + _query_params.append(('flow_uuid', flow_uuid)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/instances/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_partial_update( + self, + slug: StrictStr, + patched_flow_request: Optional[PatchedFlowRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Flow: + """flows_instances_partial_update + + Flow Viewset + + :param slug: (required) + :type slug: str + :param patched_flow_request: + :type patched_flow_request: PatchedFlowRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_partial_update_serialize( + slug=slug, + patched_flow_request=patched_flow_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_partial_update_with_http_info( + self, + slug: StrictStr, + patched_flow_request: Optional[PatchedFlowRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Flow]: + """flows_instances_partial_update + + Flow Viewset + + :param slug: (required) + :type slug: str + :param patched_flow_request: + :type patched_flow_request: PatchedFlowRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_partial_update_serialize( + slug=slug, + patched_flow_request=patched_flow_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_partial_update_without_preload_content( + self, + slug: StrictStr, + patched_flow_request: Optional[PatchedFlowRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_partial_update + + Flow Viewset + + :param slug: (required) + :type slug: str + :param patched_flow_request: + :type patched_flow_request: PatchedFlowRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_partial_update_serialize( + slug=slug, + patched_flow_request=patched_flow_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_partial_update_serialize( + self, + slug, + patched_flow_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_flow_request is not None: + _body_params = patched_flow_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/flows/instances/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Flow: + """flows_instances_retrieve + + Flow Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Flow]: + """flows_instances_retrieve + + Flow Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_retrieve + + Flow Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/instances/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_update( + self, + slug: StrictStr, + flow_request: FlowRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Flow: + """flows_instances_update + + Flow Viewset + + :param slug: (required) + :type slug: str + :param flow_request: (required) + :type flow_request: FlowRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_update_serialize( + slug=slug, + flow_request=flow_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_update_with_http_info( + self, + slug: StrictStr, + flow_request: FlowRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Flow]: + """flows_instances_update + + Flow Viewset + + :param slug: (required) + :type slug: str + :param flow_request: (required) + :type flow_request: FlowRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_update_serialize( + slug=slug, + flow_request=flow_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_update_without_preload_content( + self, + slug: StrictStr, + flow_request: FlowRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_update + + Flow Viewset + + :param slug: (required) + :type slug: str + :param flow_request: (required) + :type flow_request: FlowRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_update_serialize( + slug=slug, + flow_request=flow_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Flow", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_update_serialize( + self, + slug, + flow_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if flow_request is not None: + _body_params = flow_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/flows/instances/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def flows_instances_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """flows_instances_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def flows_instances_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """flows_instances_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def flows_instances_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """flows_instances_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._flows_instances_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _flows_instances_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/flows/instances/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/lifecycle_api.py b/authentik_client/api/lifecycle_api.py new file mode 100644 index 000000000..537bb9592 --- /dev/null +++ b/authentik_client/api/lifecycle_api.py @@ -0,0 +1,3001 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.lifecycle_iteration import LifecycleIteration +from authentik_client.models.lifecycle_iteration_request import LifecycleIterationRequest +from authentik_client.models.lifecycle_rule import LifecycleRule +from authentik_client.models.lifecycle_rule_request import LifecycleRuleRequest +from authentik_client.models.paginated_lifecycle_iteration_list import PaginatedLifecycleIterationList +from authentik_client.models.paginated_lifecycle_rule_list import PaginatedLifecycleRuleList +from authentik_client.models.patched_lifecycle_rule_request import PatchedLifecycleRuleRequest +from authentik_client.models.review import Review +from authentik_client.models.review_request import ReviewRequest + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class LifecycleApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def lifecycle_iterations_create( + self, + lifecycle_iteration_request: LifecycleIterationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LifecycleIteration: + """lifecycle_iterations_create + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param lifecycle_iteration_request: (required) + :type lifecycle_iteration_request: LifecycleIterationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_iterations_create_serialize( + lifecycle_iteration_request=lifecycle_iteration_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LifecycleIteration", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_iterations_create_with_http_info( + self, + lifecycle_iteration_request: LifecycleIterationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LifecycleIteration]: + """lifecycle_iterations_create + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param lifecycle_iteration_request: (required) + :type lifecycle_iteration_request: LifecycleIterationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_iterations_create_serialize( + lifecycle_iteration_request=lifecycle_iteration_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LifecycleIteration", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_iterations_create_without_preload_content( + self, + lifecycle_iteration_request: LifecycleIterationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_iterations_create + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param lifecycle_iteration_request: (required) + :type lifecycle_iteration_request: LifecycleIterationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_iterations_create_serialize( + lifecycle_iteration_request=lifecycle_iteration_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LifecycleIteration", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_iterations_create_serialize( + self, + lifecycle_iteration_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if lifecycle_iteration_request is not None: + _body_params = lifecycle_iteration_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/lifecycle/iterations/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def lifecycle_iterations_list_latest( + self, + content_type: Annotated[str, Field(strict=True)], + object_id: Annotated[str, Field(strict=True)], + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user_is_reviewer: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[LifecycleIteration]: + """lifecycle_iterations_list_latest + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param content_type: (required) + :type content_type: str + :param object_id: (required) + :type object_id: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param user_is_reviewer: + :type user_is_reviewer: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_iterations_list_latest_serialize( + content_type=content_type, + object_id=object_id, + ordering=ordering, + search=search, + user_is_reviewer=user_is_reviewer, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[LifecycleIteration]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_iterations_list_latest_with_http_info( + self, + content_type: Annotated[str, Field(strict=True)], + object_id: Annotated[str, Field(strict=True)], + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user_is_reviewer: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[LifecycleIteration]]: + """lifecycle_iterations_list_latest + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param content_type: (required) + :type content_type: str + :param object_id: (required) + :type object_id: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param user_is_reviewer: + :type user_is_reviewer: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_iterations_list_latest_serialize( + content_type=content_type, + object_id=object_id, + ordering=ordering, + search=search, + user_is_reviewer=user_is_reviewer, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[LifecycleIteration]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_iterations_list_latest_without_preload_content( + self, + content_type: Annotated[str, Field(strict=True)], + object_id: Annotated[str, Field(strict=True)], + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user_is_reviewer: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_iterations_list_latest + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param content_type: (required) + :type content_type: str + :param object_id: (required) + :type object_id: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param search: A search term. + :type search: str + :param user_is_reviewer: + :type user_is_reviewer: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_iterations_list_latest_serialize( + content_type=content_type, + object_id=object_id, + ordering=ordering, + search=search, + user_is_reviewer=user_is_reviewer, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[LifecycleIteration]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_iterations_list_latest_serialize( + self, + content_type, + object_id, + ordering, + search, + user_is_reviewer, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if content_type is not None: + _path_params['content_type'] = content_type + if object_id is not None: + _path_params['object_id'] = object_id + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if search is not None: + + _query_params.append(('search', search)) + + if user_is_reviewer is not None: + + _query_params.append(('user_is_reviewer', user_is_reviewer)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/lifecycle/iterations/latest/{content_type}/{object_id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def lifecycle_iterations_list_open( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user_is_reviewer: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedLifecycleIterationList: + """lifecycle_iterations_list_open + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user_is_reviewer: + :type user_is_reviewer: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_iterations_list_open_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user_is_reviewer=user_is_reviewer, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLifecycleIterationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_iterations_list_open_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user_is_reviewer: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedLifecycleIterationList]: + """lifecycle_iterations_list_open + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user_is_reviewer: + :type user_is_reviewer: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_iterations_list_open_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user_is_reviewer=user_is_reviewer, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLifecycleIterationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_iterations_list_open_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user_is_reviewer: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_iterations_list_open + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param user_is_reviewer: + :type user_is_reviewer: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_iterations_list_open_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + user_is_reviewer=user_is_reviewer, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLifecycleIterationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_iterations_list_open_serialize( + self, + ordering, + page, + page_size, + search, + user_is_reviewer, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if user_is_reviewer is not None: + + _query_params.append(('user_is_reviewer', user_is_reviewer)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/lifecycle/iterations/open/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def lifecycle_reviews_create( + self, + review_request: ReviewRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Review: + """lifecycle_reviews_create + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param review_request: (required) + :type review_request: ReviewRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_reviews_create_serialize( + review_request=review_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Review", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_reviews_create_with_http_info( + self, + review_request: ReviewRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Review]: + """lifecycle_reviews_create + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param review_request: (required) + :type review_request: ReviewRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_reviews_create_serialize( + review_request=review_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Review", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_reviews_create_without_preload_content( + self, + review_request: ReviewRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_reviews_create + + Mixin to validate that a valid enterprise license exists before allowing to save the object + + :param review_request: (required) + :type review_request: ReviewRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_reviews_create_serialize( + review_request=review_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Review", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_reviews_create_serialize( + self, + review_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if review_request is not None: + _body_params = review_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/lifecycle/reviews/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def lifecycle_rules_create( + self, + lifecycle_rule_request: LifecycleRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LifecycleRule: + """lifecycle_rules_create + + + :param lifecycle_rule_request: (required) + :type lifecycle_rule_request: LifecycleRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_create_serialize( + lifecycle_rule_request=lifecycle_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_rules_create_with_http_info( + self, + lifecycle_rule_request: LifecycleRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LifecycleRule]: + """lifecycle_rules_create + + + :param lifecycle_rule_request: (required) + :type lifecycle_rule_request: LifecycleRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_create_serialize( + lifecycle_rule_request=lifecycle_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_rules_create_without_preload_content( + self, + lifecycle_rule_request: LifecycleRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_rules_create + + + :param lifecycle_rule_request: (required) + :type lifecycle_rule_request: LifecycleRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_create_serialize( + lifecycle_rule_request=lifecycle_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_rules_create_serialize( + self, + lifecycle_rule_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if lifecycle_rule_request is not None: + _body_params = lifecycle_rule_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/lifecycle/rules/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def lifecycle_rules_destroy( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """lifecycle_rules_destroy + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_rules_destroy_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """lifecycle_rules_destroy + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_rules_destroy_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_rules_destroy + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_rules_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/lifecycle/rules/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def lifecycle_rules_list( + self, + content_type__model: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedLifecycleRuleList: + """lifecycle_rules_list + + + :param content_type__model: + :type content_type__model: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_list_serialize( + content_type__model=content_type__model, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLifecycleRuleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_rules_list_with_http_info( + self, + content_type__model: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedLifecycleRuleList]: + """lifecycle_rules_list + + + :param content_type__model: + :type content_type__model: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_list_serialize( + content_type__model=content_type__model, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLifecycleRuleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_rules_list_without_preload_content( + self, + content_type__model: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_rules_list + + + :param content_type__model: + :type content_type__model: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_list_serialize( + content_type__model=content_type__model, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLifecycleRuleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_rules_list_serialize( + self, + content_type__model, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if content_type__model is not None: + + _query_params.append(('content_type__model', content_type__model)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/lifecycle/rules/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def lifecycle_rules_partial_update( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + patched_lifecycle_rule_request: Optional[PatchedLifecycleRuleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LifecycleRule: + """lifecycle_rules_partial_update + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param patched_lifecycle_rule_request: + :type patched_lifecycle_rule_request: PatchedLifecycleRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_partial_update_serialize( + id=id, + patched_lifecycle_rule_request=patched_lifecycle_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_rules_partial_update_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + patched_lifecycle_rule_request: Optional[PatchedLifecycleRuleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LifecycleRule]: + """lifecycle_rules_partial_update + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param patched_lifecycle_rule_request: + :type patched_lifecycle_rule_request: PatchedLifecycleRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_partial_update_serialize( + id=id, + patched_lifecycle_rule_request=patched_lifecycle_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_rules_partial_update_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + patched_lifecycle_rule_request: Optional[PatchedLifecycleRuleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_rules_partial_update + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param patched_lifecycle_rule_request: + :type patched_lifecycle_rule_request: PatchedLifecycleRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_partial_update_serialize( + id=id, + patched_lifecycle_rule_request=patched_lifecycle_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_rules_partial_update_serialize( + self, + id, + patched_lifecycle_rule_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_lifecycle_rule_request is not None: + _body_params = patched_lifecycle_rule_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/lifecycle/rules/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def lifecycle_rules_retrieve( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LifecycleRule: + """lifecycle_rules_retrieve + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_rules_retrieve_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LifecycleRule]: + """lifecycle_rules_retrieve + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_rules_retrieve_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_rules_retrieve + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_rules_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/lifecycle/rules/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def lifecycle_rules_update( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + lifecycle_rule_request: LifecycleRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LifecycleRule: + """lifecycle_rules_update + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param lifecycle_rule_request: (required) + :type lifecycle_rule_request: LifecycleRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_update_serialize( + id=id, + lifecycle_rule_request=lifecycle_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def lifecycle_rules_update_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + lifecycle_rule_request: LifecycleRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LifecycleRule]: + """lifecycle_rules_update + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param lifecycle_rule_request: (required) + :type lifecycle_rule_request: LifecycleRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_update_serialize( + id=id, + lifecycle_rule_request=lifecycle_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def lifecycle_rules_update_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this lifecycle rule.")], + lifecycle_rule_request: LifecycleRuleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """lifecycle_rules_update + + + :param id: A UUID string identifying this lifecycle rule. (required) + :type id: UUID + :param lifecycle_rule_request: (required) + :type lifecycle_rule_request: LifecycleRuleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._lifecycle_rules_update_serialize( + id=id, + lifecycle_rule_request=lifecycle_rule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LifecycleRule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _lifecycle_rules_update_serialize( + self, + id, + lifecycle_rule_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if lifecycle_rule_request is not None: + _body_params = lifecycle_rule_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/lifecycle/rules/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/managed_api.py b/authentik_client/api/managed_api.py new file mode 100644 index 000000000..dbf5e2d0d --- /dev/null +++ b/authentik_client/api/managed_api.py @@ -0,0 +1,2900 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBytes, StrictInt, StrictStr +from typing import List, Optional, Tuple, Union +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.blueprint_file import BlueprintFile +from authentik_client.models.blueprint_import_result import BlueprintImportResult +from authentik_client.models.blueprint_instance import BlueprintInstance +from authentik_client.models.blueprint_instance_request import BlueprintInstanceRequest +from authentik_client.models.paginated_blueprint_instance_list import PaginatedBlueprintInstanceList +from authentik_client.models.patched_blueprint_instance_request import PatchedBlueprintInstanceRequest +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class ManagedApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def managed_blueprints_apply_create( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> BlueprintInstance: + """managed_blueprints_apply_create + + Apply a blueprint + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_apply_create_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_apply_create_with_http_info( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[BlueprintInstance]: + """managed_blueprints_apply_create + + Apply a blueprint + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_apply_create_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_apply_create_without_preload_content( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_apply_create + + Apply a blueprint + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_apply_create_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_apply_create_serialize( + self, + instance_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if instance_uuid is not None: + _path_params['instance_uuid'] = instance_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/managed/blueprints/{instance_uuid}/apply/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def managed_blueprints_available_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[BlueprintFile]: + """managed_blueprints_available_list + + Get blueprints + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_available_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[BlueprintFile]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_available_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[BlueprintFile]]: + """managed_blueprints_available_list + + Get blueprints + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_available_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[BlueprintFile]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_available_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_available_list + + Get blueprints + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_available_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[BlueprintFile]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_available_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/managed/blueprints/available/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def managed_blueprints_create( + self, + blueprint_instance_request: BlueprintInstanceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> BlueprintInstance: + """managed_blueprints_create + + Blueprint instances + + :param blueprint_instance_request: (required) + :type blueprint_instance_request: BlueprintInstanceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_create_serialize( + blueprint_instance_request=blueprint_instance_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_create_with_http_info( + self, + blueprint_instance_request: BlueprintInstanceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[BlueprintInstance]: + """managed_blueprints_create + + Blueprint instances + + :param blueprint_instance_request: (required) + :type blueprint_instance_request: BlueprintInstanceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_create_serialize( + blueprint_instance_request=blueprint_instance_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_create_without_preload_content( + self, + blueprint_instance_request: BlueprintInstanceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_create + + Blueprint instances + + :param blueprint_instance_request: (required) + :type blueprint_instance_request: BlueprintInstanceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_create_serialize( + blueprint_instance_request=blueprint_instance_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_create_serialize( + self, + blueprint_instance_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if blueprint_instance_request is not None: + _body_params = blueprint_instance_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/managed/blueprints/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def managed_blueprints_destroy( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """managed_blueprints_destroy + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_destroy_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_destroy_with_http_info( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """managed_blueprints_destroy + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_destroy_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_destroy_without_preload_content( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_destroy + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_destroy_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_destroy_serialize( + self, + instance_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if instance_uuid is not None: + _path_params['instance_uuid'] = instance_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/managed/blueprints/{instance_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def managed_blueprints_import_create( + self, + file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None, + path: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None, + context: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> BlueprintImportResult: + """managed_blueprints_import_create + + Import blueprint from .yaml file and apply it once, without creating an instance + + :param file: + :type file: bytes + :param path: + :type path: str + :param context: + :type context: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_import_create_serialize( + file=file, + path=path, + context=context, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintImportResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_import_create_with_http_info( + self, + file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None, + path: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None, + context: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[BlueprintImportResult]: + """managed_blueprints_import_create + + Import blueprint from .yaml file and apply it once, without creating an instance + + :param file: + :type file: bytes + :param path: + :type path: str + :param context: + :type context: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_import_create_serialize( + file=file, + path=path, + context=context, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintImportResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_import_create_without_preload_content( + self, + file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None, + path: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None, + context: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_import_create + + Import blueprint from .yaml file and apply it once, without creating an instance + + :param file: + :type file: bytes + :param path: + :type path: str + :param context: + :type context: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_import_create_serialize( + file=file, + path=path, + context=context, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintImportResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_import_create_serialize( + self, + file, + path, + context, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + if file is not None: + _files['file'] = file + if path is not None: + _form_params.append(('path', path)) + if context is not None: + _form_params.append(('context', context)) + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'multipart/form-data' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/managed/blueprints/import/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def managed_blueprints_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + path: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedBlueprintInstanceList: + """managed_blueprints_list + + Blueprint instances + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param path: + :type path: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + path=path, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedBlueprintInstanceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + path: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedBlueprintInstanceList]: + """managed_blueprints_list + + Blueprint instances + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param path: + :type path: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + path=path, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedBlueprintInstanceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + path: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_list + + Blueprint instances + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param path: + :type path: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + path=path, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedBlueprintInstanceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_list_serialize( + self, + name, + ordering, + page, + page_size, + path, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if path is not None: + + _query_params.append(('path', path)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/managed/blueprints/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def managed_blueprints_partial_update( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + patched_blueprint_instance_request: Optional[PatchedBlueprintInstanceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> BlueprintInstance: + """managed_blueprints_partial_update + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param patched_blueprint_instance_request: + :type patched_blueprint_instance_request: PatchedBlueprintInstanceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_partial_update_serialize( + instance_uuid=instance_uuid, + patched_blueprint_instance_request=patched_blueprint_instance_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_partial_update_with_http_info( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + patched_blueprint_instance_request: Optional[PatchedBlueprintInstanceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[BlueprintInstance]: + """managed_blueprints_partial_update + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param patched_blueprint_instance_request: + :type patched_blueprint_instance_request: PatchedBlueprintInstanceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_partial_update_serialize( + instance_uuid=instance_uuid, + patched_blueprint_instance_request=patched_blueprint_instance_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_partial_update_without_preload_content( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + patched_blueprint_instance_request: Optional[PatchedBlueprintInstanceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_partial_update + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param patched_blueprint_instance_request: + :type patched_blueprint_instance_request: PatchedBlueprintInstanceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_partial_update_serialize( + instance_uuid=instance_uuid, + patched_blueprint_instance_request=patched_blueprint_instance_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_partial_update_serialize( + self, + instance_uuid, + patched_blueprint_instance_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if instance_uuid is not None: + _path_params['instance_uuid'] = instance_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_blueprint_instance_request is not None: + _body_params = patched_blueprint_instance_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/managed/blueprints/{instance_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def managed_blueprints_retrieve( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> BlueprintInstance: + """managed_blueprints_retrieve + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_retrieve_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_retrieve_with_http_info( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[BlueprintInstance]: + """managed_blueprints_retrieve + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_retrieve_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_retrieve_without_preload_content( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_retrieve + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_retrieve_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_retrieve_serialize( + self, + instance_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if instance_uuid is not None: + _path_params['instance_uuid'] = instance_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/managed/blueprints/{instance_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def managed_blueprints_update( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + blueprint_instance_request: BlueprintInstanceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> BlueprintInstance: + """managed_blueprints_update + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param blueprint_instance_request: (required) + :type blueprint_instance_request: BlueprintInstanceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_update_serialize( + instance_uuid=instance_uuid, + blueprint_instance_request=blueprint_instance_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_update_with_http_info( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + blueprint_instance_request: BlueprintInstanceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[BlueprintInstance]: + """managed_blueprints_update + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param blueprint_instance_request: (required) + :type blueprint_instance_request: BlueprintInstanceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_update_serialize( + instance_uuid=instance_uuid, + blueprint_instance_request=blueprint_instance_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_update_without_preload_content( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + blueprint_instance_request: BlueprintInstanceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_update + + Blueprint instances + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param blueprint_instance_request: (required) + :type blueprint_instance_request: BlueprintInstanceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_update_serialize( + instance_uuid=instance_uuid, + blueprint_instance_request=blueprint_instance_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "BlueprintInstance", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_update_serialize( + self, + instance_uuid, + blueprint_instance_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if instance_uuid is not None: + _path_params['instance_uuid'] = instance_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if blueprint_instance_request is not None: + _body_params = blueprint_instance_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/managed/blueprints/{instance_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def managed_blueprints_used_by_list( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """managed_blueprints_used_by_list + + Get a list of all objects that use this object + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_used_by_list_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def managed_blueprints_used_by_list_with_http_info( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """managed_blueprints_used_by_list + + Get a list of all objects that use this object + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_used_by_list_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def managed_blueprints_used_by_list_without_preload_content( + self, + instance_uuid: Annotated[UUID, Field(description="A UUID string identifying this Blueprint Instance.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """managed_blueprints_used_by_list + + Get a list of all objects that use this object + + :param instance_uuid: A UUID string identifying this Blueprint Instance. (required) + :type instance_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._managed_blueprints_used_by_list_serialize( + instance_uuid=instance_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _managed_blueprints_used_by_list_serialize( + self, + instance_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if instance_uuid is not None: + _path_params['instance_uuid'] = instance_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/managed/blueprints/{instance_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/oauth2_api.py b/authentik_client/api/oauth2_api.py new file mode 100644 index 000000000..db7743792 --- /dev/null +++ b/authentik_client/api/oauth2_api.py @@ -0,0 +1,3508 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from authentik_client.models.expiring_base_grant_model import ExpiringBaseGrantModel +from authentik_client.models.paginated_expiring_base_grant_model_list import PaginatedExpiringBaseGrantModelList +from authentik_client.models.paginated_token_model_list import PaginatedTokenModelList +from authentik_client.models.token_model import TokenModel +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class Oauth2Api: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def oauth2_access_tokens_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Access Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """oauth2_access_tokens_destroy + + AccessToken Viewset + + :param id: A unique integer value identifying this OAuth2 Access Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_access_tokens_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Access Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """oauth2_access_tokens_destroy + + AccessToken Viewset + + :param id: A unique integer value identifying this OAuth2 Access Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_access_tokens_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Access Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_access_tokens_destroy + + AccessToken Viewset + + :param id: A unique integer value identifying this OAuth2 Access Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_access_tokens_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/oauth2/access_tokens/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_access_tokens_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedTokenModelList: + """oauth2_access_tokens_list + + AccessToken Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTokenModelList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_access_tokens_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedTokenModelList]: + """oauth2_access_tokens_list + + AccessToken Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTokenModelList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_access_tokens_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_access_tokens_list + + AccessToken Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTokenModelList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_access_tokens_list_serialize( + self, + ordering, + page, + page_size, + provider, + search, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider is not None: + + _query_params.append(('provider', provider)) + + if search is not None: + + _query_params.append(('search', search)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/oauth2/access_tokens/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_access_tokens_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Access Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TokenModel: + """oauth2_access_tokens_retrieve + + AccessToken Viewset + + :param id: A unique integer value identifying this OAuth2 Access Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenModel", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_access_tokens_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Access Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TokenModel]: + """oauth2_access_tokens_retrieve + + AccessToken Viewset + + :param id: A unique integer value identifying this OAuth2 Access Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenModel", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_access_tokens_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Access Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_access_tokens_retrieve + + AccessToken Viewset + + :param id: A unique integer value identifying this OAuth2 Access Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenModel", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_access_tokens_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/oauth2/access_tokens/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_access_tokens_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Access Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """oauth2_access_tokens_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this OAuth2 Access Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_access_tokens_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Access Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """oauth2_access_tokens_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this OAuth2 Access Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_access_tokens_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Access Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_access_tokens_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this OAuth2 Access Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_access_tokens_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_access_tokens_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/oauth2/access_tokens/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_authorization_codes_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Authorization Code.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """oauth2_authorization_codes_destroy + + AuthorizationCode Viewset + + :param id: A unique integer value identifying this Authorization Code. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_authorization_codes_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Authorization Code.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """oauth2_authorization_codes_destroy + + AuthorizationCode Viewset + + :param id: A unique integer value identifying this Authorization Code. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_authorization_codes_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Authorization Code.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_authorization_codes_destroy + + AuthorizationCode Viewset + + :param id: A unique integer value identifying this Authorization Code. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_authorization_codes_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/oauth2/authorization_codes/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_authorization_codes_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedExpiringBaseGrantModelList: + """oauth2_authorization_codes_list + + AuthorizationCode Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedExpiringBaseGrantModelList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_authorization_codes_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedExpiringBaseGrantModelList]: + """oauth2_authorization_codes_list + + AuthorizationCode Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedExpiringBaseGrantModelList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_authorization_codes_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_authorization_codes_list + + AuthorizationCode Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedExpiringBaseGrantModelList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_authorization_codes_list_serialize( + self, + ordering, + page, + page_size, + provider, + search, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider is not None: + + _query_params.append(('provider', provider)) + + if search is not None: + + _query_params.append(('search', search)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/oauth2/authorization_codes/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_authorization_codes_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Authorization Code.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ExpiringBaseGrantModel: + """oauth2_authorization_codes_retrieve + + AuthorizationCode Viewset + + :param id: A unique integer value identifying this Authorization Code. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpiringBaseGrantModel", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_authorization_codes_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Authorization Code.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ExpiringBaseGrantModel]: + """oauth2_authorization_codes_retrieve + + AuthorizationCode Viewset + + :param id: A unique integer value identifying this Authorization Code. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpiringBaseGrantModel", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_authorization_codes_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Authorization Code.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_authorization_codes_retrieve + + AuthorizationCode Viewset + + :param id: A unique integer value identifying this Authorization Code. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpiringBaseGrantModel", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_authorization_codes_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/oauth2/authorization_codes/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_authorization_codes_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Authorization Code.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """oauth2_authorization_codes_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Authorization Code. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_authorization_codes_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Authorization Code.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """oauth2_authorization_codes_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Authorization Code. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_authorization_codes_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Authorization Code.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_authorization_codes_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Authorization Code. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_authorization_codes_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_authorization_codes_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/oauth2/authorization_codes/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_refresh_tokens_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Refresh Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """oauth2_refresh_tokens_destroy + + RefreshToken Viewset + + :param id: A unique integer value identifying this OAuth2 Refresh Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_refresh_tokens_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Refresh Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """oauth2_refresh_tokens_destroy + + RefreshToken Viewset + + :param id: A unique integer value identifying this OAuth2 Refresh Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_refresh_tokens_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Refresh Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_refresh_tokens_destroy + + RefreshToken Viewset + + :param id: A unique integer value identifying this OAuth2 Refresh Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_refresh_tokens_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/oauth2/refresh_tokens/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_refresh_tokens_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedTokenModelList: + """oauth2_refresh_tokens_list + + RefreshToken Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTokenModelList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_refresh_tokens_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedTokenModelList]: + """oauth2_refresh_tokens_list + + RefreshToken Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTokenModelList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_refresh_tokens_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_refresh_tokens_list + + RefreshToken Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTokenModelList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_refresh_tokens_list_serialize( + self, + ordering, + page, + page_size, + provider, + search, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider is not None: + + _query_params.append(('provider', provider)) + + if search is not None: + + _query_params.append(('search', search)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/oauth2/refresh_tokens/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_refresh_tokens_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Refresh Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TokenModel: + """oauth2_refresh_tokens_retrieve + + RefreshToken Viewset + + :param id: A unique integer value identifying this OAuth2 Refresh Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenModel", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_refresh_tokens_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Refresh Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TokenModel]: + """oauth2_refresh_tokens_retrieve + + RefreshToken Viewset + + :param id: A unique integer value identifying this OAuth2 Refresh Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenModel", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_refresh_tokens_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Refresh Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_refresh_tokens_retrieve + + RefreshToken Viewset + + :param id: A unique integer value identifying this OAuth2 Refresh Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TokenModel", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_refresh_tokens_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/oauth2/refresh_tokens/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def oauth2_refresh_tokens_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Refresh Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """oauth2_refresh_tokens_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this OAuth2 Refresh Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def oauth2_refresh_tokens_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Refresh Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """oauth2_refresh_tokens_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this OAuth2 Refresh Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def oauth2_refresh_tokens_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2 Refresh Token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """oauth2_refresh_tokens_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this OAuth2 Refresh Token. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._oauth2_refresh_tokens_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _oauth2_refresh_tokens_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/oauth2/refresh_tokens/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/outposts_api.py b/authentik_client/api/outposts_api.py new file mode 100644 index 000000000..71325da47 --- /dev/null +++ b/authentik_client/api/outposts_api.py @@ -0,0 +1,10218 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.docker_service_connection import DockerServiceConnection +from authentik_client.models.docker_service_connection_request import DockerServiceConnectionRequest +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection +from authentik_client.models.kubernetes_service_connection_request import KubernetesServiceConnectionRequest +from authentik_client.models.ldap_check_access import LDAPCheckAccess +from authentik_client.models.outpost import Outpost +from authentik_client.models.outpost_default_config import OutpostDefaultConfig +from authentik_client.models.outpost_health import OutpostHealth +from authentik_client.models.outpost_request import OutpostRequest +from authentik_client.models.paginated_docker_service_connection_list import PaginatedDockerServiceConnectionList +from authentik_client.models.paginated_kubernetes_service_connection_list import PaginatedKubernetesServiceConnectionList +from authentik_client.models.paginated_ldap_outpost_config_list import PaginatedLDAPOutpostConfigList +from authentik_client.models.paginated_outpost_list import PaginatedOutpostList +from authentik_client.models.paginated_proxy_outpost_config_list import PaginatedProxyOutpostConfigList +from authentik_client.models.paginated_radius_outpost_config_list import PaginatedRadiusOutpostConfigList +from authentik_client.models.paginated_service_connection_list import PaginatedServiceConnectionList +from authentik_client.models.patched_docker_service_connection_request import PatchedDockerServiceConnectionRequest +from authentik_client.models.patched_kubernetes_service_connection_request import PatchedKubernetesServiceConnectionRequest +from authentik_client.models.patched_outpost_request import PatchedOutpostRequest +from authentik_client.models.radius_check_access import RadiusCheckAccess +from authentik_client.models.service_connection import ServiceConnection +from authentik_client.models.service_connection_state import ServiceConnectionState +from authentik_client.models.type_create import TypeCreate +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class OutpostsApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def outposts_instances_create( + self, + outpost_request: OutpostRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Outpost: + """outposts_instances_create + + Outpost Viewset + + :param outpost_request: (required) + :type outpost_request: OutpostRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_create_serialize( + outpost_request=outpost_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_instances_create_with_http_info( + self, + outpost_request: OutpostRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Outpost]: + """outposts_instances_create + + Outpost Viewset + + :param outpost_request: (required) + :type outpost_request: OutpostRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_create_serialize( + outpost_request=outpost_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_instances_create_without_preload_content( + self, + outpost_request: OutpostRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_instances_create + + Outpost Viewset + + :param outpost_request: (required) + :type outpost_request: OutpostRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_create_serialize( + outpost_request=outpost_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_instances_create_serialize( + self, + outpost_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if outpost_request is not None: + _body_params = outpost_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/outposts/instances/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_instances_default_settings_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OutpostDefaultConfig: + """outposts_instances_default_settings_retrieve + + Global default outpost config + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_default_settings_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OutpostDefaultConfig", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_instances_default_settings_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OutpostDefaultConfig]: + """outposts_instances_default_settings_retrieve + + Global default outpost config + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_default_settings_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OutpostDefaultConfig", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_instances_default_settings_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_instances_default_settings_retrieve + + Global default outpost config + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_default_settings_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OutpostDefaultConfig", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_instances_default_settings_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/instances/default_settings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_instances_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """outposts_instances_destroy + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_instances_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """outposts_instances_destroy + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_instances_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_instances_destroy + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_instances_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/outposts/instances/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_instances_health_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + managed__icontains: Optional[StrictStr] = None, + managed__iexact: Optional[StrictStr] = None, + name__icontains: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + providers__isnull: Optional[StrictBool] = None, + providers_by_pk: Optional[List[StrictInt]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + service_connection__name__icontains: Optional[StrictStr] = None, + service_connection__name__iexact: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[OutpostHealth]: + """outposts_instances_health_list + + Get outposts current health + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param managed__icontains: + :type managed__icontains: str + :param managed__iexact: + :type managed__iexact: str + :param name__icontains: + :type name__icontains: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param providers__isnull: + :type providers__isnull: bool + :param providers_by_pk: + :type providers_by_pk: List[int] + :param search: A search term. + :type search: str + :param service_connection__name__icontains: + :type service_connection__name__icontains: str + :param service_connection__name__iexact: + :type service_connection__name__iexact: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_health_list_serialize( + uuid=uuid, + managed__icontains=managed__icontains, + managed__iexact=managed__iexact, + name__icontains=name__icontains, + name__iexact=name__iexact, + ordering=ordering, + providers__isnull=providers__isnull, + providers_by_pk=providers_by_pk, + search=search, + service_connection__name__icontains=service_connection__name__icontains, + service_connection__name__iexact=service_connection__name__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[OutpostHealth]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_instances_health_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + managed__icontains: Optional[StrictStr] = None, + managed__iexact: Optional[StrictStr] = None, + name__icontains: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + providers__isnull: Optional[StrictBool] = None, + providers_by_pk: Optional[List[StrictInt]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + service_connection__name__icontains: Optional[StrictStr] = None, + service_connection__name__iexact: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[OutpostHealth]]: + """outposts_instances_health_list + + Get outposts current health + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param managed__icontains: + :type managed__icontains: str + :param managed__iexact: + :type managed__iexact: str + :param name__icontains: + :type name__icontains: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param providers__isnull: + :type providers__isnull: bool + :param providers_by_pk: + :type providers_by_pk: List[int] + :param search: A search term. + :type search: str + :param service_connection__name__icontains: + :type service_connection__name__icontains: str + :param service_connection__name__iexact: + :type service_connection__name__iexact: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_health_list_serialize( + uuid=uuid, + managed__icontains=managed__icontains, + managed__iexact=managed__iexact, + name__icontains=name__icontains, + name__iexact=name__iexact, + ordering=ordering, + providers__isnull=providers__isnull, + providers_by_pk=providers_by_pk, + search=search, + service_connection__name__icontains=service_connection__name__icontains, + service_connection__name__iexact=service_connection__name__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[OutpostHealth]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_instances_health_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + managed__icontains: Optional[StrictStr] = None, + managed__iexact: Optional[StrictStr] = None, + name__icontains: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + providers__isnull: Optional[StrictBool] = None, + providers_by_pk: Optional[List[StrictInt]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + service_connection__name__icontains: Optional[StrictStr] = None, + service_connection__name__iexact: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_instances_health_list + + Get outposts current health + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param managed__icontains: + :type managed__icontains: str + :param managed__iexact: + :type managed__iexact: str + :param name__icontains: + :type name__icontains: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param providers__isnull: + :type providers__isnull: bool + :param providers_by_pk: + :type providers_by_pk: List[int] + :param search: A search term. + :type search: str + :param service_connection__name__icontains: + :type service_connection__name__icontains: str + :param service_connection__name__iexact: + :type service_connection__name__iexact: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_health_list_serialize( + uuid=uuid, + managed__icontains=managed__icontains, + managed__iexact=managed__iexact, + name__icontains=name__icontains, + name__iexact=name__iexact, + ordering=ordering, + providers__isnull=providers__isnull, + providers_by_pk=providers_by_pk, + search=search, + service_connection__name__icontains=service_connection__name__icontains, + service_connection__name__iexact=service_connection__name__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[OutpostHealth]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_instances_health_list_serialize( + self, + uuid, + managed__icontains, + managed__iexact, + name__icontains, + name__iexact, + ordering, + providers__isnull, + providers_by_pk, + search, + service_connection__name__icontains, + service_connection__name__iexact, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'providers_by_pk': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + if managed__icontains is not None: + + _query_params.append(('managed__icontains', managed__icontains)) + + if managed__iexact is not None: + + _query_params.append(('managed__iexact', managed__iexact)) + + if name__icontains is not None: + + _query_params.append(('name__icontains', name__icontains)) + + if name__iexact is not None: + + _query_params.append(('name__iexact', name__iexact)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if providers__isnull is not None: + + _query_params.append(('providers__isnull', providers__isnull)) + + if providers_by_pk is not None: + + _query_params.append(('providers_by_pk', providers_by_pk)) + + if search is not None: + + _query_params.append(('search', search)) + + if service_connection__name__icontains is not None: + + _query_params.append(('service_connection__name__icontains', service_connection__name__icontains)) + + if service_connection__name__iexact is not None: + + _query_params.append(('service_connection__name__iexact', service_connection__name__iexact)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/instances/{uuid}/health/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_instances_list( + self, + managed__icontains: Optional[StrictStr] = None, + managed__iexact: Optional[StrictStr] = None, + name__icontains: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + providers__isnull: Optional[StrictBool] = None, + providers_by_pk: Optional[List[StrictInt]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + service_connection__name__icontains: Optional[StrictStr] = None, + service_connection__name__iexact: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedOutpostList: + """outposts_instances_list + + Outpost Viewset + + :param managed__icontains: + :type managed__icontains: str + :param managed__iexact: + :type managed__iexact: str + :param name__icontains: + :type name__icontains: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param providers__isnull: + :type providers__isnull: bool + :param providers_by_pk: + :type providers_by_pk: List[int] + :param search: A search term. + :type search: str + :param service_connection__name__icontains: + :type service_connection__name__icontains: str + :param service_connection__name__iexact: + :type service_connection__name__iexact: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_list_serialize( + managed__icontains=managed__icontains, + managed__iexact=managed__iexact, + name__icontains=name__icontains, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + providers__isnull=providers__isnull, + providers_by_pk=providers_by_pk, + search=search, + service_connection__name__icontains=service_connection__name__icontains, + service_connection__name__iexact=service_connection__name__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOutpostList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_instances_list_with_http_info( + self, + managed__icontains: Optional[StrictStr] = None, + managed__iexact: Optional[StrictStr] = None, + name__icontains: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + providers__isnull: Optional[StrictBool] = None, + providers_by_pk: Optional[List[StrictInt]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + service_connection__name__icontains: Optional[StrictStr] = None, + service_connection__name__iexact: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedOutpostList]: + """outposts_instances_list + + Outpost Viewset + + :param managed__icontains: + :type managed__icontains: str + :param managed__iexact: + :type managed__iexact: str + :param name__icontains: + :type name__icontains: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param providers__isnull: + :type providers__isnull: bool + :param providers_by_pk: + :type providers_by_pk: List[int] + :param search: A search term. + :type search: str + :param service_connection__name__icontains: + :type service_connection__name__icontains: str + :param service_connection__name__iexact: + :type service_connection__name__iexact: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_list_serialize( + managed__icontains=managed__icontains, + managed__iexact=managed__iexact, + name__icontains=name__icontains, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + providers__isnull=providers__isnull, + providers_by_pk=providers_by_pk, + search=search, + service_connection__name__icontains=service_connection__name__icontains, + service_connection__name__iexact=service_connection__name__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOutpostList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_instances_list_without_preload_content( + self, + managed__icontains: Optional[StrictStr] = None, + managed__iexact: Optional[StrictStr] = None, + name__icontains: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + providers__isnull: Optional[StrictBool] = None, + providers_by_pk: Optional[List[StrictInt]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + service_connection__name__icontains: Optional[StrictStr] = None, + service_connection__name__iexact: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_instances_list + + Outpost Viewset + + :param managed__icontains: + :type managed__icontains: str + :param managed__iexact: + :type managed__iexact: str + :param name__icontains: + :type name__icontains: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param providers__isnull: + :type providers__isnull: bool + :param providers_by_pk: + :type providers_by_pk: List[int] + :param search: A search term. + :type search: str + :param service_connection__name__icontains: + :type service_connection__name__icontains: str + :param service_connection__name__iexact: + :type service_connection__name__iexact: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_list_serialize( + managed__icontains=managed__icontains, + managed__iexact=managed__iexact, + name__icontains=name__icontains, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + providers__isnull=providers__isnull, + providers_by_pk=providers_by_pk, + search=search, + service_connection__name__icontains=service_connection__name__icontains, + service_connection__name__iexact=service_connection__name__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOutpostList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_instances_list_serialize( + self, + managed__icontains, + managed__iexact, + name__icontains, + name__iexact, + ordering, + page, + page_size, + providers__isnull, + providers_by_pk, + search, + service_connection__name__icontains, + service_connection__name__iexact, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'providers_by_pk': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed__icontains is not None: + + _query_params.append(('managed__icontains', managed__icontains)) + + if managed__iexact is not None: + + _query_params.append(('managed__iexact', managed__iexact)) + + if name__icontains is not None: + + _query_params.append(('name__icontains', name__icontains)) + + if name__iexact is not None: + + _query_params.append(('name__iexact', name__iexact)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if providers__isnull is not None: + + _query_params.append(('providers__isnull', providers__isnull)) + + if providers_by_pk is not None: + + _query_params.append(('providers_by_pk', providers_by_pk)) + + if search is not None: + + _query_params.append(('search', search)) + + if service_connection__name__icontains is not None: + + _query_params.append(('service_connection__name__icontains', service_connection__name__icontains)) + + if service_connection__name__iexact is not None: + + _query_params.append(('service_connection__name__iexact', service_connection__name__iexact)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/instances/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_instances_partial_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + patched_outpost_request: Optional[PatchedOutpostRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Outpost: + """outposts_instances_partial_update + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param patched_outpost_request: + :type patched_outpost_request: PatchedOutpostRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_partial_update_serialize( + uuid=uuid, + patched_outpost_request=patched_outpost_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_instances_partial_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + patched_outpost_request: Optional[PatchedOutpostRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Outpost]: + """outposts_instances_partial_update + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param patched_outpost_request: + :type patched_outpost_request: PatchedOutpostRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_partial_update_serialize( + uuid=uuid, + patched_outpost_request=patched_outpost_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_instances_partial_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + patched_outpost_request: Optional[PatchedOutpostRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_instances_partial_update + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param patched_outpost_request: + :type patched_outpost_request: PatchedOutpostRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_partial_update_serialize( + uuid=uuid, + patched_outpost_request=patched_outpost_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_instances_partial_update_serialize( + self, + uuid, + patched_outpost_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_outpost_request is not None: + _body_params = patched_outpost_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/outposts/instances/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_instances_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Outpost: + """outposts_instances_retrieve + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_instances_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Outpost]: + """outposts_instances_retrieve + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_instances_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_instances_retrieve + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_instances_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/instances/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_instances_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + outpost_request: OutpostRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Outpost: + """outposts_instances_update + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param outpost_request: (required) + :type outpost_request: OutpostRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_update_serialize( + uuid=uuid, + outpost_request=outpost_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_instances_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + outpost_request: OutpostRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Outpost]: + """outposts_instances_update + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param outpost_request: (required) + :type outpost_request: OutpostRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_update_serialize( + uuid=uuid, + outpost_request=outpost_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_instances_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + outpost_request: OutpostRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_instances_update + + Outpost Viewset + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param outpost_request: (required) + :type outpost_request: OutpostRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_update_serialize( + uuid=uuid, + outpost_request=outpost_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Outpost", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_instances_update_serialize( + self, + uuid, + outpost_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if outpost_request is not None: + _body_params = outpost_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/outposts/instances/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_instances_used_by_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """outposts_instances_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_instances_used_by_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """outposts_instances_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_instances_used_by_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_instances_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Outpost. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_instances_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_instances_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/instances/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_ldap_access_check( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + app_slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPCheckAccess: + """outposts_ldap_access_check + + Check access to a single application by slug + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param app_slug: + :type app_slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_ldap_access_check_serialize( + id=id, + app_slug=app_slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPCheckAccess", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_ldap_access_check_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + app_slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPCheckAccess]: + """outposts_ldap_access_check + + Check access to a single application by slug + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param app_slug: + :type app_slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_ldap_access_check_serialize( + id=id, + app_slug=app_slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPCheckAccess", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_ldap_access_check_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + app_slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_ldap_access_check + + Check access to a single application by slug + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param app_slug: + :type app_slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_ldap_access_check_serialize( + id=id, + app_slug=app_slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPCheckAccess", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_ldap_access_check_serialize( + self, + id, + app_slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + if app_slug is not None: + + _query_params.append(('app_slug', app_slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/ldap/{id}/check_access/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_ldap_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedLDAPOutpostConfigList: + """outposts_ldap_list + + LDAPProvider Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_ldap_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPOutpostConfigList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_ldap_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedLDAPOutpostConfigList]: + """outposts_ldap_list + + LDAPProvider Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_ldap_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPOutpostConfigList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_ldap_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_ldap_list + + LDAPProvider Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_ldap_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPOutpostConfigList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_ldap_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_proxy_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedProxyOutpostConfigList: + """outposts_proxy_list + + ProxyProvider Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_proxy_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedProxyOutpostConfigList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_proxy_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedProxyOutpostConfigList]: + """outposts_proxy_list + + ProxyProvider Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_proxy_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedProxyOutpostConfigList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_proxy_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_proxy_list + + ProxyProvider Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_proxy_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedProxyOutpostConfigList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_proxy_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/proxy/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_radius_access_check( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + app_slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RadiusCheckAccess: + """outposts_radius_access_check + + Check access to a single application by slug + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param app_slug: + :type app_slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_radius_access_check_serialize( + id=id, + app_slug=app_slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusCheckAccess", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_radius_access_check_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + app_slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RadiusCheckAccess]: + """outposts_radius_access_check + + Check access to a single application by slug + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param app_slug: + :type app_slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_radius_access_check_serialize( + id=id, + app_slug=app_slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusCheckAccess", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_radius_access_check_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + app_slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_radius_access_check + + Check access to a single application by slug + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param app_slug: + :type app_slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_radius_access_check_serialize( + id=id, + app_slug=app_slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusCheckAccess", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_radius_access_check_serialize( + self, + id, + app_slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + if app_slug is not None: + + _query_params.append(('app_slug', app_slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/radius/{id}/check_access/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_radius_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedRadiusOutpostConfigList: + """outposts_radius_list + + RadiusProvider Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_radius_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRadiusOutpostConfigList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_radius_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedRadiusOutpostConfigList]: + """outposts_radius_list + + RadiusProvider Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_radius_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRadiusOutpostConfigList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_radius_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_radius_list + + RadiusProvider Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_radius_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRadiusOutpostConfigList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_radius_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/radius/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_all_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """outposts_service_connections_all_destroy + + ServiceConnection Viewset + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_all_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """outposts_service_connections_all_destroy + + ServiceConnection Viewset + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_all_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_all_destroy + + ServiceConnection Viewset + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_all_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/outposts/service_connections/all/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_all_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedServiceConnectionList: + """outposts_service_connections_all_list + + ServiceConnection Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedServiceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_all_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedServiceConnectionList]: + """outposts_service_connections_all_list + + ServiceConnection Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedServiceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_all_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_all_list + + ServiceConnection Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedServiceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_all_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_all_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ServiceConnection: + """outposts_service_connections_all_retrieve + + ServiceConnection Viewset + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_all_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ServiceConnection]: + """outposts_service_connections_all_retrieve + + ServiceConnection Viewset + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_all_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_all_retrieve + + ServiceConnection Viewset + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_all_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/all/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_all_state_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ServiceConnectionState: + """outposts_service_connections_all_state_retrieve + + Get the service connection's state + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_state_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ServiceConnectionState", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_all_state_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ServiceConnectionState]: + """outposts_service_connections_all_state_retrieve + + Get the service connection's state + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_state_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ServiceConnectionState", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_all_state_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_all_state_retrieve + + Get the service connection's state + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_state_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ServiceConnectionState", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_all_state_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/all/{uuid}/state/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_all_types_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[TypeCreate]: + """outposts_service_connections_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_all_types_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[TypeCreate]]: + """outposts_service_connections_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_all_types_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_all_types_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/all/types/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_all_used_by_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """outposts_service_connections_all_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_all_used_by_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """outposts_service_connections_all_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_all_used_by_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Outpost Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_all_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Outpost Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_all_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_all_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/all/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_docker_create( + self, + docker_service_connection_request: DockerServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DockerServiceConnection: + """outposts_service_connections_docker_create + + DockerServiceConnection Viewset + + :param docker_service_connection_request: (required) + :type docker_service_connection_request: DockerServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_create_serialize( + docker_service_connection_request=docker_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_docker_create_with_http_info( + self, + docker_service_connection_request: DockerServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DockerServiceConnection]: + """outposts_service_connections_docker_create + + DockerServiceConnection Viewset + + :param docker_service_connection_request: (required) + :type docker_service_connection_request: DockerServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_create_serialize( + docker_service_connection_request=docker_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_docker_create_without_preload_content( + self, + docker_service_connection_request: DockerServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_docker_create + + DockerServiceConnection Viewset + + :param docker_service_connection_request: (required) + :type docker_service_connection_request: DockerServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_create_serialize( + docker_service_connection_request=docker_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_docker_create_serialize( + self, + docker_service_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if docker_service_connection_request is not None: + _body_params = docker_service_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/outposts/service_connections/docker/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_docker_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """outposts_service_connections_docker_destroy + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_docker_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """outposts_service_connections_docker_destroy + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_docker_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_docker_destroy + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_docker_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/outposts/service_connections/docker/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_docker_list( + self, + local: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + tls_authentication: Optional[UUID] = None, + tls_verification: Optional[UUID] = None, + url: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDockerServiceConnectionList: + """outposts_service_connections_docker_list + + DockerServiceConnection Viewset + + :param local: + :type local: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param tls_authentication: + :type tls_authentication: UUID + :param tls_verification: + :type tls_verification: UUID + :param url: + :type url: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_list_serialize( + local=local, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + tls_authentication=tls_authentication, + tls_verification=tls_verification, + url=url, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDockerServiceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_docker_list_with_http_info( + self, + local: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + tls_authentication: Optional[UUID] = None, + tls_verification: Optional[UUID] = None, + url: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDockerServiceConnectionList]: + """outposts_service_connections_docker_list + + DockerServiceConnection Viewset + + :param local: + :type local: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param tls_authentication: + :type tls_authentication: UUID + :param tls_verification: + :type tls_verification: UUID + :param url: + :type url: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_list_serialize( + local=local, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + tls_authentication=tls_authentication, + tls_verification=tls_verification, + url=url, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDockerServiceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_docker_list_without_preload_content( + self, + local: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + tls_authentication: Optional[UUID] = None, + tls_verification: Optional[UUID] = None, + url: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_docker_list + + DockerServiceConnection Viewset + + :param local: + :type local: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param tls_authentication: + :type tls_authentication: UUID + :param tls_verification: + :type tls_verification: UUID + :param url: + :type url: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_list_serialize( + local=local, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + tls_authentication=tls_authentication, + tls_verification=tls_verification, + url=url, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDockerServiceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_docker_list_serialize( + self, + local, + name, + ordering, + page, + page_size, + search, + tls_authentication, + tls_verification, + url, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if local is not None: + + _query_params.append(('local', local)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if tls_authentication is not None: + + _query_params.append(('tls_authentication', tls_authentication)) + + if tls_verification is not None: + + _query_params.append(('tls_verification', tls_verification)) + + if url is not None: + + _query_params.append(('url', url)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/docker/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_docker_partial_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + patched_docker_service_connection_request: Optional[PatchedDockerServiceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DockerServiceConnection: + """outposts_service_connections_docker_partial_update + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param patched_docker_service_connection_request: + :type patched_docker_service_connection_request: PatchedDockerServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_partial_update_serialize( + uuid=uuid, + patched_docker_service_connection_request=patched_docker_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_docker_partial_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + patched_docker_service_connection_request: Optional[PatchedDockerServiceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DockerServiceConnection]: + """outposts_service_connections_docker_partial_update + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param patched_docker_service_connection_request: + :type patched_docker_service_connection_request: PatchedDockerServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_partial_update_serialize( + uuid=uuid, + patched_docker_service_connection_request=patched_docker_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_docker_partial_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + patched_docker_service_connection_request: Optional[PatchedDockerServiceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_docker_partial_update + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param patched_docker_service_connection_request: + :type patched_docker_service_connection_request: PatchedDockerServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_partial_update_serialize( + uuid=uuid, + patched_docker_service_connection_request=patched_docker_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_docker_partial_update_serialize( + self, + uuid, + patched_docker_service_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_docker_service_connection_request is not None: + _body_params = patched_docker_service_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/outposts/service_connections/docker/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_docker_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DockerServiceConnection: + """outposts_service_connections_docker_retrieve + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_docker_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DockerServiceConnection]: + """outposts_service_connections_docker_retrieve + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_docker_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_docker_retrieve + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_docker_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/docker/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_docker_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + docker_service_connection_request: DockerServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DockerServiceConnection: + """outposts_service_connections_docker_update + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param docker_service_connection_request: (required) + :type docker_service_connection_request: DockerServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_update_serialize( + uuid=uuid, + docker_service_connection_request=docker_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_docker_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + docker_service_connection_request: DockerServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DockerServiceConnection]: + """outposts_service_connections_docker_update + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param docker_service_connection_request: (required) + :type docker_service_connection_request: DockerServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_update_serialize( + uuid=uuid, + docker_service_connection_request=docker_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_docker_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + docker_service_connection_request: DockerServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_docker_update + + DockerServiceConnection Viewset + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param docker_service_connection_request: (required) + :type docker_service_connection_request: DockerServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_update_serialize( + uuid=uuid, + docker_service_connection_request=docker_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DockerServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_docker_update_serialize( + self, + uuid, + docker_service_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if docker_service_connection_request is not None: + _body_params = docker_service_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/outposts/service_connections/docker/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_docker_used_by_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """outposts_service_connections_docker_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_docker_used_by_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """outposts_service_connections_docker_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_docker_used_by_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Docker Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_docker_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Docker Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_docker_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_docker_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/docker/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_kubernetes_create( + self, + kubernetes_service_connection_request: KubernetesServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KubernetesServiceConnection: + """outposts_service_connections_kubernetes_create + + KubernetesServiceConnection Viewset + + :param kubernetes_service_connection_request: (required) + :type kubernetes_service_connection_request: KubernetesServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_create_serialize( + kubernetes_service_connection_request=kubernetes_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_kubernetes_create_with_http_info( + self, + kubernetes_service_connection_request: KubernetesServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KubernetesServiceConnection]: + """outposts_service_connections_kubernetes_create + + KubernetesServiceConnection Viewset + + :param kubernetes_service_connection_request: (required) + :type kubernetes_service_connection_request: KubernetesServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_create_serialize( + kubernetes_service_connection_request=kubernetes_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_kubernetes_create_without_preload_content( + self, + kubernetes_service_connection_request: KubernetesServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_kubernetes_create + + KubernetesServiceConnection Viewset + + :param kubernetes_service_connection_request: (required) + :type kubernetes_service_connection_request: KubernetesServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_create_serialize( + kubernetes_service_connection_request=kubernetes_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_kubernetes_create_serialize( + self, + kubernetes_service_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if kubernetes_service_connection_request is not None: + _body_params = kubernetes_service_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/outposts/service_connections/kubernetes/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_kubernetes_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """outposts_service_connections_kubernetes_destroy + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_kubernetes_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """outposts_service_connections_kubernetes_destroy + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_kubernetes_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_kubernetes_destroy + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_kubernetes_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/outposts/service_connections/kubernetes/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_kubernetes_list( + self, + local: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedKubernetesServiceConnectionList: + """outposts_service_connections_kubernetes_list + + KubernetesServiceConnection Viewset + + :param local: + :type local: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_list_serialize( + local=local, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedKubernetesServiceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_kubernetes_list_with_http_info( + self, + local: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedKubernetesServiceConnectionList]: + """outposts_service_connections_kubernetes_list + + KubernetesServiceConnection Viewset + + :param local: + :type local: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_list_serialize( + local=local, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedKubernetesServiceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_kubernetes_list_without_preload_content( + self, + local: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_kubernetes_list + + KubernetesServiceConnection Viewset + + :param local: + :type local: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_list_serialize( + local=local, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedKubernetesServiceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_kubernetes_list_serialize( + self, + local, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if local is not None: + + _query_params.append(('local', local)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/kubernetes/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_kubernetes_partial_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + patched_kubernetes_service_connection_request: Optional[PatchedKubernetesServiceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KubernetesServiceConnection: + """outposts_service_connections_kubernetes_partial_update + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param patched_kubernetes_service_connection_request: + :type patched_kubernetes_service_connection_request: PatchedKubernetesServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_partial_update_serialize( + uuid=uuid, + patched_kubernetes_service_connection_request=patched_kubernetes_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_kubernetes_partial_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + patched_kubernetes_service_connection_request: Optional[PatchedKubernetesServiceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KubernetesServiceConnection]: + """outposts_service_connections_kubernetes_partial_update + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param patched_kubernetes_service_connection_request: + :type patched_kubernetes_service_connection_request: PatchedKubernetesServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_partial_update_serialize( + uuid=uuid, + patched_kubernetes_service_connection_request=patched_kubernetes_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_kubernetes_partial_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + patched_kubernetes_service_connection_request: Optional[PatchedKubernetesServiceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_kubernetes_partial_update + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param patched_kubernetes_service_connection_request: + :type patched_kubernetes_service_connection_request: PatchedKubernetesServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_partial_update_serialize( + uuid=uuid, + patched_kubernetes_service_connection_request=patched_kubernetes_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_kubernetes_partial_update_serialize( + self, + uuid, + patched_kubernetes_service_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_kubernetes_service_connection_request is not None: + _body_params = patched_kubernetes_service_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/outposts/service_connections/kubernetes/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_kubernetes_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KubernetesServiceConnection: + """outposts_service_connections_kubernetes_retrieve + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_kubernetes_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KubernetesServiceConnection]: + """outposts_service_connections_kubernetes_retrieve + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_kubernetes_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_kubernetes_retrieve + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_kubernetes_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/kubernetes/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_kubernetes_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + kubernetes_service_connection_request: KubernetesServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KubernetesServiceConnection: + """outposts_service_connections_kubernetes_update + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param kubernetes_service_connection_request: (required) + :type kubernetes_service_connection_request: KubernetesServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_update_serialize( + uuid=uuid, + kubernetes_service_connection_request=kubernetes_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_kubernetes_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + kubernetes_service_connection_request: KubernetesServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KubernetesServiceConnection]: + """outposts_service_connections_kubernetes_update + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param kubernetes_service_connection_request: (required) + :type kubernetes_service_connection_request: KubernetesServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_update_serialize( + uuid=uuid, + kubernetes_service_connection_request=kubernetes_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_kubernetes_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + kubernetes_service_connection_request: KubernetesServiceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_kubernetes_update + + KubernetesServiceConnection Viewset + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param kubernetes_service_connection_request: (required) + :type kubernetes_service_connection_request: KubernetesServiceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_update_serialize( + uuid=uuid, + kubernetes_service_connection_request=kubernetes_service_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KubernetesServiceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_kubernetes_update_serialize( + self, + uuid, + kubernetes_service_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if kubernetes_service_connection_request is not None: + _body_params = kubernetes_service_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/outposts/service_connections/kubernetes/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def outposts_service_connections_kubernetes_used_by_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """outposts_service_connections_kubernetes_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def outposts_service_connections_kubernetes_used_by_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """outposts_service_connections_kubernetes_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def outposts_service_connections_kubernetes_used_by_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Kubernetes Service-Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """outposts_service_connections_kubernetes_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Kubernetes Service-Connection. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._outposts_service_connections_kubernetes_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _outposts_service_connections_kubernetes_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/outposts/service_connections/kubernetes/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/policies_api.py b/authentik_client/api/policies_api.py new file mode 100644 index 000000000..4c957052e --- /dev/null +++ b/authentik_client/api/policies_api.py @@ -0,0 +1,23004 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from datetime import datetime +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import Any, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.cache import Cache +from authentik_client.models.detailed_country import DetailedCountry +from authentik_client.models.dummy_policy import DummyPolicy +from authentik_client.models.dummy_policy_request import DummyPolicyRequest +from authentik_client.models.event_matcher_policy import EventMatcherPolicy +from authentik_client.models.event_matcher_policy_request import EventMatcherPolicyRequest +from authentik_client.models.expression_policy import ExpressionPolicy +from authentik_client.models.expression_policy_request import ExpressionPolicyRequest +from authentik_client.models.geo_ip_policy import GeoIPPolicy +from authentik_client.models.geo_ip_policy_request import GeoIPPolicyRequest +from authentik_client.models.paginated_dummy_policy_list import PaginatedDummyPolicyList +from authentik_client.models.paginated_event_matcher_policy_list import PaginatedEventMatcherPolicyList +from authentik_client.models.paginated_expression_policy_list import PaginatedExpressionPolicyList +from authentik_client.models.paginated_geo_ip_policy_list import PaginatedGeoIPPolicyList +from authentik_client.models.paginated_password_expiry_policy_list import PaginatedPasswordExpiryPolicyList +from authentik_client.models.paginated_password_policy_list import PaginatedPasswordPolicyList +from authentik_client.models.paginated_policy_binding_list import PaginatedPolicyBindingList +from authentik_client.models.paginated_policy_list import PaginatedPolicyList +from authentik_client.models.paginated_reputation_list import PaginatedReputationList +from authentik_client.models.paginated_reputation_policy_list import PaginatedReputationPolicyList +from authentik_client.models.paginated_unique_password_policy_list import PaginatedUniquePasswordPolicyList +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy +from authentik_client.models.password_expiry_policy_request import PasswordExpiryPolicyRequest +from authentik_client.models.password_policy import PasswordPolicy +from authentik_client.models.password_policy_request import PasswordPolicyRequest +from authentik_client.models.patched_dummy_policy_request import PatchedDummyPolicyRequest +from authentik_client.models.patched_event_matcher_policy_request import PatchedEventMatcherPolicyRequest +from authentik_client.models.patched_expression_policy_request import PatchedExpressionPolicyRequest +from authentik_client.models.patched_geo_ip_policy_request import PatchedGeoIPPolicyRequest +from authentik_client.models.patched_password_expiry_policy_request import PatchedPasswordExpiryPolicyRequest +from authentik_client.models.patched_password_policy_request import PatchedPasswordPolicyRequest +from authentik_client.models.patched_policy_binding_request import PatchedPolicyBindingRequest +from authentik_client.models.patched_reputation_policy_request import PatchedReputationPolicyRequest +from authentik_client.models.patched_unique_password_policy_request import PatchedUniquePasswordPolicyRequest +from authentik_client.models.policy import Policy +from authentik_client.models.policy_binding import PolicyBinding +from authentik_client.models.policy_binding_request import PolicyBindingRequest +from authentik_client.models.policy_test_request import PolicyTestRequest +from authentik_client.models.policy_test_result import PolicyTestResult +from authentik_client.models.reputation import Reputation +from authentik_client.models.reputation_policy import ReputationPolicy +from authentik_client.models.reputation_policy_request import ReputationPolicyRequest +from authentik_client.models.type_create import TypeCreate +from authentik_client.models.unique_password_policy import UniquePasswordPolicy +from authentik_client.models.unique_password_policy_request import UniquePasswordPolicyRequest +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class PoliciesApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def policies_all_cache_clear_create( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_all_cache_clear_create + + Clear policy cache + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_cache_clear_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_all_cache_clear_create_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_all_cache_clear_create + + Clear policy cache + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_cache_clear_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_all_cache_clear_create_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_all_cache_clear_create + + Clear policy cache + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_cache_clear_create_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_all_cache_clear_create_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/all/cache_clear/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_all_cache_info_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Cache: + """policies_all_cache_info_retrieve + + Info about cached policies + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_cache_info_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Cache", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_all_cache_info_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Cache]: + """policies_all_cache_info_retrieve + + Info about cached policies + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_cache_info_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Cache", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_all_cache_info_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_all_cache_info_retrieve + + Info about cached policies + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_cache_info_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Cache", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_all_cache_info_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/all/cache_info/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_all_destroy( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_all_destroy + + Policy Viewset + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_all_destroy_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_all_destroy + + Policy Viewset + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_all_destroy_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_all_destroy + + Policy Viewset + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_all_destroy_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/all/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_all_list( + self, + bindings__isnull: Optional[StrictBool] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + promptstage__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPolicyList: + """policies_all_list + + Policy Viewset + + :param bindings__isnull: + :type bindings__isnull: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param promptstage__isnull: + :type promptstage__isnull: bool + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_list_serialize( + bindings__isnull=bindings__isnull, + ordering=ordering, + page=page, + page_size=page_size, + promptstage__isnull=promptstage__isnull, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_all_list_with_http_info( + self, + bindings__isnull: Optional[StrictBool] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + promptstage__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPolicyList]: + """policies_all_list + + Policy Viewset + + :param bindings__isnull: + :type bindings__isnull: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param promptstage__isnull: + :type promptstage__isnull: bool + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_list_serialize( + bindings__isnull=bindings__isnull, + ordering=ordering, + page=page, + page_size=page_size, + promptstage__isnull=promptstage__isnull, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_all_list_without_preload_content( + self, + bindings__isnull: Optional[StrictBool] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + promptstage__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_all_list + + Policy Viewset + + :param bindings__isnull: + :type bindings__isnull: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param promptstage__isnull: + :type promptstage__isnull: bool + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_list_serialize( + bindings__isnull=bindings__isnull, + ordering=ordering, + page=page, + page_size=page_size, + promptstage__isnull=promptstage__isnull, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_all_list_serialize( + self, + bindings__isnull, + ordering, + page, + page_size, + promptstage__isnull, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if bindings__isnull is not None: + + _query_params.append(('bindings__isnull', bindings__isnull)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if promptstage__isnull is not None: + + _query_params.append(('promptstage__isnull', promptstage__isnull)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_all_retrieve( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Policy: + """policies_all_retrieve + + Policy Viewset + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Policy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_all_retrieve_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Policy]: + """policies_all_retrieve + + Policy Viewset + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Policy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_all_retrieve_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_all_retrieve + + Policy Viewset + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Policy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_all_retrieve_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/all/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_all_test_create( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + policy_test_request: PolicyTestRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PolicyTestResult: + """policies_all_test_create + + Test policy + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param policy_test_request: (required) + :type policy_test_request: PolicyTestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_test_create_serialize( + policy_uuid=policy_uuid, + policy_test_request=policy_test_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyTestResult", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_all_test_create_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + policy_test_request: PolicyTestRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PolicyTestResult]: + """policies_all_test_create + + Test policy + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param policy_test_request: (required) + :type policy_test_request: PolicyTestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_test_create_serialize( + policy_uuid=policy_uuid, + policy_test_request=policy_test_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyTestResult", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_all_test_create_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + policy_test_request: PolicyTestRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_all_test_create + + Test policy + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param policy_test_request: (required) + :type policy_test_request: PolicyTestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_test_create_serialize( + policy_uuid=policy_uuid, + policy_test_request=policy_test_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyTestResult", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_all_test_create_serialize( + self, + policy_uuid, + policy_test_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if policy_test_request is not None: + _body_params = policy_test_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/all/{policy_uuid}/test/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_all_types_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[TypeCreate]: + """policies_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_all_types_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[TypeCreate]]: + """policies_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_all_types_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_all_types_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/all/types/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_all_used_by_list( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_all_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_all_used_by_list_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_all_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_all_used_by_list_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_all_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_all_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_all_used_by_list_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/all/{policy_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_bindings_create( + self, + policy_binding_request: PolicyBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PolicyBinding: + """policies_bindings_create + + PolicyBinding Viewset + + :param policy_binding_request: (required) + :type policy_binding_request: PolicyBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_create_serialize( + policy_binding_request=policy_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_bindings_create_with_http_info( + self, + policy_binding_request: PolicyBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PolicyBinding]: + """policies_bindings_create + + PolicyBinding Viewset + + :param policy_binding_request: (required) + :type policy_binding_request: PolicyBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_create_serialize( + policy_binding_request=policy_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_bindings_create_without_preload_content( + self, + policy_binding_request: PolicyBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_bindings_create + + PolicyBinding Viewset + + :param policy_binding_request: (required) + :type policy_binding_request: PolicyBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_create_serialize( + policy_binding_request=policy_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_bindings_create_serialize( + self, + policy_binding_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if policy_binding_request is not None: + _body_params = policy_binding_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/bindings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_bindings_destroy( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_bindings_destroy + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_destroy_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_bindings_destroy_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_bindings_destroy + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_destroy_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_bindings_destroy_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_bindings_destroy + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_destroy_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_bindings_destroy_serialize( + self, + policy_binding_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/bindings/{policy_binding_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_bindings_list( + self, + enabled: Optional[StrictBool] = None, + order: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy: Optional[UUID] = None, + policy__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + target: Optional[UUID] = None, + target_in: Optional[List[UUID]] = None, + timeout: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPolicyBindingList: + """policies_bindings_list + + PolicyBinding Viewset + + :param enabled: + :type enabled: bool + :param order: + :type order: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy: + :type policy: UUID + :param policy__isnull: + :type policy__isnull: bool + :param search: A search term. + :type search: str + :param target: + :type target: UUID + :param target_in: + :type target_in: List[UUID] + :param timeout: + :type timeout: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_list_serialize( + enabled=enabled, + order=order, + ordering=ordering, + page=page, + page_size=page_size, + policy=policy, + policy__isnull=policy__isnull, + search=search, + target=target, + target_in=target_in, + timeout=timeout, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPolicyBindingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_bindings_list_with_http_info( + self, + enabled: Optional[StrictBool] = None, + order: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy: Optional[UUID] = None, + policy__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + target: Optional[UUID] = None, + target_in: Optional[List[UUID]] = None, + timeout: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPolicyBindingList]: + """policies_bindings_list + + PolicyBinding Viewset + + :param enabled: + :type enabled: bool + :param order: + :type order: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy: + :type policy: UUID + :param policy__isnull: + :type policy__isnull: bool + :param search: A search term. + :type search: str + :param target: + :type target: UUID + :param target_in: + :type target_in: List[UUID] + :param timeout: + :type timeout: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_list_serialize( + enabled=enabled, + order=order, + ordering=ordering, + page=page, + page_size=page_size, + policy=policy, + policy__isnull=policy__isnull, + search=search, + target=target, + target_in=target_in, + timeout=timeout, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPolicyBindingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_bindings_list_without_preload_content( + self, + enabled: Optional[StrictBool] = None, + order: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy: Optional[UUID] = None, + policy__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + target: Optional[UUID] = None, + target_in: Optional[List[UUID]] = None, + timeout: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_bindings_list + + PolicyBinding Viewset + + :param enabled: + :type enabled: bool + :param order: + :type order: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy: + :type policy: UUID + :param policy__isnull: + :type policy__isnull: bool + :param search: A search term. + :type search: str + :param target: + :type target: UUID + :param target_in: + :type target_in: List[UUID] + :param timeout: + :type timeout: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_list_serialize( + enabled=enabled, + order=order, + ordering=ordering, + page=page, + page_size=page_size, + policy=policy, + policy__isnull=policy__isnull, + search=search, + target=target, + target_in=target_in, + timeout=timeout, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPolicyBindingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_bindings_list_serialize( + self, + enabled, + order, + ordering, + page, + page_size, + policy, + policy__isnull, + search, + target, + target_in, + timeout, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'target_in': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if enabled is not None: + + _query_params.append(('enabled', enabled)) + + if order is not None: + + _query_params.append(('order', order)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if policy is not None: + + _query_params.append(('policy', policy)) + + if policy__isnull is not None: + + _query_params.append(('policy__isnull', policy__isnull)) + + if search is not None: + + _query_params.append(('search', search)) + + if target is not None: + + _query_params.append(('target', target)) + + if target_in is not None: + + _query_params.append(('target_in', target_in)) + + if timeout is not None: + + _query_params.append(('timeout', timeout)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/bindings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_bindings_partial_update( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + patched_policy_binding_request: Optional[PatchedPolicyBindingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PolicyBinding: + """policies_bindings_partial_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param patched_policy_binding_request: + :type patched_policy_binding_request: PatchedPolicyBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_partial_update_serialize( + policy_binding_uuid=policy_binding_uuid, + patched_policy_binding_request=patched_policy_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_bindings_partial_update_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + patched_policy_binding_request: Optional[PatchedPolicyBindingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PolicyBinding]: + """policies_bindings_partial_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param patched_policy_binding_request: + :type patched_policy_binding_request: PatchedPolicyBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_partial_update_serialize( + policy_binding_uuid=policy_binding_uuid, + patched_policy_binding_request=patched_policy_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_bindings_partial_update_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + patched_policy_binding_request: Optional[PatchedPolicyBindingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_bindings_partial_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param patched_policy_binding_request: + :type patched_policy_binding_request: PatchedPolicyBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_partial_update_serialize( + policy_binding_uuid=policy_binding_uuid, + patched_policy_binding_request=patched_policy_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_bindings_partial_update_serialize( + self, + policy_binding_uuid, + patched_policy_binding_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_policy_binding_request is not None: + _body_params = patched_policy_binding_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/policies/bindings/{policy_binding_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_bindings_retrieve( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PolicyBinding: + """policies_bindings_retrieve + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_retrieve_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_bindings_retrieve_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PolicyBinding]: + """policies_bindings_retrieve + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_retrieve_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_bindings_retrieve_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_bindings_retrieve + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_retrieve_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_bindings_retrieve_serialize( + self, + policy_binding_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/bindings/{policy_binding_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_bindings_update( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + policy_binding_request: PolicyBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PolicyBinding: + """policies_bindings_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param policy_binding_request: (required) + :type policy_binding_request: PolicyBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_update_serialize( + policy_binding_uuid=policy_binding_uuid, + policy_binding_request=policy_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_bindings_update_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + policy_binding_request: PolicyBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PolicyBinding]: + """policies_bindings_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param policy_binding_request: (required) + :type policy_binding_request: PolicyBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_update_serialize( + policy_binding_uuid=policy_binding_uuid, + policy_binding_request=policy_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_bindings_update_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + policy_binding_request: PolicyBindingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_bindings_update + + PolicyBinding Viewset + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param policy_binding_request: (required) + :type policy_binding_request: PolicyBindingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_update_serialize( + policy_binding_uuid=policy_binding_uuid, + policy_binding_request=policy_binding_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PolicyBinding", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_bindings_update_serialize( + self, + policy_binding_uuid, + policy_binding_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if policy_binding_request is not None: + _body_params = policy_binding_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/policies/bindings/{policy_binding_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_bindings_used_by_list( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_bindings_used_by_list + + Get a list of all objects that use this object + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_used_by_list_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_bindings_used_by_list_with_http_info( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_bindings_used_by_list + + Get a list of all objects that use this object + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_used_by_list_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_bindings_used_by_list_without_preload_content( + self, + policy_binding_uuid: Annotated[UUID, Field(description="A UUID string identifying this Policy Binding.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_bindings_used_by_list + + Get a list of all objects that use this object + + :param policy_binding_uuid: A UUID string identifying this Policy Binding. (required) + :type policy_binding_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_bindings_used_by_list_serialize( + policy_binding_uuid=policy_binding_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_bindings_used_by_list_serialize( + self, + policy_binding_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_binding_uuid is not None: + _path_params['policy_binding_uuid'] = policy_binding_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/bindings/{policy_binding_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_dummy_create( + self, + dummy_policy_request: DummyPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DummyPolicy: + """policies_dummy_create + + Dummy Viewset + + :param dummy_policy_request: (required) + :type dummy_policy_request: DummyPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_create_serialize( + dummy_policy_request=dummy_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_dummy_create_with_http_info( + self, + dummy_policy_request: DummyPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DummyPolicy]: + """policies_dummy_create + + Dummy Viewset + + :param dummy_policy_request: (required) + :type dummy_policy_request: DummyPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_create_serialize( + dummy_policy_request=dummy_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_dummy_create_without_preload_content( + self, + dummy_policy_request: DummyPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_dummy_create + + Dummy Viewset + + :param dummy_policy_request: (required) + :type dummy_policy_request: DummyPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_create_serialize( + dummy_policy_request=dummy_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_dummy_create_serialize( + self, + dummy_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if dummy_policy_request is not None: + _body_params = dummy_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/dummy/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_dummy_destroy( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_dummy_destroy + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_dummy_destroy_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_dummy_destroy + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_dummy_destroy_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_dummy_destroy + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_dummy_destroy_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/dummy/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_dummy_list( + self, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + result: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + wait_max: Optional[StrictInt] = None, + wait_min: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDummyPolicyList: + """policies_dummy_list + + Dummy Viewset + + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param result: + :type result: bool + :param search: A search term. + :type search: str + :param wait_max: + :type wait_max: int + :param wait_min: + :type wait_min: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_list_serialize( + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + result=result, + search=search, + wait_max=wait_max, + wait_min=wait_min, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDummyPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_dummy_list_with_http_info( + self, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + result: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + wait_max: Optional[StrictInt] = None, + wait_min: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDummyPolicyList]: + """policies_dummy_list + + Dummy Viewset + + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param result: + :type result: bool + :param search: A search term. + :type search: str + :param wait_max: + :type wait_max: int + :param wait_min: + :type wait_min: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_list_serialize( + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + result=result, + search=search, + wait_max=wait_max, + wait_min=wait_min, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDummyPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_dummy_list_without_preload_content( + self, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + result: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + wait_max: Optional[StrictInt] = None, + wait_min: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_dummy_list + + Dummy Viewset + + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param result: + :type result: bool + :param search: A search term. + :type search: str + :param wait_max: + :type wait_max: int + :param wait_min: + :type wait_min: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_list_serialize( + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + result=result, + search=search, + wait_max=wait_max, + wait_min=wait_min, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDummyPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_dummy_list_serialize( + self, + created, + execution_logging, + last_updated, + name, + ordering, + page, + page_size, + policy_uuid, + result, + search, + wait_max, + wait_min, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if created is not None: + if isinstance(created, datetime): + _query_params.append( + ( + 'created', + created.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('created', created)) + + if execution_logging is not None: + + _query_params.append(('execution_logging', execution_logging)) + + if last_updated is not None: + if isinstance(last_updated, datetime): + _query_params.append( + ( + 'last_updated', + last_updated.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated', last_updated)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if policy_uuid is not None: + + _query_params.append(('policy_uuid', policy_uuid)) + + if result is not None: + + _query_params.append(('result', result)) + + if search is not None: + + _query_params.append(('search', search)) + + if wait_max is not None: + + _query_params.append(('wait_max', wait_max)) + + if wait_min is not None: + + _query_params.append(('wait_min', wait_min)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/dummy/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_dummy_partial_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + patched_dummy_policy_request: Optional[PatchedDummyPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DummyPolicy: + """policies_dummy_partial_update + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param patched_dummy_policy_request: + :type patched_dummy_policy_request: PatchedDummyPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_partial_update_serialize( + policy_uuid=policy_uuid, + patched_dummy_policy_request=patched_dummy_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_dummy_partial_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + patched_dummy_policy_request: Optional[PatchedDummyPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DummyPolicy]: + """policies_dummy_partial_update + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param patched_dummy_policy_request: + :type patched_dummy_policy_request: PatchedDummyPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_partial_update_serialize( + policy_uuid=policy_uuid, + patched_dummy_policy_request=patched_dummy_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_dummy_partial_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + patched_dummy_policy_request: Optional[PatchedDummyPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_dummy_partial_update + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param patched_dummy_policy_request: + :type patched_dummy_policy_request: PatchedDummyPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_partial_update_serialize( + policy_uuid=policy_uuid, + patched_dummy_policy_request=patched_dummy_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_dummy_partial_update_serialize( + self, + policy_uuid, + patched_dummy_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_dummy_policy_request is not None: + _body_params = patched_dummy_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/policies/dummy/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_dummy_retrieve( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DummyPolicy: + """policies_dummy_retrieve + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_dummy_retrieve_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DummyPolicy]: + """policies_dummy_retrieve + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_dummy_retrieve_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_dummy_retrieve + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_dummy_retrieve_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/dummy/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_dummy_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + dummy_policy_request: DummyPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DummyPolicy: + """policies_dummy_update + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param dummy_policy_request: (required) + :type dummy_policy_request: DummyPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_update_serialize( + policy_uuid=policy_uuid, + dummy_policy_request=dummy_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_dummy_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + dummy_policy_request: DummyPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DummyPolicy]: + """policies_dummy_update + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param dummy_policy_request: (required) + :type dummy_policy_request: DummyPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_update_serialize( + policy_uuid=policy_uuid, + dummy_policy_request=dummy_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_dummy_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + dummy_policy_request: DummyPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_dummy_update + + Dummy Viewset + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param dummy_policy_request: (required) + :type dummy_policy_request: DummyPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_update_serialize( + policy_uuid=policy_uuid, + dummy_policy_request=dummy_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_dummy_update_serialize( + self, + policy_uuid, + dummy_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if dummy_policy_request is not None: + _body_params = dummy_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/policies/dummy/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_dummy_used_by_list( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_dummy_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_dummy_used_by_list_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_dummy_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_dummy_used_by_list_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_dummy_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Dummy Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_dummy_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_dummy_used_by_list_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/dummy/{policy_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_event_matcher_create( + self, + event_matcher_policy_request: EventMatcherPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EventMatcherPolicy: + """policies_event_matcher_create + + Event Matcher Policy Viewset + + :param event_matcher_policy_request: (required) + :type event_matcher_policy_request: EventMatcherPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_create_serialize( + event_matcher_policy_request=event_matcher_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_event_matcher_create_with_http_info( + self, + event_matcher_policy_request: EventMatcherPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EventMatcherPolicy]: + """policies_event_matcher_create + + Event Matcher Policy Viewset + + :param event_matcher_policy_request: (required) + :type event_matcher_policy_request: EventMatcherPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_create_serialize( + event_matcher_policy_request=event_matcher_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_event_matcher_create_without_preload_content( + self, + event_matcher_policy_request: EventMatcherPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_event_matcher_create + + Event Matcher Policy Viewset + + :param event_matcher_policy_request: (required) + :type event_matcher_policy_request: EventMatcherPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_create_serialize( + event_matcher_policy_request=event_matcher_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_event_matcher_create_serialize( + self, + event_matcher_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if event_matcher_policy_request is not None: + _body_params = event_matcher_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/event_matcher/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_event_matcher_destroy( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_event_matcher_destroy + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_event_matcher_destroy_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_event_matcher_destroy + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_event_matcher_destroy_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_event_matcher_destroy + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_event_matcher_destroy_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/event_matcher/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_event_matcher_list( + self, + action: Optional[Any] = None, + app: Optional[StrictStr] = None, + client_ip: Optional[StrictStr] = None, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + model: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + query: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedEventMatcherPolicyList: + """policies_event_matcher_list + + Event Matcher Policy Viewset + + :param action: + :type action: EventActions + :param app: + :type app: str + :param client_ip: + :type client_ip: str + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param model: + :type model: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param query: + :type query: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_list_serialize( + action=action, + app=app, + client_ip=client_ip, + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + model=model, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + query=query, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEventMatcherPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_event_matcher_list_with_http_info( + self, + action: Optional[Any] = None, + app: Optional[StrictStr] = None, + client_ip: Optional[StrictStr] = None, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + model: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + query: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedEventMatcherPolicyList]: + """policies_event_matcher_list + + Event Matcher Policy Viewset + + :param action: + :type action: EventActions + :param app: + :type app: str + :param client_ip: + :type client_ip: str + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param model: + :type model: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param query: + :type query: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_list_serialize( + action=action, + app=app, + client_ip=client_ip, + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + model=model, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + query=query, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEventMatcherPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_event_matcher_list_without_preload_content( + self, + action: Optional[Any] = None, + app: Optional[StrictStr] = None, + client_ip: Optional[StrictStr] = None, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + model: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + query: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_event_matcher_list + + Event Matcher Policy Viewset + + :param action: + :type action: EventActions + :param app: + :type app: str + :param client_ip: + :type client_ip: str + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param model: + :type model: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param query: + :type query: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_list_serialize( + action=action, + app=app, + client_ip=client_ip, + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + model=model, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + query=query, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEventMatcherPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_event_matcher_list_serialize( + self, + action, + app, + client_ip, + created, + execution_logging, + last_updated, + model, + name, + ordering, + page, + page_size, + policy_uuid, + query, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if action is not None: + + _query_params.append(('action', action.value)) + + if app is not None: + + _query_params.append(('app', app)) + + if client_ip is not None: + + _query_params.append(('client_ip', client_ip)) + + if created is not None: + if isinstance(created, datetime): + _query_params.append( + ( + 'created', + created.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('created', created)) + + if execution_logging is not None: + + _query_params.append(('execution_logging', execution_logging)) + + if last_updated is not None: + if isinstance(last_updated, datetime): + _query_params.append( + ( + 'last_updated', + last_updated.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated', last_updated)) + + if model is not None: + + _query_params.append(('model', model)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if policy_uuid is not None: + + _query_params.append(('policy_uuid', policy_uuid)) + + if query is not None: + + _query_params.append(('query', query)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/event_matcher/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_event_matcher_partial_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + patched_event_matcher_policy_request: Optional[PatchedEventMatcherPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EventMatcherPolicy: + """policies_event_matcher_partial_update + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param patched_event_matcher_policy_request: + :type patched_event_matcher_policy_request: PatchedEventMatcherPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_partial_update_serialize( + policy_uuid=policy_uuid, + patched_event_matcher_policy_request=patched_event_matcher_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_event_matcher_partial_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + patched_event_matcher_policy_request: Optional[PatchedEventMatcherPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EventMatcherPolicy]: + """policies_event_matcher_partial_update + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param patched_event_matcher_policy_request: + :type patched_event_matcher_policy_request: PatchedEventMatcherPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_partial_update_serialize( + policy_uuid=policy_uuid, + patched_event_matcher_policy_request=patched_event_matcher_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_event_matcher_partial_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + patched_event_matcher_policy_request: Optional[PatchedEventMatcherPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_event_matcher_partial_update + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param patched_event_matcher_policy_request: + :type patched_event_matcher_policy_request: PatchedEventMatcherPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_partial_update_serialize( + policy_uuid=policy_uuid, + patched_event_matcher_policy_request=patched_event_matcher_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_event_matcher_partial_update_serialize( + self, + policy_uuid, + patched_event_matcher_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_event_matcher_policy_request is not None: + _body_params = patched_event_matcher_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/policies/event_matcher/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_event_matcher_retrieve( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EventMatcherPolicy: + """policies_event_matcher_retrieve + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_event_matcher_retrieve_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EventMatcherPolicy]: + """policies_event_matcher_retrieve + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_event_matcher_retrieve_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_event_matcher_retrieve + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_event_matcher_retrieve_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/event_matcher/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_event_matcher_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + event_matcher_policy_request: EventMatcherPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EventMatcherPolicy: + """policies_event_matcher_update + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param event_matcher_policy_request: (required) + :type event_matcher_policy_request: EventMatcherPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_update_serialize( + policy_uuid=policy_uuid, + event_matcher_policy_request=event_matcher_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_event_matcher_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + event_matcher_policy_request: EventMatcherPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EventMatcherPolicy]: + """policies_event_matcher_update + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param event_matcher_policy_request: (required) + :type event_matcher_policy_request: EventMatcherPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_update_serialize( + policy_uuid=policy_uuid, + event_matcher_policy_request=event_matcher_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_event_matcher_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + event_matcher_policy_request: EventMatcherPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_event_matcher_update + + Event Matcher Policy Viewset + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param event_matcher_policy_request: (required) + :type event_matcher_policy_request: EventMatcherPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_update_serialize( + policy_uuid=policy_uuid, + event_matcher_policy_request=event_matcher_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EventMatcherPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_event_matcher_update_serialize( + self, + policy_uuid, + event_matcher_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if event_matcher_policy_request is not None: + _body_params = event_matcher_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/policies/event_matcher/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_event_matcher_used_by_list( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_event_matcher_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_event_matcher_used_by_list_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_event_matcher_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_event_matcher_used_by_list_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Event Matcher Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_event_matcher_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Event Matcher Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_event_matcher_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_event_matcher_used_by_list_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/event_matcher/{policy_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_expression_create( + self, + expression_policy_request: ExpressionPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ExpressionPolicy: + """policies_expression_create + + Source Viewset + + :param expression_policy_request: (required) + :type expression_policy_request: ExpressionPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_create_serialize( + expression_policy_request=expression_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_expression_create_with_http_info( + self, + expression_policy_request: ExpressionPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ExpressionPolicy]: + """policies_expression_create + + Source Viewset + + :param expression_policy_request: (required) + :type expression_policy_request: ExpressionPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_create_serialize( + expression_policy_request=expression_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_expression_create_without_preload_content( + self, + expression_policy_request: ExpressionPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_expression_create + + Source Viewset + + :param expression_policy_request: (required) + :type expression_policy_request: ExpressionPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_create_serialize( + expression_policy_request=expression_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_expression_create_serialize( + self, + expression_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if expression_policy_request is not None: + _body_params = expression_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/expression/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_expression_destroy( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_expression_destroy + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_expression_destroy_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_expression_destroy + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_expression_destroy_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_expression_destroy + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_expression_destroy_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/expression/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_expression_list( + self, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + expression: Optional[StrictStr] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedExpressionPolicyList: + """policies_expression_list + + Source Viewset + + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param expression: + :type expression: str + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_list_serialize( + created=created, + execution_logging=execution_logging, + expression=expression, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedExpressionPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_expression_list_with_http_info( + self, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + expression: Optional[StrictStr] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedExpressionPolicyList]: + """policies_expression_list + + Source Viewset + + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param expression: + :type expression: str + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_list_serialize( + created=created, + execution_logging=execution_logging, + expression=expression, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedExpressionPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_expression_list_without_preload_content( + self, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + expression: Optional[StrictStr] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_expression_list + + Source Viewset + + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param expression: + :type expression: str + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_list_serialize( + created=created, + execution_logging=execution_logging, + expression=expression, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedExpressionPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_expression_list_serialize( + self, + created, + execution_logging, + expression, + last_updated, + name, + ordering, + page, + page_size, + policy_uuid, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if created is not None: + if isinstance(created, datetime): + _query_params.append( + ( + 'created', + created.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('created', created)) + + if execution_logging is not None: + + _query_params.append(('execution_logging', execution_logging)) + + if expression is not None: + + _query_params.append(('expression', expression)) + + if last_updated is not None: + if isinstance(last_updated, datetime): + _query_params.append( + ( + 'last_updated', + last_updated.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated', last_updated)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if policy_uuid is not None: + + _query_params.append(('policy_uuid', policy_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/expression/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_expression_partial_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + patched_expression_policy_request: Optional[PatchedExpressionPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ExpressionPolicy: + """policies_expression_partial_update + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param patched_expression_policy_request: + :type patched_expression_policy_request: PatchedExpressionPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_partial_update_serialize( + policy_uuid=policy_uuid, + patched_expression_policy_request=patched_expression_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_expression_partial_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + patched_expression_policy_request: Optional[PatchedExpressionPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ExpressionPolicy]: + """policies_expression_partial_update + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param patched_expression_policy_request: + :type patched_expression_policy_request: PatchedExpressionPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_partial_update_serialize( + policy_uuid=policy_uuid, + patched_expression_policy_request=patched_expression_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_expression_partial_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + patched_expression_policy_request: Optional[PatchedExpressionPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_expression_partial_update + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param patched_expression_policy_request: + :type patched_expression_policy_request: PatchedExpressionPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_partial_update_serialize( + policy_uuid=policy_uuid, + patched_expression_policy_request=patched_expression_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_expression_partial_update_serialize( + self, + policy_uuid, + patched_expression_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_expression_policy_request is not None: + _body_params = patched_expression_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/policies/expression/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_expression_retrieve( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ExpressionPolicy: + """policies_expression_retrieve + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_expression_retrieve_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ExpressionPolicy]: + """policies_expression_retrieve + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_expression_retrieve_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_expression_retrieve + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_expression_retrieve_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/expression/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_expression_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + expression_policy_request: ExpressionPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ExpressionPolicy: + """policies_expression_update + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param expression_policy_request: (required) + :type expression_policy_request: ExpressionPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_update_serialize( + policy_uuid=policy_uuid, + expression_policy_request=expression_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_expression_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + expression_policy_request: ExpressionPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ExpressionPolicy]: + """policies_expression_update + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param expression_policy_request: (required) + :type expression_policy_request: ExpressionPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_update_serialize( + policy_uuid=policy_uuid, + expression_policy_request=expression_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_expression_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + expression_policy_request: ExpressionPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_expression_update + + Source Viewset + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param expression_policy_request: (required) + :type expression_policy_request: ExpressionPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_update_serialize( + policy_uuid=policy_uuid, + expression_policy_request=expression_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ExpressionPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_expression_update_serialize( + self, + policy_uuid, + expression_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if expression_policy_request is not None: + _body_params = expression_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/policies/expression/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_expression_used_by_list( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_expression_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_expression_used_by_list_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_expression_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_expression_used_by_list_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Expression Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_expression_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Expression Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_expression_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_expression_used_by_list_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/expression/{policy_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_geoip_create( + self, + geo_ip_policy_request: GeoIPPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GeoIPPolicy: + """policies_geoip_create + + GeoIP Viewset + + :param geo_ip_policy_request: (required) + :type geo_ip_policy_request: GeoIPPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_create_serialize( + geo_ip_policy_request=geo_ip_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_geoip_create_with_http_info( + self, + geo_ip_policy_request: GeoIPPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GeoIPPolicy]: + """policies_geoip_create + + GeoIP Viewset + + :param geo_ip_policy_request: (required) + :type geo_ip_policy_request: GeoIPPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_create_serialize( + geo_ip_policy_request=geo_ip_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_geoip_create_without_preload_content( + self, + geo_ip_policy_request: GeoIPPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_geoip_create + + GeoIP Viewset + + :param geo_ip_policy_request: (required) + :type geo_ip_policy_request: GeoIPPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_create_serialize( + geo_ip_policy_request=geo_ip_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_geoip_create_serialize( + self, + geo_ip_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if geo_ip_policy_request is not None: + _body_params = geo_ip_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/geoip/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_geoip_destroy( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_geoip_destroy + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_geoip_destroy_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_geoip_destroy + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_geoip_destroy_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_geoip_destroy + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_geoip_destroy_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/geoip/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_geoip_iso3166_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[DetailedCountry]: + """policies_geoip_iso3166_list + + Get all countries in ISO-3166-1 + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_iso3166_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[DetailedCountry]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_geoip_iso3166_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[DetailedCountry]]: + """policies_geoip_iso3166_list + + Get all countries in ISO-3166-1 + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_iso3166_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[DetailedCountry]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_geoip_iso3166_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_geoip_iso3166_list + + Get all countries in ISO-3166-1 + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_iso3166_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[DetailedCountry]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_geoip_iso3166_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/geoip_iso3166/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_geoip_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGeoIPPolicyList: + """policies_geoip_list + + GeoIP Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGeoIPPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_geoip_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGeoIPPolicyList]: + """policies_geoip_list + + GeoIP Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGeoIPPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_geoip_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_geoip_list + + GeoIP Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGeoIPPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_geoip_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/geoip/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_geoip_partial_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + patched_geo_ip_policy_request: Optional[PatchedGeoIPPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GeoIPPolicy: + """policies_geoip_partial_update + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param patched_geo_ip_policy_request: + :type patched_geo_ip_policy_request: PatchedGeoIPPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_partial_update_serialize( + policy_uuid=policy_uuid, + patched_geo_ip_policy_request=patched_geo_ip_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_geoip_partial_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + patched_geo_ip_policy_request: Optional[PatchedGeoIPPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GeoIPPolicy]: + """policies_geoip_partial_update + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param patched_geo_ip_policy_request: + :type patched_geo_ip_policy_request: PatchedGeoIPPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_partial_update_serialize( + policy_uuid=policy_uuid, + patched_geo_ip_policy_request=patched_geo_ip_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_geoip_partial_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + patched_geo_ip_policy_request: Optional[PatchedGeoIPPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_geoip_partial_update + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param patched_geo_ip_policy_request: + :type patched_geo_ip_policy_request: PatchedGeoIPPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_partial_update_serialize( + policy_uuid=policy_uuid, + patched_geo_ip_policy_request=patched_geo_ip_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_geoip_partial_update_serialize( + self, + policy_uuid, + patched_geo_ip_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_geo_ip_policy_request is not None: + _body_params = patched_geo_ip_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/policies/geoip/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_geoip_retrieve( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GeoIPPolicy: + """policies_geoip_retrieve + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_geoip_retrieve_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GeoIPPolicy]: + """policies_geoip_retrieve + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_geoip_retrieve_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_geoip_retrieve + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_geoip_retrieve_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/geoip/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_geoip_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + geo_ip_policy_request: GeoIPPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GeoIPPolicy: + """policies_geoip_update + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param geo_ip_policy_request: (required) + :type geo_ip_policy_request: GeoIPPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_update_serialize( + policy_uuid=policy_uuid, + geo_ip_policy_request=geo_ip_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_geoip_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + geo_ip_policy_request: GeoIPPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GeoIPPolicy]: + """policies_geoip_update + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param geo_ip_policy_request: (required) + :type geo_ip_policy_request: GeoIPPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_update_serialize( + policy_uuid=policy_uuid, + geo_ip_policy_request=geo_ip_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_geoip_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + geo_ip_policy_request: GeoIPPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_geoip_update + + GeoIP Viewset + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param geo_ip_policy_request: (required) + :type geo_ip_policy_request: GeoIPPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_update_serialize( + policy_uuid=policy_uuid, + geo_ip_policy_request=geo_ip_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GeoIPPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_geoip_update_serialize( + self, + policy_uuid, + geo_ip_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if geo_ip_policy_request is not None: + _body_params = geo_ip_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/policies/geoip/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_geoip_used_by_list( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_geoip_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_geoip_used_by_list_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_geoip_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_geoip_used_by_list_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this GeoIP Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_geoip_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this GeoIP Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_geoip_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_geoip_used_by_list_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/geoip/{policy_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_create( + self, + password_policy_request: PasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordPolicy: + """policies_password_create + + Password Policy Viewset + + :param password_policy_request: (required) + :type password_policy_request: PasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_create_serialize( + password_policy_request=password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_create_with_http_info( + self, + password_policy_request: PasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordPolicy]: + """policies_password_create + + Password Policy Viewset + + :param password_policy_request: (required) + :type password_policy_request: PasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_create_serialize( + password_policy_request=password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_create_without_preload_content( + self, + password_policy_request: PasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_create + + Password Policy Viewset + + :param password_policy_request: (required) + :type password_policy_request: PasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_create_serialize( + password_policy_request=password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_create_serialize( + self, + password_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if password_policy_request is not None: + _body_params = password_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/password/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_destroy( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_password_destroy + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_destroy_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_password_destroy + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_destroy_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_destroy + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_destroy_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/password/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_expiry_create( + self, + password_expiry_policy_request: PasswordExpiryPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordExpiryPolicy: + """policies_password_expiry_create + + Password Expiry Viewset + + :param password_expiry_policy_request: (required) + :type password_expiry_policy_request: PasswordExpiryPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_create_serialize( + password_expiry_policy_request=password_expiry_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_expiry_create_with_http_info( + self, + password_expiry_policy_request: PasswordExpiryPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordExpiryPolicy]: + """policies_password_expiry_create + + Password Expiry Viewset + + :param password_expiry_policy_request: (required) + :type password_expiry_policy_request: PasswordExpiryPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_create_serialize( + password_expiry_policy_request=password_expiry_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_expiry_create_without_preload_content( + self, + password_expiry_policy_request: PasswordExpiryPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_expiry_create + + Password Expiry Viewset + + :param password_expiry_policy_request: (required) + :type password_expiry_policy_request: PasswordExpiryPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_create_serialize( + password_expiry_policy_request=password_expiry_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_expiry_create_serialize( + self, + password_expiry_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if password_expiry_policy_request is not None: + _body_params = password_expiry_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/password_expiry/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_expiry_destroy( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_password_expiry_destroy + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_expiry_destroy_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_password_expiry_destroy + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_expiry_destroy_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_expiry_destroy + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_expiry_destroy_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/password_expiry/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_expiry_list( + self, + created: Optional[datetime] = None, + days: Optional[StrictInt] = None, + deny_only: Optional[StrictBool] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPasswordExpiryPolicyList: + """policies_password_expiry_list + + Password Expiry Viewset + + :param created: + :type created: datetime + :param days: + :type days: int + :param deny_only: + :type deny_only: bool + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_list_serialize( + created=created, + days=days, + deny_only=deny_only, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPasswordExpiryPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_expiry_list_with_http_info( + self, + created: Optional[datetime] = None, + days: Optional[StrictInt] = None, + deny_only: Optional[StrictBool] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPasswordExpiryPolicyList]: + """policies_password_expiry_list + + Password Expiry Viewset + + :param created: + :type created: datetime + :param days: + :type days: int + :param deny_only: + :type deny_only: bool + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_list_serialize( + created=created, + days=days, + deny_only=deny_only, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPasswordExpiryPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_expiry_list_without_preload_content( + self, + created: Optional[datetime] = None, + days: Optional[StrictInt] = None, + deny_only: Optional[StrictBool] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_expiry_list + + Password Expiry Viewset + + :param created: + :type created: datetime + :param days: + :type days: int + :param deny_only: + :type deny_only: bool + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_list_serialize( + created=created, + days=days, + deny_only=deny_only, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPasswordExpiryPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_expiry_list_serialize( + self, + created, + days, + deny_only, + execution_logging, + last_updated, + name, + ordering, + page, + page_size, + policy_uuid, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if created is not None: + if isinstance(created, datetime): + _query_params.append( + ( + 'created', + created.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('created', created)) + + if days is not None: + + _query_params.append(('days', days)) + + if deny_only is not None: + + _query_params.append(('deny_only', deny_only)) + + if execution_logging is not None: + + _query_params.append(('execution_logging', execution_logging)) + + if last_updated is not None: + if isinstance(last_updated, datetime): + _query_params.append( + ( + 'last_updated', + last_updated.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated', last_updated)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if policy_uuid is not None: + + _query_params.append(('policy_uuid', policy_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/password_expiry/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_expiry_partial_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + patched_password_expiry_policy_request: Optional[PatchedPasswordExpiryPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordExpiryPolicy: + """policies_password_expiry_partial_update + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param patched_password_expiry_policy_request: + :type patched_password_expiry_policy_request: PatchedPasswordExpiryPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_partial_update_serialize( + policy_uuid=policy_uuid, + patched_password_expiry_policy_request=patched_password_expiry_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_expiry_partial_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + patched_password_expiry_policy_request: Optional[PatchedPasswordExpiryPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordExpiryPolicy]: + """policies_password_expiry_partial_update + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param patched_password_expiry_policy_request: + :type patched_password_expiry_policy_request: PatchedPasswordExpiryPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_partial_update_serialize( + policy_uuid=policy_uuid, + patched_password_expiry_policy_request=patched_password_expiry_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_expiry_partial_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + patched_password_expiry_policy_request: Optional[PatchedPasswordExpiryPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_expiry_partial_update + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param patched_password_expiry_policy_request: + :type patched_password_expiry_policy_request: PatchedPasswordExpiryPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_partial_update_serialize( + policy_uuid=policy_uuid, + patched_password_expiry_policy_request=patched_password_expiry_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_expiry_partial_update_serialize( + self, + policy_uuid, + patched_password_expiry_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_password_expiry_policy_request is not None: + _body_params = patched_password_expiry_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/policies/password_expiry/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_expiry_retrieve( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordExpiryPolicy: + """policies_password_expiry_retrieve + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_expiry_retrieve_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordExpiryPolicy]: + """policies_password_expiry_retrieve + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_expiry_retrieve_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_expiry_retrieve + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_expiry_retrieve_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/password_expiry/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_expiry_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + password_expiry_policy_request: PasswordExpiryPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordExpiryPolicy: + """policies_password_expiry_update + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param password_expiry_policy_request: (required) + :type password_expiry_policy_request: PasswordExpiryPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_update_serialize( + policy_uuid=policy_uuid, + password_expiry_policy_request=password_expiry_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_expiry_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + password_expiry_policy_request: PasswordExpiryPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordExpiryPolicy]: + """policies_password_expiry_update + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param password_expiry_policy_request: (required) + :type password_expiry_policy_request: PasswordExpiryPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_update_serialize( + policy_uuid=policy_uuid, + password_expiry_policy_request=password_expiry_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_expiry_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + password_expiry_policy_request: PasswordExpiryPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_expiry_update + + Password Expiry Viewset + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param password_expiry_policy_request: (required) + :type password_expiry_policy_request: PasswordExpiryPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_update_serialize( + policy_uuid=policy_uuid, + password_expiry_policy_request=password_expiry_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordExpiryPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_expiry_update_serialize( + self, + policy_uuid, + password_expiry_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if password_expiry_policy_request is not None: + _body_params = password_expiry_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/policies/password_expiry/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_expiry_used_by_list( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_password_expiry_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_expiry_used_by_list_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_password_expiry_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_expiry_used_by_list_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Expiry Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_expiry_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Password Expiry Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_expiry_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_expiry_used_by_list_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/password_expiry/{policy_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_list( + self, + amount_digits: Optional[StrictInt] = None, + amount_lowercase: Optional[StrictInt] = None, + amount_symbols: Optional[StrictInt] = None, + amount_uppercase: Optional[StrictInt] = None, + check_have_i_been_pwned: Optional[StrictBool] = None, + check_static_rules: Optional[StrictBool] = None, + check_zxcvbn: Optional[StrictBool] = None, + created: Optional[datetime] = None, + error_message: Optional[StrictStr] = None, + execution_logging: Optional[StrictBool] = None, + hibp_allowed_count: Optional[StrictInt] = None, + last_updated: Optional[datetime] = None, + length_min: Optional[StrictInt] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_field: Optional[StrictStr] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + symbol_charset: Optional[StrictStr] = None, + zxcvbn_score_threshold: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPasswordPolicyList: + """policies_password_list + + Password Policy Viewset + + :param amount_digits: + :type amount_digits: int + :param amount_lowercase: + :type amount_lowercase: int + :param amount_symbols: + :type amount_symbols: int + :param amount_uppercase: + :type amount_uppercase: int + :param check_have_i_been_pwned: + :type check_have_i_been_pwned: bool + :param check_static_rules: + :type check_static_rules: bool + :param check_zxcvbn: + :type check_zxcvbn: bool + :param created: + :type created: datetime + :param error_message: + :type error_message: str + :param execution_logging: + :type execution_logging: bool + :param hibp_allowed_count: + :type hibp_allowed_count: int + :param last_updated: + :type last_updated: datetime + :param length_min: + :type length_min: int + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_field: + :type password_field: str + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param symbol_charset: + :type symbol_charset: str + :param zxcvbn_score_threshold: + :type zxcvbn_score_threshold: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_list_serialize( + amount_digits=amount_digits, + amount_lowercase=amount_lowercase, + amount_symbols=amount_symbols, + amount_uppercase=amount_uppercase, + check_have_i_been_pwned=check_have_i_been_pwned, + check_static_rules=check_static_rules, + check_zxcvbn=check_zxcvbn, + created=created, + error_message=error_message, + execution_logging=execution_logging, + hibp_allowed_count=hibp_allowed_count, + last_updated=last_updated, + length_min=length_min, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password_field=password_field, + policy_uuid=policy_uuid, + search=search, + symbol_charset=symbol_charset, + zxcvbn_score_threshold=zxcvbn_score_threshold, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPasswordPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_list_with_http_info( + self, + amount_digits: Optional[StrictInt] = None, + amount_lowercase: Optional[StrictInt] = None, + amount_symbols: Optional[StrictInt] = None, + amount_uppercase: Optional[StrictInt] = None, + check_have_i_been_pwned: Optional[StrictBool] = None, + check_static_rules: Optional[StrictBool] = None, + check_zxcvbn: Optional[StrictBool] = None, + created: Optional[datetime] = None, + error_message: Optional[StrictStr] = None, + execution_logging: Optional[StrictBool] = None, + hibp_allowed_count: Optional[StrictInt] = None, + last_updated: Optional[datetime] = None, + length_min: Optional[StrictInt] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_field: Optional[StrictStr] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + symbol_charset: Optional[StrictStr] = None, + zxcvbn_score_threshold: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPasswordPolicyList]: + """policies_password_list + + Password Policy Viewset + + :param amount_digits: + :type amount_digits: int + :param amount_lowercase: + :type amount_lowercase: int + :param amount_symbols: + :type amount_symbols: int + :param amount_uppercase: + :type amount_uppercase: int + :param check_have_i_been_pwned: + :type check_have_i_been_pwned: bool + :param check_static_rules: + :type check_static_rules: bool + :param check_zxcvbn: + :type check_zxcvbn: bool + :param created: + :type created: datetime + :param error_message: + :type error_message: str + :param execution_logging: + :type execution_logging: bool + :param hibp_allowed_count: + :type hibp_allowed_count: int + :param last_updated: + :type last_updated: datetime + :param length_min: + :type length_min: int + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_field: + :type password_field: str + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param symbol_charset: + :type symbol_charset: str + :param zxcvbn_score_threshold: + :type zxcvbn_score_threshold: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_list_serialize( + amount_digits=amount_digits, + amount_lowercase=amount_lowercase, + amount_symbols=amount_symbols, + amount_uppercase=amount_uppercase, + check_have_i_been_pwned=check_have_i_been_pwned, + check_static_rules=check_static_rules, + check_zxcvbn=check_zxcvbn, + created=created, + error_message=error_message, + execution_logging=execution_logging, + hibp_allowed_count=hibp_allowed_count, + last_updated=last_updated, + length_min=length_min, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password_field=password_field, + policy_uuid=policy_uuid, + search=search, + symbol_charset=symbol_charset, + zxcvbn_score_threshold=zxcvbn_score_threshold, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPasswordPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_list_without_preload_content( + self, + amount_digits: Optional[StrictInt] = None, + amount_lowercase: Optional[StrictInt] = None, + amount_symbols: Optional[StrictInt] = None, + amount_uppercase: Optional[StrictInt] = None, + check_have_i_been_pwned: Optional[StrictBool] = None, + check_static_rules: Optional[StrictBool] = None, + check_zxcvbn: Optional[StrictBool] = None, + created: Optional[datetime] = None, + error_message: Optional[StrictStr] = None, + execution_logging: Optional[StrictBool] = None, + hibp_allowed_count: Optional[StrictInt] = None, + last_updated: Optional[datetime] = None, + length_min: Optional[StrictInt] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_field: Optional[StrictStr] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + symbol_charset: Optional[StrictStr] = None, + zxcvbn_score_threshold: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_list + + Password Policy Viewset + + :param amount_digits: + :type amount_digits: int + :param amount_lowercase: + :type amount_lowercase: int + :param amount_symbols: + :type amount_symbols: int + :param amount_uppercase: + :type amount_uppercase: int + :param check_have_i_been_pwned: + :type check_have_i_been_pwned: bool + :param check_static_rules: + :type check_static_rules: bool + :param check_zxcvbn: + :type check_zxcvbn: bool + :param created: + :type created: datetime + :param error_message: + :type error_message: str + :param execution_logging: + :type execution_logging: bool + :param hibp_allowed_count: + :type hibp_allowed_count: int + :param last_updated: + :type last_updated: datetime + :param length_min: + :type length_min: int + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_field: + :type password_field: str + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param symbol_charset: + :type symbol_charset: str + :param zxcvbn_score_threshold: + :type zxcvbn_score_threshold: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_list_serialize( + amount_digits=amount_digits, + amount_lowercase=amount_lowercase, + amount_symbols=amount_symbols, + amount_uppercase=amount_uppercase, + check_have_i_been_pwned=check_have_i_been_pwned, + check_static_rules=check_static_rules, + check_zxcvbn=check_zxcvbn, + created=created, + error_message=error_message, + execution_logging=execution_logging, + hibp_allowed_count=hibp_allowed_count, + last_updated=last_updated, + length_min=length_min, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password_field=password_field, + policy_uuid=policy_uuid, + search=search, + symbol_charset=symbol_charset, + zxcvbn_score_threshold=zxcvbn_score_threshold, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPasswordPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_list_serialize( + self, + amount_digits, + amount_lowercase, + amount_symbols, + amount_uppercase, + check_have_i_been_pwned, + check_static_rules, + check_zxcvbn, + created, + error_message, + execution_logging, + hibp_allowed_count, + last_updated, + length_min, + name, + ordering, + page, + page_size, + password_field, + policy_uuid, + search, + symbol_charset, + zxcvbn_score_threshold, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if amount_digits is not None: + + _query_params.append(('amount_digits', amount_digits)) + + if amount_lowercase is not None: + + _query_params.append(('amount_lowercase', amount_lowercase)) + + if amount_symbols is not None: + + _query_params.append(('amount_symbols', amount_symbols)) + + if amount_uppercase is not None: + + _query_params.append(('amount_uppercase', amount_uppercase)) + + if check_have_i_been_pwned is not None: + + _query_params.append(('check_have_i_been_pwned', check_have_i_been_pwned)) + + if check_static_rules is not None: + + _query_params.append(('check_static_rules', check_static_rules)) + + if check_zxcvbn is not None: + + _query_params.append(('check_zxcvbn', check_zxcvbn)) + + if created is not None: + if isinstance(created, datetime): + _query_params.append( + ( + 'created', + created.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('created', created)) + + if error_message is not None: + + _query_params.append(('error_message', error_message)) + + if execution_logging is not None: + + _query_params.append(('execution_logging', execution_logging)) + + if hibp_allowed_count is not None: + + _query_params.append(('hibp_allowed_count', hibp_allowed_count)) + + if last_updated is not None: + if isinstance(last_updated, datetime): + _query_params.append( + ( + 'last_updated', + last_updated.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated', last_updated)) + + if length_min is not None: + + _query_params.append(('length_min', length_min)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if password_field is not None: + + _query_params.append(('password_field', password_field)) + + if policy_uuid is not None: + + _query_params.append(('policy_uuid', policy_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + if symbol_charset is not None: + + _query_params.append(('symbol_charset', symbol_charset)) + + if zxcvbn_score_threshold is not None: + + _query_params.append(('zxcvbn_score_threshold', zxcvbn_score_threshold)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/password/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_partial_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + patched_password_policy_request: Optional[PatchedPasswordPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordPolicy: + """policies_password_partial_update + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param patched_password_policy_request: + :type patched_password_policy_request: PatchedPasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_partial_update_serialize( + policy_uuid=policy_uuid, + patched_password_policy_request=patched_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_partial_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + patched_password_policy_request: Optional[PatchedPasswordPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordPolicy]: + """policies_password_partial_update + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param patched_password_policy_request: + :type patched_password_policy_request: PatchedPasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_partial_update_serialize( + policy_uuid=policy_uuid, + patched_password_policy_request=patched_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_partial_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + patched_password_policy_request: Optional[PatchedPasswordPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_partial_update + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param patched_password_policy_request: + :type patched_password_policy_request: PatchedPasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_partial_update_serialize( + policy_uuid=policy_uuid, + patched_password_policy_request=patched_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_partial_update_serialize( + self, + policy_uuid, + patched_password_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_password_policy_request is not None: + _body_params = patched_password_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/policies/password/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_retrieve( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordPolicy: + """policies_password_retrieve + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_retrieve_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordPolicy]: + """policies_password_retrieve + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_retrieve_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_retrieve + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_retrieve_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/password/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + password_policy_request: PasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordPolicy: + """policies_password_update + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param password_policy_request: (required) + :type password_policy_request: PasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_update_serialize( + policy_uuid=policy_uuid, + password_policy_request=password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + password_policy_request: PasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordPolicy]: + """policies_password_update + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param password_policy_request: (required) + :type password_policy_request: PasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_update_serialize( + policy_uuid=policy_uuid, + password_policy_request=password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + password_policy_request: PasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_update + + Password Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param password_policy_request: (required) + :type password_policy_request: PasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_update_serialize( + policy_uuid=policy_uuid, + password_policy_request=password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_update_serialize( + self, + policy_uuid, + password_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if password_policy_request is not None: + _body_params = password_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/policies/password/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_password_used_by_list( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_password_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_password_used_by_list_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_password_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_password_used_by_list_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_password_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Password Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_password_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_password_used_by_list_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/password/{policy_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_create( + self, + reputation_policy_request: ReputationPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ReputationPolicy: + """policies_reputation_create + + Reputation Policy Viewset + + :param reputation_policy_request: (required) + :type reputation_policy_request: ReputationPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_create_serialize( + reputation_policy_request=reputation_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_create_with_http_info( + self, + reputation_policy_request: ReputationPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ReputationPolicy]: + """policies_reputation_create + + Reputation Policy Viewset + + :param reputation_policy_request: (required) + :type reputation_policy_request: ReputationPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_create_serialize( + reputation_policy_request=reputation_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_create_without_preload_content( + self, + reputation_policy_request: ReputationPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_create + + Reputation Policy Viewset + + :param reputation_policy_request: (required) + :type reputation_policy_request: ReputationPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_create_serialize( + reputation_policy_request=reputation_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_create_serialize( + self, + reputation_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if reputation_policy_request is not None: + _body_params = reputation_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/reputation/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_destroy( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_reputation_destroy + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_destroy_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_reputation_destroy + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_destroy_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_destroy + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_destroy_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/reputation/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_list( + self, + check_ip: Optional[StrictBool] = None, + check_username: Optional[StrictBool] = None, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + threshold: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedReputationPolicyList: + """policies_reputation_list + + Reputation Policy Viewset + + :param check_ip: + :type check_ip: bool + :param check_username: + :type check_username: bool + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param threshold: + :type threshold: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_list_serialize( + check_ip=check_ip, + check_username=check_username, + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + search=search, + threshold=threshold, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedReputationPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_list_with_http_info( + self, + check_ip: Optional[StrictBool] = None, + check_username: Optional[StrictBool] = None, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + threshold: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedReputationPolicyList]: + """policies_reputation_list + + Reputation Policy Viewset + + :param check_ip: + :type check_ip: bool + :param check_username: + :type check_username: bool + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param threshold: + :type threshold: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_list_serialize( + check_ip=check_ip, + check_username=check_username, + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + search=search, + threshold=threshold, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedReputationPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_list_without_preload_content( + self, + check_ip: Optional[StrictBool] = None, + check_username: Optional[StrictBool] = None, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + threshold: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_list + + Reputation Policy Viewset + + :param check_ip: + :type check_ip: bool + :param check_username: + :type check_username: bool + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param threshold: + :type threshold: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_list_serialize( + check_ip=check_ip, + check_username=check_username, + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + policy_uuid=policy_uuid, + search=search, + threshold=threshold, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedReputationPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_list_serialize( + self, + check_ip, + check_username, + created, + execution_logging, + last_updated, + name, + ordering, + page, + page_size, + policy_uuid, + search, + threshold, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if check_ip is not None: + + _query_params.append(('check_ip', check_ip)) + + if check_username is not None: + + _query_params.append(('check_username', check_username)) + + if created is not None: + if isinstance(created, datetime): + _query_params.append( + ( + 'created', + created.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('created', created)) + + if execution_logging is not None: + + _query_params.append(('execution_logging', execution_logging)) + + if last_updated is not None: + if isinstance(last_updated, datetime): + _query_params.append( + ( + 'last_updated', + last_updated.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated', last_updated)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if policy_uuid is not None: + + _query_params.append(('policy_uuid', policy_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + if threshold is not None: + + _query_params.append(('threshold', threshold)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/reputation/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_partial_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + patched_reputation_policy_request: Optional[PatchedReputationPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ReputationPolicy: + """policies_reputation_partial_update + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param patched_reputation_policy_request: + :type patched_reputation_policy_request: PatchedReputationPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_partial_update_serialize( + policy_uuid=policy_uuid, + patched_reputation_policy_request=patched_reputation_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_partial_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + patched_reputation_policy_request: Optional[PatchedReputationPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ReputationPolicy]: + """policies_reputation_partial_update + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param patched_reputation_policy_request: + :type patched_reputation_policy_request: PatchedReputationPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_partial_update_serialize( + policy_uuid=policy_uuid, + patched_reputation_policy_request=patched_reputation_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_partial_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + patched_reputation_policy_request: Optional[PatchedReputationPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_partial_update + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param patched_reputation_policy_request: + :type patched_reputation_policy_request: PatchedReputationPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_partial_update_serialize( + policy_uuid=policy_uuid, + patched_reputation_policy_request=patched_reputation_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_partial_update_serialize( + self, + policy_uuid, + patched_reputation_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_reputation_policy_request is not None: + _body_params = patched_reputation_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/policies/reputation/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_retrieve( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ReputationPolicy: + """policies_reputation_retrieve + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_retrieve_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ReputationPolicy]: + """policies_reputation_retrieve + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_retrieve_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_retrieve + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_retrieve_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/reputation/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_scores_destroy( + self, + reputation_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Score.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_reputation_scores_destroy + + Reputation Viewset + + :param reputation_uuid: A UUID string identifying this Reputation Score. (required) + :type reputation_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_destroy_serialize( + reputation_uuid=reputation_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_scores_destroy_with_http_info( + self, + reputation_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Score.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_reputation_scores_destroy + + Reputation Viewset + + :param reputation_uuid: A UUID string identifying this Reputation Score. (required) + :type reputation_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_destroy_serialize( + reputation_uuid=reputation_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_scores_destroy_without_preload_content( + self, + reputation_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Score.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_scores_destroy + + Reputation Viewset + + :param reputation_uuid: A UUID string identifying this Reputation Score. (required) + :type reputation_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_destroy_serialize( + reputation_uuid=reputation_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_scores_destroy_serialize( + self, + reputation_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if reputation_uuid is not None: + _path_params['reputation_uuid'] = reputation_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/reputation/scores/{reputation_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_scores_list( + self, + identifier: Optional[StrictStr] = None, + identifier_in: Annotated[Optional[List[StrictStr]], Field(description="Multiple values may be separated by commas.")] = None, + ip: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + score: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedReputationList: + """policies_reputation_scores_list + + Reputation Viewset + + :param identifier: + :type identifier: str + :param identifier_in: Multiple values may be separated by commas. + :type identifier_in: List[str] + :param ip: + :type ip: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param score: + :type score: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_list_serialize( + identifier=identifier, + identifier_in=identifier_in, + ip=ip, + ordering=ordering, + page=page, + page_size=page_size, + score=score, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedReputationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_scores_list_with_http_info( + self, + identifier: Optional[StrictStr] = None, + identifier_in: Annotated[Optional[List[StrictStr]], Field(description="Multiple values may be separated by commas.")] = None, + ip: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + score: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedReputationList]: + """policies_reputation_scores_list + + Reputation Viewset + + :param identifier: + :type identifier: str + :param identifier_in: Multiple values may be separated by commas. + :type identifier_in: List[str] + :param ip: + :type ip: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param score: + :type score: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_list_serialize( + identifier=identifier, + identifier_in=identifier_in, + ip=ip, + ordering=ordering, + page=page, + page_size=page_size, + score=score, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedReputationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_scores_list_without_preload_content( + self, + identifier: Optional[StrictStr] = None, + identifier_in: Annotated[Optional[List[StrictStr]], Field(description="Multiple values may be separated by commas.")] = None, + ip: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + score: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_scores_list + + Reputation Viewset + + :param identifier: + :type identifier: str + :param identifier_in: Multiple values may be separated by commas. + :type identifier_in: List[str] + :param ip: + :type ip: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param score: + :type score: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_list_serialize( + identifier=identifier, + identifier_in=identifier_in, + ip=ip, + ordering=ordering, + page=page, + page_size=page_size, + score=score, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedReputationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_scores_list_serialize( + self, + identifier, + identifier_in, + ip, + ordering, + page, + page_size, + score, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'identifier_in': 'csv', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if identifier is not None: + + _query_params.append(('identifier', identifier)) + + if identifier_in is not None: + + _query_params.append(('identifier_in', identifier_in)) + + if ip is not None: + + _query_params.append(('ip', ip)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if score is not None: + + _query_params.append(('score', score)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/reputation/scores/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_scores_retrieve( + self, + reputation_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Score.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Reputation: + """policies_reputation_scores_retrieve + + Reputation Viewset + + :param reputation_uuid: A UUID string identifying this Reputation Score. (required) + :type reputation_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_retrieve_serialize( + reputation_uuid=reputation_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Reputation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_scores_retrieve_with_http_info( + self, + reputation_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Score.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Reputation]: + """policies_reputation_scores_retrieve + + Reputation Viewset + + :param reputation_uuid: A UUID string identifying this Reputation Score. (required) + :type reputation_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_retrieve_serialize( + reputation_uuid=reputation_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Reputation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_scores_retrieve_without_preload_content( + self, + reputation_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Score.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_scores_retrieve + + Reputation Viewset + + :param reputation_uuid: A UUID string identifying this Reputation Score. (required) + :type reputation_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_retrieve_serialize( + reputation_uuid=reputation_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Reputation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_scores_retrieve_serialize( + self, + reputation_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if reputation_uuid is not None: + _path_params['reputation_uuid'] = reputation_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/reputation/scores/{reputation_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_scores_used_by_list( + self, + reputation_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Score.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_reputation_scores_used_by_list + + Get a list of all objects that use this object + + :param reputation_uuid: A UUID string identifying this Reputation Score. (required) + :type reputation_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_used_by_list_serialize( + reputation_uuid=reputation_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_scores_used_by_list_with_http_info( + self, + reputation_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Score.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_reputation_scores_used_by_list + + Get a list of all objects that use this object + + :param reputation_uuid: A UUID string identifying this Reputation Score. (required) + :type reputation_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_used_by_list_serialize( + reputation_uuid=reputation_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_scores_used_by_list_without_preload_content( + self, + reputation_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Score.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_scores_used_by_list + + Get a list of all objects that use this object + + :param reputation_uuid: A UUID string identifying this Reputation Score. (required) + :type reputation_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_scores_used_by_list_serialize( + reputation_uuid=reputation_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_scores_used_by_list_serialize( + self, + reputation_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if reputation_uuid is not None: + _path_params['reputation_uuid'] = reputation_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/reputation/scores/{reputation_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + reputation_policy_request: ReputationPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ReputationPolicy: + """policies_reputation_update + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param reputation_policy_request: (required) + :type reputation_policy_request: ReputationPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_update_serialize( + policy_uuid=policy_uuid, + reputation_policy_request=reputation_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + reputation_policy_request: ReputationPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ReputationPolicy]: + """policies_reputation_update + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param reputation_policy_request: (required) + :type reputation_policy_request: ReputationPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_update_serialize( + policy_uuid=policy_uuid, + reputation_policy_request=reputation_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + reputation_policy_request: ReputationPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_update + + Reputation Policy Viewset + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param reputation_policy_request: (required) + :type reputation_policy_request: ReputationPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_update_serialize( + policy_uuid=policy_uuid, + reputation_policy_request=reputation_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ReputationPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_update_serialize( + self, + policy_uuid, + reputation_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if reputation_policy_request is not None: + _body_params = reputation_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/policies/reputation/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_reputation_used_by_list( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_reputation_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_reputation_used_by_list_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_reputation_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_reputation_used_by_list_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Reputation Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_reputation_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Reputation Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_reputation_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_reputation_used_by_list_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/reputation/{policy_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_unique_password_create( + self, + unique_password_policy_request: UniquePasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UniquePasswordPolicy: + """policies_unique_password_create + + Password Uniqueness Policy Viewset + + :param unique_password_policy_request: (required) + :type unique_password_policy_request: UniquePasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_create_serialize( + unique_password_policy_request=unique_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_unique_password_create_with_http_info( + self, + unique_password_policy_request: UniquePasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UniquePasswordPolicy]: + """policies_unique_password_create + + Password Uniqueness Policy Viewset + + :param unique_password_policy_request: (required) + :type unique_password_policy_request: UniquePasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_create_serialize( + unique_password_policy_request=unique_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_unique_password_create_without_preload_content( + self, + unique_password_policy_request: UniquePasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_unique_password_create + + Password Uniqueness Policy Viewset + + :param unique_password_policy_request: (required) + :type unique_password_policy_request: UniquePasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_create_serialize( + unique_password_policy_request=unique_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_unique_password_create_serialize( + self, + unique_password_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if unique_password_policy_request is not None: + _body_params = unique_password_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/policies/unique_password/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_unique_password_destroy( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """policies_unique_password_destroy + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_unique_password_destroy_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """policies_unique_password_destroy + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_unique_password_destroy_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_unique_password_destroy + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_destroy_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_unique_password_destroy_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/policies/unique_password/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_unique_password_list( + self, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + num_historical_passwords: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_field: Optional[StrictStr] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUniquePasswordPolicyList: + """policies_unique_password_list + + Password Uniqueness Policy Viewset + + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param num_historical_passwords: + :type num_historical_passwords: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_field: + :type password_field: str + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_list_serialize( + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + num_historical_passwords=num_historical_passwords, + ordering=ordering, + page=page, + page_size=page_size, + password_field=password_field, + policy_uuid=policy_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUniquePasswordPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_unique_password_list_with_http_info( + self, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + num_historical_passwords: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_field: Optional[StrictStr] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUniquePasswordPolicyList]: + """policies_unique_password_list + + Password Uniqueness Policy Viewset + + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param num_historical_passwords: + :type num_historical_passwords: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_field: + :type password_field: str + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_list_serialize( + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + num_historical_passwords=num_historical_passwords, + ordering=ordering, + page=page, + page_size=page_size, + password_field=password_field, + policy_uuid=policy_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUniquePasswordPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_unique_password_list_without_preload_content( + self, + created: Optional[datetime] = None, + execution_logging: Optional[StrictBool] = None, + last_updated: Optional[datetime] = None, + name: Optional[StrictStr] = None, + num_historical_passwords: Optional[StrictInt] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_field: Optional[StrictStr] = None, + policy_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_unique_password_list + + Password Uniqueness Policy Viewset + + :param created: + :type created: datetime + :param execution_logging: + :type execution_logging: bool + :param last_updated: + :type last_updated: datetime + :param name: + :type name: str + :param num_historical_passwords: + :type num_historical_passwords: int + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_field: + :type password_field: str + :param policy_uuid: + :type policy_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_list_serialize( + created=created, + execution_logging=execution_logging, + last_updated=last_updated, + name=name, + num_historical_passwords=num_historical_passwords, + ordering=ordering, + page=page, + page_size=page_size, + password_field=password_field, + policy_uuid=policy_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUniquePasswordPolicyList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_unique_password_list_serialize( + self, + created, + execution_logging, + last_updated, + name, + num_historical_passwords, + ordering, + page, + page_size, + password_field, + policy_uuid, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if created is not None: + if isinstance(created, datetime): + _query_params.append( + ( + 'created', + created.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('created', created)) + + if execution_logging is not None: + + _query_params.append(('execution_logging', execution_logging)) + + if last_updated is not None: + if isinstance(last_updated, datetime): + _query_params.append( + ( + 'last_updated', + last_updated.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('last_updated', last_updated)) + + if name is not None: + + _query_params.append(('name', name)) + + if num_historical_passwords is not None: + + _query_params.append(('num_historical_passwords', num_historical_passwords)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if password_field is not None: + + _query_params.append(('password_field', password_field)) + + if policy_uuid is not None: + + _query_params.append(('policy_uuid', policy_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/unique_password/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_unique_password_partial_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + patched_unique_password_policy_request: Optional[PatchedUniquePasswordPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UniquePasswordPolicy: + """policies_unique_password_partial_update + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param patched_unique_password_policy_request: + :type patched_unique_password_policy_request: PatchedUniquePasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_partial_update_serialize( + policy_uuid=policy_uuid, + patched_unique_password_policy_request=patched_unique_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_unique_password_partial_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + patched_unique_password_policy_request: Optional[PatchedUniquePasswordPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UniquePasswordPolicy]: + """policies_unique_password_partial_update + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param patched_unique_password_policy_request: + :type patched_unique_password_policy_request: PatchedUniquePasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_partial_update_serialize( + policy_uuid=policy_uuid, + patched_unique_password_policy_request=patched_unique_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_unique_password_partial_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + patched_unique_password_policy_request: Optional[PatchedUniquePasswordPolicyRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_unique_password_partial_update + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param patched_unique_password_policy_request: + :type patched_unique_password_policy_request: PatchedUniquePasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_partial_update_serialize( + policy_uuid=policy_uuid, + patched_unique_password_policy_request=patched_unique_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_unique_password_partial_update_serialize( + self, + policy_uuid, + patched_unique_password_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_unique_password_policy_request is not None: + _body_params = patched_unique_password_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/policies/unique_password/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_unique_password_retrieve( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UniquePasswordPolicy: + """policies_unique_password_retrieve + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_unique_password_retrieve_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UniquePasswordPolicy]: + """policies_unique_password_retrieve + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_unique_password_retrieve_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_unique_password_retrieve + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_retrieve_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_unique_password_retrieve_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/unique_password/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_unique_password_update( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + unique_password_policy_request: UniquePasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UniquePasswordPolicy: + """policies_unique_password_update + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param unique_password_policy_request: (required) + :type unique_password_policy_request: UniquePasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_update_serialize( + policy_uuid=policy_uuid, + unique_password_policy_request=unique_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_unique_password_update_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + unique_password_policy_request: UniquePasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UniquePasswordPolicy]: + """policies_unique_password_update + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param unique_password_policy_request: (required) + :type unique_password_policy_request: UniquePasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_update_serialize( + policy_uuid=policy_uuid, + unique_password_policy_request=unique_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_unique_password_update_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + unique_password_policy_request: UniquePasswordPolicyRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_unique_password_update + + Password Uniqueness Policy Viewset + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param unique_password_policy_request: (required) + :type unique_password_policy_request: UniquePasswordPolicyRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_update_serialize( + policy_uuid=policy_uuid, + unique_password_policy_request=unique_password_policy_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UniquePasswordPolicy", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_unique_password_update_serialize( + self, + policy_uuid, + unique_password_policy_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if unique_password_policy_request is not None: + _body_params = unique_password_policy_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/policies/unique_password/{policy_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def policies_unique_password_used_by_list( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """policies_unique_password_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def policies_unique_password_used_by_list_with_http_info( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """policies_unique_password_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def policies_unique_password_used_by_list_without_preload_content( + self, + policy_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Uniqueness Policy.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """policies_unique_password_used_by_list + + Get a list of all objects that use this object + + :param policy_uuid: A UUID string identifying this Password Uniqueness Policy. (required) + :type policy_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._policies_unique_password_used_by_list_serialize( + policy_uuid=policy_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _policies_unique_password_used_by_list_serialize( + self, + policy_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if policy_uuid is not None: + _path_params['policy_uuid'] = policy_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/policies/unique_password/{policy_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/propertymappings_api.py b/authentik_client/api/propertymappings_api.py new file mode 100644 index 000000000..eaaad48b3 --- /dev/null +++ b/authentik_client/api/propertymappings_api.py @@ -0,0 +1,32520 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping +from authentik_client.models.google_workspace_provider_mapping_request import GoogleWorkspaceProviderMappingRequest +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping +from authentik_client.models.kerberos_source_property_mapping_request import KerberosSourcePropertyMappingRequest +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping +from authentik_client.models.ldap_source_property_mapping_request import LDAPSourcePropertyMappingRequest +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping +from authentik_client.models.microsoft_entra_provider_mapping_request import MicrosoftEntraProviderMappingRequest +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping +from authentik_client.models.notification_webhook_mapping_request import NotificationWebhookMappingRequest +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping +from authentik_client.models.o_auth_source_property_mapping_request import OAuthSourcePropertyMappingRequest +from authentik_client.models.paginated_google_workspace_provider_mapping_list import PaginatedGoogleWorkspaceProviderMappingList +from authentik_client.models.paginated_kerberos_source_property_mapping_list import PaginatedKerberosSourcePropertyMappingList +from authentik_client.models.paginated_ldap_source_property_mapping_list import PaginatedLDAPSourcePropertyMappingList +from authentik_client.models.paginated_microsoft_entra_provider_mapping_list import PaginatedMicrosoftEntraProviderMappingList +from authentik_client.models.paginated_notification_webhook_mapping_list import PaginatedNotificationWebhookMappingList +from authentik_client.models.paginated_o_auth_source_property_mapping_list import PaginatedOAuthSourcePropertyMappingList +from authentik_client.models.paginated_plex_source_property_mapping_list import PaginatedPlexSourcePropertyMappingList +from authentik_client.models.paginated_property_mapping_list import PaginatedPropertyMappingList +from authentik_client.models.paginated_rac_property_mapping_list import PaginatedRACPropertyMappingList +from authentik_client.models.paginated_radius_provider_property_mapping_list import PaginatedRadiusProviderPropertyMappingList +from authentik_client.models.paginated_saml_property_mapping_list import PaginatedSAMLPropertyMappingList +from authentik_client.models.paginated_saml_source_property_mapping_list import PaginatedSAMLSourcePropertyMappingList +from authentik_client.models.paginated_scim_mapping_list import PaginatedSCIMMappingList +from authentik_client.models.paginated_scim_source_property_mapping_list import PaginatedSCIMSourcePropertyMappingList +from authentik_client.models.paginated_scope_mapping_list import PaginatedScopeMappingList +from authentik_client.models.paginated_telegram_source_property_mapping_list import PaginatedTelegramSourcePropertyMappingList +from authentik_client.models.patched_google_workspace_provider_mapping_request import PatchedGoogleWorkspaceProviderMappingRequest +from authentik_client.models.patched_kerberos_source_property_mapping_request import PatchedKerberosSourcePropertyMappingRequest +from authentik_client.models.patched_ldap_source_property_mapping_request import PatchedLDAPSourcePropertyMappingRequest +from authentik_client.models.patched_microsoft_entra_provider_mapping_request import PatchedMicrosoftEntraProviderMappingRequest +from authentik_client.models.patched_notification_webhook_mapping_request import PatchedNotificationWebhookMappingRequest +from authentik_client.models.patched_o_auth_source_property_mapping_request import PatchedOAuthSourcePropertyMappingRequest +from authentik_client.models.patched_plex_source_property_mapping_request import PatchedPlexSourcePropertyMappingRequest +from authentik_client.models.patched_rac_property_mapping_request import PatchedRACPropertyMappingRequest +from authentik_client.models.patched_radius_provider_property_mapping_request import PatchedRadiusProviderPropertyMappingRequest +from authentik_client.models.patched_saml_property_mapping_request import PatchedSAMLPropertyMappingRequest +from authentik_client.models.patched_saml_source_property_mapping_request import PatchedSAMLSourcePropertyMappingRequest +from authentik_client.models.patched_scim_mapping_request import PatchedSCIMMappingRequest +from authentik_client.models.patched_scim_source_property_mapping_request import PatchedSCIMSourcePropertyMappingRequest +from authentik_client.models.patched_scope_mapping_request import PatchedScopeMappingRequest +from authentik_client.models.patched_telegram_source_property_mapping_request import PatchedTelegramSourcePropertyMappingRequest +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping +from authentik_client.models.plex_source_property_mapping_request import PlexSourcePropertyMappingRequest +from authentik_client.models.property_mapping import PropertyMapping +from authentik_client.models.property_mapping_test_request import PropertyMappingTestRequest +from authentik_client.models.property_mapping_test_result import PropertyMappingTestResult +from authentik_client.models.rac_property_mapping import RACPropertyMapping +from authentik_client.models.rac_property_mapping_request import RACPropertyMappingRequest +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping +from authentik_client.models.radius_provider_property_mapping_request import RadiusProviderPropertyMappingRequest +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping +from authentik_client.models.saml_property_mapping_request import SAMLPropertyMappingRequest +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping +from authentik_client.models.saml_source_property_mapping_request import SAMLSourcePropertyMappingRequest +from authentik_client.models.scim_mapping import SCIMMapping +from authentik_client.models.scim_mapping_request import SCIMMappingRequest +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping +from authentik_client.models.scim_source_property_mapping_request import SCIMSourcePropertyMappingRequest +from authentik_client.models.scope_mapping import ScopeMapping +from authentik_client.models.scope_mapping_request import ScopeMappingRequest +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping +from authentik_client.models.telegram_source_property_mapping_request import TelegramSourcePropertyMappingRequest +from authentik_client.models.type_create import TypeCreate +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class PropertymappingsApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def propertymappings_all_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_all_destroy + + PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_all_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_all_destroy + + PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_all_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_all_destroy + + PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_all_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/all/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_all_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPropertyMappingList: + """propertymappings_all_list + + PropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_all_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPropertyMappingList]: + """propertymappings_all_list + + PropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_all_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_all_list + + PropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_all_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_all_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PropertyMapping: + """propertymappings_all_retrieve + + PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_all_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PropertyMapping]: + """propertymappings_all_retrieve + + PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_all_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_all_retrieve + + PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_all_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/all/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_all_test_create( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + format_result: Optional[StrictBool] = None, + property_mapping_test_request: Optional[PropertyMappingTestRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PropertyMappingTestResult: + """propertymappings_all_test_create + + Test Property Mapping + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param format_result: + :type format_result: bool + :param property_mapping_test_request: + :type property_mapping_test_request: PropertyMappingTestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_test_create_serialize( + pm_uuid=pm_uuid, + format_result=format_result, + property_mapping_test_request=property_mapping_test_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingTestResult", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_all_test_create_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + format_result: Optional[StrictBool] = None, + property_mapping_test_request: Optional[PropertyMappingTestRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PropertyMappingTestResult]: + """propertymappings_all_test_create + + Test Property Mapping + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param format_result: + :type format_result: bool + :param property_mapping_test_request: + :type property_mapping_test_request: PropertyMappingTestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_test_create_serialize( + pm_uuid=pm_uuid, + format_result=format_result, + property_mapping_test_request=property_mapping_test_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingTestResult", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_all_test_create_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + format_result: Optional[StrictBool] = None, + property_mapping_test_request: Optional[PropertyMappingTestRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_all_test_create + + Test Property Mapping + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param format_result: + :type format_result: bool + :param property_mapping_test_request: + :type property_mapping_test_request: PropertyMappingTestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_test_create_serialize( + pm_uuid=pm_uuid, + format_result=format_result, + property_mapping_test_request=property_mapping_test_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingTestResult", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_all_test_create_serialize( + self, + pm_uuid, + format_result, + property_mapping_test_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + if format_result is not None: + + _query_params.append(('format_result', format_result)) + + # process the header parameters + # process the form parameters + # process the body parameter + if property_mapping_test_request is not None: + _body_params = property_mapping_test_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/all/{pm_uuid}/test/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_all_types_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[TypeCreate]: + """propertymappings_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_all_types_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[TypeCreate]]: + """propertymappings_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_all_types_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_all_types_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/all/types/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_all_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_all_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_all_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_all_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_all_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_all_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_all_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_all_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/all/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_notification_create( + self, + notification_webhook_mapping_request: NotificationWebhookMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationWebhookMapping: + """propertymappings_notification_create + + NotificationWebhookMapping Viewset + + :param notification_webhook_mapping_request: (required) + :type notification_webhook_mapping_request: NotificationWebhookMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_create_serialize( + notification_webhook_mapping_request=notification_webhook_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_notification_create_with_http_info( + self, + notification_webhook_mapping_request: NotificationWebhookMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationWebhookMapping]: + """propertymappings_notification_create + + NotificationWebhookMapping Viewset + + :param notification_webhook_mapping_request: (required) + :type notification_webhook_mapping_request: NotificationWebhookMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_create_serialize( + notification_webhook_mapping_request=notification_webhook_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_notification_create_without_preload_content( + self, + notification_webhook_mapping_request: NotificationWebhookMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_notification_create + + NotificationWebhookMapping Viewset + + :param notification_webhook_mapping_request: (required) + :type notification_webhook_mapping_request: NotificationWebhookMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_create_serialize( + notification_webhook_mapping_request=notification_webhook_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_notification_create_serialize( + self, + notification_webhook_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if notification_webhook_mapping_request is not None: + _body_params = notification_webhook_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/notification/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_notification_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_notification_destroy + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_notification_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_notification_destroy + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_notification_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_notification_destroy + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_notification_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/notification/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_notification_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedNotificationWebhookMappingList: + """propertymappings_notification_list + + NotificationWebhookMapping Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationWebhookMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_notification_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedNotificationWebhookMappingList]: + """propertymappings_notification_list + + NotificationWebhookMapping Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationWebhookMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_notification_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_notification_list + + NotificationWebhookMapping Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedNotificationWebhookMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_notification_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/notification/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_notification_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + patched_notification_webhook_mapping_request: Optional[PatchedNotificationWebhookMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationWebhookMapping: + """propertymappings_notification_partial_update + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param patched_notification_webhook_mapping_request: + :type patched_notification_webhook_mapping_request: PatchedNotificationWebhookMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_partial_update_serialize( + pm_uuid=pm_uuid, + patched_notification_webhook_mapping_request=patched_notification_webhook_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_notification_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + patched_notification_webhook_mapping_request: Optional[PatchedNotificationWebhookMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationWebhookMapping]: + """propertymappings_notification_partial_update + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param patched_notification_webhook_mapping_request: + :type patched_notification_webhook_mapping_request: PatchedNotificationWebhookMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_partial_update_serialize( + pm_uuid=pm_uuid, + patched_notification_webhook_mapping_request=patched_notification_webhook_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_notification_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + patched_notification_webhook_mapping_request: Optional[PatchedNotificationWebhookMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_notification_partial_update + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param patched_notification_webhook_mapping_request: + :type patched_notification_webhook_mapping_request: PatchedNotificationWebhookMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_partial_update_serialize( + pm_uuid=pm_uuid, + patched_notification_webhook_mapping_request=patched_notification_webhook_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_notification_partial_update_serialize( + self, + pm_uuid, + patched_notification_webhook_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_notification_webhook_mapping_request is not None: + _body_params = patched_notification_webhook_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/notification/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_notification_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationWebhookMapping: + """propertymappings_notification_retrieve + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_notification_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationWebhookMapping]: + """propertymappings_notification_retrieve + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_notification_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_notification_retrieve + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_notification_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/notification/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_notification_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + notification_webhook_mapping_request: NotificationWebhookMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> NotificationWebhookMapping: + """propertymappings_notification_update + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param notification_webhook_mapping_request: (required) + :type notification_webhook_mapping_request: NotificationWebhookMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_update_serialize( + pm_uuid=pm_uuid, + notification_webhook_mapping_request=notification_webhook_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_notification_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + notification_webhook_mapping_request: NotificationWebhookMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[NotificationWebhookMapping]: + """propertymappings_notification_update + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param notification_webhook_mapping_request: (required) + :type notification_webhook_mapping_request: NotificationWebhookMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_update_serialize( + pm_uuid=pm_uuid, + notification_webhook_mapping_request=notification_webhook_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_notification_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + notification_webhook_mapping_request: NotificationWebhookMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_notification_update + + NotificationWebhookMapping Viewset + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param notification_webhook_mapping_request: (required) + :type notification_webhook_mapping_request: NotificationWebhookMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_update_serialize( + pm_uuid=pm_uuid, + notification_webhook_mapping_request=notification_webhook_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "NotificationWebhookMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_notification_update_serialize( + self, + pm_uuid, + notification_webhook_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if notification_webhook_mapping_request is not None: + _body_params = notification_webhook_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/notification/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_notification_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_notification_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_notification_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_notification_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_notification_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Webhook Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_notification_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Webhook Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_notification_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_notification_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/notification/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_google_workspace_create( + self, + google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProviderMapping: + """propertymappings_provider_google_workspace_create + + GoogleWorkspaceProviderMapping Viewset + + :param google_workspace_provider_mapping_request: (required) + :type google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_create_serialize( + google_workspace_provider_mapping_request=google_workspace_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_google_workspace_create_with_http_info( + self, + google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProviderMapping]: + """propertymappings_provider_google_workspace_create + + GoogleWorkspaceProviderMapping Viewset + + :param google_workspace_provider_mapping_request: (required) + :type google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_create_serialize( + google_workspace_provider_mapping_request=google_workspace_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_google_workspace_create_without_preload_content( + self, + google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_google_workspace_create + + GoogleWorkspaceProviderMapping Viewset + + :param google_workspace_provider_mapping_request: (required) + :type google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_create_serialize( + google_workspace_provider_mapping_request=google_workspace_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_google_workspace_create_serialize( + self, + google_workspace_provider_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_workspace_provider_mapping_request is not None: + _body_params = google_workspace_provider_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/provider/google_workspace/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_google_workspace_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_provider_google_workspace_destroy + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_google_workspace_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_provider_google_workspace_destroy + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_google_workspace_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_google_workspace_destroy + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_google_workspace_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/provider/google_workspace/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_google_workspace_list( + self, + expression: Optional[StrictStr] = None, + managed: Optional[List[StrictStr]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGoogleWorkspaceProviderMappingList: + """propertymappings_provider_google_workspace_list + + GoogleWorkspaceProviderMapping Viewset + + :param expression: + :type expression: str + :param managed: + :type managed: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pm_uuid: + :type pm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_list_serialize( + expression=expression, + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pm_uuid=pm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_google_workspace_list_with_http_info( + self, + expression: Optional[StrictStr] = None, + managed: Optional[List[StrictStr]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGoogleWorkspaceProviderMappingList]: + """propertymappings_provider_google_workspace_list + + GoogleWorkspaceProviderMapping Viewset + + :param expression: + :type expression: str + :param managed: + :type managed: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pm_uuid: + :type pm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_list_serialize( + expression=expression, + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pm_uuid=pm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_google_workspace_list_without_preload_content( + self, + expression: Optional[StrictStr] = None, + managed: Optional[List[StrictStr]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_google_workspace_list + + GoogleWorkspaceProviderMapping Viewset + + :param expression: + :type expression: str + :param managed: + :type managed: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pm_uuid: + :type pm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_list_serialize( + expression=expression, + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pm_uuid=pm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_google_workspace_list_serialize( + self, + expression, + managed, + name, + ordering, + page, + page_size, + pm_uuid, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if expression is not None: + + _query_params.append(('expression', expression)) + + if managed is not None: + + _query_params.append(('managed', managed)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pm_uuid is not None: + + _query_params.append(('pm_uuid', pm_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/google_workspace/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_google_workspace_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + patched_google_workspace_provider_mapping_request: Optional[PatchedGoogleWorkspaceProviderMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProviderMapping: + """propertymappings_provider_google_workspace_partial_update + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param patched_google_workspace_provider_mapping_request: + :type patched_google_workspace_provider_mapping_request: PatchedGoogleWorkspaceProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_partial_update_serialize( + pm_uuid=pm_uuid, + patched_google_workspace_provider_mapping_request=patched_google_workspace_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_google_workspace_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + patched_google_workspace_provider_mapping_request: Optional[PatchedGoogleWorkspaceProviderMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProviderMapping]: + """propertymappings_provider_google_workspace_partial_update + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param patched_google_workspace_provider_mapping_request: + :type patched_google_workspace_provider_mapping_request: PatchedGoogleWorkspaceProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_partial_update_serialize( + pm_uuid=pm_uuid, + patched_google_workspace_provider_mapping_request=patched_google_workspace_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_google_workspace_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + patched_google_workspace_provider_mapping_request: Optional[PatchedGoogleWorkspaceProviderMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_google_workspace_partial_update + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param patched_google_workspace_provider_mapping_request: + :type patched_google_workspace_provider_mapping_request: PatchedGoogleWorkspaceProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_partial_update_serialize( + pm_uuid=pm_uuid, + patched_google_workspace_provider_mapping_request=patched_google_workspace_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_google_workspace_partial_update_serialize( + self, + pm_uuid, + patched_google_workspace_provider_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_google_workspace_provider_mapping_request is not None: + _body_params = patched_google_workspace_provider_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/provider/google_workspace/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_google_workspace_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProviderMapping: + """propertymappings_provider_google_workspace_retrieve + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_google_workspace_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProviderMapping]: + """propertymappings_provider_google_workspace_retrieve + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_google_workspace_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_google_workspace_retrieve + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_google_workspace_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/google_workspace/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_google_workspace_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProviderMapping: + """propertymappings_provider_google_workspace_update + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param google_workspace_provider_mapping_request: (required) + :type google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_update_serialize( + pm_uuid=pm_uuid, + google_workspace_provider_mapping_request=google_workspace_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_google_workspace_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProviderMapping]: + """propertymappings_provider_google_workspace_update + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param google_workspace_provider_mapping_request: (required) + :type google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_update_serialize( + pm_uuid=pm_uuid, + google_workspace_provider_mapping_request=google_workspace_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_google_workspace_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_google_workspace_update + + GoogleWorkspaceProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param google_workspace_provider_mapping_request: (required) + :type google_workspace_provider_mapping_request: GoogleWorkspaceProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_update_serialize( + pm_uuid=pm_uuid, + google_workspace_provider_mapping_request=google_workspace_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_google_workspace_update_serialize( + self, + pm_uuid, + google_workspace_provider_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_workspace_provider_mapping_request is not None: + _body_params = google_workspace_provider_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/provider/google_workspace/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_google_workspace_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_provider_google_workspace_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_google_workspace_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_provider_google_workspace_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_google_workspace_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_google_workspace_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Google Workspace Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_google_workspace_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_google_workspace_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/google_workspace/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_microsoft_entra_create( + self, + microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProviderMapping: + """propertymappings_provider_microsoft_entra_create + + MicrosoftEntraProviderMapping Viewset + + :param microsoft_entra_provider_mapping_request: (required) + :type microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_create_serialize( + microsoft_entra_provider_mapping_request=microsoft_entra_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_microsoft_entra_create_with_http_info( + self, + microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProviderMapping]: + """propertymappings_provider_microsoft_entra_create + + MicrosoftEntraProviderMapping Viewset + + :param microsoft_entra_provider_mapping_request: (required) + :type microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_create_serialize( + microsoft_entra_provider_mapping_request=microsoft_entra_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_microsoft_entra_create_without_preload_content( + self, + microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_microsoft_entra_create + + MicrosoftEntraProviderMapping Viewset + + :param microsoft_entra_provider_mapping_request: (required) + :type microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_create_serialize( + microsoft_entra_provider_mapping_request=microsoft_entra_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_microsoft_entra_create_serialize( + self, + microsoft_entra_provider_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if microsoft_entra_provider_mapping_request is not None: + _body_params = microsoft_entra_provider_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/provider/microsoft_entra/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_microsoft_entra_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_provider_microsoft_entra_destroy + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_microsoft_entra_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_provider_microsoft_entra_destroy + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_microsoft_entra_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_microsoft_entra_destroy + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_microsoft_entra_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/provider/microsoft_entra/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_microsoft_entra_list( + self, + expression: Optional[StrictStr] = None, + managed: Optional[List[StrictStr]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedMicrosoftEntraProviderMappingList: + """propertymappings_provider_microsoft_entra_list + + MicrosoftEntraProviderMapping Viewset + + :param expression: + :type expression: str + :param managed: + :type managed: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pm_uuid: + :type pm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_list_serialize( + expression=expression, + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pm_uuid=pm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_microsoft_entra_list_with_http_info( + self, + expression: Optional[StrictStr] = None, + managed: Optional[List[StrictStr]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedMicrosoftEntraProviderMappingList]: + """propertymappings_provider_microsoft_entra_list + + MicrosoftEntraProviderMapping Viewset + + :param expression: + :type expression: str + :param managed: + :type managed: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pm_uuid: + :type pm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_list_serialize( + expression=expression, + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pm_uuid=pm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_microsoft_entra_list_without_preload_content( + self, + expression: Optional[StrictStr] = None, + managed: Optional[List[StrictStr]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_microsoft_entra_list + + MicrosoftEntraProviderMapping Viewset + + :param expression: + :type expression: str + :param managed: + :type managed: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pm_uuid: + :type pm_uuid: UUID + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_list_serialize( + expression=expression, + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pm_uuid=pm_uuid, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_microsoft_entra_list_serialize( + self, + expression, + managed, + name, + ordering, + page, + page_size, + pm_uuid, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if expression is not None: + + _query_params.append(('expression', expression)) + + if managed is not None: + + _query_params.append(('managed', managed)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pm_uuid is not None: + + _query_params.append(('pm_uuid', pm_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/microsoft_entra/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_microsoft_entra_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + patched_microsoft_entra_provider_mapping_request: Optional[PatchedMicrosoftEntraProviderMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProviderMapping: + """propertymappings_provider_microsoft_entra_partial_update + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param patched_microsoft_entra_provider_mapping_request: + :type patched_microsoft_entra_provider_mapping_request: PatchedMicrosoftEntraProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_partial_update_serialize( + pm_uuid=pm_uuid, + patched_microsoft_entra_provider_mapping_request=patched_microsoft_entra_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_microsoft_entra_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + patched_microsoft_entra_provider_mapping_request: Optional[PatchedMicrosoftEntraProviderMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProviderMapping]: + """propertymappings_provider_microsoft_entra_partial_update + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param patched_microsoft_entra_provider_mapping_request: + :type patched_microsoft_entra_provider_mapping_request: PatchedMicrosoftEntraProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_partial_update_serialize( + pm_uuid=pm_uuid, + patched_microsoft_entra_provider_mapping_request=patched_microsoft_entra_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_microsoft_entra_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + patched_microsoft_entra_provider_mapping_request: Optional[PatchedMicrosoftEntraProviderMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_microsoft_entra_partial_update + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param patched_microsoft_entra_provider_mapping_request: + :type patched_microsoft_entra_provider_mapping_request: PatchedMicrosoftEntraProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_partial_update_serialize( + pm_uuid=pm_uuid, + patched_microsoft_entra_provider_mapping_request=patched_microsoft_entra_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_microsoft_entra_partial_update_serialize( + self, + pm_uuid, + patched_microsoft_entra_provider_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_microsoft_entra_provider_mapping_request is not None: + _body_params = patched_microsoft_entra_provider_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/provider/microsoft_entra/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_microsoft_entra_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProviderMapping: + """propertymappings_provider_microsoft_entra_retrieve + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_microsoft_entra_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProviderMapping]: + """propertymappings_provider_microsoft_entra_retrieve + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_microsoft_entra_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_microsoft_entra_retrieve + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_microsoft_entra_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/microsoft_entra/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_microsoft_entra_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProviderMapping: + """propertymappings_provider_microsoft_entra_update + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param microsoft_entra_provider_mapping_request: (required) + :type microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_update_serialize( + pm_uuid=pm_uuid, + microsoft_entra_provider_mapping_request=microsoft_entra_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_microsoft_entra_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProviderMapping]: + """propertymappings_provider_microsoft_entra_update + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param microsoft_entra_provider_mapping_request: (required) + :type microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_update_serialize( + pm_uuid=pm_uuid, + microsoft_entra_provider_mapping_request=microsoft_entra_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_microsoft_entra_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_microsoft_entra_update + + MicrosoftEntraProviderMapping Viewset + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param microsoft_entra_provider_mapping_request: (required) + :type microsoft_entra_provider_mapping_request: MicrosoftEntraProviderMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_update_serialize( + pm_uuid=pm_uuid, + microsoft_entra_provider_mapping_request=microsoft_entra_provider_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_microsoft_entra_update_serialize( + self, + pm_uuid, + microsoft_entra_provider_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if microsoft_entra_provider_mapping_request is not None: + _body_params = microsoft_entra_provider_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/provider/microsoft_entra/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_microsoft_entra_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_provider_microsoft_entra_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_microsoft_entra_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_provider_microsoft_entra_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_microsoft_entra_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_microsoft_entra_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Microsoft Entra Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_microsoft_entra_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_microsoft_entra_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/microsoft_entra/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_rac_create( + self, + rac_property_mapping_request: RACPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RACPropertyMapping: + """propertymappings_provider_rac_create + + RACPropertyMapping Viewset + + :param rac_property_mapping_request: (required) + :type rac_property_mapping_request: RACPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_create_serialize( + rac_property_mapping_request=rac_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_rac_create_with_http_info( + self, + rac_property_mapping_request: RACPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RACPropertyMapping]: + """propertymappings_provider_rac_create + + RACPropertyMapping Viewset + + :param rac_property_mapping_request: (required) + :type rac_property_mapping_request: RACPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_create_serialize( + rac_property_mapping_request=rac_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_rac_create_without_preload_content( + self, + rac_property_mapping_request: RACPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_rac_create + + RACPropertyMapping Viewset + + :param rac_property_mapping_request: (required) + :type rac_property_mapping_request: RACPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_create_serialize( + rac_property_mapping_request=rac_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_rac_create_serialize( + self, + rac_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if rac_property_mapping_request is not None: + _body_params = rac_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/provider/rac/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_rac_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_provider_rac_destroy + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_rac_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_provider_rac_destroy + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_rac_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_rac_destroy + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_rac_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/provider/rac/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_rac_list( + self, + managed: Optional[List[StrictStr]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedRACPropertyMappingList: + """propertymappings_provider_rac_list + + RACPropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_list_serialize( + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRACPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_rac_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedRACPropertyMappingList]: + """propertymappings_provider_rac_list + + RACPropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_list_serialize( + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRACPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_rac_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_rac_list + + RACPropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_list_serialize( + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRACPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_rac_list_serialize( + self, + managed, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/rac/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_rac_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + patched_rac_property_mapping_request: Optional[PatchedRACPropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RACPropertyMapping: + """propertymappings_provider_rac_partial_update + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param patched_rac_property_mapping_request: + :type patched_rac_property_mapping_request: PatchedRACPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_partial_update_serialize( + pm_uuid=pm_uuid, + patched_rac_property_mapping_request=patched_rac_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_rac_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + patched_rac_property_mapping_request: Optional[PatchedRACPropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RACPropertyMapping]: + """propertymappings_provider_rac_partial_update + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param patched_rac_property_mapping_request: + :type patched_rac_property_mapping_request: PatchedRACPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_partial_update_serialize( + pm_uuid=pm_uuid, + patched_rac_property_mapping_request=patched_rac_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_rac_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + patched_rac_property_mapping_request: Optional[PatchedRACPropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_rac_partial_update + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param patched_rac_property_mapping_request: + :type patched_rac_property_mapping_request: PatchedRACPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_partial_update_serialize( + pm_uuid=pm_uuid, + patched_rac_property_mapping_request=patched_rac_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_rac_partial_update_serialize( + self, + pm_uuid, + patched_rac_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_rac_property_mapping_request is not None: + _body_params = patched_rac_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/provider/rac/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_rac_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RACPropertyMapping: + """propertymappings_provider_rac_retrieve + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_rac_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RACPropertyMapping]: + """propertymappings_provider_rac_retrieve + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_rac_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_rac_retrieve + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_rac_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/rac/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_rac_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + rac_property_mapping_request: RACPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RACPropertyMapping: + """propertymappings_provider_rac_update + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param rac_property_mapping_request: (required) + :type rac_property_mapping_request: RACPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_update_serialize( + pm_uuid=pm_uuid, + rac_property_mapping_request=rac_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_rac_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + rac_property_mapping_request: RACPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RACPropertyMapping]: + """propertymappings_provider_rac_update + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param rac_property_mapping_request: (required) + :type rac_property_mapping_request: RACPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_update_serialize( + pm_uuid=pm_uuid, + rac_property_mapping_request=rac_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_rac_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + rac_property_mapping_request: RACPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_rac_update + + RACPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param rac_property_mapping_request: (required) + :type rac_property_mapping_request: RACPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_update_serialize( + pm_uuid=pm_uuid, + rac_property_mapping_request=rac_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_rac_update_serialize( + self, + pm_uuid, + rac_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if rac_property_mapping_request is not None: + _body_params = rac_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/provider/rac/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_rac_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_provider_rac_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_rac_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_provider_rac_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_rac_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_rac_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this RAC Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_rac_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_rac_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/rac/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_radius_create( + self, + radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RadiusProviderPropertyMapping: + """propertymappings_provider_radius_create + + RadiusProviderPropertyMapping Viewset + + :param radius_provider_property_mapping_request: (required) + :type radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_create_serialize( + radius_provider_property_mapping_request=radius_provider_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_radius_create_with_http_info( + self, + radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RadiusProviderPropertyMapping]: + """propertymappings_provider_radius_create + + RadiusProviderPropertyMapping Viewset + + :param radius_provider_property_mapping_request: (required) + :type radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_create_serialize( + radius_provider_property_mapping_request=radius_provider_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_radius_create_without_preload_content( + self, + radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_radius_create + + RadiusProviderPropertyMapping Viewset + + :param radius_provider_property_mapping_request: (required) + :type radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_create_serialize( + radius_provider_property_mapping_request=radius_provider_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_radius_create_serialize( + self, + radius_provider_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if radius_provider_property_mapping_request is not None: + _body_params = radius_provider_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/provider/radius/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_radius_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_provider_radius_destroy + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_radius_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_provider_radius_destroy + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_radius_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_radius_destroy + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_radius_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/provider/radius/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_radius_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedRadiusProviderPropertyMappingList: + """propertymappings_provider_radius_list + + RadiusProviderPropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRadiusProviderPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_radius_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedRadiusProviderPropertyMappingList]: + """propertymappings_provider_radius_list + + RadiusProviderPropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRadiusProviderPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_radius_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_radius_list + + RadiusProviderPropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRadiusProviderPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_radius_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/radius/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_radius_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + patched_radius_provider_property_mapping_request: Optional[PatchedRadiusProviderPropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RadiusProviderPropertyMapping: + """propertymappings_provider_radius_partial_update + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param patched_radius_provider_property_mapping_request: + :type patched_radius_provider_property_mapping_request: PatchedRadiusProviderPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_partial_update_serialize( + pm_uuid=pm_uuid, + patched_radius_provider_property_mapping_request=patched_radius_provider_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_radius_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + patched_radius_provider_property_mapping_request: Optional[PatchedRadiusProviderPropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RadiusProviderPropertyMapping]: + """propertymappings_provider_radius_partial_update + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param patched_radius_provider_property_mapping_request: + :type patched_radius_provider_property_mapping_request: PatchedRadiusProviderPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_partial_update_serialize( + pm_uuid=pm_uuid, + patched_radius_provider_property_mapping_request=patched_radius_provider_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_radius_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + patched_radius_provider_property_mapping_request: Optional[PatchedRadiusProviderPropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_radius_partial_update + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param patched_radius_provider_property_mapping_request: + :type patched_radius_provider_property_mapping_request: PatchedRadiusProviderPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_partial_update_serialize( + pm_uuid=pm_uuid, + patched_radius_provider_property_mapping_request=patched_radius_provider_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_radius_partial_update_serialize( + self, + pm_uuid, + patched_radius_provider_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_radius_provider_property_mapping_request is not None: + _body_params = patched_radius_provider_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/provider/radius/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_radius_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RadiusProviderPropertyMapping: + """propertymappings_provider_radius_retrieve + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_radius_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RadiusProviderPropertyMapping]: + """propertymappings_provider_radius_retrieve + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_radius_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_radius_retrieve + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_radius_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/radius/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_radius_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RadiusProviderPropertyMapping: + """propertymappings_provider_radius_update + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param radius_provider_property_mapping_request: (required) + :type radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_update_serialize( + pm_uuid=pm_uuid, + radius_provider_property_mapping_request=radius_provider_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_radius_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RadiusProviderPropertyMapping]: + """propertymappings_provider_radius_update + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param radius_provider_property_mapping_request: (required) + :type radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_update_serialize( + pm_uuid=pm_uuid, + radius_provider_property_mapping_request=radius_provider_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_radius_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_radius_update + + RadiusProviderPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param radius_provider_property_mapping_request: (required) + :type radius_provider_property_mapping_request: RadiusProviderPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_update_serialize( + pm_uuid=pm_uuid, + radius_provider_property_mapping_request=radius_provider_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProviderPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_radius_update_serialize( + self, + pm_uuid, + radius_provider_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if radius_provider_property_mapping_request is not None: + _body_params = radius_provider_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/provider/radius/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_radius_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_provider_radius_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_radius_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_provider_radius_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_radius_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Radius Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_radius_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Radius Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_radius_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_radius_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/radius/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_saml_create( + self, + saml_property_mapping_request: SAMLPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLPropertyMapping: + """propertymappings_provider_saml_create + + SAMLPropertyMapping Viewset + + :param saml_property_mapping_request: (required) + :type saml_property_mapping_request: SAMLPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_create_serialize( + saml_property_mapping_request=saml_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_saml_create_with_http_info( + self, + saml_property_mapping_request: SAMLPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLPropertyMapping]: + """propertymappings_provider_saml_create + + SAMLPropertyMapping Viewset + + :param saml_property_mapping_request: (required) + :type saml_property_mapping_request: SAMLPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_create_serialize( + saml_property_mapping_request=saml_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_saml_create_without_preload_content( + self, + saml_property_mapping_request: SAMLPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_saml_create + + SAMLPropertyMapping Viewset + + :param saml_property_mapping_request: (required) + :type saml_property_mapping_request: SAMLPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_create_serialize( + saml_property_mapping_request=saml_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_saml_create_serialize( + self, + saml_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if saml_property_mapping_request is not None: + _body_params = saml_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/provider/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_saml_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_provider_saml_destroy + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_saml_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_provider_saml_destroy + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_saml_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_saml_destroy + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_saml_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/provider/saml/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_saml_list( + self, + friendly_name: Optional[StrictStr] = None, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + saml_name: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSAMLPropertyMappingList: + """propertymappings_provider_saml_list + + SAMLPropertyMapping Viewset + + :param friendly_name: + :type friendly_name: str + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param saml_name: + :type saml_name: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_list_serialize( + friendly_name=friendly_name, + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + saml_name=saml_name, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_saml_list_with_http_info( + self, + friendly_name: Optional[StrictStr] = None, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + saml_name: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSAMLPropertyMappingList]: + """propertymappings_provider_saml_list + + SAMLPropertyMapping Viewset + + :param friendly_name: + :type friendly_name: str + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param saml_name: + :type saml_name: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_list_serialize( + friendly_name=friendly_name, + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + saml_name=saml_name, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_saml_list_without_preload_content( + self, + friendly_name: Optional[StrictStr] = None, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + saml_name: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_saml_list + + SAMLPropertyMapping Viewset + + :param friendly_name: + :type friendly_name: str + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param saml_name: + :type saml_name: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_list_serialize( + friendly_name=friendly_name, + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + saml_name=saml_name, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLPropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_saml_list_serialize( + self, + friendly_name, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + saml_name, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if friendly_name is not None: + + _query_params.append(('friendly_name', friendly_name)) + + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if saml_name is not None: + + _query_params.append(('saml_name', saml_name)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_saml_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + patched_saml_property_mapping_request: Optional[PatchedSAMLPropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLPropertyMapping: + """propertymappings_provider_saml_partial_update + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param patched_saml_property_mapping_request: + :type patched_saml_property_mapping_request: PatchedSAMLPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_partial_update_serialize( + pm_uuid=pm_uuid, + patched_saml_property_mapping_request=patched_saml_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_saml_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + patched_saml_property_mapping_request: Optional[PatchedSAMLPropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLPropertyMapping]: + """propertymappings_provider_saml_partial_update + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param patched_saml_property_mapping_request: + :type patched_saml_property_mapping_request: PatchedSAMLPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_partial_update_serialize( + pm_uuid=pm_uuid, + patched_saml_property_mapping_request=patched_saml_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_saml_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + patched_saml_property_mapping_request: Optional[PatchedSAMLPropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_saml_partial_update + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param patched_saml_property_mapping_request: + :type patched_saml_property_mapping_request: PatchedSAMLPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_partial_update_serialize( + pm_uuid=pm_uuid, + patched_saml_property_mapping_request=patched_saml_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_saml_partial_update_serialize( + self, + pm_uuid, + patched_saml_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_saml_property_mapping_request is not None: + _body_params = patched_saml_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/provider/saml/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_saml_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLPropertyMapping: + """propertymappings_provider_saml_retrieve + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_saml_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLPropertyMapping]: + """propertymappings_provider_saml_retrieve + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_saml_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_saml_retrieve + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_saml_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/saml/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_saml_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + saml_property_mapping_request: SAMLPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLPropertyMapping: + """propertymappings_provider_saml_update + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param saml_property_mapping_request: (required) + :type saml_property_mapping_request: SAMLPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_update_serialize( + pm_uuid=pm_uuid, + saml_property_mapping_request=saml_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_saml_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + saml_property_mapping_request: SAMLPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLPropertyMapping]: + """propertymappings_provider_saml_update + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param saml_property_mapping_request: (required) + :type saml_property_mapping_request: SAMLPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_update_serialize( + pm_uuid=pm_uuid, + saml_property_mapping_request=saml_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_saml_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + saml_property_mapping_request: SAMLPropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_saml_update + + SAMLPropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param saml_property_mapping_request: (required) + :type saml_property_mapping_request: SAMLPropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_update_serialize( + pm_uuid=pm_uuid, + saml_property_mapping_request=saml_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLPropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_saml_update_serialize( + self, + pm_uuid, + saml_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if saml_property_mapping_request is not None: + _body_params = saml_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/provider/saml/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_saml_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_provider_saml_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_saml_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_provider_saml_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_saml_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Provider Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_saml_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SAML Provider Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_saml_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_saml_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/saml/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scim_create( + self, + scim_mapping_request: SCIMMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMMapping: + """propertymappings_provider_scim_create + + SCIMMapping Viewset + + :param scim_mapping_request: (required) + :type scim_mapping_request: SCIMMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_create_serialize( + scim_mapping_request=scim_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scim_create_with_http_info( + self, + scim_mapping_request: SCIMMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMMapping]: + """propertymappings_provider_scim_create + + SCIMMapping Viewset + + :param scim_mapping_request: (required) + :type scim_mapping_request: SCIMMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_create_serialize( + scim_mapping_request=scim_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scim_create_without_preload_content( + self, + scim_mapping_request: SCIMMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scim_create + + SCIMMapping Viewset + + :param scim_mapping_request: (required) + :type scim_mapping_request: SCIMMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_create_serialize( + scim_mapping_request=scim_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scim_create_serialize( + self, + scim_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_mapping_request is not None: + _body_params = scim_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/provider/scim/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scim_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_provider_scim_destroy + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scim_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_provider_scim_destroy + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scim_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scim_destroy + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scim_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/provider/scim/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scim_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSCIMMappingList: + """propertymappings_provider_scim_list + + SCIMMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scim_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSCIMMappingList]: + """propertymappings_provider_scim_list + + SCIMMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scim_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scim_list + + SCIMMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scim_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/scim/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scim_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + patched_scim_mapping_request: Optional[PatchedSCIMMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMMapping: + """propertymappings_provider_scim_partial_update + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param patched_scim_mapping_request: + :type patched_scim_mapping_request: PatchedSCIMMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_partial_update_serialize( + pm_uuid=pm_uuid, + patched_scim_mapping_request=patched_scim_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scim_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + patched_scim_mapping_request: Optional[PatchedSCIMMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMMapping]: + """propertymappings_provider_scim_partial_update + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param patched_scim_mapping_request: + :type patched_scim_mapping_request: PatchedSCIMMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_partial_update_serialize( + pm_uuid=pm_uuid, + patched_scim_mapping_request=patched_scim_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scim_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + patched_scim_mapping_request: Optional[PatchedSCIMMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scim_partial_update + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param patched_scim_mapping_request: + :type patched_scim_mapping_request: PatchedSCIMMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_partial_update_serialize( + pm_uuid=pm_uuid, + patched_scim_mapping_request=patched_scim_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scim_partial_update_serialize( + self, + pm_uuid, + patched_scim_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_scim_mapping_request is not None: + _body_params = patched_scim_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/provider/scim/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scim_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMMapping: + """propertymappings_provider_scim_retrieve + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scim_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMMapping]: + """propertymappings_provider_scim_retrieve + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scim_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scim_retrieve + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scim_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/scim/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scim_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + scim_mapping_request: SCIMMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMMapping: + """propertymappings_provider_scim_update + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param scim_mapping_request: (required) + :type scim_mapping_request: SCIMMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_update_serialize( + pm_uuid=pm_uuid, + scim_mapping_request=scim_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scim_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + scim_mapping_request: SCIMMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMMapping]: + """propertymappings_provider_scim_update + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param scim_mapping_request: (required) + :type scim_mapping_request: SCIMMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_update_serialize( + pm_uuid=pm_uuid, + scim_mapping_request=scim_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scim_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + scim_mapping_request: SCIMMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scim_update + + SCIMMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param scim_mapping_request: (required) + :type scim_mapping_request: SCIMMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_update_serialize( + pm_uuid=pm_uuid, + scim_mapping_request=scim_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scim_update_serialize( + self, + pm_uuid, + scim_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_mapping_request is not None: + _body_params = scim_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/provider/scim/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scim_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_provider_scim_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scim_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_provider_scim_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scim_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Provider Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scim_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SCIM Provider Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scim_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scim_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/scim/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scope_create( + self, + scope_mapping_request: ScopeMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ScopeMapping: + """propertymappings_provider_scope_create + + ScopeMapping Viewset + + :param scope_mapping_request: (required) + :type scope_mapping_request: ScopeMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_create_serialize( + scope_mapping_request=scope_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scope_create_with_http_info( + self, + scope_mapping_request: ScopeMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ScopeMapping]: + """propertymappings_provider_scope_create + + ScopeMapping Viewset + + :param scope_mapping_request: (required) + :type scope_mapping_request: ScopeMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_create_serialize( + scope_mapping_request=scope_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scope_create_without_preload_content( + self, + scope_mapping_request: ScopeMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scope_create + + ScopeMapping Viewset + + :param scope_mapping_request: (required) + :type scope_mapping_request: ScopeMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_create_serialize( + scope_mapping_request=scope_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scope_create_serialize( + self, + scope_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scope_mapping_request is not None: + _body_params = scope_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/provider/scope/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scope_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_provider_scope_destroy + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scope_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_provider_scope_destroy + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scope_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scope_destroy + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scope_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/provider/scope/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scope_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + scope_name: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedScopeMappingList: + """propertymappings_provider_scope_list + + ScopeMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param scope_name: + :type scope_name: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + scope_name=scope_name, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedScopeMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scope_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + scope_name: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedScopeMappingList]: + """propertymappings_provider_scope_list + + ScopeMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param scope_name: + :type scope_name: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + scope_name=scope_name, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedScopeMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scope_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + scope_name: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scope_list + + ScopeMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param scope_name: + :type scope_name: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + scope_name=scope_name, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedScopeMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scope_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + scope_name, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if scope_name is not None: + + _query_params.append(('scope_name', scope_name)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/scope/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scope_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + patched_scope_mapping_request: Optional[PatchedScopeMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ScopeMapping: + """propertymappings_provider_scope_partial_update + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param patched_scope_mapping_request: + :type patched_scope_mapping_request: PatchedScopeMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_partial_update_serialize( + pm_uuid=pm_uuid, + patched_scope_mapping_request=patched_scope_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scope_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + patched_scope_mapping_request: Optional[PatchedScopeMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ScopeMapping]: + """propertymappings_provider_scope_partial_update + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param patched_scope_mapping_request: + :type patched_scope_mapping_request: PatchedScopeMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_partial_update_serialize( + pm_uuid=pm_uuid, + patched_scope_mapping_request=patched_scope_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scope_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + patched_scope_mapping_request: Optional[PatchedScopeMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scope_partial_update + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param patched_scope_mapping_request: + :type patched_scope_mapping_request: PatchedScopeMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_partial_update_serialize( + pm_uuid=pm_uuid, + patched_scope_mapping_request=patched_scope_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scope_partial_update_serialize( + self, + pm_uuid, + patched_scope_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_scope_mapping_request is not None: + _body_params = patched_scope_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/provider/scope/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scope_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ScopeMapping: + """propertymappings_provider_scope_retrieve + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scope_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ScopeMapping]: + """propertymappings_provider_scope_retrieve + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scope_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scope_retrieve + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scope_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/scope/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scope_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + scope_mapping_request: ScopeMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ScopeMapping: + """propertymappings_provider_scope_update + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param scope_mapping_request: (required) + :type scope_mapping_request: ScopeMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_update_serialize( + pm_uuid=pm_uuid, + scope_mapping_request=scope_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scope_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + scope_mapping_request: ScopeMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ScopeMapping]: + """propertymappings_provider_scope_update + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param scope_mapping_request: (required) + :type scope_mapping_request: ScopeMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_update_serialize( + pm_uuid=pm_uuid, + scope_mapping_request=scope_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scope_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + scope_mapping_request: ScopeMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scope_update + + ScopeMapping Viewset + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param scope_mapping_request: (required) + :type scope_mapping_request: ScopeMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_update_serialize( + pm_uuid=pm_uuid, + scope_mapping_request=scope_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ScopeMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scope_update_serialize( + self, + pm_uuid, + scope_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scope_mapping_request is not None: + _body_params = scope_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/provider/scope/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_provider_scope_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_provider_scope_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_provider_scope_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_provider_scope_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_provider_scope_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Scope Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_provider_scope_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Scope Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_provider_scope_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_provider_scope_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/provider/scope/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_kerberos_create( + self, + kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KerberosSourcePropertyMapping: + """propertymappings_source_kerberos_create + + KerberosSource PropertyMapping Viewset + + :param kerberos_source_property_mapping_request: (required) + :type kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_create_serialize( + kerberos_source_property_mapping_request=kerberos_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_kerberos_create_with_http_info( + self, + kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KerberosSourcePropertyMapping]: + """propertymappings_source_kerberos_create + + KerberosSource PropertyMapping Viewset + + :param kerberos_source_property_mapping_request: (required) + :type kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_create_serialize( + kerberos_source_property_mapping_request=kerberos_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_kerberos_create_without_preload_content( + self, + kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_kerberos_create + + KerberosSource PropertyMapping Viewset + + :param kerberos_source_property_mapping_request: (required) + :type kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_create_serialize( + kerberos_source_property_mapping_request=kerberos_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_kerberos_create_serialize( + self, + kerberos_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if kerberos_source_property_mapping_request is not None: + _body_params = kerberos_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/source/kerberos/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_kerberos_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_source_kerberos_destroy + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_kerberos_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_source_kerberos_destroy + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_kerberos_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_kerberos_destroy + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_kerberos_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/source/kerberos/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_kerberos_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedKerberosSourcePropertyMappingList: + """propertymappings_source_kerberos_list + + KerberosSource PropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedKerberosSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_kerberos_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedKerberosSourcePropertyMappingList]: + """propertymappings_source_kerberos_list + + KerberosSource PropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedKerberosSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_kerberos_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_kerberos_list + + KerberosSource PropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedKerberosSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_kerberos_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/kerberos/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_kerberos_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + patched_kerberos_source_property_mapping_request: Optional[PatchedKerberosSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KerberosSourcePropertyMapping: + """propertymappings_source_kerberos_partial_update + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_kerberos_source_property_mapping_request: + :type patched_kerberos_source_property_mapping_request: PatchedKerberosSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_partial_update_serialize( + pm_uuid=pm_uuid, + patched_kerberos_source_property_mapping_request=patched_kerberos_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_kerberos_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + patched_kerberos_source_property_mapping_request: Optional[PatchedKerberosSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KerberosSourcePropertyMapping]: + """propertymappings_source_kerberos_partial_update + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_kerberos_source_property_mapping_request: + :type patched_kerberos_source_property_mapping_request: PatchedKerberosSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_partial_update_serialize( + pm_uuid=pm_uuid, + patched_kerberos_source_property_mapping_request=patched_kerberos_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_kerberos_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + patched_kerberos_source_property_mapping_request: Optional[PatchedKerberosSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_kerberos_partial_update + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_kerberos_source_property_mapping_request: + :type patched_kerberos_source_property_mapping_request: PatchedKerberosSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_partial_update_serialize( + pm_uuid=pm_uuid, + patched_kerberos_source_property_mapping_request=patched_kerberos_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_kerberos_partial_update_serialize( + self, + pm_uuid, + patched_kerberos_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_kerberos_source_property_mapping_request is not None: + _body_params = patched_kerberos_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/source/kerberos/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_kerberos_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KerberosSourcePropertyMapping: + """propertymappings_source_kerberos_retrieve + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_kerberos_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KerberosSourcePropertyMapping]: + """propertymappings_source_kerberos_retrieve + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_kerberos_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_kerberos_retrieve + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_kerberos_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/kerberos/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_kerberos_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KerberosSourcePropertyMapping: + """propertymappings_source_kerberos_update + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param kerberos_source_property_mapping_request: (required) + :type kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_update_serialize( + pm_uuid=pm_uuid, + kerberos_source_property_mapping_request=kerberos_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_kerberos_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KerberosSourcePropertyMapping]: + """propertymappings_source_kerberos_update + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param kerberos_source_property_mapping_request: (required) + :type kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_update_serialize( + pm_uuid=pm_uuid, + kerberos_source_property_mapping_request=kerberos_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_kerberos_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_kerberos_update + + KerberosSource PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param kerberos_source_property_mapping_request: (required) + :type kerberos_source_property_mapping_request: KerberosSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_update_serialize( + pm_uuid=pm_uuid, + kerberos_source_property_mapping_request=kerberos_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_kerberos_update_serialize( + self, + pm_uuid, + kerberos_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if kerberos_source_property_mapping_request is not None: + _body_params = kerberos_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/source/kerberos/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_kerberos_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_source_kerberos_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_kerberos_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_source_kerberos_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_kerberos_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Kerberos Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_kerberos_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Kerberos Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_kerberos_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_kerberos_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/kerberos/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_ldap_create( + self, + ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPSourcePropertyMapping: + """propertymappings_source_ldap_create + + LDAP PropertyMapping Viewset + + :param ldap_source_property_mapping_request: (required) + :type ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_create_serialize( + ldap_source_property_mapping_request=ldap_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_ldap_create_with_http_info( + self, + ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPSourcePropertyMapping]: + """propertymappings_source_ldap_create + + LDAP PropertyMapping Viewset + + :param ldap_source_property_mapping_request: (required) + :type ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_create_serialize( + ldap_source_property_mapping_request=ldap_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_ldap_create_without_preload_content( + self, + ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_ldap_create + + LDAP PropertyMapping Viewset + + :param ldap_source_property_mapping_request: (required) + :type ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_create_serialize( + ldap_source_property_mapping_request=ldap_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_ldap_create_serialize( + self, + ldap_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ldap_source_property_mapping_request is not None: + _body_params = ldap_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/source/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_ldap_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_source_ldap_destroy + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_ldap_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_source_ldap_destroy + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_ldap_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_ldap_destroy + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_ldap_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/source/ldap/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_ldap_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedLDAPSourcePropertyMappingList: + """propertymappings_source_ldap_list + + LDAP PropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_ldap_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedLDAPSourcePropertyMappingList]: + """propertymappings_source_ldap_list + + LDAP PropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_ldap_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_ldap_list + + LDAP PropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_ldap_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_ldap_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + patched_ldap_source_property_mapping_request: Optional[PatchedLDAPSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPSourcePropertyMapping: + """propertymappings_source_ldap_partial_update + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_ldap_source_property_mapping_request: + :type patched_ldap_source_property_mapping_request: PatchedLDAPSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_partial_update_serialize( + pm_uuid=pm_uuid, + patched_ldap_source_property_mapping_request=patched_ldap_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_ldap_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + patched_ldap_source_property_mapping_request: Optional[PatchedLDAPSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPSourcePropertyMapping]: + """propertymappings_source_ldap_partial_update + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_ldap_source_property_mapping_request: + :type patched_ldap_source_property_mapping_request: PatchedLDAPSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_partial_update_serialize( + pm_uuid=pm_uuid, + patched_ldap_source_property_mapping_request=patched_ldap_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_ldap_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + patched_ldap_source_property_mapping_request: Optional[PatchedLDAPSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_ldap_partial_update + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_ldap_source_property_mapping_request: + :type patched_ldap_source_property_mapping_request: PatchedLDAPSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_partial_update_serialize( + pm_uuid=pm_uuid, + patched_ldap_source_property_mapping_request=patched_ldap_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_ldap_partial_update_serialize( + self, + pm_uuid, + patched_ldap_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_ldap_source_property_mapping_request is not None: + _body_params = patched_ldap_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/source/ldap/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_ldap_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPSourcePropertyMapping: + """propertymappings_source_ldap_retrieve + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_ldap_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPSourcePropertyMapping]: + """propertymappings_source_ldap_retrieve + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_ldap_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_ldap_retrieve + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_ldap_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/ldap/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_ldap_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPSourcePropertyMapping: + """propertymappings_source_ldap_update + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param ldap_source_property_mapping_request: (required) + :type ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_update_serialize( + pm_uuid=pm_uuid, + ldap_source_property_mapping_request=ldap_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_ldap_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPSourcePropertyMapping]: + """propertymappings_source_ldap_update + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param ldap_source_property_mapping_request: (required) + :type ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_update_serialize( + pm_uuid=pm_uuid, + ldap_source_property_mapping_request=ldap_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_ldap_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_ldap_update + + LDAP PropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param ldap_source_property_mapping_request: (required) + :type ldap_source_property_mapping_request: LDAPSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_update_serialize( + pm_uuid=pm_uuid, + ldap_source_property_mapping_request=ldap_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_ldap_update_serialize( + self, + pm_uuid, + ldap_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ldap_source_property_mapping_request is not None: + _body_params = ldap_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/source/ldap/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_ldap_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_source_ldap_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_ldap_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_source_ldap_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_ldap_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this LDAP Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_ldap_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this LDAP Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_ldap_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_ldap_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/ldap/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_oauth_create( + self, + o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuthSourcePropertyMapping: + """propertymappings_source_oauth_create + + OAuthSourcePropertyMapping Viewset + + :param o_auth_source_property_mapping_request: (required) + :type o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_create_serialize( + o_auth_source_property_mapping_request=o_auth_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_oauth_create_with_http_info( + self, + o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuthSourcePropertyMapping]: + """propertymappings_source_oauth_create + + OAuthSourcePropertyMapping Viewset + + :param o_auth_source_property_mapping_request: (required) + :type o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_create_serialize( + o_auth_source_property_mapping_request=o_auth_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_oauth_create_without_preload_content( + self, + o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_oauth_create + + OAuthSourcePropertyMapping Viewset + + :param o_auth_source_property_mapping_request: (required) + :type o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_create_serialize( + o_auth_source_property_mapping_request=o_auth_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_oauth_create_serialize( + self, + o_auth_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if o_auth_source_property_mapping_request is not None: + _body_params = o_auth_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/source/oauth/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_oauth_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_source_oauth_destroy + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_oauth_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_source_oauth_destroy + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_oauth_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_oauth_destroy + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_oauth_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/source/oauth/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_oauth_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedOAuthSourcePropertyMappingList: + """propertymappings_source_oauth_list + + OAuthSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOAuthSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_oauth_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedOAuthSourcePropertyMappingList]: + """propertymappings_source_oauth_list + + OAuthSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOAuthSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_oauth_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_oauth_list + + OAuthSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOAuthSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_oauth_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/oauth/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_oauth_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + patched_o_auth_source_property_mapping_request: Optional[PatchedOAuthSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuthSourcePropertyMapping: + """propertymappings_source_oauth_partial_update + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_o_auth_source_property_mapping_request: + :type patched_o_auth_source_property_mapping_request: PatchedOAuthSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_partial_update_serialize( + pm_uuid=pm_uuid, + patched_o_auth_source_property_mapping_request=patched_o_auth_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_oauth_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + patched_o_auth_source_property_mapping_request: Optional[PatchedOAuthSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuthSourcePropertyMapping]: + """propertymappings_source_oauth_partial_update + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_o_auth_source_property_mapping_request: + :type patched_o_auth_source_property_mapping_request: PatchedOAuthSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_partial_update_serialize( + pm_uuid=pm_uuid, + patched_o_auth_source_property_mapping_request=patched_o_auth_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_oauth_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + patched_o_auth_source_property_mapping_request: Optional[PatchedOAuthSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_oauth_partial_update + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_o_auth_source_property_mapping_request: + :type patched_o_auth_source_property_mapping_request: PatchedOAuthSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_partial_update_serialize( + pm_uuid=pm_uuid, + patched_o_auth_source_property_mapping_request=patched_o_auth_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_oauth_partial_update_serialize( + self, + pm_uuid, + patched_o_auth_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_o_auth_source_property_mapping_request is not None: + _body_params = patched_o_auth_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/source/oauth/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_oauth_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuthSourcePropertyMapping: + """propertymappings_source_oauth_retrieve + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_oauth_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuthSourcePropertyMapping]: + """propertymappings_source_oauth_retrieve + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_oauth_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_oauth_retrieve + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_oauth_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/oauth/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_oauth_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuthSourcePropertyMapping: + """propertymappings_source_oauth_update + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param o_auth_source_property_mapping_request: (required) + :type o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_update_serialize( + pm_uuid=pm_uuid, + o_auth_source_property_mapping_request=o_auth_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_oauth_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuthSourcePropertyMapping]: + """propertymappings_source_oauth_update + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param o_auth_source_property_mapping_request: (required) + :type o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_update_serialize( + pm_uuid=pm_uuid, + o_auth_source_property_mapping_request=o_auth_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_oauth_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_oauth_update + + OAuthSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param o_auth_source_property_mapping_request: (required) + :type o_auth_source_property_mapping_request: OAuthSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_update_serialize( + pm_uuid=pm_uuid, + o_auth_source_property_mapping_request=o_auth_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_oauth_update_serialize( + self, + pm_uuid, + o_auth_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if o_auth_source_property_mapping_request is not None: + _body_params = o_auth_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/source/oauth/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_oauth_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_source_oauth_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_oauth_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_source_oauth_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_oauth_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this OAuth Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_oauth_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this OAuth Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_oauth_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_oauth_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/oauth/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_plex_create( + self, + plex_source_property_mapping_request: PlexSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PlexSourcePropertyMapping: + """propertymappings_source_plex_create + + PlexSourcePropertyMapping Viewset + + :param plex_source_property_mapping_request: (required) + :type plex_source_property_mapping_request: PlexSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_create_serialize( + plex_source_property_mapping_request=plex_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_plex_create_with_http_info( + self, + plex_source_property_mapping_request: PlexSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PlexSourcePropertyMapping]: + """propertymappings_source_plex_create + + PlexSourcePropertyMapping Viewset + + :param plex_source_property_mapping_request: (required) + :type plex_source_property_mapping_request: PlexSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_create_serialize( + plex_source_property_mapping_request=plex_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_plex_create_without_preload_content( + self, + plex_source_property_mapping_request: PlexSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_plex_create + + PlexSourcePropertyMapping Viewset + + :param plex_source_property_mapping_request: (required) + :type plex_source_property_mapping_request: PlexSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_create_serialize( + plex_source_property_mapping_request=plex_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_plex_create_serialize( + self, + plex_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if plex_source_property_mapping_request is not None: + _body_params = plex_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/source/plex/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_plex_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_source_plex_destroy + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_plex_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_source_plex_destroy + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_plex_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_plex_destroy + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_plex_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/source/plex/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_plex_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPlexSourcePropertyMappingList: + """propertymappings_source_plex_list + + PlexSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPlexSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_plex_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPlexSourcePropertyMappingList]: + """propertymappings_source_plex_list + + PlexSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPlexSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_plex_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_plex_list + + PlexSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPlexSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_plex_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/plex/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_plex_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + patched_plex_source_property_mapping_request: Optional[PatchedPlexSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PlexSourcePropertyMapping: + """propertymappings_source_plex_partial_update + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_plex_source_property_mapping_request: + :type patched_plex_source_property_mapping_request: PatchedPlexSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_partial_update_serialize( + pm_uuid=pm_uuid, + patched_plex_source_property_mapping_request=patched_plex_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_plex_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + patched_plex_source_property_mapping_request: Optional[PatchedPlexSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PlexSourcePropertyMapping]: + """propertymappings_source_plex_partial_update + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_plex_source_property_mapping_request: + :type patched_plex_source_property_mapping_request: PatchedPlexSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_partial_update_serialize( + pm_uuid=pm_uuid, + patched_plex_source_property_mapping_request=patched_plex_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_plex_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + patched_plex_source_property_mapping_request: Optional[PatchedPlexSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_plex_partial_update + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_plex_source_property_mapping_request: + :type patched_plex_source_property_mapping_request: PatchedPlexSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_partial_update_serialize( + pm_uuid=pm_uuid, + patched_plex_source_property_mapping_request=patched_plex_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_plex_partial_update_serialize( + self, + pm_uuid, + patched_plex_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_plex_source_property_mapping_request is not None: + _body_params = patched_plex_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/source/plex/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_plex_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PlexSourcePropertyMapping: + """propertymappings_source_plex_retrieve + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_plex_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PlexSourcePropertyMapping]: + """propertymappings_source_plex_retrieve + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_plex_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_plex_retrieve + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_plex_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/plex/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_plex_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + plex_source_property_mapping_request: PlexSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PlexSourcePropertyMapping: + """propertymappings_source_plex_update + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param plex_source_property_mapping_request: (required) + :type plex_source_property_mapping_request: PlexSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_update_serialize( + pm_uuid=pm_uuid, + plex_source_property_mapping_request=plex_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_plex_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + plex_source_property_mapping_request: PlexSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PlexSourcePropertyMapping]: + """propertymappings_source_plex_update + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param plex_source_property_mapping_request: (required) + :type plex_source_property_mapping_request: PlexSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_update_serialize( + pm_uuid=pm_uuid, + plex_source_property_mapping_request=plex_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_plex_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + plex_source_property_mapping_request: PlexSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_plex_update + + PlexSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param plex_source_property_mapping_request: (required) + :type plex_source_property_mapping_request: PlexSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_update_serialize( + pm_uuid=pm_uuid, + plex_source_property_mapping_request=plex_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_plex_update_serialize( + self, + pm_uuid, + plex_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if plex_source_property_mapping_request is not None: + _body_params = plex_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/source/plex/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_plex_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_source_plex_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_plex_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_source_plex_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_plex_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Plex Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_plex_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Plex Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_plex_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_plex_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/plex/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_saml_create( + self, + saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLSourcePropertyMapping: + """propertymappings_source_saml_create + + SAMLSourcePropertyMapping Viewset + + :param saml_source_property_mapping_request: (required) + :type saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_create_serialize( + saml_source_property_mapping_request=saml_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_saml_create_with_http_info( + self, + saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLSourcePropertyMapping]: + """propertymappings_source_saml_create + + SAMLSourcePropertyMapping Viewset + + :param saml_source_property_mapping_request: (required) + :type saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_create_serialize( + saml_source_property_mapping_request=saml_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_saml_create_without_preload_content( + self, + saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_saml_create + + SAMLSourcePropertyMapping Viewset + + :param saml_source_property_mapping_request: (required) + :type saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_create_serialize( + saml_source_property_mapping_request=saml_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_saml_create_serialize( + self, + saml_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if saml_source_property_mapping_request is not None: + _body_params = saml_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/source/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_saml_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_source_saml_destroy + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_saml_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_source_saml_destroy + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_saml_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_saml_destroy + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_saml_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/source/saml/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_saml_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSAMLSourcePropertyMappingList: + """propertymappings_source_saml_list + + SAMLSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_saml_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSAMLSourcePropertyMappingList]: + """propertymappings_source_saml_list + + SAMLSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_saml_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_saml_list + + SAMLSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_saml_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_saml_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + patched_saml_source_property_mapping_request: Optional[PatchedSAMLSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLSourcePropertyMapping: + """propertymappings_source_saml_partial_update + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_saml_source_property_mapping_request: + :type patched_saml_source_property_mapping_request: PatchedSAMLSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_partial_update_serialize( + pm_uuid=pm_uuid, + patched_saml_source_property_mapping_request=patched_saml_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_saml_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + patched_saml_source_property_mapping_request: Optional[PatchedSAMLSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLSourcePropertyMapping]: + """propertymappings_source_saml_partial_update + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_saml_source_property_mapping_request: + :type patched_saml_source_property_mapping_request: PatchedSAMLSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_partial_update_serialize( + pm_uuid=pm_uuid, + patched_saml_source_property_mapping_request=patched_saml_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_saml_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + patched_saml_source_property_mapping_request: Optional[PatchedSAMLSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_saml_partial_update + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_saml_source_property_mapping_request: + :type patched_saml_source_property_mapping_request: PatchedSAMLSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_partial_update_serialize( + pm_uuid=pm_uuid, + patched_saml_source_property_mapping_request=patched_saml_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_saml_partial_update_serialize( + self, + pm_uuid, + patched_saml_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_saml_source_property_mapping_request is not None: + _body_params = patched_saml_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/source/saml/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_saml_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLSourcePropertyMapping: + """propertymappings_source_saml_retrieve + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_saml_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLSourcePropertyMapping]: + """propertymappings_source_saml_retrieve + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_saml_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_saml_retrieve + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_saml_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/saml/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_saml_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLSourcePropertyMapping: + """propertymappings_source_saml_update + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param saml_source_property_mapping_request: (required) + :type saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_update_serialize( + pm_uuid=pm_uuid, + saml_source_property_mapping_request=saml_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_saml_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLSourcePropertyMapping]: + """propertymappings_source_saml_update + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param saml_source_property_mapping_request: (required) + :type saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_update_serialize( + pm_uuid=pm_uuid, + saml_source_property_mapping_request=saml_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_saml_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_saml_update + + SAMLSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param saml_source_property_mapping_request: (required) + :type saml_source_property_mapping_request: SAMLSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_update_serialize( + pm_uuid=pm_uuid, + saml_source_property_mapping_request=saml_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_saml_update_serialize( + self, + pm_uuid, + saml_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if saml_source_property_mapping_request is not None: + _body_params = saml_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/source/saml/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_saml_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_source_saml_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_saml_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_source_saml_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_saml_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SAML Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_saml_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SAML Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_saml_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_saml_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/saml/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_scim_create( + self, + scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourcePropertyMapping: + """propertymappings_source_scim_create + + SCIMSourcePropertyMapping Viewset + + :param scim_source_property_mapping_request: (required) + :type scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_create_serialize( + scim_source_property_mapping_request=scim_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_scim_create_with_http_info( + self, + scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourcePropertyMapping]: + """propertymappings_source_scim_create + + SCIMSourcePropertyMapping Viewset + + :param scim_source_property_mapping_request: (required) + :type scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_create_serialize( + scim_source_property_mapping_request=scim_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_scim_create_without_preload_content( + self, + scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_scim_create + + SCIMSourcePropertyMapping Viewset + + :param scim_source_property_mapping_request: (required) + :type scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_create_serialize( + scim_source_property_mapping_request=scim_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_scim_create_serialize( + self, + scim_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_source_property_mapping_request is not None: + _body_params = scim_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/source/scim/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_scim_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_source_scim_destroy + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_scim_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_source_scim_destroy + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_scim_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_scim_destroy + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_scim_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/source/scim/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_scim_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSCIMSourcePropertyMappingList: + """propertymappings_source_scim_list + + SCIMSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_scim_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSCIMSourcePropertyMappingList]: + """propertymappings_source_scim_list + + SCIMSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_scim_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_scim_list + + SCIMSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_scim_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/scim/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_scim_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + patched_scim_source_property_mapping_request: Optional[PatchedSCIMSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourcePropertyMapping: + """propertymappings_source_scim_partial_update + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_scim_source_property_mapping_request: + :type patched_scim_source_property_mapping_request: PatchedSCIMSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_partial_update_serialize( + pm_uuid=pm_uuid, + patched_scim_source_property_mapping_request=patched_scim_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_scim_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + patched_scim_source_property_mapping_request: Optional[PatchedSCIMSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourcePropertyMapping]: + """propertymappings_source_scim_partial_update + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_scim_source_property_mapping_request: + :type patched_scim_source_property_mapping_request: PatchedSCIMSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_partial_update_serialize( + pm_uuid=pm_uuid, + patched_scim_source_property_mapping_request=patched_scim_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_scim_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + patched_scim_source_property_mapping_request: Optional[PatchedSCIMSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_scim_partial_update + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_scim_source_property_mapping_request: + :type patched_scim_source_property_mapping_request: PatchedSCIMSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_partial_update_serialize( + pm_uuid=pm_uuid, + patched_scim_source_property_mapping_request=patched_scim_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_scim_partial_update_serialize( + self, + pm_uuid, + patched_scim_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_scim_source_property_mapping_request is not None: + _body_params = patched_scim_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/source/scim/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_scim_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourcePropertyMapping: + """propertymappings_source_scim_retrieve + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_scim_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourcePropertyMapping]: + """propertymappings_source_scim_retrieve + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_scim_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_scim_retrieve + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_scim_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/scim/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_scim_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourcePropertyMapping: + """propertymappings_source_scim_update + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param scim_source_property_mapping_request: (required) + :type scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_update_serialize( + pm_uuid=pm_uuid, + scim_source_property_mapping_request=scim_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_scim_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourcePropertyMapping]: + """propertymappings_source_scim_update + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param scim_source_property_mapping_request: (required) + :type scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_update_serialize( + pm_uuid=pm_uuid, + scim_source_property_mapping_request=scim_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_scim_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_scim_update + + SCIMSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param scim_source_property_mapping_request: (required) + :type scim_source_property_mapping_request: SCIMSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_update_serialize( + pm_uuid=pm_uuid, + scim_source_property_mapping_request=scim_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_scim_update_serialize( + self, + pm_uuid, + scim_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_source_property_mapping_request is not None: + _body_params = scim_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/source/scim/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_scim_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_source_scim_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_scim_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_source_scim_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_scim_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this SCIM Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_scim_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this SCIM Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_scim_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_scim_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/scim/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_telegram_create( + self, + telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TelegramSourcePropertyMapping: + """propertymappings_source_telegram_create + + TelegramSourcePropertyMapping Viewset + + :param telegram_source_property_mapping_request: (required) + :type telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_create_serialize( + telegram_source_property_mapping_request=telegram_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_telegram_create_with_http_info( + self, + telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TelegramSourcePropertyMapping]: + """propertymappings_source_telegram_create + + TelegramSourcePropertyMapping Viewset + + :param telegram_source_property_mapping_request: (required) + :type telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_create_serialize( + telegram_source_property_mapping_request=telegram_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_telegram_create_without_preload_content( + self, + telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_telegram_create + + TelegramSourcePropertyMapping Viewset + + :param telegram_source_property_mapping_request: (required) + :type telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_create_serialize( + telegram_source_property_mapping_request=telegram_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_telegram_create_serialize( + self, + telegram_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if telegram_source_property_mapping_request is not None: + _body_params = telegram_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/propertymappings/source/telegram/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_telegram_destroy( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """propertymappings_source_telegram_destroy + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_telegram_destroy_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """propertymappings_source_telegram_destroy + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_telegram_destroy_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_telegram_destroy + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_destroy_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_telegram_destroy_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/propertymappings/source/telegram/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_telegram_list( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedTelegramSourcePropertyMappingList: + """propertymappings_source_telegram_list + + TelegramSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTelegramSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_telegram_list_with_http_info( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedTelegramSourcePropertyMappingList]: + """propertymappings_source_telegram_list + + TelegramSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTelegramSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_telegram_list_without_preload_content( + self, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_telegram_list + + TelegramSourcePropertyMapping Viewset + + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_list_serialize( + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTelegramSourcePropertyMappingList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_telegram_list_serialize( + self, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/telegram/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_telegram_partial_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + patched_telegram_source_property_mapping_request: Optional[PatchedTelegramSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TelegramSourcePropertyMapping: + """propertymappings_source_telegram_partial_update + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_telegram_source_property_mapping_request: + :type patched_telegram_source_property_mapping_request: PatchedTelegramSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_partial_update_serialize( + pm_uuid=pm_uuid, + patched_telegram_source_property_mapping_request=patched_telegram_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_telegram_partial_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + patched_telegram_source_property_mapping_request: Optional[PatchedTelegramSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TelegramSourcePropertyMapping]: + """propertymappings_source_telegram_partial_update + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_telegram_source_property_mapping_request: + :type patched_telegram_source_property_mapping_request: PatchedTelegramSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_partial_update_serialize( + pm_uuid=pm_uuid, + patched_telegram_source_property_mapping_request=patched_telegram_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_telegram_partial_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + patched_telegram_source_property_mapping_request: Optional[PatchedTelegramSourcePropertyMappingRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_telegram_partial_update + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param patched_telegram_source_property_mapping_request: + :type patched_telegram_source_property_mapping_request: PatchedTelegramSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_partial_update_serialize( + pm_uuid=pm_uuid, + patched_telegram_source_property_mapping_request=patched_telegram_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_telegram_partial_update_serialize( + self, + pm_uuid, + patched_telegram_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_telegram_source_property_mapping_request is not None: + _body_params = patched_telegram_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/propertymappings/source/telegram/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_telegram_retrieve( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TelegramSourcePropertyMapping: + """propertymappings_source_telegram_retrieve + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_telegram_retrieve_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TelegramSourcePropertyMapping]: + """propertymappings_source_telegram_retrieve + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_telegram_retrieve_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_telegram_retrieve + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_retrieve_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_telegram_retrieve_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/telegram/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_telegram_update( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TelegramSourcePropertyMapping: + """propertymappings_source_telegram_update + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param telegram_source_property_mapping_request: (required) + :type telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_update_serialize( + pm_uuid=pm_uuid, + telegram_source_property_mapping_request=telegram_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_telegram_update_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TelegramSourcePropertyMapping]: + """propertymappings_source_telegram_update + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param telegram_source_property_mapping_request: (required) + :type telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_update_serialize( + pm_uuid=pm_uuid, + telegram_source_property_mapping_request=telegram_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_telegram_update_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_telegram_update + + TelegramSourcePropertyMapping Viewset + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param telegram_source_property_mapping_request: (required) + :type telegram_source_property_mapping_request: TelegramSourcePropertyMappingRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_update_serialize( + pm_uuid=pm_uuid, + telegram_source_property_mapping_request=telegram_source_property_mapping_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSourcePropertyMapping", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_telegram_update_serialize( + self, + pm_uuid, + telegram_source_property_mapping_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if telegram_source_property_mapping_request is not None: + _body_params = telegram_source_property_mapping_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/propertymappings/source/telegram/{pm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def propertymappings_source_telegram_used_by_list( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """propertymappings_source_telegram_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def propertymappings_source_telegram_used_by_list_with_http_info( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """propertymappings_source_telegram_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def propertymappings_source_telegram_used_by_list_without_preload_content( + self, + pm_uuid: Annotated[UUID, Field(description="A UUID string identifying this Telegram Source Property Mapping.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """propertymappings_source_telegram_used_by_list + + Get a list of all objects that use this object + + :param pm_uuid: A UUID string identifying this Telegram Source Property Mapping. (required) + :type pm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._propertymappings_source_telegram_used_by_list_serialize( + pm_uuid=pm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _propertymappings_source_telegram_used_by_list_serialize( + self, + pm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pm_uuid is not None: + _path_params['pm_uuid'] = pm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/propertymappings/source/telegram/{pm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/providers_api.py b/authentik_client/api/providers_api.py new file mode 100644 index 000000000..1bf7b059b --- /dev/null +++ b/authentik_client/api/providers_api.py @@ -0,0 +1,37854 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictBytes, StrictInt, StrictStr +from typing import Any, List, Optional, Tuple, Union +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider +from authentik_client.models.google_workspace_provider_group import GoogleWorkspaceProviderGroup +from authentik_client.models.google_workspace_provider_group_request import GoogleWorkspaceProviderGroupRequest +from authentik_client.models.google_workspace_provider_request import GoogleWorkspaceProviderRequest +from authentik_client.models.google_workspace_provider_user import GoogleWorkspaceProviderUser +from authentik_client.models.google_workspace_provider_user_request import GoogleWorkspaceProviderUserRequest +from authentik_client.models.ldap_provider import LDAPProvider +from authentik_client.models.ldap_provider_request import LDAPProviderRequest +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider +from authentik_client.models.microsoft_entra_provider_group import MicrosoftEntraProviderGroup +from authentik_client.models.microsoft_entra_provider_group_request import MicrosoftEntraProviderGroupRequest +from authentik_client.models.microsoft_entra_provider_request import MicrosoftEntraProviderRequest +from authentik_client.models.microsoft_entra_provider_user import MicrosoftEntraProviderUser +from authentik_client.models.microsoft_entra_provider_user_request import MicrosoftEntraProviderUserRequest +from authentik_client.models.o_auth2_provider import OAuth2Provider +from authentik_client.models.o_auth2_provider_request import OAuth2ProviderRequest +from authentik_client.models.o_auth2_provider_setup_urls import OAuth2ProviderSetupURLs +from authentik_client.models.paginated_google_workspace_provider_group_list import PaginatedGoogleWorkspaceProviderGroupList +from authentik_client.models.paginated_google_workspace_provider_list import PaginatedGoogleWorkspaceProviderList +from authentik_client.models.paginated_google_workspace_provider_user_list import PaginatedGoogleWorkspaceProviderUserList +from authentik_client.models.paginated_ldap_provider_list import PaginatedLDAPProviderList +from authentik_client.models.paginated_microsoft_entra_provider_group_list import PaginatedMicrosoftEntraProviderGroupList +from authentik_client.models.paginated_microsoft_entra_provider_list import PaginatedMicrosoftEntraProviderList +from authentik_client.models.paginated_microsoft_entra_provider_user_list import PaginatedMicrosoftEntraProviderUserList +from authentik_client.models.paginated_o_auth2_provider_list import PaginatedOAuth2ProviderList +from authentik_client.models.paginated_provider_list import PaginatedProviderList +from authentik_client.models.paginated_proxy_provider_list import PaginatedProxyProviderList +from authentik_client.models.paginated_rac_provider_list import PaginatedRACProviderList +from authentik_client.models.paginated_radius_provider_list import PaginatedRadiusProviderList +from authentik_client.models.paginated_saml_provider_list import PaginatedSAMLProviderList +from authentik_client.models.paginated_scim_provider_group_list import PaginatedSCIMProviderGroupList +from authentik_client.models.paginated_scim_provider_list import PaginatedSCIMProviderList +from authentik_client.models.paginated_scim_provider_user_list import PaginatedSCIMProviderUserList +from authentik_client.models.paginated_ssf_provider_list import PaginatedSSFProviderList +from authentik_client.models.paginated_ws_federation_provider_list import PaginatedWSFederationProviderList +from authentik_client.models.patched_google_workspace_provider_request import PatchedGoogleWorkspaceProviderRequest +from authentik_client.models.patched_ldap_provider_request import PatchedLDAPProviderRequest +from authentik_client.models.patched_microsoft_entra_provider_request import PatchedMicrosoftEntraProviderRequest +from authentik_client.models.patched_o_auth2_provider_request import PatchedOAuth2ProviderRequest +from authentik_client.models.patched_proxy_provider_request import PatchedProxyProviderRequest +from authentik_client.models.patched_rac_provider_request import PatchedRACProviderRequest +from authentik_client.models.patched_radius_provider_request import PatchedRadiusProviderRequest +from authentik_client.models.patched_saml_provider_request import PatchedSAMLProviderRequest +from authentik_client.models.patched_scim_provider_request import PatchedSCIMProviderRequest +from authentik_client.models.patched_ssf_provider_request import PatchedSSFProviderRequest +from authentik_client.models.patched_ws_federation_provider_request import PatchedWSFederationProviderRequest +from authentik_client.models.property_mapping_preview import PropertyMappingPreview +from authentik_client.models.provider import Provider +from authentik_client.models.proxy_provider import ProxyProvider +from authentik_client.models.proxy_provider_request import ProxyProviderRequest +from authentik_client.models.rac_provider import RACProvider +from authentik_client.models.rac_provider_request import RACProviderRequest +from authentik_client.models.radius_provider import RadiusProvider +from authentik_client.models.radius_provider_request import RadiusProviderRequest +from authentik_client.models.saml_metadata import SAMLMetadata +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.saml_provider import SAMLProvider +from authentik_client.models.saml_provider_request import SAMLProviderRequest +from authentik_client.models.scim_provider import SCIMProvider +from authentik_client.models.scim_provider_group import SCIMProviderGroup +from authentik_client.models.scim_provider_group_request import SCIMProviderGroupRequest +from authentik_client.models.scim_provider_request import SCIMProviderRequest +from authentik_client.models.scim_provider_user import SCIMProviderUser +from authentik_client.models.scim_provider_user_request import SCIMProviderUserRequest +from authentik_client.models.ssf_provider import SSFProvider +from authentik_client.models.ssf_provider_request import SSFProviderRequest +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from authentik_client.models.sync_object_request import SyncObjectRequest +from authentik_client.models.sync_object_result import SyncObjectResult +from authentik_client.models.sync_status import SyncStatus +from authentik_client.models.type_create import TypeCreate +from authentik_client.models.used_by import UsedBy +from authentik_client.models.ws_federation_provider import WSFederationProvider +from authentik_client.models.ws_federation_provider_request import WSFederationProviderRequest + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class ProvidersApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def providers_all_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_all_destroy + + Provider Viewset + + :param id: A unique integer value identifying this provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_all_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_all_destroy + + Provider Viewset + + :param id: A unique integer value identifying this provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_all_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_all_destroy + + Provider Viewset + + :param id: A unique integer value identifying this provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_all_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_all_list( + self, + application__isnull: Optional[StrictBool] = None, + backchannel: Annotated[Optional[StrictBool], Field(description="When not set all providers are returned. When set to true, only backchannel providers are returned. When set to false, backchannel providers are excluded")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedProviderList: + """providers_all_list + + Provider Viewset + + :param application__isnull: + :type application__isnull: bool + :param backchannel: When not set all providers are returned. When set to true, only backchannel providers are returned. When set to false, backchannel providers are excluded + :type backchannel: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_list_serialize( + application__isnull=application__isnull, + backchannel=backchannel, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_all_list_with_http_info( + self, + application__isnull: Optional[StrictBool] = None, + backchannel: Annotated[Optional[StrictBool], Field(description="When not set all providers are returned. When set to true, only backchannel providers are returned. When set to false, backchannel providers are excluded")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedProviderList]: + """providers_all_list + + Provider Viewset + + :param application__isnull: + :type application__isnull: bool + :param backchannel: When not set all providers are returned. When set to true, only backchannel providers are returned. When set to false, backchannel providers are excluded + :type backchannel: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_list_serialize( + application__isnull=application__isnull, + backchannel=backchannel, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_all_list_without_preload_content( + self, + application__isnull: Optional[StrictBool] = None, + backchannel: Annotated[Optional[StrictBool], Field(description="When not set all providers are returned. When set to true, only backchannel providers are returned. When set to false, backchannel providers are excluded")] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_all_list + + Provider Viewset + + :param application__isnull: + :type application__isnull: bool + :param backchannel: When not set all providers are returned. When set to true, only backchannel providers are returned. When set to false, backchannel providers are excluded + :type backchannel: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_list_serialize( + application__isnull=application__isnull, + backchannel=backchannel, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_all_list_serialize( + self, + application__isnull, + backchannel, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if application__isnull is not None: + + _query_params.append(('application__isnull', application__isnull)) + + if backchannel is not None: + + _query_params.append(('backchannel', backchannel)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_all_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Provider: + """providers_all_retrieve + + Provider Viewset + + :param id: A unique integer value identifying this provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_all_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Provider]: + """providers_all_retrieve + + Provider Viewset + + :param id: A unique integer value identifying this provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_all_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_all_retrieve + + Provider Viewset + + :param id: A unique integer value identifying this provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_all_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_all_types_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[TypeCreate]: + """providers_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_all_types_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[TypeCreate]]: + """providers_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_all_types_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_all_types_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/all/types/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_all_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_all_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_all_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_all_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_all_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_all_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_all_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_all_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/all/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_create( + self, + google_workspace_provider_request: GoogleWorkspaceProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProvider: + """providers_google_workspace_create + + GoogleWorkspaceProvider Viewset + + :param google_workspace_provider_request: (required) + :type google_workspace_provider_request: GoogleWorkspaceProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_create_serialize( + google_workspace_provider_request=google_workspace_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_create_with_http_info( + self, + google_workspace_provider_request: GoogleWorkspaceProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProvider]: + """providers_google_workspace_create + + GoogleWorkspaceProvider Viewset + + :param google_workspace_provider_request: (required) + :type google_workspace_provider_request: GoogleWorkspaceProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_create_serialize( + google_workspace_provider_request=google_workspace_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_create_without_preload_content( + self, + google_workspace_provider_request: GoogleWorkspaceProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_create + + GoogleWorkspaceProvider Viewset + + :param google_workspace_provider_request: (required) + :type google_workspace_provider_request: GoogleWorkspaceProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_create_serialize( + google_workspace_provider_request=google_workspace_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_create_serialize( + self, + google_workspace_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_workspace_provider_request is not None: + _body_params = google_workspace_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/google_workspace/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_google_workspace_destroy + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_google_workspace_destroy + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_destroy + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/google_workspace/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_groups_create( + self, + google_workspace_provider_group_request: GoogleWorkspaceProviderGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProviderGroup: + """providers_google_workspace_groups_create + + GoogleWorkspaceProviderGroup Viewset + + :param google_workspace_provider_group_request: (required) + :type google_workspace_provider_group_request: GoogleWorkspaceProviderGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_create_serialize( + google_workspace_provider_group_request=google_workspace_provider_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_groups_create_with_http_info( + self, + google_workspace_provider_group_request: GoogleWorkspaceProviderGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProviderGroup]: + """providers_google_workspace_groups_create + + GoogleWorkspaceProviderGroup Viewset + + :param google_workspace_provider_group_request: (required) + :type google_workspace_provider_group_request: GoogleWorkspaceProviderGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_create_serialize( + google_workspace_provider_group_request=google_workspace_provider_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_groups_create_without_preload_content( + self, + google_workspace_provider_group_request: GoogleWorkspaceProviderGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_groups_create + + GoogleWorkspaceProviderGroup Viewset + + :param google_workspace_provider_group_request: (required) + :type google_workspace_provider_group_request: GoogleWorkspaceProviderGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_create_serialize( + google_workspace_provider_group_request=google_workspace_provider_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_groups_create_serialize( + self, + google_workspace_provider_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_workspace_provider_group_request is not None: + _body_params = google_workspace_provider_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/google_workspace_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_groups_destroy( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_google_workspace_groups_destroy + + GoogleWorkspaceProviderGroup Viewset + + :param id: A UUID string identifying this Google Workspace Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_groups_destroy_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_google_workspace_groups_destroy + + GoogleWorkspaceProviderGroup Viewset + + :param id: A UUID string identifying this Google Workspace Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_groups_destroy_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_groups_destroy + + GoogleWorkspaceProviderGroup Viewset + + :param id: A UUID string identifying this Google Workspace Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_groups_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/google_workspace_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_groups_list( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGoogleWorkspaceProviderGroupList: + """providers_google_workspace_groups_list + + GoogleWorkspaceProviderGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_groups_list_with_http_info( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGoogleWorkspaceProviderGroupList]: + """providers_google_workspace_groups_list + + GoogleWorkspaceProviderGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_groups_list_without_preload_content( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_groups_list + + GoogleWorkspaceProviderGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_groups_list_serialize( + self, + group__group_uuid, + group__name, + ordering, + page, + page_size, + provider__id, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group__group_uuid is not None: + + _query_params.append(('group__group_uuid', group__group_uuid)) + + if group__name is not None: + + _query_params.append(('group__name', group__name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider__id is not None: + + _query_params.append(('provider__id', provider__id)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_groups_retrieve( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProviderGroup: + """providers_google_workspace_groups_retrieve + + GoogleWorkspaceProviderGroup Viewset + + :param id: A UUID string identifying this Google Workspace Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_groups_retrieve_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProviderGroup]: + """providers_google_workspace_groups_retrieve + + GoogleWorkspaceProviderGroup Viewset + + :param id: A UUID string identifying this Google Workspace Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_groups_retrieve_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_groups_retrieve + + GoogleWorkspaceProviderGroup Viewset + + :param id: A UUID string identifying this Google Workspace Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_groups_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_groups_used_by_list( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_google_workspace_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Google Workspace Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_groups_used_by_list_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_google_workspace_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Google Workspace Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_groups_used_by_list_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Google Workspace Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_groups_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace_groups/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_list( + self, + delegated_subject: Optional[StrictStr] = None, + exclude_users_service_account: Optional[StrictBool] = None, + filter_group: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGoogleWorkspaceProviderList: + """providers_google_workspace_list + + GoogleWorkspaceProvider Viewset + + :param delegated_subject: + :type delegated_subject: str + :param exclude_users_service_account: + :type exclude_users_service_account: bool + :param filter_group: + :type filter_group: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_list_serialize( + delegated_subject=delegated_subject, + exclude_users_service_account=exclude_users_service_account, + filter_group=filter_group, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_list_with_http_info( + self, + delegated_subject: Optional[StrictStr] = None, + exclude_users_service_account: Optional[StrictBool] = None, + filter_group: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGoogleWorkspaceProviderList]: + """providers_google_workspace_list + + GoogleWorkspaceProvider Viewset + + :param delegated_subject: + :type delegated_subject: str + :param exclude_users_service_account: + :type exclude_users_service_account: bool + :param filter_group: + :type filter_group: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_list_serialize( + delegated_subject=delegated_subject, + exclude_users_service_account=exclude_users_service_account, + filter_group=filter_group, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_list_without_preload_content( + self, + delegated_subject: Optional[StrictStr] = None, + exclude_users_service_account: Optional[StrictBool] = None, + filter_group: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_list + + GoogleWorkspaceProvider Viewset + + :param delegated_subject: + :type delegated_subject: str + :param exclude_users_service_account: + :type exclude_users_service_account: bool + :param filter_group: + :type filter_group: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_list_serialize( + delegated_subject=delegated_subject, + exclude_users_service_account=exclude_users_service_account, + filter_group=filter_group, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_list_serialize( + self, + delegated_subject, + exclude_users_service_account, + filter_group, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if delegated_subject is not None: + + _query_params.append(('delegated_subject', delegated_subject)) + + if exclude_users_service_account is not None: + + _query_params.append(('exclude_users_service_account', exclude_users_service_account)) + + if filter_group is not None: + + _query_params.append(('filter_group', filter_group)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + patched_google_workspace_provider_request: Optional[PatchedGoogleWorkspaceProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProvider: + """providers_google_workspace_partial_update + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param patched_google_workspace_provider_request: + :type patched_google_workspace_provider_request: PatchedGoogleWorkspaceProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_partial_update_serialize( + id=id, + patched_google_workspace_provider_request=patched_google_workspace_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + patched_google_workspace_provider_request: Optional[PatchedGoogleWorkspaceProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProvider]: + """providers_google_workspace_partial_update + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param patched_google_workspace_provider_request: + :type patched_google_workspace_provider_request: PatchedGoogleWorkspaceProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_partial_update_serialize( + id=id, + patched_google_workspace_provider_request=patched_google_workspace_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + patched_google_workspace_provider_request: Optional[PatchedGoogleWorkspaceProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_partial_update + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param patched_google_workspace_provider_request: + :type patched_google_workspace_provider_request: PatchedGoogleWorkspaceProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_partial_update_serialize( + id=id, + patched_google_workspace_provider_request=patched_google_workspace_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_partial_update_serialize( + self, + id, + patched_google_workspace_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_google_workspace_provider_request is not None: + _body_params = patched_google_workspace_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/google_workspace/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProvider: + """providers_google_workspace_retrieve + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProvider]: + """providers_google_workspace_retrieve + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_retrieve + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_sync_object_create( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + sync_object_request: SyncObjectRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SyncObjectResult: + """providers_google_workspace_sync_object_create + + Sync/Re-sync a single user/group object + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param sync_object_request: (required) + :type sync_object_request: SyncObjectRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_sync_object_create_serialize( + id=id, + sync_object_request=sync_object_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncObjectResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_sync_object_create_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + sync_object_request: SyncObjectRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SyncObjectResult]: + """providers_google_workspace_sync_object_create + + Sync/Re-sync a single user/group object + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param sync_object_request: (required) + :type sync_object_request: SyncObjectRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_sync_object_create_serialize( + id=id, + sync_object_request=sync_object_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncObjectResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_sync_object_create_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + sync_object_request: SyncObjectRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_sync_object_create + + Sync/Re-sync a single user/group object + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param sync_object_request: (required) + :type sync_object_request: SyncObjectRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_sync_object_create_serialize( + id=id, + sync_object_request=sync_object_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncObjectResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_sync_object_create_serialize( + self, + id, + sync_object_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if sync_object_request is not None: + _body_params = sync_object_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/google_workspace/{id}/sync/object/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_sync_status_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SyncStatus: + """providers_google_workspace_sync_status_retrieve + + Get provider's sync status + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_sync_status_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_sync_status_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SyncStatus]: + """providers_google_workspace_sync_status_retrieve + + Get provider's sync status + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_sync_status_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_sync_status_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_sync_status_retrieve + + Get provider's sync status + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_sync_status_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_sync_status_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace/{id}/sync/status/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + google_workspace_provider_request: GoogleWorkspaceProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProvider: + """providers_google_workspace_update + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param google_workspace_provider_request: (required) + :type google_workspace_provider_request: GoogleWorkspaceProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_update_serialize( + id=id, + google_workspace_provider_request=google_workspace_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + google_workspace_provider_request: GoogleWorkspaceProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProvider]: + """providers_google_workspace_update + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param google_workspace_provider_request: (required) + :type google_workspace_provider_request: GoogleWorkspaceProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_update_serialize( + id=id, + google_workspace_provider_request=google_workspace_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + google_workspace_provider_request: GoogleWorkspaceProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_update + + GoogleWorkspaceProvider Viewset + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param google_workspace_provider_request: (required) + :type google_workspace_provider_request: GoogleWorkspaceProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_update_serialize( + id=id, + google_workspace_provider_request=google_workspace_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_update_serialize( + self, + id, + google_workspace_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_workspace_provider_request is not None: + _body_params = google_workspace_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/google_workspace/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_google_workspace_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_google_workspace_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Google Workspace Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Google Workspace Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_users_create( + self, + google_workspace_provider_user_request: GoogleWorkspaceProviderUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProviderUser: + """providers_google_workspace_users_create + + GoogleWorkspaceProviderUser Viewset + + :param google_workspace_provider_user_request: (required) + :type google_workspace_provider_user_request: GoogleWorkspaceProviderUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_create_serialize( + google_workspace_provider_user_request=google_workspace_provider_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_users_create_with_http_info( + self, + google_workspace_provider_user_request: GoogleWorkspaceProviderUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProviderUser]: + """providers_google_workspace_users_create + + GoogleWorkspaceProviderUser Viewset + + :param google_workspace_provider_user_request: (required) + :type google_workspace_provider_user_request: GoogleWorkspaceProviderUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_create_serialize( + google_workspace_provider_user_request=google_workspace_provider_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_users_create_without_preload_content( + self, + google_workspace_provider_user_request: GoogleWorkspaceProviderUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_users_create + + GoogleWorkspaceProviderUser Viewset + + :param google_workspace_provider_user_request: (required) + :type google_workspace_provider_user_request: GoogleWorkspaceProviderUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_create_serialize( + google_workspace_provider_user_request=google_workspace_provider_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GoogleWorkspaceProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_users_create_serialize( + self, + google_workspace_provider_user_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if google_workspace_provider_user_request is not None: + _body_params = google_workspace_provider_user_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/google_workspace_users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_users_destroy( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_google_workspace_users_destroy + + GoogleWorkspaceProviderUser Viewset + + :param id: A UUID string identifying this Google Workspace Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_users_destroy_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_google_workspace_users_destroy + + GoogleWorkspaceProviderUser Viewset + + :param id: A UUID string identifying this Google Workspace Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_users_destroy_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_users_destroy + + GoogleWorkspaceProviderUser Viewset + + :param id: A UUID string identifying this Google Workspace Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_users_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/google_workspace_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_users_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGoogleWorkspaceProviderUserList: + """providers_google_workspace_users_list + + GoogleWorkspaceProviderUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_users_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGoogleWorkspaceProviderUserList]: + """providers_google_workspace_users_list + + GoogleWorkspaceProviderUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_users_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_users_list + + GoogleWorkspaceProviderUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGoogleWorkspaceProviderUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_users_list_serialize( + self, + ordering, + page, + page_size, + provider__id, + search, + user__id, + user__username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider__id is not None: + + _query_params.append(('provider__id', provider__id)) + + if search is not None: + + _query_params.append(('search', search)) + + if user__id is not None: + + _query_params.append(('user__id', user__id)) + + if user__username is not None: + + _query_params.append(('user__username', user__username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace_users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_users_retrieve( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GoogleWorkspaceProviderUser: + """providers_google_workspace_users_retrieve + + GoogleWorkspaceProviderUser Viewset + + :param id: A UUID string identifying this Google Workspace Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_users_retrieve_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GoogleWorkspaceProviderUser]: + """providers_google_workspace_users_retrieve + + GoogleWorkspaceProviderUser Viewset + + :param id: A UUID string identifying this Google Workspace Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_users_retrieve_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_users_retrieve + + GoogleWorkspaceProviderUser Viewset + + :param id: A UUID string identifying this Google Workspace Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GoogleWorkspaceProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_users_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_google_workspace_users_used_by_list( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_google_workspace_users_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Google Workspace Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_google_workspace_users_used_by_list_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_google_workspace_users_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Google Workspace Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_google_workspace_users_used_by_list_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Google Workspace Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_google_workspace_users_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Google Workspace Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_google_workspace_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_google_workspace_users_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/google_workspace_users/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ldap_create( + self, + ldap_provider_request: LDAPProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPProvider: + """providers_ldap_create + + LDAPProvider Viewset + + :param ldap_provider_request: (required) + :type ldap_provider_request: LDAPProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_create_serialize( + ldap_provider_request=ldap_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ldap_create_with_http_info( + self, + ldap_provider_request: LDAPProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPProvider]: + """providers_ldap_create + + LDAPProvider Viewset + + :param ldap_provider_request: (required) + :type ldap_provider_request: LDAPProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_create_serialize( + ldap_provider_request=ldap_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ldap_create_without_preload_content( + self, + ldap_provider_request: LDAPProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ldap_create + + LDAPProvider Viewset + + :param ldap_provider_request: (required) + :type ldap_provider_request: LDAPProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_create_serialize( + ldap_provider_request=ldap_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ldap_create_serialize( + self, + ldap_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ldap_provider_request is not None: + _body_params = ldap_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ldap_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_ldap_destroy + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ldap_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_ldap_destroy + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ldap_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ldap_destroy + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ldap_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ldap_list( + self, + application__isnull: Optional[StrictBool] = None, + authorization_flow__slug__iexact: Optional[StrictStr] = None, + base_dn__iexact: Optional[StrictStr] = None, + certificate__kp_uuid__iexact: Optional[UUID] = None, + certificate__name__iexact: Optional[StrictStr] = None, + gid_start_number__iexact: Optional[StrictInt] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + tls_server_name__iexact: Optional[StrictStr] = None, + uid_start_number__iexact: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedLDAPProviderList: + """providers_ldap_list + + LDAPProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param authorization_flow__slug__iexact: + :type authorization_flow__slug__iexact: str + :param base_dn__iexact: + :type base_dn__iexact: str + :param certificate__kp_uuid__iexact: + :type certificate__kp_uuid__iexact: UUID + :param certificate__name__iexact: + :type certificate__name__iexact: str + :param gid_start_number__iexact: + :type gid_start_number__iexact: int + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param tls_server_name__iexact: + :type tls_server_name__iexact: str + :param uid_start_number__iexact: + :type uid_start_number__iexact: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_list_serialize( + application__isnull=application__isnull, + authorization_flow__slug__iexact=authorization_flow__slug__iexact, + base_dn__iexact=base_dn__iexact, + certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, + certificate__name__iexact=certificate__name__iexact, + gid_start_number__iexact=gid_start_number__iexact, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + tls_server_name__iexact=tls_server_name__iexact, + uid_start_number__iexact=uid_start_number__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ldap_list_with_http_info( + self, + application__isnull: Optional[StrictBool] = None, + authorization_flow__slug__iexact: Optional[StrictStr] = None, + base_dn__iexact: Optional[StrictStr] = None, + certificate__kp_uuid__iexact: Optional[UUID] = None, + certificate__name__iexact: Optional[StrictStr] = None, + gid_start_number__iexact: Optional[StrictInt] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + tls_server_name__iexact: Optional[StrictStr] = None, + uid_start_number__iexact: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedLDAPProviderList]: + """providers_ldap_list + + LDAPProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param authorization_flow__slug__iexact: + :type authorization_flow__slug__iexact: str + :param base_dn__iexact: + :type base_dn__iexact: str + :param certificate__kp_uuid__iexact: + :type certificate__kp_uuid__iexact: UUID + :param certificate__name__iexact: + :type certificate__name__iexact: str + :param gid_start_number__iexact: + :type gid_start_number__iexact: int + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param tls_server_name__iexact: + :type tls_server_name__iexact: str + :param uid_start_number__iexact: + :type uid_start_number__iexact: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_list_serialize( + application__isnull=application__isnull, + authorization_flow__slug__iexact=authorization_flow__slug__iexact, + base_dn__iexact=base_dn__iexact, + certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, + certificate__name__iexact=certificate__name__iexact, + gid_start_number__iexact=gid_start_number__iexact, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + tls_server_name__iexact=tls_server_name__iexact, + uid_start_number__iexact=uid_start_number__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ldap_list_without_preload_content( + self, + application__isnull: Optional[StrictBool] = None, + authorization_flow__slug__iexact: Optional[StrictStr] = None, + base_dn__iexact: Optional[StrictStr] = None, + certificate__kp_uuid__iexact: Optional[UUID] = None, + certificate__name__iexact: Optional[StrictStr] = None, + gid_start_number__iexact: Optional[StrictInt] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + tls_server_name__iexact: Optional[StrictStr] = None, + uid_start_number__iexact: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ldap_list + + LDAPProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param authorization_flow__slug__iexact: + :type authorization_flow__slug__iexact: str + :param base_dn__iexact: + :type base_dn__iexact: str + :param certificate__kp_uuid__iexact: + :type certificate__kp_uuid__iexact: UUID + :param certificate__name__iexact: + :type certificate__name__iexact: str + :param gid_start_number__iexact: + :type gid_start_number__iexact: int + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param tls_server_name__iexact: + :type tls_server_name__iexact: str + :param uid_start_number__iexact: + :type uid_start_number__iexact: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_list_serialize( + application__isnull=application__isnull, + authorization_flow__slug__iexact=authorization_flow__slug__iexact, + base_dn__iexact=base_dn__iexact, + certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, + certificate__name__iexact=certificate__name__iexact, + gid_start_number__iexact=gid_start_number__iexact, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + tls_server_name__iexact=tls_server_name__iexact, + uid_start_number__iexact=uid_start_number__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ldap_list_serialize( + self, + application__isnull, + authorization_flow__slug__iexact, + base_dn__iexact, + certificate__kp_uuid__iexact, + certificate__name__iexact, + gid_start_number__iexact, + name__iexact, + ordering, + page, + page_size, + search, + tls_server_name__iexact, + uid_start_number__iexact, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if application__isnull is not None: + + _query_params.append(('application__isnull', application__isnull)) + + if authorization_flow__slug__iexact is not None: + + _query_params.append(('authorization_flow__slug__iexact', authorization_flow__slug__iexact)) + + if base_dn__iexact is not None: + + _query_params.append(('base_dn__iexact', base_dn__iexact)) + + if certificate__kp_uuid__iexact is not None: + + _query_params.append(('certificate__kp_uuid__iexact', certificate__kp_uuid__iexact)) + + if certificate__name__iexact is not None: + + _query_params.append(('certificate__name__iexact', certificate__name__iexact)) + + if gid_start_number__iexact is not None: + + _query_params.append(('gid_start_number__iexact', gid_start_number__iexact)) + + if name__iexact is not None: + + _query_params.append(('name__iexact', name__iexact)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if tls_server_name__iexact is not None: + + _query_params.append(('tls_server_name__iexact', tls_server_name__iexact)) + + if uid_start_number__iexact is not None: + + _query_params.append(('uid_start_number__iexact', uid_start_number__iexact)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ldap_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + patched_ldap_provider_request: Optional[PatchedLDAPProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPProvider: + """providers_ldap_partial_update + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param patched_ldap_provider_request: + :type patched_ldap_provider_request: PatchedLDAPProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_partial_update_serialize( + id=id, + patched_ldap_provider_request=patched_ldap_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ldap_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + patched_ldap_provider_request: Optional[PatchedLDAPProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPProvider]: + """providers_ldap_partial_update + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param patched_ldap_provider_request: + :type patched_ldap_provider_request: PatchedLDAPProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_partial_update_serialize( + id=id, + patched_ldap_provider_request=patched_ldap_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ldap_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + patched_ldap_provider_request: Optional[PatchedLDAPProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ldap_partial_update + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param patched_ldap_provider_request: + :type patched_ldap_provider_request: PatchedLDAPProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_partial_update_serialize( + id=id, + patched_ldap_provider_request=patched_ldap_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ldap_partial_update_serialize( + self, + id, + patched_ldap_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_ldap_provider_request is not None: + _body_params = patched_ldap_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ldap_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPProvider: + """providers_ldap_retrieve + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ldap_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPProvider]: + """providers_ldap_retrieve + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ldap_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ldap_retrieve + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ldap_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ldap_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + ldap_provider_request: LDAPProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPProvider: + """providers_ldap_update + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param ldap_provider_request: (required) + :type ldap_provider_request: LDAPProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_update_serialize( + id=id, + ldap_provider_request=ldap_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ldap_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + ldap_provider_request: LDAPProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPProvider]: + """providers_ldap_update + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param ldap_provider_request: (required) + :type ldap_provider_request: LDAPProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_update_serialize( + id=id, + ldap_provider_request=ldap_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ldap_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + ldap_provider_request: LDAPProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ldap_update + + LDAPProvider Viewset + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param ldap_provider_request: (required) + :type ldap_provider_request: LDAPProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_update_serialize( + id=id, + ldap_provider_request=ldap_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ldap_update_serialize( + self, + id, + ldap_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ldap_provider_request is not None: + _body_params = ldap_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ldap_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_ldap_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ldap_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_ldap_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ldap_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this LDAP Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ldap_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this LDAP Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ldap_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ldap_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/ldap/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_create( + self, + microsoft_entra_provider_request: MicrosoftEntraProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProvider: + """providers_microsoft_entra_create + + MicrosoftEntraProvider Viewset + + :param microsoft_entra_provider_request: (required) + :type microsoft_entra_provider_request: MicrosoftEntraProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_create_serialize( + microsoft_entra_provider_request=microsoft_entra_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_create_with_http_info( + self, + microsoft_entra_provider_request: MicrosoftEntraProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProvider]: + """providers_microsoft_entra_create + + MicrosoftEntraProvider Viewset + + :param microsoft_entra_provider_request: (required) + :type microsoft_entra_provider_request: MicrosoftEntraProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_create_serialize( + microsoft_entra_provider_request=microsoft_entra_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_create_without_preload_content( + self, + microsoft_entra_provider_request: MicrosoftEntraProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_create + + MicrosoftEntraProvider Viewset + + :param microsoft_entra_provider_request: (required) + :type microsoft_entra_provider_request: MicrosoftEntraProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_create_serialize( + microsoft_entra_provider_request=microsoft_entra_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_create_serialize( + self, + microsoft_entra_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if microsoft_entra_provider_request is not None: + _body_params = microsoft_entra_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/microsoft_entra/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_microsoft_entra_destroy + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_microsoft_entra_destroy + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_destroy + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/microsoft_entra/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_groups_create( + self, + microsoft_entra_provider_group_request: MicrosoftEntraProviderGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProviderGroup: + """providers_microsoft_entra_groups_create + + MicrosoftEntraProviderGroup Viewset + + :param microsoft_entra_provider_group_request: (required) + :type microsoft_entra_provider_group_request: MicrosoftEntraProviderGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_create_serialize( + microsoft_entra_provider_group_request=microsoft_entra_provider_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_groups_create_with_http_info( + self, + microsoft_entra_provider_group_request: MicrosoftEntraProviderGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProviderGroup]: + """providers_microsoft_entra_groups_create + + MicrosoftEntraProviderGroup Viewset + + :param microsoft_entra_provider_group_request: (required) + :type microsoft_entra_provider_group_request: MicrosoftEntraProviderGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_create_serialize( + microsoft_entra_provider_group_request=microsoft_entra_provider_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_groups_create_without_preload_content( + self, + microsoft_entra_provider_group_request: MicrosoftEntraProviderGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_groups_create + + MicrosoftEntraProviderGroup Viewset + + :param microsoft_entra_provider_group_request: (required) + :type microsoft_entra_provider_group_request: MicrosoftEntraProviderGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_create_serialize( + microsoft_entra_provider_group_request=microsoft_entra_provider_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_groups_create_serialize( + self, + microsoft_entra_provider_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if microsoft_entra_provider_group_request is not None: + _body_params = microsoft_entra_provider_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/microsoft_entra_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_groups_destroy( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_microsoft_entra_groups_destroy + + MicrosoftEntraProviderGroup Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_groups_destroy_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_microsoft_entra_groups_destroy + + MicrosoftEntraProviderGroup Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_groups_destroy_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_groups_destroy + + MicrosoftEntraProviderGroup Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_groups_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/microsoft_entra_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_groups_list( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedMicrosoftEntraProviderGroupList: + """providers_microsoft_entra_groups_list + + MicrosoftEntraProviderGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_groups_list_with_http_info( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedMicrosoftEntraProviderGroupList]: + """providers_microsoft_entra_groups_list + + MicrosoftEntraProviderGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_groups_list_without_preload_content( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_groups_list + + MicrosoftEntraProviderGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_groups_list_serialize( + self, + group__group_uuid, + group__name, + ordering, + page, + page_size, + provider__id, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group__group_uuid is not None: + + _query_params.append(('group__group_uuid', group__group_uuid)) + + if group__name is not None: + + _query_params.append(('group__name', group__name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider__id is not None: + + _query_params.append(('provider__id', provider__id)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_groups_retrieve( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProviderGroup: + """providers_microsoft_entra_groups_retrieve + + MicrosoftEntraProviderGroup Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_groups_retrieve_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProviderGroup]: + """providers_microsoft_entra_groups_retrieve + + MicrosoftEntraProviderGroup Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_groups_retrieve_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_groups_retrieve + + MicrosoftEntraProviderGroup Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_groups_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_groups_used_by_list( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_microsoft_entra_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Microsoft Entra Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_groups_used_by_list_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_microsoft_entra_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Microsoft Entra Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_groups_used_by_list_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider Group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Microsoft Entra Provider Group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_groups_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra_groups/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_list( + self, + exclude_users_service_account: Optional[StrictBool] = None, + filter_group: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedMicrosoftEntraProviderList: + """providers_microsoft_entra_list + + MicrosoftEntraProvider Viewset + + :param exclude_users_service_account: + :type exclude_users_service_account: bool + :param filter_group: + :type filter_group: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_list_serialize( + exclude_users_service_account=exclude_users_service_account, + filter_group=filter_group, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_list_with_http_info( + self, + exclude_users_service_account: Optional[StrictBool] = None, + filter_group: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedMicrosoftEntraProviderList]: + """providers_microsoft_entra_list + + MicrosoftEntraProvider Viewset + + :param exclude_users_service_account: + :type exclude_users_service_account: bool + :param filter_group: + :type filter_group: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_list_serialize( + exclude_users_service_account=exclude_users_service_account, + filter_group=filter_group, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_list_without_preload_content( + self, + exclude_users_service_account: Optional[StrictBool] = None, + filter_group: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_list + + MicrosoftEntraProvider Viewset + + :param exclude_users_service_account: + :type exclude_users_service_account: bool + :param filter_group: + :type filter_group: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_list_serialize( + exclude_users_service_account=exclude_users_service_account, + filter_group=filter_group, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_list_serialize( + self, + exclude_users_service_account, + filter_group, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if exclude_users_service_account is not None: + + _query_params.append(('exclude_users_service_account', exclude_users_service_account)) + + if filter_group is not None: + + _query_params.append(('filter_group', filter_group)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + patched_microsoft_entra_provider_request: Optional[PatchedMicrosoftEntraProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProvider: + """providers_microsoft_entra_partial_update + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param patched_microsoft_entra_provider_request: + :type patched_microsoft_entra_provider_request: PatchedMicrosoftEntraProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_partial_update_serialize( + id=id, + patched_microsoft_entra_provider_request=patched_microsoft_entra_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + patched_microsoft_entra_provider_request: Optional[PatchedMicrosoftEntraProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProvider]: + """providers_microsoft_entra_partial_update + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param patched_microsoft_entra_provider_request: + :type patched_microsoft_entra_provider_request: PatchedMicrosoftEntraProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_partial_update_serialize( + id=id, + patched_microsoft_entra_provider_request=patched_microsoft_entra_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + patched_microsoft_entra_provider_request: Optional[PatchedMicrosoftEntraProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_partial_update + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param patched_microsoft_entra_provider_request: + :type patched_microsoft_entra_provider_request: PatchedMicrosoftEntraProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_partial_update_serialize( + id=id, + patched_microsoft_entra_provider_request=patched_microsoft_entra_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_partial_update_serialize( + self, + id, + patched_microsoft_entra_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_microsoft_entra_provider_request is not None: + _body_params = patched_microsoft_entra_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/microsoft_entra/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProvider: + """providers_microsoft_entra_retrieve + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProvider]: + """providers_microsoft_entra_retrieve + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_retrieve + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_sync_object_create( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + sync_object_request: SyncObjectRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SyncObjectResult: + """providers_microsoft_entra_sync_object_create + + Sync/Re-sync a single user/group object + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param sync_object_request: (required) + :type sync_object_request: SyncObjectRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_sync_object_create_serialize( + id=id, + sync_object_request=sync_object_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncObjectResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_sync_object_create_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + sync_object_request: SyncObjectRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SyncObjectResult]: + """providers_microsoft_entra_sync_object_create + + Sync/Re-sync a single user/group object + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param sync_object_request: (required) + :type sync_object_request: SyncObjectRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_sync_object_create_serialize( + id=id, + sync_object_request=sync_object_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncObjectResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_sync_object_create_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + sync_object_request: SyncObjectRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_sync_object_create + + Sync/Re-sync a single user/group object + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param sync_object_request: (required) + :type sync_object_request: SyncObjectRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_sync_object_create_serialize( + id=id, + sync_object_request=sync_object_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncObjectResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_sync_object_create_serialize( + self, + id, + sync_object_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if sync_object_request is not None: + _body_params = sync_object_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/microsoft_entra/{id}/sync/object/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_sync_status_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SyncStatus: + """providers_microsoft_entra_sync_status_retrieve + + Get provider's sync status + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_sync_status_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_sync_status_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SyncStatus]: + """providers_microsoft_entra_sync_status_retrieve + + Get provider's sync status + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_sync_status_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_sync_status_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_sync_status_retrieve + + Get provider's sync status + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_sync_status_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_sync_status_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra/{id}/sync/status/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + microsoft_entra_provider_request: MicrosoftEntraProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProvider: + """providers_microsoft_entra_update + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param microsoft_entra_provider_request: (required) + :type microsoft_entra_provider_request: MicrosoftEntraProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_update_serialize( + id=id, + microsoft_entra_provider_request=microsoft_entra_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + microsoft_entra_provider_request: MicrosoftEntraProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProvider]: + """providers_microsoft_entra_update + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param microsoft_entra_provider_request: (required) + :type microsoft_entra_provider_request: MicrosoftEntraProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_update_serialize( + id=id, + microsoft_entra_provider_request=microsoft_entra_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + microsoft_entra_provider_request: MicrosoftEntraProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_update + + MicrosoftEntraProvider Viewset + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param microsoft_entra_provider_request: (required) + :type microsoft_entra_provider_request: MicrosoftEntraProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_update_serialize( + id=id, + microsoft_entra_provider_request=microsoft_entra_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_update_serialize( + self, + id, + microsoft_entra_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if microsoft_entra_provider_request is not None: + _body_params = microsoft_entra_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/microsoft_entra/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_microsoft_entra_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_microsoft_entra_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Microsoft Entra Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Microsoft Entra Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_users_create( + self, + microsoft_entra_provider_user_request: MicrosoftEntraProviderUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProviderUser: + """providers_microsoft_entra_users_create + + MicrosoftEntraProviderUser Viewset + + :param microsoft_entra_provider_user_request: (required) + :type microsoft_entra_provider_user_request: MicrosoftEntraProviderUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_create_serialize( + microsoft_entra_provider_user_request=microsoft_entra_provider_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_users_create_with_http_info( + self, + microsoft_entra_provider_user_request: MicrosoftEntraProviderUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProviderUser]: + """providers_microsoft_entra_users_create + + MicrosoftEntraProviderUser Viewset + + :param microsoft_entra_provider_user_request: (required) + :type microsoft_entra_provider_user_request: MicrosoftEntraProviderUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_create_serialize( + microsoft_entra_provider_user_request=microsoft_entra_provider_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_users_create_without_preload_content( + self, + microsoft_entra_provider_user_request: MicrosoftEntraProviderUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_users_create + + MicrosoftEntraProviderUser Viewset + + :param microsoft_entra_provider_user_request: (required) + :type microsoft_entra_provider_user_request: MicrosoftEntraProviderUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_create_serialize( + microsoft_entra_provider_user_request=microsoft_entra_provider_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MicrosoftEntraProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_users_create_serialize( + self, + microsoft_entra_provider_user_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if microsoft_entra_provider_user_request is not None: + _body_params = microsoft_entra_provider_user_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/microsoft_entra_users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_users_destroy( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_microsoft_entra_users_destroy + + MicrosoftEntraProviderUser Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_users_destroy_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_microsoft_entra_users_destroy + + MicrosoftEntraProviderUser Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_users_destroy_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_users_destroy + + MicrosoftEntraProviderUser Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_users_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/microsoft_entra_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_users_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedMicrosoftEntraProviderUserList: + """providers_microsoft_entra_users_list + + MicrosoftEntraProviderUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_users_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedMicrosoftEntraProviderUserList]: + """providers_microsoft_entra_users_list + + MicrosoftEntraProviderUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_users_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_users_list + + MicrosoftEntraProviderUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMicrosoftEntraProviderUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_users_list_serialize( + self, + ordering, + page, + page_size, + provider__id, + search, + user__id, + user__username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider__id is not None: + + _query_params.append(('provider__id', provider__id)) + + if search is not None: + + _query_params.append(('search', search)) + + if user__id is not None: + + _query_params.append(('user__id', user__id)) + + if user__username is not None: + + _query_params.append(('user__username', user__username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra_users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_users_retrieve( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MicrosoftEntraProviderUser: + """providers_microsoft_entra_users_retrieve + + MicrosoftEntraProviderUser Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_users_retrieve_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MicrosoftEntraProviderUser]: + """providers_microsoft_entra_users_retrieve + + MicrosoftEntraProviderUser Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_users_retrieve_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_users_retrieve + + MicrosoftEntraProviderUser Viewset + + :param id: A UUID string identifying this Microsoft Entra Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MicrosoftEntraProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_users_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_microsoft_entra_users_used_by_list( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_microsoft_entra_users_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Microsoft Entra Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_microsoft_entra_users_used_by_list_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_microsoft_entra_users_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Microsoft Entra Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_microsoft_entra_users_used_by_list_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Microsoft Entra Provider User.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_microsoft_entra_users_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this Microsoft Entra Provider User. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_microsoft_entra_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_microsoft_entra_users_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/microsoft_entra_users/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_oauth2_create( + self, + o_auth2_provider_request: OAuth2ProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuth2Provider: + """providers_oauth2_create + + OAuth2Provider Viewset + + :param o_auth2_provider_request: (required) + :type o_auth2_provider_request: OAuth2ProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_create_serialize( + o_auth2_provider_request=o_auth2_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_oauth2_create_with_http_info( + self, + o_auth2_provider_request: OAuth2ProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuth2Provider]: + """providers_oauth2_create + + OAuth2Provider Viewset + + :param o_auth2_provider_request: (required) + :type o_auth2_provider_request: OAuth2ProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_create_serialize( + o_auth2_provider_request=o_auth2_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_oauth2_create_without_preload_content( + self, + o_auth2_provider_request: OAuth2ProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_oauth2_create + + OAuth2Provider Viewset + + :param o_auth2_provider_request: (required) + :type o_auth2_provider_request: OAuth2ProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_create_serialize( + o_auth2_provider_request=o_auth2_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_oauth2_create_serialize( + self, + o_auth2_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if o_auth2_provider_request is not None: + _body_params = o_auth2_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/oauth2/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_oauth2_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_oauth2_destroy + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_oauth2_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_oauth2_destroy + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_oauth2_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_oauth2_destroy + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_oauth2_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/oauth2/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_oauth2_list( + self, + access_code_validity: Optional[StrictStr] = None, + access_token_validity: Optional[StrictStr] = None, + application: Optional[UUID] = None, + authorization_flow: Optional[UUID] = None, + client_id: Optional[StrictStr] = None, + client_type: Optional[Any] = None, + include_claims_in_id_token: Optional[StrictBool] = None, + issuer_mode: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings: Optional[List[UUID]] = None, + refresh_token_validity: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + signing_key: Optional[UUID] = None, + sub_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedOAuth2ProviderList: + """providers_oauth2_list + + OAuth2Provider Viewset + + :param access_code_validity: + :type access_code_validity: str + :param access_token_validity: + :type access_token_validity: str + :param application: + :type application: UUID + :param authorization_flow: + :type authorization_flow: UUID + :param client_id: + :type client_id: str + :param client_type: + :type client_type: ClientTypeEnum + :param include_claims_in_id_token: + :type include_claims_in_id_token: bool + :param issuer_mode: + :type issuer_mode: IssuerModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings: + :type property_mappings: List[UUID] + :param refresh_token_validity: + :type refresh_token_validity: str + :param search: A search term. + :type search: str + :param signing_key: + :type signing_key: UUID + :param sub_mode: + :type sub_mode: SubModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_list_serialize( + access_code_validity=access_code_validity, + access_token_validity=access_token_validity, + application=application, + authorization_flow=authorization_flow, + client_id=client_id, + client_type=client_type, + include_claims_in_id_token=include_claims_in_id_token, + issuer_mode=issuer_mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings=property_mappings, + refresh_token_validity=refresh_token_validity, + search=search, + signing_key=signing_key, + sub_mode=sub_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOAuth2ProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_oauth2_list_with_http_info( + self, + access_code_validity: Optional[StrictStr] = None, + access_token_validity: Optional[StrictStr] = None, + application: Optional[UUID] = None, + authorization_flow: Optional[UUID] = None, + client_id: Optional[StrictStr] = None, + client_type: Optional[Any] = None, + include_claims_in_id_token: Optional[StrictBool] = None, + issuer_mode: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings: Optional[List[UUID]] = None, + refresh_token_validity: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + signing_key: Optional[UUID] = None, + sub_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedOAuth2ProviderList]: + """providers_oauth2_list + + OAuth2Provider Viewset + + :param access_code_validity: + :type access_code_validity: str + :param access_token_validity: + :type access_token_validity: str + :param application: + :type application: UUID + :param authorization_flow: + :type authorization_flow: UUID + :param client_id: + :type client_id: str + :param client_type: + :type client_type: ClientTypeEnum + :param include_claims_in_id_token: + :type include_claims_in_id_token: bool + :param issuer_mode: + :type issuer_mode: IssuerModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings: + :type property_mappings: List[UUID] + :param refresh_token_validity: + :type refresh_token_validity: str + :param search: A search term. + :type search: str + :param signing_key: + :type signing_key: UUID + :param sub_mode: + :type sub_mode: SubModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_list_serialize( + access_code_validity=access_code_validity, + access_token_validity=access_token_validity, + application=application, + authorization_flow=authorization_flow, + client_id=client_id, + client_type=client_type, + include_claims_in_id_token=include_claims_in_id_token, + issuer_mode=issuer_mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings=property_mappings, + refresh_token_validity=refresh_token_validity, + search=search, + signing_key=signing_key, + sub_mode=sub_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOAuth2ProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_oauth2_list_without_preload_content( + self, + access_code_validity: Optional[StrictStr] = None, + access_token_validity: Optional[StrictStr] = None, + application: Optional[UUID] = None, + authorization_flow: Optional[UUID] = None, + client_id: Optional[StrictStr] = None, + client_type: Optional[Any] = None, + include_claims_in_id_token: Optional[StrictBool] = None, + issuer_mode: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings: Optional[List[UUID]] = None, + refresh_token_validity: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + signing_key: Optional[UUID] = None, + sub_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_oauth2_list + + OAuth2Provider Viewset + + :param access_code_validity: + :type access_code_validity: str + :param access_token_validity: + :type access_token_validity: str + :param application: + :type application: UUID + :param authorization_flow: + :type authorization_flow: UUID + :param client_id: + :type client_id: str + :param client_type: + :type client_type: ClientTypeEnum + :param include_claims_in_id_token: + :type include_claims_in_id_token: bool + :param issuer_mode: + :type issuer_mode: IssuerModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings: + :type property_mappings: List[UUID] + :param refresh_token_validity: + :type refresh_token_validity: str + :param search: A search term. + :type search: str + :param signing_key: + :type signing_key: UUID + :param sub_mode: + :type sub_mode: SubModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_list_serialize( + access_code_validity=access_code_validity, + access_token_validity=access_token_validity, + application=application, + authorization_flow=authorization_flow, + client_id=client_id, + client_type=client_type, + include_claims_in_id_token=include_claims_in_id_token, + issuer_mode=issuer_mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings=property_mappings, + refresh_token_validity=refresh_token_validity, + search=search, + signing_key=signing_key, + sub_mode=sub_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOAuth2ProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_oauth2_list_serialize( + self, + access_code_validity, + access_token_validity, + application, + authorization_flow, + client_id, + client_type, + include_claims_in_id_token, + issuer_mode, + name, + ordering, + page, + page_size, + property_mappings, + refresh_token_validity, + search, + signing_key, + sub_mode, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'property_mappings': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if access_code_validity is not None: + + _query_params.append(('access_code_validity', access_code_validity)) + + if access_token_validity is not None: + + _query_params.append(('access_token_validity', access_token_validity)) + + if application is not None: + + _query_params.append(('application', application)) + + if authorization_flow is not None: + + _query_params.append(('authorization_flow', authorization_flow)) + + if client_id is not None: + + _query_params.append(('client_id', client_id)) + + if client_type is not None: + + _query_params.append(('client_type', client_type.value)) + + if include_claims_in_id_token is not None: + + _query_params.append(('include_claims_in_id_token', include_claims_in_id_token)) + + if issuer_mode is not None: + + _query_params.append(('issuer_mode', issuer_mode.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if property_mappings is not None: + + _query_params.append(('property_mappings', property_mappings)) + + if refresh_token_validity is not None: + + _query_params.append(('refresh_token_validity', refresh_token_validity)) + + if search is not None: + + _query_params.append(('search', search)) + + if signing_key is not None: + + _query_params.append(('signing_key', signing_key)) + + if sub_mode is not None: + + _query_params.append(('sub_mode', sub_mode.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/oauth2/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_oauth2_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + patched_o_auth2_provider_request: Optional[PatchedOAuth2ProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuth2Provider: + """providers_oauth2_partial_update + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param patched_o_auth2_provider_request: + :type patched_o_auth2_provider_request: PatchedOAuth2ProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_partial_update_serialize( + id=id, + patched_o_auth2_provider_request=patched_o_auth2_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_oauth2_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + patched_o_auth2_provider_request: Optional[PatchedOAuth2ProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuth2Provider]: + """providers_oauth2_partial_update + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param patched_o_auth2_provider_request: + :type patched_o_auth2_provider_request: PatchedOAuth2ProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_partial_update_serialize( + id=id, + patched_o_auth2_provider_request=patched_o_auth2_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_oauth2_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + patched_o_auth2_provider_request: Optional[PatchedOAuth2ProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_oauth2_partial_update + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param patched_o_auth2_provider_request: + :type patched_o_auth2_provider_request: PatchedOAuth2ProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_partial_update_serialize( + id=id, + patched_o_auth2_provider_request=patched_o_auth2_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_oauth2_partial_update_serialize( + self, + id, + patched_o_auth2_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_o_auth2_provider_request is not None: + _body_params = patched_o_auth2_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/oauth2/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_oauth2_preview_user_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PropertyMappingPreview: + """providers_oauth2_preview_user_retrieve + + Preview user data for provider + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_preview_user_retrieve_serialize( + id=id, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingPreview", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_oauth2_preview_user_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PropertyMappingPreview]: + """providers_oauth2_preview_user_retrieve + + Preview user data for provider + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_preview_user_retrieve_serialize( + id=id, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingPreview", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_oauth2_preview_user_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_oauth2_preview_user_retrieve + + Preview user data for provider + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_preview_user_retrieve_serialize( + id=id, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingPreview", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_oauth2_preview_user_retrieve_serialize( + self, + id, + for_user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + if for_user is not None: + + _query_params.append(('for_user', for_user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/oauth2/{id}/preview_user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_oauth2_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuth2Provider: + """providers_oauth2_retrieve + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_oauth2_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuth2Provider]: + """providers_oauth2_retrieve + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_oauth2_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_oauth2_retrieve + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_oauth2_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/oauth2/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_oauth2_setup_urls_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuth2ProviderSetupURLs: + """providers_oauth2_setup_urls_retrieve + + Get Providers setup URLs + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_setup_urls_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2ProviderSetupURLs", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_oauth2_setup_urls_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuth2ProviderSetupURLs]: + """providers_oauth2_setup_urls_retrieve + + Get Providers setup URLs + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_setup_urls_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2ProviderSetupURLs", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_oauth2_setup_urls_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_oauth2_setup_urls_retrieve + + Get Providers setup URLs + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_setup_urls_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2ProviderSetupURLs", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_oauth2_setup_urls_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/oauth2/{id}/setup_urls/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_oauth2_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + o_auth2_provider_request: OAuth2ProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuth2Provider: + """providers_oauth2_update + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param o_auth2_provider_request: (required) + :type o_auth2_provider_request: OAuth2ProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_update_serialize( + id=id, + o_auth2_provider_request=o_auth2_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_oauth2_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + o_auth2_provider_request: OAuth2ProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuth2Provider]: + """providers_oauth2_update + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param o_auth2_provider_request: (required) + :type o_auth2_provider_request: OAuth2ProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_update_serialize( + id=id, + o_auth2_provider_request=o_auth2_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_oauth2_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + o_auth2_provider_request: OAuth2ProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_oauth2_update + + OAuth2Provider Viewset + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param o_auth2_provider_request: (required) + :type o_auth2_provider_request: OAuth2ProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_update_serialize( + id=id, + o_auth2_provider_request=o_auth2_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuth2Provider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_oauth2_update_serialize( + self, + id, + o_auth2_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if o_auth2_provider_request is not None: + _body_params = o_auth2_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/oauth2/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_oauth2_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_oauth2_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_oauth2_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_oauth2_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_oauth2_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this OAuth2/OpenID Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_oauth2_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this OAuth2/OpenID Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_oauth2_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_oauth2_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/oauth2/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_proxy_create( + self, + proxy_provider_request: ProxyProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ProxyProvider: + """providers_proxy_create + + ProxyProvider Viewset + + :param proxy_provider_request: (required) + :type proxy_provider_request: ProxyProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_create_serialize( + proxy_provider_request=proxy_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_proxy_create_with_http_info( + self, + proxy_provider_request: ProxyProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ProxyProvider]: + """providers_proxy_create + + ProxyProvider Viewset + + :param proxy_provider_request: (required) + :type proxy_provider_request: ProxyProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_create_serialize( + proxy_provider_request=proxy_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_proxy_create_without_preload_content( + self, + proxy_provider_request: ProxyProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_proxy_create + + ProxyProvider Viewset + + :param proxy_provider_request: (required) + :type proxy_provider_request: ProxyProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_create_serialize( + proxy_provider_request=proxy_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_proxy_create_serialize( + self, + proxy_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if proxy_provider_request is not None: + _body_params = proxy_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/proxy/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_proxy_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_proxy_destroy + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_proxy_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_proxy_destroy + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_proxy_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_proxy_destroy + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_proxy_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/proxy/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_proxy_list( + self, + application__isnull: Optional[StrictBool] = None, + authorization_flow__slug__iexact: Optional[StrictStr] = None, + basic_auth_enabled__iexact: Optional[StrictBool] = None, + basic_auth_password_attribute__iexact: Optional[StrictStr] = None, + basic_auth_user_attribute__iexact: Optional[StrictStr] = None, + certificate__kp_uuid__iexact: Optional[UUID] = None, + certificate__name__iexact: Optional[StrictStr] = None, + cookie_domain__iexact: Optional[StrictStr] = None, + external_host__iexact: Optional[StrictStr] = None, + internal_host__iexact: Optional[StrictStr] = None, + internal_host_ssl_validation__iexact: Optional[StrictBool] = None, + mode__iexact: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings__iexact: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + skip_path_regex__iexact: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedProxyProviderList: + """providers_proxy_list + + ProxyProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param authorization_flow__slug__iexact: + :type authorization_flow__slug__iexact: str + :param basic_auth_enabled__iexact: + :type basic_auth_enabled__iexact: bool + :param basic_auth_password_attribute__iexact: + :type basic_auth_password_attribute__iexact: str + :param basic_auth_user_attribute__iexact: + :type basic_auth_user_attribute__iexact: str + :param certificate__kp_uuid__iexact: + :type certificate__kp_uuid__iexact: UUID + :param certificate__name__iexact: + :type certificate__name__iexact: str + :param cookie_domain__iexact: + :type cookie_domain__iexact: str + :param external_host__iexact: + :type external_host__iexact: str + :param internal_host__iexact: + :type internal_host__iexact: str + :param internal_host_ssl_validation__iexact: + :type internal_host_ssl_validation__iexact: bool + :param mode__iexact: + :type mode__iexact: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings__iexact: + :type property_mappings__iexact: List[UUID] + :param search: A search term. + :type search: str + :param skip_path_regex__iexact: + :type skip_path_regex__iexact: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_list_serialize( + application__isnull=application__isnull, + authorization_flow__slug__iexact=authorization_flow__slug__iexact, + basic_auth_enabled__iexact=basic_auth_enabled__iexact, + basic_auth_password_attribute__iexact=basic_auth_password_attribute__iexact, + basic_auth_user_attribute__iexact=basic_auth_user_attribute__iexact, + certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, + certificate__name__iexact=certificate__name__iexact, + cookie_domain__iexact=cookie_domain__iexact, + external_host__iexact=external_host__iexact, + internal_host__iexact=internal_host__iexact, + internal_host_ssl_validation__iexact=internal_host_ssl_validation__iexact, + mode__iexact=mode__iexact, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings__iexact=property_mappings__iexact, + search=search, + skip_path_regex__iexact=skip_path_regex__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedProxyProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_proxy_list_with_http_info( + self, + application__isnull: Optional[StrictBool] = None, + authorization_flow__slug__iexact: Optional[StrictStr] = None, + basic_auth_enabled__iexact: Optional[StrictBool] = None, + basic_auth_password_attribute__iexact: Optional[StrictStr] = None, + basic_auth_user_attribute__iexact: Optional[StrictStr] = None, + certificate__kp_uuid__iexact: Optional[UUID] = None, + certificate__name__iexact: Optional[StrictStr] = None, + cookie_domain__iexact: Optional[StrictStr] = None, + external_host__iexact: Optional[StrictStr] = None, + internal_host__iexact: Optional[StrictStr] = None, + internal_host_ssl_validation__iexact: Optional[StrictBool] = None, + mode__iexact: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings__iexact: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + skip_path_regex__iexact: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedProxyProviderList]: + """providers_proxy_list + + ProxyProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param authorization_flow__slug__iexact: + :type authorization_flow__slug__iexact: str + :param basic_auth_enabled__iexact: + :type basic_auth_enabled__iexact: bool + :param basic_auth_password_attribute__iexact: + :type basic_auth_password_attribute__iexact: str + :param basic_auth_user_attribute__iexact: + :type basic_auth_user_attribute__iexact: str + :param certificate__kp_uuid__iexact: + :type certificate__kp_uuid__iexact: UUID + :param certificate__name__iexact: + :type certificate__name__iexact: str + :param cookie_domain__iexact: + :type cookie_domain__iexact: str + :param external_host__iexact: + :type external_host__iexact: str + :param internal_host__iexact: + :type internal_host__iexact: str + :param internal_host_ssl_validation__iexact: + :type internal_host_ssl_validation__iexact: bool + :param mode__iexact: + :type mode__iexact: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings__iexact: + :type property_mappings__iexact: List[UUID] + :param search: A search term. + :type search: str + :param skip_path_regex__iexact: + :type skip_path_regex__iexact: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_list_serialize( + application__isnull=application__isnull, + authorization_flow__slug__iexact=authorization_flow__slug__iexact, + basic_auth_enabled__iexact=basic_auth_enabled__iexact, + basic_auth_password_attribute__iexact=basic_auth_password_attribute__iexact, + basic_auth_user_attribute__iexact=basic_auth_user_attribute__iexact, + certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, + certificate__name__iexact=certificate__name__iexact, + cookie_domain__iexact=cookie_domain__iexact, + external_host__iexact=external_host__iexact, + internal_host__iexact=internal_host__iexact, + internal_host_ssl_validation__iexact=internal_host_ssl_validation__iexact, + mode__iexact=mode__iexact, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings__iexact=property_mappings__iexact, + search=search, + skip_path_regex__iexact=skip_path_regex__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedProxyProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_proxy_list_without_preload_content( + self, + application__isnull: Optional[StrictBool] = None, + authorization_flow__slug__iexact: Optional[StrictStr] = None, + basic_auth_enabled__iexact: Optional[StrictBool] = None, + basic_auth_password_attribute__iexact: Optional[StrictStr] = None, + basic_auth_user_attribute__iexact: Optional[StrictStr] = None, + certificate__kp_uuid__iexact: Optional[UUID] = None, + certificate__name__iexact: Optional[StrictStr] = None, + cookie_domain__iexact: Optional[StrictStr] = None, + external_host__iexact: Optional[StrictStr] = None, + internal_host__iexact: Optional[StrictStr] = None, + internal_host_ssl_validation__iexact: Optional[StrictBool] = None, + mode__iexact: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings__iexact: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + skip_path_regex__iexact: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_proxy_list + + ProxyProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param authorization_flow__slug__iexact: + :type authorization_flow__slug__iexact: str + :param basic_auth_enabled__iexact: + :type basic_auth_enabled__iexact: bool + :param basic_auth_password_attribute__iexact: + :type basic_auth_password_attribute__iexact: str + :param basic_auth_user_attribute__iexact: + :type basic_auth_user_attribute__iexact: str + :param certificate__kp_uuid__iexact: + :type certificate__kp_uuid__iexact: UUID + :param certificate__name__iexact: + :type certificate__name__iexact: str + :param cookie_domain__iexact: + :type cookie_domain__iexact: str + :param external_host__iexact: + :type external_host__iexact: str + :param internal_host__iexact: + :type internal_host__iexact: str + :param internal_host_ssl_validation__iexact: + :type internal_host_ssl_validation__iexact: bool + :param mode__iexact: + :type mode__iexact: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings__iexact: + :type property_mappings__iexact: List[UUID] + :param search: A search term. + :type search: str + :param skip_path_regex__iexact: + :type skip_path_regex__iexact: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_list_serialize( + application__isnull=application__isnull, + authorization_flow__slug__iexact=authorization_flow__slug__iexact, + basic_auth_enabled__iexact=basic_auth_enabled__iexact, + basic_auth_password_attribute__iexact=basic_auth_password_attribute__iexact, + basic_auth_user_attribute__iexact=basic_auth_user_attribute__iexact, + certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, + certificate__name__iexact=certificate__name__iexact, + cookie_domain__iexact=cookie_domain__iexact, + external_host__iexact=external_host__iexact, + internal_host__iexact=internal_host__iexact, + internal_host_ssl_validation__iexact=internal_host_ssl_validation__iexact, + mode__iexact=mode__iexact, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings__iexact=property_mappings__iexact, + search=search, + skip_path_regex__iexact=skip_path_regex__iexact, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedProxyProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_proxy_list_serialize( + self, + application__isnull, + authorization_flow__slug__iexact, + basic_auth_enabled__iexact, + basic_auth_password_attribute__iexact, + basic_auth_user_attribute__iexact, + certificate__kp_uuid__iexact, + certificate__name__iexact, + cookie_domain__iexact, + external_host__iexact, + internal_host__iexact, + internal_host_ssl_validation__iexact, + mode__iexact, + name__iexact, + ordering, + page, + page_size, + property_mappings__iexact, + search, + skip_path_regex__iexact, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'property_mappings__iexact': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if application__isnull is not None: + + _query_params.append(('application__isnull', application__isnull)) + + if authorization_flow__slug__iexact is not None: + + _query_params.append(('authorization_flow__slug__iexact', authorization_flow__slug__iexact)) + + if basic_auth_enabled__iexact is not None: + + _query_params.append(('basic_auth_enabled__iexact', basic_auth_enabled__iexact)) + + if basic_auth_password_attribute__iexact is not None: + + _query_params.append(('basic_auth_password_attribute__iexact', basic_auth_password_attribute__iexact)) + + if basic_auth_user_attribute__iexact is not None: + + _query_params.append(('basic_auth_user_attribute__iexact', basic_auth_user_attribute__iexact)) + + if certificate__kp_uuid__iexact is not None: + + _query_params.append(('certificate__kp_uuid__iexact', certificate__kp_uuid__iexact)) + + if certificate__name__iexact is not None: + + _query_params.append(('certificate__name__iexact', certificate__name__iexact)) + + if cookie_domain__iexact is not None: + + _query_params.append(('cookie_domain__iexact', cookie_domain__iexact)) + + if external_host__iexact is not None: + + _query_params.append(('external_host__iexact', external_host__iexact)) + + if internal_host__iexact is not None: + + _query_params.append(('internal_host__iexact', internal_host__iexact)) + + if internal_host_ssl_validation__iexact is not None: + + _query_params.append(('internal_host_ssl_validation__iexact', internal_host_ssl_validation__iexact)) + + if mode__iexact is not None: + + _query_params.append(('mode__iexact', mode__iexact)) + + if name__iexact is not None: + + _query_params.append(('name__iexact', name__iexact)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if property_mappings__iexact is not None: + + _query_params.append(('property_mappings__iexact', property_mappings__iexact)) + + if search is not None: + + _query_params.append(('search', search)) + + if skip_path_regex__iexact is not None: + + _query_params.append(('skip_path_regex__iexact', skip_path_regex__iexact)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/proxy/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_proxy_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + patched_proxy_provider_request: Optional[PatchedProxyProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ProxyProvider: + """providers_proxy_partial_update + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param patched_proxy_provider_request: + :type patched_proxy_provider_request: PatchedProxyProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_partial_update_serialize( + id=id, + patched_proxy_provider_request=patched_proxy_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_proxy_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + patched_proxy_provider_request: Optional[PatchedProxyProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ProxyProvider]: + """providers_proxy_partial_update + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param patched_proxy_provider_request: + :type patched_proxy_provider_request: PatchedProxyProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_partial_update_serialize( + id=id, + patched_proxy_provider_request=patched_proxy_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_proxy_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + patched_proxy_provider_request: Optional[PatchedProxyProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_proxy_partial_update + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param patched_proxy_provider_request: + :type patched_proxy_provider_request: PatchedProxyProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_partial_update_serialize( + id=id, + patched_proxy_provider_request=patched_proxy_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_proxy_partial_update_serialize( + self, + id, + patched_proxy_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_proxy_provider_request is not None: + _body_params = patched_proxy_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/proxy/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_proxy_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ProxyProvider: + """providers_proxy_retrieve + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_proxy_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ProxyProvider]: + """providers_proxy_retrieve + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_proxy_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_proxy_retrieve + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_proxy_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/proxy/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_proxy_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + proxy_provider_request: ProxyProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ProxyProvider: + """providers_proxy_update + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param proxy_provider_request: (required) + :type proxy_provider_request: ProxyProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_update_serialize( + id=id, + proxy_provider_request=proxy_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_proxy_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + proxy_provider_request: ProxyProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ProxyProvider]: + """providers_proxy_update + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param proxy_provider_request: (required) + :type proxy_provider_request: ProxyProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_update_serialize( + id=id, + proxy_provider_request=proxy_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_proxy_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + proxy_provider_request: ProxyProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_proxy_update + + ProxyProvider Viewset + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param proxy_provider_request: (required) + :type proxy_provider_request: ProxyProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_update_serialize( + id=id, + proxy_provider_request=proxy_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ProxyProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_proxy_update_serialize( + self, + id, + proxy_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if proxy_provider_request is not None: + _body_params = proxy_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/proxy/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_proxy_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_proxy_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_proxy_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_proxy_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_proxy_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Proxy Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_proxy_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Proxy Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_proxy_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_proxy_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/proxy/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_rac_create( + self, + rac_provider_request: RACProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RACProvider: + """providers_rac_create + + RACProvider Viewset + + :param rac_provider_request: (required) + :type rac_provider_request: RACProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_create_serialize( + rac_provider_request=rac_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_rac_create_with_http_info( + self, + rac_provider_request: RACProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RACProvider]: + """providers_rac_create + + RACProvider Viewset + + :param rac_provider_request: (required) + :type rac_provider_request: RACProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_create_serialize( + rac_provider_request=rac_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_rac_create_without_preload_content( + self, + rac_provider_request: RACProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_rac_create + + RACProvider Viewset + + :param rac_provider_request: (required) + :type rac_provider_request: RACProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_create_serialize( + rac_provider_request=rac_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_rac_create_serialize( + self, + rac_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if rac_provider_request is not None: + _body_params = rac_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/rac/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_rac_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_rac_destroy + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_rac_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_rac_destroy + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_rac_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_rac_destroy + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_rac_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/rac/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_rac_list( + self, + application__isnull: Optional[StrictBool] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedRACProviderList: + """providers_rac_list + + RACProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_list_serialize( + application__isnull=application__isnull, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRACProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_rac_list_with_http_info( + self, + application__isnull: Optional[StrictBool] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedRACProviderList]: + """providers_rac_list + + RACProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_list_serialize( + application__isnull=application__isnull, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRACProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_rac_list_without_preload_content( + self, + application__isnull: Optional[StrictBool] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_rac_list + + RACProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_list_serialize( + application__isnull=application__isnull, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRACProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_rac_list_serialize( + self, + application__isnull, + name__iexact, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if application__isnull is not None: + + _query_params.append(('application__isnull', application__isnull)) + + if name__iexact is not None: + + _query_params.append(('name__iexact', name__iexact)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/rac/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_rac_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + patched_rac_provider_request: Optional[PatchedRACProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RACProvider: + """providers_rac_partial_update + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param patched_rac_provider_request: + :type patched_rac_provider_request: PatchedRACProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_partial_update_serialize( + id=id, + patched_rac_provider_request=patched_rac_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_rac_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + patched_rac_provider_request: Optional[PatchedRACProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RACProvider]: + """providers_rac_partial_update + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param patched_rac_provider_request: + :type patched_rac_provider_request: PatchedRACProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_partial_update_serialize( + id=id, + patched_rac_provider_request=patched_rac_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_rac_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + patched_rac_provider_request: Optional[PatchedRACProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_rac_partial_update + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param patched_rac_provider_request: + :type patched_rac_provider_request: PatchedRACProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_partial_update_serialize( + id=id, + patched_rac_provider_request=patched_rac_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_rac_partial_update_serialize( + self, + id, + patched_rac_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_rac_provider_request is not None: + _body_params = patched_rac_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/rac/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_rac_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RACProvider: + """providers_rac_retrieve + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_rac_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RACProvider]: + """providers_rac_retrieve + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_rac_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_rac_retrieve + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_rac_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/rac/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_rac_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + rac_provider_request: RACProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RACProvider: + """providers_rac_update + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param rac_provider_request: (required) + :type rac_provider_request: RACProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_update_serialize( + id=id, + rac_provider_request=rac_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_rac_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + rac_provider_request: RACProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RACProvider]: + """providers_rac_update + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param rac_provider_request: (required) + :type rac_provider_request: RACProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_update_serialize( + id=id, + rac_provider_request=rac_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_rac_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + rac_provider_request: RACProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_rac_update + + RACProvider Viewset + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param rac_provider_request: (required) + :type rac_provider_request: RACProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_update_serialize( + id=id, + rac_provider_request=rac_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RACProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_rac_update_serialize( + self, + id, + rac_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if rac_provider_request is not None: + _body_params = rac_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/rac/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_rac_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_rac_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_rac_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_rac_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_rac_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this RAC Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_rac_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this RAC Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_rac_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_rac_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/rac/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_radius_create( + self, + radius_provider_request: RadiusProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RadiusProvider: + """providers_radius_create + + RadiusProvider Viewset + + :param radius_provider_request: (required) + :type radius_provider_request: RadiusProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_create_serialize( + radius_provider_request=radius_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_radius_create_with_http_info( + self, + radius_provider_request: RadiusProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RadiusProvider]: + """providers_radius_create + + RadiusProvider Viewset + + :param radius_provider_request: (required) + :type radius_provider_request: RadiusProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_create_serialize( + radius_provider_request=radius_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_radius_create_without_preload_content( + self, + radius_provider_request: RadiusProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_radius_create + + RadiusProvider Viewset + + :param radius_provider_request: (required) + :type radius_provider_request: RadiusProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_create_serialize( + radius_provider_request=radius_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_radius_create_serialize( + self, + radius_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if radius_provider_request is not None: + _body_params = radius_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/radius/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_radius_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_radius_destroy + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_radius_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_radius_destroy + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_radius_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_radius_destroy + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_radius_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/radius/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_radius_list( + self, + application__isnull: Optional[StrictBool] = None, + authorization_flow__slug__iexact: Optional[StrictStr] = None, + client_networks__iexact: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedRadiusProviderList: + """providers_radius_list + + RadiusProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param authorization_flow__slug__iexact: + :type authorization_flow__slug__iexact: str + :param client_networks__iexact: + :type client_networks__iexact: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_list_serialize( + application__isnull=application__isnull, + authorization_flow__slug__iexact=authorization_flow__slug__iexact, + client_networks__iexact=client_networks__iexact, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRadiusProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_radius_list_with_http_info( + self, + application__isnull: Optional[StrictBool] = None, + authorization_flow__slug__iexact: Optional[StrictStr] = None, + client_networks__iexact: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedRadiusProviderList]: + """providers_radius_list + + RadiusProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param authorization_flow__slug__iexact: + :type authorization_flow__slug__iexact: str + :param client_networks__iexact: + :type client_networks__iexact: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_list_serialize( + application__isnull=application__isnull, + authorization_flow__slug__iexact=authorization_flow__slug__iexact, + client_networks__iexact=client_networks__iexact, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRadiusProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_radius_list_without_preload_content( + self, + application__isnull: Optional[StrictBool] = None, + authorization_flow__slug__iexact: Optional[StrictStr] = None, + client_networks__iexact: Optional[StrictStr] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_radius_list + + RadiusProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param authorization_flow__slug__iexact: + :type authorization_flow__slug__iexact: str + :param client_networks__iexact: + :type client_networks__iexact: str + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_list_serialize( + application__isnull=application__isnull, + authorization_flow__slug__iexact=authorization_flow__slug__iexact, + client_networks__iexact=client_networks__iexact, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRadiusProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_radius_list_serialize( + self, + application__isnull, + authorization_flow__slug__iexact, + client_networks__iexact, + name__iexact, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if application__isnull is not None: + + _query_params.append(('application__isnull', application__isnull)) + + if authorization_flow__slug__iexact is not None: + + _query_params.append(('authorization_flow__slug__iexact', authorization_flow__slug__iexact)) + + if client_networks__iexact is not None: + + _query_params.append(('client_networks__iexact', client_networks__iexact)) + + if name__iexact is not None: + + _query_params.append(('name__iexact', name__iexact)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/radius/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_radius_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + patched_radius_provider_request: Optional[PatchedRadiusProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RadiusProvider: + """providers_radius_partial_update + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param patched_radius_provider_request: + :type patched_radius_provider_request: PatchedRadiusProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_partial_update_serialize( + id=id, + patched_radius_provider_request=patched_radius_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_radius_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + patched_radius_provider_request: Optional[PatchedRadiusProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RadiusProvider]: + """providers_radius_partial_update + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param patched_radius_provider_request: + :type patched_radius_provider_request: PatchedRadiusProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_partial_update_serialize( + id=id, + patched_radius_provider_request=patched_radius_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_radius_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + patched_radius_provider_request: Optional[PatchedRadiusProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_radius_partial_update + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param patched_radius_provider_request: + :type patched_radius_provider_request: PatchedRadiusProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_partial_update_serialize( + id=id, + patched_radius_provider_request=patched_radius_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_radius_partial_update_serialize( + self, + id, + patched_radius_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_radius_provider_request is not None: + _body_params = patched_radius_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/radius/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_radius_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RadiusProvider: + """providers_radius_retrieve + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_radius_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RadiusProvider]: + """providers_radius_retrieve + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_radius_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_radius_retrieve + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_radius_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/radius/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_radius_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + radius_provider_request: RadiusProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RadiusProvider: + """providers_radius_update + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param radius_provider_request: (required) + :type radius_provider_request: RadiusProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_update_serialize( + id=id, + radius_provider_request=radius_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_radius_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + radius_provider_request: RadiusProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RadiusProvider]: + """providers_radius_update + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param radius_provider_request: (required) + :type radius_provider_request: RadiusProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_update_serialize( + id=id, + radius_provider_request=radius_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_radius_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + radius_provider_request: RadiusProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_radius_update + + RadiusProvider Viewset + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param radius_provider_request: (required) + :type radius_provider_request: RadiusProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_update_serialize( + id=id, + radius_provider_request=radius_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RadiusProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_radius_update_serialize( + self, + id, + radius_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if radius_provider_request is not None: + _body_params = radius_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/radius/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_radius_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_radius_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_radius_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_radius_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_radius_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Radius Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_radius_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Radius Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_radius_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_radius_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/radius/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_create( + self, + saml_provider_request: SAMLProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLProvider: + """providers_saml_create + + SAMLProvider Viewset + + :param saml_provider_request: (required) + :type saml_provider_request: SAMLProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_create_serialize( + saml_provider_request=saml_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_create_with_http_info( + self, + saml_provider_request: SAMLProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLProvider]: + """providers_saml_create + + SAMLProvider Viewset + + :param saml_provider_request: (required) + :type saml_provider_request: SAMLProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_create_serialize( + saml_provider_request=saml_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_create_without_preload_content( + self, + saml_provider_request: SAMLProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_create + + SAMLProvider Viewset + + :param saml_provider_request: (required) + :type saml_provider_request: SAMLProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_create_serialize( + saml_provider_request=saml_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_create_serialize( + self, + saml_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if saml_provider_request is not None: + _body_params = saml_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_saml_destroy + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_saml_destroy + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_destroy + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_import_metadata_create( + self, + name: Annotated[str, Field(min_length=1, strict=True)], + authorization_flow: UUID, + invalidation_flow: UUID, + file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLProvider: + """providers_saml_import_metadata_create + + Create provider from SAML Metadata + + :param name: (required) + :type name: str + :param authorization_flow: (required) + :type authorization_flow: UUID + :param invalidation_flow: (required) + :type invalidation_flow: UUID + :param file: (required) + :type file: bytes + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_import_metadata_create_serialize( + name=name, + authorization_flow=authorization_flow, + invalidation_flow=invalidation_flow, + file=file, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLProvider", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_import_metadata_create_with_http_info( + self, + name: Annotated[str, Field(min_length=1, strict=True)], + authorization_flow: UUID, + invalidation_flow: UUID, + file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLProvider]: + """providers_saml_import_metadata_create + + Create provider from SAML Metadata + + :param name: (required) + :type name: str + :param authorization_flow: (required) + :type authorization_flow: UUID + :param invalidation_flow: (required) + :type invalidation_flow: UUID + :param file: (required) + :type file: bytes + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_import_metadata_create_serialize( + name=name, + authorization_flow=authorization_flow, + invalidation_flow=invalidation_flow, + file=file, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLProvider", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_import_metadata_create_without_preload_content( + self, + name: Annotated[str, Field(min_length=1, strict=True)], + authorization_flow: UUID, + invalidation_flow: UUID, + file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_import_metadata_create + + Create provider from SAML Metadata + + :param name: (required) + :type name: str + :param authorization_flow: (required) + :type authorization_flow: UUID + :param invalidation_flow: (required) + :type invalidation_flow: UUID + :param file: (required) + :type file: bytes + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_import_metadata_create_serialize( + name=name, + authorization_flow=authorization_flow, + invalidation_flow=invalidation_flow, + file=file, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLProvider", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_import_metadata_create_serialize( + self, + name, + authorization_flow, + invalidation_flow, + file, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + if name is not None: + _form_params.append(('name', name)) + if authorization_flow is not None: + _form_params.append(('authorization_flow', authorization_flow)) + if invalidation_flow is not None: + _form_params.append(('invalidation_flow', invalidation_flow)) + if file is not None: + _files['file'] = file + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'multipart/form-data' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/saml/import_metadata/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_list( + self, + acs_url: Optional[StrictStr] = None, + assertion_valid_not_before: Optional[StrictStr] = None, + assertion_valid_not_on_or_after: Optional[StrictStr] = None, + audience: Optional[StrictStr] = None, + authentication_flow: Optional[UUID] = None, + authn_context_class_ref_mapping: Optional[UUID] = None, + authorization_flow: Optional[UUID] = None, + backchannel_application: Optional[UUID] = None, + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None, + default_relay_state: Optional[StrictStr] = None, + digest_algorithm: Optional[DigestAlgorithmEnum] = None, + encryption_kp: Optional[UUID] = None, + invalidation_flow: Optional[UUID] = None, + is_backchannel: Optional[StrictBool] = None, + issuer_override: Optional[StrictStr] = None, + logout_method: Optional[Any] = None, + name: Optional[StrictStr] = None, + name_id_mapping: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session_valid_not_on_or_after: Optional[StrictStr] = None, + sign_assertion: Optional[StrictBool] = None, + sign_logout_request: Optional[StrictBool] = None, + sign_logout_response: Optional[StrictBool] = None, + sign_response: Optional[StrictBool] = None, + signature_algorithm: Optional[SignatureAlgorithmEnum] = None, + signing_kp: Optional[UUID] = None, + sls_binding: Optional[Any] = None, + sls_url: Optional[StrictStr] = None, + sp_binding: Optional[Any] = None, + verification_kp: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSAMLProviderList: + """providers_saml_list + + SAMLProvider Viewset + + :param acs_url: + :type acs_url: str + :param assertion_valid_not_before: + :type assertion_valid_not_before: str + :param assertion_valid_not_on_or_after: + :type assertion_valid_not_on_or_after: str + :param audience: + :type audience: str + :param authentication_flow: + :type authentication_flow: UUID + :param authn_context_class_ref_mapping: + :type authn_context_class_ref_mapping: UUID + :param authorization_flow: + :type authorization_flow: UUID + :param backchannel_application: + :type backchannel_application: UUID + :param default_name_id_policy: + :type default_name_id_policy: SAMLNameIDPolicyEnum + :param default_relay_state: + :type default_relay_state: str + :param digest_algorithm: + :type digest_algorithm: DigestAlgorithmEnum + :param encryption_kp: + :type encryption_kp: UUID + :param invalidation_flow: + :type invalidation_flow: UUID + :param is_backchannel: + :type is_backchannel: bool + :param issuer_override: + :type issuer_override: str + :param logout_method: + :type logout_method: SAMLLogoutMethods + :param name: + :type name: str + :param name_id_mapping: + :type name_id_mapping: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings: + :type property_mappings: List[UUID] + :param search: A search term. + :type search: str + :param session_valid_not_on_or_after: + :type session_valid_not_on_or_after: str + :param sign_assertion: + :type sign_assertion: bool + :param sign_logout_request: + :type sign_logout_request: bool + :param sign_logout_response: + :type sign_logout_response: bool + :param sign_response: + :type sign_response: bool + :param signature_algorithm: + :type signature_algorithm: SignatureAlgorithmEnum + :param signing_kp: + :type signing_kp: UUID + :param sls_binding: + :type sls_binding: SAMLBindingsEnum + :param sls_url: + :type sls_url: str + :param sp_binding: + :type sp_binding: SAMLBindingsEnum + :param verification_kp: + :type verification_kp: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_list_serialize( + acs_url=acs_url, + assertion_valid_not_before=assertion_valid_not_before, + assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, + audience=audience, + authentication_flow=authentication_flow, + authn_context_class_ref_mapping=authn_context_class_ref_mapping, + authorization_flow=authorization_flow, + backchannel_application=backchannel_application, + default_name_id_policy=default_name_id_policy, + default_relay_state=default_relay_state, + digest_algorithm=digest_algorithm, + encryption_kp=encryption_kp, + invalidation_flow=invalidation_flow, + is_backchannel=is_backchannel, + issuer_override=issuer_override, + logout_method=logout_method, + name=name, + name_id_mapping=name_id_mapping, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings=property_mappings, + search=search, + session_valid_not_on_or_after=session_valid_not_on_or_after, + sign_assertion=sign_assertion, + sign_logout_request=sign_logout_request, + sign_logout_response=sign_logout_response, + sign_response=sign_response, + signature_algorithm=signature_algorithm, + signing_kp=signing_kp, + sls_binding=sls_binding, + sls_url=sls_url, + sp_binding=sp_binding, + verification_kp=verification_kp, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_list_with_http_info( + self, + acs_url: Optional[StrictStr] = None, + assertion_valid_not_before: Optional[StrictStr] = None, + assertion_valid_not_on_or_after: Optional[StrictStr] = None, + audience: Optional[StrictStr] = None, + authentication_flow: Optional[UUID] = None, + authn_context_class_ref_mapping: Optional[UUID] = None, + authorization_flow: Optional[UUID] = None, + backchannel_application: Optional[UUID] = None, + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None, + default_relay_state: Optional[StrictStr] = None, + digest_algorithm: Optional[DigestAlgorithmEnum] = None, + encryption_kp: Optional[UUID] = None, + invalidation_flow: Optional[UUID] = None, + is_backchannel: Optional[StrictBool] = None, + issuer_override: Optional[StrictStr] = None, + logout_method: Optional[Any] = None, + name: Optional[StrictStr] = None, + name_id_mapping: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session_valid_not_on_or_after: Optional[StrictStr] = None, + sign_assertion: Optional[StrictBool] = None, + sign_logout_request: Optional[StrictBool] = None, + sign_logout_response: Optional[StrictBool] = None, + sign_response: Optional[StrictBool] = None, + signature_algorithm: Optional[SignatureAlgorithmEnum] = None, + signing_kp: Optional[UUID] = None, + sls_binding: Optional[Any] = None, + sls_url: Optional[StrictStr] = None, + sp_binding: Optional[Any] = None, + verification_kp: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSAMLProviderList]: + """providers_saml_list + + SAMLProvider Viewset + + :param acs_url: + :type acs_url: str + :param assertion_valid_not_before: + :type assertion_valid_not_before: str + :param assertion_valid_not_on_or_after: + :type assertion_valid_not_on_or_after: str + :param audience: + :type audience: str + :param authentication_flow: + :type authentication_flow: UUID + :param authn_context_class_ref_mapping: + :type authn_context_class_ref_mapping: UUID + :param authorization_flow: + :type authorization_flow: UUID + :param backchannel_application: + :type backchannel_application: UUID + :param default_name_id_policy: + :type default_name_id_policy: SAMLNameIDPolicyEnum + :param default_relay_state: + :type default_relay_state: str + :param digest_algorithm: + :type digest_algorithm: DigestAlgorithmEnum + :param encryption_kp: + :type encryption_kp: UUID + :param invalidation_flow: + :type invalidation_flow: UUID + :param is_backchannel: + :type is_backchannel: bool + :param issuer_override: + :type issuer_override: str + :param logout_method: + :type logout_method: SAMLLogoutMethods + :param name: + :type name: str + :param name_id_mapping: + :type name_id_mapping: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings: + :type property_mappings: List[UUID] + :param search: A search term. + :type search: str + :param session_valid_not_on_or_after: + :type session_valid_not_on_or_after: str + :param sign_assertion: + :type sign_assertion: bool + :param sign_logout_request: + :type sign_logout_request: bool + :param sign_logout_response: + :type sign_logout_response: bool + :param sign_response: + :type sign_response: bool + :param signature_algorithm: + :type signature_algorithm: SignatureAlgorithmEnum + :param signing_kp: + :type signing_kp: UUID + :param sls_binding: + :type sls_binding: SAMLBindingsEnum + :param sls_url: + :type sls_url: str + :param sp_binding: + :type sp_binding: SAMLBindingsEnum + :param verification_kp: + :type verification_kp: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_list_serialize( + acs_url=acs_url, + assertion_valid_not_before=assertion_valid_not_before, + assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, + audience=audience, + authentication_flow=authentication_flow, + authn_context_class_ref_mapping=authn_context_class_ref_mapping, + authorization_flow=authorization_flow, + backchannel_application=backchannel_application, + default_name_id_policy=default_name_id_policy, + default_relay_state=default_relay_state, + digest_algorithm=digest_algorithm, + encryption_kp=encryption_kp, + invalidation_flow=invalidation_flow, + is_backchannel=is_backchannel, + issuer_override=issuer_override, + logout_method=logout_method, + name=name, + name_id_mapping=name_id_mapping, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings=property_mappings, + search=search, + session_valid_not_on_or_after=session_valid_not_on_or_after, + sign_assertion=sign_assertion, + sign_logout_request=sign_logout_request, + sign_logout_response=sign_logout_response, + sign_response=sign_response, + signature_algorithm=signature_algorithm, + signing_kp=signing_kp, + sls_binding=sls_binding, + sls_url=sls_url, + sp_binding=sp_binding, + verification_kp=verification_kp, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_list_without_preload_content( + self, + acs_url: Optional[StrictStr] = None, + assertion_valid_not_before: Optional[StrictStr] = None, + assertion_valid_not_on_or_after: Optional[StrictStr] = None, + audience: Optional[StrictStr] = None, + authentication_flow: Optional[UUID] = None, + authn_context_class_ref_mapping: Optional[UUID] = None, + authorization_flow: Optional[UUID] = None, + backchannel_application: Optional[UUID] = None, + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None, + default_relay_state: Optional[StrictStr] = None, + digest_algorithm: Optional[DigestAlgorithmEnum] = None, + encryption_kp: Optional[UUID] = None, + invalidation_flow: Optional[UUID] = None, + is_backchannel: Optional[StrictBool] = None, + issuer_override: Optional[StrictStr] = None, + logout_method: Optional[Any] = None, + name: Optional[StrictStr] = None, + name_id_mapping: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session_valid_not_on_or_after: Optional[StrictStr] = None, + sign_assertion: Optional[StrictBool] = None, + sign_logout_request: Optional[StrictBool] = None, + sign_logout_response: Optional[StrictBool] = None, + sign_response: Optional[StrictBool] = None, + signature_algorithm: Optional[SignatureAlgorithmEnum] = None, + signing_kp: Optional[UUID] = None, + sls_binding: Optional[Any] = None, + sls_url: Optional[StrictStr] = None, + sp_binding: Optional[Any] = None, + verification_kp: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_list + + SAMLProvider Viewset + + :param acs_url: + :type acs_url: str + :param assertion_valid_not_before: + :type assertion_valid_not_before: str + :param assertion_valid_not_on_or_after: + :type assertion_valid_not_on_or_after: str + :param audience: + :type audience: str + :param authentication_flow: + :type authentication_flow: UUID + :param authn_context_class_ref_mapping: + :type authn_context_class_ref_mapping: UUID + :param authorization_flow: + :type authorization_flow: UUID + :param backchannel_application: + :type backchannel_application: UUID + :param default_name_id_policy: + :type default_name_id_policy: SAMLNameIDPolicyEnum + :param default_relay_state: + :type default_relay_state: str + :param digest_algorithm: + :type digest_algorithm: DigestAlgorithmEnum + :param encryption_kp: + :type encryption_kp: UUID + :param invalidation_flow: + :type invalidation_flow: UUID + :param is_backchannel: + :type is_backchannel: bool + :param issuer_override: + :type issuer_override: str + :param logout_method: + :type logout_method: SAMLLogoutMethods + :param name: + :type name: str + :param name_id_mapping: + :type name_id_mapping: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings: + :type property_mappings: List[UUID] + :param search: A search term. + :type search: str + :param session_valid_not_on_or_after: + :type session_valid_not_on_or_after: str + :param sign_assertion: + :type sign_assertion: bool + :param sign_logout_request: + :type sign_logout_request: bool + :param sign_logout_response: + :type sign_logout_response: bool + :param sign_response: + :type sign_response: bool + :param signature_algorithm: + :type signature_algorithm: SignatureAlgorithmEnum + :param signing_kp: + :type signing_kp: UUID + :param sls_binding: + :type sls_binding: SAMLBindingsEnum + :param sls_url: + :type sls_url: str + :param sp_binding: + :type sp_binding: SAMLBindingsEnum + :param verification_kp: + :type verification_kp: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_list_serialize( + acs_url=acs_url, + assertion_valid_not_before=assertion_valid_not_before, + assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, + audience=audience, + authentication_flow=authentication_flow, + authn_context_class_ref_mapping=authn_context_class_ref_mapping, + authorization_flow=authorization_flow, + backchannel_application=backchannel_application, + default_name_id_policy=default_name_id_policy, + default_relay_state=default_relay_state, + digest_algorithm=digest_algorithm, + encryption_kp=encryption_kp, + invalidation_flow=invalidation_flow, + is_backchannel=is_backchannel, + issuer_override=issuer_override, + logout_method=logout_method, + name=name, + name_id_mapping=name_id_mapping, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings=property_mappings, + search=search, + session_valid_not_on_or_after=session_valid_not_on_or_after, + sign_assertion=sign_assertion, + sign_logout_request=sign_logout_request, + sign_logout_response=sign_logout_response, + sign_response=sign_response, + signature_algorithm=signature_algorithm, + signing_kp=signing_kp, + sls_binding=sls_binding, + sls_url=sls_url, + sp_binding=sp_binding, + verification_kp=verification_kp, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_list_serialize( + self, + acs_url, + assertion_valid_not_before, + assertion_valid_not_on_or_after, + audience, + authentication_flow, + authn_context_class_ref_mapping, + authorization_flow, + backchannel_application, + default_name_id_policy, + default_relay_state, + digest_algorithm, + encryption_kp, + invalidation_flow, + is_backchannel, + issuer_override, + logout_method, + name, + name_id_mapping, + ordering, + page, + page_size, + property_mappings, + search, + session_valid_not_on_or_after, + sign_assertion, + sign_logout_request, + sign_logout_response, + sign_response, + signature_algorithm, + signing_kp, + sls_binding, + sls_url, + sp_binding, + verification_kp, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'property_mappings': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if acs_url is not None: + + _query_params.append(('acs_url', acs_url)) + + if assertion_valid_not_before is not None: + + _query_params.append(('assertion_valid_not_before', assertion_valid_not_before)) + + if assertion_valid_not_on_or_after is not None: + + _query_params.append(('assertion_valid_not_on_or_after', assertion_valid_not_on_or_after)) + + if audience is not None: + + _query_params.append(('audience', audience)) + + if authentication_flow is not None: + + _query_params.append(('authentication_flow', authentication_flow)) + + if authn_context_class_ref_mapping is not None: + + _query_params.append(('authn_context_class_ref_mapping', authn_context_class_ref_mapping)) + + if authorization_flow is not None: + + _query_params.append(('authorization_flow', authorization_flow)) + + if backchannel_application is not None: + + _query_params.append(('backchannel_application', backchannel_application)) + + if default_name_id_policy is not None: + + _query_params.append(('default_name_id_policy', default_name_id_policy.value)) + + if default_relay_state is not None: + + _query_params.append(('default_relay_state', default_relay_state)) + + if digest_algorithm is not None: + + _query_params.append(('digest_algorithm', digest_algorithm.value)) + + if encryption_kp is not None: + + _query_params.append(('encryption_kp', encryption_kp)) + + if invalidation_flow is not None: + + _query_params.append(('invalidation_flow', invalidation_flow)) + + if is_backchannel is not None: + + _query_params.append(('is_backchannel', is_backchannel)) + + if issuer_override is not None: + + _query_params.append(('issuer_override', issuer_override)) + + if logout_method is not None: + + _query_params.append(('logout_method', logout_method.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if name_id_mapping is not None: + + _query_params.append(('name_id_mapping', name_id_mapping)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if property_mappings is not None: + + _query_params.append(('property_mappings', property_mappings)) + + if search is not None: + + _query_params.append(('search', search)) + + if session_valid_not_on_or_after is not None: + + _query_params.append(('session_valid_not_on_or_after', session_valid_not_on_or_after)) + + if sign_assertion is not None: + + _query_params.append(('sign_assertion', sign_assertion)) + + if sign_logout_request is not None: + + _query_params.append(('sign_logout_request', sign_logout_request)) + + if sign_logout_response is not None: + + _query_params.append(('sign_logout_response', sign_logout_response)) + + if sign_response is not None: + + _query_params.append(('sign_response', sign_response)) + + if signature_algorithm is not None: + + _query_params.append(('signature_algorithm', signature_algorithm.value)) + + if signing_kp is not None: + + _query_params.append(('signing_kp', signing_kp)) + + if sls_binding is not None: + + _query_params.append(('sls_binding', sls_binding.value)) + + if sls_url is not None: + + _query_params.append(('sls_url', sls_url)) + + if sp_binding is not None: + + _query_params.append(('sp_binding', sp_binding.value)) + + if verification_kp is not None: + + _query_params.append(('verification_kp', verification_kp)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_metadata_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + download: Optional[StrictBool] = None, + force_binding: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLMetadata: + """providers_saml_metadata_retrieve + + Return metadata as XML string + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param download: + :type download: bool + :param force_binding: + :type force_binding: ForceBindingEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_metadata_retrieve_serialize( + id=id, + download=download, + force_binding=force_binding, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLMetadata", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_metadata_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + download: Optional[StrictBool] = None, + force_binding: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLMetadata]: + """providers_saml_metadata_retrieve + + Return metadata as XML string + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param download: + :type download: bool + :param force_binding: + :type force_binding: ForceBindingEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_metadata_retrieve_serialize( + id=id, + download=download, + force_binding=force_binding, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLMetadata", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_metadata_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + download: Optional[StrictBool] = None, + force_binding: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_metadata_retrieve + + Return metadata as XML string + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param download: + :type download: bool + :param force_binding: + :type force_binding: ForceBindingEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_metadata_retrieve_serialize( + id=id, + download=download, + force_binding=force_binding, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLMetadata", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_metadata_retrieve_serialize( + self, + id, + download, + force_binding, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + if download is not None: + + _query_params.append(('download', download)) + + if force_binding is not None: + + _query_params.append(('force_binding', force_binding.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json', + 'application/xml' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/saml/{id}/metadata/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + patched_saml_provider_request: Optional[PatchedSAMLProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLProvider: + """providers_saml_partial_update + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param patched_saml_provider_request: + :type patched_saml_provider_request: PatchedSAMLProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_partial_update_serialize( + id=id, + patched_saml_provider_request=patched_saml_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + patched_saml_provider_request: Optional[PatchedSAMLProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLProvider]: + """providers_saml_partial_update + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param patched_saml_provider_request: + :type patched_saml_provider_request: PatchedSAMLProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_partial_update_serialize( + id=id, + patched_saml_provider_request=patched_saml_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + patched_saml_provider_request: Optional[PatchedSAMLProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_partial_update + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param patched_saml_provider_request: + :type patched_saml_provider_request: PatchedSAMLProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_partial_update_serialize( + id=id, + patched_saml_provider_request=patched_saml_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_partial_update_serialize( + self, + id, + patched_saml_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_saml_provider_request is not None: + _body_params = patched_saml_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_preview_user_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PropertyMappingPreview: + """providers_saml_preview_user_retrieve + + Preview user data for provider + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_preview_user_retrieve_serialize( + id=id, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingPreview", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_preview_user_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PropertyMappingPreview]: + """providers_saml_preview_user_retrieve + + Preview user data for provider + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_preview_user_retrieve_serialize( + id=id, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingPreview", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_preview_user_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_preview_user_retrieve + + Preview user data for provider + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_preview_user_retrieve_serialize( + id=id, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingPreview", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_preview_user_retrieve_serialize( + self, + id, + for_user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + if for_user is not None: + + _query_params.append(('for_user', for_user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/saml/{id}/preview_user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLProvider: + """providers_saml_retrieve + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLProvider]: + """providers_saml_retrieve + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_retrieve + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + saml_provider_request: SAMLProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLProvider: + """providers_saml_update + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param saml_provider_request: (required) + :type saml_provider_request: SAMLProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_update_serialize( + id=id, + saml_provider_request=saml_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + saml_provider_request: SAMLProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLProvider]: + """providers_saml_update + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param saml_provider_request: (required) + :type saml_provider_request: SAMLProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_update_serialize( + id=id, + saml_provider_request=saml_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + saml_provider_request: SAMLProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_update + + SAMLProvider Viewset + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param saml_provider_request: (required) + :type saml_provider_request: SAMLProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_update_serialize( + id=id, + saml_provider_request=saml_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_update_serialize( + self, + id, + saml_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if saml_provider_request is not None: + _body_params = saml_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_saml_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_saml_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_saml_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_saml_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_saml_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SAML Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_saml_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this SAML Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_saml_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_saml_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/saml/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_create( + self, + scim_provider_request: SCIMProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMProvider: + """providers_scim_create + + SCIMProvider Viewset + + :param scim_provider_request: (required) + :type scim_provider_request: SCIMProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_create_serialize( + scim_provider_request=scim_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_create_with_http_info( + self, + scim_provider_request: SCIMProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMProvider]: + """providers_scim_create + + SCIMProvider Viewset + + :param scim_provider_request: (required) + :type scim_provider_request: SCIMProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_create_serialize( + scim_provider_request=scim_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_create_without_preload_content( + self, + scim_provider_request: SCIMProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_create + + SCIMProvider Viewset + + :param scim_provider_request: (required) + :type scim_provider_request: SCIMProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_create_serialize( + scim_provider_request=scim_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_create_serialize( + self, + scim_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_provider_request is not None: + _body_params = scim_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/scim/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_scim_destroy + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_scim_destroy + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_destroy + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/scim/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_groups_create( + self, + scim_provider_group_request: SCIMProviderGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMProviderGroup: + """providers_scim_groups_create + + SCIMProviderGroup Viewset + + :param scim_provider_group_request: (required) + :type scim_provider_group_request: SCIMProviderGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_create_serialize( + scim_provider_group_request=scim_provider_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_groups_create_with_http_info( + self, + scim_provider_group_request: SCIMProviderGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMProviderGroup]: + """providers_scim_groups_create + + SCIMProviderGroup Viewset + + :param scim_provider_group_request: (required) + :type scim_provider_group_request: SCIMProviderGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_create_serialize( + scim_provider_group_request=scim_provider_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_groups_create_without_preload_content( + self, + scim_provider_group_request: SCIMProviderGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_groups_create + + SCIMProviderGroup Viewset + + :param scim_provider_group_request: (required) + :type scim_provider_group_request: SCIMProviderGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_create_serialize( + scim_provider_group_request=scim_provider_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_groups_create_serialize( + self, + scim_provider_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_provider_group_request is not None: + _body_params = scim_provider_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/scim_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_groups_destroy( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_scim_groups_destroy + + SCIMProviderGroup Viewset + + :param id: A UUID string identifying this scim provider group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_groups_destroy_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_scim_groups_destroy + + SCIMProviderGroup Viewset + + :param id: A UUID string identifying this scim provider group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_groups_destroy_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_groups_destroy + + SCIMProviderGroup Viewset + + :param id: A UUID string identifying this scim provider group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_groups_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/scim_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_groups_list( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSCIMProviderGroupList: + """providers_scim_groups_list + + SCIMProviderGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMProviderGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_groups_list_with_http_info( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSCIMProviderGroupList]: + """providers_scim_groups_list + + SCIMProviderGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMProviderGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_groups_list_without_preload_content( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_groups_list + + SCIMProviderGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMProviderGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_groups_list_serialize( + self, + group__group_uuid, + group__name, + ordering, + page, + page_size, + provider__id, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group__group_uuid is not None: + + _query_params.append(('group__group_uuid', group__group_uuid)) + + if group__name is not None: + + _query_params.append(('group__name', group__name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider__id is not None: + + _query_params.append(('provider__id', provider__id)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_groups_retrieve( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMProviderGroup: + """providers_scim_groups_retrieve + + SCIMProviderGroup Viewset + + :param id: A UUID string identifying this scim provider group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_groups_retrieve_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMProviderGroup]: + """providers_scim_groups_retrieve + + SCIMProviderGroup Viewset + + :param id: A UUID string identifying this scim provider group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_groups_retrieve_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_groups_retrieve + + SCIMProviderGroup Viewset + + :param id: A UUID string identifying this scim provider group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProviderGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_groups_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_groups_used_by_list( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_scim_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this scim provider group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_groups_used_by_list_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_scim_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this scim provider group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_groups_used_by_list_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this scim provider group. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_groups_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim_groups/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_list( + self, + exclude_users_service_account: Optional[StrictBool] = None, + group_filters: Optional[List[UUID]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + url: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSCIMProviderList: + """providers_scim_list + + SCIMProvider Viewset + + :param exclude_users_service_account: + :type exclude_users_service_account: bool + :param group_filters: + :type group_filters: List[UUID] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param url: + :type url: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_list_serialize( + exclude_users_service_account=exclude_users_service_account, + group_filters=group_filters, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + url=url, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_list_with_http_info( + self, + exclude_users_service_account: Optional[StrictBool] = None, + group_filters: Optional[List[UUID]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + url: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSCIMProviderList]: + """providers_scim_list + + SCIMProvider Viewset + + :param exclude_users_service_account: + :type exclude_users_service_account: bool + :param group_filters: + :type group_filters: List[UUID] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param url: + :type url: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_list_serialize( + exclude_users_service_account=exclude_users_service_account, + group_filters=group_filters, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + url=url, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_list_without_preload_content( + self, + exclude_users_service_account: Optional[StrictBool] = None, + group_filters: Optional[List[UUID]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + url: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_list + + SCIMProvider Viewset + + :param exclude_users_service_account: + :type exclude_users_service_account: bool + :param group_filters: + :type group_filters: List[UUID] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param url: + :type url: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_list_serialize( + exclude_users_service_account=exclude_users_service_account, + group_filters=group_filters, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + url=url, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_list_serialize( + self, + exclude_users_service_account, + group_filters, + name, + ordering, + page, + page_size, + search, + url, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'group_filters': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if exclude_users_service_account is not None: + + _query_params.append(('exclude_users_service_account', exclude_users_service_account)) + + if group_filters is not None: + + _query_params.append(('group_filters', group_filters)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if url is not None: + + _query_params.append(('url', url)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + patched_scim_provider_request: Optional[PatchedSCIMProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMProvider: + """providers_scim_partial_update + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param patched_scim_provider_request: + :type patched_scim_provider_request: PatchedSCIMProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_partial_update_serialize( + id=id, + patched_scim_provider_request=patched_scim_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + patched_scim_provider_request: Optional[PatchedSCIMProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMProvider]: + """providers_scim_partial_update + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param patched_scim_provider_request: + :type patched_scim_provider_request: PatchedSCIMProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_partial_update_serialize( + id=id, + patched_scim_provider_request=patched_scim_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + patched_scim_provider_request: Optional[PatchedSCIMProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_partial_update + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param patched_scim_provider_request: + :type patched_scim_provider_request: PatchedSCIMProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_partial_update_serialize( + id=id, + patched_scim_provider_request=patched_scim_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_partial_update_serialize( + self, + id, + patched_scim_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_scim_provider_request is not None: + _body_params = patched_scim_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/scim/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMProvider: + """providers_scim_retrieve + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMProvider]: + """providers_scim_retrieve + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_retrieve + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_sync_object_create( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + sync_object_request: SyncObjectRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SyncObjectResult: + """providers_scim_sync_object_create + + Sync/Re-sync a single user/group object + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param sync_object_request: (required) + :type sync_object_request: SyncObjectRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_sync_object_create_serialize( + id=id, + sync_object_request=sync_object_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncObjectResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_sync_object_create_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + sync_object_request: SyncObjectRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SyncObjectResult]: + """providers_scim_sync_object_create + + Sync/Re-sync a single user/group object + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param sync_object_request: (required) + :type sync_object_request: SyncObjectRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_sync_object_create_serialize( + id=id, + sync_object_request=sync_object_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncObjectResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_sync_object_create_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + sync_object_request: SyncObjectRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_sync_object_create + + Sync/Re-sync a single user/group object + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param sync_object_request: (required) + :type sync_object_request: SyncObjectRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_sync_object_create_serialize( + id=id, + sync_object_request=sync_object_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncObjectResult", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_sync_object_create_serialize( + self, + id, + sync_object_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if sync_object_request is not None: + _body_params = sync_object_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/scim/{id}/sync/object/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_sync_status_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SyncStatus: + """providers_scim_sync_status_retrieve + + Get provider's sync status + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_sync_status_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_sync_status_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SyncStatus]: + """providers_scim_sync_status_retrieve + + Get provider's sync status + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_sync_status_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_sync_status_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_sync_status_retrieve + + Get provider's sync status + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_sync_status_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_sync_status_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim/{id}/sync/status/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + scim_provider_request: SCIMProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMProvider: + """providers_scim_update + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param scim_provider_request: (required) + :type scim_provider_request: SCIMProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_update_serialize( + id=id, + scim_provider_request=scim_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + scim_provider_request: SCIMProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMProvider]: + """providers_scim_update + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param scim_provider_request: (required) + :type scim_provider_request: SCIMProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_update_serialize( + id=id, + scim_provider_request=scim_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + scim_provider_request: SCIMProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_update + + SCIMProvider Viewset + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param scim_provider_request: (required) + :type scim_provider_request: SCIMProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_update_serialize( + id=id, + scim_provider_request=scim_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_update_serialize( + self, + id, + scim_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_provider_request is not None: + _body_params = scim_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/scim/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_scim_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_scim_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this SCIM Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this SCIM Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_users_create( + self, + scim_provider_user_request: SCIMProviderUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMProviderUser: + """providers_scim_users_create + + SCIMProviderUser Viewset + + :param scim_provider_user_request: (required) + :type scim_provider_user_request: SCIMProviderUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_create_serialize( + scim_provider_user_request=scim_provider_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_users_create_with_http_info( + self, + scim_provider_user_request: SCIMProviderUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMProviderUser]: + """providers_scim_users_create + + SCIMProviderUser Viewset + + :param scim_provider_user_request: (required) + :type scim_provider_user_request: SCIMProviderUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_create_serialize( + scim_provider_user_request=scim_provider_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_users_create_without_preload_content( + self, + scim_provider_user_request: SCIMProviderUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_users_create + + SCIMProviderUser Viewset + + :param scim_provider_user_request: (required) + :type scim_provider_user_request: SCIMProviderUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_create_serialize( + scim_provider_user_request=scim_provider_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_users_create_serialize( + self, + scim_provider_user_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_provider_user_request is not None: + _body_params = scim_provider_user_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/scim_users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_users_destroy( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_scim_users_destroy + + SCIMProviderUser Viewset + + :param id: A UUID string identifying this scim provider user. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_users_destroy_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_scim_users_destroy + + SCIMProviderUser Viewset + + :param id: A UUID string identifying this scim provider user. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_users_destroy_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_users_destroy + + SCIMProviderUser Viewset + + :param id: A UUID string identifying this scim provider user. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_users_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/scim_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_users_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSCIMProviderUserList: + """providers_scim_users_list + + SCIMProviderUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMProviderUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_users_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSCIMProviderUserList]: + """providers_scim_users_list + + SCIMProviderUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMProviderUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_users_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider__id: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_users_list + + SCIMProviderUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider__id: + :type provider__id: int + :param search: A search term. + :type search: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + provider__id=provider__id, + search=search, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMProviderUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_users_list_serialize( + self, + ordering, + page, + page_size, + provider__id, + search, + user__id, + user__username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider__id is not None: + + _query_params.append(('provider__id', provider__id)) + + if search is not None: + + _query_params.append(('search', search)) + + if user__id is not None: + + _query_params.append(('user__id', user__id)) + + if user__username is not None: + + _query_params.append(('user__username', user__username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim_users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_users_retrieve( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMProviderUser: + """providers_scim_users_retrieve + + SCIMProviderUser Viewset + + :param id: A UUID string identifying this scim provider user. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_users_retrieve_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMProviderUser]: + """providers_scim_users_retrieve + + SCIMProviderUser Viewset + + :param id: A UUID string identifying this scim provider user. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_users_retrieve_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_users_retrieve + + SCIMProviderUser Viewset + + :param id: A UUID string identifying this scim provider user. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMProviderUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_users_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_scim_users_used_by_list( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_scim_users_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this scim provider user. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_scim_users_used_by_list_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_scim_users_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this scim provider user. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_scim_users_used_by_list_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this scim provider user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_scim_users_used_by_list + + Get a list of all objects that use this object + + :param id: A UUID string identifying this scim provider user. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_scim_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_scim_users_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/scim_users/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ssf_create( + self, + ssf_provider_request: SSFProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SSFProvider: + """providers_ssf_create + + SSFProvider Viewset + + :param ssf_provider_request: (required) + :type ssf_provider_request: SSFProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_create_serialize( + ssf_provider_request=ssf_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ssf_create_with_http_info( + self, + ssf_provider_request: SSFProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SSFProvider]: + """providers_ssf_create + + SSFProvider Viewset + + :param ssf_provider_request: (required) + :type ssf_provider_request: SSFProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_create_serialize( + ssf_provider_request=ssf_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ssf_create_without_preload_content( + self, + ssf_provider_request: SSFProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ssf_create + + SSFProvider Viewset + + :param ssf_provider_request: (required) + :type ssf_provider_request: SSFProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_create_serialize( + ssf_provider_request=ssf_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ssf_create_serialize( + self, + ssf_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ssf_provider_request is not None: + _body_params = ssf_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/ssf/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ssf_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_ssf_destroy + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ssf_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_ssf_destroy + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ssf_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ssf_destroy + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ssf_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/ssf/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ssf_list( + self, + application__isnull: Optional[StrictBool] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSSFProviderList: + """providers_ssf_list + + SSFProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_list_serialize( + application__isnull=application__isnull, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSSFProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ssf_list_with_http_info( + self, + application__isnull: Optional[StrictBool] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSSFProviderList]: + """providers_ssf_list + + SSFProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_list_serialize( + application__isnull=application__isnull, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSSFProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ssf_list_without_preload_content( + self, + application__isnull: Optional[StrictBool] = None, + name__iexact: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ssf_list + + SSFProvider Viewset + + :param application__isnull: + :type application__isnull: bool + :param name__iexact: + :type name__iexact: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_list_serialize( + application__isnull=application__isnull, + name__iexact=name__iexact, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSSFProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ssf_list_serialize( + self, + application__isnull, + name__iexact, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if application__isnull is not None: + + _query_params.append(('application__isnull', application__isnull)) + + if name__iexact is not None: + + _query_params.append(('name__iexact', name__iexact)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/ssf/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ssf_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + patched_ssf_provider_request: Optional[PatchedSSFProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SSFProvider: + """providers_ssf_partial_update + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param patched_ssf_provider_request: + :type patched_ssf_provider_request: PatchedSSFProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_partial_update_serialize( + id=id, + patched_ssf_provider_request=patched_ssf_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ssf_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + patched_ssf_provider_request: Optional[PatchedSSFProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SSFProvider]: + """providers_ssf_partial_update + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param patched_ssf_provider_request: + :type patched_ssf_provider_request: PatchedSSFProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_partial_update_serialize( + id=id, + patched_ssf_provider_request=patched_ssf_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ssf_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + patched_ssf_provider_request: Optional[PatchedSSFProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ssf_partial_update + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param patched_ssf_provider_request: + :type patched_ssf_provider_request: PatchedSSFProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_partial_update_serialize( + id=id, + patched_ssf_provider_request=patched_ssf_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ssf_partial_update_serialize( + self, + id, + patched_ssf_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_ssf_provider_request is not None: + _body_params = patched_ssf_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/ssf/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ssf_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SSFProvider: + """providers_ssf_retrieve + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ssf_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SSFProvider]: + """providers_ssf_retrieve + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ssf_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ssf_retrieve + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ssf_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/ssf/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ssf_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + ssf_provider_request: SSFProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SSFProvider: + """providers_ssf_update + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param ssf_provider_request: (required) + :type ssf_provider_request: SSFProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_update_serialize( + id=id, + ssf_provider_request=ssf_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ssf_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + ssf_provider_request: SSFProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SSFProvider]: + """providers_ssf_update + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param ssf_provider_request: (required) + :type ssf_provider_request: SSFProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_update_serialize( + id=id, + ssf_provider_request=ssf_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ssf_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + ssf_provider_request: SSFProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ssf_update + + SSFProvider Viewset + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param ssf_provider_request: (required) + :type ssf_provider_request: SSFProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_update_serialize( + id=id, + ssf_provider_request=ssf_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ssf_update_serialize( + self, + id, + ssf_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ssf_provider_request is not None: + _body_params = ssf_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/ssf/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_ssf_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_ssf_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_ssf_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_ssf_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_ssf_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Shared Signals Framework Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_ssf_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Shared Signals Framework Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_ssf_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_ssf_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/ssf/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_wsfed_create( + self, + ws_federation_provider_request: WSFederationProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WSFederationProvider: + """providers_wsfed_create + + WSFederationProvider Viewset + + :param ws_federation_provider_request: (required) + :type ws_federation_provider_request: WSFederationProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_create_serialize( + ws_federation_provider_request=ws_federation_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_wsfed_create_with_http_info( + self, + ws_federation_provider_request: WSFederationProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WSFederationProvider]: + """providers_wsfed_create + + WSFederationProvider Viewset + + :param ws_federation_provider_request: (required) + :type ws_federation_provider_request: WSFederationProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_create_serialize( + ws_federation_provider_request=ws_federation_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_wsfed_create_without_preload_content( + self, + ws_federation_provider_request: WSFederationProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_wsfed_create + + WSFederationProvider Viewset + + :param ws_federation_provider_request: (required) + :type ws_federation_provider_request: WSFederationProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_create_serialize( + ws_federation_provider_request=ws_federation_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_wsfed_create_serialize( + self, + ws_federation_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ws_federation_provider_request is not None: + _body_params = ws_federation_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/providers/wsfed/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_wsfed_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """providers_wsfed_destroy + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_wsfed_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """providers_wsfed_destroy + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_wsfed_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_wsfed_destroy + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_wsfed_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/providers/wsfed/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_wsfed_list( + self, + acs_url: Optional[StrictStr] = None, + assertion_valid_not_before: Optional[StrictStr] = None, + assertion_valid_not_on_or_after: Optional[StrictStr] = None, + audience: Optional[StrictStr] = None, + authentication_flow: Optional[UUID] = None, + authn_context_class_ref_mapping: Optional[UUID] = None, + authorization_flow: Optional[UUID] = None, + backchannel_application: Optional[UUID] = None, + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None, + default_relay_state: Optional[StrictStr] = None, + digest_algorithm: Optional[DigestAlgorithmEnum] = None, + encryption_kp: Optional[UUID] = None, + invalidation_flow: Optional[UUID] = None, + is_backchannel: Optional[StrictBool] = None, + issuer_override: Optional[StrictStr] = None, + logout_method: Optional[Any] = None, + name: Optional[StrictStr] = None, + name_id_mapping: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session_valid_not_on_or_after: Optional[StrictStr] = None, + sign_assertion: Optional[StrictBool] = None, + sign_logout_request: Optional[StrictBool] = None, + sign_logout_response: Optional[StrictBool] = None, + sign_response: Optional[StrictBool] = None, + signature_algorithm: Optional[SignatureAlgorithmEnum] = None, + signing_kp: Optional[UUID] = None, + sls_binding: Optional[Any] = None, + sls_url: Optional[StrictStr] = None, + sp_binding: Optional[Any] = None, + verification_kp: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedWSFederationProviderList: + """providers_wsfed_list + + WSFederationProvider Viewset + + :param acs_url: + :type acs_url: str + :param assertion_valid_not_before: + :type assertion_valid_not_before: str + :param assertion_valid_not_on_or_after: + :type assertion_valid_not_on_or_after: str + :param audience: + :type audience: str + :param authentication_flow: + :type authentication_flow: UUID + :param authn_context_class_ref_mapping: + :type authn_context_class_ref_mapping: UUID + :param authorization_flow: + :type authorization_flow: UUID + :param backchannel_application: + :type backchannel_application: UUID + :param default_name_id_policy: + :type default_name_id_policy: SAMLNameIDPolicyEnum + :param default_relay_state: + :type default_relay_state: str + :param digest_algorithm: + :type digest_algorithm: DigestAlgorithmEnum + :param encryption_kp: + :type encryption_kp: UUID + :param invalidation_flow: + :type invalidation_flow: UUID + :param is_backchannel: + :type is_backchannel: bool + :param issuer_override: + :type issuer_override: str + :param logout_method: + :type logout_method: SAMLLogoutMethods + :param name: + :type name: str + :param name_id_mapping: + :type name_id_mapping: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings: + :type property_mappings: List[UUID] + :param search: A search term. + :type search: str + :param session_valid_not_on_or_after: + :type session_valid_not_on_or_after: str + :param sign_assertion: + :type sign_assertion: bool + :param sign_logout_request: + :type sign_logout_request: bool + :param sign_logout_response: + :type sign_logout_response: bool + :param sign_response: + :type sign_response: bool + :param signature_algorithm: + :type signature_algorithm: SignatureAlgorithmEnum + :param signing_kp: + :type signing_kp: UUID + :param sls_binding: + :type sls_binding: SAMLBindingsEnum + :param sls_url: + :type sls_url: str + :param sp_binding: + :type sp_binding: SAMLBindingsEnum + :param verification_kp: + :type verification_kp: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_list_serialize( + acs_url=acs_url, + assertion_valid_not_before=assertion_valid_not_before, + assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, + audience=audience, + authentication_flow=authentication_flow, + authn_context_class_ref_mapping=authn_context_class_ref_mapping, + authorization_flow=authorization_flow, + backchannel_application=backchannel_application, + default_name_id_policy=default_name_id_policy, + default_relay_state=default_relay_state, + digest_algorithm=digest_algorithm, + encryption_kp=encryption_kp, + invalidation_flow=invalidation_flow, + is_backchannel=is_backchannel, + issuer_override=issuer_override, + logout_method=logout_method, + name=name, + name_id_mapping=name_id_mapping, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings=property_mappings, + search=search, + session_valid_not_on_or_after=session_valid_not_on_or_after, + sign_assertion=sign_assertion, + sign_logout_request=sign_logout_request, + sign_logout_response=sign_logout_response, + sign_response=sign_response, + signature_algorithm=signature_algorithm, + signing_kp=signing_kp, + sls_binding=sls_binding, + sls_url=sls_url, + sp_binding=sp_binding, + verification_kp=verification_kp, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWSFederationProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_wsfed_list_with_http_info( + self, + acs_url: Optional[StrictStr] = None, + assertion_valid_not_before: Optional[StrictStr] = None, + assertion_valid_not_on_or_after: Optional[StrictStr] = None, + audience: Optional[StrictStr] = None, + authentication_flow: Optional[UUID] = None, + authn_context_class_ref_mapping: Optional[UUID] = None, + authorization_flow: Optional[UUID] = None, + backchannel_application: Optional[UUID] = None, + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None, + default_relay_state: Optional[StrictStr] = None, + digest_algorithm: Optional[DigestAlgorithmEnum] = None, + encryption_kp: Optional[UUID] = None, + invalidation_flow: Optional[UUID] = None, + is_backchannel: Optional[StrictBool] = None, + issuer_override: Optional[StrictStr] = None, + logout_method: Optional[Any] = None, + name: Optional[StrictStr] = None, + name_id_mapping: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session_valid_not_on_or_after: Optional[StrictStr] = None, + sign_assertion: Optional[StrictBool] = None, + sign_logout_request: Optional[StrictBool] = None, + sign_logout_response: Optional[StrictBool] = None, + sign_response: Optional[StrictBool] = None, + signature_algorithm: Optional[SignatureAlgorithmEnum] = None, + signing_kp: Optional[UUID] = None, + sls_binding: Optional[Any] = None, + sls_url: Optional[StrictStr] = None, + sp_binding: Optional[Any] = None, + verification_kp: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedWSFederationProviderList]: + """providers_wsfed_list + + WSFederationProvider Viewset + + :param acs_url: + :type acs_url: str + :param assertion_valid_not_before: + :type assertion_valid_not_before: str + :param assertion_valid_not_on_or_after: + :type assertion_valid_not_on_or_after: str + :param audience: + :type audience: str + :param authentication_flow: + :type authentication_flow: UUID + :param authn_context_class_ref_mapping: + :type authn_context_class_ref_mapping: UUID + :param authorization_flow: + :type authorization_flow: UUID + :param backchannel_application: + :type backchannel_application: UUID + :param default_name_id_policy: + :type default_name_id_policy: SAMLNameIDPolicyEnum + :param default_relay_state: + :type default_relay_state: str + :param digest_algorithm: + :type digest_algorithm: DigestAlgorithmEnum + :param encryption_kp: + :type encryption_kp: UUID + :param invalidation_flow: + :type invalidation_flow: UUID + :param is_backchannel: + :type is_backchannel: bool + :param issuer_override: + :type issuer_override: str + :param logout_method: + :type logout_method: SAMLLogoutMethods + :param name: + :type name: str + :param name_id_mapping: + :type name_id_mapping: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings: + :type property_mappings: List[UUID] + :param search: A search term. + :type search: str + :param session_valid_not_on_or_after: + :type session_valid_not_on_or_after: str + :param sign_assertion: + :type sign_assertion: bool + :param sign_logout_request: + :type sign_logout_request: bool + :param sign_logout_response: + :type sign_logout_response: bool + :param sign_response: + :type sign_response: bool + :param signature_algorithm: + :type signature_algorithm: SignatureAlgorithmEnum + :param signing_kp: + :type signing_kp: UUID + :param sls_binding: + :type sls_binding: SAMLBindingsEnum + :param sls_url: + :type sls_url: str + :param sp_binding: + :type sp_binding: SAMLBindingsEnum + :param verification_kp: + :type verification_kp: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_list_serialize( + acs_url=acs_url, + assertion_valid_not_before=assertion_valid_not_before, + assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, + audience=audience, + authentication_flow=authentication_flow, + authn_context_class_ref_mapping=authn_context_class_ref_mapping, + authorization_flow=authorization_flow, + backchannel_application=backchannel_application, + default_name_id_policy=default_name_id_policy, + default_relay_state=default_relay_state, + digest_algorithm=digest_algorithm, + encryption_kp=encryption_kp, + invalidation_flow=invalidation_flow, + is_backchannel=is_backchannel, + issuer_override=issuer_override, + logout_method=logout_method, + name=name, + name_id_mapping=name_id_mapping, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings=property_mappings, + search=search, + session_valid_not_on_or_after=session_valid_not_on_or_after, + sign_assertion=sign_assertion, + sign_logout_request=sign_logout_request, + sign_logout_response=sign_logout_response, + sign_response=sign_response, + signature_algorithm=signature_algorithm, + signing_kp=signing_kp, + sls_binding=sls_binding, + sls_url=sls_url, + sp_binding=sp_binding, + verification_kp=verification_kp, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWSFederationProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_wsfed_list_without_preload_content( + self, + acs_url: Optional[StrictStr] = None, + assertion_valid_not_before: Optional[StrictStr] = None, + assertion_valid_not_on_or_after: Optional[StrictStr] = None, + audience: Optional[StrictStr] = None, + authentication_flow: Optional[UUID] = None, + authn_context_class_ref_mapping: Optional[UUID] = None, + authorization_flow: Optional[UUID] = None, + backchannel_application: Optional[UUID] = None, + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None, + default_relay_state: Optional[StrictStr] = None, + digest_algorithm: Optional[DigestAlgorithmEnum] = None, + encryption_kp: Optional[UUID] = None, + invalidation_flow: Optional[UUID] = None, + is_backchannel: Optional[StrictBool] = None, + issuer_override: Optional[StrictStr] = None, + logout_method: Optional[Any] = None, + name: Optional[StrictStr] = None, + name_id_mapping: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + property_mappings: Optional[List[UUID]] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session_valid_not_on_or_after: Optional[StrictStr] = None, + sign_assertion: Optional[StrictBool] = None, + sign_logout_request: Optional[StrictBool] = None, + sign_logout_response: Optional[StrictBool] = None, + sign_response: Optional[StrictBool] = None, + signature_algorithm: Optional[SignatureAlgorithmEnum] = None, + signing_kp: Optional[UUID] = None, + sls_binding: Optional[Any] = None, + sls_url: Optional[StrictStr] = None, + sp_binding: Optional[Any] = None, + verification_kp: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_wsfed_list + + WSFederationProvider Viewset + + :param acs_url: + :type acs_url: str + :param assertion_valid_not_before: + :type assertion_valid_not_before: str + :param assertion_valid_not_on_or_after: + :type assertion_valid_not_on_or_after: str + :param audience: + :type audience: str + :param authentication_flow: + :type authentication_flow: UUID + :param authn_context_class_ref_mapping: + :type authn_context_class_ref_mapping: UUID + :param authorization_flow: + :type authorization_flow: UUID + :param backchannel_application: + :type backchannel_application: UUID + :param default_name_id_policy: + :type default_name_id_policy: SAMLNameIDPolicyEnum + :param default_relay_state: + :type default_relay_state: str + :param digest_algorithm: + :type digest_algorithm: DigestAlgorithmEnum + :param encryption_kp: + :type encryption_kp: UUID + :param invalidation_flow: + :type invalidation_flow: UUID + :param is_backchannel: + :type is_backchannel: bool + :param issuer_override: + :type issuer_override: str + :param logout_method: + :type logout_method: SAMLLogoutMethods + :param name: + :type name: str + :param name_id_mapping: + :type name_id_mapping: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param property_mappings: + :type property_mappings: List[UUID] + :param search: A search term. + :type search: str + :param session_valid_not_on_or_after: + :type session_valid_not_on_or_after: str + :param sign_assertion: + :type sign_assertion: bool + :param sign_logout_request: + :type sign_logout_request: bool + :param sign_logout_response: + :type sign_logout_response: bool + :param sign_response: + :type sign_response: bool + :param signature_algorithm: + :type signature_algorithm: SignatureAlgorithmEnum + :param signing_kp: + :type signing_kp: UUID + :param sls_binding: + :type sls_binding: SAMLBindingsEnum + :param sls_url: + :type sls_url: str + :param sp_binding: + :type sp_binding: SAMLBindingsEnum + :param verification_kp: + :type verification_kp: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_list_serialize( + acs_url=acs_url, + assertion_valid_not_before=assertion_valid_not_before, + assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, + audience=audience, + authentication_flow=authentication_flow, + authn_context_class_ref_mapping=authn_context_class_ref_mapping, + authorization_flow=authorization_flow, + backchannel_application=backchannel_application, + default_name_id_policy=default_name_id_policy, + default_relay_state=default_relay_state, + digest_algorithm=digest_algorithm, + encryption_kp=encryption_kp, + invalidation_flow=invalidation_flow, + is_backchannel=is_backchannel, + issuer_override=issuer_override, + logout_method=logout_method, + name=name, + name_id_mapping=name_id_mapping, + ordering=ordering, + page=page, + page_size=page_size, + property_mappings=property_mappings, + search=search, + session_valid_not_on_or_after=session_valid_not_on_or_after, + sign_assertion=sign_assertion, + sign_logout_request=sign_logout_request, + sign_logout_response=sign_logout_response, + sign_response=sign_response, + signature_algorithm=signature_algorithm, + signing_kp=signing_kp, + sls_binding=sls_binding, + sls_url=sls_url, + sp_binding=sp_binding, + verification_kp=verification_kp, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWSFederationProviderList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_wsfed_list_serialize( + self, + acs_url, + assertion_valid_not_before, + assertion_valid_not_on_or_after, + audience, + authentication_flow, + authn_context_class_ref_mapping, + authorization_flow, + backchannel_application, + default_name_id_policy, + default_relay_state, + digest_algorithm, + encryption_kp, + invalidation_flow, + is_backchannel, + issuer_override, + logout_method, + name, + name_id_mapping, + ordering, + page, + page_size, + property_mappings, + search, + session_valid_not_on_or_after, + sign_assertion, + sign_logout_request, + sign_logout_response, + sign_response, + signature_algorithm, + signing_kp, + sls_binding, + sls_url, + sp_binding, + verification_kp, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'property_mappings': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if acs_url is not None: + + _query_params.append(('acs_url', acs_url)) + + if assertion_valid_not_before is not None: + + _query_params.append(('assertion_valid_not_before', assertion_valid_not_before)) + + if assertion_valid_not_on_or_after is not None: + + _query_params.append(('assertion_valid_not_on_or_after', assertion_valid_not_on_or_after)) + + if audience is not None: + + _query_params.append(('audience', audience)) + + if authentication_flow is not None: + + _query_params.append(('authentication_flow', authentication_flow)) + + if authn_context_class_ref_mapping is not None: + + _query_params.append(('authn_context_class_ref_mapping', authn_context_class_ref_mapping)) + + if authorization_flow is not None: + + _query_params.append(('authorization_flow', authorization_flow)) + + if backchannel_application is not None: + + _query_params.append(('backchannel_application', backchannel_application)) + + if default_name_id_policy is not None: + + _query_params.append(('default_name_id_policy', default_name_id_policy.value)) + + if default_relay_state is not None: + + _query_params.append(('default_relay_state', default_relay_state)) + + if digest_algorithm is not None: + + _query_params.append(('digest_algorithm', digest_algorithm.value)) + + if encryption_kp is not None: + + _query_params.append(('encryption_kp', encryption_kp)) + + if invalidation_flow is not None: + + _query_params.append(('invalidation_flow', invalidation_flow)) + + if is_backchannel is not None: + + _query_params.append(('is_backchannel', is_backchannel)) + + if issuer_override is not None: + + _query_params.append(('issuer_override', issuer_override)) + + if logout_method is not None: + + _query_params.append(('logout_method', logout_method.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if name_id_mapping is not None: + + _query_params.append(('name_id_mapping', name_id_mapping)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if property_mappings is not None: + + _query_params.append(('property_mappings', property_mappings)) + + if search is not None: + + _query_params.append(('search', search)) + + if session_valid_not_on_or_after is not None: + + _query_params.append(('session_valid_not_on_or_after', session_valid_not_on_or_after)) + + if sign_assertion is not None: + + _query_params.append(('sign_assertion', sign_assertion)) + + if sign_logout_request is not None: + + _query_params.append(('sign_logout_request', sign_logout_request)) + + if sign_logout_response is not None: + + _query_params.append(('sign_logout_response', sign_logout_response)) + + if sign_response is not None: + + _query_params.append(('sign_response', sign_response)) + + if signature_algorithm is not None: + + _query_params.append(('signature_algorithm', signature_algorithm.value)) + + if signing_kp is not None: + + _query_params.append(('signing_kp', signing_kp)) + + if sls_binding is not None: + + _query_params.append(('sls_binding', sls_binding.value)) + + if sls_url is not None: + + _query_params.append(('sls_url', sls_url)) + + if sp_binding is not None: + + _query_params.append(('sp_binding', sp_binding.value)) + + if verification_kp is not None: + + _query_params.append(('verification_kp', verification_kp)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/wsfed/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_wsfed_metadata_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + download: Optional[StrictBool] = None, + force_binding: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLMetadata: + """providers_wsfed_metadata_retrieve + + Return metadata as XML string + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param download: + :type download: bool + :param force_binding: + :type force_binding: ForceBindingEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_metadata_retrieve_serialize( + id=id, + download=download, + force_binding=force_binding, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLMetadata", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_wsfed_metadata_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + download: Optional[StrictBool] = None, + force_binding: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLMetadata]: + """providers_wsfed_metadata_retrieve + + Return metadata as XML string + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param download: + :type download: bool + :param force_binding: + :type force_binding: ForceBindingEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_metadata_retrieve_serialize( + id=id, + download=download, + force_binding=force_binding, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLMetadata", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_wsfed_metadata_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + download: Optional[StrictBool] = None, + force_binding: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_wsfed_metadata_retrieve + + Return metadata as XML string + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param download: + :type download: bool + :param force_binding: + :type force_binding: ForceBindingEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_metadata_retrieve_serialize( + id=id, + download=download, + force_binding=force_binding, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLMetadata", + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_wsfed_metadata_retrieve_serialize( + self, + id, + download, + force_binding, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + if download is not None: + + _query_params.append(('download', download)) + + if force_binding is not None: + + _query_params.append(('force_binding', force_binding.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json', + 'application/xml' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/wsfed/{id}/metadata/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_wsfed_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + patched_ws_federation_provider_request: Optional[PatchedWSFederationProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WSFederationProvider: + """providers_wsfed_partial_update + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param patched_ws_federation_provider_request: + :type patched_ws_federation_provider_request: PatchedWSFederationProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_partial_update_serialize( + id=id, + patched_ws_federation_provider_request=patched_ws_federation_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_wsfed_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + patched_ws_federation_provider_request: Optional[PatchedWSFederationProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WSFederationProvider]: + """providers_wsfed_partial_update + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param patched_ws_federation_provider_request: + :type patched_ws_federation_provider_request: PatchedWSFederationProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_partial_update_serialize( + id=id, + patched_ws_federation_provider_request=patched_ws_federation_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_wsfed_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + patched_ws_federation_provider_request: Optional[PatchedWSFederationProviderRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_wsfed_partial_update + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param patched_ws_federation_provider_request: + :type patched_ws_federation_provider_request: PatchedWSFederationProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_partial_update_serialize( + id=id, + patched_ws_federation_provider_request=patched_ws_federation_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_wsfed_partial_update_serialize( + self, + id, + patched_ws_federation_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_ws_federation_provider_request is not None: + _body_params = patched_ws_federation_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/providers/wsfed/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_wsfed_preview_user_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PropertyMappingPreview: + """providers_wsfed_preview_user_retrieve + + Preview user data for provider + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_preview_user_retrieve_serialize( + id=id, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingPreview", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_wsfed_preview_user_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PropertyMappingPreview]: + """providers_wsfed_preview_user_retrieve + + Preview user data for provider + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_preview_user_retrieve_serialize( + id=id, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingPreview", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_wsfed_preview_user_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + for_user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_wsfed_preview_user_retrieve + + Preview user data for provider + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param for_user: + :type for_user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_preview_user_retrieve_serialize( + id=id, + for_user=for_user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PropertyMappingPreview", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_wsfed_preview_user_retrieve_serialize( + self, + id, + for_user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + if for_user is not None: + + _query_params.append(('for_user', for_user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/wsfed/{id}/preview_user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_wsfed_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WSFederationProvider: + """providers_wsfed_retrieve + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_wsfed_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WSFederationProvider]: + """providers_wsfed_retrieve + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_wsfed_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_wsfed_retrieve + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_wsfed_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/wsfed/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_wsfed_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + ws_federation_provider_request: WSFederationProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WSFederationProvider: + """providers_wsfed_update + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param ws_federation_provider_request: (required) + :type ws_federation_provider_request: WSFederationProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_update_serialize( + id=id, + ws_federation_provider_request=ws_federation_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_wsfed_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + ws_federation_provider_request: WSFederationProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WSFederationProvider]: + """providers_wsfed_update + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param ws_federation_provider_request: (required) + :type ws_federation_provider_request: WSFederationProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_update_serialize( + id=id, + ws_federation_provider_request=ws_federation_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_wsfed_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + ws_federation_provider_request: WSFederationProviderRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_wsfed_update + + WSFederationProvider Viewset + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param ws_federation_provider_request: (required) + :type ws_federation_provider_request: WSFederationProviderRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_update_serialize( + id=id, + ws_federation_provider_request=ws_federation_provider_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WSFederationProvider", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_wsfed_update_serialize( + self, + id, + ws_federation_provider_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ws_federation_provider_request is not None: + _body_params = ws_federation_provider_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/providers/wsfed/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def providers_wsfed_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """providers_wsfed_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def providers_wsfed_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """providers_wsfed_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def providers_wsfed_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this WS-Federation Provider.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """providers_wsfed_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this WS-Federation Provider. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._providers_wsfed_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _providers_wsfed_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/providers/wsfed/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/rac_api.py b/authentik_client/api/rac_api.py new file mode 100644 index 000000000..f1114ee96 --- /dev/null +++ b/authentik_client/api/rac_api.py @@ -0,0 +1,3852 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.connection_token import ConnectionToken +from authentik_client.models.connection_token_request import ConnectionTokenRequest +from authentik_client.models.endpoint import Endpoint +from authentik_client.models.endpoint_request import EndpointRequest +from authentik_client.models.paginated_connection_token_list import PaginatedConnectionTokenList +from authentik_client.models.paginated_endpoint_list import PaginatedEndpointList +from authentik_client.models.patched_connection_token_request import PatchedConnectionTokenRequest +from authentik_client.models.patched_endpoint_request import PatchedEndpointRequest +from authentik_client.models.used_by import UsedBy + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class RacApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def rac_connection_tokens_destroy( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """rac_connection_tokens_destroy + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_destroy_serialize( + connection_token_uuid=connection_token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_connection_tokens_destroy_with_http_info( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """rac_connection_tokens_destroy + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_destroy_serialize( + connection_token_uuid=connection_token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_connection_tokens_destroy_without_preload_content( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_connection_tokens_destroy + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_destroy_serialize( + connection_token_uuid=connection_token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_connection_tokens_destroy_serialize( + self, + connection_token_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connection_token_uuid is not None: + _path_params['connection_token_uuid'] = connection_token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/rac/connection_tokens/{connection_token_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_connection_tokens_list( + self, + endpoint: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session__user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedConnectionTokenList: + """rac_connection_tokens_list + + ConnectionToken Viewset + + :param endpoint: + :type endpoint: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param session__user: + :type session__user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_list_serialize( + endpoint=endpoint, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + session__user=session__user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedConnectionTokenList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_connection_tokens_list_with_http_info( + self, + endpoint: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session__user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedConnectionTokenList]: + """rac_connection_tokens_list + + ConnectionToken Viewset + + :param endpoint: + :type endpoint: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param session__user: + :type session__user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_list_serialize( + endpoint=endpoint, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + session__user=session__user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedConnectionTokenList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_connection_tokens_list_without_preload_content( + self, + endpoint: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session__user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_connection_tokens_list + + ConnectionToken Viewset + + :param endpoint: + :type endpoint: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param session__user: + :type session__user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_list_serialize( + endpoint=endpoint, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + session__user=session__user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedConnectionTokenList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_connection_tokens_list_serialize( + self, + endpoint, + ordering, + page, + page_size, + provider, + search, + session__user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if endpoint is not None: + + _query_params.append(('endpoint', endpoint)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider is not None: + + _query_params.append(('provider', provider)) + + if search is not None: + + _query_params.append(('search', search)) + + if session__user is not None: + + _query_params.append(('session__user', session__user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rac/connection_tokens/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_connection_tokens_partial_update( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + patched_connection_token_request: Optional[PatchedConnectionTokenRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ConnectionToken: + """rac_connection_tokens_partial_update + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param patched_connection_token_request: + :type patched_connection_token_request: PatchedConnectionTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_partial_update_serialize( + connection_token_uuid=connection_token_uuid, + patched_connection_token_request=patched_connection_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConnectionToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_connection_tokens_partial_update_with_http_info( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + patched_connection_token_request: Optional[PatchedConnectionTokenRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ConnectionToken]: + """rac_connection_tokens_partial_update + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param patched_connection_token_request: + :type patched_connection_token_request: PatchedConnectionTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_partial_update_serialize( + connection_token_uuid=connection_token_uuid, + patched_connection_token_request=patched_connection_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConnectionToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_connection_tokens_partial_update_without_preload_content( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + patched_connection_token_request: Optional[PatchedConnectionTokenRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_connection_tokens_partial_update + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param patched_connection_token_request: + :type patched_connection_token_request: PatchedConnectionTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_partial_update_serialize( + connection_token_uuid=connection_token_uuid, + patched_connection_token_request=patched_connection_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConnectionToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_connection_tokens_partial_update_serialize( + self, + connection_token_uuid, + patched_connection_token_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connection_token_uuid is not None: + _path_params['connection_token_uuid'] = connection_token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_connection_token_request is not None: + _body_params = patched_connection_token_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/rac/connection_tokens/{connection_token_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_connection_tokens_retrieve( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ConnectionToken: + """rac_connection_tokens_retrieve + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_retrieve_serialize( + connection_token_uuid=connection_token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConnectionToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_connection_tokens_retrieve_with_http_info( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ConnectionToken]: + """rac_connection_tokens_retrieve + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_retrieve_serialize( + connection_token_uuid=connection_token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConnectionToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_connection_tokens_retrieve_without_preload_content( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_connection_tokens_retrieve + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_retrieve_serialize( + connection_token_uuid=connection_token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConnectionToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_connection_tokens_retrieve_serialize( + self, + connection_token_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connection_token_uuid is not None: + _path_params['connection_token_uuid'] = connection_token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rac/connection_tokens/{connection_token_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_connection_tokens_update( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + connection_token_request: ConnectionTokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ConnectionToken: + """rac_connection_tokens_update + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param connection_token_request: (required) + :type connection_token_request: ConnectionTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_update_serialize( + connection_token_uuid=connection_token_uuid, + connection_token_request=connection_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConnectionToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_connection_tokens_update_with_http_info( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + connection_token_request: ConnectionTokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ConnectionToken]: + """rac_connection_tokens_update + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param connection_token_request: (required) + :type connection_token_request: ConnectionTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_update_serialize( + connection_token_uuid=connection_token_uuid, + connection_token_request=connection_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConnectionToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_connection_tokens_update_without_preload_content( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + connection_token_request: ConnectionTokenRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_connection_tokens_update + + ConnectionToken Viewset + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param connection_token_request: (required) + :type connection_token_request: ConnectionTokenRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_update_serialize( + connection_token_uuid=connection_token_uuid, + connection_token_request=connection_token_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConnectionToken", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_connection_tokens_update_serialize( + self, + connection_token_uuid, + connection_token_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connection_token_uuid is not None: + _path_params['connection_token_uuid'] = connection_token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if connection_token_request is not None: + _body_params = connection_token_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/rac/connection_tokens/{connection_token_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_connection_tokens_used_by_list( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """rac_connection_tokens_used_by_list + + Get a list of all objects that use this object + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_used_by_list_serialize( + connection_token_uuid=connection_token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_connection_tokens_used_by_list_with_http_info( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """rac_connection_tokens_used_by_list + + Get a list of all objects that use this object + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_used_by_list_serialize( + connection_token_uuid=connection_token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_connection_tokens_used_by_list_without_preload_content( + self, + connection_token_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Connection token.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_connection_tokens_used_by_list + + Get a list of all objects that use this object + + :param connection_token_uuid: A UUID string identifying this RAC Connection token. (required) + :type connection_token_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_connection_tokens_used_by_list_serialize( + connection_token_uuid=connection_token_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_connection_tokens_used_by_list_serialize( + self, + connection_token_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if connection_token_uuid is not None: + _path_params['connection_token_uuid'] = connection_token_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rac/connection_tokens/{connection_token_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_endpoints_create( + self, + endpoint_request: EndpointRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Endpoint: + """rac_endpoints_create + + Endpoint Viewset + + :param endpoint_request: (required) + :type endpoint_request: EndpointRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_create_serialize( + endpoint_request=endpoint_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_endpoints_create_with_http_info( + self, + endpoint_request: EndpointRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Endpoint]: + """rac_endpoints_create + + Endpoint Viewset + + :param endpoint_request: (required) + :type endpoint_request: EndpointRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_create_serialize( + endpoint_request=endpoint_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_endpoints_create_without_preload_content( + self, + endpoint_request: EndpointRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_endpoints_create + + Endpoint Viewset + + :param endpoint_request: (required) + :type endpoint_request: EndpointRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_create_serialize( + endpoint_request=endpoint_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_endpoints_create_serialize( + self, + endpoint_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if endpoint_request is not None: + _body_params = endpoint_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/rac/endpoints/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_endpoints_destroy( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """rac_endpoints_destroy + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_endpoints_destroy_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """rac_endpoints_destroy + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_endpoints_destroy_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_endpoints_destroy + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_destroy_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_endpoints_destroy_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/rac/endpoints/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_endpoints_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + superuser_full_list: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedEndpointList: + """rac_endpoints_list + + List accessible endpoints + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param superuser_full_list: + :type superuser_full_list: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + superuser_full_list=superuser_full_list, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEndpointList", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_endpoints_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + superuser_full_list: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedEndpointList]: + """rac_endpoints_list + + List accessible endpoints + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param superuser_full_list: + :type superuser_full_list: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + superuser_full_list=superuser_full_list, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEndpointList", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_endpoints_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + superuser_full_list: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_endpoints_list + + List accessible endpoints + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param superuser_full_list: + :type superuser_full_list: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + superuser_full_list=superuser_full_list, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEndpointList", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_endpoints_list_serialize( + self, + name, + ordering, + page, + page_size, + provider, + search, + superuser_full_list, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider is not None: + + _query_params.append(('provider', provider)) + + if search is not None: + + _query_params.append(('search', search)) + + if superuser_full_list is not None: + + _query_params.append(('superuser_full_list', superuser_full_list)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rac/endpoints/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_endpoints_partial_update( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + patched_endpoint_request: Optional[PatchedEndpointRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Endpoint: + """rac_endpoints_partial_update + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param patched_endpoint_request: + :type patched_endpoint_request: PatchedEndpointRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_endpoint_request=patched_endpoint_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_endpoints_partial_update_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + patched_endpoint_request: Optional[PatchedEndpointRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Endpoint]: + """rac_endpoints_partial_update + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param patched_endpoint_request: + :type patched_endpoint_request: PatchedEndpointRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_endpoint_request=patched_endpoint_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_endpoints_partial_update_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + patched_endpoint_request: Optional[PatchedEndpointRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_endpoints_partial_update + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param patched_endpoint_request: + :type patched_endpoint_request: PatchedEndpointRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_partial_update_serialize( + pbm_uuid=pbm_uuid, + patched_endpoint_request=patched_endpoint_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_endpoints_partial_update_serialize( + self, + pbm_uuid, + patched_endpoint_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_endpoint_request is not None: + _body_params = patched_endpoint_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/rac/endpoints/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_endpoints_retrieve( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Endpoint: + """rac_endpoints_retrieve + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_endpoints_retrieve_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Endpoint]: + """rac_endpoints_retrieve + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_endpoints_retrieve_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_endpoints_retrieve + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_retrieve_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_endpoints_retrieve_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rac/endpoints/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_endpoints_update( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + endpoint_request: EndpointRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Endpoint: + """rac_endpoints_update + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param endpoint_request: (required) + :type endpoint_request: EndpointRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_update_serialize( + pbm_uuid=pbm_uuid, + endpoint_request=endpoint_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_endpoints_update_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + endpoint_request: EndpointRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Endpoint]: + """rac_endpoints_update + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param endpoint_request: (required) + :type endpoint_request: EndpointRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_update_serialize( + pbm_uuid=pbm_uuid, + endpoint_request=endpoint_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_endpoints_update_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + endpoint_request: EndpointRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_endpoints_update + + Endpoint Viewset + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param endpoint_request: (required) + :type endpoint_request: EndpointRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_update_serialize( + pbm_uuid=pbm_uuid, + endpoint_request=endpoint_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Endpoint", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_endpoints_update_serialize( + self, + pbm_uuid, + endpoint_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if endpoint_request is not None: + _body_params = endpoint_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/rac/endpoints/{pbm_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rac_endpoints_used_by_list( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """rac_endpoints_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rac_endpoints_used_by_list_with_http_info( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """rac_endpoints_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rac_endpoints_used_by_list_without_preload_content( + self, + pbm_uuid: Annotated[UUID, Field(description="A UUID string identifying this RAC Endpoint.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rac_endpoints_used_by_list + + Get a list of all objects that use this object + + :param pbm_uuid: A UUID string identifying this RAC Endpoint. (required) + :type pbm_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rac_endpoints_used_by_list_serialize( + pbm_uuid=pbm_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rac_endpoints_used_by_list_serialize( + self, + pbm_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if pbm_uuid is not None: + _path_params['pbm_uuid'] = pbm_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rac/endpoints/{pbm_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/rbac_api.py b/authentik_client/api/rbac_api.py new file mode 100644 index 000000000..162993dc5 --- /dev/null +++ b/authentik_client/api/rbac_api.py @@ -0,0 +1,6690 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.initial_permissions import InitialPermissions +from authentik_client.models.initial_permissions_request import InitialPermissionsRequest +from authentik_client.models.paginated_extra_role_object_permission_list import PaginatedExtraRoleObjectPermissionList +from authentik_client.models.paginated_initial_permissions_list import PaginatedInitialPermissionsList +from authentik_client.models.paginated_permission_list import PaginatedPermissionList +from authentik_client.models.paginated_role_assigned_object_permission_list import PaginatedRoleAssignedObjectPermissionList +from authentik_client.models.paginated_role_list import PaginatedRoleList +from authentik_client.models.patched_initial_permissions_request import PatchedInitialPermissionsRequest +from authentik_client.models.patched_permission_assign_request import PatchedPermissionAssignRequest +from authentik_client.models.patched_role_request import PatchedRoleRequest +from authentik_client.models.permission import Permission +from authentik_client.models.permission_assign_request import PermissionAssignRequest +from authentik_client.models.permission_assign_result import PermissionAssignResult +from authentik_client.models.role import Role +from authentik_client.models.role_request import RoleRequest +from authentik_client.models.used_by import UsedBy +from authentik_client.models.user_account_serializer_for_role_request import UserAccountSerializerForRoleRequest + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class RbacApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def rbac_initial_permissions_create( + self, + initial_permissions_request: InitialPermissionsRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> InitialPermissions: + """rbac_initial_permissions_create + + InitialPermissions viewset + + :param initial_permissions_request: (required) + :type initial_permissions_request: InitialPermissionsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_create_serialize( + initial_permissions_request=initial_permissions_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_initial_permissions_create_with_http_info( + self, + initial_permissions_request: InitialPermissionsRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[InitialPermissions]: + """rbac_initial_permissions_create + + InitialPermissions viewset + + :param initial_permissions_request: (required) + :type initial_permissions_request: InitialPermissionsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_create_serialize( + initial_permissions_request=initial_permissions_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_initial_permissions_create_without_preload_content( + self, + initial_permissions_request: InitialPermissionsRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_initial_permissions_create + + InitialPermissions viewset + + :param initial_permissions_request: (required) + :type initial_permissions_request: InitialPermissionsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_create_serialize( + initial_permissions_request=initial_permissions_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_initial_permissions_create_serialize( + self, + initial_permissions_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if initial_permissions_request is not None: + _body_params = initial_permissions_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/rbac/initial_permissions/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_initial_permissions_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """rbac_initial_permissions_destroy + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_initial_permissions_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """rbac_initial_permissions_destroy + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_initial_permissions_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_initial_permissions_destroy + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_initial_permissions_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/rbac/initial_permissions/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_initial_permissions_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedInitialPermissionsList: + """rbac_initial_permissions_list + + InitialPermissions viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedInitialPermissionsList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_initial_permissions_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedInitialPermissionsList]: + """rbac_initial_permissions_list + + InitialPermissions viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedInitialPermissionsList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_initial_permissions_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_initial_permissions_list + + InitialPermissions viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedInitialPermissionsList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_initial_permissions_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/initial_permissions/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_initial_permissions_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + patched_initial_permissions_request: Optional[PatchedInitialPermissionsRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> InitialPermissions: + """rbac_initial_permissions_partial_update + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param patched_initial_permissions_request: + :type patched_initial_permissions_request: PatchedInitialPermissionsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_partial_update_serialize( + id=id, + patched_initial_permissions_request=patched_initial_permissions_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_initial_permissions_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + patched_initial_permissions_request: Optional[PatchedInitialPermissionsRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[InitialPermissions]: + """rbac_initial_permissions_partial_update + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param patched_initial_permissions_request: + :type patched_initial_permissions_request: PatchedInitialPermissionsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_partial_update_serialize( + id=id, + patched_initial_permissions_request=patched_initial_permissions_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_initial_permissions_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + patched_initial_permissions_request: Optional[PatchedInitialPermissionsRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_initial_permissions_partial_update + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param patched_initial_permissions_request: + :type patched_initial_permissions_request: PatchedInitialPermissionsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_partial_update_serialize( + id=id, + patched_initial_permissions_request=patched_initial_permissions_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_initial_permissions_partial_update_serialize( + self, + id, + patched_initial_permissions_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_initial_permissions_request is not None: + _body_params = patched_initial_permissions_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/rbac/initial_permissions/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_initial_permissions_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> InitialPermissions: + """rbac_initial_permissions_retrieve + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_initial_permissions_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[InitialPermissions]: + """rbac_initial_permissions_retrieve + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_initial_permissions_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_initial_permissions_retrieve + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_initial_permissions_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/initial_permissions/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_initial_permissions_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + initial_permissions_request: InitialPermissionsRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> InitialPermissions: + """rbac_initial_permissions_update + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param initial_permissions_request: (required) + :type initial_permissions_request: InitialPermissionsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_update_serialize( + id=id, + initial_permissions_request=initial_permissions_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_initial_permissions_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + initial_permissions_request: InitialPermissionsRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[InitialPermissions]: + """rbac_initial_permissions_update + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param initial_permissions_request: (required) + :type initial_permissions_request: InitialPermissionsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_update_serialize( + id=id, + initial_permissions_request=initial_permissions_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_initial_permissions_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + initial_permissions_request: InitialPermissionsRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_initial_permissions_update + + InitialPermissions viewset + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param initial_permissions_request: (required) + :type initial_permissions_request: InitialPermissionsRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_update_serialize( + id=id, + initial_permissions_request=initial_permissions_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InitialPermissions", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_initial_permissions_update_serialize( + self, + id, + initial_permissions_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if initial_permissions_request is not None: + _body_params = initial_permissions_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/rbac/initial_permissions/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_initial_permissions_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """rbac_initial_permissions_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_initial_permissions_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """rbac_initial_permissions_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_initial_permissions_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Initial Permissions.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_initial_permissions_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Initial Permissions. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_initial_permissions_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_initial_permissions_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/initial_permissions/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_permissions_assigned_by_roles_assign( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + permission_assign_request: PermissionAssignRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[PermissionAssignResult]: + """rbac_permissions_assigned_by_roles_assign + + Assign permission(s) to role. When `object_pk` is set, the permissions are only assigned to the specific object, otherwise they are assigned globally. + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param permission_assign_request: (required) + :type permission_assign_request: PermissionAssignRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_assigned_by_roles_assign_serialize( + uuid=uuid, + permission_assign_request=permission_assign_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[PermissionAssignResult]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_permissions_assigned_by_roles_assign_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + permission_assign_request: PermissionAssignRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[PermissionAssignResult]]: + """rbac_permissions_assigned_by_roles_assign + + Assign permission(s) to role. When `object_pk` is set, the permissions are only assigned to the specific object, otherwise they are assigned globally. + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param permission_assign_request: (required) + :type permission_assign_request: PermissionAssignRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_assigned_by_roles_assign_serialize( + uuid=uuid, + permission_assign_request=permission_assign_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[PermissionAssignResult]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_permissions_assigned_by_roles_assign_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + permission_assign_request: PermissionAssignRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_permissions_assigned_by_roles_assign + + Assign permission(s) to role. When `object_pk` is set, the permissions are only assigned to the specific object, otherwise they are assigned globally. + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param permission_assign_request: (required) + :type permission_assign_request: PermissionAssignRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_assigned_by_roles_assign_serialize( + uuid=uuid, + permission_assign_request=permission_assign_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[PermissionAssignResult]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_permissions_assigned_by_roles_assign_serialize( + self, + uuid, + permission_assign_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if permission_assign_request is not None: + _body_params = permission_assign_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/rbac/permissions/assigned_by_roles/{uuid}/assign/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_permissions_assigned_by_roles_list( + self, + model: StrictStr, + object_pk: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedRoleAssignedObjectPermissionList: + """rbac_permissions_assigned_by_roles_list + + Get assigned object permissions for a single object + + :param model: (required) + :type model: str + :param object_pk: + :type object_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_assigned_by_roles_list_serialize( + model=model, + object_pk=object_pk, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRoleAssignedObjectPermissionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_permissions_assigned_by_roles_list_with_http_info( + self, + model: StrictStr, + object_pk: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedRoleAssignedObjectPermissionList]: + """rbac_permissions_assigned_by_roles_list + + Get assigned object permissions for a single object + + :param model: (required) + :type model: str + :param object_pk: + :type object_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_assigned_by_roles_list_serialize( + model=model, + object_pk=object_pk, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRoleAssignedObjectPermissionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_permissions_assigned_by_roles_list_without_preload_content( + self, + model: StrictStr, + object_pk: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_permissions_assigned_by_roles_list + + Get assigned object permissions for a single object + + :param model: (required) + :type model: str + :param object_pk: + :type object_pk: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_assigned_by_roles_list_serialize( + model=model, + object_pk=object_pk, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRoleAssignedObjectPermissionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_permissions_assigned_by_roles_list_serialize( + self, + model, + object_pk, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if model is not None: + + _query_params.append(('model', model)) + + if object_pk is not None: + + _query_params.append(('object_pk', object_pk)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/permissions/assigned_by_roles/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_permissions_assigned_by_roles_unassign_partial_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + patched_permission_assign_request: Optional[PatchedPermissionAssignRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """rbac_permissions_assigned_by_roles_unassign_partial_update + + Unassign permission(s) to role. When `object_pk` is set, the permissions are only assigned to the specific object, otherwise they are assigned globally. + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param patched_permission_assign_request: + :type patched_permission_assign_request: PatchedPermissionAssignRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_assigned_by_roles_unassign_partial_update_serialize( + uuid=uuid, + patched_permission_assign_request=patched_permission_assign_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_permissions_assigned_by_roles_unassign_partial_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + patched_permission_assign_request: Optional[PatchedPermissionAssignRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """rbac_permissions_assigned_by_roles_unassign_partial_update + + Unassign permission(s) to role. When `object_pk` is set, the permissions are only assigned to the specific object, otherwise they are assigned globally. + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param patched_permission_assign_request: + :type patched_permission_assign_request: PatchedPermissionAssignRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_assigned_by_roles_unassign_partial_update_serialize( + uuid=uuid, + patched_permission_assign_request=patched_permission_assign_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_permissions_assigned_by_roles_unassign_partial_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + patched_permission_assign_request: Optional[PatchedPermissionAssignRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_permissions_assigned_by_roles_unassign_partial_update + + Unassign permission(s) to role. When `object_pk` is set, the permissions are only assigned to the specific object, otherwise they are assigned globally. + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param patched_permission_assign_request: + :type patched_permission_assign_request: PatchedPermissionAssignRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_assigned_by_roles_unassign_partial_update_serialize( + uuid=uuid, + patched_permission_assign_request=patched_permission_assign_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_permissions_assigned_by_roles_unassign_partial_update_serialize( + self, + uuid, + patched_permission_assign_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_permission_assign_request is not None: + _body_params = patched_permission_assign_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/rbac/permissions/assigned_by_roles/{uuid}/unassign/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_permissions_list( + self, + codename: Optional[StrictStr] = None, + content_type__app_label: Optional[StrictStr] = None, + content_type__model: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + role: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPermissionList: + """rbac_permissions_list + + Read-only list of all permissions, filterable by model and app + + :param codename: + :type codename: str + :param content_type__app_label: + :type content_type__app_label: str + :param content_type__model: + :type content_type__model: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param role: + :type role: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_list_serialize( + codename=codename, + content_type__app_label=content_type__app_label, + content_type__model=content_type__model, + ordering=ordering, + page=page, + page_size=page_size, + role=role, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPermissionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_permissions_list_with_http_info( + self, + codename: Optional[StrictStr] = None, + content_type__app_label: Optional[StrictStr] = None, + content_type__model: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + role: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPermissionList]: + """rbac_permissions_list + + Read-only list of all permissions, filterable by model and app + + :param codename: + :type codename: str + :param content_type__app_label: + :type content_type__app_label: str + :param content_type__model: + :type content_type__model: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param role: + :type role: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_list_serialize( + codename=codename, + content_type__app_label=content_type__app_label, + content_type__model=content_type__model, + ordering=ordering, + page=page, + page_size=page_size, + role=role, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPermissionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_permissions_list_without_preload_content( + self, + codename: Optional[StrictStr] = None, + content_type__app_label: Optional[StrictStr] = None, + content_type__model: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + role: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_permissions_list + + Read-only list of all permissions, filterable by model and app + + :param codename: + :type codename: str + :param content_type__app_label: + :type content_type__app_label: str + :param content_type__model: + :type content_type__model: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param role: + :type role: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_list_serialize( + codename=codename, + content_type__app_label=content_type__app_label, + content_type__model=content_type__model, + ordering=ordering, + page=page, + page_size=page_size, + role=role, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPermissionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_permissions_list_serialize( + self, + codename, + content_type__app_label, + content_type__model, + ordering, + page, + page_size, + role, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if codename is not None: + + _query_params.append(('codename', codename)) + + if content_type__app_label is not None: + + _query_params.append(('content_type__app_label', content_type__app_label)) + + if content_type__model is not None: + + _query_params.append(('content_type__model', content_type__model)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if role is not None: + + _query_params.append(('role', role)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/permissions/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_permissions_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this permission.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Permission: + """rbac_permissions_retrieve + + Read-only list of all permissions, filterable by model and app + + :param id: A unique integer value identifying this permission. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Permission", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_permissions_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this permission.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Permission]: + """rbac_permissions_retrieve + + Read-only list of all permissions, filterable by model and app + + :param id: A unique integer value identifying this permission. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Permission", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_permissions_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this permission.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_permissions_retrieve + + Read-only list of all permissions, filterable by model and app + + :param id: A unique integer value identifying this permission. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Permission", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_permissions_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/permissions/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_permissions_roles_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedExtraRoleObjectPermissionList: + """rbac_permissions_roles_list + + Get a role's assigned object permissions + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param uuid: + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_roles_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedExtraRoleObjectPermissionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_permissions_roles_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedExtraRoleObjectPermissionList]: + """rbac_permissions_roles_list + + Get a role's assigned object permissions + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param uuid: + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_roles_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedExtraRoleObjectPermissionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_permissions_roles_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_permissions_roles_list + + Get a role's assigned object permissions + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param uuid: + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_permissions_roles_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedExtraRoleObjectPermissionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_permissions_roles_list_serialize( + self, + ordering, + page, + page_size, + search, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if uuid is not None: + + _query_params.append(('uuid', uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/permissions/roles/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_roles_add_user_create( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """rbac_roles_add_user_create + + Add user to role + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param user_account_serializer_for_role_request: (required) + :type user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_add_user_create_serialize( + uuid=uuid, + user_account_serializer_for_role_request=user_account_serializer_for_role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_roles_add_user_create_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """rbac_roles_add_user_create + + Add user to role + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param user_account_serializer_for_role_request: (required) + :type user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_add_user_create_serialize( + uuid=uuid, + user_account_serializer_for_role_request=user_account_serializer_for_role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_roles_add_user_create_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_roles_add_user_create + + Add user to role + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param user_account_serializer_for_role_request: (required) + :type user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_add_user_create_serialize( + uuid=uuid, + user_account_serializer_for_role_request=user_account_serializer_for_role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_roles_add_user_create_serialize( + self, + uuid, + user_account_serializer_for_role_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_account_serializer_for_role_request is not None: + _body_params = user_account_serializer_for_role_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/rbac/roles/{uuid}/add_user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_roles_create( + self, + role_request: RoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Role: + """rbac_roles_create + + Role viewset + + :param role_request: (required) + :type role_request: RoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_create_serialize( + role_request=role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_roles_create_with_http_info( + self, + role_request: RoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Role]: + """rbac_roles_create + + Role viewset + + :param role_request: (required) + :type role_request: RoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_create_serialize( + role_request=role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_roles_create_without_preload_content( + self, + role_request: RoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_roles_create + + Role viewset + + :param role_request: (required) + :type role_request: RoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_create_serialize( + role_request=role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_roles_create_serialize( + self, + role_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if role_request is not None: + _body_params = role_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/rbac/roles/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_roles_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """rbac_roles_destroy + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_roles_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """rbac_roles_destroy + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_roles_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_roles_destroy + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_roles_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/rbac/roles/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_roles_list( + self, + groups: Optional[UUID] = None, + inherited: Annotated[Optional[StrictBool], Field(description="Include inherited roles (requires users or groups filter)")] = None, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + users: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedRoleList: + """rbac_roles_list + + Role viewset + + :param groups: + :type groups: UUID + :param inherited: Include inherited roles (requires users or groups filter) + :type inherited: bool + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param users: + :type users: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_list_serialize( + groups=groups, + inherited=inherited, + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + users=users, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRoleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_roles_list_with_http_info( + self, + groups: Optional[UUID] = None, + inherited: Annotated[Optional[StrictBool], Field(description="Include inherited roles (requires users or groups filter)")] = None, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + users: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedRoleList]: + """rbac_roles_list + + Role viewset + + :param groups: + :type groups: UUID + :param inherited: Include inherited roles (requires users or groups filter) + :type inherited: bool + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param users: + :type users: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_list_serialize( + groups=groups, + inherited=inherited, + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + users=users, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRoleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_roles_list_without_preload_content( + self, + groups: Optional[UUID] = None, + inherited: Annotated[Optional[StrictBool], Field(description="Include inherited roles (requires users or groups filter)")] = None, + managed: Optional[List[StrictStr]] = None, + managed__isnull: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + users: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_roles_list + + Role viewset + + :param groups: + :type groups: UUID + :param inherited: Include inherited roles (requires users or groups filter) + :type inherited: bool + :param managed: + :type managed: List[str] + :param managed__isnull: + :type managed__isnull: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param users: + :type users: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_list_serialize( + groups=groups, + inherited=inherited, + managed=managed, + managed__isnull=managed__isnull, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + users=users, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRoleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_roles_list_serialize( + self, + groups, + inherited, + managed, + managed__isnull, + name, + ordering, + page, + page_size, + search, + users, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'managed': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if groups is not None: + + _query_params.append(('groups', groups)) + + if inherited is not None: + + _query_params.append(('inherited', inherited)) + + if managed is not None: + + _query_params.append(('managed', managed)) + + if managed__isnull is not None: + + _query_params.append(('managed__isnull', managed__isnull)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if users is not None: + + _query_params.append(('users', users)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/roles/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_roles_partial_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + patched_role_request: Optional[PatchedRoleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Role: + """rbac_roles_partial_update + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param patched_role_request: + :type patched_role_request: PatchedRoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_partial_update_serialize( + uuid=uuid, + patched_role_request=patched_role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_roles_partial_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + patched_role_request: Optional[PatchedRoleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Role]: + """rbac_roles_partial_update + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param patched_role_request: + :type patched_role_request: PatchedRoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_partial_update_serialize( + uuid=uuid, + patched_role_request=patched_role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_roles_partial_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + patched_role_request: Optional[PatchedRoleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_roles_partial_update + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param patched_role_request: + :type patched_role_request: PatchedRoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_partial_update_serialize( + uuid=uuid, + patched_role_request=patched_role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_roles_partial_update_serialize( + self, + uuid, + patched_role_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_role_request is not None: + _body_params = patched_role_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/rbac/roles/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_roles_remove_user_create( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """rbac_roles_remove_user_create + + Remove user from role + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param user_account_serializer_for_role_request: (required) + :type user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_remove_user_create_serialize( + uuid=uuid, + user_account_serializer_for_role_request=user_account_serializer_for_role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_roles_remove_user_create_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """rbac_roles_remove_user_create + + Remove user from role + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param user_account_serializer_for_role_request: (required) + :type user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_remove_user_create_serialize( + uuid=uuid, + user_account_serializer_for_role_request=user_account_serializer_for_role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_roles_remove_user_create_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_roles_remove_user_create + + Remove user from role + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param user_account_serializer_for_role_request: (required) + :type user_account_serializer_for_role_request: UserAccountSerializerForRoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_remove_user_create_serialize( + uuid=uuid, + user_account_serializer_for_role_request=user_account_serializer_for_role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_roles_remove_user_create_serialize( + self, + uuid, + user_account_serializer_for_role_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_account_serializer_for_role_request is not None: + _body_params = user_account_serializer_for_role_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/rbac/roles/{uuid}/remove_user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_roles_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Role: + """rbac_roles_retrieve + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_roles_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Role]: + """rbac_roles_retrieve + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_roles_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_roles_retrieve + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_roles_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/roles/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_roles_update( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + role_request: RoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Role: + """rbac_roles_update + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param role_request: (required) + :type role_request: RoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_update_serialize( + uuid=uuid, + role_request=role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_roles_update_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + role_request: RoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Role]: + """rbac_roles_update + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param role_request: (required) + :type role_request: RoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_update_serialize( + uuid=uuid, + role_request=role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_roles_update_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + role_request: RoleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_roles_update + + Role viewset + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param role_request: (required) + :type role_request: RoleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_update_serialize( + uuid=uuid, + role_request=role_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Role", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_roles_update_serialize( + self, + uuid, + role_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if role_request is not None: + _body_params = role_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/rbac/roles/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def rbac_roles_used_by_list( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """rbac_roles_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def rbac_roles_used_by_list_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """rbac_roles_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def rbac_roles_used_by_list_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this Role.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """rbac_roles_used_by_list + + Get a list of all objects that use this object + + :param uuid: A UUID string identifying this Role. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._rbac_roles_used_by_list_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _rbac_roles_used_by_list_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/rbac/roles/{uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/reports_api.py b/authentik_client/api/reports_api.py new file mode 100644 index 000000000..165114ecc --- /dev/null +++ b/authentik_client/api/reports_api.py @@ -0,0 +1,886 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictInt, StrictStr +from typing import Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.data_export import DataExport +from authentik_client.models.paginated_data_export_list import PaginatedDataExportList + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class ReportsApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def reports_exports_destroy( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Data Export.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """reports_exports_destroy + + + :param id: A UUID string identifying this Data Export. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._reports_exports_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def reports_exports_destroy_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Data Export.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """reports_exports_destroy + + + :param id: A UUID string identifying this Data Export. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._reports_exports_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def reports_exports_destroy_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Data Export.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """reports_exports_destroy + + + :param id: A UUID string identifying this Data Export. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._reports_exports_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _reports_exports_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/reports/exports/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def reports_exports_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDataExportList: + """reports_exports_list + + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._reports_exports_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDataExportList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def reports_exports_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDataExportList]: + """reports_exports_list + + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._reports_exports_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDataExportList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def reports_exports_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """reports_exports_list + + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._reports_exports_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDataExportList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _reports_exports_list_serialize( + self, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/reports/exports/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def reports_exports_retrieve( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Data Export.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DataExport: + """reports_exports_retrieve + + + :param id: A UUID string identifying this Data Export. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._reports_exports_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DataExport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def reports_exports_retrieve_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Data Export.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DataExport]: + """reports_exports_retrieve + + + :param id: A UUID string identifying this Data Export. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._reports_exports_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DataExport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def reports_exports_retrieve_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Data Export.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """reports_exports_retrieve + + + :param id: A UUID string identifying this Data Export. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._reports_exports_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DataExport", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _reports_exports_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/reports/exports/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/root_api.py b/authentik_client/api/root_api.py new file mode 100644 index 000000000..3ae564a5a --- /dev/null +++ b/authentik_client/api/root_api.py @@ -0,0 +1,288 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from authentik_client.models.config import Config + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class RootApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def root_config_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Config: + """root_config_retrieve + + Retrieve public configuration options + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._root_config_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Config", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def root_config_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Config]: + """root_config_retrieve + + Retrieve public configuration options + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._root_config_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Config", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def root_config_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """root_config_retrieve + + Retrieve public configuration options + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._root_config_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Config", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _root_config_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/root/config/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/schema_api.py b/authentik_client/api/schema_api.py new file mode 100644 index 000000000..7b61baaf5 --- /dev/null +++ b/authentik_client/api/schema_api.py @@ -0,0 +1,327 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from typing import Any, Dict, Optional +from authentik_client.models.format_enum import FormatEnum +from authentik_client.models.lang_enum import LangEnum + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class SchemaApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def schema_retrieve( + self, + format: Optional[FormatEnum] = None, + lang: Optional[LangEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Dict[str, object]: + """schema_retrieve + + OpenApi3 schema for this API. Format can be selected via content negotiation. - YAML: application/vnd.oai.openapi - JSON: application/vnd.oai.openapi+json + + :param format: + :type format: FormatEnum + :param lang: + :type lang: LangEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._schema_retrieve_serialize( + format=format, + lang=lang, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Dict[str, object]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def schema_retrieve_with_http_info( + self, + format: Optional[FormatEnum] = None, + lang: Optional[LangEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Dict[str, object]]: + """schema_retrieve + + OpenApi3 schema for this API. Format can be selected via content negotiation. - YAML: application/vnd.oai.openapi - JSON: application/vnd.oai.openapi+json + + :param format: + :type format: FormatEnum + :param lang: + :type lang: LangEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._schema_retrieve_serialize( + format=format, + lang=lang, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Dict[str, object]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def schema_retrieve_without_preload_content( + self, + format: Optional[FormatEnum] = None, + lang: Optional[LangEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """schema_retrieve + + OpenApi3 schema for this API. Format can be selected via content negotiation. - YAML: application/vnd.oai.openapi - JSON: application/vnd.oai.openapi+json + + :param format: + :type format: FormatEnum + :param lang: + :type lang: LangEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._schema_retrieve_serialize( + format=format, + lang=lang, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Dict[str, object]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _schema_retrieve_serialize( + self, + format, + lang, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if format is not None: + + _query_params.append(('format', format.value)) + + if lang is not None: + + _query_params.append(('lang', lang.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/vnd.oai.openapi', + 'application/yaml', + 'application/vnd.oai.openapi+json', + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/schema/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/sources_api.py b/authentik_client/api/sources_api.py new file mode 100644 index 000000000..53ec0093d --- /dev/null +++ b/authentik_client/api/sources_api.py @@ -0,0 +1,51640 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import Any, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.binding_type_enum import BindingTypeEnum +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection +from authentik_client.models.group_kerberos_source_connection_request import GroupKerberosSourceConnectionRequest +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection +from authentik_client.models.group_ldap_source_connection_request import GroupLDAPSourceConnectionRequest +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection +from authentik_client.models.group_o_auth_source_connection_request import GroupOAuthSourceConnectionRequest +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection +from authentik_client.models.group_plex_source_connection_request import GroupPlexSourceConnectionRequest +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection +from authentik_client.models.group_saml_source_connection_request import GroupSAMLSourceConnectionRequest +from authentik_client.models.group_source_connection import GroupSourceConnection +from authentik_client.models.group_source_connection_request import GroupSourceConnectionRequest +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection +from authentik_client.models.group_telegram_source_connection_request import GroupTelegramSourceConnectionRequest +from authentik_client.models.kerberos_source import KerberosSource +from authentik_client.models.kerberos_source_request import KerberosSourceRequest +from authentik_client.models.ldap_debug import LDAPDebug +from authentik_client.models.ldap_source import LDAPSource +from authentik_client.models.ldap_source_request import LDAPSourceRequest +from authentik_client.models.o_auth_source import OAuthSource +from authentik_client.models.o_auth_source_request import OAuthSourceRequest +from authentik_client.models.paginated_group_kerberos_source_connection_list import PaginatedGroupKerberosSourceConnectionList +from authentik_client.models.paginated_group_ldap_source_connection_list import PaginatedGroupLDAPSourceConnectionList +from authentik_client.models.paginated_group_o_auth_source_connection_list import PaginatedGroupOAuthSourceConnectionList +from authentik_client.models.paginated_group_plex_source_connection_list import PaginatedGroupPlexSourceConnectionList +from authentik_client.models.paginated_group_saml_source_connection_list import PaginatedGroupSAMLSourceConnectionList +from authentik_client.models.paginated_group_source_connection_list import PaginatedGroupSourceConnectionList +from authentik_client.models.paginated_group_telegram_source_connection_list import PaginatedGroupTelegramSourceConnectionList +from authentik_client.models.paginated_kerberos_source_list import PaginatedKerberosSourceList +from authentik_client.models.paginated_ldap_source_list import PaginatedLDAPSourceList +from authentik_client.models.paginated_o_auth_source_list import PaginatedOAuthSourceList +from authentik_client.models.paginated_plex_source_list import PaginatedPlexSourceList +from authentik_client.models.paginated_saml_source_list import PaginatedSAMLSourceList +from authentik_client.models.paginated_scim_source_group_list import PaginatedSCIMSourceGroupList +from authentik_client.models.paginated_scim_source_list import PaginatedSCIMSourceList +from authentik_client.models.paginated_scim_source_user_list import PaginatedSCIMSourceUserList +from authentik_client.models.paginated_source_list import PaginatedSourceList +from authentik_client.models.paginated_telegram_source_list import PaginatedTelegramSourceList +from authentik_client.models.paginated_user_kerberos_source_connection_list import PaginatedUserKerberosSourceConnectionList +from authentik_client.models.paginated_user_ldap_source_connection_list import PaginatedUserLDAPSourceConnectionList +from authentik_client.models.paginated_user_o_auth_source_connection_list import PaginatedUserOAuthSourceConnectionList +from authentik_client.models.paginated_user_plex_source_connection_list import PaginatedUserPlexSourceConnectionList +from authentik_client.models.paginated_user_saml_source_connection_list import PaginatedUserSAMLSourceConnectionList +from authentik_client.models.paginated_user_source_connection_list import PaginatedUserSourceConnectionList +from authentik_client.models.paginated_user_telegram_source_connection_list import PaginatedUserTelegramSourceConnectionList +from authentik_client.models.patched_group_kerberos_source_connection_request import PatchedGroupKerberosSourceConnectionRequest +from authentik_client.models.patched_group_ldap_source_connection_request import PatchedGroupLDAPSourceConnectionRequest +from authentik_client.models.patched_group_o_auth_source_connection_request import PatchedGroupOAuthSourceConnectionRequest +from authentik_client.models.patched_group_plex_source_connection_request import PatchedGroupPlexSourceConnectionRequest +from authentik_client.models.patched_group_saml_source_connection_request import PatchedGroupSAMLSourceConnectionRequest +from authentik_client.models.patched_group_source_connection_request import PatchedGroupSourceConnectionRequest +from authentik_client.models.patched_group_telegram_source_connection_request import PatchedGroupTelegramSourceConnectionRequest +from authentik_client.models.patched_kerberos_source_request import PatchedKerberosSourceRequest +from authentik_client.models.patched_ldap_source_request import PatchedLDAPSourceRequest +from authentik_client.models.patched_o_auth_source_request import PatchedOAuthSourceRequest +from authentik_client.models.patched_plex_source_request import PatchedPlexSourceRequest +from authentik_client.models.patched_saml_source_request import PatchedSAMLSourceRequest +from authentik_client.models.patched_scim_source_group_request import PatchedSCIMSourceGroupRequest +from authentik_client.models.patched_scim_source_request import PatchedSCIMSourceRequest +from authentik_client.models.patched_scim_source_user_request import PatchedSCIMSourceUserRequest +from authentik_client.models.patched_telegram_source_request import PatchedTelegramSourceRequest +from authentik_client.models.patched_user_kerberos_source_connection_request import PatchedUserKerberosSourceConnectionRequest +from authentik_client.models.patched_user_ldap_source_connection_request import PatchedUserLDAPSourceConnectionRequest +from authentik_client.models.patched_user_o_auth_source_connection_request import PatchedUserOAuthSourceConnectionRequest +from authentik_client.models.patched_user_plex_source_connection_request import PatchedUserPlexSourceConnectionRequest +from authentik_client.models.patched_user_saml_source_connection_request import PatchedUserSAMLSourceConnectionRequest +from authentik_client.models.patched_user_source_connection_request import PatchedUserSourceConnectionRequest +from authentik_client.models.patched_user_telegram_source_connection_request import PatchedUserTelegramSourceConnectionRequest +from authentik_client.models.plex_source import PlexSource +from authentik_client.models.plex_source_request import PlexSourceRequest +from authentik_client.models.plex_token_redeem_request import PlexTokenRedeemRequest +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.redirect_challenge import RedirectChallenge +from authentik_client.models.saml_metadata import SAMLMetadata +from authentik_client.models.saml_source import SAMLSource +from authentik_client.models.saml_source_request import SAMLSourceRequest +from authentik_client.models.scim_source import SCIMSource +from authentik_client.models.scim_source_group import SCIMSourceGroup +from authentik_client.models.scim_source_group_request import SCIMSourceGroupRequest +from authentik_client.models.scim_source_request import SCIMSourceRequest +from authentik_client.models.scim_source_user import SCIMSourceUser +from authentik_client.models.scim_source_user_request import SCIMSourceUserRequest +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from authentik_client.models.source import Source +from authentik_client.models.source_type import SourceType +from authentik_client.models.sync_status import SyncStatus +from authentik_client.models.telegram_auth_request import TelegramAuthRequest +from authentik_client.models.telegram_source import TelegramSource +from authentik_client.models.telegram_source_request import TelegramSourceRequest +from authentik_client.models.type_create import TypeCreate +from authentik_client.models.used_by import UsedBy +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection +from authentik_client.models.user_kerberos_source_connection_request import UserKerberosSourceConnectionRequest +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection +from authentik_client.models.user_ldap_source_connection_request import UserLDAPSourceConnectionRequest +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection +from authentik_client.models.user_o_auth_source_connection_request import UserOAuthSourceConnectionRequest +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection +from authentik_client.models.user_plex_source_connection_request import UserPlexSourceConnectionRequest +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection +from authentik_client.models.user_saml_source_connection_request import UserSAMLSourceConnectionRequest +from authentik_client.models.user_setting import UserSetting +from authentik_client.models.user_source_connection import UserSourceConnection +from authentik_client.models.user_source_connection_request import UserSourceConnectionRequest +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection +from authentik_client.models.user_telegram_source_connection_request import UserTelegramSourceConnectionRequest + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class SourcesApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def sources_all_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_all_destroy + + Prevent deletion of built-in sources + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_all_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_all_destroy + + Prevent deletion of built-in sources + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_all_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_all_destroy + + Prevent deletion of built-in sources + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_all_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/all/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_all_list( + self, + managed: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSourceList: + """sources_all_list + + Source Viewset + + :param managed: + :type managed: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_list_serialize( + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_all_list_with_http_info( + self, + managed: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSourceList]: + """sources_all_list + + Source Viewset + + :param managed: + :type managed: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_list_serialize( + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_all_list_without_preload_content( + self, + managed: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_all_list + + Source Viewset + + :param managed: + :type managed: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_list_serialize( + managed=managed, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_all_list_serialize( + self, + managed, + name, + ordering, + page, + page_size, + pbm_uuid, + search, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if managed is not None: + + _query_params.append(('managed', managed)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_all_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Source: + """sources_all_retrieve + + Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Source", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_all_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Source]: + """sources_all_retrieve + + Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Source", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_all_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_all_retrieve + + Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Source", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_all_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/all/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_all_types_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[TypeCreate]: + """sources_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_all_types_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[TypeCreate]]: + """sources_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_all_types_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_all_types_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/all/types/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_all_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_all_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_all_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_all_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_all_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_all_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_all_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/all/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_all_user_settings_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UserSetting]: + """sources_all_user_settings_list + + Get all sources the user can configure + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_user_settings_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UserSetting]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_all_user_settings_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UserSetting]]: + """sources_all_user_settings_list + + Get all sources the user can configure + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_user_settings_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UserSetting]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_all_user_settings_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_all_user_settings_list + + Get all sources the user can configure + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_all_user_settings_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UserSetting]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_all_user_settings_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/all/user_settings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_all_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_group_connections_all_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_all_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_group_connections_all_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_all_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_all_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_all_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/group_connections/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_all_list( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGroupSourceConnectionList: + """sources_group_connections_all_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_all_list_with_http_info( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGroupSourceConnectionList]: + """sources_group_connections_all_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_all_list_without_preload_content( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_all_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_all_list_serialize( + self, + group, + ordering, + page, + page_size, + search, + source__slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group is not None: + + _query_params.append(('group', group)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_all_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + patched_group_source_connection_request: Optional[PatchedGroupSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupSourceConnection: + """sources_group_connections_all_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param patched_group_source_connection_request: + :type patched_group_source_connection_request: PatchedGroupSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_partial_update_serialize( + id=id, + patched_group_source_connection_request=patched_group_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_all_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + patched_group_source_connection_request: Optional[PatchedGroupSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupSourceConnection]: + """sources_group_connections_all_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param patched_group_source_connection_request: + :type patched_group_source_connection_request: PatchedGroupSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_partial_update_serialize( + id=id, + patched_group_source_connection_request=patched_group_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_all_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + patched_group_source_connection_request: Optional[PatchedGroupSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_all_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param patched_group_source_connection_request: + :type patched_group_source_connection_request: PatchedGroupSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_partial_update_serialize( + id=id, + patched_group_source_connection_request=patched_group_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_all_partial_update_serialize( + self, + id, + patched_group_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_group_source_connection_request is not None: + _body_params = patched_group_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/group_connections/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_all_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupSourceConnection: + """sources_group_connections_all_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_all_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupSourceConnection]: + """sources_group_connections_all_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_all_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_all_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_all_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_all_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + group_source_connection_request: GroupSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupSourceConnection: + """sources_group_connections_all_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param group_source_connection_request: (required) + :type group_source_connection_request: GroupSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_update_serialize( + id=id, + group_source_connection_request=group_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_all_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + group_source_connection_request: GroupSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupSourceConnection]: + """sources_group_connections_all_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param group_source_connection_request: (required) + :type group_source_connection_request: GroupSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_update_serialize( + id=id, + group_source_connection_request=group_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_all_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + group_source_connection_request: GroupSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_all_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param group_source_connection_request: (required) + :type group_source_connection_request: GroupSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_update_serialize( + id=id, + group_source_connection_request=group_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_all_update_serialize( + self, + id, + group_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_source_connection_request is not None: + _body_params = group_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/group_connections/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_all_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_group_connections_all_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_all_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_group_connections_all_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_all_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this group source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_all_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this group source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_all_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_all_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/all/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_kerberos_create( + self, + group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupKerberosSourceConnection: + """sources_group_connections_kerberos_create + + Group-source connection Viewset + + :param group_kerberos_source_connection_request: (required) + :type group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_create_serialize( + group_kerberos_source_connection_request=group_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_kerberos_create_with_http_info( + self, + group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupKerberosSourceConnection]: + """sources_group_connections_kerberos_create + + Group-source connection Viewset + + :param group_kerberos_source_connection_request: (required) + :type group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_create_serialize( + group_kerberos_source_connection_request=group_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_kerberos_create_without_preload_content( + self, + group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_kerberos_create + + Group-source connection Viewset + + :param group_kerberos_source_connection_request: (required) + :type group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_create_serialize( + group_kerberos_source_connection_request=group_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_kerberos_create_serialize( + self, + group_kerberos_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_kerberos_source_connection_request is not None: + _body_params = group_kerberos_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/group_connections/kerberos/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_kerberos_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_group_connections_kerberos_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_kerberos_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_group_connections_kerberos_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_kerberos_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_kerberos_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_kerberos_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/group_connections/kerberos/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_kerberos_list( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGroupKerberosSourceConnectionList: + """sources_group_connections_kerberos_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupKerberosSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_kerberos_list_with_http_info( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGroupKerberosSourceConnectionList]: + """sources_group_connections_kerberos_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupKerberosSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_kerberos_list_without_preload_content( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_kerberos_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupKerberosSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_kerberos_list_serialize( + self, + group, + ordering, + page, + page_size, + search, + source__slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group is not None: + + _query_params.append(('group', group)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/kerberos/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_kerberos_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + patched_group_kerberos_source_connection_request: Optional[PatchedGroupKerberosSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupKerberosSourceConnection: + """sources_group_connections_kerberos_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param patched_group_kerberos_source_connection_request: + :type patched_group_kerberos_source_connection_request: PatchedGroupKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_partial_update_serialize( + id=id, + patched_group_kerberos_source_connection_request=patched_group_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_kerberos_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + patched_group_kerberos_source_connection_request: Optional[PatchedGroupKerberosSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupKerberosSourceConnection]: + """sources_group_connections_kerberos_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param patched_group_kerberos_source_connection_request: + :type patched_group_kerberos_source_connection_request: PatchedGroupKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_partial_update_serialize( + id=id, + patched_group_kerberos_source_connection_request=patched_group_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_kerberos_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + patched_group_kerberos_source_connection_request: Optional[PatchedGroupKerberosSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_kerberos_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param patched_group_kerberos_source_connection_request: + :type patched_group_kerberos_source_connection_request: PatchedGroupKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_partial_update_serialize( + id=id, + patched_group_kerberos_source_connection_request=patched_group_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_kerberos_partial_update_serialize( + self, + id, + patched_group_kerberos_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_group_kerberos_source_connection_request is not None: + _body_params = patched_group_kerberos_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/group_connections/kerberos/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_kerberos_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupKerberosSourceConnection: + """sources_group_connections_kerberos_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_kerberos_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupKerberosSourceConnection]: + """sources_group_connections_kerberos_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_kerberos_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_kerberos_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_kerberos_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/kerberos/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_kerberos_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupKerberosSourceConnection: + """sources_group_connections_kerberos_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param group_kerberos_source_connection_request: (required) + :type group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_update_serialize( + id=id, + group_kerberos_source_connection_request=group_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_kerberos_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupKerberosSourceConnection]: + """sources_group_connections_kerberos_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param group_kerberos_source_connection_request: (required) + :type group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_update_serialize( + id=id, + group_kerberos_source_connection_request=group_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_kerberos_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_kerberos_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param group_kerberos_source_connection_request: (required) + :type group_kerberos_source_connection_request: GroupKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_update_serialize( + id=id, + group_kerberos_source_connection_request=group_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_kerberos_update_serialize( + self, + id, + group_kerberos_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_kerberos_source_connection_request is not None: + _body_params = group_kerberos_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/group_connections/kerberos/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_kerberos_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_group_connections_kerberos_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_kerberos_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_group_connections_kerberos_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_kerberos_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_kerberos_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_kerberos_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_kerberos_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/kerberos/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_ldap_create( + self, + group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupLDAPSourceConnection: + """sources_group_connections_ldap_create + + Group-source connection Viewset + + :param group_ldap_source_connection_request: (required) + :type group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_create_serialize( + group_ldap_source_connection_request=group_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_ldap_create_with_http_info( + self, + group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupLDAPSourceConnection]: + """sources_group_connections_ldap_create + + Group-source connection Viewset + + :param group_ldap_source_connection_request: (required) + :type group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_create_serialize( + group_ldap_source_connection_request=group_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_ldap_create_without_preload_content( + self, + group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_ldap_create + + Group-source connection Viewset + + :param group_ldap_source_connection_request: (required) + :type group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_create_serialize( + group_ldap_source_connection_request=group_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_ldap_create_serialize( + self, + group_ldap_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_ldap_source_connection_request is not None: + _body_params = group_ldap_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/group_connections/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_ldap_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_group_connections_ldap_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_ldap_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_group_connections_ldap_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_ldap_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_ldap_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_ldap_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/group_connections/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_ldap_list( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGroupLDAPSourceConnectionList: + """sources_group_connections_ldap_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupLDAPSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_ldap_list_with_http_info( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGroupLDAPSourceConnectionList]: + """sources_group_connections_ldap_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupLDAPSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_ldap_list_without_preload_content( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_ldap_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupLDAPSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_ldap_list_serialize( + self, + group, + ordering, + page, + page_size, + search, + source__slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group is not None: + + _query_params.append(('group', group)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_ldap_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + patched_group_ldap_source_connection_request: Optional[PatchedGroupLDAPSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupLDAPSourceConnection: + """sources_group_connections_ldap_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param patched_group_ldap_source_connection_request: + :type patched_group_ldap_source_connection_request: PatchedGroupLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_partial_update_serialize( + id=id, + patched_group_ldap_source_connection_request=patched_group_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_ldap_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + patched_group_ldap_source_connection_request: Optional[PatchedGroupLDAPSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupLDAPSourceConnection]: + """sources_group_connections_ldap_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param patched_group_ldap_source_connection_request: + :type patched_group_ldap_source_connection_request: PatchedGroupLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_partial_update_serialize( + id=id, + patched_group_ldap_source_connection_request=patched_group_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_ldap_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + patched_group_ldap_source_connection_request: Optional[PatchedGroupLDAPSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_ldap_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param patched_group_ldap_source_connection_request: + :type patched_group_ldap_source_connection_request: PatchedGroupLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_partial_update_serialize( + id=id, + patched_group_ldap_source_connection_request=patched_group_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_ldap_partial_update_serialize( + self, + id, + patched_group_ldap_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_group_ldap_source_connection_request is not None: + _body_params = patched_group_ldap_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/group_connections/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_ldap_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupLDAPSourceConnection: + """sources_group_connections_ldap_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_ldap_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupLDAPSourceConnection]: + """sources_group_connections_ldap_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_ldap_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_ldap_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_ldap_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_ldap_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupLDAPSourceConnection: + """sources_group_connections_ldap_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param group_ldap_source_connection_request: (required) + :type group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_update_serialize( + id=id, + group_ldap_source_connection_request=group_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_ldap_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupLDAPSourceConnection]: + """sources_group_connections_ldap_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param group_ldap_source_connection_request: (required) + :type group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_update_serialize( + id=id, + group_ldap_source_connection_request=group_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_ldap_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_ldap_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param group_ldap_source_connection_request: (required) + :type group_ldap_source_connection_request: GroupLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_update_serialize( + id=id, + group_ldap_source_connection_request=group_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_ldap_update_serialize( + self, + id, + group_ldap_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_ldap_source_connection_request is not None: + _body_params = group_ldap_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/group_connections/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_ldap_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_group_connections_ldap_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_ldap_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_group_connections_ldap_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_ldap_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_ldap_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_ldap_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_ldap_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/ldap/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_oauth_create( + self, + group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupOAuthSourceConnection: + """sources_group_connections_oauth_create + + Group-source connection Viewset + + :param group_o_auth_source_connection_request: (required) + :type group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_create_serialize( + group_o_auth_source_connection_request=group_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_oauth_create_with_http_info( + self, + group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupOAuthSourceConnection]: + """sources_group_connections_oauth_create + + Group-source connection Viewset + + :param group_o_auth_source_connection_request: (required) + :type group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_create_serialize( + group_o_auth_source_connection_request=group_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_oauth_create_without_preload_content( + self, + group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_oauth_create + + Group-source connection Viewset + + :param group_o_auth_source_connection_request: (required) + :type group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_create_serialize( + group_o_auth_source_connection_request=group_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_oauth_create_serialize( + self, + group_o_auth_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_o_auth_source_connection_request is not None: + _body_params = group_o_auth_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/group_connections/oauth/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_oauth_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_group_connections_oauth_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_oauth_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_group_connections_oauth_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_oauth_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_oauth_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_oauth_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/group_connections/oauth/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_oauth_list( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGroupOAuthSourceConnectionList: + """sources_group_connections_oauth_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupOAuthSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_oauth_list_with_http_info( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGroupOAuthSourceConnectionList]: + """sources_group_connections_oauth_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupOAuthSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_oauth_list_without_preload_content( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_oauth_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupOAuthSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_oauth_list_serialize( + self, + group, + ordering, + page, + page_size, + search, + source__slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group is not None: + + _query_params.append(('group', group)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/oauth/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_oauth_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + patched_group_o_auth_source_connection_request: Optional[PatchedGroupOAuthSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupOAuthSourceConnection: + """sources_group_connections_oauth_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param patched_group_o_auth_source_connection_request: + :type patched_group_o_auth_source_connection_request: PatchedGroupOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_partial_update_serialize( + id=id, + patched_group_o_auth_source_connection_request=patched_group_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_oauth_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + patched_group_o_auth_source_connection_request: Optional[PatchedGroupOAuthSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupOAuthSourceConnection]: + """sources_group_connections_oauth_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param patched_group_o_auth_source_connection_request: + :type patched_group_o_auth_source_connection_request: PatchedGroupOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_partial_update_serialize( + id=id, + patched_group_o_auth_source_connection_request=patched_group_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_oauth_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + patched_group_o_auth_source_connection_request: Optional[PatchedGroupOAuthSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_oauth_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param patched_group_o_auth_source_connection_request: + :type patched_group_o_auth_source_connection_request: PatchedGroupOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_partial_update_serialize( + id=id, + patched_group_o_auth_source_connection_request=patched_group_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_oauth_partial_update_serialize( + self, + id, + patched_group_o_auth_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_group_o_auth_source_connection_request is not None: + _body_params = patched_group_o_auth_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/group_connections/oauth/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_oauth_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupOAuthSourceConnection: + """sources_group_connections_oauth_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_oauth_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupOAuthSourceConnection]: + """sources_group_connections_oauth_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_oauth_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_oauth_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_oauth_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/oauth/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_oauth_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupOAuthSourceConnection: + """sources_group_connections_oauth_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param group_o_auth_source_connection_request: (required) + :type group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_update_serialize( + id=id, + group_o_auth_source_connection_request=group_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_oauth_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupOAuthSourceConnection]: + """sources_group_connections_oauth_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param group_o_auth_source_connection_request: (required) + :type group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_update_serialize( + id=id, + group_o_auth_source_connection_request=group_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_oauth_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_oauth_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param group_o_auth_source_connection_request: (required) + :type group_o_auth_source_connection_request: GroupOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_update_serialize( + id=id, + group_o_auth_source_connection_request=group_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_oauth_update_serialize( + self, + id, + group_o_auth_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_o_auth_source_connection_request is not None: + _body_params = group_o_auth_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/group_connections/oauth/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_oauth_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_group_connections_oauth_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_oauth_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_group_connections_oauth_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_oauth_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_oauth_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_oauth_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_oauth_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/oauth/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_plex_create( + self, + group_plex_source_connection_request: GroupPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupPlexSourceConnection: + """sources_group_connections_plex_create + + Group-source connection Viewset + + :param group_plex_source_connection_request: (required) + :type group_plex_source_connection_request: GroupPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_create_serialize( + group_plex_source_connection_request=group_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_plex_create_with_http_info( + self, + group_plex_source_connection_request: GroupPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupPlexSourceConnection]: + """sources_group_connections_plex_create + + Group-source connection Viewset + + :param group_plex_source_connection_request: (required) + :type group_plex_source_connection_request: GroupPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_create_serialize( + group_plex_source_connection_request=group_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_plex_create_without_preload_content( + self, + group_plex_source_connection_request: GroupPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_plex_create + + Group-source connection Viewset + + :param group_plex_source_connection_request: (required) + :type group_plex_source_connection_request: GroupPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_create_serialize( + group_plex_source_connection_request=group_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_plex_create_serialize( + self, + group_plex_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_plex_source_connection_request is not None: + _body_params = group_plex_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/group_connections/plex/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_plex_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_group_connections_plex_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_plex_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_group_connections_plex_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_plex_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_plex_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_plex_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/group_connections/plex/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_plex_list( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGroupPlexSourceConnectionList: + """sources_group_connections_plex_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupPlexSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_plex_list_with_http_info( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGroupPlexSourceConnectionList]: + """sources_group_connections_plex_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupPlexSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_plex_list_without_preload_content( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_plex_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupPlexSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_plex_list_serialize( + self, + group, + ordering, + page, + page_size, + search, + source__slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group is not None: + + _query_params.append(('group', group)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/plex/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_plex_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + patched_group_plex_source_connection_request: Optional[PatchedGroupPlexSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupPlexSourceConnection: + """sources_group_connections_plex_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param patched_group_plex_source_connection_request: + :type patched_group_plex_source_connection_request: PatchedGroupPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_partial_update_serialize( + id=id, + patched_group_plex_source_connection_request=patched_group_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_plex_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + patched_group_plex_source_connection_request: Optional[PatchedGroupPlexSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupPlexSourceConnection]: + """sources_group_connections_plex_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param patched_group_plex_source_connection_request: + :type patched_group_plex_source_connection_request: PatchedGroupPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_partial_update_serialize( + id=id, + patched_group_plex_source_connection_request=patched_group_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_plex_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + patched_group_plex_source_connection_request: Optional[PatchedGroupPlexSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_plex_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param patched_group_plex_source_connection_request: + :type patched_group_plex_source_connection_request: PatchedGroupPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_partial_update_serialize( + id=id, + patched_group_plex_source_connection_request=patched_group_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_plex_partial_update_serialize( + self, + id, + patched_group_plex_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_group_plex_source_connection_request is not None: + _body_params = patched_group_plex_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/group_connections/plex/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_plex_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupPlexSourceConnection: + """sources_group_connections_plex_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_plex_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupPlexSourceConnection]: + """sources_group_connections_plex_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_plex_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_plex_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_plex_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/plex/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_plex_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + group_plex_source_connection_request: GroupPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupPlexSourceConnection: + """sources_group_connections_plex_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param group_plex_source_connection_request: (required) + :type group_plex_source_connection_request: GroupPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_update_serialize( + id=id, + group_plex_source_connection_request=group_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_plex_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + group_plex_source_connection_request: GroupPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupPlexSourceConnection]: + """sources_group_connections_plex_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param group_plex_source_connection_request: (required) + :type group_plex_source_connection_request: GroupPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_update_serialize( + id=id, + group_plex_source_connection_request=group_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_plex_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + group_plex_source_connection_request: GroupPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_plex_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param group_plex_source_connection_request: (required) + :type group_plex_source_connection_request: GroupPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_update_serialize( + id=id, + group_plex_source_connection_request=group_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_plex_update_serialize( + self, + id, + group_plex_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_plex_source_connection_request is not None: + _body_params = group_plex_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/group_connections/plex/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_plex_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_group_connections_plex_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_plex_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_group_connections_plex_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_plex_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_plex_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_plex_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_plex_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/plex/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_saml_create( + self, + group_saml_source_connection_request: GroupSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupSAMLSourceConnection: + """sources_group_connections_saml_create + + Group-source connection Viewset + + :param group_saml_source_connection_request: (required) + :type group_saml_source_connection_request: GroupSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_create_serialize( + group_saml_source_connection_request=group_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_saml_create_with_http_info( + self, + group_saml_source_connection_request: GroupSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupSAMLSourceConnection]: + """sources_group_connections_saml_create + + Group-source connection Viewset + + :param group_saml_source_connection_request: (required) + :type group_saml_source_connection_request: GroupSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_create_serialize( + group_saml_source_connection_request=group_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_saml_create_without_preload_content( + self, + group_saml_source_connection_request: GroupSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_saml_create + + Group-source connection Viewset + + :param group_saml_source_connection_request: (required) + :type group_saml_source_connection_request: GroupSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_create_serialize( + group_saml_source_connection_request=group_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_saml_create_serialize( + self, + group_saml_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_saml_source_connection_request is not None: + _body_params = group_saml_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/group_connections/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_saml_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_group_connections_saml_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_saml_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_group_connections_saml_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_saml_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_saml_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_saml_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/group_connections/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_saml_list( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGroupSAMLSourceConnectionList: + """sources_group_connections_saml_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupSAMLSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_saml_list_with_http_info( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGroupSAMLSourceConnectionList]: + """sources_group_connections_saml_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupSAMLSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_saml_list_without_preload_content( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_saml_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupSAMLSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_saml_list_serialize( + self, + group, + ordering, + page, + page_size, + search, + source__slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group is not None: + + _query_params.append(('group', group)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_saml_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + patched_group_saml_source_connection_request: Optional[PatchedGroupSAMLSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupSAMLSourceConnection: + """sources_group_connections_saml_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param patched_group_saml_source_connection_request: + :type patched_group_saml_source_connection_request: PatchedGroupSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_partial_update_serialize( + id=id, + patched_group_saml_source_connection_request=patched_group_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_saml_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + patched_group_saml_source_connection_request: Optional[PatchedGroupSAMLSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupSAMLSourceConnection]: + """sources_group_connections_saml_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param patched_group_saml_source_connection_request: + :type patched_group_saml_source_connection_request: PatchedGroupSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_partial_update_serialize( + id=id, + patched_group_saml_source_connection_request=patched_group_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_saml_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + patched_group_saml_source_connection_request: Optional[PatchedGroupSAMLSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_saml_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param patched_group_saml_source_connection_request: + :type patched_group_saml_source_connection_request: PatchedGroupSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_partial_update_serialize( + id=id, + patched_group_saml_source_connection_request=patched_group_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_saml_partial_update_serialize( + self, + id, + patched_group_saml_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_group_saml_source_connection_request is not None: + _body_params = patched_group_saml_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/group_connections/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_saml_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupSAMLSourceConnection: + """sources_group_connections_saml_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_saml_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupSAMLSourceConnection]: + """sources_group_connections_saml_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_saml_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_saml_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_saml_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_saml_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + group_saml_source_connection_request: GroupSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupSAMLSourceConnection: + """sources_group_connections_saml_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param group_saml_source_connection_request: (required) + :type group_saml_source_connection_request: GroupSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_update_serialize( + id=id, + group_saml_source_connection_request=group_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_saml_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + group_saml_source_connection_request: GroupSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupSAMLSourceConnection]: + """sources_group_connections_saml_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param group_saml_source_connection_request: (required) + :type group_saml_source_connection_request: GroupSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_update_serialize( + id=id, + group_saml_source_connection_request=group_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_saml_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + group_saml_source_connection_request: GroupSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_saml_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param group_saml_source_connection_request: (required) + :type group_saml_source_connection_request: GroupSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_update_serialize( + id=id, + group_saml_source_connection_request=group_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_saml_update_serialize( + self, + id, + group_saml_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_saml_source_connection_request is not None: + _body_params = group_saml_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/group_connections/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_saml_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_group_connections_saml_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_saml_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_group_connections_saml_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_saml_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_saml_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_saml_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_saml_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/saml/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_telegram_create( + self, + group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupTelegramSourceConnection: + """sources_group_connections_telegram_create + + Group-source connection Viewset + + :param group_telegram_source_connection_request: (required) + :type group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_create_serialize( + group_telegram_source_connection_request=group_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_telegram_create_with_http_info( + self, + group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupTelegramSourceConnection]: + """sources_group_connections_telegram_create + + Group-source connection Viewset + + :param group_telegram_source_connection_request: (required) + :type group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_create_serialize( + group_telegram_source_connection_request=group_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_telegram_create_without_preload_content( + self, + group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_telegram_create + + Group-source connection Viewset + + :param group_telegram_source_connection_request: (required) + :type group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_create_serialize( + group_telegram_source_connection_request=group_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_telegram_create_serialize( + self, + group_telegram_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_telegram_source_connection_request is not None: + _body_params = group_telegram_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/group_connections/telegram/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_telegram_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_group_connections_telegram_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_telegram_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_group_connections_telegram_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_telegram_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_telegram_destroy + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_telegram_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/group_connections/telegram/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_telegram_list( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedGroupTelegramSourceConnectionList: + """sources_group_connections_telegram_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupTelegramSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_telegram_list_with_http_info( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedGroupTelegramSourceConnectionList]: + """sources_group_connections_telegram_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupTelegramSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_telegram_list_without_preload_content( + self, + group: Optional[UUID] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_telegram_list + + Group-source connection Viewset + + :param group: + :type group: UUID + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_list_serialize( + group=group, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedGroupTelegramSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_telegram_list_serialize( + self, + group, + ordering, + page, + page_size, + search, + source__slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group is not None: + + _query_params.append(('group', group)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/telegram/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_telegram_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + patched_group_telegram_source_connection_request: Optional[PatchedGroupTelegramSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupTelegramSourceConnection: + """sources_group_connections_telegram_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param patched_group_telegram_source_connection_request: + :type patched_group_telegram_source_connection_request: PatchedGroupTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_partial_update_serialize( + id=id, + patched_group_telegram_source_connection_request=patched_group_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_telegram_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + patched_group_telegram_source_connection_request: Optional[PatchedGroupTelegramSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupTelegramSourceConnection]: + """sources_group_connections_telegram_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param patched_group_telegram_source_connection_request: + :type patched_group_telegram_source_connection_request: PatchedGroupTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_partial_update_serialize( + id=id, + patched_group_telegram_source_connection_request=patched_group_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_telegram_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + patched_group_telegram_source_connection_request: Optional[PatchedGroupTelegramSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_telegram_partial_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param patched_group_telegram_source_connection_request: + :type patched_group_telegram_source_connection_request: PatchedGroupTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_partial_update_serialize( + id=id, + patched_group_telegram_source_connection_request=patched_group_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_telegram_partial_update_serialize( + self, + id, + patched_group_telegram_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_group_telegram_source_connection_request is not None: + _body_params = patched_group_telegram_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/group_connections/telegram/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_telegram_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupTelegramSourceConnection: + """sources_group_connections_telegram_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_telegram_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupTelegramSourceConnection]: + """sources_group_connections_telegram_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_telegram_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_telegram_retrieve + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_telegram_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/telegram/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_telegram_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GroupTelegramSourceConnection: + """sources_group_connections_telegram_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param group_telegram_source_connection_request: (required) + :type group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_update_serialize( + id=id, + group_telegram_source_connection_request=group_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_telegram_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GroupTelegramSourceConnection]: + """sources_group_connections_telegram_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param group_telegram_source_connection_request: (required) + :type group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_update_serialize( + id=id, + group_telegram_source_connection_request=group_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_telegram_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_telegram_update + + Group-source connection Viewset + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param group_telegram_source_connection_request: (required) + :type group_telegram_source_connection_request: GroupTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_update_serialize( + id=id, + group_telegram_source_connection_request=group_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GroupTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_telegram_update_serialize( + self, + id, + group_telegram_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if group_telegram_source_connection_request is not None: + _body_params = group_telegram_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/group_connections/telegram/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_group_connections_telegram_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_group_connections_telegram_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_group_connections_telegram_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_group_connections_telegram_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_group_connections_telegram_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Group Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_group_connections_telegram_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this Group Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_group_connections_telegram_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_group_connections_telegram_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/group_connections/telegram/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_kerberos_create( + self, + kerberos_source_request: KerberosSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KerberosSource: + """sources_kerberos_create + + Kerberos Source Viewset + + :param kerberos_source_request: (required) + :type kerberos_source_request: KerberosSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_create_serialize( + kerberos_source_request=kerberos_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_kerberos_create_with_http_info( + self, + kerberos_source_request: KerberosSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KerberosSource]: + """sources_kerberos_create + + Kerberos Source Viewset + + :param kerberos_source_request: (required) + :type kerberos_source_request: KerberosSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_create_serialize( + kerberos_source_request=kerberos_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_kerberos_create_without_preload_content( + self, + kerberos_source_request: KerberosSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_kerberos_create + + Kerberos Source Viewset + + :param kerberos_source_request: (required) + :type kerberos_source_request: KerberosSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_create_serialize( + kerberos_source_request=kerberos_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_kerberos_create_serialize( + self, + kerberos_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if kerberos_source_request is not None: + _body_params = kerberos_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/kerberos/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_kerberos_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_kerberos_destroy + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_kerberos_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_kerberos_destroy + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_kerberos_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_kerberos_destroy + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_kerberos_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/kerberos/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_kerberos_list( + self, + enabled: Optional[StrictBool] = None, + kadmin_type: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_login_update_internal_password: Optional[StrictBool] = None, + pbm_uuid: Optional[UUID] = None, + realm: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + spnego_server_name: Optional[StrictStr] = None, + sync_principal: Optional[StrictStr] = None, + sync_users: Optional[StrictBool] = None, + sync_users_password: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedKerberosSourceList: + """sources_kerberos_list + + Kerberos Source Viewset + + :param enabled: + :type enabled: bool + :param kadmin_type: + :type kadmin_type: KadminTypeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_login_update_internal_password: + :type password_login_update_internal_password: bool + :param pbm_uuid: + :type pbm_uuid: UUID + :param realm: + :type realm: str + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param spnego_server_name: + :type spnego_server_name: str + :param sync_principal: + :type sync_principal: str + :param sync_users: + :type sync_users: bool + :param sync_users_password: + :type sync_users_password: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_list_serialize( + enabled=enabled, + kadmin_type=kadmin_type, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password_login_update_internal_password=password_login_update_internal_password, + pbm_uuid=pbm_uuid, + realm=realm, + search=search, + slug=slug, + spnego_server_name=spnego_server_name, + sync_principal=sync_principal, + sync_users=sync_users, + sync_users_password=sync_users_password, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedKerberosSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_kerberos_list_with_http_info( + self, + enabled: Optional[StrictBool] = None, + kadmin_type: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_login_update_internal_password: Optional[StrictBool] = None, + pbm_uuid: Optional[UUID] = None, + realm: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + spnego_server_name: Optional[StrictStr] = None, + sync_principal: Optional[StrictStr] = None, + sync_users: Optional[StrictBool] = None, + sync_users_password: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedKerberosSourceList]: + """sources_kerberos_list + + Kerberos Source Viewset + + :param enabled: + :type enabled: bool + :param kadmin_type: + :type kadmin_type: KadminTypeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_login_update_internal_password: + :type password_login_update_internal_password: bool + :param pbm_uuid: + :type pbm_uuid: UUID + :param realm: + :type realm: str + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param spnego_server_name: + :type spnego_server_name: str + :param sync_principal: + :type sync_principal: str + :param sync_users: + :type sync_users: bool + :param sync_users_password: + :type sync_users_password: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_list_serialize( + enabled=enabled, + kadmin_type=kadmin_type, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password_login_update_internal_password=password_login_update_internal_password, + pbm_uuid=pbm_uuid, + realm=realm, + search=search, + slug=slug, + spnego_server_name=spnego_server_name, + sync_principal=sync_principal, + sync_users=sync_users, + sync_users_password=sync_users_password, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedKerberosSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_kerberos_list_without_preload_content( + self, + enabled: Optional[StrictBool] = None, + kadmin_type: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_login_update_internal_password: Optional[StrictBool] = None, + pbm_uuid: Optional[UUID] = None, + realm: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + spnego_server_name: Optional[StrictStr] = None, + sync_principal: Optional[StrictStr] = None, + sync_users: Optional[StrictBool] = None, + sync_users_password: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_kerberos_list + + Kerberos Source Viewset + + :param enabled: + :type enabled: bool + :param kadmin_type: + :type kadmin_type: KadminTypeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_login_update_internal_password: + :type password_login_update_internal_password: bool + :param pbm_uuid: + :type pbm_uuid: UUID + :param realm: + :type realm: str + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param spnego_server_name: + :type spnego_server_name: str + :param sync_principal: + :type sync_principal: str + :param sync_users: + :type sync_users: bool + :param sync_users_password: + :type sync_users_password: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_list_serialize( + enabled=enabled, + kadmin_type=kadmin_type, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password_login_update_internal_password=password_login_update_internal_password, + pbm_uuid=pbm_uuid, + realm=realm, + search=search, + slug=slug, + spnego_server_name=spnego_server_name, + sync_principal=sync_principal, + sync_users=sync_users, + sync_users_password=sync_users_password, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedKerberosSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_kerberos_list_serialize( + self, + enabled, + kadmin_type, + name, + ordering, + page, + page_size, + password_login_update_internal_password, + pbm_uuid, + realm, + search, + slug, + spnego_server_name, + sync_principal, + sync_users, + sync_users_password, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if enabled is not None: + + _query_params.append(('enabled', enabled)) + + if kadmin_type is not None: + + _query_params.append(('kadmin_type', kadmin_type.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if password_login_update_internal_password is not None: + + _query_params.append(('password_login_update_internal_password', password_login_update_internal_password)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if realm is not None: + + _query_params.append(('realm', realm)) + + if search is not None: + + _query_params.append(('search', search)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + if spnego_server_name is not None: + + _query_params.append(('spnego_server_name', spnego_server_name)) + + if sync_principal is not None: + + _query_params.append(('sync_principal', sync_principal)) + + if sync_users is not None: + + _query_params.append(('sync_users', sync_users)) + + if sync_users_password is not None: + + _query_params.append(('sync_users_password', sync_users_password)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/kerberos/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_kerberos_partial_update( + self, + slug: StrictStr, + patched_kerberos_source_request: Optional[PatchedKerberosSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KerberosSource: + """sources_kerberos_partial_update + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param patched_kerberos_source_request: + :type patched_kerberos_source_request: PatchedKerberosSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_partial_update_serialize( + slug=slug, + patched_kerberos_source_request=patched_kerberos_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_kerberos_partial_update_with_http_info( + self, + slug: StrictStr, + patched_kerberos_source_request: Optional[PatchedKerberosSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KerberosSource]: + """sources_kerberos_partial_update + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param patched_kerberos_source_request: + :type patched_kerberos_source_request: PatchedKerberosSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_partial_update_serialize( + slug=slug, + patched_kerberos_source_request=patched_kerberos_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_kerberos_partial_update_without_preload_content( + self, + slug: StrictStr, + patched_kerberos_source_request: Optional[PatchedKerberosSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_kerberos_partial_update + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param patched_kerberos_source_request: + :type patched_kerberos_source_request: PatchedKerberosSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_partial_update_serialize( + slug=slug, + patched_kerberos_source_request=patched_kerberos_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_kerberos_partial_update_serialize( + self, + slug, + patched_kerberos_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_kerberos_source_request is not None: + _body_params = patched_kerberos_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/kerberos/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_kerberos_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KerberosSource: + """sources_kerberos_retrieve + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_kerberos_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KerberosSource]: + """sources_kerberos_retrieve + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_kerberos_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_kerberos_retrieve + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_kerberos_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/kerberos/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_kerberos_sync_status_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SyncStatus: + """sources_kerberos_sync_status_retrieve + + Get provider's sync status + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_sync_status_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_kerberos_sync_status_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SyncStatus]: + """sources_kerberos_sync_status_retrieve + + Get provider's sync status + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_sync_status_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_kerberos_sync_status_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_kerberos_sync_status_retrieve + + Get provider's sync status + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_sync_status_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_kerberos_sync_status_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/kerberos/{slug}/sync/status/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_kerberos_update( + self, + slug: StrictStr, + kerberos_source_request: KerberosSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> KerberosSource: + """sources_kerberos_update + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param kerberos_source_request: (required) + :type kerberos_source_request: KerberosSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_update_serialize( + slug=slug, + kerberos_source_request=kerberos_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_kerberos_update_with_http_info( + self, + slug: StrictStr, + kerberos_source_request: KerberosSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[KerberosSource]: + """sources_kerberos_update + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param kerberos_source_request: (required) + :type kerberos_source_request: KerberosSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_update_serialize( + slug=slug, + kerberos_source_request=kerberos_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_kerberos_update_without_preload_content( + self, + slug: StrictStr, + kerberos_source_request: KerberosSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_kerberos_update + + Kerberos Source Viewset + + :param slug: (required) + :type slug: str + :param kerberos_source_request: (required) + :type kerberos_source_request: KerberosSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_update_serialize( + slug=slug, + kerberos_source_request=kerberos_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "KerberosSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_kerberos_update_serialize( + self, + slug, + kerberos_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if kerberos_source_request is not None: + _body_params = kerberos_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/kerberos/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_kerberos_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_kerberos_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_kerberos_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_kerberos_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_kerberos_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_kerberos_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_kerberos_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_kerberos_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/kerberos/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_ldap_create( + self, + ldap_source_request: LDAPSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPSource: + """sources_ldap_create + + LDAP Source Viewset + + :param ldap_source_request: (required) + :type ldap_source_request: LDAPSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_create_serialize( + ldap_source_request=ldap_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_ldap_create_with_http_info( + self, + ldap_source_request: LDAPSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPSource]: + """sources_ldap_create + + LDAP Source Viewset + + :param ldap_source_request: (required) + :type ldap_source_request: LDAPSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_create_serialize( + ldap_source_request=ldap_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_ldap_create_without_preload_content( + self, + ldap_source_request: LDAPSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_ldap_create + + LDAP Source Viewset + + :param ldap_source_request: (required) + :type ldap_source_request: LDAPSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_create_serialize( + ldap_source_request=ldap_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_ldap_create_serialize( + self, + ldap_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ldap_source_request is not None: + _body_params = ldap_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_ldap_debug_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPDebug: + """sources_ldap_debug_retrieve + + Get raw LDAP data to debug + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_debug_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPDebug", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_ldap_debug_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPDebug]: + """sources_ldap_debug_retrieve + + Get raw LDAP data to debug + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_debug_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPDebug", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_ldap_debug_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_ldap_debug_retrieve + + Get raw LDAP data to debug + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_debug_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPDebug", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_ldap_debug_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/ldap/{slug}/debug/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_ldap_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_ldap_destroy + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_ldap_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_ldap_destroy + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_ldap_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_ldap_destroy + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_ldap_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/ldap/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_ldap_list( + self, + additional_group_dn: Optional[StrictStr] = None, + additional_user_dn: Optional[StrictStr] = None, + base_dn: Optional[StrictStr] = None, + bind_cn: Optional[StrictStr] = None, + client_certificate: Optional[UUID] = None, + delete_not_found_objects: Optional[StrictBool] = None, + enabled: Optional[StrictBool] = None, + group_membership_field: Optional[StrictStr] = None, + group_object_filter: Optional[StrictStr] = None, + group_property_mappings: Optional[List[UUID]] = None, + lookup_groups_from_user: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + object_uniqueness_field: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_login_update_internal_password: Optional[StrictBool] = None, + pbm_uuid: Optional[UUID] = None, + peer_certificate: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + server_uri: Optional[StrictStr] = None, + slug: Optional[StrictStr] = None, + sni: Optional[StrictBool] = None, + start_tls: Optional[StrictBool] = None, + sync_groups: Optional[StrictBool] = None, + sync_parent_group: Optional[UUID] = None, + sync_users: Optional[StrictBool] = None, + sync_users_password: Optional[StrictBool] = None, + user_membership_attribute: Optional[StrictStr] = None, + user_object_filter: Optional[StrictStr] = None, + user_property_mappings: Optional[List[UUID]] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedLDAPSourceList: + """sources_ldap_list + + LDAP Source Viewset + + :param additional_group_dn: + :type additional_group_dn: str + :param additional_user_dn: + :type additional_user_dn: str + :param base_dn: + :type base_dn: str + :param bind_cn: + :type bind_cn: str + :param client_certificate: + :type client_certificate: UUID + :param delete_not_found_objects: + :type delete_not_found_objects: bool + :param enabled: + :type enabled: bool + :param group_membership_field: + :type group_membership_field: str + :param group_object_filter: + :type group_object_filter: str + :param group_property_mappings: + :type group_property_mappings: List[UUID] + :param lookup_groups_from_user: + :type lookup_groups_from_user: bool + :param name: + :type name: str + :param object_uniqueness_field: + :type object_uniqueness_field: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_login_update_internal_password: + :type password_login_update_internal_password: bool + :param pbm_uuid: + :type pbm_uuid: UUID + :param peer_certificate: + :type peer_certificate: UUID + :param search: A search term. + :type search: str + :param server_uri: + :type server_uri: str + :param slug: + :type slug: str + :param sni: + :type sni: bool + :param start_tls: + :type start_tls: bool + :param sync_groups: + :type sync_groups: bool + :param sync_parent_group: + :type sync_parent_group: UUID + :param sync_users: + :type sync_users: bool + :param sync_users_password: + :type sync_users_password: bool + :param user_membership_attribute: + :type user_membership_attribute: str + :param user_object_filter: + :type user_object_filter: str + :param user_property_mappings: + :type user_property_mappings: List[UUID] + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_list_serialize( + additional_group_dn=additional_group_dn, + additional_user_dn=additional_user_dn, + base_dn=base_dn, + bind_cn=bind_cn, + client_certificate=client_certificate, + delete_not_found_objects=delete_not_found_objects, + enabled=enabled, + group_membership_field=group_membership_field, + group_object_filter=group_object_filter, + group_property_mappings=group_property_mappings, + lookup_groups_from_user=lookup_groups_from_user, + name=name, + object_uniqueness_field=object_uniqueness_field, + ordering=ordering, + page=page, + page_size=page_size, + password_login_update_internal_password=password_login_update_internal_password, + pbm_uuid=pbm_uuid, + peer_certificate=peer_certificate, + search=search, + server_uri=server_uri, + slug=slug, + sni=sni, + start_tls=start_tls, + sync_groups=sync_groups, + sync_parent_group=sync_parent_group, + sync_users=sync_users, + sync_users_password=sync_users_password, + user_membership_attribute=user_membership_attribute, + user_object_filter=user_object_filter, + user_property_mappings=user_property_mappings, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_ldap_list_with_http_info( + self, + additional_group_dn: Optional[StrictStr] = None, + additional_user_dn: Optional[StrictStr] = None, + base_dn: Optional[StrictStr] = None, + bind_cn: Optional[StrictStr] = None, + client_certificate: Optional[UUID] = None, + delete_not_found_objects: Optional[StrictBool] = None, + enabled: Optional[StrictBool] = None, + group_membership_field: Optional[StrictStr] = None, + group_object_filter: Optional[StrictStr] = None, + group_property_mappings: Optional[List[UUID]] = None, + lookup_groups_from_user: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + object_uniqueness_field: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_login_update_internal_password: Optional[StrictBool] = None, + pbm_uuid: Optional[UUID] = None, + peer_certificate: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + server_uri: Optional[StrictStr] = None, + slug: Optional[StrictStr] = None, + sni: Optional[StrictBool] = None, + start_tls: Optional[StrictBool] = None, + sync_groups: Optional[StrictBool] = None, + sync_parent_group: Optional[UUID] = None, + sync_users: Optional[StrictBool] = None, + sync_users_password: Optional[StrictBool] = None, + user_membership_attribute: Optional[StrictStr] = None, + user_object_filter: Optional[StrictStr] = None, + user_property_mappings: Optional[List[UUID]] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedLDAPSourceList]: + """sources_ldap_list + + LDAP Source Viewset + + :param additional_group_dn: + :type additional_group_dn: str + :param additional_user_dn: + :type additional_user_dn: str + :param base_dn: + :type base_dn: str + :param bind_cn: + :type bind_cn: str + :param client_certificate: + :type client_certificate: UUID + :param delete_not_found_objects: + :type delete_not_found_objects: bool + :param enabled: + :type enabled: bool + :param group_membership_field: + :type group_membership_field: str + :param group_object_filter: + :type group_object_filter: str + :param group_property_mappings: + :type group_property_mappings: List[UUID] + :param lookup_groups_from_user: + :type lookup_groups_from_user: bool + :param name: + :type name: str + :param object_uniqueness_field: + :type object_uniqueness_field: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_login_update_internal_password: + :type password_login_update_internal_password: bool + :param pbm_uuid: + :type pbm_uuid: UUID + :param peer_certificate: + :type peer_certificate: UUID + :param search: A search term. + :type search: str + :param server_uri: + :type server_uri: str + :param slug: + :type slug: str + :param sni: + :type sni: bool + :param start_tls: + :type start_tls: bool + :param sync_groups: + :type sync_groups: bool + :param sync_parent_group: + :type sync_parent_group: UUID + :param sync_users: + :type sync_users: bool + :param sync_users_password: + :type sync_users_password: bool + :param user_membership_attribute: + :type user_membership_attribute: str + :param user_object_filter: + :type user_object_filter: str + :param user_property_mappings: + :type user_property_mappings: List[UUID] + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_list_serialize( + additional_group_dn=additional_group_dn, + additional_user_dn=additional_user_dn, + base_dn=base_dn, + bind_cn=bind_cn, + client_certificate=client_certificate, + delete_not_found_objects=delete_not_found_objects, + enabled=enabled, + group_membership_field=group_membership_field, + group_object_filter=group_object_filter, + group_property_mappings=group_property_mappings, + lookup_groups_from_user=lookup_groups_from_user, + name=name, + object_uniqueness_field=object_uniqueness_field, + ordering=ordering, + page=page, + page_size=page_size, + password_login_update_internal_password=password_login_update_internal_password, + pbm_uuid=pbm_uuid, + peer_certificate=peer_certificate, + search=search, + server_uri=server_uri, + slug=slug, + sni=sni, + start_tls=start_tls, + sync_groups=sync_groups, + sync_parent_group=sync_parent_group, + sync_users=sync_users, + sync_users_password=sync_users_password, + user_membership_attribute=user_membership_attribute, + user_object_filter=user_object_filter, + user_property_mappings=user_property_mappings, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_ldap_list_without_preload_content( + self, + additional_group_dn: Optional[StrictStr] = None, + additional_user_dn: Optional[StrictStr] = None, + base_dn: Optional[StrictStr] = None, + bind_cn: Optional[StrictStr] = None, + client_certificate: Optional[UUID] = None, + delete_not_found_objects: Optional[StrictBool] = None, + enabled: Optional[StrictBool] = None, + group_membership_field: Optional[StrictStr] = None, + group_object_filter: Optional[StrictStr] = None, + group_property_mappings: Optional[List[UUID]] = None, + lookup_groups_from_user: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + object_uniqueness_field: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_login_update_internal_password: Optional[StrictBool] = None, + pbm_uuid: Optional[UUID] = None, + peer_certificate: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + server_uri: Optional[StrictStr] = None, + slug: Optional[StrictStr] = None, + sni: Optional[StrictBool] = None, + start_tls: Optional[StrictBool] = None, + sync_groups: Optional[StrictBool] = None, + sync_parent_group: Optional[UUID] = None, + sync_users: Optional[StrictBool] = None, + sync_users_password: Optional[StrictBool] = None, + user_membership_attribute: Optional[StrictStr] = None, + user_object_filter: Optional[StrictStr] = None, + user_property_mappings: Optional[List[UUID]] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_ldap_list + + LDAP Source Viewset + + :param additional_group_dn: + :type additional_group_dn: str + :param additional_user_dn: + :type additional_user_dn: str + :param base_dn: + :type base_dn: str + :param bind_cn: + :type bind_cn: str + :param client_certificate: + :type client_certificate: UUID + :param delete_not_found_objects: + :type delete_not_found_objects: bool + :param enabled: + :type enabled: bool + :param group_membership_field: + :type group_membership_field: str + :param group_object_filter: + :type group_object_filter: str + :param group_property_mappings: + :type group_property_mappings: List[UUID] + :param lookup_groups_from_user: + :type lookup_groups_from_user: bool + :param name: + :type name: str + :param object_uniqueness_field: + :type object_uniqueness_field: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_login_update_internal_password: + :type password_login_update_internal_password: bool + :param pbm_uuid: + :type pbm_uuid: UUID + :param peer_certificate: + :type peer_certificate: UUID + :param search: A search term. + :type search: str + :param server_uri: + :type server_uri: str + :param slug: + :type slug: str + :param sni: + :type sni: bool + :param start_tls: + :type start_tls: bool + :param sync_groups: + :type sync_groups: bool + :param sync_parent_group: + :type sync_parent_group: UUID + :param sync_users: + :type sync_users: bool + :param sync_users_password: + :type sync_users_password: bool + :param user_membership_attribute: + :type user_membership_attribute: str + :param user_object_filter: + :type user_object_filter: str + :param user_property_mappings: + :type user_property_mappings: List[UUID] + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_list_serialize( + additional_group_dn=additional_group_dn, + additional_user_dn=additional_user_dn, + base_dn=base_dn, + bind_cn=bind_cn, + client_certificate=client_certificate, + delete_not_found_objects=delete_not_found_objects, + enabled=enabled, + group_membership_field=group_membership_field, + group_object_filter=group_object_filter, + group_property_mappings=group_property_mappings, + lookup_groups_from_user=lookup_groups_from_user, + name=name, + object_uniqueness_field=object_uniqueness_field, + ordering=ordering, + page=page, + page_size=page_size, + password_login_update_internal_password=password_login_update_internal_password, + pbm_uuid=pbm_uuid, + peer_certificate=peer_certificate, + search=search, + server_uri=server_uri, + slug=slug, + sni=sni, + start_tls=start_tls, + sync_groups=sync_groups, + sync_parent_group=sync_parent_group, + sync_users=sync_users, + sync_users_password=sync_users_password, + user_membership_attribute=user_membership_attribute, + user_object_filter=user_object_filter, + user_property_mappings=user_property_mappings, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedLDAPSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_ldap_list_serialize( + self, + additional_group_dn, + additional_user_dn, + base_dn, + bind_cn, + client_certificate, + delete_not_found_objects, + enabled, + group_membership_field, + group_object_filter, + group_property_mappings, + lookup_groups_from_user, + name, + object_uniqueness_field, + ordering, + page, + page_size, + password_login_update_internal_password, + pbm_uuid, + peer_certificate, + search, + server_uri, + slug, + sni, + start_tls, + sync_groups, + sync_parent_group, + sync_users, + sync_users_password, + user_membership_attribute, + user_object_filter, + user_property_mappings, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'group_property_mappings': 'multi', + 'user_property_mappings': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if additional_group_dn is not None: + + _query_params.append(('additional_group_dn', additional_group_dn)) + + if additional_user_dn is not None: + + _query_params.append(('additional_user_dn', additional_user_dn)) + + if base_dn is not None: + + _query_params.append(('base_dn', base_dn)) + + if bind_cn is not None: + + _query_params.append(('bind_cn', bind_cn)) + + if client_certificate is not None: + + _query_params.append(('client_certificate', client_certificate)) + + if delete_not_found_objects is not None: + + _query_params.append(('delete_not_found_objects', delete_not_found_objects)) + + if enabled is not None: + + _query_params.append(('enabled', enabled)) + + if group_membership_field is not None: + + _query_params.append(('group_membership_field', group_membership_field)) + + if group_object_filter is not None: + + _query_params.append(('group_object_filter', group_object_filter)) + + if group_property_mappings is not None: + + _query_params.append(('group_property_mappings', group_property_mappings)) + + if lookup_groups_from_user is not None: + + _query_params.append(('lookup_groups_from_user', lookup_groups_from_user)) + + if name is not None: + + _query_params.append(('name', name)) + + if object_uniqueness_field is not None: + + _query_params.append(('object_uniqueness_field', object_uniqueness_field)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if password_login_update_internal_password is not None: + + _query_params.append(('password_login_update_internal_password', password_login_update_internal_password)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if peer_certificate is not None: + + _query_params.append(('peer_certificate', peer_certificate)) + + if search is not None: + + _query_params.append(('search', search)) + + if server_uri is not None: + + _query_params.append(('server_uri', server_uri)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + if sni is not None: + + _query_params.append(('sni', sni)) + + if start_tls is not None: + + _query_params.append(('start_tls', start_tls)) + + if sync_groups is not None: + + _query_params.append(('sync_groups', sync_groups)) + + if sync_parent_group is not None: + + _query_params.append(('sync_parent_group', sync_parent_group)) + + if sync_users is not None: + + _query_params.append(('sync_users', sync_users)) + + if sync_users_password is not None: + + _query_params.append(('sync_users_password', sync_users_password)) + + if user_membership_attribute is not None: + + _query_params.append(('user_membership_attribute', user_membership_attribute)) + + if user_object_filter is not None: + + _query_params.append(('user_object_filter', user_object_filter)) + + if user_property_mappings is not None: + + _query_params.append(('user_property_mappings', user_property_mappings)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_ldap_partial_update( + self, + slug: StrictStr, + patched_ldap_source_request: Optional[PatchedLDAPSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPSource: + """sources_ldap_partial_update + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param patched_ldap_source_request: + :type patched_ldap_source_request: PatchedLDAPSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_partial_update_serialize( + slug=slug, + patched_ldap_source_request=patched_ldap_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_ldap_partial_update_with_http_info( + self, + slug: StrictStr, + patched_ldap_source_request: Optional[PatchedLDAPSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPSource]: + """sources_ldap_partial_update + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param patched_ldap_source_request: + :type patched_ldap_source_request: PatchedLDAPSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_partial_update_serialize( + slug=slug, + patched_ldap_source_request=patched_ldap_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_ldap_partial_update_without_preload_content( + self, + slug: StrictStr, + patched_ldap_source_request: Optional[PatchedLDAPSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_ldap_partial_update + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param patched_ldap_source_request: + :type patched_ldap_source_request: PatchedLDAPSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_partial_update_serialize( + slug=slug, + patched_ldap_source_request=patched_ldap_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_ldap_partial_update_serialize( + self, + slug, + patched_ldap_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_ldap_source_request is not None: + _body_params = patched_ldap_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/ldap/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_ldap_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPSource: + """sources_ldap_retrieve + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_ldap_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPSource]: + """sources_ldap_retrieve + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_ldap_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_ldap_retrieve + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_ldap_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/ldap/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_ldap_sync_status_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SyncStatus: + """sources_ldap_sync_status_retrieve + + Get provider's sync status + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_sync_status_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_ldap_sync_status_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SyncStatus]: + """sources_ldap_sync_status_retrieve + + Get provider's sync status + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_sync_status_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_ldap_sync_status_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_ldap_sync_status_retrieve + + Get provider's sync status + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_sync_status_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SyncStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_ldap_sync_status_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/ldap/{slug}/sync/status/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_ldap_update( + self, + slug: StrictStr, + ldap_source_request: LDAPSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> LDAPSource: + """sources_ldap_update + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param ldap_source_request: (required) + :type ldap_source_request: LDAPSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_update_serialize( + slug=slug, + ldap_source_request=ldap_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_ldap_update_with_http_info( + self, + slug: StrictStr, + ldap_source_request: LDAPSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[LDAPSource]: + """sources_ldap_update + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param ldap_source_request: (required) + :type ldap_source_request: LDAPSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_update_serialize( + slug=slug, + ldap_source_request=ldap_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_ldap_update_without_preload_content( + self, + slug: StrictStr, + ldap_source_request: LDAPSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_ldap_update + + LDAP Source Viewset + + :param slug: (required) + :type slug: str + :param ldap_source_request: (required) + :type ldap_source_request: LDAPSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_update_serialize( + slug=slug, + ldap_source_request=ldap_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "LDAPSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_ldap_update_serialize( + self, + slug, + ldap_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if ldap_source_request is not None: + _body_params = ldap_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/ldap/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_ldap_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_ldap_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_ldap_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_ldap_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_ldap_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_ldap_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_ldap_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_ldap_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/ldap/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_oauth_create( + self, + o_auth_source_request: OAuthSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuthSource: + """sources_oauth_create + + Source Viewset + + :param o_auth_source_request: (required) + :type o_auth_source_request: OAuthSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_create_serialize( + o_auth_source_request=o_auth_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_oauth_create_with_http_info( + self, + o_auth_source_request: OAuthSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuthSource]: + """sources_oauth_create + + Source Viewset + + :param o_auth_source_request: (required) + :type o_auth_source_request: OAuthSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_create_serialize( + o_auth_source_request=o_auth_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_oauth_create_without_preload_content( + self, + o_auth_source_request: OAuthSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_oauth_create + + Source Viewset + + :param o_auth_source_request: (required) + :type o_auth_source_request: OAuthSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_create_serialize( + o_auth_source_request=o_auth_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_oauth_create_serialize( + self, + o_auth_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if o_auth_source_request is not None: + _body_params = o_auth_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/oauth/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_oauth_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_oauth_destroy + + Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_oauth_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_oauth_destroy + + Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_oauth_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_oauth_destroy + + Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_oauth_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/oauth/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_oauth_list( + self, + access_token_url: Optional[StrictStr] = None, + additional_scopes: Optional[StrictStr] = None, + authentication_flow: Optional[UUID] = None, + authorization_url: Optional[StrictStr] = None, + consumer_key: Optional[StrictStr] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + group_matching_mode: Optional[Any] = None, + has_jwks: Annotated[Optional[StrictBool], Field(description="Only return sources with JWKS data")] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + profile_url: Optional[StrictStr] = None, + provider_type: Optional[StrictStr] = None, + request_token_url: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedOAuthSourceList: + """sources_oauth_list + + Source Viewset + + :param access_token_url: + :type access_token_url: str + :param additional_scopes: + :type additional_scopes: str + :param authentication_flow: + :type authentication_flow: UUID + :param authorization_url: + :type authorization_url: str + :param consumer_key: + :type consumer_key: str + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param group_matching_mode: + :type group_matching_mode: GroupMatchingModeEnum + :param has_jwks: Only return sources with JWKS data + :type has_jwks: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param profile_url: + :type profile_url: str + :param provider_type: + :type provider_type: str + :param request_token_url: + :type request_token_url: str + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_list_serialize( + access_token_url=access_token_url, + additional_scopes=additional_scopes, + authentication_flow=authentication_flow, + authorization_url=authorization_url, + consumer_key=consumer_key, + enabled=enabled, + enrollment_flow=enrollment_flow, + group_matching_mode=group_matching_mode, + has_jwks=has_jwks, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + profile_url=profile_url, + provider_type=provider_type, + request_token_url=request_token_url, + search=search, + slug=slug, + user_matching_mode=user_matching_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOAuthSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_oauth_list_with_http_info( + self, + access_token_url: Optional[StrictStr] = None, + additional_scopes: Optional[StrictStr] = None, + authentication_flow: Optional[UUID] = None, + authorization_url: Optional[StrictStr] = None, + consumer_key: Optional[StrictStr] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + group_matching_mode: Optional[Any] = None, + has_jwks: Annotated[Optional[StrictBool], Field(description="Only return sources with JWKS data")] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + profile_url: Optional[StrictStr] = None, + provider_type: Optional[StrictStr] = None, + request_token_url: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedOAuthSourceList]: + """sources_oauth_list + + Source Viewset + + :param access_token_url: + :type access_token_url: str + :param additional_scopes: + :type additional_scopes: str + :param authentication_flow: + :type authentication_flow: UUID + :param authorization_url: + :type authorization_url: str + :param consumer_key: + :type consumer_key: str + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param group_matching_mode: + :type group_matching_mode: GroupMatchingModeEnum + :param has_jwks: Only return sources with JWKS data + :type has_jwks: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param profile_url: + :type profile_url: str + :param provider_type: + :type provider_type: str + :param request_token_url: + :type request_token_url: str + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_list_serialize( + access_token_url=access_token_url, + additional_scopes=additional_scopes, + authentication_flow=authentication_flow, + authorization_url=authorization_url, + consumer_key=consumer_key, + enabled=enabled, + enrollment_flow=enrollment_flow, + group_matching_mode=group_matching_mode, + has_jwks=has_jwks, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + profile_url=profile_url, + provider_type=provider_type, + request_token_url=request_token_url, + search=search, + slug=slug, + user_matching_mode=user_matching_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOAuthSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_oauth_list_without_preload_content( + self, + access_token_url: Optional[StrictStr] = None, + additional_scopes: Optional[StrictStr] = None, + authentication_flow: Optional[UUID] = None, + authorization_url: Optional[StrictStr] = None, + consumer_key: Optional[StrictStr] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + group_matching_mode: Optional[Any] = None, + has_jwks: Annotated[Optional[StrictBool], Field(description="Only return sources with JWKS data")] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + profile_url: Optional[StrictStr] = None, + provider_type: Optional[StrictStr] = None, + request_token_url: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_oauth_list + + Source Viewset + + :param access_token_url: + :type access_token_url: str + :param additional_scopes: + :type additional_scopes: str + :param authentication_flow: + :type authentication_flow: UUID + :param authorization_url: + :type authorization_url: str + :param consumer_key: + :type consumer_key: str + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param group_matching_mode: + :type group_matching_mode: GroupMatchingModeEnum + :param has_jwks: Only return sources with JWKS data + :type has_jwks: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param profile_url: + :type profile_url: str + :param provider_type: + :type provider_type: str + :param request_token_url: + :type request_token_url: str + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_list_serialize( + access_token_url=access_token_url, + additional_scopes=additional_scopes, + authentication_flow=authentication_flow, + authorization_url=authorization_url, + consumer_key=consumer_key, + enabled=enabled, + enrollment_flow=enrollment_flow, + group_matching_mode=group_matching_mode, + has_jwks=has_jwks, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + profile_url=profile_url, + provider_type=provider_type, + request_token_url=request_token_url, + search=search, + slug=slug, + user_matching_mode=user_matching_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedOAuthSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_oauth_list_serialize( + self, + access_token_url, + additional_scopes, + authentication_flow, + authorization_url, + consumer_key, + enabled, + enrollment_flow, + group_matching_mode, + has_jwks, + name, + ordering, + page, + page_size, + pbm_uuid, + policy_engine_mode, + profile_url, + provider_type, + request_token_url, + search, + slug, + user_matching_mode, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if access_token_url is not None: + + _query_params.append(('access_token_url', access_token_url)) + + if additional_scopes is not None: + + _query_params.append(('additional_scopes', additional_scopes)) + + if authentication_flow is not None: + + _query_params.append(('authentication_flow', authentication_flow)) + + if authorization_url is not None: + + _query_params.append(('authorization_url', authorization_url)) + + if consumer_key is not None: + + _query_params.append(('consumer_key', consumer_key)) + + if enabled is not None: + + _query_params.append(('enabled', enabled)) + + if enrollment_flow is not None: + + _query_params.append(('enrollment_flow', enrollment_flow)) + + if group_matching_mode is not None: + + _query_params.append(('group_matching_mode', group_matching_mode.value)) + + if has_jwks is not None: + + _query_params.append(('has_jwks', has_jwks)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if policy_engine_mode is not None: + + _query_params.append(('policy_engine_mode', policy_engine_mode.value)) + + if profile_url is not None: + + _query_params.append(('profile_url', profile_url)) + + if provider_type is not None: + + _query_params.append(('provider_type', provider_type)) + + if request_token_url is not None: + + _query_params.append(('request_token_url', request_token_url)) + + if search is not None: + + _query_params.append(('search', search)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + if user_matching_mode is not None: + + _query_params.append(('user_matching_mode', user_matching_mode.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/oauth/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_oauth_partial_update( + self, + slug: StrictStr, + patched_o_auth_source_request: Optional[PatchedOAuthSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuthSource: + """sources_oauth_partial_update + + Source Viewset + + :param slug: (required) + :type slug: str + :param patched_o_auth_source_request: + :type patched_o_auth_source_request: PatchedOAuthSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_partial_update_serialize( + slug=slug, + patched_o_auth_source_request=patched_o_auth_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_oauth_partial_update_with_http_info( + self, + slug: StrictStr, + patched_o_auth_source_request: Optional[PatchedOAuthSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuthSource]: + """sources_oauth_partial_update + + Source Viewset + + :param slug: (required) + :type slug: str + :param patched_o_auth_source_request: + :type patched_o_auth_source_request: PatchedOAuthSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_partial_update_serialize( + slug=slug, + patched_o_auth_source_request=patched_o_auth_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_oauth_partial_update_without_preload_content( + self, + slug: StrictStr, + patched_o_auth_source_request: Optional[PatchedOAuthSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_oauth_partial_update + + Source Viewset + + :param slug: (required) + :type slug: str + :param patched_o_auth_source_request: + :type patched_o_auth_source_request: PatchedOAuthSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_partial_update_serialize( + slug=slug, + patched_o_auth_source_request=patched_o_auth_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_oauth_partial_update_serialize( + self, + slug, + patched_o_auth_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_o_auth_source_request is not None: + _body_params = patched_o_auth_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/oauth/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_oauth_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuthSource: + """sources_oauth_retrieve + + Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_oauth_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuthSource]: + """sources_oauth_retrieve + + Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_oauth_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_oauth_retrieve + + Source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_oauth_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/oauth/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_oauth_source_types_list( + self, + name: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[SourceType]: + """sources_oauth_source_types_list + + Get all creatable source types. If ?name is set, only returns the type for . If isn't found, returns the default type. + + :param name: + :type name: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_source_types_list_serialize( + name=name, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[SourceType]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_oauth_source_types_list_with_http_info( + self, + name: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[SourceType]]: + """sources_oauth_source_types_list + + Get all creatable source types. If ?name is set, only returns the type for . If isn't found, returns the default type. + + :param name: + :type name: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_source_types_list_serialize( + name=name, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[SourceType]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_oauth_source_types_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_oauth_source_types_list + + Get all creatable source types. If ?name is set, only returns the type for . If isn't found, returns the default type. + + :param name: + :type name: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_source_types_list_serialize( + name=name, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[SourceType]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_oauth_source_types_list_serialize( + self, + name, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/oauth/source_types/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_oauth_update( + self, + slug: StrictStr, + o_auth_source_request: OAuthSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> OAuthSource: + """sources_oauth_update + + Source Viewset + + :param slug: (required) + :type slug: str + :param o_auth_source_request: (required) + :type o_auth_source_request: OAuthSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_update_serialize( + slug=slug, + o_auth_source_request=o_auth_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_oauth_update_with_http_info( + self, + slug: StrictStr, + o_auth_source_request: OAuthSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[OAuthSource]: + """sources_oauth_update + + Source Viewset + + :param slug: (required) + :type slug: str + :param o_auth_source_request: (required) + :type o_auth_source_request: OAuthSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_update_serialize( + slug=slug, + o_auth_source_request=o_auth_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_oauth_update_without_preload_content( + self, + slug: StrictStr, + o_auth_source_request: OAuthSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_oauth_update + + Source Viewset + + :param slug: (required) + :type slug: str + :param o_auth_source_request: (required) + :type o_auth_source_request: OAuthSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_update_serialize( + slug=slug, + o_auth_source_request=o_auth_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "OAuthSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_oauth_update_serialize( + self, + slug, + o_auth_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if o_auth_source_request is not None: + _body_params = o_auth_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/oauth/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_oauth_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_oauth_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_oauth_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_oauth_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_oauth_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_oauth_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_oauth_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_oauth_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/oauth/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_plex_create( + self, + plex_source_request: PlexSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PlexSource: + """sources_plex_create + + Plex source Viewset + + :param plex_source_request: (required) + :type plex_source_request: PlexSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_create_serialize( + plex_source_request=plex_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_plex_create_with_http_info( + self, + plex_source_request: PlexSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PlexSource]: + """sources_plex_create + + Plex source Viewset + + :param plex_source_request: (required) + :type plex_source_request: PlexSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_create_serialize( + plex_source_request=plex_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_plex_create_without_preload_content( + self, + plex_source_request: PlexSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_plex_create + + Plex source Viewset + + :param plex_source_request: (required) + :type plex_source_request: PlexSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_create_serialize( + plex_source_request=plex_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_plex_create_serialize( + self, + plex_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if plex_source_request is not None: + _body_params = plex_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/plex/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_plex_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_plex_destroy + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_plex_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_plex_destroy + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_plex_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_plex_destroy + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_plex_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/plex/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_plex_list( + self, + allow_friends: Optional[StrictBool] = None, + authentication_flow: Optional[UUID] = None, + client_id: Optional[StrictStr] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + group_matching_mode: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPlexSourceList: + """sources_plex_list + + Plex source Viewset + + :param allow_friends: + :type allow_friends: bool + :param authentication_flow: + :type authentication_flow: UUID + :param client_id: + :type client_id: str + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param group_matching_mode: + :type group_matching_mode: GroupMatchingModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_list_serialize( + allow_friends=allow_friends, + authentication_flow=authentication_flow, + client_id=client_id, + enabled=enabled, + enrollment_flow=enrollment_flow, + group_matching_mode=group_matching_mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + search=search, + slug=slug, + user_matching_mode=user_matching_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPlexSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_plex_list_with_http_info( + self, + allow_friends: Optional[StrictBool] = None, + authentication_flow: Optional[UUID] = None, + client_id: Optional[StrictStr] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + group_matching_mode: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPlexSourceList]: + """sources_plex_list + + Plex source Viewset + + :param allow_friends: + :type allow_friends: bool + :param authentication_flow: + :type authentication_flow: UUID + :param client_id: + :type client_id: str + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param group_matching_mode: + :type group_matching_mode: GroupMatchingModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_list_serialize( + allow_friends=allow_friends, + authentication_flow=authentication_flow, + client_id=client_id, + enabled=enabled, + enrollment_flow=enrollment_flow, + group_matching_mode=group_matching_mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + search=search, + slug=slug, + user_matching_mode=user_matching_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPlexSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_plex_list_without_preload_content( + self, + allow_friends: Optional[StrictBool] = None, + authentication_flow: Optional[UUID] = None, + client_id: Optional[StrictStr] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + group_matching_mode: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_plex_list + + Plex source Viewset + + :param allow_friends: + :type allow_friends: bool + :param authentication_flow: + :type authentication_flow: UUID + :param client_id: + :type client_id: str + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param group_matching_mode: + :type group_matching_mode: GroupMatchingModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_list_serialize( + allow_friends=allow_friends, + authentication_flow=authentication_flow, + client_id=client_id, + enabled=enabled, + enrollment_flow=enrollment_flow, + group_matching_mode=group_matching_mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + search=search, + slug=slug, + user_matching_mode=user_matching_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPlexSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_plex_list_serialize( + self, + allow_friends, + authentication_flow, + client_id, + enabled, + enrollment_flow, + group_matching_mode, + name, + ordering, + page, + page_size, + pbm_uuid, + policy_engine_mode, + search, + slug, + user_matching_mode, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if allow_friends is not None: + + _query_params.append(('allow_friends', allow_friends)) + + if authentication_flow is not None: + + _query_params.append(('authentication_flow', authentication_flow)) + + if client_id is not None: + + _query_params.append(('client_id', client_id)) + + if enabled is not None: + + _query_params.append(('enabled', enabled)) + + if enrollment_flow is not None: + + _query_params.append(('enrollment_flow', enrollment_flow)) + + if group_matching_mode is not None: + + _query_params.append(('group_matching_mode', group_matching_mode.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if policy_engine_mode is not None: + + _query_params.append(('policy_engine_mode', policy_engine_mode.value)) + + if search is not None: + + _query_params.append(('search', search)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + if user_matching_mode is not None: + + _query_params.append(('user_matching_mode', user_matching_mode.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/plex/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_plex_partial_update( + self, + slug: StrictStr, + patched_plex_source_request: Optional[PatchedPlexSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PlexSource: + """sources_plex_partial_update + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param patched_plex_source_request: + :type patched_plex_source_request: PatchedPlexSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_partial_update_serialize( + slug=slug, + patched_plex_source_request=patched_plex_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_plex_partial_update_with_http_info( + self, + slug: StrictStr, + patched_plex_source_request: Optional[PatchedPlexSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PlexSource]: + """sources_plex_partial_update + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param patched_plex_source_request: + :type patched_plex_source_request: PatchedPlexSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_partial_update_serialize( + slug=slug, + patched_plex_source_request=patched_plex_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_plex_partial_update_without_preload_content( + self, + slug: StrictStr, + patched_plex_source_request: Optional[PatchedPlexSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_plex_partial_update + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param patched_plex_source_request: + :type patched_plex_source_request: PatchedPlexSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_partial_update_serialize( + slug=slug, + patched_plex_source_request=patched_plex_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_plex_partial_update_serialize( + self, + slug, + patched_plex_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_plex_source_request is not None: + _body_params = patched_plex_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/plex/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_plex_redeem_token_authenticated_create( + self, + plex_token_redeem_request: PlexTokenRedeemRequest, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_plex_redeem_token_authenticated_create + + Redeem a plex token for an authenticated user, creating a connection + + :param plex_token_redeem_request: (required) + :type plex_token_redeem_request: PlexTokenRedeemRequest + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_redeem_token_authenticated_create_serialize( + plex_token_redeem_request=plex_token_redeem_request, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': None, + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_plex_redeem_token_authenticated_create_with_http_info( + self, + plex_token_redeem_request: PlexTokenRedeemRequest, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_plex_redeem_token_authenticated_create + + Redeem a plex token for an authenticated user, creating a connection + + :param plex_token_redeem_request: (required) + :type plex_token_redeem_request: PlexTokenRedeemRequest + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_redeem_token_authenticated_create_serialize( + plex_token_redeem_request=plex_token_redeem_request, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': None, + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_plex_redeem_token_authenticated_create_without_preload_content( + self, + plex_token_redeem_request: PlexTokenRedeemRequest, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_plex_redeem_token_authenticated_create + + Redeem a plex token for an authenticated user, creating a connection + + :param plex_token_redeem_request: (required) + :type plex_token_redeem_request: PlexTokenRedeemRequest + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_redeem_token_authenticated_create_serialize( + plex_token_redeem_request=plex_token_redeem_request, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': None, + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_plex_redeem_token_authenticated_create_serialize( + self, + plex_token_redeem_request, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if slug is not None: + + _query_params.append(('slug', slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + if plex_token_redeem_request is not None: + _body_params = plex_token_redeem_request + + + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/plex/redeem_token_authenticated/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_plex_redeem_token_create( + self, + plex_token_redeem_request: PlexTokenRedeemRequest, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RedirectChallenge: + """sources_plex_redeem_token_create + + Redeem a plex token, check it's access to resources against what's allowed for the source, and redirect to an authentication/enrollment flow. + + :param plex_token_redeem_request: (required) + :type plex_token_redeem_request: PlexTokenRedeemRequest + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_redeem_token_create_serialize( + plex_token_redeem_request=plex_token_redeem_request, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectChallenge", + '400': None, + '403': None, + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_plex_redeem_token_create_with_http_info( + self, + plex_token_redeem_request: PlexTokenRedeemRequest, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RedirectChallenge]: + """sources_plex_redeem_token_create + + Redeem a plex token, check it's access to resources against what's allowed for the source, and redirect to an authentication/enrollment flow. + + :param plex_token_redeem_request: (required) + :type plex_token_redeem_request: PlexTokenRedeemRequest + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_redeem_token_create_serialize( + plex_token_redeem_request=plex_token_redeem_request, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectChallenge", + '400': None, + '403': None, + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_plex_redeem_token_create_without_preload_content( + self, + plex_token_redeem_request: PlexTokenRedeemRequest, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_plex_redeem_token_create + + Redeem a plex token, check it's access to resources against what's allowed for the source, and redirect to an authentication/enrollment flow. + + :param plex_token_redeem_request: (required) + :type plex_token_redeem_request: PlexTokenRedeemRequest + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_redeem_token_create_serialize( + plex_token_redeem_request=plex_token_redeem_request, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectChallenge", + '400': None, + '403': None, + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_plex_redeem_token_create_serialize( + self, + plex_token_redeem_request, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if slug is not None: + + _query_params.append(('slug', slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + if plex_token_redeem_request is not None: + _body_params = plex_token_redeem_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/plex/redeem_token/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_plex_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PlexSource: + """sources_plex_retrieve + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_plex_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PlexSource]: + """sources_plex_retrieve + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_plex_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_plex_retrieve + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_plex_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/plex/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_plex_update( + self, + slug: StrictStr, + plex_source_request: PlexSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PlexSource: + """sources_plex_update + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param plex_source_request: (required) + :type plex_source_request: PlexSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_update_serialize( + slug=slug, + plex_source_request=plex_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_plex_update_with_http_info( + self, + slug: StrictStr, + plex_source_request: PlexSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PlexSource]: + """sources_plex_update + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param plex_source_request: (required) + :type plex_source_request: PlexSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_update_serialize( + slug=slug, + plex_source_request=plex_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_plex_update_without_preload_content( + self, + slug: StrictStr, + plex_source_request: PlexSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_plex_update + + Plex source Viewset + + :param slug: (required) + :type slug: str + :param plex_source_request: (required) + :type plex_source_request: PlexSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_update_serialize( + slug=slug, + plex_source_request=plex_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PlexSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_plex_update_serialize( + self, + slug, + plex_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if plex_source_request is not None: + _body_params = plex_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/plex/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_plex_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_plex_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_plex_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_plex_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_plex_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_plex_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_plex_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_plex_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/plex/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_saml_create( + self, + saml_source_request: SAMLSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLSource: + """sources_saml_create + + SAMLSource Viewset + + :param saml_source_request: (required) + :type saml_source_request: SAMLSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_create_serialize( + saml_source_request=saml_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_saml_create_with_http_info( + self, + saml_source_request: SAMLSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLSource]: + """sources_saml_create + + SAMLSource Viewset + + :param saml_source_request: (required) + :type saml_source_request: SAMLSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_create_serialize( + saml_source_request=saml_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_saml_create_without_preload_content( + self, + saml_source_request: SAMLSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_saml_create + + SAMLSource Viewset + + :param saml_source_request: (required) + :type saml_source_request: SAMLSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_create_serialize( + saml_source_request=saml_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_saml_create_serialize( + self, + saml_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if saml_source_request is not None: + _body_params = saml_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_saml_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_saml_destroy + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_saml_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_saml_destroy + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_saml_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_saml_destroy + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_saml_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/saml/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_saml_list( + self, + allow_idp_initiated: Optional[StrictBool] = None, + authentication_flow: Optional[UUID] = None, + binding_type: Optional[BindingTypeEnum] = None, + digest_algorithm: Optional[DigestAlgorithmEnum] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + force_authn: Optional[StrictBool] = None, + issuer: Optional[StrictStr] = None, + managed: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + name_id_policy: Optional[Any] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + pre_authentication_flow: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + signature_algorithm: Optional[SignatureAlgorithmEnum] = None, + signed_assertion: Optional[StrictBool] = None, + signed_response: Optional[StrictBool] = None, + signing_kp: Optional[UUID] = None, + slo_url: Optional[StrictStr] = None, + slug: Optional[StrictStr] = None, + sso_url: Optional[StrictStr] = None, + temporary_user_delete_after: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + verification_kp: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSAMLSourceList: + """sources_saml_list + + SAMLSource Viewset + + :param allow_idp_initiated: + :type allow_idp_initiated: bool + :param authentication_flow: + :type authentication_flow: UUID + :param binding_type: + :type binding_type: BindingTypeEnum + :param digest_algorithm: + :type digest_algorithm: DigestAlgorithmEnum + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param force_authn: + :type force_authn: bool + :param issuer: + :type issuer: str + :param managed: + :type managed: str + :param name: + :type name: str + :param name_id_policy: + :type name_id_policy: SAMLNameIDPolicyEnum + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param pre_authentication_flow: + :type pre_authentication_flow: UUID + :param search: A search term. + :type search: str + :param signature_algorithm: + :type signature_algorithm: SignatureAlgorithmEnum + :param signed_assertion: + :type signed_assertion: bool + :param signed_response: + :type signed_response: bool + :param signing_kp: + :type signing_kp: UUID + :param slo_url: + :type slo_url: str + :param slug: + :type slug: str + :param sso_url: + :type sso_url: str + :param temporary_user_delete_after: + :type temporary_user_delete_after: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param verification_kp: + :type verification_kp: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_list_serialize( + allow_idp_initiated=allow_idp_initiated, + authentication_flow=authentication_flow, + binding_type=binding_type, + digest_algorithm=digest_algorithm, + enabled=enabled, + enrollment_flow=enrollment_flow, + force_authn=force_authn, + issuer=issuer, + managed=managed, + name=name, + name_id_policy=name_id_policy, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + pre_authentication_flow=pre_authentication_flow, + search=search, + signature_algorithm=signature_algorithm, + signed_assertion=signed_assertion, + signed_response=signed_response, + signing_kp=signing_kp, + slo_url=slo_url, + slug=slug, + sso_url=sso_url, + temporary_user_delete_after=temporary_user_delete_after, + user_matching_mode=user_matching_mode, + verification_kp=verification_kp, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_saml_list_with_http_info( + self, + allow_idp_initiated: Optional[StrictBool] = None, + authentication_flow: Optional[UUID] = None, + binding_type: Optional[BindingTypeEnum] = None, + digest_algorithm: Optional[DigestAlgorithmEnum] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + force_authn: Optional[StrictBool] = None, + issuer: Optional[StrictStr] = None, + managed: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + name_id_policy: Optional[Any] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + pre_authentication_flow: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + signature_algorithm: Optional[SignatureAlgorithmEnum] = None, + signed_assertion: Optional[StrictBool] = None, + signed_response: Optional[StrictBool] = None, + signing_kp: Optional[UUID] = None, + slo_url: Optional[StrictStr] = None, + slug: Optional[StrictStr] = None, + sso_url: Optional[StrictStr] = None, + temporary_user_delete_after: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + verification_kp: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSAMLSourceList]: + """sources_saml_list + + SAMLSource Viewset + + :param allow_idp_initiated: + :type allow_idp_initiated: bool + :param authentication_flow: + :type authentication_flow: UUID + :param binding_type: + :type binding_type: BindingTypeEnum + :param digest_algorithm: + :type digest_algorithm: DigestAlgorithmEnum + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param force_authn: + :type force_authn: bool + :param issuer: + :type issuer: str + :param managed: + :type managed: str + :param name: + :type name: str + :param name_id_policy: + :type name_id_policy: SAMLNameIDPolicyEnum + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param pre_authentication_flow: + :type pre_authentication_flow: UUID + :param search: A search term. + :type search: str + :param signature_algorithm: + :type signature_algorithm: SignatureAlgorithmEnum + :param signed_assertion: + :type signed_assertion: bool + :param signed_response: + :type signed_response: bool + :param signing_kp: + :type signing_kp: UUID + :param slo_url: + :type slo_url: str + :param slug: + :type slug: str + :param sso_url: + :type sso_url: str + :param temporary_user_delete_after: + :type temporary_user_delete_after: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param verification_kp: + :type verification_kp: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_list_serialize( + allow_idp_initiated=allow_idp_initiated, + authentication_flow=authentication_flow, + binding_type=binding_type, + digest_algorithm=digest_algorithm, + enabled=enabled, + enrollment_flow=enrollment_flow, + force_authn=force_authn, + issuer=issuer, + managed=managed, + name=name, + name_id_policy=name_id_policy, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + pre_authentication_flow=pre_authentication_flow, + search=search, + signature_algorithm=signature_algorithm, + signed_assertion=signed_assertion, + signed_response=signed_response, + signing_kp=signing_kp, + slo_url=slo_url, + slug=slug, + sso_url=sso_url, + temporary_user_delete_after=temporary_user_delete_after, + user_matching_mode=user_matching_mode, + verification_kp=verification_kp, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_saml_list_without_preload_content( + self, + allow_idp_initiated: Optional[StrictBool] = None, + authentication_flow: Optional[UUID] = None, + binding_type: Optional[BindingTypeEnum] = None, + digest_algorithm: Optional[DigestAlgorithmEnum] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + force_authn: Optional[StrictBool] = None, + issuer: Optional[StrictStr] = None, + managed: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + name_id_policy: Optional[Any] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + pre_authentication_flow: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + signature_algorithm: Optional[SignatureAlgorithmEnum] = None, + signed_assertion: Optional[StrictBool] = None, + signed_response: Optional[StrictBool] = None, + signing_kp: Optional[UUID] = None, + slo_url: Optional[StrictStr] = None, + slug: Optional[StrictStr] = None, + sso_url: Optional[StrictStr] = None, + temporary_user_delete_after: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + verification_kp: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_saml_list + + SAMLSource Viewset + + :param allow_idp_initiated: + :type allow_idp_initiated: bool + :param authentication_flow: + :type authentication_flow: UUID + :param binding_type: + :type binding_type: BindingTypeEnum + :param digest_algorithm: + :type digest_algorithm: DigestAlgorithmEnum + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param force_authn: + :type force_authn: bool + :param issuer: + :type issuer: str + :param managed: + :type managed: str + :param name: + :type name: str + :param name_id_policy: + :type name_id_policy: SAMLNameIDPolicyEnum + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param pre_authentication_flow: + :type pre_authentication_flow: UUID + :param search: A search term. + :type search: str + :param signature_algorithm: + :type signature_algorithm: SignatureAlgorithmEnum + :param signed_assertion: + :type signed_assertion: bool + :param signed_response: + :type signed_response: bool + :param signing_kp: + :type signing_kp: UUID + :param slo_url: + :type slo_url: str + :param slug: + :type slug: str + :param sso_url: + :type sso_url: str + :param temporary_user_delete_after: + :type temporary_user_delete_after: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param verification_kp: + :type verification_kp: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_list_serialize( + allow_idp_initiated=allow_idp_initiated, + authentication_flow=authentication_flow, + binding_type=binding_type, + digest_algorithm=digest_algorithm, + enabled=enabled, + enrollment_flow=enrollment_flow, + force_authn=force_authn, + issuer=issuer, + managed=managed, + name=name, + name_id_policy=name_id_policy, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + pre_authentication_flow=pre_authentication_flow, + search=search, + signature_algorithm=signature_algorithm, + signed_assertion=signed_assertion, + signed_response=signed_response, + signing_kp=signing_kp, + slo_url=slo_url, + slug=slug, + sso_url=sso_url, + temporary_user_delete_after=temporary_user_delete_after, + user_matching_mode=user_matching_mode, + verification_kp=verification_kp, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSAMLSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_saml_list_serialize( + self, + allow_idp_initiated, + authentication_flow, + binding_type, + digest_algorithm, + enabled, + enrollment_flow, + force_authn, + issuer, + managed, + name, + name_id_policy, + ordering, + page, + page_size, + pbm_uuid, + policy_engine_mode, + pre_authentication_flow, + search, + signature_algorithm, + signed_assertion, + signed_response, + signing_kp, + slo_url, + slug, + sso_url, + temporary_user_delete_after, + user_matching_mode, + verification_kp, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if allow_idp_initiated is not None: + + _query_params.append(('allow_idp_initiated', allow_idp_initiated)) + + if authentication_flow is not None: + + _query_params.append(('authentication_flow', authentication_flow)) + + if binding_type is not None: + + _query_params.append(('binding_type', binding_type.value)) + + if digest_algorithm is not None: + + _query_params.append(('digest_algorithm', digest_algorithm.value)) + + if enabled is not None: + + _query_params.append(('enabled', enabled)) + + if enrollment_flow is not None: + + _query_params.append(('enrollment_flow', enrollment_flow)) + + if force_authn is not None: + + _query_params.append(('force_authn', force_authn)) + + if issuer is not None: + + _query_params.append(('issuer', issuer)) + + if managed is not None: + + _query_params.append(('managed', managed)) + + if name is not None: + + _query_params.append(('name', name)) + + if name_id_policy is not None: + + _query_params.append(('name_id_policy', name_id_policy.value)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if policy_engine_mode is not None: + + _query_params.append(('policy_engine_mode', policy_engine_mode.value)) + + if pre_authentication_flow is not None: + + _query_params.append(('pre_authentication_flow', pre_authentication_flow)) + + if search is not None: + + _query_params.append(('search', search)) + + if signature_algorithm is not None: + + _query_params.append(('signature_algorithm', signature_algorithm.value)) + + if signed_assertion is not None: + + _query_params.append(('signed_assertion', signed_assertion)) + + if signed_response is not None: + + _query_params.append(('signed_response', signed_response)) + + if signing_kp is not None: + + _query_params.append(('signing_kp', signing_kp)) + + if slo_url is not None: + + _query_params.append(('slo_url', slo_url)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + if sso_url is not None: + + _query_params.append(('sso_url', sso_url)) + + if temporary_user_delete_after is not None: + + _query_params.append(('temporary_user_delete_after', temporary_user_delete_after)) + + if user_matching_mode is not None: + + _query_params.append(('user_matching_mode', user_matching_mode.value)) + + if verification_kp is not None: + + _query_params.append(('verification_kp', verification_kp)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_saml_metadata_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLMetadata: + """sources_saml_metadata_retrieve + + Return metadata as XML string + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_metadata_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLMetadata", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_saml_metadata_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLMetadata]: + """sources_saml_metadata_retrieve + + Return metadata as XML string + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_metadata_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLMetadata", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_saml_metadata_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_saml_metadata_retrieve + + Return metadata as XML string + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_metadata_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLMetadata", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_saml_metadata_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/saml/{slug}/metadata/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_saml_partial_update( + self, + slug: StrictStr, + patched_saml_source_request: Optional[PatchedSAMLSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLSource: + """sources_saml_partial_update + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param patched_saml_source_request: + :type patched_saml_source_request: PatchedSAMLSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_partial_update_serialize( + slug=slug, + patched_saml_source_request=patched_saml_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_saml_partial_update_with_http_info( + self, + slug: StrictStr, + patched_saml_source_request: Optional[PatchedSAMLSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLSource]: + """sources_saml_partial_update + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param patched_saml_source_request: + :type patched_saml_source_request: PatchedSAMLSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_partial_update_serialize( + slug=slug, + patched_saml_source_request=patched_saml_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_saml_partial_update_without_preload_content( + self, + slug: StrictStr, + patched_saml_source_request: Optional[PatchedSAMLSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_saml_partial_update + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param patched_saml_source_request: + :type patched_saml_source_request: PatchedSAMLSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_partial_update_serialize( + slug=slug, + patched_saml_source_request=patched_saml_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_saml_partial_update_serialize( + self, + slug, + patched_saml_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_saml_source_request is not None: + _body_params = patched_saml_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/saml/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_saml_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLSource: + """sources_saml_retrieve + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_saml_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLSource]: + """sources_saml_retrieve + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_saml_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_saml_retrieve + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_saml_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/saml/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_saml_update( + self, + slug: StrictStr, + saml_source_request: SAMLSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SAMLSource: + """sources_saml_update + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param saml_source_request: (required) + :type saml_source_request: SAMLSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_update_serialize( + slug=slug, + saml_source_request=saml_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_saml_update_with_http_info( + self, + slug: StrictStr, + saml_source_request: SAMLSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SAMLSource]: + """sources_saml_update + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param saml_source_request: (required) + :type saml_source_request: SAMLSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_update_serialize( + slug=slug, + saml_source_request=saml_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_saml_update_without_preload_content( + self, + slug: StrictStr, + saml_source_request: SAMLSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_saml_update + + SAMLSource Viewset + + :param slug: (required) + :type slug: str + :param saml_source_request: (required) + :type saml_source_request: SAMLSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_update_serialize( + slug=slug, + saml_source_request=saml_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SAMLSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_saml_update_serialize( + self, + slug, + saml_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if saml_source_request is not None: + _body_params = saml_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/saml/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_saml_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_saml_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_saml_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_saml_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_saml_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_saml_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_saml_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_saml_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/saml/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_create( + self, + scim_source_request: SCIMSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSource: + """sources_scim_create + + SCIMSource Viewset + + :param scim_source_request: (required) + :type scim_source_request: SCIMSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_create_serialize( + scim_source_request=scim_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_create_with_http_info( + self, + scim_source_request: SCIMSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSource]: + """sources_scim_create + + SCIMSource Viewset + + :param scim_source_request: (required) + :type scim_source_request: SCIMSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_create_serialize( + scim_source_request=scim_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_create_without_preload_content( + self, + scim_source_request: SCIMSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_create + + SCIMSource Viewset + + :param scim_source_request: (required) + :type scim_source_request: SCIMSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_create_serialize( + scim_source_request=scim_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_create_serialize( + self, + scim_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_source_request is not None: + _body_params = scim_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/scim/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_scim_destroy + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_scim_destroy + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_destroy + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/scim/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_groups_create( + self, + scim_source_group_request: SCIMSourceGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourceGroup: + """sources_scim_groups_create + + SCIMSourceGroup Viewset + + :param scim_source_group_request: (required) + :type scim_source_group_request: SCIMSourceGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_create_serialize( + scim_source_group_request=scim_source_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_groups_create_with_http_info( + self, + scim_source_group_request: SCIMSourceGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourceGroup]: + """sources_scim_groups_create + + SCIMSourceGroup Viewset + + :param scim_source_group_request: (required) + :type scim_source_group_request: SCIMSourceGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_create_serialize( + scim_source_group_request=scim_source_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_groups_create_without_preload_content( + self, + scim_source_group_request: SCIMSourceGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_groups_create + + SCIMSourceGroup Viewset + + :param scim_source_group_request: (required) + :type scim_source_group_request: SCIMSourceGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_create_serialize( + scim_source_group_request=scim_source_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_groups_create_serialize( + self, + scim_source_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_source_group_request is not None: + _body_params = scim_source_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/scim_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_groups_destroy( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_scim_groups_destroy + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_groups_destroy_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_scim_groups_destroy + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_groups_destroy_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_groups_destroy + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_groups_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/scim_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_groups_list( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSCIMSourceGroupList: + """sources_scim_groups_list + + SCIMSourceGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourceGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_groups_list_with_http_info( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSCIMSourceGroupList]: + """sources_scim_groups_list + + SCIMSourceGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourceGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_groups_list_without_preload_content( + self, + group__group_uuid: Optional[UUID] = None, + group__name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_groups_list + + SCIMSourceGroup Viewset + + :param group__group_uuid: + :type group__group_uuid: UUID + :param group__name: + :type group__name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_list_serialize( + group__group_uuid=group__group_uuid, + group__name=group__name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourceGroupList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_groups_list_serialize( + self, + group__group_uuid, + group__name, + ordering, + page, + page_size, + search, + source__slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if group__group_uuid is not None: + + _query_params.append(('group__group_uuid', group__group_uuid)) + + if group__name is not None: + + _query_params.append(('group__name', group__name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/scim_groups/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_groups_partial_update( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + patched_scim_source_group_request: Optional[PatchedSCIMSourceGroupRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourceGroup: + """sources_scim_groups_partial_update + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param patched_scim_source_group_request: + :type patched_scim_source_group_request: PatchedSCIMSourceGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_partial_update_serialize( + id=id, + patched_scim_source_group_request=patched_scim_source_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_groups_partial_update_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + patched_scim_source_group_request: Optional[PatchedSCIMSourceGroupRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourceGroup]: + """sources_scim_groups_partial_update + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param patched_scim_source_group_request: + :type patched_scim_source_group_request: PatchedSCIMSourceGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_partial_update_serialize( + id=id, + patched_scim_source_group_request=patched_scim_source_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_groups_partial_update_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + patched_scim_source_group_request: Optional[PatchedSCIMSourceGroupRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_groups_partial_update + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param patched_scim_source_group_request: + :type patched_scim_source_group_request: PatchedSCIMSourceGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_partial_update_serialize( + id=id, + patched_scim_source_group_request=patched_scim_source_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_groups_partial_update_serialize( + self, + id, + patched_scim_source_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_scim_source_group_request is not None: + _body_params = patched_scim_source_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/scim_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_groups_retrieve( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourceGroup: + """sources_scim_groups_retrieve + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_groups_retrieve_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourceGroup]: + """sources_scim_groups_retrieve + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_groups_retrieve_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_groups_retrieve + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_groups_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/scim_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_groups_update( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + scim_source_group_request: SCIMSourceGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourceGroup: + """sources_scim_groups_update + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param scim_source_group_request: (required) + :type scim_source_group_request: SCIMSourceGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_update_serialize( + id=id, + scim_source_group_request=scim_source_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_groups_update_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + scim_source_group_request: SCIMSourceGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourceGroup]: + """sources_scim_groups_update + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param scim_source_group_request: (required) + :type scim_source_group_request: SCIMSourceGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_update_serialize( + id=id, + scim_source_group_request=scim_source_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_groups_update_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + scim_source_group_request: SCIMSourceGroupRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_groups_update + + SCIMSourceGroup Viewset + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param scim_source_group_request: (required) + :type scim_source_group_request: SCIMSourceGroupRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_update_serialize( + id=id, + scim_source_group_request=scim_source_group_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceGroup", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_groups_update_serialize( + self, + id, + scim_source_group_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_source_group_request is not None: + _body_params = scim_source_group_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/scim_groups/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_groups_used_by_list( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_scim_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_groups_used_by_list_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_scim_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_groups_used_by_list_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source group.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_groups_used_by_list + + Get a list of all objects that use this object + + :param id: A unique value identifying this scim source group. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_groups_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_groups_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/scim_groups/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSCIMSourceList: + """sources_scim_list + + SCIMSource Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSCIMSourceList]: + """sources_scim_list + + SCIMSource Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_list + + SCIMSource Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + search=search, + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_list_serialize( + self, + name, + ordering, + page, + page_size, + pbm_uuid, + search, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if search is not None: + + _query_params.append(('search', search)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/scim/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_partial_update( + self, + slug: StrictStr, + patched_scim_source_request: Optional[PatchedSCIMSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSource: + """sources_scim_partial_update + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param patched_scim_source_request: + :type patched_scim_source_request: PatchedSCIMSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_partial_update_serialize( + slug=slug, + patched_scim_source_request=patched_scim_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_partial_update_with_http_info( + self, + slug: StrictStr, + patched_scim_source_request: Optional[PatchedSCIMSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSource]: + """sources_scim_partial_update + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param patched_scim_source_request: + :type patched_scim_source_request: PatchedSCIMSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_partial_update_serialize( + slug=slug, + patched_scim_source_request=patched_scim_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_partial_update_without_preload_content( + self, + slug: StrictStr, + patched_scim_source_request: Optional[PatchedSCIMSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_partial_update + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param patched_scim_source_request: + :type patched_scim_source_request: PatchedSCIMSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_partial_update_serialize( + slug=slug, + patched_scim_source_request=patched_scim_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_partial_update_serialize( + self, + slug, + patched_scim_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_scim_source_request is not None: + _body_params = patched_scim_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/scim/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSource: + """sources_scim_retrieve + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSource]: + """sources_scim_retrieve + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_retrieve + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/scim/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_update( + self, + slug: StrictStr, + scim_source_request: SCIMSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSource: + """sources_scim_update + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param scim_source_request: (required) + :type scim_source_request: SCIMSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_update_serialize( + slug=slug, + scim_source_request=scim_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_update_with_http_info( + self, + slug: StrictStr, + scim_source_request: SCIMSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSource]: + """sources_scim_update + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param scim_source_request: (required) + :type scim_source_request: SCIMSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_update_serialize( + slug=slug, + scim_source_request=scim_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_update_without_preload_content( + self, + slug: StrictStr, + scim_source_request: SCIMSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_update + + SCIMSource Viewset + + :param slug: (required) + :type slug: str + :param scim_source_request: (required) + :type scim_source_request: SCIMSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_update_serialize( + slug=slug, + scim_source_request=scim_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_update_serialize( + self, + slug, + scim_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_source_request is not None: + _body_params = scim_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/scim/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_scim_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_scim_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/scim/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_users_create( + self, + scim_source_user_request: SCIMSourceUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourceUser: + """sources_scim_users_create + + SCIMSourceUser Viewset + + :param scim_source_user_request: (required) + :type scim_source_user_request: SCIMSourceUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_create_serialize( + scim_source_user_request=scim_source_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_users_create_with_http_info( + self, + scim_source_user_request: SCIMSourceUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourceUser]: + """sources_scim_users_create + + SCIMSourceUser Viewset + + :param scim_source_user_request: (required) + :type scim_source_user_request: SCIMSourceUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_create_serialize( + scim_source_user_request=scim_source_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_users_create_without_preload_content( + self, + scim_source_user_request: SCIMSourceUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_users_create + + SCIMSourceUser Viewset + + :param scim_source_user_request: (required) + :type scim_source_user_request: SCIMSourceUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_create_serialize( + scim_source_user_request=scim_source_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_users_create_serialize( + self, + scim_source_user_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_source_user_request is not None: + _body_params = scim_source_user_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/scim_users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_users_destroy( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_scim_users_destroy + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_users_destroy_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_scim_users_destroy + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_users_destroy_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_users_destroy + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_users_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/scim_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_users_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSCIMSourceUserList: + """sources_scim_users_list + + SCIMSourceUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourceUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_users_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSCIMSourceUserList]: + """sources_scim_users_list + + SCIMSourceUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourceUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_users_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user__id: Optional[StrictInt] = None, + user__username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_users_list + + SCIMSourceUser Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user__id: + :type user__id: int + :param user__username: + :type user__username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user__id=user__id, + user__username=user__username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSCIMSourceUserList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_users_list_serialize( + self, + ordering, + page, + page_size, + search, + source__slug, + user__id, + user__username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + if user__id is not None: + + _query_params.append(('user__id', user__id)) + + if user__username is not None: + + _query_params.append(('user__username', user__username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/scim_users/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_users_partial_update( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + patched_scim_source_user_request: Optional[PatchedSCIMSourceUserRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourceUser: + """sources_scim_users_partial_update + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param patched_scim_source_user_request: + :type patched_scim_source_user_request: PatchedSCIMSourceUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_partial_update_serialize( + id=id, + patched_scim_source_user_request=patched_scim_source_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_users_partial_update_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + patched_scim_source_user_request: Optional[PatchedSCIMSourceUserRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourceUser]: + """sources_scim_users_partial_update + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param patched_scim_source_user_request: + :type patched_scim_source_user_request: PatchedSCIMSourceUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_partial_update_serialize( + id=id, + patched_scim_source_user_request=patched_scim_source_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_users_partial_update_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + patched_scim_source_user_request: Optional[PatchedSCIMSourceUserRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_users_partial_update + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param patched_scim_source_user_request: + :type patched_scim_source_user_request: PatchedSCIMSourceUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_partial_update_serialize( + id=id, + patched_scim_source_user_request=patched_scim_source_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_users_partial_update_serialize( + self, + id, + patched_scim_source_user_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_scim_source_user_request is not None: + _body_params = patched_scim_source_user_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/scim_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_users_retrieve( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourceUser: + """sources_scim_users_retrieve + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_users_retrieve_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourceUser]: + """sources_scim_users_retrieve + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_users_retrieve_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_users_retrieve + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_users_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/scim_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_users_update( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + scim_source_user_request: SCIMSourceUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SCIMSourceUser: + """sources_scim_users_update + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param scim_source_user_request: (required) + :type scim_source_user_request: SCIMSourceUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_update_serialize( + id=id, + scim_source_user_request=scim_source_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_users_update_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + scim_source_user_request: SCIMSourceUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SCIMSourceUser]: + """sources_scim_users_update + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param scim_source_user_request: (required) + :type scim_source_user_request: SCIMSourceUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_update_serialize( + id=id, + scim_source_user_request=scim_source_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_users_update_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + scim_source_user_request: SCIMSourceUserRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_users_update + + SCIMSourceUser Viewset + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param scim_source_user_request: (required) + :type scim_source_user_request: SCIMSourceUserRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_update_serialize( + id=id, + scim_source_user_request=scim_source_user_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SCIMSourceUser", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_users_update_serialize( + self, + id, + scim_source_user_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if scim_source_user_request is not None: + _body_params = scim_source_user_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/scim_users/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_scim_users_used_by_list( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_scim_users_used_by_list + + Get a list of all objects that use this object + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_scim_users_used_by_list_with_http_info( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_scim_users_used_by_list + + Get a list of all objects that use this object + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_scim_users_used_by_list_without_preload_content( + self, + id: Annotated[StrictStr, Field(description="A unique value identifying this scim source user.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_scim_users_used_by_list + + Get a list of all objects that use this object + + :param id: A unique value identifying this scim source user. (required) + :type id: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_scim_users_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_scim_users_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/scim_users/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_telegram_connect_user_create( + self, + slug: StrictStr, + telegram_auth_request: TelegramAuthRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserTelegramSourceConnection: + """sources_telegram_connect_user_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param telegram_auth_request: (required) + :type telegram_auth_request: TelegramAuthRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_connect_user_create_serialize( + slug=slug, + telegram_auth_request=telegram_auth_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserTelegramSourceConnection", + '403': None, + '400': "ValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_telegram_connect_user_create_with_http_info( + self, + slug: StrictStr, + telegram_auth_request: TelegramAuthRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserTelegramSourceConnection]: + """sources_telegram_connect_user_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param telegram_auth_request: (required) + :type telegram_auth_request: TelegramAuthRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_connect_user_create_serialize( + slug=slug, + telegram_auth_request=telegram_auth_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserTelegramSourceConnection", + '403': None, + '400': "ValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_telegram_connect_user_create_without_preload_content( + self, + slug: StrictStr, + telegram_auth_request: TelegramAuthRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_telegram_connect_user_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param telegram_auth_request: (required) + :type telegram_auth_request: TelegramAuthRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_connect_user_create_serialize( + slug=slug, + telegram_auth_request=telegram_auth_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserTelegramSourceConnection", + '403': None, + '400': "ValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_telegram_connect_user_create_serialize( + self, + slug, + telegram_auth_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if telegram_auth_request is not None: + _body_params = telegram_auth_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/telegram/{slug}/connect_user/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_telegram_create( + self, + telegram_source_request: TelegramSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TelegramSource: + """sources_telegram_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param telegram_source_request: (required) + :type telegram_source_request: TelegramSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_create_serialize( + telegram_source_request=telegram_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_telegram_create_with_http_info( + self, + telegram_source_request: TelegramSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TelegramSource]: + """sources_telegram_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param telegram_source_request: (required) + :type telegram_source_request: TelegramSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_create_serialize( + telegram_source_request=telegram_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_telegram_create_without_preload_content( + self, + telegram_source_request: TelegramSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_telegram_create + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param telegram_source_request: (required) + :type telegram_source_request: TelegramSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_create_serialize( + telegram_source_request=telegram_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_telegram_create_serialize( + self, + telegram_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if telegram_source_request is not None: + _body_params = telegram_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/telegram/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_telegram_destroy( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_telegram_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_telegram_destroy_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_telegram_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_telegram_destroy_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_telegram_destroy + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_destroy_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_telegram_destroy_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/telegram/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_telegram_list( + self, + authentication_flow: Optional[UUID] = None, + bot_username: Optional[StrictStr] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + group_matching_mode: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + request_message_access: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedTelegramSourceList: + """sources_telegram_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param authentication_flow: + :type authentication_flow: UUID + :param bot_username: + :type bot_username: str + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param group_matching_mode: + :type group_matching_mode: GroupMatchingModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param request_message_access: + :type request_message_access: bool + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_list_serialize( + authentication_flow=authentication_flow, + bot_username=bot_username, + enabled=enabled, + enrollment_flow=enrollment_flow, + group_matching_mode=group_matching_mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + request_message_access=request_message_access, + search=search, + slug=slug, + user_matching_mode=user_matching_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTelegramSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_telegram_list_with_http_info( + self, + authentication_flow: Optional[UUID] = None, + bot_username: Optional[StrictStr] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + group_matching_mode: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + request_message_access: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedTelegramSourceList]: + """sources_telegram_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param authentication_flow: + :type authentication_flow: UUID + :param bot_username: + :type bot_username: str + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param group_matching_mode: + :type group_matching_mode: GroupMatchingModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param request_message_access: + :type request_message_access: bool + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_list_serialize( + authentication_flow=authentication_flow, + bot_username=bot_username, + enabled=enabled, + enrollment_flow=enrollment_flow, + group_matching_mode=group_matching_mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + request_message_access=request_message_access, + search=search, + slug=slug, + user_matching_mode=user_matching_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTelegramSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_telegram_list_without_preload_content( + self, + authentication_flow: Optional[UUID] = None, + bot_username: Optional[StrictStr] = None, + enabled: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + group_matching_mode: Optional[Any] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + pbm_uuid: Optional[UUID] = None, + policy_engine_mode: Optional[PolicyEngineMode] = None, + request_message_access: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + slug: Optional[StrictStr] = None, + user_matching_mode: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_telegram_list + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param authentication_flow: + :type authentication_flow: UUID + :param bot_username: + :type bot_username: str + :param enabled: + :type enabled: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param group_matching_mode: + :type group_matching_mode: GroupMatchingModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param pbm_uuid: + :type pbm_uuid: UUID + :param policy_engine_mode: + :type policy_engine_mode: PolicyEngineMode + :param request_message_access: + :type request_message_access: bool + :param search: A search term. + :type search: str + :param slug: + :type slug: str + :param user_matching_mode: + :type user_matching_mode: UserMatchingModeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_list_serialize( + authentication_flow=authentication_flow, + bot_username=bot_username, + enabled=enabled, + enrollment_flow=enrollment_flow, + group_matching_mode=group_matching_mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + pbm_uuid=pbm_uuid, + policy_engine_mode=policy_engine_mode, + request_message_access=request_message_access, + search=search, + slug=slug, + user_matching_mode=user_matching_mode, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTelegramSourceList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_telegram_list_serialize( + self, + authentication_flow, + bot_username, + enabled, + enrollment_flow, + group_matching_mode, + name, + ordering, + page, + page_size, + pbm_uuid, + policy_engine_mode, + request_message_access, + search, + slug, + user_matching_mode, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if authentication_flow is not None: + + _query_params.append(('authentication_flow', authentication_flow)) + + if bot_username is not None: + + _query_params.append(('bot_username', bot_username)) + + if enabled is not None: + + _query_params.append(('enabled', enabled)) + + if enrollment_flow is not None: + + _query_params.append(('enrollment_flow', enrollment_flow)) + + if group_matching_mode is not None: + + _query_params.append(('group_matching_mode', group_matching_mode.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if pbm_uuid is not None: + + _query_params.append(('pbm_uuid', pbm_uuid)) + + if policy_engine_mode is not None: + + _query_params.append(('policy_engine_mode', policy_engine_mode.value)) + + if request_message_access is not None: + + _query_params.append(('request_message_access', request_message_access)) + + if search is not None: + + _query_params.append(('search', search)) + + if slug is not None: + + _query_params.append(('slug', slug)) + + if user_matching_mode is not None: + + _query_params.append(('user_matching_mode', user_matching_mode.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/telegram/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_telegram_partial_update( + self, + slug: StrictStr, + patched_telegram_source_request: Optional[PatchedTelegramSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TelegramSource: + """sources_telegram_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param patched_telegram_source_request: + :type patched_telegram_source_request: PatchedTelegramSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_partial_update_serialize( + slug=slug, + patched_telegram_source_request=patched_telegram_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_telegram_partial_update_with_http_info( + self, + slug: StrictStr, + patched_telegram_source_request: Optional[PatchedTelegramSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TelegramSource]: + """sources_telegram_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param patched_telegram_source_request: + :type patched_telegram_source_request: PatchedTelegramSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_partial_update_serialize( + slug=slug, + patched_telegram_source_request=patched_telegram_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_telegram_partial_update_without_preload_content( + self, + slug: StrictStr, + patched_telegram_source_request: Optional[PatchedTelegramSourceRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_telegram_partial_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param patched_telegram_source_request: + :type patched_telegram_source_request: PatchedTelegramSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_partial_update_serialize( + slug=slug, + patched_telegram_source_request=patched_telegram_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_telegram_partial_update_serialize( + self, + slug, + patched_telegram_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_telegram_source_request is not None: + _body_params = patched_telegram_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/telegram/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_telegram_retrieve( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TelegramSource: + """sources_telegram_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_telegram_retrieve_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TelegramSource]: + """sources_telegram_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_telegram_retrieve_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_telegram_retrieve + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_retrieve_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_telegram_retrieve_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/telegram/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_telegram_update( + self, + slug: StrictStr, + telegram_source_request: TelegramSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TelegramSource: + """sources_telegram_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param telegram_source_request: (required) + :type telegram_source_request: TelegramSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_update_serialize( + slug=slug, + telegram_source_request=telegram_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_telegram_update_with_http_info( + self, + slug: StrictStr, + telegram_source_request: TelegramSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TelegramSource]: + """sources_telegram_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param telegram_source_request: (required) + :type telegram_source_request: TelegramSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_update_serialize( + slug=slug, + telegram_source_request=telegram_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_telegram_update_without_preload_content( + self, + slug: StrictStr, + telegram_source_request: TelegramSourceRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_telegram_update + + Mixin to add a used_by endpoint to return a list of all objects using this object + + :param slug: (required) + :type slug: str + :param telegram_source_request: (required) + :type telegram_source_request: TelegramSourceRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_update_serialize( + slug=slug, + telegram_source_request=telegram_source_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TelegramSource", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_telegram_update_serialize( + self, + slug, + telegram_source_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if telegram_source_request is not None: + _body_params = telegram_source_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/telegram/{slug}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_telegram_used_by_list( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_telegram_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_telegram_used_by_list_with_http_info( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_telegram_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_telegram_used_by_list_without_preload_content( + self, + slug: StrictStr, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_telegram_used_by_list + + Get a list of all objects that use this object + + :param slug: (required) + :type slug: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_telegram_used_by_list_serialize( + slug=slug, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_telegram_used_by_list_serialize( + self, + slug, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if slug is not None: + _path_params['slug'] = slug + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/telegram/{slug}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_all_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_user_connections_all_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_all_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_user_connections_all_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_all_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_all_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_all_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/user_connections/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_all_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserSourceConnectionList: + """sources_user_connections_all_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_all_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserSourceConnectionList]: + """sources_user_connections_all_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_all_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_all_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_all_list_serialize( + self, + ordering, + page, + page_size, + search, + source__slug, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_all_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + patched_user_source_connection_request: Optional[PatchedUserSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserSourceConnection: + """sources_user_connections_all_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param patched_user_source_connection_request: + :type patched_user_source_connection_request: PatchedUserSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_partial_update_serialize( + id=id, + patched_user_source_connection_request=patched_user_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_all_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + patched_user_source_connection_request: Optional[PatchedUserSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserSourceConnection]: + """sources_user_connections_all_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param patched_user_source_connection_request: + :type patched_user_source_connection_request: PatchedUserSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_partial_update_serialize( + id=id, + patched_user_source_connection_request=patched_user_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_all_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + patched_user_source_connection_request: Optional[PatchedUserSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_all_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param patched_user_source_connection_request: + :type patched_user_source_connection_request: PatchedUserSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_partial_update_serialize( + id=id, + patched_user_source_connection_request=patched_user_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_all_partial_update_serialize( + self, + id, + patched_user_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_source_connection_request is not None: + _body_params = patched_user_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/user_connections/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_all_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserSourceConnection: + """sources_user_connections_all_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_all_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserSourceConnection]: + """sources_user_connections_all_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_all_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_all_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_all_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_all_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + user_source_connection_request: UserSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserSourceConnection: + """sources_user_connections_all_update + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param user_source_connection_request: (required) + :type user_source_connection_request: UserSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_update_serialize( + id=id, + user_source_connection_request=user_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_all_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + user_source_connection_request: UserSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserSourceConnection]: + """sources_user_connections_all_update + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param user_source_connection_request: (required) + :type user_source_connection_request: UserSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_update_serialize( + id=id, + user_source_connection_request=user_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_all_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + user_source_connection_request: UserSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_all_update + + User-source connection Viewset + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param user_source_connection_request: (required) + :type user_source_connection_request: UserSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_update_serialize( + id=id, + user_source_connection_request=user_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_all_update_serialize( + self, + id, + user_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_source_connection_request is not None: + _body_params = user_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/user_connections/all/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_all_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_user_connections_all_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_all_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_user_connections_all_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_all_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this user source connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_all_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this user source connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_all_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_all_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/all/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_kerberos_create( + self, + user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserKerberosSourceConnection: + """sources_user_connections_kerberos_create + + User-source connection Viewset + + :param user_kerberos_source_connection_request: (required) + :type user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_create_serialize( + user_kerberos_source_connection_request=user_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_kerberos_create_with_http_info( + self, + user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserKerberosSourceConnection]: + """sources_user_connections_kerberos_create + + User-source connection Viewset + + :param user_kerberos_source_connection_request: (required) + :type user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_create_serialize( + user_kerberos_source_connection_request=user_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_kerberos_create_without_preload_content( + self, + user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_kerberos_create + + User-source connection Viewset + + :param user_kerberos_source_connection_request: (required) + :type user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_create_serialize( + user_kerberos_source_connection_request=user_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_kerberos_create_serialize( + self, + user_kerberos_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_kerberos_source_connection_request is not None: + _body_params = user_kerberos_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/user_connections/kerberos/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_kerberos_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_user_connections_kerberos_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_kerberos_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_user_connections_kerberos_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_kerberos_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_kerberos_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_kerberos_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/user_connections/kerberos/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_kerberos_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserKerberosSourceConnectionList: + """sources_user_connections_kerberos_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserKerberosSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_kerberos_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserKerberosSourceConnectionList]: + """sources_user_connections_kerberos_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserKerberosSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_kerberos_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_kerberos_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserKerberosSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_kerberos_list_serialize( + self, + ordering, + page, + page_size, + search, + source__slug, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/kerberos/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_kerberos_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + patched_user_kerberos_source_connection_request: Optional[PatchedUserKerberosSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserKerberosSourceConnection: + """sources_user_connections_kerberos_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param patched_user_kerberos_source_connection_request: + :type patched_user_kerberos_source_connection_request: PatchedUserKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_partial_update_serialize( + id=id, + patched_user_kerberos_source_connection_request=patched_user_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_kerberos_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + patched_user_kerberos_source_connection_request: Optional[PatchedUserKerberosSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserKerberosSourceConnection]: + """sources_user_connections_kerberos_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param patched_user_kerberos_source_connection_request: + :type patched_user_kerberos_source_connection_request: PatchedUserKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_partial_update_serialize( + id=id, + patched_user_kerberos_source_connection_request=patched_user_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_kerberos_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + patched_user_kerberos_source_connection_request: Optional[PatchedUserKerberosSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_kerberos_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param patched_user_kerberos_source_connection_request: + :type patched_user_kerberos_source_connection_request: PatchedUserKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_partial_update_serialize( + id=id, + patched_user_kerberos_source_connection_request=patched_user_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_kerberos_partial_update_serialize( + self, + id, + patched_user_kerberos_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_kerberos_source_connection_request is not None: + _body_params = patched_user_kerberos_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/user_connections/kerberos/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_kerberos_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserKerberosSourceConnection: + """sources_user_connections_kerberos_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_kerberos_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserKerberosSourceConnection]: + """sources_user_connections_kerberos_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_kerberos_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_kerberos_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_kerberos_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/kerberos/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_kerberos_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserKerberosSourceConnection: + """sources_user_connections_kerberos_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param user_kerberos_source_connection_request: (required) + :type user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_update_serialize( + id=id, + user_kerberos_source_connection_request=user_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_kerberos_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserKerberosSourceConnection]: + """sources_user_connections_kerberos_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param user_kerberos_source_connection_request: (required) + :type user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_update_serialize( + id=id, + user_kerberos_source_connection_request=user_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_kerberos_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_kerberos_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param user_kerberos_source_connection_request: (required) + :type user_kerberos_source_connection_request: UserKerberosSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_update_serialize( + id=id, + user_kerberos_source_connection_request=user_kerberos_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserKerberosSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_kerberos_update_serialize( + self, + id, + user_kerberos_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_kerberos_source_connection_request is not None: + _body_params = user_kerberos_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/user_connections/kerberos/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_kerberos_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_user_connections_kerberos_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_kerberos_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_user_connections_kerberos_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_kerberos_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Kerberos Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_kerberos_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Kerberos Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_kerberos_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_kerberos_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/kerberos/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_ldap_create( + self, + user_ldap_source_connection_request: UserLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLDAPSourceConnection: + """sources_user_connections_ldap_create + + User-source connection Viewset + + :param user_ldap_source_connection_request: (required) + :type user_ldap_source_connection_request: UserLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_create_serialize( + user_ldap_source_connection_request=user_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_ldap_create_with_http_info( + self, + user_ldap_source_connection_request: UserLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLDAPSourceConnection]: + """sources_user_connections_ldap_create + + User-source connection Viewset + + :param user_ldap_source_connection_request: (required) + :type user_ldap_source_connection_request: UserLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_create_serialize( + user_ldap_source_connection_request=user_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_ldap_create_without_preload_content( + self, + user_ldap_source_connection_request: UserLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_ldap_create + + User-source connection Viewset + + :param user_ldap_source_connection_request: (required) + :type user_ldap_source_connection_request: UserLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_create_serialize( + user_ldap_source_connection_request=user_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_ldap_create_serialize( + self, + user_ldap_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_ldap_source_connection_request is not None: + _body_params = user_ldap_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/user_connections/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_ldap_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_user_connections_ldap_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_ldap_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_user_connections_ldap_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_ldap_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_ldap_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_ldap_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/user_connections/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_ldap_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserLDAPSourceConnectionList: + """sources_user_connections_ldap_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserLDAPSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_ldap_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserLDAPSourceConnectionList]: + """sources_user_connections_ldap_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserLDAPSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_ldap_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_ldap_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserLDAPSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_ldap_list_serialize( + self, + ordering, + page, + page_size, + search, + source__slug, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/ldap/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_ldap_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + patched_user_ldap_source_connection_request: Optional[PatchedUserLDAPSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLDAPSourceConnection: + """sources_user_connections_ldap_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param patched_user_ldap_source_connection_request: + :type patched_user_ldap_source_connection_request: PatchedUserLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_partial_update_serialize( + id=id, + patched_user_ldap_source_connection_request=patched_user_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_ldap_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + patched_user_ldap_source_connection_request: Optional[PatchedUserLDAPSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLDAPSourceConnection]: + """sources_user_connections_ldap_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param patched_user_ldap_source_connection_request: + :type patched_user_ldap_source_connection_request: PatchedUserLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_partial_update_serialize( + id=id, + patched_user_ldap_source_connection_request=patched_user_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_ldap_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + patched_user_ldap_source_connection_request: Optional[PatchedUserLDAPSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_ldap_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param patched_user_ldap_source_connection_request: + :type patched_user_ldap_source_connection_request: PatchedUserLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_partial_update_serialize( + id=id, + patched_user_ldap_source_connection_request=patched_user_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_ldap_partial_update_serialize( + self, + id, + patched_user_ldap_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_ldap_source_connection_request is not None: + _body_params = patched_user_ldap_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/user_connections/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_ldap_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLDAPSourceConnection: + """sources_user_connections_ldap_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_ldap_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLDAPSourceConnection]: + """sources_user_connections_ldap_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_ldap_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_ldap_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_ldap_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_ldap_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + user_ldap_source_connection_request: UserLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLDAPSourceConnection: + """sources_user_connections_ldap_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param user_ldap_source_connection_request: (required) + :type user_ldap_source_connection_request: UserLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_update_serialize( + id=id, + user_ldap_source_connection_request=user_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_ldap_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + user_ldap_source_connection_request: UserLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLDAPSourceConnection]: + """sources_user_connections_ldap_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param user_ldap_source_connection_request: (required) + :type user_ldap_source_connection_request: UserLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_update_serialize( + id=id, + user_ldap_source_connection_request=user_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_ldap_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + user_ldap_source_connection_request: UserLDAPSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_ldap_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param user_ldap_source_connection_request: (required) + :type user_ldap_source_connection_request: UserLDAPSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_update_serialize( + id=id, + user_ldap_source_connection_request=user_ldap_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLDAPSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_ldap_update_serialize( + self, + id, + user_ldap_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_ldap_source_connection_request is not None: + _body_params = user_ldap_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/user_connections/ldap/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_ldap_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_user_connections_ldap_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_ldap_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_user_connections_ldap_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_ldap_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User LDAP Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_ldap_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User LDAP Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_ldap_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_ldap_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/ldap/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_oauth_create( + self, + user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserOAuthSourceConnection: + """sources_user_connections_oauth_create + + User-source connection Viewset + + :param user_o_auth_source_connection_request: (required) + :type user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_create_serialize( + user_o_auth_source_connection_request=user_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_oauth_create_with_http_info( + self, + user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserOAuthSourceConnection]: + """sources_user_connections_oauth_create + + User-source connection Viewset + + :param user_o_auth_source_connection_request: (required) + :type user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_create_serialize( + user_o_auth_source_connection_request=user_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_oauth_create_without_preload_content( + self, + user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_oauth_create + + User-source connection Viewset + + :param user_o_auth_source_connection_request: (required) + :type user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_create_serialize( + user_o_auth_source_connection_request=user_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_oauth_create_serialize( + self, + user_o_auth_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_o_auth_source_connection_request is not None: + _body_params = user_o_auth_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/user_connections/oauth/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_oauth_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_user_connections_oauth_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_oauth_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_user_connections_oauth_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_oauth_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_oauth_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_oauth_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/user_connections/oauth/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_oauth_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserOAuthSourceConnectionList: + """sources_user_connections_oauth_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserOAuthSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_oauth_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserOAuthSourceConnectionList]: + """sources_user_connections_oauth_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserOAuthSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_oauth_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_oauth_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserOAuthSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_oauth_list_serialize( + self, + ordering, + page, + page_size, + search, + source__slug, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/oauth/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_oauth_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + patched_user_o_auth_source_connection_request: Optional[PatchedUserOAuthSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserOAuthSourceConnection: + """sources_user_connections_oauth_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param patched_user_o_auth_source_connection_request: + :type patched_user_o_auth_source_connection_request: PatchedUserOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_partial_update_serialize( + id=id, + patched_user_o_auth_source_connection_request=patched_user_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_oauth_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + patched_user_o_auth_source_connection_request: Optional[PatchedUserOAuthSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserOAuthSourceConnection]: + """sources_user_connections_oauth_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param patched_user_o_auth_source_connection_request: + :type patched_user_o_auth_source_connection_request: PatchedUserOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_partial_update_serialize( + id=id, + patched_user_o_auth_source_connection_request=patched_user_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_oauth_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + patched_user_o_auth_source_connection_request: Optional[PatchedUserOAuthSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_oauth_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param patched_user_o_auth_source_connection_request: + :type patched_user_o_auth_source_connection_request: PatchedUserOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_partial_update_serialize( + id=id, + patched_user_o_auth_source_connection_request=patched_user_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_oauth_partial_update_serialize( + self, + id, + patched_user_o_auth_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_o_auth_source_connection_request is not None: + _body_params = patched_user_o_auth_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/user_connections/oauth/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_oauth_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserOAuthSourceConnection: + """sources_user_connections_oauth_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_oauth_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserOAuthSourceConnection]: + """sources_user_connections_oauth_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_oauth_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_oauth_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_oauth_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/oauth/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_oauth_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserOAuthSourceConnection: + """sources_user_connections_oauth_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param user_o_auth_source_connection_request: (required) + :type user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_update_serialize( + id=id, + user_o_auth_source_connection_request=user_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_oauth_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserOAuthSourceConnection]: + """sources_user_connections_oauth_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param user_o_auth_source_connection_request: (required) + :type user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_update_serialize( + id=id, + user_o_auth_source_connection_request=user_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_oauth_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_oauth_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param user_o_auth_source_connection_request: (required) + :type user_o_auth_source_connection_request: UserOAuthSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_update_serialize( + id=id, + user_o_auth_source_connection_request=user_o_auth_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserOAuthSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_oauth_update_serialize( + self, + id, + user_o_auth_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_o_auth_source_connection_request is not None: + _body_params = user_o_auth_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/user_connections/oauth/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_oauth_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_user_connections_oauth_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_oauth_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_user_connections_oauth_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_oauth_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User OAuth Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_oauth_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User OAuth Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_oauth_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_oauth_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/oauth/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_plex_create( + self, + user_plex_source_connection_request: UserPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserPlexSourceConnection: + """sources_user_connections_plex_create + + User-source connection Viewset + + :param user_plex_source_connection_request: (required) + :type user_plex_source_connection_request: UserPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_create_serialize( + user_plex_source_connection_request=user_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_plex_create_with_http_info( + self, + user_plex_source_connection_request: UserPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserPlexSourceConnection]: + """sources_user_connections_plex_create + + User-source connection Viewset + + :param user_plex_source_connection_request: (required) + :type user_plex_source_connection_request: UserPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_create_serialize( + user_plex_source_connection_request=user_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_plex_create_without_preload_content( + self, + user_plex_source_connection_request: UserPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_plex_create + + User-source connection Viewset + + :param user_plex_source_connection_request: (required) + :type user_plex_source_connection_request: UserPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_create_serialize( + user_plex_source_connection_request=user_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_plex_create_serialize( + self, + user_plex_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_plex_source_connection_request is not None: + _body_params = user_plex_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/user_connections/plex/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_plex_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_user_connections_plex_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_plex_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_user_connections_plex_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_plex_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_plex_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_plex_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/user_connections/plex/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_plex_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserPlexSourceConnectionList: + """sources_user_connections_plex_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserPlexSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_plex_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserPlexSourceConnectionList]: + """sources_user_connections_plex_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserPlexSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_plex_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_plex_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserPlexSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_plex_list_serialize( + self, + ordering, + page, + page_size, + search, + source__slug, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/plex/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_plex_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + patched_user_plex_source_connection_request: Optional[PatchedUserPlexSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserPlexSourceConnection: + """sources_user_connections_plex_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param patched_user_plex_source_connection_request: + :type patched_user_plex_source_connection_request: PatchedUserPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_partial_update_serialize( + id=id, + patched_user_plex_source_connection_request=patched_user_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_plex_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + patched_user_plex_source_connection_request: Optional[PatchedUserPlexSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserPlexSourceConnection]: + """sources_user_connections_plex_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param patched_user_plex_source_connection_request: + :type patched_user_plex_source_connection_request: PatchedUserPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_partial_update_serialize( + id=id, + patched_user_plex_source_connection_request=patched_user_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_plex_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + patched_user_plex_source_connection_request: Optional[PatchedUserPlexSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_plex_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param patched_user_plex_source_connection_request: + :type patched_user_plex_source_connection_request: PatchedUserPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_partial_update_serialize( + id=id, + patched_user_plex_source_connection_request=patched_user_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_plex_partial_update_serialize( + self, + id, + patched_user_plex_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_plex_source_connection_request is not None: + _body_params = patched_user_plex_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/user_connections/plex/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_plex_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserPlexSourceConnection: + """sources_user_connections_plex_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_plex_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserPlexSourceConnection]: + """sources_user_connections_plex_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_plex_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_plex_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_plex_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/plex/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_plex_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + user_plex_source_connection_request: UserPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserPlexSourceConnection: + """sources_user_connections_plex_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param user_plex_source_connection_request: (required) + :type user_plex_source_connection_request: UserPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_update_serialize( + id=id, + user_plex_source_connection_request=user_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_plex_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + user_plex_source_connection_request: UserPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserPlexSourceConnection]: + """sources_user_connections_plex_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param user_plex_source_connection_request: (required) + :type user_plex_source_connection_request: UserPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_update_serialize( + id=id, + user_plex_source_connection_request=user_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_plex_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + user_plex_source_connection_request: UserPlexSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_plex_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param user_plex_source_connection_request: (required) + :type user_plex_source_connection_request: UserPlexSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_update_serialize( + id=id, + user_plex_source_connection_request=user_plex_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserPlexSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_plex_update_serialize( + self, + id, + user_plex_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_plex_source_connection_request is not None: + _body_params = user_plex_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/user_connections/plex/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_plex_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_user_connections_plex_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_plex_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_user_connections_plex_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_plex_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Plex Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_plex_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Plex Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_plex_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_plex_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/plex/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_saml_create( + self, + user_saml_source_connection_request: UserSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserSAMLSourceConnection: + """sources_user_connections_saml_create + + User-source connection Viewset + + :param user_saml_source_connection_request: (required) + :type user_saml_source_connection_request: UserSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_create_serialize( + user_saml_source_connection_request=user_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_saml_create_with_http_info( + self, + user_saml_source_connection_request: UserSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserSAMLSourceConnection]: + """sources_user_connections_saml_create + + User-source connection Viewset + + :param user_saml_source_connection_request: (required) + :type user_saml_source_connection_request: UserSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_create_serialize( + user_saml_source_connection_request=user_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_saml_create_without_preload_content( + self, + user_saml_source_connection_request: UserSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_saml_create + + User-source connection Viewset + + :param user_saml_source_connection_request: (required) + :type user_saml_source_connection_request: UserSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_create_serialize( + user_saml_source_connection_request=user_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_saml_create_serialize( + self, + user_saml_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_saml_source_connection_request is not None: + _body_params = user_saml_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/user_connections/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_saml_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_user_connections_saml_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_saml_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_user_connections_saml_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_saml_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_saml_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_saml_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/user_connections/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_saml_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserSAMLSourceConnectionList: + """sources_user_connections_saml_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserSAMLSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_saml_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserSAMLSourceConnectionList]: + """sources_user_connections_saml_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserSAMLSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_saml_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_saml_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserSAMLSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_saml_list_serialize( + self, + ordering, + page, + page_size, + search, + source__slug, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/saml/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_saml_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + patched_user_saml_source_connection_request: Optional[PatchedUserSAMLSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserSAMLSourceConnection: + """sources_user_connections_saml_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param patched_user_saml_source_connection_request: + :type patched_user_saml_source_connection_request: PatchedUserSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_partial_update_serialize( + id=id, + patched_user_saml_source_connection_request=patched_user_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_saml_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + patched_user_saml_source_connection_request: Optional[PatchedUserSAMLSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserSAMLSourceConnection]: + """sources_user_connections_saml_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param patched_user_saml_source_connection_request: + :type patched_user_saml_source_connection_request: PatchedUserSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_partial_update_serialize( + id=id, + patched_user_saml_source_connection_request=patched_user_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_saml_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + patched_user_saml_source_connection_request: Optional[PatchedUserSAMLSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_saml_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param patched_user_saml_source_connection_request: + :type patched_user_saml_source_connection_request: PatchedUserSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_partial_update_serialize( + id=id, + patched_user_saml_source_connection_request=patched_user_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_saml_partial_update_serialize( + self, + id, + patched_user_saml_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_saml_source_connection_request is not None: + _body_params = patched_user_saml_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/user_connections/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_saml_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserSAMLSourceConnection: + """sources_user_connections_saml_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_saml_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserSAMLSourceConnection]: + """sources_user_connections_saml_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_saml_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_saml_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_saml_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_saml_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + user_saml_source_connection_request: UserSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserSAMLSourceConnection: + """sources_user_connections_saml_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param user_saml_source_connection_request: (required) + :type user_saml_source_connection_request: UserSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_update_serialize( + id=id, + user_saml_source_connection_request=user_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_saml_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + user_saml_source_connection_request: UserSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserSAMLSourceConnection]: + """sources_user_connections_saml_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param user_saml_source_connection_request: (required) + :type user_saml_source_connection_request: UserSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_update_serialize( + id=id, + user_saml_source_connection_request=user_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_saml_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + user_saml_source_connection_request: UserSAMLSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_saml_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param user_saml_source_connection_request: (required) + :type user_saml_source_connection_request: UserSAMLSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_update_serialize( + id=id, + user_saml_source_connection_request=user_saml_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserSAMLSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_saml_update_serialize( + self, + id, + user_saml_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_saml_source_connection_request is not None: + _body_params = user_saml_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/user_connections/saml/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_saml_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_user_connections_saml_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_saml_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_user_connections_saml_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_saml_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User SAML Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_saml_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User SAML Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_saml_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_saml_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/saml/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_telegram_create( + self, + user_telegram_source_connection_request: UserTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserTelegramSourceConnection: + """sources_user_connections_telegram_create + + User-source connection Viewset + + :param user_telegram_source_connection_request: (required) + :type user_telegram_source_connection_request: UserTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_create_serialize( + user_telegram_source_connection_request=user_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_telegram_create_with_http_info( + self, + user_telegram_source_connection_request: UserTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserTelegramSourceConnection]: + """sources_user_connections_telegram_create + + User-source connection Viewset + + :param user_telegram_source_connection_request: (required) + :type user_telegram_source_connection_request: UserTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_create_serialize( + user_telegram_source_connection_request=user_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_telegram_create_without_preload_content( + self, + user_telegram_source_connection_request: UserTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_telegram_create + + User-source connection Viewset + + :param user_telegram_source_connection_request: (required) + :type user_telegram_source_connection_request: UserTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_create_serialize( + user_telegram_source_connection_request=user_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_telegram_create_serialize( + self, + user_telegram_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_telegram_source_connection_request is not None: + _body_params = user_telegram_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/sources/user_connections/telegram/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_telegram_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """sources_user_connections_telegram_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_telegram_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """sources_user_connections_telegram_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_telegram_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_telegram_destroy + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_telegram_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/sources/user_connections/telegram/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_telegram_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserTelegramSourceConnectionList: + """sources_user_connections_telegram_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserTelegramSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_telegram_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserTelegramSourceConnectionList]: + """sources_user_connections_telegram_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserTelegramSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_telegram_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source__slug: Optional[StrictStr] = None, + user: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_telegram_list + + User-source connection Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param source__slug: + :type source__slug: str + :param user: + :type user: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + source__slug=source__slug, + user=user, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserTelegramSourceConnectionList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_telegram_list_serialize( + self, + ordering, + page, + page_size, + search, + source__slug, + user, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if source__slug is not None: + + _query_params.append(('source__slug', source__slug)) + + if user is not None: + + _query_params.append(('user', user)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/telegram/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_telegram_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + patched_user_telegram_source_connection_request: Optional[PatchedUserTelegramSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserTelegramSourceConnection: + """sources_user_connections_telegram_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param patched_user_telegram_source_connection_request: + :type patched_user_telegram_source_connection_request: PatchedUserTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_partial_update_serialize( + id=id, + patched_user_telegram_source_connection_request=patched_user_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_telegram_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + patched_user_telegram_source_connection_request: Optional[PatchedUserTelegramSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserTelegramSourceConnection]: + """sources_user_connections_telegram_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param patched_user_telegram_source_connection_request: + :type patched_user_telegram_source_connection_request: PatchedUserTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_partial_update_serialize( + id=id, + patched_user_telegram_source_connection_request=patched_user_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_telegram_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + patched_user_telegram_source_connection_request: Optional[PatchedUserTelegramSourceConnectionRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_telegram_partial_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param patched_user_telegram_source_connection_request: + :type patched_user_telegram_source_connection_request: PatchedUserTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_partial_update_serialize( + id=id, + patched_user_telegram_source_connection_request=patched_user_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_telegram_partial_update_serialize( + self, + id, + patched_user_telegram_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_telegram_source_connection_request is not None: + _body_params = patched_user_telegram_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/sources/user_connections/telegram/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_telegram_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserTelegramSourceConnection: + """sources_user_connections_telegram_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_telegram_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserTelegramSourceConnection]: + """sources_user_connections_telegram_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_telegram_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_telegram_retrieve + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_telegram_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/telegram/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_telegram_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + user_telegram_source_connection_request: UserTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserTelegramSourceConnection: + """sources_user_connections_telegram_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param user_telegram_source_connection_request: (required) + :type user_telegram_source_connection_request: UserTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_update_serialize( + id=id, + user_telegram_source_connection_request=user_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_telegram_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + user_telegram_source_connection_request: UserTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserTelegramSourceConnection]: + """sources_user_connections_telegram_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param user_telegram_source_connection_request: (required) + :type user_telegram_source_connection_request: UserTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_update_serialize( + id=id, + user_telegram_source_connection_request=user_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_telegram_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + user_telegram_source_connection_request: UserTelegramSourceConnectionRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_telegram_update + + User-source connection Viewset + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param user_telegram_source_connection_request: (required) + :type user_telegram_source_connection_request: UserTelegramSourceConnectionRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_update_serialize( + id=id, + user_telegram_source_connection_request=user_telegram_source_connection_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserTelegramSourceConnection", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_telegram_update_serialize( + self, + id, + user_telegram_source_connection_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_telegram_source_connection_request is not None: + _body_params = user_telegram_source_connection_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/sources/user_connections/telegram/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def sources_user_connections_telegram_used_by_list( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """sources_user_connections_telegram_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def sources_user_connections_telegram_used_by_list_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """sources_user_connections_telegram_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def sources_user_connections_telegram_used_by_list_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this User Telegram Source Connection.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """sources_user_connections_telegram_used_by_list + + Get a list of all objects that use this object + + :param id: A unique integer value identifying this User Telegram Source Connection. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._sources_user_connections_telegram_used_by_list_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _sources_user_connections_telegram_used_by_list_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/sources/user_connections/telegram/{id}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/ssf_api.py b/authentik_client/api/ssf_api.py new file mode 100644 index 000000000..08e90e76d --- /dev/null +++ b/authentik_client/api/ssf_api.py @@ -0,0 +1,947 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictInt, StrictStr +from typing import Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.delivery_method_enum import DeliveryMethodEnum +from authentik_client.models.paginated_ssf_stream_list import PaginatedSSFStreamList +from authentik_client.models.ssf_stream import SSFStream + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class SsfApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def ssf_streams_destroy( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this SSF Stream.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """ssf_streams_destroy + + SSFStream Viewset + + :param uuid: A UUID string identifying this SSF Stream. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._ssf_streams_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def ssf_streams_destroy_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this SSF Stream.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """ssf_streams_destroy + + SSFStream Viewset + + :param uuid: A UUID string identifying this SSF Stream. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._ssf_streams_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def ssf_streams_destroy_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this SSF Stream.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """ssf_streams_destroy + + SSFStream Viewset + + :param uuid: A UUID string identifying this SSF Stream. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._ssf_streams_destroy_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _ssf_streams_destroy_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/ssf/streams/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def ssf_streams_list( + self, + delivery_method: Optional[DeliveryMethodEnum] = None, + endpoint_url: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSSFStreamList: + """ssf_streams_list + + SSFStream Viewset + + :param delivery_method: + :type delivery_method: DeliveryMethodEnum + :param endpoint_url: + :type endpoint_url: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._ssf_streams_list_serialize( + delivery_method=delivery_method, + endpoint_url=endpoint_url, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSSFStreamList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def ssf_streams_list_with_http_info( + self, + delivery_method: Optional[DeliveryMethodEnum] = None, + endpoint_url: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSSFStreamList]: + """ssf_streams_list + + SSFStream Viewset + + :param delivery_method: + :type delivery_method: DeliveryMethodEnum + :param endpoint_url: + :type endpoint_url: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._ssf_streams_list_serialize( + delivery_method=delivery_method, + endpoint_url=endpoint_url, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSSFStreamList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def ssf_streams_list_without_preload_content( + self, + delivery_method: Optional[DeliveryMethodEnum] = None, + endpoint_url: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """ssf_streams_list + + SSFStream Viewset + + :param delivery_method: + :type delivery_method: DeliveryMethodEnum + :param endpoint_url: + :type endpoint_url: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._ssf_streams_list_serialize( + delivery_method=delivery_method, + endpoint_url=endpoint_url, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSSFStreamList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _ssf_streams_list_serialize( + self, + delivery_method, + endpoint_url, + ordering, + page, + page_size, + provider, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if delivery_method is not None: + + _query_params.append(('delivery_method', delivery_method.value)) + + if endpoint_url is not None: + + _query_params.append(('endpoint_url', endpoint_url)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider is not None: + + _query_params.append(('provider', provider)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/ssf/streams/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def ssf_streams_retrieve( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this SSF Stream.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SSFStream: + """ssf_streams_retrieve + + SSFStream Viewset + + :param uuid: A UUID string identifying this SSF Stream. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._ssf_streams_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFStream", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def ssf_streams_retrieve_with_http_info( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this SSF Stream.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SSFStream]: + """ssf_streams_retrieve + + SSFStream Viewset + + :param uuid: A UUID string identifying this SSF Stream. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._ssf_streams_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFStream", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def ssf_streams_retrieve_without_preload_content( + self, + uuid: Annotated[UUID, Field(description="A UUID string identifying this SSF Stream.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """ssf_streams_retrieve + + SSFStream Viewset + + :param uuid: A UUID string identifying this SSF Stream. (required) + :type uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._ssf_streams_retrieve_serialize( + uuid=uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SSFStream", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _ssf_streams_retrieve_serialize( + self, + uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if uuid is not None: + _path_params['uuid'] = uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/ssf/streams/{uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/stages_api.py b/authentik_client/api/stages_api.py new file mode 100644 index 000000000..8b98845d7 --- /dev/null +++ b/authentik_client/api/stages_api.py @@ -0,0 +1,62406 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from datetime import datetime +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import Any, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.account_lockdown_stage import AccountLockdownStage +from authentik_client.models.account_lockdown_stage_request import AccountLockdownStageRequest +from authentik_client.models.auth_type_enum import AuthTypeEnum +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage +from authentik_client.models.authenticator_duo_stage_device_import_response import AuthenticatorDuoStageDeviceImportResponse +from authentik_client.models.authenticator_duo_stage_manual_device_import_request import AuthenticatorDuoStageManualDeviceImportRequest +from authentik_client.models.authenticator_duo_stage_request import AuthenticatorDuoStageRequest +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage +from authentik_client.models.authenticator_email_stage_request import AuthenticatorEmailStageRequest +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage +from authentik_client.models.authenticator_endpoint_gdtc_stage_request import AuthenticatorEndpointGDTCStageRequest +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage +from authentik_client.models.authenticator_sms_stage_request import AuthenticatorSMSStageRequest +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage +from authentik_client.models.authenticator_static_stage_request import AuthenticatorStaticStageRequest +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage +from authentik_client.models.authenticator_totp_stage_request import AuthenticatorTOTPStageRequest +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage +from authentik_client.models.authenticator_validate_stage_request import AuthenticatorValidateStageRequest +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage +from authentik_client.models.authenticator_web_authn_stage_request import AuthenticatorWebAuthnStageRequest +from authentik_client.models.captcha_stage import CaptchaStage +from authentik_client.models.captcha_stage_request import CaptchaStageRequest +from authentik_client.models.cert_attribute_enum import CertAttributeEnum +from authentik_client.models.consent_mode_enum import ConsentModeEnum +from authentik_client.models.consent_stage import ConsentStage +from authentik_client.models.consent_stage_request import ConsentStageRequest +from authentik_client.models.deny_stage import DenyStage +from authentik_client.models.deny_stage_request import DenyStageRequest +from authentik_client.models.digits_enum import DigitsEnum +from authentik_client.models.dummy_stage import DummyStage +from authentik_client.models.dummy_stage_request import DummyStageRequest +from authentik_client.models.duo_device_enrollment_status import DuoDeviceEnrollmentStatus +from authentik_client.models.email_stage import EmailStage +from authentik_client.models.email_stage_request import EmailStageRequest +from authentik_client.models.endpoint_stage import EndpointStage +from authentik_client.models.endpoint_stage_request import EndpointStageRequest +from authentik_client.models.identification_stage import IdentificationStage +from authentik_client.models.identification_stage_request import IdentificationStageRequest +from authentik_client.models.invitation import Invitation +from authentik_client.models.invitation_request import InvitationRequest +from authentik_client.models.invitation_send_email_request import InvitationSendEmailRequest +from authentik_client.models.invitation_stage import InvitationStage +from authentik_client.models.invitation_stage_request import InvitationStageRequest +from authentik_client.models.mutual_tls_stage import MutualTLSStage +from authentik_client.models.mutual_tls_stage_request import MutualTLSStageRequest +from authentik_client.models.not_configured_action_enum import NotConfiguredActionEnum +from authentik_client.models.paginated_account_lockdown_stage_list import PaginatedAccountLockdownStageList +from authentik_client.models.paginated_authenticator_duo_stage_list import PaginatedAuthenticatorDuoStageList +from authentik_client.models.paginated_authenticator_email_stage_list import PaginatedAuthenticatorEmailStageList +from authentik_client.models.paginated_authenticator_endpoint_gdtc_stage_list import PaginatedAuthenticatorEndpointGDTCStageList +from authentik_client.models.paginated_authenticator_sms_stage_list import PaginatedAuthenticatorSMSStageList +from authentik_client.models.paginated_authenticator_static_stage_list import PaginatedAuthenticatorStaticStageList +from authentik_client.models.paginated_authenticator_totp_stage_list import PaginatedAuthenticatorTOTPStageList +from authentik_client.models.paginated_authenticator_validate_stage_list import PaginatedAuthenticatorValidateStageList +from authentik_client.models.paginated_authenticator_web_authn_stage_list import PaginatedAuthenticatorWebAuthnStageList +from authentik_client.models.paginated_captcha_stage_list import PaginatedCaptchaStageList +from authentik_client.models.paginated_consent_stage_list import PaginatedConsentStageList +from authentik_client.models.paginated_deny_stage_list import PaginatedDenyStageList +from authentik_client.models.paginated_dummy_stage_list import PaginatedDummyStageList +from authentik_client.models.paginated_email_stage_list import PaginatedEmailStageList +from authentik_client.models.paginated_endpoint_stage_list import PaginatedEndpointStageList +from authentik_client.models.paginated_identification_stage_list import PaginatedIdentificationStageList +from authentik_client.models.paginated_invitation_list import PaginatedInvitationList +from authentik_client.models.paginated_invitation_stage_list import PaginatedInvitationStageList +from authentik_client.models.paginated_mutual_tls_stage_list import PaginatedMutualTLSStageList +from authentik_client.models.paginated_password_stage_list import PaginatedPasswordStageList +from authentik_client.models.paginated_prompt_list import PaginatedPromptList +from authentik_client.models.paginated_prompt_stage_list import PaginatedPromptStageList +from authentik_client.models.paginated_redirect_stage_list import PaginatedRedirectStageList +from authentik_client.models.paginated_source_stage_list import PaginatedSourceStageList +from authentik_client.models.paginated_stage_list import PaginatedStageList +from authentik_client.models.paginated_user_delete_stage_list import PaginatedUserDeleteStageList +from authentik_client.models.paginated_user_login_stage_list import PaginatedUserLoginStageList +from authentik_client.models.paginated_user_logout_stage_list import PaginatedUserLogoutStageList +from authentik_client.models.paginated_user_write_stage_list import PaginatedUserWriteStageList +from authentik_client.models.paginated_web_authn_device_type_list import PaginatedWebAuthnDeviceTypeList +from authentik_client.models.password_stage import PasswordStage +from authentik_client.models.password_stage_request import PasswordStageRequest +from authentik_client.models.patched_account_lockdown_stage_request import PatchedAccountLockdownStageRequest +from authentik_client.models.patched_authenticator_duo_stage_request import PatchedAuthenticatorDuoStageRequest +from authentik_client.models.patched_authenticator_email_stage_request import PatchedAuthenticatorEmailStageRequest +from authentik_client.models.patched_authenticator_endpoint_gdtc_stage_request import PatchedAuthenticatorEndpointGDTCStageRequest +from authentik_client.models.patched_authenticator_sms_stage_request import PatchedAuthenticatorSMSStageRequest +from authentik_client.models.patched_authenticator_static_stage_request import PatchedAuthenticatorStaticStageRequest +from authentik_client.models.patched_authenticator_totp_stage_request import PatchedAuthenticatorTOTPStageRequest +from authentik_client.models.patched_authenticator_validate_stage_request import PatchedAuthenticatorValidateStageRequest +from authentik_client.models.patched_authenticator_web_authn_stage_request import PatchedAuthenticatorWebAuthnStageRequest +from authentik_client.models.patched_captcha_stage_request import PatchedCaptchaStageRequest +from authentik_client.models.patched_consent_stage_request import PatchedConsentStageRequest +from authentik_client.models.patched_deny_stage_request import PatchedDenyStageRequest +from authentik_client.models.patched_dummy_stage_request import PatchedDummyStageRequest +from authentik_client.models.patched_email_stage_request import PatchedEmailStageRequest +from authentik_client.models.patched_endpoint_stage_request import PatchedEndpointStageRequest +from authentik_client.models.patched_identification_stage_request import PatchedIdentificationStageRequest +from authentik_client.models.patched_invitation_request import PatchedInvitationRequest +from authentik_client.models.patched_invitation_stage_request import PatchedInvitationStageRequest +from authentik_client.models.patched_mutual_tls_stage_request import PatchedMutualTLSStageRequest +from authentik_client.models.patched_password_stage_request import PatchedPasswordStageRequest +from authentik_client.models.patched_prompt_request import PatchedPromptRequest +from authentik_client.models.patched_prompt_stage_request import PatchedPromptStageRequest +from authentik_client.models.patched_redirect_stage_request import PatchedRedirectStageRequest +from authentik_client.models.patched_source_stage_request import PatchedSourceStageRequest +from authentik_client.models.patched_user_delete_stage_request import PatchedUserDeleteStageRequest +from authentik_client.models.patched_user_login_stage_request import PatchedUserLoginStageRequest +from authentik_client.models.patched_user_logout_stage_request import PatchedUserLogoutStageRequest +from authentik_client.models.patched_user_write_stage_request import PatchedUserWriteStageRequest +from authentik_client.models.prompt import Prompt +from authentik_client.models.prompt_challenge import PromptChallenge +from authentik_client.models.prompt_request import PromptRequest +from authentik_client.models.prompt_stage import PromptStage +from authentik_client.models.prompt_stage_request import PromptStageRequest +from authentik_client.models.prompt_type_enum import PromptTypeEnum +from authentik_client.models.provider_enum import ProviderEnum +from authentik_client.models.redirect_stage import RedirectStage +from authentik_client.models.redirect_stage_request import RedirectStageRequest +from authentik_client.models.source_stage import SourceStage +from authentik_client.models.source_stage_request import SourceStageRequest +from authentik_client.models.stage import Stage +from authentik_client.models.stage_mode_enum import StageModeEnum +from authentik_client.models.type_create import TypeCreate +from authentik_client.models.used_by import UsedBy +from authentik_client.models.user_attribute_enum import UserAttributeEnum +from authentik_client.models.user_creation_mode_enum import UserCreationModeEnum +from authentik_client.models.user_delete_stage import UserDeleteStage +from authentik_client.models.user_delete_stage_request import UserDeleteStageRequest +from authentik_client.models.user_login_stage import UserLoginStage +from authentik_client.models.user_login_stage_request import UserLoginStageRequest +from authentik_client.models.user_logout_stage import UserLogoutStage +from authentik_client.models.user_logout_stage_request import UserLogoutStageRequest +from authentik_client.models.user_setting import UserSetting +from authentik_client.models.user_type_enum import UserTypeEnum +from authentik_client.models.user_verification_enum import UserVerificationEnum +from authentik_client.models.user_write_stage import UserWriteStage +from authentik_client.models.user_write_stage_request import UserWriteStageRequest +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class StagesApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def stages_account_lockdown_create( + self, + account_lockdown_stage_request: AccountLockdownStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AccountLockdownStage: + """stages_account_lockdown_create + + AccountLockdownStage Viewset + + :param account_lockdown_stage_request: (required) + :type account_lockdown_stage_request: AccountLockdownStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_create_serialize( + account_lockdown_stage_request=account_lockdown_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_account_lockdown_create_with_http_info( + self, + account_lockdown_stage_request: AccountLockdownStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AccountLockdownStage]: + """stages_account_lockdown_create + + AccountLockdownStage Viewset + + :param account_lockdown_stage_request: (required) + :type account_lockdown_stage_request: AccountLockdownStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_create_serialize( + account_lockdown_stage_request=account_lockdown_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_account_lockdown_create_without_preload_content( + self, + account_lockdown_stage_request: AccountLockdownStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_account_lockdown_create + + AccountLockdownStage Viewset + + :param account_lockdown_stage_request: (required) + :type account_lockdown_stage_request: AccountLockdownStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_create_serialize( + account_lockdown_stage_request=account_lockdown_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_account_lockdown_create_serialize( + self, + account_lockdown_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if account_lockdown_stage_request is not None: + _body_params = account_lockdown_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/account_lockdown/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_account_lockdown_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_account_lockdown_destroy + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_account_lockdown_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_account_lockdown_destroy + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_account_lockdown_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_account_lockdown_destroy + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_account_lockdown_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/account_lockdown/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_account_lockdown_list( + self, + deactivate_user: Optional[StrictBool] = None, + delete_sessions: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + revoke_tokens: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + self_service_completion_flow: Optional[UUID] = None, + set_unusable_password: Optional[StrictBool] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAccountLockdownStageList: + """stages_account_lockdown_list + + AccountLockdownStage Viewset + + :param deactivate_user: + :type deactivate_user: bool + :param delete_sessions: + :type delete_sessions: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param revoke_tokens: + :type revoke_tokens: bool + :param search: A search term. + :type search: str + :param self_service_completion_flow: + :type self_service_completion_flow: UUID + :param set_unusable_password: + :type set_unusable_password: bool + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_list_serialize( + deactivate_user=deactivate_user, + delete_sessions=delete_sessions, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + revoke_tokens=revoke_tokens, + search=search, + self_service_completion_flow=self_service_completion_flow, + set_unusable_password=set_unusable_password, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAccountLockdownStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_account_lockdown_list_with_http_info( + self, + deactivate_user: Optional[StrictBool] = None, + delete_sessions: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + revoke_tokens: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + self_service_completion_flow: Optional[UUID] = None, + set_unusable_password: Optional[StrictBool] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAccountLockdownStageList]: + """stages_account_lockdown_list + + AccountLockdownStage Viewset + + :param deactivate_user: + :type deactivate_user: bool + :param delete_sessions: + :type delete_sessions: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param revoke_tokens: + :type revoke_tokens: bool + :param search: A search term. + :type search: str + :param self_service_completion_flow: + :type self_service_completion_flow: UUID + :param set_unusable_password: + :type set_unusable_password: bool + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_list_serialize( + deactivate_user=deactivate_user, + delete_sessions=delete_sessions, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + revoke_tokens=revoke_tokens, + search=search, + self_service_completion_flow=self_service_completion_flow, + set_unusable_password=set_unusable_password, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAccountLockdownStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_account_lockdown_list_without_preload_content( + self, + deactivate_user: Optional[StrictBool] = None, + delete_sessions: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + revoke_tokens: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + self_service_completion_flow: Optional[UUID] = None, + set_unusable_password: Optional[StrictBool] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_account_lockdown_list + + AccountLockdownStage Viewset + + :param deactivate_user: + :type deactivate_user: bool + :param delete_sessions: + :type delete_sessions: bool + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param revoke_tokens: + :type revoke_tokens: bool + :param search: A search term. + :type search: str + :param self_service_completion_flow: + :type self_service_completion_flow: UUID + :param set_unusable_password: + :type set_unusable_password: bool + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_list_serialize( + deactivate_user=deactivate_user, + delete_sessions=delete_sessions, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + revoke_tokens=revoke_tokens, + search=search, + self_service_completion_flow=self_service_completion_flow, + set_unusable_password=set_unusable_password, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAccountLockdownStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_account_lockdown_list_serialize( + self, + deactivate_user, + delete_sessions, + name, + ordering, + page, + page_size, + revoke_tokens, + search, + self_service_completion_flow, + set_unusable_password, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if deactivate_user is not None: + + _query_params.append(('deactivate_user', deactivate_user)) + + if delete_sessions is not None: + + _query_params.append(('delete_sessions', delete_sessions)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if revoke_tokens is not None: + + _query_params.append(('revoke_tokens', revoke_tokens)) + + if search is not None: + + _query_params.append(('search', search)) + + if self_service_completion_flow is not None: + + _query_params.append(('self_service_completion_flow', self_service_completion_flow)) + + if set_unusable_password is not None: + + _query_params.append(('set_unusable_password', set_unusable_password)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/account_lockdown/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_account_lockdown_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + patched_account_lockdown_stage_request: Optional[PatchedAccountLockdownStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AccountLockdownStage: + """stages_account_lockdown_partial_update + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param patched_account_lockdown_stage_request: + :type patched_account_lockdown_stage_request: PatchedAccountLockdownStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_partial_update_serialize( + stage_uuid=stage_uuid, + patched_account_lockdown_stage_request=patched_account_lockdown_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_account_lockdown_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + patched_account_lockdown_stage_request: Optional[PatchedAccountLockdownStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AccountLockdownStage]: + """stages_account_lockdown_partial_update + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param patched_account_lockdown_stage_request: + :type patched_account_lockdown_stage_request: PatchedAccountLockdownStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_partial_update_serialize( + stage_uuid=stage_uuid, + patched_account_lockdown_stage_request=patched_account_lockdown_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_account_lockdown_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + patched_account_lockdown_stage_request: Optional[PatchedAccountLockdownStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_account_lockdown_partial_update + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param patched_account_lockdown_stage_request: + :type patched_account_lockdown_stage_request: PatchedAccountLockdownStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_partial_update_serialize( + stage_uuid=stage_uuid, + patched_account_lockdown_stage_request=patched_account_lockdown_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_account_lockdown_partial_update_serialize( + self, + stage_uuid, + patched_account_lockdown_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_account_lockdown_stage_request is not None: + _body_params = patched_account_lockdown_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/account_lockdown/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_account_lockdown_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AccountLockdownStage: + """stages_account_lockdown_retrieve + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_account_lockdown_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AccountLockdownStage]: + """stages_account_lockdown_retrieve + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_account_lockdown_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_account_lockdown_retrieve + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_account_lockdown_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/account_lockdown/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_account_lockdown_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + account_lockdown_stage_request: AccountLockdownStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AccountLockdownStage: + """stages_account_lockdown_update + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param account_lockdown_stage_request: (required) + :type account_lockdown_stage_request: AccountLockdownStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_update_serialize( + stage_uuid=stage_uuid, + account_lockdown_stage_request=account_lockdown_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_account_lockdown_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + account_lockdown_stage_request: AccountLockdownStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AccountLockdownStage]: + """stages_account_lockdown_update + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param account_lockdown_stage_request: (required) + :type account_lockdown_stage_request: AccountLockdownStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_update_serialize( + stage_uuid=stage_uuid, + account_lockdown_stage_request=account_lockdown_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_account_lockdown_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + account_lockdown_stage_request: AccountLockdownStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_account_lockdown_update + + AccountLockdownStage Viewset + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param account_lockdown_stage_request: (required) + :type account_lockdown_stage_request: AccountLockdownStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_update_serialize( + stage_uuid=stage_uuid, + account_lockdown_stage_request=account_lockdown_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AccountLockdownStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_account_lockdown_update_serialize( + self, + stage_uuid, + account_lockdown_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if account_lockdown_stage_request is not None: + _body_params = account_lockdown_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/account_lockdown/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_account_lockdown_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_account_lockdown_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_account_lockdown_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_account_lockdown_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_account_lockdown_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Account Lockdown Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_account_lockdown_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Account Lockdown Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_account_lockdown_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_account_lockdown_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/account_lockdown/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_all_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_all_destroy + + Stage Viewset + + :param stage_uuid: A UUID string identifying this stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_all_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_all_destroy + + Stage Viewset + + :param stage_uuid: A UUID string identifying this stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_all_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_all_destroy + + Stage Viewset + + :param stage_uuid: A UUID string identifying this stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_all_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/all/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_all_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedStageList: + """stages_all_list + + Stage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_all_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedStageList]: + """stages_all_list + + Stage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_all_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_all_list + + Stage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_all_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/all/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_all_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Stage: + """stages_all_retrieve + + Stage Viewset + + :param stage_uuid: A UUID string identifying this stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Stage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_all_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Stage]: + """stages_all_retrieve + + Stage Viewset + + :param stage_uuid: A UUID string identifying this stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Stage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_all_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_all_retrieve + + Stage Viewset + + :param stage_uuid: A UUID string identifying this stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Stage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_all_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/all/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_all_types_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[TypeCreate]: + """stages_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_all_types_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[TypeCreate]]: + """stages_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_all_types_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_all_types_list + + Get all creatable types + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_types_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_all_types_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/all/types/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_all_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_all_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_all_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_all_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_all_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_all_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_all_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/all/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_all_user_settings_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UserSetting]: + """stages_all_user_settings_list + + Get all stages the user can configure + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_user_settings_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UserSetting]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_all_user_settings_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UserSetting]]: + """stages_all_user_settings_list + + Get all stages the user can configure + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_user_settings_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UserSetting]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_all_user_settings_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_all_user_settings_list + + Get all stages the user can configure + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_all_user_settings_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UserSetting]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_all_user_settings_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/all/user_settings/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_create( + self, + authenticator_duo_stage_request: AuthenticatorDuoStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorDuoStage: + """stages_authenticator_duo_create + + AuthenticatorDuoStage Viewset + + :param authenticator_duo_stage_request: (required) + :type authenticator_duo_stage_request: AuthenticatorDuoStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_create_serialize( + authenticator_duo_stage_request=authenticator_duo_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_create_with_http_info( + self, + authenticator_duo_stage_request: AuthenticatorDuoStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorDuoStage]: + """stages_authenticator_duo_create + + AuthenticatorDuoStage Viewset + + :param authenticator_duo_stage_request: (required) + :type authenticator_duo_stage_request: AuthenticatorDuoStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_create_serialize( + authenticator_duo_stage_request=authenticator_duo_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_create_without_preload_content( + self, + authenticator_duo_stage_request: AuthenticatorDuoStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_create + + AuthenticatorDuoStage Viewset + + :param authenticator_duo_stage_request: (required) + :type authenticator_duo_stage_request: AuthenticatorDuoStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_create_serialize( + authenticator_duo_stage_request=authenticator_duo_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_create_serialize( + self, + authenticator_duo_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_duo_stage_request is not None: + _body_params = authenticator_duo_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/duo/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_authenticator_duo_destroy + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_authenticator_duo_destroy + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_destroy + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/authenticator/duo/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_enrollment_status_create( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DuoDeviceEnrollmentStatus: + """stages_authenticator_duo_enrollment_status_create + + Check enrollment status of user details in current session + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_enrollment_status_create_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDeviceEnrollmentStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_enrollment_status_create_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DuoDeviceEnrollmentStatus]: + """stages_authenticator_duo_enrollment_status_create + + Check enrollment status of user details in current session + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_enrollment_status_create_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDeviceEnrollmentStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_enrollment_status_create_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_enrollment_status_create + + Check enrollment status of user details in current session + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_enrollment_status_create_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DuoDeviceEnrollmentStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_enrollment_status_create_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/duo/{stage_uuid}/enrollment_status/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_import_device_manual_create( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + authenticator_duo_stage_manual_device_import_request: AuthenticatorDuoStageManualDeviceImportRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_authenticator_duo_import_device_manual_create + + Import duo devices into authentik + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_duo_stage_manual_device_import_request: (required) + :type authenticator_duo_stage_manual_device_import_request: AuthenticatorDuoStageManualDeviceImportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_import_device_manual_create_serialize( + stage_uuid=stage_uuid, + authenticator_duo_stage_manual_device_import_request=authenticator_duo_stage_manual_device_import_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_import_device_manual_create_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + authenticator_duo_stage_manual_device_import_request: AuthenticatorDuoStageManualDeviceImportRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_authenticator_duo_import_device_manual_create + + Import duo devices into authentik + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_duo_stage_manual_device_import_request: (required) + :type authenticator_duo_stage_manual_device_import_request: AuthenticatorDuoStageManualDeviceImportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_import_device_manual_create_serialize( + stage_uuid=stage_uuid, + authenticator_duo_stage_manual_device_import_request=authenticator_duo_stage_manual_device_import_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_import_device_manual_create_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + authenticator_duo_stage_manual_device_import_request: AuthenticatorDuoStageManualDeviceImportRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_import_device_manual_create + + Import duo devices into authentik + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_duo_stage_manual_device_import_request: (required) + :type authenticator_duo_stage_manual_device_import_request: AuthenticatorDuoStageManualDeviceImportRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_import_device_manual_create_serialize( + stage_uuid=stage_uuid, + authenticator_duo_stage_manual_device_import_request=authenticator_duo_stage_manual_device_import_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_import_device_manual_create_serialize( + self, + stage_uuid, + authenticator_duo_stage_manual_device_import_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_duo_stage_manual_device_import_request is not None: + _body_params = authenticator_duo_stage_manual_device_import_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/duo/{stage_uuid}/import_device_manual/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_import_devices_automatic_create( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorDuoStageDeviceImportResponse: + """stages_authenticator_duo_import_devices_automatic_create + + Import duo devices into authentik + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_import_devices_automatic_create_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStageDeviceImportResponse", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_import_devices_automatic_create_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorDuoStageDeviceImportResponse]: + """stages_authenticator_duo_import_devices_automatic_create + + Import duo devices into authentik + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_import_devices_automatic_create_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStageDeviceImportResponse", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_import_devices_automatic_create_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_import_devices_automatic_create + + Import duo devices into authentik + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_import_devices_automatic_create_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStageDeviceImportResponse", + '400': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_import_devices_automatic_create_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/duo/{stage_uuid}/import_devices_automatic/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_list( + self, + api_hostname: Optional[StrictStr] = None, + client_id: Optional[StrictStr] = None, + configure_flow: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAuthenticatorDuoStageList: + """stages_authenticator_duo_list + + AuthenticatorDuoStage Viewset + + :param api_hostname: + :type api_hostname: str + :param client_id: + :type client_id: str + :param configure_flow: + :type configure_flow: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_list_serialize( + api_hostname=api_hostname, + client_id=client_id, + configure_flow=configure_flow, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorDuoStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_list_with_http_info( + self, + api_hostname: Optional[StrictStr] = None, + client_id: Optional[StrictStr] = None, + configure_flow: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAuthenticatorDuoStageList]: + """stages_authenticator_duo_list + + AuthenticatorDuoStage Viewset + + :param api_hostname: + :type api_hostname: str + :param client_id: + :type client_id: str + :param configure_flow: + :type configure_flow: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_list_serialize( + api_hostname=api_hostname, + client_id=client_id, + configure_flow=configure_flow, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorDuoStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_list_without_preload_content( + self, + api_hostname: Optional[StrictStr] = None, + client_id: Optional[StrictStr] = None, + configure_flow: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_list + + AuthenticatorDuoStage Viewset + + :param api_hostname: + :type api_hostname: str + :param client_id: + :type client_id: str + :param configure_flow: + :type configure_flow: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_list_serialize( + api_hostname=api_hostname, + client_id=client_id, + configure_flow=configure_flow, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorDuoStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_list_serialize( + self, + api_hostname, + client_id, + configure_flow, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if api_hostname is not None: + + _query_params.append(('api_hostname', api_hostname)) + + if client_id is not None: + + _query_params.append(('client_id', client_id)) + + if configure_flow is not None: + + _query_params.append(('configure_flow', configure_flow)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/duo/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + patched_authenticator_duo_stage_request: Optional[PatchedAuthenticatorDuoStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorDuoStage: + """stages_authenticator_duo_partial_update + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_duo_stage_request: + :type patched_authenticator_duo_stage_request: PatchedAuthenticatorDuoStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_duo_stage_request=patched_authenticator_duo_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + patched_authenticator_duo_stage_request: Optional[PatchedAuthenticatorDuoStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorDuoStage]: + """stages_authenticator_duo_partial_update + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_duo_stage_request: + :type patched_authenticator_duo_stage_request: PatchedAuthenticatorDuoStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_duo_stage_request=patched_authenticator_duo_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + patched_authenticator_duo_stage_request: Optional[PatchedAuthenticatorDuoStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_partial_update + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_duo_stage_request: + :type patched_authenticator_duo_stage_request: PatchedAuthenticatorDuoStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_duo_stage_request=patched_authenticator_duo_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_partial_update_serialize( + self, + stage_uuid, + patched_authenticator_duo_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_authenticator_duo_stage_request is not None: + _body_params = patched_authenticator_duo_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/authenticator/duo/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorDuoStage: + """stages_authenticator_duo_retrieve + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorDuoStage]: + """stages_authenticator_duo_retrieve + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_retrieve + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/duo/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + authenticator_duo_stage_request: AuthenticatorDuoStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorDuoStage: + """stages_authenticator_duo_update + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_duo_stage_request: (required) + :type authenticator_duo_stage_request: AuthenticatorDuoStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_update_serialize( + stage_uuid=stage_uuid, + authenticator_duo_stage_request=authenticator_duo_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + authenticator_duo_stage_request: AuthenticatorDuoStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorDuoStage]: + """stages_authenticator_duo_update + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_duo_stage_request: (required) + :type authenticator_duo_stage_request: AuthenticatorDuoStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_update_serialize( + stage_uuid=stage_uuid, + authenticator_duo_stage_request=authenticator_duo_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + authenticator_duo_stage_request: AuthenticatorDuoStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_update + + AuthenticatorDuoStage Viewset + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_duo_stage_request: (required) + :type authenticator_duo_stage_request: AuthenticatorDuoStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_update_serialize( + stage_uuid=stage_uuid, + authenticator_duo_stage_request=authenticator_duo_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorDuoStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_update_serialize( + self, + stage_uuid, + authenticator_duo_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_duo_stage_request is not None: + _body_params = authenticator_duo_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/authenticator/duo/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_duo_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_authenticator_duo_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_duo_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_authenticator_duo_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_duo_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Duo Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_duo_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Duo Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_duo_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_duo_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/duo/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_email_create( + self, + authenticator_email_stage_request: AuthenticatorEmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorEmailStage: + """stages_authenticator_email_create + + AuthenticatorEmailStage Viewset + + :param authenticator_email_stage_request: (required) + :type authenticator_email_stage_request: AuthenticatorEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_create_serialize( + authenticator_email_stage_request=authenticator_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_email_create_with_http_info( + self, + authenticator_email_stage_request: AuthenticatorEmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorEmailStage]: + """stages_authenticator_email_create + + AuthenticatorEmailStage Viewset + + :param authenticator_email_stage_request: (required) + :type authenticator_email_stage_request: AuthenticatorEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_create_serialize( + authenticator_email_stage_request=authenticator_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_email_create_without_preload_content( + self, + authenticator_email_stage_request: AuthenticatorEmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_email_create + + AuthenticatorEmailStage Viewset + + :param authenticator_email_stage_request: (required) + :type authenticator_email_stage_request: AuthenticatorEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_create_serialize( + authenticator_email_stage_request=authenticator_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_email_create_serialize( + self, + authenticator_email_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_email_stage_request is not None: + _body_params = authenticator_email_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/email/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_email_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_authenticator_email_destroy + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_email_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_authenticator_email_destroy + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_email_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_email_destroy + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_email_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/authenticator/email/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_email_list( + self, + configure_flow: Optional[UUID] = None, + friendly_name: Optional[StrictStr] = None, + from_address: Optional[StrictStr] = None, + host: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password: Optional[StrictStr] = None, + port: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + subject: Optional[StrictStr] = None, + template: Optional[StrictStr] = None, + timeout: Optional[StrictInt] = None, + token_expiry: Optional[StrictStr] = None, + use_global_settings: Optional[StrictBool] = None, + use_ssl: Optional[StrictBool] = None, + use_tls: Optional[StrictBool] = None, + username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAuthenticatorEmailStageList: + """stages_authenticator_email_list + + AuthenticatorEmailStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param friendly_name: + :type friendly_name: str + :param from_address: + :type from_address: str + :param host: + :type host: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password: + :type password: str + :param port: + :type port: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param subject: + :type subject: str + :param template: + :type template: str + :param timeout: + :type timeout: int + :param token_expiry: + :type token_expiry: str + :param use_global_settings: + :type use_global_settings: bool + :param use_ssl: + :type use_ssl: bool + :param use_tls: + :type use_tls: bool + :param username: + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_list_serialize( + configure_flow=configure_flow, + friendly_name=friendly_name, + from_address=from_address, + host=host, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password=password, + port=port, + search=search, + stage_uuid=stage_uuid, + subject=subject, + template=template, + timeout=timeout, + token_expiry=token_expiry, + use_global_settings=use_global_settings, + use_ssl=use_ssl, + use_tls=use_tls, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorEmailStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_email_list_with_http_info( + self, + configure_flow: Optional[UUID] = None, + friendly_name: Optional[StrictStr] = None, + from_address: Optional[StrictStr] = None, + host: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password: Optional[StrictStr] = None, + port: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + subject: Optional[StrictStr] = None, + template: Optional[StrictStr] = None, + timeout: Optional[StrictInt] = None, + token_expiry: Optional[StrictStr] = None, + use_global_settings: Optional[StrictBool] = None, + use_ssl: Optional[StrictBool] = None, + use_tls: Optional[StrictBool] = None, + username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAuthenticatorEmailStageList]: + """stages_authenticator_email_list + + AuthenticatorEmailStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param friendly_name: + :type friendly_name: str + :param from_address: + :type from_address: str + :param host: + :type host: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password: + :type password: str + :param port: + :type port: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param subject: + :type subject: str + :param template: + :type template: str + :param timeout: + :type timeout: int + :param token_expiry: + :type token_expiry: str + :param use_global_settings: + :type use_global_settings: bool + :param use_ssl: + :type use_ssl: bool + :param use_tls: + :type use_tls: bool + :param username: + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_list_serialize( + configure_flow=configure_flow, + friendly_name=friendly_name, + from_address=from_address, + host=host, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password=password, + port=port, + search=search, + stage_uuid=stage_uuid, + subject=subject, + template=template, + timeout=timeout, + token_expiry=token_expiry, + use_global_settings=use_global_settings, + use_ssl=use_ssl, + use_tls=use_tls, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorEmailStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_email_list_without_preload_content( + self, + configure_flow: Optional[UUID] = None, + friendly_name: Optional[StrictStr] = None, + from_address: Optional[StrictStr] = None, + host: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password: Optional[StrictStr] = None, + port: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + subject: Optional[StrictStr] = None, + template: Optional[StrictStr] = None, + timeout: Optional[StrictInt] = None, + token_expiry: Optional[StrictStr] = None, + use_global_settings: Optional[StrictBool] = None, + use_ssl: Optional[StrictBool] = None, + use_tls: Optional[StrictBool] = None, + username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_email_list + + AuthenticatorEmailStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param friendly_name: + :type friendly_name: str + :param from_address: + :type from_address: str + :param host: + :type host: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password: + :type password: str + :param port: + :type port: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param subject: + :type subject: str + :param template: + :type template: str + :param timeout: + :type timeout: int + :param token_expiry: + :type token_expiry: str + :param use_global_settings: + :type use_global_settings: bool + :param use_ssl: + :type use_ssl: bool + :param use_tls: + :type use_tls: bool + :param username: + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_list_serialize( + configure_flow=configure_flow, + friendly_name=friendly_name, + from_address=from_address, + host=host, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password=password, + port=port, + search=search, + stage_uuid=stage_uuid, + subject=subject, + template=template, + timeout=timeout, + token_expiry=token_expiry, + use_global_settings=use_global_settings, + use_ssl=use_ssl, + use_tls=use_tls, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorEmailStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_email_list_serialize( + self, + configure_flow, + friendly_name, + from_address, + host, + name, + ordering, + page, + page_size, + password, + port, + search, + stage_uuid, + subject, + template, + timeout, + token_expiry, + use_global_settings, + use_ssl, + use_tls, + username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if configure_flow is not None: + + _query_params.append(('configure_flow', configure_flow)) + + if friendly_name is not None: + + _query_params.append(('friendly_name', friendly_name)) + + if from_address is not None: + + _query_params.append(('from_address', from_address)) + + if host is not None: + + _query_params.append(('host', host)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if password is not None: + + _query_params.append(('password', password)) + + if port is not None: + + _query_params.append(('port', port)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + if subject is not None: + + _query_params.append(('subject', subject)) + + if template is not None: + + _query_params.append(('template', template)) + + if timeout is not None: + + _query_params.append(('timeout', timeout)) + + if token_expiry is not None: + + _query_params.append(('token_expiry', token_expiry)) + + if use_global_settings is not None: + + _query_params.append(('use_global_settings', use_global_settings)) + + if use_ssl is not None: + + _query_params.append(('use_ssl', use_ssl)) + + if use_tls is not None: + + _query_params.append(('use_tls', use_tls)) + + if username is not None: + + _query_params.append(('username', username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/email/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_email_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + patched_authenticator_email_stage_request: Optional[PatchedAuthenticatorEmailStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorEmailStage: + """stages_authenticator_email_partial_update + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_email_stage_request: + :type patched_authenticator_email_stage_request: PatchedAuthenticatorEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_email_stage_request=patched_authenticator_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_email_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + patched_authenticator_email_stage_request: Optional[PatchedAuthenticatorEmailStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorEmailStage]: + """stages_authenticator_email_partial_update + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_email_stage_request: + :type patched_authenticator_email_stage_request: PatchedAuthenticatorEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_email_stage_request=patched_authenticator_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_email_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + patched_authenticator_email_stage_request: Optional[PatchedAuthenticatorEmailStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_email_partial_update + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_email_stage_request: + :type patched_authenticator_email_stage_request: PatchedAuthenticatorEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_email_stage_request=patched_authenticator_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_email_partial_update_serialize( + self, + stage_uuid, + patched_authenticator_email_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_authenticator_email_stage_request is not None: + _body_params = patched_authenticator_email_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/authenticator/email/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_email_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorEmailStage: + """stages_authenticator_email_retrieve + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_email_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorEmailStage]: + """stages_authenticator_email_retrieve + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_email_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_email_retrieve + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_email_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/email/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_email_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + authenticator_email_stage_request: AuthenticatorEmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorEmailStage: + """stages_authenticator_email_update + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_email_stage_request: (required) + :type authenticator_email_stage_request: AuthenticatorEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_update_serialize( + stage_uuid=stage_uuid, + authenticator_email_stage_request=authenticator_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_email_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + authenticator_email_stage_request: AuthenticatorEmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorEmailStage]: + """stages_authenticator_email_update + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_email_stage_request: (required) + :type authenticator_email_stage_request: AuthenticatorEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_update_serialize( + stage_uuid=stage_uuid, + authenticator_email_stage_request=authenticator_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_email_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + authenticator_email_stage_request: AuthenticatorEmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_email_update + + AuthenticatorEmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_email_stage_request: (required) + :type authenticator_email_stage_request: AuthenticatorEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_update_serialize( + stage_uuid=stage_uuid, + authenticator_email_stage_request=authenticator_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_email_update_serialize( + self, + stage_uuid, + authenticator_email_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_email_stage_request is not None: + _body_params = authenticator_email_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/authenticator/email/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_email_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_authenticator_email_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_email_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_authenticator_email_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_email_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_email_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Email Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_email_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_email_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/email/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_endpoint_gdtc_create( + self, + authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorEndpointGDTCStage: + """stages_authenticator_endpoint_gdtc_create + + AuthenticatorEndpointGDTCStage Viewset + + :param authenticator_endpoint_gdtc_stage_request: (required) + :type authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_create_serialize( + authenticator_endpoint_gdtc_stage_request=authenticator_endpoint_gdtc_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_endpoint_gdtc_create_with_http_info( + self, + authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorEndpointGDTCStage]: + """stages_authenticator_endpoint_gdtc_create + + AuthenticatorEndpointGDTCStage Viewset + + :param authenticator_endpoint_gdtc_stage_request: (required) + :type authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_create_serialize( + authenticator_endpoint_gdtc_stage_request=authenticator_endpoint_gdtc_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_endpoint_gdtc_create_without_preload_content( + self, + authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_endpoint_gdtc_create + + AuthenticatorEndpointGDTCStage Viewset + + :param authenticator_endpoint_gdtc_stage_request: (required) + :type authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_create_serialize( + authenticator_endpoint_gdtc_stage_request=authenticator_endpoint_gdtc_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_endpoint_gdtc_create_serialize( + self, + authenticator_endpoint_gdtc_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_endpoint_gdtc_stage_request is not None: + _body_params = authenticator_endpoint_gdtc_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/endpoint_gdtc/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_endpoint_gdtc_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_authenticator_endpoint_gdtc_destroy + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_endpoint_gdtc_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_authenticator_endpoint_gdtc_destroy + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_endpoint_gdtc_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_endpoint_gdtc_destroy + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_endpoint_gdtc_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/authenticator/endpoint_gdtc/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_endpoint_gdtc_list( + self, + configure_flow: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAuthenticatorEndpointGDTCStageList: + """stages_authenticator_endpoint_gdtc_list + + AuthenticatorEndpointGDTCStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_list_serialize( + configure_flow=configure_flow, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorEndpointGDTCStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_endpoint_gdtc_list_with_http_info( + self, + configure_flow: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAuthenticatorEndpointGDTCStageList]: + """stages_authenticator_endpoint_gdtc_list + + AuthenticatorEndpointGDTCStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_list_serialize( + configure_flow=configure_flow, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorEndpointGDTCStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_endpoint_gdtc_list_without_preload_content( + self, + configure_flow: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_endpoint_gdtc_list + + AuthenticatorEndpointGDTCStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_list_serialize( + configure_flow=configure_flow, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorEndpointGDTCStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_endpoint_gdtc_list_serialize( + self, + configure_flow, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if configure_flow is not None: + + _query_params.append(('configure_flow', configure_flow)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/endpoint_gdtc/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_endpoint_gdtc_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + patched_authenticator_endpoint_gdtc_stage_request: Optional[PatchedAuthenticatorEndpointGDTCStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorEndpointGDTCStage: + """stages_authenticator_endpoint_gdtc_partial_update + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_endpoint_gdtc_stage_request: + :type patched_authenticator_endpoint_gdtc_stage_request: PatchedAuthenticatorEndpointGDTCStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_endpoint_gdtc_stage_request=patched_authenticator_endpoint_gdtc_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_endpoint_gdtc_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + patched_authenticator_endpoint_gdtc_stage_request: Optional[PatchedAuthenticatorEndpointGDTCStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorEndpointGDTCStage]: + """stages_authenticator_endpoint_gdtc_partial_update + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_endpoint_gdtc_stage_request: + :type patched_authenticator_endpoint_gdtc_stage_request: PatchedAuthenticatorEndpointGDTCStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_endpoint_gdtc_stage_request=patched_authenticator_endpoint_gdtc_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_endpoint_gdtc_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + patched_authenticator_endpoint_gdtc_stage_request: Optional[PatchedAuthenticatorEndpointGDTCStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_endpoint_gdtc_partial_update + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_endpoint_gdtc_stage_request: + :type patched_authenticator_endpoint_gdtc_stage_request: PatchedAuthenticatorEndpointGDTCStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_endpoint_gdtc_stage_request=patched_authenticator_endpoint_gdtc_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_endpoint_gdtc_partial_update_serialize( + self, + stage_uuid, + patched_authenticator_endpoint_gdtc_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_authenticator_endpoint_gdtc_stage_request is not None: + _body_params = patched_authenticator_endpoint_gdtc_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/authenticator/endpoint_gdtc/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_endpoint_gdtc_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorEndpointGDTCStage: + """stages_authenticator_endpoint_gdtc_retrieve + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_endpoint_gdtc_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorEndpointGDTCStage]: + """stages_authenticator_endpoint_gdtc_retrieve + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_endpoint_gdtc_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_endpoint_gdtc_retrieve + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_endpoint_gdtc_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/endpoint_gdtc/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_endpoint_gdtc_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorEndpointGDTCStage: + """stages_authenticator_endpoint_gdtc_update + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param authenticator_endpoint_gdtc_stage_request: (required) + :type authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_update_serialize( + stage_uuid=stage_uuid, + authenticator_endpoint_gdtc_stage_request=authenticator_endpoint_gdtc_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_endpoint_gdtc_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorEndpointGDTCStage]: + """stages_authenticator_endpoint_gdtc_update + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param authenticator_endpoint_gdtc_stage_request: (required) + :type authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_update_serialize( + stage_uuid=stage_uuid, + authenticator_endpoint_gdtc_stage_request=authenticator_endpoint_gdtc_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_endpoint_gdtc_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_endpoint_gdtc_update + + AuthenticatorEndpointGDTCStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param authenticator_endpoint_gdtc_stage_request: (required) + :type authenticator_endpoint_gdtc_stage_request: AuthenticatorEndpointGDTCStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_update_serialize( + stage_uuid=stage_uuid, + authenticator_endpoint_gdtc_stage_request=authenticator_endpoint_gdtc_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorEndpointGDTCStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_endpoint_gdtc_update_serialize( + self, + stage_uuid, + authenticator_endpoint_gdtc_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_endpoint_gdtc_stage_request is not None: + _body_params = authenticator_endpoint_gdtc_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/authenticator/endpoint_gdtc/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_endpoint_gdtc_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_authenticator_endpoint_gdtc_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_endpoint_gdtc_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_authenticator_endpoint_gdtc_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_endpoint_gdtc_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_endpoint_gdtc_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_endpoint_gdtc_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_endpoint_gdtc_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/endpoint_gdtc/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_sms_create( + self, + authenticator_sms_stage_request: AuthenticatorSMSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorSMSStage: + """stages_authenticator_sms_create + + AuthenticatorSMSStage Viewset + + :param authenticator_sms_stage_request: (required) + :type authenticator_sms_stage_request: AuthenticatorSMSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_create_serialize( + authenticator_sms_stage_request=authenticator_sms_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_sms_create_with_http_info( + self, + authenticator_sms_stage_request: AuthenticatorSMSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorSMSStage]: + """stages_authenticator_sms_create + + AuthenticatorSMSStage Viewset + + :param authenticator_sms_stage_request: (required) + :type authenticator_sms_stage_request: AuthenticatorSMSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_create_serialize( + authenticator_sms_stage_request=authenticator_sms_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_sms_create_without_preload_content( + self, + authenticator_sms_stage_request: AuthenticatorSMSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_sms_create + + AuthenticatorSMSStage Viewset + + :param authenticator_sms_stage_request: (required) + :type authenticator_sms_stage_request: AuthenticatorSMSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_create_serialize( + authenticator_sms_stage_request=authenticator_sms_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_sms_create_serialize( + self, + authenticator_sms_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_sms_stage_request is not None: + _body_params = authenticator_sms_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/sms/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_sms_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_authenticator_sms_destroy + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_sms_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_authenticator_sms_destroy + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_sms_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_sms_destroy + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_sms_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/authenticator/sms/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_sms_list( + self, + account_sid: Optional[StrictStr] = None, + auth: Optional[StrictStr] = None, + auth_password: Optional[StrictStr] = None, + auth_type: Optional[AuthTypeEnum] = None, + configure_flow: Optional[UUID] = None, + friendly_name: Optional[StrictStr] = None, + from_number: Optional[StrictStr] = None, + mapping: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[ProviderEnum] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + verify_only: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAuthenticatorSMSStageList: + """stages_authenticator_sms_list + + AuthenticatorSMSStage Viewset + + :param account_sid: + :type account_sid: str + :param auth: + :type auth: str + :param auth_password: + :type auth_password: str + :param auth_type: + :type auth_type: AuthTypeEnum + :param configure_flow: + :type configure_flow: UUID + :param friendly_name: + :type friendly_name: str + :param from_number: + :type from_number: str + :param mapping: + :type mapping: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: ProviderEnum + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param verify_only: + :type verify_only: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_list_serialize( + account_sid=account_sid, + auth=auth, + auth_password=auth_password, + auth_type=auth_type, + configure_flow=configure_flow, + friendly_name=friendly_name, + from_number=from_number, + mapping=mapping, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + stage_uuid=stage_uuid, + verify_only=verify_only, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorSMSStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_sms_list_with_http_info( + self, + account_sid: Optional[StrictStr] = None, + auth: Optional[StrictStr] = None, + auth_password: Optional[StrictStr] = None, + auth_type: Optional[AuthTypeEnum] = None, + configure_flow: Optional[UUID] = None, + friendly_name: Optional[StrictStr] = None, + from_number: Optional[StrictStr] = None, + mapping: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[ProviderEnum] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + verify_only: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAuthenticatorSMSStageList]: + """stages_authenticator_sms_list + + AuthenticatorSMSStage Viewset + + :param account_sid: + :type account_sid: str + :param auth: + :type auth: str + :param auth_password: + :type auth_password: str + :param auth_type: + :type auth_type: AuthTypeEnum + :param configure_flow: + :type configure_flow: UUID + :param friendly_name: + :type friendly_name: str + :param from_number: + :type from_number: str + :param mapping: + :type mapping: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: ProviderEnum + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param verify_only: + :type verify_only: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_list_serialize( + account_sid=account_sid, + auth=auth, + auth_password=auth_password, + auth_type=auth_type, + configure_flow=configure_flow, + friendly_name=friendly_name, + from_number=from_number, + mapping=mapping, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + stage_uuid=stage_uuid, + verify_only=verify_only, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorSMSStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_sms_list_without_preload_content( + self, + account_sid: Optional[StrictStr] = None, + auth: Optional[StrictStr] = None, + auth_password: Optional[StrictStr] = None, + auth_type: Optional[AuthTypeEnum] = None, + configure_flow: Optional[UUID] = None, + friendly_name: Optional[StrictStr] = None, + from_number: Optional[StrictStr] = None, + mapping: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + provider: Optional[ProviderEnum] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + verify_only: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_sms_list + + AuthenticatorSMSStage Viewset + + :param account_sid: + :type account_sid: str + :param auth: + :type auth: str + :param auth_password: + :type auth_password: str + :param auth_type: + :type auth_type: AuthTypeEnum + :param configure_flow: + :type configure_flow: UUID + :param friendly_name: + :type friendly_name: str + :param from_number: + :type from_number: str + :param mapping: + :type mapping: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param provider: + :type provider: ProviderEnum + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param verify_only: + :type verify_only: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_list_serialize( + account_sid=account_sid, + auth=auth, + auth_password=auth_password, + auth_type=auth_type, + configure_flow=configure_flow, + friendly_name=friendly_name, + from_number=from_number, + mapping=mapping, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + provider=provider, + search=search, + stage_uuid=stage_uuid, + verify_only=verify_only, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorSMSStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_sms_list_serialize( + self, + account_sid, + auth, + auth_password, + auth_type, + configure_flow, + friendly_name, + from_number, + mapping, + name, + ordering, + page, + page_size, + provider, + search, + stage_uuid, + verify_only, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if account_sid is not None: + + _query_params.append(('account_sid', account_sid)) + + if auth is not None: + + _query_params.append(('auth', auth)) + + if auth_password is not None: + + _query_params.append(('auth_password', auth_password)) + + if auth_type is not None: + + _query_params.append(('auth_type', auth_type.value)) + + if configure_flow is not None: + + _query_params.append(('configure_flow', configure_flow)) + + if friendly_name is not None: + + _query_params.append(('friendly_name', friendly_name)) + + if from_number is not None: + + _query_params.append(('from_number', from_number)) + + if mapping is not None: + + _query_params.append(('mapping', mapping)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if provider is not None: + + _query_params.append(('provider', provider.value)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + if verify_only is not None: + + _query_params.append(('verify_only', verify_only)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/sms/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_sms_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + patched_authenticator_sms_stage_request: Optional[PatchedAuthenticatorSMSStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorSMSStage: + """stages_authenticator_sms_partial_update + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_sms_stage_request: + :type patched_authenticator_sms_stage_request: PatchedAuthenticatorSMSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_sms_stage_request=patched_authenticator_sms_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_sms_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + patched_authenticator_sms_stage_request: Optional[PatchedAuthenticatorSMSStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorSMSStage]: + """stages_authenticator_sms_partial_update + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_sms_stage_request: + :type patched_authenticator_sms_stage_request: PatchedAuthenticatorSMSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_sms_stage_request=patched_authenticator_sms_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_sms_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + patched_authenticator_sms_stage_request: Optional[PatchedAuthenticatorSMSStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_sms_partial_update + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_sms_stage_request: + :type patched_authenticator_sms_stage_request: PatchedAuthenticatorSMSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_sms_stage_request=patched_authenticator_sms_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_sms_partial_update_serialize( + self, + stage_uuid, + patched_authenticator_sms_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_authenticator_sms_stage_request is not None: + _body_params = patched_authenticator_sms_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/authenticator/sms/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_sms_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorSMSStage: + """stages_authenticator_sms_retrieve + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_sms_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorSMSStage]: + """stages_authenticator_sms_retrieve + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_sms_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_sms_retrieve + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_sms_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/sms/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_sms_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + authenticator_sms_stage_request: AuthenticatorSMSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorSMSStage: + """stages_authenticator_sms_update + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_sms_stage_request: (required) + :type authenticator_sms_stage_request: AuthenticatorSMSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_update_serialize( + stage_uuid=stage_uuid, + authenticator_sms_stage_request=authenticator_sms_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_sms_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + authenticator_sms_stage_request: AuthenticatorSMSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorSMSStage]: + """stages_authenticator_sms_update + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_sms_stage_request: (required) + :type authenticator_sms_stage_request: AuthenticatorSMSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_update_serialize( + stage_uuid=stage_uuid, + authenticator_sms_stage_request=authenticator_sms_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_sms_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + authenticator_sms_stage_request: AuthenticatorSMSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_sms_update + + AuthenticatorSMSStage Viewset + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_sms_stage_request: (required) + :type authenticator_sms_stage_request: AuthenticatorSMSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_update_serialize( + stage_uuid=stage_uuid, + authenticator_sms_stage_request=authenticator_sms_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorSMSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_sms_update_serialize( + self, + stage_uuid, + authenticator_sms_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_sms_stage_request is not None: + _body_params = authenticator_sms_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/authenticator/sms/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_sms_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_authenticator_sms_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_sms_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_authenticator_sms_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_sms_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this SMS Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_sms_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this SMS Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_sms_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_sms_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/sms/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_static_create( + self, + authenticator_static_stage_request: AuthenticatorStaticStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorStaticStage: + """stages_authenticator_static_create + + AuthenticatorStaticStage Viewset + + :param authenticator_static_stage_request: (required) + :type authenticator_static_stage_request: AuthenticatorStaticStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_create_serialize( + authenticator_static_stage_request=authenticator_static_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_static_create_with_http_info( + self, + authenticator_static_stage_request: AuthenticatorStaticStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorStaticStage]: + """stages_authenticator_static_create + + AuthenticatorStaticStage Viewset + + :param authenticator_static_stage_request: (required) + :type authenticator_static_stage_request: AuthenticatorStaticStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_create_serialize( + authenticator_static_stage_request=authenticator_static_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_static_create_without_preload_content( + self, + authenticator_static_stage_request: AuthenticatorStaticStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_static_create + + AuthenticatorStaticStage Viewset + + :param authenticator_static_stage_request: (required) + :type authenticator_static_stage_request: AuthenticatorStaticStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_create_serialize( + authenticator_static_stage_request=authenticator_static_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_static_create_serialize( + self, + authenticator_static_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_static_stage_request is not None: + _body_params = authenticator_static_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/static/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_static_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_authenticator_static_destroy + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_static_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_authenticator_static_destroy + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_static_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_static_destroy + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_static_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/authenticator/static/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_static_list( + self, + configure_flow: Optional[UUID] = None, + friendly_name: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + token_count: Optional[StrictInt] = None, + token_length: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAuthenticatorStaticStageList: + """stages_authenticator_static_list + + AuthenticatorStaticStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param friendly_name: + :type friendly_name: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param token_count: + :type token_count: int + :param token_length: + :type token_length: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_list_serialize( + configure_flow=configure_flow, + friendly_name=friendly_name, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + token_count=token_count, + token_length=token_length, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorStaticStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_static_list_with_http_info( + self, + configure_flow: Optional[UUID] = None, + friendly_name: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + token_count: Optional[StrictInt] = None, + token_length: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAuthenticatorStaticStageList]: + """stages_authenticator_static_list + + AuthenticatorStaticStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param friendly_name: + :type friendly_name: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param token_count: + :type token_count: int + :param token_length: + :type token_length: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_list_serialize( + configure_flow=configure_flow, + friendly_name=friendly_name, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + token_count=token_count, + token_length=token_length, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorStaticStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_static_list_without_preload_content( + self, + configure_flow: Optional[UUID] = None, + friendly_name: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + token_count: Optional[StrictInt] = None, + token_length: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_static_list + + AuthenticatorStaticStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param friendly_name: + :type friendly_name: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param token_count: + :type token_count: int + :param token_length: + :type token_length: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_list_serialize( + configure_flow=configure_flow, + friendly_name=friendly_name, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + token_count=token_count, + token_length=token_length, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorStaticStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_static_list_serialize( + self, + configure_flow, + friendly_name, + name, + ordering, + page, + page_size, + search, + stage_uuid, + token_count, + token_length, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if configure_flow is not None: + + _query_params.append(('configure_flow', configure_flow)) + + if friendly_name is not None: + + _query_params.append(('friendly_name', friendly_name)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + if token_count is not None: + + _query_params.append(('token_count', token_count)) + + if token_length is not None: + + _query_params.append(('token_length', token_length)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/static/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_static_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + patched_authenticator_static_stage_request: Optional[PatchedAuthenticatorStaticStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorStaticStage: + """stages_authenticator_static_partial_update + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_static_stage_request: + :type patched_authenticator_static_stage_request: PatchedAuthenticatorStaticStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_static_stage_request=patched_authenticator_static_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_static_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + patched_authenticator_static_stage_request: Optional[PatchedAuthenticatorStaticStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorStaticStage]: + """stages_authenticator_static_partial_update + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_static_stage_request: + :type patched_authenticator_static_stage_request: PatchedAuthenticatorStaticStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_static_stage_request=patched_authenticator_static_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_static_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + patched_authenticator_static_stage_request: Optional[PatchedAuthenticatorStaticStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_static_partial_update + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_static_stage_request: + :type patched_authenticator_static_stage_request: PatchedAuthenticatorStaticStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_static_stage_request=patched_authenticator_static_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_static_partial_update_serialize( + self, + stage_uuid, + patched_authenticator_static_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_authenticator_static_stage_request is not None: + _body_params = patched_authenticator_static_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/authenticator/static/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_static_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorStaticStage: + """stages_authenticator_static_retrieve + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_static_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorStaticStage]: + """stages_authenticator_static_retrieve + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_static_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_static_retrieve + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_static_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/static/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_static_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + authenticator_static_stage_request: AuthenticatorStaticStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorStaticStage: + """stages_authenticator_static_update + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_static_stage_request: (required) + :type authenticator_static_stage_request: AuthenticatorStaticStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_update_serialize( + stage_uuid=stage_uuid, + authenticator_static_stage_request=authenticator_static_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_static_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + authenticator_static_stage_request: AuthenticatorStaticStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorStaticStage]: + """stages_authenticator_static_update + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_static_stage_request: (required) + :type authenticator_static_stage_request: AuthenticatorStaticStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_update_serialize( + stage_uuid=stage_uuid, + authenticator_static_stage_request=authenticator_static_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_static_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + authenticator_static_stage_request: AuthenticatorStaticStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_static_update + + AuthenticatorStaticStage Viewset + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_static_stage_request: (required) + :type authenticator_static_stage_request: AuthenticatorStaticStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_update_serialize( + stage_uuid=stage_uuid, + authenticator_static_stage_request=authenticator_static_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorStaticStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_static_update_serialize( + self, + stage_uuid, + authenticator_static_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_static_stage_request is not None: + _body_params = authenticator_static_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/authenticator/static/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_static_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_authenticator_static_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_static_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_authenticator_static_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_static_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Static Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_static_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Static Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_static_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_static_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/static/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_totp_create( + self, + authenticator_totp_stage_request: AuthenticatorTOTPStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorTOTPStage: + """stages_authenticator_totp_create + + AuthenticatorTOTPStage Viewset + + :param authenticator_totp_stage_request: (required) + :type authenticator_totp_stage_request: AuthenticatorTOTPStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_create_serialize( + authenticator_totp_stage_request=authenticator_totp_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_totp_create_with_http_info( + self, + authenticator_totp_stage_request: AuthenticatorTOTPStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorTOTPStage]: + """stages_authenticator_totp_create + + AuthenticatorTOTPStage Viewset + + :param authenticator_totp_stage_request: (required) + :type authenticator_totp_stage_request: AuthenticatorTOTPStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_create_serialize( + authenticator_totp_stage_request=authenticator_totp_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_totp_create_without_preload_content( + self, + authenticator_totp_stage_request: AuthenticatorTOTPStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_totp_create + + AuthenticatorTOTPStage Viewset + + :param authenticator_totp_stage_request: (required) + :type authenticator_totp_stage_request: AuthenticatorTOTPStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_create_serialize( + authenticator_totp_stage_request=authenticator_totp_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_totp_create_serialize( + self, + authenticator_totp_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_totp_stage_request is not None: + _body_params = authenticator_totp_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/totp/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_totp_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_authenticator_totp_destroy + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_totp_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_authenticator_totp_destroy + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_totp_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_totp_destroy + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_totp_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/authenticator/totp/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_totp_list( + self, + configure_flow: Optional[UUID] = None, + digits: Optional[DigitsEnum] = None, + friendly_name: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAuthenticatorTOTPStageList: + """stages_authenticator_totp_list + + AuthenticatorTOTPStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param digits: + :type digits: DigitsEnum + :param friendly_name: + :type friendly_name: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_list_serialize( + configure_flow=configure_flow, + digits=digits, + friendly_name=friendly_name, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorTOTPStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_totp_list_with_http_info( + self, + configure_flow: Optional[UUID] = None, + digits: Optional[DigitsEnum] = None, + friendly_name: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAuthenticatorTOTPStageList]: + """stages_authenticator_totp_list + + AuthenticatorTOTPStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param digits: + :type digits: DigitsEnum + :param friendly_name: + :type friendly_name: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_list_serialize( + configure_flow=configure_flow, + digits=digits, + friendly_name=friendly_name, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorTOTPStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_totp_list_without_preload_content( + self, + configure_flow: Optional[UUID] = None, + digits: Optional[DigitsEnum] = None, + friendly_name: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_totp_list + + AuthenticatorTOTPStage Viewset + + :param configure_flow: + :type configure_flow: UUID + :param digits: + :type digits: DigitsEnum + :param friendly_name: + :type friendly_name: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_list_serialize( + configure_flow=configure_flow, + digits=digits, + friendly_name=friendly_name, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorTOTPStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_totp_list_serialize( + self, + configure_flow, + digits, + friendly_name, + name, + ordering, + page, + page_size, + search, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if configure_flow is not None: + + _query_params.append(('configure_flow', configure_flow)) + + if digits is not None: + + _query_params.append(('digits', digits.value)) + + if friendly_name is not None: + + _query_params.append(('friendly_name', friendly_name)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/totp/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_totp_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + patched_authenticator_totp_stage_request: Optional[PatchedAuthenticatorTOTPStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorTOTPStage: + """stages_authenticator_totp_partial_update + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_totp_stage_request: + :type patched_authenticator_totp_stage_request: PatchedAuthenticatorTOTPStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_totp_stage_request=patched_authenticator_totp_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_totp_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + patched_authenticator_totp_stage_request: Optional[PatchedAuthenticatorTOTPStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorTOTPStage]: + """stages_authenticator_totp_partial_update + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_totp_stage_request: + :type patched_authenticator_totp_stage_request: PatchedAuthenticatorTOTPStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_totp_stage_request=patched_authenticator_totp_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_totp_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + patched_authenticator_totp_stage_request: Optional[PatchedAuthenticatorTOTPStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_totp_partial_update + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_totp_stage_request: + :type patched_authenticator_totp_stage_request: PatchedAuthenticatorTOTPStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_totp_stage_request=patched_authenticator_totp_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_totp_partial_update_serialize( + self, + stage_uuid, + patched_authenticator_totp_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_authenticator_totp_stage_request is not None: + _body_params = patched_authenticator_totp_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/authenticator/totp/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_totp_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorTOTPStage: + """stages_authenticator_totp_retrieve + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_totp_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorTOTPStage]: + """stages_authenticator_totp_retrieve + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_totp_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_totp_retrieve + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_totp_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/totp/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_totp_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + authenticator_totp_stage_request: AuthenticatorTOTPStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorTOTPStage: + """stages_authenticator_totp_update + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_totp_stage_request: (required) + :type authenticator_totp_stage_request: AuthenticatorTOTPStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_update_serialize( + stage_uuid=stage_uuid, + authenticator_totp_stage_request=authenticator_totp_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_totp_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + authenticator_totp_stage_request: AuthenticatorTOTPStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorTOTPStage]: + """stages_authenticator_totp_update + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_totp_stage_request: (required) + :type authenticator_totp_stage_request: AuthenticatorTOTPStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_update_serialize( + stage_uuid=stage_uuid, + authenticator_totp_stage_request=authenticator_totp_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_totp_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + authenticator_totp_stage_request: AuthenticatorTOTPStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_totp_update + + AuthenticatorTOTPStage Viewset + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_totp_stage_request: (required) + :type authenticator_totp_stage_request: AuthenticatorTOTPStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_update_serialize( + stage_uuid=stage_uuid, + authenticator_totp_stage_request=authenticator_totp_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorTOTPStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_totp_update_serialize( + self, + stage_uuid, + authenticator_totp_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_totp_stage_request is not None: + _body_params = authenticator_totp_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/authenticator/totp/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_totp_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_authenticator_totp_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_totp_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_authenticator_totp_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_totp_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this TOTP Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_totp_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this TOTP Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_totp_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_totp_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/totp/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_validate_create( + self, + authenticator_validate_stage_request: AuthenticatorValidateStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorValidateStage: + """stages_authenticator_validate_create + + AuthenticatorValidateStage Viewset + + :param authenticator_validate_stage_request: (required) + :type authenticator_validate_stage_request: AuthenticatorValidateStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_create_serialize( + authenticator_validate_stage_request=authenticator_validate_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_validate_create_with_http_info( + self, + authenticator_validate_stage_request: AuthenticatorValidateStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorValidateStage]: + """stages_authenticator_validate_create + + AuthenticatorValidateStage Viewset + + :param authenticator_validate_stage_request: (required) + :type authenticator_validate_stage_request: AuthenticatorValidateStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_create_serialize( + authenticator_validate_stage_request=authenticator_validate_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_validate_create_without_preload_content( + self, + authenticator_validate_stage_request: AuthenticatorValidateStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_validate_create + + AuthenticatorValidateStage Viewset + + :param authenticator_validate_stage_request: (required) + :type authenticator_validate_stage_request: AuthenticatorValidateStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_create_serialize( + authenticator_validate_stage_request=authenticator_validate_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_validate_create_serialize( + self, + authenticator_validate_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_validate_stage_request is not None: + _body_params = authenticator_validate_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/validate/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_validate_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_authenticator_validate_destroy + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_validate_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_authenticator_validate_destroy + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_validate_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_validate_destroy + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_validate_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/authenticator/validate/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_validate_list( + self, + configuration_stages: Optional[List[UUID]] = None, + name: Optional[StrictStr] = None, + not_configured_action: Optional[NotConfiguredActionEnum] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAuthenticatorValidateStageList: + """stages_authenticator_validate_list + + AuthenticatorValidateStage Viewset + + :param configuration_stages: + :type configuration_stages: List[UUID] + :param name: + :type name: str + :param not_configured_action: + :type not_configured_action: NotConfiguredActionEnum + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_list_serialize( + configuration_stages=configuration_stages, + name=name, + not_configured_action=not_configured_action, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorValidateStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_validate_list_with_http_info( + self, + configuration_stages: Optional[List[UUID]] = None, + name: Optional[StrictStr] = None, + not_configured_action: Optional[NotConfiguredActionEnum] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAuthenticatorValidateStageList]: + """stages_authenticator_validate_list + + AuthenticatorValidateStage Viewset + + :param configuration_stages: + :type configuration_stages: List[UUID] + :param name: + :type name: str + :param not_configured_action: + :type not_configured_action: NotConfiguredActionEnum + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_list_serialize( + configuration_stages=configuration_stages, + name=name, + not_configured_action=not_configured_action, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorValidateStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_validate_list_without_preload_content( + self, + configuration_stages: Optional[List[UUID]] = None, + name: Optional[StrictStr] = None, + not_configured_action: Optional[NotConfiguredActionEnum] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_validate_list + + AuthenticatorValidateStage Viewset + + :param configuration_stages: + :type configuration_stages: List[UUID] + :param name: + :type name: str + :param not_configured_action: + :type not_configured_action: NotConfiguredActionEnum + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_list_serialize( + configuration_stages=configuration_stages, + name=name, + not_configured_action=not_configured_action, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorValidateStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_validate_list_serialize( + self, + configuration_stages, + name, + not_configured_action, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'configuration_stages': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if configuration_stages is not None: + + _query_params.append(('configuration_stages', configuration_stages)) + + if name is not None: + + _query_params.append(('name', name)) + + if not_configured_action is not None: + + _query_params.append(('not_configured_action', not_configured_action.value)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/validate/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_validate_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + patched_authenticator_validate_stage_request: Optional[PatchedAuthenticatorValidateStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorValidateStage: + """stages_authenticator_validate_partial_update + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_validate_stage_request: + :type patched_authenticator_validate_stage_request: PatchedAuthenticatorValidateStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_validate_stage_request=patched_authenticator_validate_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_validate_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + patched_authenticator_validate_stage_request: Optional[PatchedAuthenticatorValidateStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorValidateStage]: + """stages_authenticator_validate_partial_update + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_validate_stage_request: + :type patched_authenticator_validate_stage_request: PatchedAuthenticatorValidateStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_validate_stage_request=patched_authenticator_validate_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_validate_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + patched_authenticator_validate_stage_request: Optional[PatchedAuthenticatorValidateStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_validate_partial_update + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_validate_stage_request: + :type patched_authenticator_validate_stage_request: PatchedAuthenticatorValidateStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_validate_stage_request=patched_authenticator_validate_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_validate_partial_update_serialize( + self, + stage_uuid, + patched_authenticator_validate_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_authenticator_validate_stage_request is not None: + _body_params = patched_authenticator_validate_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/authenticator/validate/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_validate_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorValidateStage: + """stages_authenticator_validate_retrieve + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_validate_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorValidateStage]: + """stages_authenticator_validate_retrieve + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_validate_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_validate_retrieve + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_validate_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/validate/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_validate_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + authenticator_validate_stage_request: AuthenticatorValidateStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorValidateStage: + """stages_authenticator_validate_update + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param authenticator_validate_stage_request: (required) + :type authenticator_validate_stage_request: AuthenticatorValidateStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_update_serialize( + stage_uuid=stage_uuid, + authenticator_validate_stage_request=authenticator_validate_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_validate_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + authenticator_validate_stage_request: AuthenticatorValidateStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorValidateStage]: + """stages_authenticator_validate_update + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param authenticator_validate_stage_request: (required) + :type authenticator_validate_stage_request: AuthenticatorValidateStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_update_serialize( + stage_uuid=stage_uuid, + authenticator_validate_stage_request=authenticator_validate_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_validate_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + authenticator_validate_stage_request: AuthenticatorValidateStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_validate_update + + AuthenticatorValidateStage Viewset + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param authenticator_validate_stage_request: (required) + :type authenticator_validate_stage_request: AuthenticatorValidateStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_update_serialize( + stage_uuid=stage_uuid, + authenticator_validate_stage_request=authenticator_validate_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorValidateStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_validate_update_serialize( + self, + stage_uuid, + authenticator_validate_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_validate_stage_request is not None: + _body_params = authenticator_validate_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/authenticator/validate/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_validate_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_authenticator_validate_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_validate_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_authenticator_validate_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_validate_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Authenticator Validation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_validate_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Authenticator Validation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_validate_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_validate_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/validate/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_webauthn_create( + self, + authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorWebAuthnStage: + """stages_authenticator_webauthn_create + + AuthenticatorWebAuthnStage Viewset + + :param authenticator_web_authn_stage_request: (required) + :type authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_create_serialize( + authenticator_web_authn_stage_request=authenticator_web_authn_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_webauthn_create_with_http_info( + self, + authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorWebAuthnStage]: + """stages_authenticator_webauthn_create + + AuthenticatorWebAuthnStage Viewset + + :param authenticator_web_authn_stage_request: (required) + :type authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_create_serialize( + authenticator_web_authn_stage_request=authenticator_web_authn_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_webauthn_create_without_preload_content( + self, + authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_webauthn_create + + AuthenticatorWebAuthnStage Viewset + + :param authenticator_web_authn_stage_request: (required) + :type authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_create_serialize( + authenticator_web_authn_stage_request=authenticator_web_authn_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_webauthn_create_serialize( + self, + authenticator_web_authn_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_web_authn_stage_request is not None: + _body_params = authenticator_web_authn_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/authenticator/webauthn/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_webauthn_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_authenticator_webauthn_destroy + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_webauthn_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_authenticator_webauthn_destroy + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_webauthn_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_webauthn_destroy + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_webauthn_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/authenticator/webauthn/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_webauthn_device_types_list( + self, + aaguid: Optional[UUID] = None, + description: Optional[StrictStr] = None, + icon: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedWebAuthnDeviceTypeList: + """stages_authenticator_webauthn_device_types_list + + WebAuthnDeviceType Viewset + + :param aaguid: + :type aaguid: UUID + :param description: + :type description: str + :param icon: + :type icon: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_device_types_list_serialize( + aaguid=aaguid, + description=description, + icon=icon, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWebAuthnDeviceTypeList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_webauthn_device_types_list_with_http_info( + self, + aaguid: Optional[UUID] = None, + description: Optional[StrictStr] = None, + icon: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedWebAuthnDeviceTypeList]: + """stages_authenticator_webauthn_device_types_list + + WebAuthnDeviceType Viewset + + :param aaguid: + :type aaguid: UUID + :param description: + :type description: str + :param icon: + :type icon: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_device_types_list_serialize( + aaguid=aaguid, + description=description, + icon=icon, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWebAuthnDeviceTypeList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_webauthn_device_types_list_without_preload_content( + self, + aaguid: Optional[UUID] = None, + description: Optional[StrictStr] = None, + icon: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_webauthn_device_types_list + + WebAuthnDeviceType Viewset + + :param aaguid: + :type aaguid: UUID + :param description: + :type description: str + :param icon: + :type icon: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_device_types_list_serialize( + aaguid=aaguid, + description=description, + icon=icon, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedWebAuthnDeviceTypeList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_webauthn_device_types_list_serialize( + self, + aaguid, + description, + icon, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if aaguid is not None: + + _query_params.append(('aaguid', aaguid)) + + if description is not None: + + _query_params.append(('description', description)) + + if icon is not None: + + _query_params.append(('icon', icon)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/webauthn_device_types/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_webauthn_device_types_retrieve( + self, + aaguid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Device type.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> WebAuthnDeviceType: + """stages_authenticator_webauthn_device_types_retrieve + + WebAuthnDeviceType Viewset + + :param aaguid: A UUID string identifying this WebAuthn Device type. (required) + :type aaguid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_device_types_retrieve_serialize( + aaguid=aaguid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDeviceType", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_webauthn_device_types_retrieve_with_http_info( + self, + aaguid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Device type.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[WebAuthnDeviceType]: + """stages_authenticator_webauthn_device_types_retrieve + + WebAuthnDeviceType Viewset + + :param aaguid: A UUID string identifying this WebAuthn Device type. (required) + :type aaguid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_device_types_retrieve_serialize( + aaguid=aaguid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDeviceType", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_webauthn_device_types_retrieve_without_preload_content( + self, + aaguid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Device type.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_webauthn_device_types_retrieve + + WebAuthnDeviceType Viewset + + :param aaguid: A UUID string identifying this WebAuthn Device type. (required) + :type aaguid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_device_types_retrieve_serialize( + aaguid=aaguid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "WebAuthnDeviceType", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_webauthn_device_types_retrieve_serialize( + self, + aaguid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if aaguid is not None: + _path_params['aaguid'] = aaguid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/webauthn_device_types/{aaguid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_webauthn_list( + self, + authenticator_attachment: Optional[Any] = None, + configure_flow: Optional[UUID] = None, + device_type_restrictions: Optional[List[UUID]] = None, + max_attempts: Optional[StrictInt] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + resident_key_requirement: Optional[UserVerificationEnum] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user_verification: Optional[UserVerificationEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedAuthenticatorWebAuthnStageList: + """stages_authenticator_webauthn_list + + AuthenticatorWebAuthnStage Viewset + + :param authenticator_attachment: + :type authenticator_attachment: AuthenticatorAttachmentEnum + :param configure_flow: + :type configure_flow: UUID + :param device_type_restrictions: + :type device_type_restrictions: List[UUID] + :param max_attempts: + :type max_attempts: int + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param resident_key_requirement: + :type resident_key_requirement: UserVerificationEnum + :param search: A search term. + :type search: str + :param user_verification: + :type user_verification: UserVerificationEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_list_serialize( + authenticator_attachment=authenticator_attachment, + configure_flow=configure_flow, + device_type_restrictions=device_type_restrictions, + max_attempts=max_attempts, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + resident_key_requirement=resident_key_requirement, + search=search, + user_verification=user_verification, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorWebAuthnStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_webauthn_list_with_http_info( + self, + authenticator_attachment: Optional[Any] = None, + configure_flow: Optional[UUID] = None, + device_type_restrictions: Optional[List[UUID]] = None, + max_attempts: Optional[StrictInt] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + resident_key_requirement: Optional[UserVerificationEnum] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user_verification: Optional[UserVerificationEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedAuthenticatorWebAuthnStageList]: + """stages_authenticator_webauthn_list + + AuthenticatorWebAuthnStage Viewset + + :param authenticator_attachment: + :type authenticator_attachment: AuthenticatorAttachmentEnum + :param configure_flow: + :type configure_flow: UUID + :param device_type_restrictions: + :type device_type_restrictions: List[UUID] + :param max_attempts: + :type max_attempts: int + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param resident_key_requirement: + :type resident_key_requirement: UserVerificationEnum + :param search: A search term. + :type search: str + :param user_verification: + :type user_verification: UserVerificationEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_list_serialize( + authenticator_attachment=authenticator_attachment, + configure_flow=configure_flow, + device_type_restrictions=device_type_restrictions, + max_attempts=max_attempts, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + resident_key_requirement=resident_key_requirement, + search=search, + user_verification=user_verification, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorWebAuthnStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_webauthn_list_without_preload_content( + self, + authenticator_attachment: Optional[Any] = None, + configure_flow: Optional[UUID] = None, + device_type_restrictions: Optional[List[UUID]] = None, + max_attempts: Optional[StrictInt] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + resident_key_requirement: Optional[UserVerificationEnum] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + user_verification: Optional[UserVerificationEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_webauthn_list + + AuthenticatorWebAuthnStage Viewset + + :param authenticator_attachment: + :type authenticator_attachment: AuthenticatorAttachmentEnum + :param configure_flow: + :type configure_flow: UUID + :param device_type_restrictions: + :type device_type_restrictions: List[UUID] + :param max_attempts: + :type max_attempts: int + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param resident_key_requirement: + :type resident_key_requirement: UserVerificationEnum + :param search: A search term. + :type search: str + :param user_verification: + :type user_verification: UserVerificationEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_list_serialize( + authenticator_attachment=authenticator_attachment, + configure_flow=configure_flow, + device_type_restrictions=device_type_restrictions, + max_attempts=max_attempts, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + resident_key_requirement=resident_key_requirement, + search=search, + user_verification=user_verification, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedAuthenticatorWebAuthnStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_webauthn_list_serialize( + self, + authenticator_attachment, + configure_flow, + device_type_restrictions, + max_attempts, + name, + ordering, + page, + page_size, + resident_key_requirement, + search, + user_verification, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'device_type_restrictions': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if authenticator_attachment is not None: + + _query_params.append(('authenticator_attachment', authenticator_attachment.value)) + + if configure_flow is not None: + + _query_params.append(('configure_flow', configure_flow)) + + if device_type_restrictions is not None: + + _query_params.append(('device_type_restrictions', device_type_restrictions)) + + if max_attempts is not None: + + _query_params.append(('max_attempts', max_attempts)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if resident_key_requirement is not None: + + _query_params.append(('resident_key_requirement', resident_key_requirement.value)) + + if search is not None: + + _query_params.append(('search', search)) + + if user_verification is not None: + + _query_params.append(('user_verification', user_verification.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/webauthn/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_webauthn_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + patched_authenticator_web_authn_stage_request: Optional[PatchedAuthenticatorWebAuthnStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorWebAuthnStage: + """stages_authenticator_webauthn_partial_update + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_web_authn_stage_request: + :type patched_authenticator_web_authn_stage_request: PatchedAuthenticatorWebAuthnStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_web_authn_stage_request=patched_authenticator_web_authn_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_webauthn_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + patched_authenticator_web_authn_stage_request: Optional[PatchedAuthenticatorWebAuthnStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorWebAuthnStage]: + """stages_authenticator_webauthn_partial_update + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_web_authn_stage_request: + :type patched_authenticator_web_authn_stage_request: PatchedAuthenticatorWebAuthnStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_web_authn_stage_request=patched_authenticator_web_authn_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_webauthn_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + patched_authenticator_web_authn_stage_request: Optional[PatchedAuthenticatorWebAuthnStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_webauthn_partial_update + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param patched_authenticator_web_authn_stage_request: + :type patched_authenticator_web_authn_stage_request: PatchedAuthenticatorWebAuthnStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_partial_update_serialize( + stage_uuid=stage_uuid, + patched_authenticator_web_authn_stage_request=patched_authenticator_web_authn_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_webauthn_partial_update_serialize( + self, + stage_uuid, + patched_authenticator_web_authn_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_authenticator_web_authn_stage_request is not None: + _body_params = patched_authenticator_web_authn_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/authenticator/webauthn/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_webauthn_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorWebAuthnStage: + """stages_authenticator_webauthn_retrieve + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_webauthn_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorWebAuthnStage]: + """stages_authenticator_webauthn_retrieve + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_webauthn_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_webauthn_retrieve + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_webauthn_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/webauthn/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_webauthn_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> AuthenticatorWebAuthnStage: + """stages_authenticator_webauthn_update + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_web_authn_stage_request: (required) + :type authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_update_serialize( + stage_uuid=stage_uuid, + authenticator_web_authn_stage_request=authenticator_web_authn_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_webauthn_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[AuthenticatorWebAuthnStage]: + """stages_authenticator_webauthn_update + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_web_authn_stage_request: (required) + :type authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_update_serialize( + stage_uuid=stage_uuid, + authenticator_web_authn_stage_request=authenticator_web_authn_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_webauthn_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_webauthn_update + + AuthenticatorWebAuthnStage Viewset + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param authenticator_web_authn_stage_request: (required) + :type authenticator_web_authn_stage_request: AuthenticatorWebAuthnStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_update_serialize( + stage_uuid=stage_uuid, + authenticator_web_authn_stage_request=authenticator_web_authn_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "AuthenticatorWebAuthnStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_webauthn_update_serialize( + self, + stage_uuid, + authenticator_web_authn_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if authenticator_web_authn_stage_request is not None: + _body_params = authenticator_web_authn_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/authenticator/webauthn/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_authenticator_webauthn_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_authenticator_webauthn_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_authenticator_webauthn_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_authenticator_webauthn_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_authenticator_webauthn_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this WebAuthn Authenticator Setup Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_authenticator_webauthn_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this WebAuthn Authenticator Setup Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_authenticator_webauthn_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_authenticator_webauthn_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/authenticator/webauthn/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_captcha_create( + self, + captcha_stage_request: CaptchaStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CaptchaStage: + """stages_captcha_create + + CaptchaStage Viewset + + :param captcha_stage_request: (required) + :type captcha_stage_request: CaptchaStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_create_serialize( + captcha_stage_request=captcha_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_captcha_create_with_http_info( + self, + captcha_stage_request: CaptchaStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CaptchaStage]: + """stages_captcha_create + + CaptchaStage Viewset + + :param captcha_stage_request: (required) + :type captcha_stage_request: CaptchaStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_create_serialize( + captcha_stage_request=captcha_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_captcha_create_without_preload_content( + self, + captcha_stage_request: CaptchaStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_captcha_create + + CaptchaStage Viewset + + :param captcha_stage_request: (required) + :type captcha_stage_request: CaptchaStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_create_serialize( + captcha_stage_request=captcha_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_captcha_create_serialize( + self, + captcha_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if captcha_stage_request is not None: + _body_params = captcha_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/captcha/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_captcha_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_captcha_destroy + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_captcha_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_captcha_destroy + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_captcha_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_captcha_destroy + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_captcha_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/captcha/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_captcha_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + public_key: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedCaptchaStageList: + """stages_captcha_list + + CaptchaStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param public_key: + :type public_key: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + public_key=public_key, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedCaptchaStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_captcha_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + public_key: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedCaptchaStageList]: + """stages_captcha_list + + CaptchaStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param public_key: + :type public_key: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + public_key=public_key, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedCaptchaStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_captcha_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + public_key: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_captcha_list + + CaptchaStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param public_key: + :type public_key: str + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + public_key=public_key, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedCaptchaStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_captcha_list_serialize( + self, + name, + ordering, + page, + page_size, + public_key, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if public_key is not None: + + _query_params.append(('public_key', public_key)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/captcha/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_captcha_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + patched_captcha_stage_request: Optional[PatchedCaptchaStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CaptchaStage: + """stages_captcha_partial_update + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param patched_captcha_stage_request: + :type patched_captcha_stage_request: PatchedCaptchaStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_partial_update_serialize( + stage_uuid=stage_uuid, + patched_captcha_stage_request=patched_captcha_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_captcha_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + patched_captcha_stage_request: Optional[PatchedCaptchaStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CaptchaStage]: + """stages_captcha_partial_update + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param patched_captcha_stage_request: + :type patched_captcha_stage_request: PatchedCaptchaStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_partial_update_serialize( + stage_uuid=stage_uuid, + patched_captcha_stage_request=patched_captcha_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_captcha_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + patched_captcha_stage_request: Optional[PatchedCaptchaStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_captcha_partial_update + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param patched_captcha_stage_request: + :type patched_captcha_stage_request: PatchedCaptchaStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_partial_update_serialize( + stage_uuid=stage_uuid, + patched_captcha_stage_request=patched_captcha_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_captcha_partial_update_serialize( + self, + stage_uuid, + patched_captcha_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_captcha_stage_request is not None: + _body_params = patched_captcha_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/captcha/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_captcha_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CaptchaStage: + """stages_captcha_retrieve + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_captcha_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CaptchaStage]: + """stages_captcha_retrieve + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_captcha_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_captcha_retrieve + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_captcha_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/captcha/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_captcha_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + captcha_stage_request: CaptchaStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> CaptchaStage: + """stages_captcha_update + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param captcha_stage_request: (required) + :type captcha_stage_request: CaptchaStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_update_serialize( + stage_uuid=stage_uuid, + captcha_stage_request=captcha_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_captcha_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + captcha_stage_request: CaptchaStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[CaptchaStage]: + """stages_captcha_update + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param captcha_stage_request: (required) + :type captcha_stage_request: CaptchaStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_update_serialize( + stage_uuid=stage_uuid, + captcha_stage_request=captcha_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_captcha_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + captcha_stage_request: CaptchaStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_captcha_update + + CaptchaStage Viewset + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param captcha_stage_request: (required) + :type captcha_stage_request: CaptchaStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_update_serialize( + stage_uuid=stage_uuid, + captcha_stage_request=captcha_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "CaptchaStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_captcha_update_serialize( + self, + stage_uuid, + captcha_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if captcha_stage_request is not None: + _body_params = captcha_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/captcha/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_captcha_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_captcha_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_captcha_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_captcha_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_captcha_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Captcha Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_captcha_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Captcha Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_captcha_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_captcha_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/captcha/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_consent_create( + self, + consent_stage_request: ConsentStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ConsentStage: + """stages_consent_create + + ConsentStage Viewset + + :param consent_stage_request: (required) + :type consent_stage_request: ConsentStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_create_serialize( + consent_stage_request=consent_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_consent_create_with_http_info( + self, + consent_stage_request: ConsentStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ConsentStage]: + """stages_consent_create + + ConsentStage Viewset + + :param consent_stage_request: (required) + :type consent_stage_request: ConsentStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_create_serialize( + consent_stage_request=consent_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_consent_create_without_preload_content( + self, + consent_stage_request: ConsentStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_consent_create + + ConsentStage Viewset + + :param consent_stage_request: (required) + :type consent_stage_request: ConsentStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_create_serialize( + consent_stage_request=consent_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_consent_create_serialize( + self, + consent_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if consent_stage_request is not None: + _body_params = consent_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/consent/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_consent_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_consent_destroy + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_consent_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_consent_destroy + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_consent_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_consent_destroy + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_consent_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/consent/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_consent_list( + self, + consent_expire_in: Optional[StrictStr] = None, + mode: Optional[ConsentModeEnum] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedConsentStageList: + """stages_consent_list + + ConsentStage Viewset + + :param consent_expire_in: + :type consent_expire_in: str + :param mode: + :type mode: ConsentModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_list_serialize( + consent_expire_in=consent_expire_in, + mode=mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedConsentStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_consent_list_with_http_info( + self, + consent_expire_in: Optional[StrictStr] = None, + mode: Optional[ConsentModeEnum] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedConsentStageList]: + """stages_consent_list + + ConsentStage Viewset + + :param consent_expire_in: + :type consent_expire_in: str + :param mode: + :type mode: ConsentModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_list_serialize( + consent_expire_in=consent_expire_in, + mode=mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedConsentStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_consent_list_without_preload_content( + self, + consent_expire_in: Optional[StrictStr] = None, + mode: Optional[ConsentModeEnum] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_consent_list + + ConsentStage Viewset + + :param consent_expire_in: + :type consent_expire_in: str + :param mode: + :type mode: ConsentModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_list_serialize( + consent_expire_in=consent_expire_in, + mode=mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedConsentStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_consent_list_serialize( + self, + consent_expire_in, + mode, + name, + ordering, + page, + page_size, + search, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if consent_expire_in is not None: + + _query_params.append(('consent_expire_in', consent_expire_in)) + + if mode is not None: + + _query_params.append(('mode', mode.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/consent/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_consent_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + patched_consent_stage_request: Optional[PatchedConsentStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ConsentStage: + """stages_consent_partial_update + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param patched_consent_stage_request: + :type patched_consent_stage_request: PatchedConsentStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_partial_update_serialize( + stage_uuid=stage_uuid, + patched_consent_stage_request=patched_consent_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_consent_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + patched_consent_stage_request: Optional[PatchedConsentStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ConsentStage]: + """stages_consent_partial_update + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param patched_consent_stage_request: + :type patched_consent_stage_request: PatchedConsentStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_partial_update_serialize( + stage_uuid=stage_uuid, + patched_consent_stage_request=patched_consent_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_consent_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + patched_consent_stage_request: Optional[PatchedConsentStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_consent_partial_update + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param patched_consent_stage_request: + :type patched_consent_stage_request: PatchedConsentStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_partial_update_serialize( + stage_uuid=stage_uuid, + patched_consent_stage_request=patched_consent_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_consent_partial_update_serialize( + self, + stage_uuid, + patched_consent_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_consent_stage_request is not None: + _body_params = patched_consent_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/consent/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_consent_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ConsentStage: + """stages_consent_retrieve + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_consent_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ConsentStage]: + """stages_consent_retrieve + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_consent_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_consent_retrieve + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_consent_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/consent/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_consent_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + consent_stage_request: ConsentStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ConsentStage: + """stages_consent_update + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param consent_stage_request: (required) + :type consent_stage_request: ConsentStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_update_serialize( + stage_uuid=stage_uuid, + consent_stage_request=consent_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_consent_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + consent_stage_request: ConsentStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ConsentStage]: + """stages_consent_update + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param consent_stage_request: (required) + :type consent_stage_request: ConsentStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_update_serialize( + stage_uuid=stage_uuid, + consent_stage_request=consent_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_consent_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + consent_stage_request: ConsentStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_consent_update + + ConsentStage Viewset + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param consent_stage_request: (required) + :type consent_stage_request: ConsentStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_update_serialize( + stage_uuid=stage_uuid, + consent_stage_request=consent_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ConsentStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_consent_update_serialize( + self, + stage_uuid, + consent_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if consent_stage_request is not None: + _body_params = consent_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/consent/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_consent_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_consent_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_consent_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_consent_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_consent_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Consent Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_consent_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Consent Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_consent_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_consent_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/consent/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_deny_create( + self, + deny_stage_request: DenyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DenyStage: + """stages_deny_create + + DenyStage Viewset + + :param deny_stage_request: (required) + :type deny_stage_request: DenyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_create_serialize( + deny_stage_request=deny_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_deny_create_with_http_info( + self, + deny_stage_request: DenyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DenyStage]: + """stages_deny_create + + DenyStage Viewset + + :param deny_stage_request: (required) + :type deny_stage_request: DenyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_create_serialize( + deny_stage_request=deny_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_deny_create_without_preload_content( + self, + deny_stage_request: DenyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_deny_create + + DenyStage Viewset + + :param deny_stage_request: (required) + :type deny_stage_request: DenyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_create_serialize( + deny_stage_request=deny_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_deny_create_serialize( + self, + deny_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if deny_stage_request is not None: + _body_params = deny_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/deny/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_deny_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_deny_destroy + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_deny_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_deny_destroy + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_deny_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_deny_destroy + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_deny_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/deny/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_deny_list( + self, + deny_message: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDenyStageList: + """stages_deny_list + + DenyStage Viewset + + :param deny_message: + :type deny_message: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_list_serialize( + deny_message=deny_message, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDenyStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_deny_list_with_http_info( + self, + deny_message: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDenyStageList]: + """stages_deny_list + + DenyStage Viewset + + :param deny_message: + :type deny_message: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_list_serialize( + deny_message=deny_message, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDenyStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_deny_list_without_preload_content( + self, + deny_message: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_deny_list + + DenyStage Viewset + + :param deny_message: + :type deny_message: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_list_serialize( + deny_message=deny_message, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDenyStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_deny_list_serialize( + self, + deny_message, + name, + ordering, + page, + page_size, + search, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if deny_message is not None: + + _query_params.append(('deny_message', deny_message)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/deny/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_deny_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + patched_deny_stage_request: Optional[PatchedDenyStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DenyStage: + """stages_deny_partial_update + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param patched_deny_stage_request: + :type patched_deny_stage_request: PatchedDenyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_partial_update_serialize( + stage_uuid=stage_uuid, + patched_deny_stage_request=patched_deny_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_deny_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + patched_deny_stage_request: Optional[PatchedDenyStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DenyStage]: + """stages_deny_partial_update + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param patched_deny_stage_request: + :type patched_deny_stage_request: PatchedDenyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_partial_update_serialize( + stage_uuid=stage_uuid, + patched_deny_stage_request=patched_deny_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_deny_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + patched_deny_stage_request: Optional[PatchedDenyStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_deny_partial_update + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param patched_deny_stage_request: + :type patched_deny_stage_request: PatchedDenyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_partial_update_serialize( + stage_uuid=stage_uuid, + patched_deny_stage_request=patched_deny_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_deny_partial_update_serialize( + self, + stage_uuid, + patched_deny_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_deny_stage_request is not None: + _body_params = patched_deny_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/deny/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_deny_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DenyStage: + """stages_deny_retrieve + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_deny_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DenyStage]: + """stages_deny_retrieve + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_deny_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_deny_retrieve + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_deny_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/deny/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_deny_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + deny_stage_request: DenyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DenyStage: + """stages_deny_update + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param deny_stage_request: (required) + :type deny_stage_request: DenyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_update_serialize( + stage_uuid=stage_uuid, + deny_stage_request=deny_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_deny_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + deny_stage_request: DenyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DenyStage]: + """stages_deny_update + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param deny_stage_request: (required) + :type deny_stage_request: DenyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_update_serialize( + stage_uuid=stage_uuid, + deny_stage_request=deny_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_deny_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + deny_stage_request: DenyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_deny_update + + DenyStage Viewset + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param deny_stage_request: (required) + :type deny_stage_request: DenyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_update_serialize( + stage_uuid=stage_uuid, + deny_stage_request=deny_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DenyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_deny_update_serialize( + self, + stage_uuid, + deny_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if deny_stage_request is not None: + _body_params = deny_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/deny/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_deny_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_deny_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_deny_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_deny_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_deny_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Deny Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_deny_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Deny Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_deny_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_deny_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/deny/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_dummy_create( + self, + dummy_stage_request: DummyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DummyStage: + """stages_dummy_create + + DummyStage Viewset + + :param dummy_stage_request: (required) + :type dummy_stage_request: DummyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_create_serialize( + dummy_stage_request=dummy_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_dummy_create_with_http_info( + self, + dummy_stage_request: DummyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DummyStage]: + """stages_dummy_create + + DummyStage Viewset + + :param dummy_stage_request: (required) + :type dummy_stage_request: DummyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_create_serialize( + dummy_stage_request=dummy_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_dummy_create_without_preload_content( + self, + dummy_stage_request: DummyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_dummy_create + + DummyStage Viewset + + :param dummy_stage_request: (required) + :type dummy_stage_request: DummyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_create_serialize( + dummy_stage_request=dummy_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_dummy_create_serialize( + self, + dummy_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if dummy_stage_request is not None: + _body_params = dummy_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/dummy/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_dummy_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_dummy_destroy + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_dummy_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_dummy_destroy + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_dummy_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_dummy_destroy + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_dummy_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/dummy/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_dummy_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + throw_error: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDummyStageList: + """stages_dummy_list + + DummyStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param throw_error: + :type throw_error: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + throw_error=throw_error, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDummyStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_dummy_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + throw_error: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDummyStageList]: + """stages_dummy_list + + DummyStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param throw_error: + :type throw_error: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + throw_error=throw_error, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDummyStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_dummy_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + throw_error: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_dummy_list + + DummyStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param throw_error: + :type throw_error: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + throw_error=throw_error, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDummyStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_dummy_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + stage_uuid, + throw_error, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + if throw_error is not None: + + _query_params.append(('throw_error', throw_error)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/dummy/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_dummy_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + patched_dummy_stage_request: Optional[PatchedDummyStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DummyStage: + """stages_dummy_partial_update + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param patched_dummy_stage_request: + :type patched_dummy_stage_request: PatchedDummyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_partial_update_serialize( + stage_uuid=stage_uuid, + patched_dummy_stage_request=patched_dummy_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_dummy_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + patched_dummy_stage_request: Optional[PatchedDummyStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DummyStage]: + """stages_dummy_partial_update + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param patched_dummy_stage_request: + :type patched_dummy_stage_request: PatchedDummyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_partial_update_serialize( + stage_uuid=stage_uuid, + patched_dummy_stage_request=patched_dummy_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_dummy_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + patched_dummy_stage_request: Optional[PatchedDummyStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_dummy_partial_update + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param patched_dummy_stage_request: + :type patched_dummy_stage_request: PatchedDummyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_partial_update_serialize( + stage_uuid=stage_uuid, + patched_dummy_stage_request=patched_dummy_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_dummy_partial_update_serialize( + self, + stage_uuid, + patched_dummy_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_dummy_stage_request is not None: + _body_params = patched_dummy_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/dummy/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_dummy_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DummyStage: + """stages_dummy_retrieve + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_dummy_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DummyStage]: + """stages_dummy_retrieve + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_dummy_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_dummy_retrieve + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_dummy_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/dummy/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_dummy_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + dummy_stage_request: DummyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> DummyStage: + """stages_dummy_update + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param dummy_stage_request: (required) + :type dummy_stage_request: DummyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_update_serialize( + stage_uuid=stage_uuid, + dummy_stage_request=dummy_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_dummy_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + dummy_stage_request: DummyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[DummyStage]: + """stages_dummy_update + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param dummy_stage_request: (required) + :type dummy_stage_request: DummyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_update_serialize( + stage_uuid=stage_uuid, + dummy_stage_request=dummy_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_dummy_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + dummy_stage_request: DummyStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_dummy_update + + DummyStage Viewset + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param dummy_stage_request: (required) + :type dummy_stage_request: DummyStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_update_serialize( + stage_uuid=stage_uuid, + dummy_stage_request=dummy_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "DummyStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_dummy_update_serialize( + self, + stage_uuid, + dummy_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if dummy_stage_request is not None: + _body_params = dummy_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/dummy/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_dummy_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_dummy_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_dummy_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_dummy_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_dummy_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Dummy Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_dummy_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Dummy Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_dummy_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_dummy_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/dummy/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_email_create( + self, + email_stage_request: EmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailStage: + """stages_email_create + + EmailStage Viewset + + :param email_stage_request: (required) + :type email_stage_request: EmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_create_serialize( + email_stage_request=email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_email_create_with_http_info( + self, + email_stage_request: EmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailStage]: + """stages_email_create + + EmailStage Viewset + + :param email_stage_request: (required) + :type email_stage_request: EmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_create_serialize( + email_stage_request=email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_email_create_without_preload_content( + self, + email_stage_request: EmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_email_create + + EmailStage Viewset + + :param email_stage_request: (required) + :type email_stage_request: EmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_create_serialize( + email_stage_request=email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_email_create_serialize( + self, + email_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if email_stage_request is not None: + _body_params = email_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/email/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_email_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_email_destroy + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_email_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_email_destroy + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_email_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_email_destroy + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_email_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/email/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_email_list( + self, + activate_user_on_success: Optional[StrictBool] = None, + from_address: Optional[StrictStr] = None, + host: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + port: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + subject: Optional[StrictStr] = None, + template: Optional[StrictStr] = None, + timeout: Optional[StrictInt] = None, + token_expiry: Optional[StrictStr] = None, + use_global_settings: Optional[StrictBool] = None, + use_ssl: Optional[StrictBool] = None, + use_tls: Optional[StrictBool] = None, + username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedEmailStageList: + """stages_email_list + + EmailStage Viewset + + :param activate_user_on_success: + :type activate_user_on_success: bool + :param from_address: + :type from_address: str + :param host: + :type host: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param port: + :type port: int + :param search: A search term. + :type search: str + :param subject: + :type subject: str + :param template: + :type template: str + :param timeout: + :type timeout: int + :param token_expiry: + :type token_expiry: str + :param use_global_settings: + :type use_global_settings: bool + :param use_ssl: + :type use_ssl: bool + :param use_tls: + :type use_tls: bool + :param username: + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_list_serialize( + activate_user_on_success=activate_user_on_success, + from_address=from_address, + host=host, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + port=port, + search=search, + subject=subject, + template=template, + timeout=timeout, + token_expiry=token_expiry, + use_global_settings=use_global_settings, + use_ssl=use_ssl, + use_tls=use_tls, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEmailStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_email_list_with_http_info( + self, + activate_user_on_success: Optional[StrictBool] = None, + from_address: Optional[StrictStr] = None, + host: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + port: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + subject: Optional[StrictStr] = None, + template: Optional[StrictStr] = None, + timeout: Optional[StrictInt] = None, + token_expiry: Optional[StrictStr] = None, + use_global_settings: Optional[StrictBool] = None, + use_ssl: Optional[StrictBool] = None, + use_tls: Optional[StrictBool] = None, + username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedEmailStageList]: + """stages_email_list + + EmailStage Viewset + + :param activate_user_on_success: + :type activate_user_on_success: bool + :param from_address: + :type from_address: str + :param host: + :type host: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param port: + :type port: int + :param search: A search term. + :type search: str + :param subject: + :type subject: str + :param template: + :type template: str + :param timeout: + :type timeout: int + :param token_expiry: + :type token_expiry: str + :param use_global_settings: + :type use_global_settings: bool + :param use_ssl: + :type use_ssl: bool + :param use_tls: + :type use_tls: bool + :param username: + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_list_serialize( + activate_user_on_success=activate_user_on_success, + from_address=from_address, + host=host, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + port=port, + search=search, + subject=subject, + template=template, + timeout=timeout, + token_expiry=token_expiry, + use_global_settings=use_global_settings, + use_ssl=use_ssl, + use_tls=use_tls, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEmailStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_email_list_without_preload_content( + self, + activate_user_on_success: Optional[StrictBool] = None, + from_address: Optional[StrictStr] = None, + host: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + port: Optional[StrictInt] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + subject: Optional[StrictStr] = None, + template: Optional[StrictStr] = None, + timeout: Optional[StrictInt] = None, + token_expiry: Optional[StrictStr] = None, + use_global_settings: Optional[StrictBool] = None, + use_ssl: Optional[StrictBool] = None, + use_tls: Optional[StrictBool] = None, + username: Optional[StrictStr] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_email_list + + EmailStage Viewset + + :param activate_user_on_success: + :type activate_user_on_success: bool + :param from_address: + :type from_address: str + :param host: + :type host: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param port: + :type port: int + :param search: A search term. + :type search: str + :param subject: + :type subject: str + :param template: + :type template: str + :param timeout: + :type timeout: int + :param token_expiry: + :type token_expiry: str + :param use_global_settings: + :type use_global_settings: bool + :param use_ssl: + :type use_ssl: bool + :param use_tls: + :type use_tls: bool + :param username: + :type username: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_list_serialize( + activate_user_on_success=activate_user_on_success, + from_address=from_address, + host=host, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + port=port, + search=search, + subject=subject, + template=template, + timeout=timeout, + token_expiry=token_expiry, + use_global_settings=use_global_settings, + use_ssl=use_ssl, + use_tls=use_tls, + username=username, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEmailStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_email_list_serialize( + self, + activate_user_on_success, + from_address, + host, + name, + ordering, + page, + page_size, + port, + search, + subject, + template, + timeout, + token_expiry, + use_global_settings, + use_ssl, + use_tls, + username, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if activate_user_on_success is not None: + + _query_params.append(('activate_user_on_success', activate_user_on_success)) + + if from_address is not None: + + _query_params.append(('from_address', from_address)) + + if host is not None: + + _query_params.append(('host', host)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if port is not None: + + _query_params.append(('port', port)) + + if search is not None: + + _query_params.append(('search', search)) + + if subject is not None: + + _query_params.append(('subject', subject)) + + if template is not None: + + _query_params.append(('template', template)) + + if timeout is not None: + + _query_params.append(('timeout', timeout)) + + if token_expiry is not None: + + _query_params.append(('token_expiry', token_expiry)) + + if use_global_settings is not None: + + _query_params.append(('use_global_settings', use_global_settings)) + + if use_ssl is not None: + + _query_params.append(('use_ssl', use_ssl)) + + if use_tls is not None: + + _query_params.append(('use_tls', use_tls)) + + if username is not None: + + _query_params.append(('username', username)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/email/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_email_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + patched_email_stage_request: Optional[PatchedEmailStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailStage: + """stages_email_partial_update + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param patched_email_stage_request: + :type patched_email_stage_request: PatchedEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_partial_update_serialize( + stage_uuid=stage_uuid, + patched_email_stage_request=patched_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_email_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + patched_email_stage_request: Optional[PatchedEmailStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailStage]: + """stages_email_partial_update + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param patched_email_stage_request: + :type patched_email_stage_request: PatchedEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_partial_update_serialize( + stage_uuid=stage_uuid, + patched_email_stage_request=patched_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_email_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + patched_email_stage_request: Optional[PatchedEmailStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_email_partial_update + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param patched_email_stage_request: + :type patched_email_stage_request: PatchedEmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_partial_update_serialize( + stage_uuid=stage_uuid, + patched_email_stage_request=patched_email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_email_partial_update_serialize( + self, + stage_uuid, + patched_email_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_email_stage_request is not None: + _body_params = patched_email_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/email/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_email_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailStage: + """stages_email_retrieve + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_email_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailStage]: + """stages_email_retrieve + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_email_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_email_retrieve + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_email_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/email/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_email_templates_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[TypeCreate]: + """stages_email_templates_list + + Get all available templates, including custom templates + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_templates_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_email_templates_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[TypeCreate]]: + """stages_email_templates_list + + Get all available templates, including custom templates + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_templates_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_email_templates_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_email_templates_list + + Get all available templates, including custom templates + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_templates_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[TypeCreate]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_email_templates_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/email/templates/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_email_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + email_stage_request: EmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EmailStage: + """stages_email_update + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param email_stage_request: (required) + :type email_stage_request: EmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_update_serialize( + stage_uuid=stage_uuid, + email_stage_request=email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_email_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + email_stage_request: EmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EmailStage]: + """stages_email_update + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param email_stage_request: (required) + :type email_stage_request: EmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_update_serialize( + stage_uuid=stage_uuid, + email_stage_request=email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_email_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + email_stage_request: EmailStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_email_update + + EmailStage Viewset + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param email_stage_request: (required) + :type email_stage_request: EmailStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_update_serialize( + stage_uuid=stage_uuid, + email_stage_request=email_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EmailStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_email_update_serialize( + self, + stage_uuid, + email_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if email_stage_request is not None: + _body_params = email_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/email/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_email_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_email_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_email_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_email_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_email_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Email Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_email_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Email Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_email_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_email_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/email/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_endpoints_create( + self, + endpoint_stage_request: EndpointStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EndpointStage: + """stages_endpoints_create + + EndpointStage Viewset + + :param endpoint_stage_request: (required) + :type endpoint_stage_request: EndpointStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_create_serialize( + endpoint_stage_request=endpoint_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_endpoints_create_with_http_info( + self, + endpoint_stage_request: EndpointStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EndpointStage]: + """stages_endpoints_create + + EndpointStage Viewset + + :param endpoint_stage_request: (required) + :type endpoint_stage_request: EndpointStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_create_serialize( + endpoint_stage_request=endpoint_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_endpoints_create_without_preload_content( + self, + endpoint_stage_request: EndpointStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_endpoints_create + + EndpointStage Viewset + + :param endpoint_stage_request: (required) + :type endpoint_stage_request: EndpointStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_create_serialize( + endpoint_stage_request=endpoint_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_endpoints_create_serialize( + self, + endpoint_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if endpoint_stage_request is not None: + _body_params = endpoint_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/endpoints/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_endpoints_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_endpoints_destroy + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_endpoints_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_endpoints_destroy + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_endpoints_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_endpoints_destroy + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_endpoints_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/endpoints/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_endpoints_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedEndpointStageList: + """stages_endpoints_list + + EndpointStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEndpointStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_endpoints_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedEndpointStageList]: + """stages_endpoints_list + + EndpointStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEndpointStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_endpoints_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_endpoints_list + + EndpointStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedEndpointStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_endpoints_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/endpoints/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_endpoints_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + patched_endpoint_stage_request: Optional[PatchedEndpointStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EndpointStage: + """stages_endpoints_partial_update + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param patched_endpoint_stage_request: + :type patched_endpoint_stage_request: PatchedEndpointStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_partial_update_serialize( + stage_uuid=stage_uuid, + patched_endpoint_stage_request=patched_endpoint_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_endpoints_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + patched_endpoint_stage_request: Optional[PatchedEndpointStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EndpointStage]: + """stages_endpoints_partial_update + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param patched_endpoint_stage_request: + :type patched_endpoint_stage_request: PatchedEndpointStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_partial_update_serialize( + stage_uuid=stage_uuid, + patched_endpoint_stage_request=patched_endpoint_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_endpoints_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + patched_endpoint_stage_request: Optional[PatchedEndpointStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_endpoints_partial_update + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param patched_endpoint_stage_request: + :type patched_endpoint_stage_request: PatchedEndpointStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_partial_update_serialize( + stage_uuid=stage_uuid, + patched_endpoint_stage_request=patched_endpoint_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_endpoints_partial_update_serialize( + self, + stage_uuid, + patched_endpoint_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_endpoint_stage_request is not None: + _body_params = patched_endpoint_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/endpoints/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_endpoints_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EndpointStage: + """stages_endpoints_retrieve + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_endpoints_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EndpointStage]: + """stages_endpoints_retrieve + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_endpoints_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_endpoints_retrieve + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_endpoints_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/endpoints/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_endpoints_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + endpoint_stage_request: EndpointStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> EndpointStage: + """stages_endpoints_update + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param endpoint_stage_request: (required) + :type endpoint_stage_request: EndpointStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_update_serialize( + stage_uuid=stage_uuid, + endpoint_stage_request=endpoint_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_endpoints_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + endpoint_stage_request: EndpointStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[EndpointStage]: + """stages_endpoints_update + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param endpoint_stage_request: (required) + :type endpoint_stage_request: EndpointStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_update_serialize( + stage_uuid=stage_uuid, + endpoint_stage_request=endpoint_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_endpoints_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + endpoint_stage_request: EndpointStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_endpoints_update + + EndpointStage Viewset + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param endpoint_stage_request: (required) + :type endpoint_stage_request: EndpointStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_update_serialize( + stage_uuid=stage_uuid, + endpoint_stage_request=endpoint_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "EndpointStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_endpoints_update_serialize( + self, + stage_uuid, + endpoint_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if endpoint_stage_request is not None: + _body_params = endpoint_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/endpoints/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_endpoints_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_endpoints_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_endpoints_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_endpoints_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_endpoints_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Endpoint Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_endpoints_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Endpoint Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_endpoints_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_endpoints_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/endpoints/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_identification_create( + self, + identification_stage_request: IdentificationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> IdentificationStage: + """stages_identification_create + + IdentificationStage Viewset + + :param identification_stage_request: (required) + :type identification_stage_request: IdentificationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_create_serialize( + identification_stage_request=identification_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_identification_create_with_http_info( + self, + identification_stage_request: IdentificationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[IdentificationStage]: + """stages_identification_create + + IdentificationStage Viewset + + :param identification_stage_request: (required) + :type identification_stage_request: IdentificationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_create_serialize( + identification_stage_request=identification_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_identification_create_without_preload_content( + self, + identification_stage_request: IdentificationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_identification_create + + IdentificationStage Viewset + + :param identification_stage_request: (required) + :type identification_stage_request: IdentificationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_create_serialize( + identification_stage_request=identification_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_identification_create_serialize( + self, + identification_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if identification_stage_request is not None: + _body_params = identification_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/identification/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_identification_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_identification_destroy + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_identification_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_identification_destroy + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_identification_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_identification_destroy + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_identification_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/identification/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_identification_list( + self, + captcha_stage: Optional[UUID] = None, + case_insensitive_matching: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_stage: Optional[UUID] = None, + passwordless_flow: Optional[UUID] = None, + recovery_flow: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + show_matched_user: Optional[StrictBool] = None, + show_source_labels: Optional[StrictBool] = None, + webauthn_stage: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedIdentificationStageList: + """stages_identification_list + + IdentificationStage Viewset + + :param captcha_stage: + :type captcha_stage: UUID + :param case_insensitive_matching: + :type case_insensitive_matching: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_stage: + :type password_stage: UUID + :param passwordless_flow: + :type passwordless_flow: UUID + :param recovery_flow: + :type recovery_flow: UUID + :param search: A search term. + :type search: str + :param show_matched_user: + :type show_matched_user: bool + :param show_source_labels: + :type show_source_labels: bool + :param webauthn_stage: + :type webauthn_stage: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_list_serialize( + captcha_stage=captcha_stage, + case_insensitive_matching=case_insensitive_matching, + enrollment_flow=enrollment_flow, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password_stage=password_stage, + passwordless_flow=passwordless_flow, + recovery_flow=recovery_flow, + search=search, + show_matched_user=show_matched_user, + show_source_labels=show_source_labels, + webauthn_stage=webauthn_stage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedIdentificationStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_identification_list_with_http_info( + self, + captcha_stage: Optional[UUID] = None, + case_insensitive_matching: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_stage: Optional[UUID] = None, + passwordless_flow: Optional[UUID] = None, + recovery_flow: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + show_matched_user: Optional[StrictBool] = None, + show_source_labels: Optional[StrictBool] = None, + webauthn_stage: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedIdentificationStageList]: + """stages_identification_list + + IdentificationStage Viewset + + :param captcha_stage: + :type captcha_stage: UUID + :param case_insensitive_matching: + :type case_insensitive_matching: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_stage: + :type password_stage: UUID + :param passwordless_flow: + :type passwordless_flow: UUID + :param recovery_flow: + :type recovery_flow: UUID + :param search: A search term. + :type search: str + :param show_matched_user: + :type show_matched_user: bool + :param show_source_labels: + :type show_source_labels: bool + :param webauthn_stage: + :type webauthn_stage: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_list_serialize( + captcha_stage=captcha_stage, + case_insensitive_matching=case_insensitive_matching, + enrollment_flow=enrollment_flow, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password_stage=password_stage, + passwordless_flow=passwordless_flow, + recovery_flow=recovery_flow, + search=search, + show_matched_user=show_matched_user, + show_source_labels=show_source_labels, + webauthn_stage=webauthn_stage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedIdentificationStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_identification_list_without_preload_content( + self, + captcha_stage: Optional[UUID] = None, + case_insensitive_matching: Optional[StrictBool] = None, + enrollment_flow: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + password_stage: Optional[UUID] = None, + passwordless_flow: Optional[UUID] = None, + recovery_flow: Optional[UUID] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + show_matched_user: Optional[StrictBool] = None, + show_source_labels: Optional[StrictBool] = None, + webauthn_stage: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_identification_list + + IdentificationStage Viewset + + :param captcha_stage: + :type captcha_stage: UUID + :param case_insensitive_matching: + :type case_insensitive_matching: bool + :param enrollment_flow: + :type enrollment_flow: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param password_stage: + :type password_stage: UUID + :param passwordless_flow: + :type passwordless_flow: UUID + :param recovery_flow: + :type recovery_flow: UUID + :param search: A search term. + :type search: str + :param show_matched_user: + :type show_matched_user: bool + :param show_source_labels: + :type show_source_labels: bool + :param webauthn_stage: + :type webauthn_stage: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_list_serialize( + captcha_stage=captcha_stage, + case_insensitive_matching=case_insensitive_matching, + enrollment_flow=enrollment_flow, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + password_stage=password_stage, + passwordless_flow=passwordless_flow, + recovery_flow=recovery_flow, + search=search, + show_matched_user=show_matched_user, + show_source_labels=show_source_labels, + webauthn_stage=webauthn_stage, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedIdentificationStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_identification_list_serialize( + self, + captcha_stage, + case_insensitive_matching, + enrollment_flow, + name, + ordering, + page, + page_size, + password_stage, + passwordless_flow, + recovery_flow, + search, + show_matched_user, + show_source_labels, + webauthn_stage, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if captcha_stage is not None: + + _query_params.append(('captcha_stage', captcha_stage)) + + if case_insensitive_matching is not None: + + _query_params.append(('case_insensitive_matching', case_insensitive_matching)) + + if enrollment_flow is not None: + + _query_params.append(('enrollment_flow', enrollment_flow)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if password_stage is not None: + + _query_params.append(('password_stage', password_stage)) + + if passwordless_flow is not None: + + _query_params.append(('passwordless_flow', passwordless_flow)) + + if recovery_flow is not None: + + _query_params.append(('recovery_flow', recovery_flow)) + + if search is not None: + + _query_params.append(('search', search)) + + if show_matched_user is not None: + + _query_params.append(('show_matched_user', show_matched_user)) + + if show_source_labels is not None: + + _query_params.append(('show_source_labels', show_source_labels)) + + if webauthn_stage is not None: + + _query_params.append(('webauthn_stage', webauthn_stage)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/identification/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_identification_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + patched_identification_stage_request: Optional[PatchedIdentificationStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> IdentificationStage: + """stages_identification_partial_update + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param patched_identification_stage_request: + :type patched_identification_stage_request: PatchedIdentificationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_partial_update_serialize( + stage_uuid=stage_uuid, + patched_identification_stage_request=patched_identification_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_identification_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + patched_identification_stage_request: Optional[PatchedIdentificationStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[IdentificationStage]: + """stages_identification_partial_update + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param patched_identification_stage_request: + :type patched_identification_stage_request: PatchedIdentificationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_partial_update_serialize( + stage_uuid=stage_uuid, + patched_identification_stage_request=patched_identification_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_identification_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + patched_identification_stage_request: Optional[PatchedIdentificationStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_identification_partial_update + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param patched_identification_stage_request: + :type patched_identification_stage_request: PatchedIdentificationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_partial_update_serialize( + stage_uuid=stage_uuid, + patched_identification_stage_request=patched_identification_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_identification_partial_update_serialize( + self, + stage_uuid, + patched_identification_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_identification_stage_request is not None: + _body_params = patched_identification_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/identification/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_identification_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> IdentificationStage: + """stages_identification_retrieve + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_identification_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[IdentificationStage]: + """stages_identification_retrieve + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_identification_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_identification_retrieve + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_identification_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/identification/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_identification_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + identification_stage_request: IdentificationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> IdentificationStage: + """stages_identification_update + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param identification_stage_request: (required) + :type identification_stage_request: IdentificationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_update_serialize( + stage_uuid=stage_uuid, + identification_stage_request=identification_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_identification_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + identification_stage_request: IdentificationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[IdentificationStage]: + """stages_identification_update + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param identification_stage_request: (required) + :type identification_stage_request: IdentificationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_update_serialize( + stage_uuid=stage_uuid, + identification_stage_request=identification_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_identification_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + identification_stage_request: IdentificationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_identification_update + + IdentificationStage Viewset + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param identification_stage_request: (required) + :type identification_stage_request: IdentificationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_update_serialize( + stage_uuid=stage_uuid, + identification_stage_request=identification_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "IdentificationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_identification_update_serialize( + self, + stage_uuid, + identification_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if identification_stage_request is not None: + _body_params = identification_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/identification/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_identification_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_identification_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_identification_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_identification_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_identification_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Identification Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_identification_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Identification Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_identification_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_identification_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/identification/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_invitations_create( + self, + invitation_request: InvitationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Invitation: + """stages_invitation_invitations_create + + Invitation Viewset + + :param invitation_request: (required) + :type invitation_request: InvitationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_create_serialize( + invitation_request=invitation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_invitations_create_with_http_info( + self, + invitation_request: InvitationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Invitation]: + """stages_invitation_invitations_create + + Invitation Viewset + + :param invitation_request: (required) + :type invitation_request: InvitationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_create_serialize( + invitation_request=invitation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_invitations_create_without_preload_content( + self, + invitation_request: InvitationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_invitations_create + + Invitation Viewset + + :param invitation_request: (required) + :type invitation_request: InvitationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_create_serialize( + invitation_request=invitation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_invitations_create_serialize( + self, + invitation_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if invitation_request is not None: + _body_params = invitation_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/invitation/invitations/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_invitations_destroy( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_invitation_invitations_destroy + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_destroy_serialize( + invite_uuid=invite_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_invitations_destroy_with_http_info( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_invitation_invitations_destroy + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_destroy_serialize( + invite_uuid=invite_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_invitations_destroy_without_preload_content( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_invitations_destroy + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_destroy_serialize( + invite_uuid=invite_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_invitations_destroy_serialize( + self, + invite_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if invite_uuid is not None: + _path_params['invite_uuid'] = invite_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/invitation/invitations/{invite_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_invitations_list( + self, + created_by__username: Optional[StrictStr] = None, + expires: Optional[datetime] = None, + flow__slug: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedInvitationList: + """stages_invitation_invitations_list + + Invitation Viewset + + :param created_by__username: + :type created_by__username: str + :param expires: + :type expires: datetime + :param flow__slug: + :type flow__slug: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_list_serialize( + created_by__username=created_by__username, + expires=expires, + flow__slug=flow__slug, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedInvitationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_invitations_list_with_http_info( + self, + created_by__username: Optional[StrictStr] = None, + expires: Optional[datetime] = None, + flow__slug: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedInvitationList]: + """stages_invitation_invitations_list + + Invitation Viewset + + :param created_by__username: + :type created_by__username: str + :param expires: + :type expires: datetime + :param flow__slug: + :type flow__slug: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_list_serialize( + created_by__username=created_by__username, + expires=expires, + flow__slug=flow__slug, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedInvitationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_invitations_list_without_preload_content( + self, + created_by__username: Optional[StrictStr] = None, + expires: Optional[datetime] = None, + flow__slug: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_invitations_list + + Invitation Viewset + + :param created_by__username: + :type created_by__username: str + :param expires: + :type expires: datetime + :param flow__slug: + :type flow__slug: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_list_serialize( + created_by__username=created_by__username, + expires=expires, + flow__slug=flow__slug, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedInvitationList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_invitations_list_serialize( + self, + created_by__username, + expires, + flow__slug, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if created_by__username is not None: + + _query_params.append(('created_by__username', created_by__username)) + + if expires is not None: + if isinstance(expires, datetime): + _query_params.append( + ( + 'expires', + expires.strftime( + self.api_client.configuration.datetime_format + ) + ) + ) + else: + _query_params.append(('expires', expires)) + + if flow__slug is not None: + + _query_params.append(('flow__slug', flow__slug)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/invitation/invitations/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_invitations_partial_update( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + patched_invitation_request: Optional[PatchedInvitationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Invitation: + """stages_invitation_invitations_partial_update + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param patched_invitation_request: + :type patched_invitation_request: PatchedInvitationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_partial_update_serialize( + invite_uuid=invite_uuid, + patched_invitation_request=patched_invitation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_invitations_partial_update_with_http_info( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + patched_invitation_request: Optional[PatchedInvitationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Invitation]: + """stages_invitation_invitations_partial_update + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param patched_invitation_request: + :type patched_invitation_request: PatchedInvitationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_partial_update_serialize( + invite_uuid=invite_uuid, + patched_invitation_request=patched_invitation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_invitations_partial_update_without_preload_content( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + patched_invitation_request: Optional[PatchedInvitationRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_invitations_partial_update + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param patched_invitation_request: + :type patched_invitation_request: PatchedInvitationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_partial_update_serialize( + invite_uuid=invite_uuid, + patched_invitation_request=patched_invitation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_invitations_partial_update_serialize( + self, + invite_uuid, + patched_invitation_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if invite_uuid is not None: + _path_params['invite_uuid'] = invite_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_invitation_request is not None: + _body_params = patched_invitation_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/invitation/invitations/{invite_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_invitations_retrieve( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Invitation: + """stages_invitation_invitations_retrieve + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_retrieve_serialize( + invite_uuid=invite_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_invitations_retrieve_with_http_info( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Invitation]: + """stages_invitation_invitations_retrieve + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_retrieve_serialize( + invite_uuid=invite_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_invitations_retrieve_without_preload_content( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_invitations_retrieve + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_retrieve_serialize( + invite_uuid=invite_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_invitations_retrieve_serialize( + self, + invite_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if invite_uuid is not None: + _path_params['invite_uuid'] = invite_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/invitation/invitations/{invite_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_invitations_send_email_create( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + invitation_send_email_request: InvitationSendEmailRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_invitation_invitations_send_email_create + + Send invitation link via email to one or more addresses + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param invitation_send_email_request: (required) + :type invitation_send_email_request: InvitationSendEmailRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_send_email_create_serialize( + invite_uuid=invite_uuid, + invitation_send_email_request=invitation_send_email_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_invitations_send_email_create_with_http_info( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + invitation_send_email_request: InvitationSendEmailRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_invitation_invitations_send_email_create + + Send invitation link via email to one or more addresses + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param invitation_send_email_request: (required) + :type invitation_send_email_request: InvitationSendEmailRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_send_email_create_serialize( + invite_uuid=invite_uuid, + invitation_send_email_request=invitation_send_email_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_invitations_send_email_create_without_preload_content( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + invitation_send_email_request: InvitationSendEmailRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_invitations_send_email_create + + Send invitation link via email to one or more addresses + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param invitation_send_email_request: (required) + :type invitation_send_email_request: InvitationSendEmailRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_send_email_create_serialize( + invite_uuid=invite_uuid, + invitation_send_email_request=invitation_send_email_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_invitations_send_email_create_serialize( + self, + invite_uuid, + invitation_send_email_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if invite_uuid is not None: + _path_params['invite_uuid'] = invite_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if invitation_send_email_request is not None: + _body_params = invitation_send_email_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/invitation/invitations/{invite_uuid}/send_email/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_invitations_update( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + invitation_request: InvitationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Invitation: + """stages_invitation_invitations_update + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param invitation_request: (required) + :type invitation_request: InvitationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_update_serialize( + invite_uuid=invite_uuid, + invitation_request=invitation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_invitations_update_with_http_info( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + invitation_request: InvitationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Invitation]: + """stages_invitation_invitations_update + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param invitation_request: (required) + :type invitation_request: InvitationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_update_serialize( + invite_uuid=invite_uuid, + invitation_request=invitation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_invitations_update_without_preload_content( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + invitation_request: InvitationRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_invitations_update + + Invitation Viewset + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param invitation_request: (required) + :type invitation_request: InvitationRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_update_serialize( + invite_uuid=invite_uuid, + invitation_request=invitation_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Invitation", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_invitations_update_serialize( + self, + invite_uuid, + invitation_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if invite_uuid is not None: + _path_params['invite_uuid'] = invite_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if invitation_request is not None: + _body_params = invitation_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/invitation/invitations/{invite_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_invitations_used_by_list( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_invitation_invitations_used_by_list + + Get a list of all objects that use this object + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_used_by_list_serialize( + invite_uuid=invite_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_invitations_used_by_list_with_http_info( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_invitation_invitations_used_by_list + + Get a list of all objects that use this object + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_used_by_list_serialize( + invite_uuid=invite_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_invitations_used_by_list_without_preload_content( + self, + invite_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_invitations_used_by_list + + Get a list of all objects that use this object + + :param invite_uuid: A UUID string identifying this Invitation. (required) + :type invite_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_invitations_used_by_list_serialize( + invite_uuid=invite_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_invitations_used_by_list_serialize( + self, + invite_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if invite_uuid is not None: + _path_params['invite_uuid'] = invite_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/invitation/invitations/{invite_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_stages_create( + self, + invitation_stage_request: InvitationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> InvitationStage: + """stages_invitation_stages_create + + InvitationStage Viewset + + :param invitation_stage_request: (required) + :type invitation_stage_request: InvitationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_create_serialize( + invitation_stage_request=invitation_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_stages_create_with_http_info( + self, + invitation_stage_request: InvitationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[InvitationStage]: + """stages_invitation_stages_create + + InvitationStage Viewset + + :param invitation_stage_request: (required) + :type invitation_stage_request: InvitationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_create_serialize( + invitation_stage_request=invitation_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_stages_create_without_preload_content( + self, + invitation_stage_request: InvitationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_stages_create + + InvitationStage Viewset + + :param invitation_stage_request: (required) + :type invitation_stage_request: InvitationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_create_serialize( + invitation_stage_request=invitation_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_stages_create_serialize( + self, + invitation_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if invitation_stage_request is not None: + _body_params = invitation_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/invitation/stages/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_stages_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_invitation_stages_destroy + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_stages_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_invitation_stages_destroy + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_stages_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_stages_destroy + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_stages_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/invitation/stages/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_stages_list( + self, + continue_flow_without_invitation: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + no_flows: Optional[StrictBool] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedInvitationStageList: + """stages_invitation_stages_list + + InvitationStage Viewset + + :param continue_flow_without_invitation: + :type continue_flow_without_invitation: bool + :param name: + :type name: str + :param no_flows: + :type no_flows: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_list_serialize( + continue_flow_without_invitation=continue_flow_without_invitation, + name=name, + no_flows=no_flows, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedInvitationStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_stages_list_with_http_info( + self, + continue_flow_without_invitation: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + no_flows: Optional[StrictBool] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedInvitationStageList]: + """stages_invitation_stages_list + + InvitationStage Viewset + + :param continue_flow_without_invitation: + :type continue_flow_without_invitation: bool + :param name: + :type name: str + :param no_flows: + :type no_flows: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_list_serialize( + continue_flow_without_invitation=continue_flow_without_invitation, + name=name, + no_flows=no_flows, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedInvitationStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_stages_list_without_preload_content( + self, + continue_flow_without_invitation: Optional[StrictBool] = None, + name: Optional[StrictStr] = None, + no_flows: Optional[StrictBool] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_stages_list + + InvitationStage Viewset + + :param continue_flow_without_invitation: + :type continue_flow_without_invitation: bool + :param name: + :type name: str + :param no_flows: + :type no_flows: bool + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_list_serialize( + continue_flow_without_invitation=continue_flow_without_invitation, + name=name, + no_flows=no_flows, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedInvitationStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_stages_list_serialize( + self, + continue_flow_without_invitation, + name, + no_flows, + ordering, + page, + page_size, + search, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if continue_flow_without_invitation is not None: + + _query_params.append(('continue_flow_without_invitation', continue_flow_without_invitation)) + + if name is not None: + + _query_params.append(('name', name)) + + if no_flows is not None: + + _query_params.append(('no_flows', no_flows)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/invitation/stages/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_stages_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + patched_invitation_stage_request: Optional[PatchedInvitationStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> InvitationStage: + """stages_invitation_stages_partial_update + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param patched_invitation_stage_request: + :type patched_invitation_stage_request: PatchedInvitationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_partial_update_serialize( + stage_uuid=stage_uuid, + patched_invitation_stage_request=patched_invitation_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_stages_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + patched_invitation_stage_request: Optional[PatchedInvitationStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[InvitationStage]: + """stages_invitation_stages_partial_update + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param patched_invitation_stage_request: + :type patched_invitation_stage_request: PatchedInvitationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_partial_update_serialize( + stage_uuid=stage_uuid, + patched_invitation_stage_request=patched_invitation_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_stages_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + patched_invitation_stage_request: Optional[PatchedInvitationStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_stages_partial_update + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param patched_invitation_stage_request: + :type patched_invitation_stage_request: PatchedInvitationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_partial_update_serialize( + stage_uuid=stage_uuid, + patched_invitation_stage_request=patched_invitation_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_stages_partial_update_serialize( + self, + stage_uuid, + patched_invitation_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_invitation_stage_request is not None: + _body_params = patched_invitation_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/invitation/stages/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_stages_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> InvitationStage: + """stages_invitation_stages_retrieve + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_stages_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[InvitationStage]: + """stages_invitation_stages_retrieve + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_stages_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_stages_retrieve + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_stages_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/invitation/stages/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_stages_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + invitation_stage_request: InvitationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> InvitationStage: + """stages_invitation_stages_update + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param invitation_stage_request: (required) + :type invitation_stage_request: InvitationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_update_serialize( + stage_uuid=stage_uuid, + invitation_stage_request=invitation_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_stages_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + invitation_stage_request: InvitationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[InvitationStage]: + """stages_invitation_stages_update + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param invitation_stage_request: (required) + :type invitation_stage_request: InvitationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_update_serialize( + stage_uuid=stage_uuid, + invitation_stage_request=invitation_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_stages_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + invitation_stage_request: InvitationStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_stages_update + + InvitationStage Viewset + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param invitation_stage_request: (required) + :type invitation_stage_request: InvitationStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_update_serialize( + stage_uuid=stage_uuid, + invitation_stage_request=invitation_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "InvitationStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_stages_update_serialize( + self, + stage_uuid, + invitation_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if invitation_stage_request is not None: + _body_params = invitation_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/invitation/stages/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_invitation_stages_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_invitation_stages_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_invitation_stages_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_invitation_stages_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_invitation_stages_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Invitation Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_invitation_stages_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Invitation Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_invitation_stages_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_invitation_stages_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/invitation/stages/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_mtls_create( + self, + mutual_tls_stage_request: MutualTLSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MutualTLSStage: + """stages_mtls_create + + MutualTLSStage Viewset + + :param mutual_tls_stage_request: (required) + :type mutual_tls_stage_request: MutualTLSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_create_serialize( + mutual_tls_stage_request=mutual_tls_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_mtls_create_with_http_info( + self, + mutual_tls_stage_request: MutualTLSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MutualTLSStage]: + """stages_mtls_create + + MutualTLSStage Viewset + + :param mutual_tls_stage_request: (required) + :type mutual_tls_stage_request: MutualTLSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_create_serialize( + mutual_tls_stage_request=mutual_tls_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_mtls_create_without_preload_content( + self, + mutual_tls_stage_request: MutualTLSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_mtls_create + + MutualTLSStage Viewset + + :param mutual_tls_stage_request: (required) + :type mutual_tls_stage_request: MutualTLSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_create_serialize( + mutual_tls_stage_request=mutual_tls_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_mtls_create_serialize( + self, + mutual_tls_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if mutual_tls_stage_request is not None: + _body_params = mutual_tls_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/mtls/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_mtls_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_mtls_destroy + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_mtls_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_mtls_destroy + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_mtls_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_mtls_destroy + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_mtls_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/mtls/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_mtls_list( + self, + cert_attribute: Optional[CertAttributeEnum] = None, + certificate_authorities: Optional[List[UUID]] = None, + mode: Optional[StageModeEnum] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + user_attribute: Optional[UserAttributeEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedMutualTLSStageList: + """stages_mtls_list + + MutualTLSStage Viewset + + :param cert_attribute: + :type cert_attribute: CertAttributeEnum + :param certificate_authorities: + :type certificate_authorities: List[UUID] + :param mode: + :type mode: StageModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param user_attribute: + :type user_attribute: UserAttributeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_list_serialize( + cert_attribute=cert_attribute, + certificate_authorities=certificate_authorities, + mode=mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + user_attribute=user_attribute, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMutualTLSStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_mtls_list_with_http_info( + self, + cert_attribute: Optional[CertAttributeEnum] = None, + certificate_authorities: Optional[List[UUID]] = None, + mode: Optional[StageModeEnum] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + user_attribute: Optional[UserAttributeEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedMutualTLSStageList]: + """stages_mtls_list + + MutualTLSStage Viewset + + :param cert_attribute: + :type cert_attribute: CertAttributeEnum + :param certificate_authorities: + :type certificate_authorities: List[UUID] + :param mode: + :type mode: StageModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param user_attribute: + :type user_attribute: UserAttributeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_list_serialize( + cert_attribute=cert_attribute, + certificate_authorities=certificate_authorities, + mode=mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + user_attribute=user_attribute, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMutualTLSStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_mtls_list_without_preload_content( + self, + cert_attribute: Optional[CertAttributeEnum] = None, + certificate_authorities: Optional[List[UUID]] = None, + mode: Optional[StageModeEnum] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + user_attribute: Optional[UserAttributeEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_mtls_list + + MutualTLSStage Viewset + + :param cert_attribute: + :type cert_attribute: CertAttributeEnum + :param certificate_authorities: + :type certificate_authorities: List[UUID] + :param mode: + :type mode: StageModeEnum + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param user_attribute: + :type user_attribute: UserAttributeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_list_serialize( + cert_attribute=cert_attribute, + certificate_authorities=certificate_authorities, + mode=mode, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + user_attribute=user_attribute, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedMutualTLSStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_mtls_list_serialize( + self, + cert_attribute, + certificate_authorities, + mode, + name, + ordering, + page, + page_size, + search, + stage_uuid, + user_attribute, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'certificate_authorities': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if cert_attribute is not None: + + _query_params.append(('cert_attribute', cert_attribute.value)) + + if certificate_authorities is not None: + + _query_params.append(('certificate_authorities', certificate_authorities)) + + if mode is not None: + + _query_params.append(('mode', mode.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + if user_attribute is not None: + + _query_params.append(('user_attribute', user_attribute.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/mtls/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_mtls_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + patched_mutual_tls_stage_request: Optional[PatchedMutualTLSStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MutualTLSStage: + """stages_mtls_partial_update + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param patched_mutual_tls_stage_request: + :type patched_mutual_tls_stage_request: PatchedMutualTLSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_partial_update_serialize( + stage_uuid=stage_uuid, + patched_mutual_tls_stage_request=patched_mutual_tls_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_mtls_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + patched_mutual_tls_stage_request: Optional[PatchedMutualTLSStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MutualTLSStage]: + """stages_mtls_partial_update + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param patched_mutual_tls_stage_request: + :type patched_mutual_tls_stage_request: PatchedMutualTLSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_partial_update_serialize( + stage_uuid=stage_uuid, + patched_mutual_tls_stage_request=patched_mutual_tls_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_mtls_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + patched_mutual_tls_stage_request: Optional[PatchedMutualTLSStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_mtls_partial_update + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param patched_mutual_tls_stage_request: + :type patched_mutual_tls_stage_request: PatchedMutualTLSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_partial_update_serialize( + stage_uuid=stage_uuid, + patched_mutual_tls_stage_request=patched_mutual_tls_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_mtls_partial_update_serialize( + self, + stage_uuid, + patched_mutual_tls_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_mutual_tls_stage_request is not None: + _body_params = patched_mutual_tls_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/mtls/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_mtls_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MutualTLSStage: + """stages_mtls_retrieve + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_mtls_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MutualTLSStage]: + """stages_mtls_retrieve + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_mtls_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_mtls_retrieve + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_mtls_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/mtls/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_mtls_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + mutual_tls_stage_request: MutualTLSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> MutualTLSStage: + """stages_mtls_update + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param mutual_tls_stage_request: (required) + :type mutual_tls_stage_request: MutualTLSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_update_serialize( + stage_uuid=stage_uuid, + mutual_tls_stage_request=mutual_tls_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_mtls_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + mutual_tls_stage_request: MutualTLSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[MutualTLSStage]: + """stages_mtls_update + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param mutual_tls_stage_request: (required) + :type mutual_tls_stage_request: MutualTLSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_update_serialize( + stage_uuid=stage_uuid, + mutual_tls_stage_request=mutual_tls_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_mtls_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + mutual_tls_stage_request: MutualTLSStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_mtls_update + + MutualTLSStage Viewset + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param mutual_tls_stage_request: (required) + :type mutual_tls_stage_request: MutualTLSStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_update_serialize( + stage_uuid=stage_uuid, + mutual_tls_stage_request=mutual_tls_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "MutualTLSStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_mtls_update_serialize( + self, + stage_uuid, + mutual_tls_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if mutual_tls_stage_request is not None: + _body_params = mutual_tls_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/mtls/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_mtls_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_mtls_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_mtls_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_mtls_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_mtls_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Mutual TLS Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_mtls_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Mutual TLS Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_mtls_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_mtls_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/mtls/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_password_create( + self, + password_stage_request: PasswordStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordStage: + """stages_password_create + + PasswordStage Viewset + + :param password_stage_request: (required) + :type password_stage_request: PasswordStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_create_serialize( + password_stage_request=password_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_password_create_with_http_info( + self, + password_stage_request: PasswordStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordStage]: + """stages_password_create + + PasswordStage Viewset + + :param password_stage_request: (required) + :type password_stage_request: PasswordStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_create_serialize( + password_stage_request=password_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_password_create_without_preload_content( + self, + password_stage_request: PasswordStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_password_create + + PasswordStage Viewset + + :param password_stage_request: (required) + :type password_stage_request: PasswordStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_create_serialize( + password_stage_request=password_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_password_create_serialize( + self, + password_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if password_stage_request is not None: + _body_params = password_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/password/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_password_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_password_destroy + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_password_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_password_destroy + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_password_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_password_destroy + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_password_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/password/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_password_list( + self, + allow_show_password: Optional[StrictBool] = None, + configure_flow: Optional[UUID] = None, + failed_attempts_before_cancel: Optional[StrictInt] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPasswordStageList: + """stages_password_list + + PasswordStage Viewset + + :param allow_show_password: + :type allow_show_password: bool + :param configure_flow: + :type configure_flow: UUID + :param failed_attempts_before_cancel: + :type failed_attempts_before_cancel: int + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_list_serialize( + allow_show_password=allow_show_password, + configure_flow=configure_flow, + failed_attempts_before_cancel=failed_attempts_before_cancel, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPasswordStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_password_list_with_http_info( + self, + allow_show_password: Optional[StrictBool] = None, + configure_flow: Optional[UUID] = None, + failed_attempts_before_cancel: Optional[StrictInt] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPasswordStageList]: + """stages_password_list + + PasswordStage Viewset + + :param allow_show_password: + :type allow_show_password: bool + :param configure_flow: + :type configure_flow: UUID + :param failed_attempts_before_cancel: + :type failed_attempts_before_cancel: int + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_list_serialize( + allow_show_password=allow_show_password, + configure_flow=configure_flow, + failed_attempts_before_cancel=failed_attempts_before_cancel, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPasswordStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_password_list_without_preload_content( + self, + allow_show_password: Optional[StrictBool] = None, + configure_flow: Optional[UUID] = None, + failed_attempts_before_cancel: Optional[StrictInt] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_password_list + + PasswordStage Viewset + + :param allow_show_password: + :type allow_show_password: bool + :param configure_flow: + :type configure_flow: UUID + :param failed_attempts_before_cancel: + :type failed_attempts_before_cancel: int + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_list_serialize( + allow_show_password=allow_show_password, + configure_flow=configure_flow, + failed_attempts_before_cancel=failed_attempts_before_cancel, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPasswordStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_password_list_serialize( + self, + allow_show_password, + configure_flow, + failed_attempts_before_cancel, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if allow_show_password is not None: + + _query_params.append(('allow_show_password', allow_show_password)) + + if configure_flow is not None: + + _query_params.append(('configure_flow', configure_flow)) + + if failed_attempts_before_cancel is not None: + + _query_params.append(('failed_attempts_before_cancel', failed_attempts_before_cancel)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/password/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_password_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + patched_password_stage_request: Optional[PatchedPasswordStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordStage: + """stages_password_partial_update + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param patched_password_stage_request: + :type patched_password_stage_request: PatchedPasswordStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_partial_update_serialize( + stage_uuid=stage_uuid, + patched_password_stage_request=patched_password_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_password_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + patched_password_stage_request: Optional[PatchedPasswordStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordStage]: + """stages_password_partial_update + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param patched_password_stage_request: + :type patched_password_stage_request: PatchedPasswordStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_partial_update_serialize( + stage_uuid=stage_uuid, + patched_password_stage_request=patched_password_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_password_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + patched_password_stage_request: Optional[PatchedPasswordStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_password_partial_update + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param patched_password_stage_request: + :type patched_password_stage_request: PatchedPasswordStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_partial_update_serialize( + stage_uuid=stage_uuid, + patched_password_stage_request=patched_password_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_password_partial_update_serialize( + self, + stage_uuid, + patched_password_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_password_stage_request is not None: + _body_params = patched_password_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/password/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_password_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordStage: + """stages_password_retrieve + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_password_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordStage]: + """stages_password_retrieve + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_password_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_password_retrieve + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_password_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/password/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_password_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + password_stage_request: PasswordStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PasswordStage: + """stages_password_update + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param password_stage_request: (required) + :type password_stage_request: PasswordStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_update_serialize( + stage_uuid=stage_uuid, + password_stage_request=password_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_password_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + password_stage_request: PasswordStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PasswordStage]: + """stages_password_update + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param password_stage_request: (required) + :type password_stage_request: PasswordStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_update_serialize( + stage_uuid=stage_uuid, + password_stage_request=password_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_password_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + password_stage_request: PasswordStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_password_update + + PasswordStage Viewset + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param password_stage_request: (required) + :type password_stage_request: PasswordStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_update_serialize( + stage_uuid=stage_uuid, + password_stage_request=password_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PasswordStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_password_update_serialize( + self, + stage_uuid, + password_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if password_stage_request is not None: + _body_params = password_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/password/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_password_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_password_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_password_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_password_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_password_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Password Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_password_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Password Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_password_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_password_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/password/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_prompts_create( + self, + prompt_request: PromptRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Prompt: + """stages_prompt_prompts_create + + Prompt Viewset + + :param prompt_request: (required) + :type prompt_request: PromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_create_serialize( + prompt_request=prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_prompts_create_with_http_info( + self, + prompt_request: PromptRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Prompt]: + """stages_prompt_prompts_create + + Prompt Viewset + + :param prompt_request: (required) + :type prompt_request: PromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_create_serialize( + prompt_request=prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_prompts_create_without_preload_content( + self, + prompt_request: PromptRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_prompts_create + + Prompt Viewset + + :param prompt_request: (required) + :type prompt_request: PromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_create_serialize( + prompt_request=prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_prompts_create_serialize( + self, + prompt_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if prompt_request is not None: + _body_params = prompt_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/prompt/prompts/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_prompts_destroy( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_prompt_prompts_destroy + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_destroy_serialize( + prompt_uuid=prompt_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_prompts_destroy_with_http_info( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_prompt_prompts_destroy + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_destroy_serialize( + prompt_uuid=prompt_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_prompts_destroy_without_preload_content( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_prompts_destroy + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_destroy_serialize( + prompt_uuid=prompt_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_prompts_destroy_serialize( + self, + prompt_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if prompt_uuid is not None: + _path_params['prompt_uuid'] = prompt_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/prompt/prompts/{prompt_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_prompts_list( + self, + field_key: Optional[StrictStr] = None, + label: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + placeholder: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + type: Optional[PromptTypeEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPromptList: + """stages_prompt_prompts_list + + Prompt Viewset + + :param field_key: + :type field_key: str + :param label: + :type label: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param placeholder: + :type placeholder: str + :param search: A search term. + :type search: str + :param type: + :type type: PromptTypeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_list_serialize( + field_key=field_key, + label=label, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + placeholder=placeholder, + search=search, + type=type, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPromptList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_prompts_list_with_http_info( + self, + field_key: Optional[StrictStr] = None, + label: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + placeholder: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + type: Optional[PromptTypeEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPromptList]: + """stages_prompt_prompts_list + + Prompt Viewset + + :param field_key: + :type field_key: str + :param label: + :type label: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param placeholder: + :type placeholder: str + :param search: A search term. + :type search: str + :param type: + :type type: PromptTypeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_list_serialize( + field_key=field_key, + label=label, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + placeholder=placeholder, + search=search, + type=type, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPromptList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_prompts_list_without_preload_content( + self, + field_key: Optional[StrictStr] = None, + label: Optional[StrictStr] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + placeholder: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + type: Optional[PromptTypeEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_prompts_list + + Prompt Viewset + + :param field_key: + :type field_key: str + :param label: + :type label: str + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param placeholder: + :type placeholder: str + :param search: A search term. + :type search: str + :param type: + :type type: PromptTypeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_list_serialize( + field_key=field_key, + label=label, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + placeholder=placeholder, + search=search, + type=type, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPromptList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_prompts_list_serialize( + self, + field_key, + label, + name, + ordering, + page, + page_size, + placeholder, + search, + type, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if field_key is not None: + + _query_params.append(('field_key', field_key)) + + if label is not None: + + _query_params.append(('label', label)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if placeholder is not None: + + _query_params.append(('placeholder', placeholder)) + + if search is not None: + + _query_params.append(('search', search)) + + if type is not None: + + _query_params.append(('type', type.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/prompt/prompts/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_prompts_partial_update( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + patched_prompt_request: Optional[PatchedPromptRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Prompt: + """stages_prompt_prompts_partial_update + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param patched_prompt_request: + :type patched_prompt_request: PatchedPromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_partial_update_serialize( + prompt_uuid=prompt_uuid, + patched_prompt_request=patched_prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_prompts_partial_update_with_http_info( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + patched_prompt_request: Optional[PatchedPromptRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Prompt]: + """stages_prompt_prompts_partial_update + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param patched_prompt_request: + :type patched_prompt_request: PatchedPromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_partial_update_serialize( + prompt_uuid=prompt_uuid, + patched_prompt_request=patched_prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_prompts_partial_update_without_preload_content( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + patched_prompt_request: Optional[PatchedPromptRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_prompts_partial_update + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param patched_prompt_request: + :type patched_prompt_request: PatchedPromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_partial_update_serialize( + prompt_uuid=prompt_uuid, + patched_prompt_request=patched_prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_prompts_partial_update_serialize( + self, + prompt_uuid, + patched_prompt_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if prompt_uuid is not None: + _path_params['prompt_uuid'] = prompt_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_prompt_request is not None: + _body_params = patched_prompt_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/prompt/prompts/{prompt_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_prompts_preview_create( + self, + prompt_request: PromptRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PromptChallenge: + """stages_prompt_prompts_preview_create + + Preview a prompt as a challenge, just like a flow would receive + + :param prompt_request: (required) + :type prompt_request: PromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_preview_create_serialize( + prompt_request=prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptChallenge", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_prompts_preview_create_with_http_info( + self, + prompt_request: PromptRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PromptChallenge]: + """stages_prompt_prompts_preview_create + + Preview a prompt as a challenge, just like a flow would receive + + :param prompt_request: (required) + :type prompt_request: PromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_preview_create_serialize( + prompt_request=prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptChallenge", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_prompts_preview_create_without_preload_content( + self, + prompt_request: PromptRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_prompts_preview_create + + Preview a prompt as a challenge, just like a flow would receive + + :param prompt_request: (required) + :type prompt_request: PromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_preview_create_serialize( + prompt_request=prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptChallenge", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_prompts_preview_create_serialize( + self, + prompt_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if prompt_request is not None: + _body_params = prompt_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/prompt/prompts/preview/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_prompts_retrieve( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Prompt: + """stages_prompt_prompts_retrieve + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_retrieve_serialize( + prompt_uuid=prompt_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_prompts_retrieve_with_http_info( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Prompt]: + """stages_prompt_prompts_retrieve + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_retrieve_serialize( + prompt_uuid=prompt_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_prompts_retrieve_without_preload_content( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_prompts_retrieve + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_retrieve_serialize( + prompt_uuid=prompt_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_prompts_retrieve_serialize( + self, + prompt_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if prompt_uuid is not None: + _path_params['prompt_uuid'] = prompt_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/prompt/prompts/{prompt_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_prompts_update( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + prompt_request: PromptRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Prompt: + """stages_prompt_prompts_update + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param prompt_request: (required) + :type prompt_request: PromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_update_serialize( + prompt_uuid=prompt_uuid, + prompt_request=prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_prompts_update_with_http_info( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + prompt_request: PromptRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Prompt]: + """stages_prompt_prompts_update + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param prompt_request: (required) + :type prompt_request: PromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_update_serialize( + prompt_uuid=prompt_uuid, + prompt_request=prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_prompts_update_without_preload_content( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + prompt_request: PromptRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_prompts_update + + Prompt Viewset + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param prompt_request: (required) + :type prompt_request: PromptRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_update_serialize( + prompt_uuid=prompt_uuid, + prompt_request=prompt_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Prompt", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_prompts_update_serialize( + self, + prompt_uuid, + prompt_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if prompt_uuid is not None: + _path_params['prompt_uuid'] = prompt_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if prompt_request is not None: + _body_params = prompt_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/prompt/prompts/{prompt_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_prompts_used_by_list( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_prompt_prompts_used_by_list + + Get a list of all objects that use this object + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_used_by_list_serialize( + prompt_uuid=prompt_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_prompts_used_by_list_with_http_info( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_prompt_prompts_used_by_list + + Get a list of all objects that use this object + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_used_by_list_serialize( + prompt_uuid=prompt_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_prompts_used_by_list_without_preload_content( + self, + prompt_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_prompts_used_by_list + + Get a list of all objects that use this object + + :param prompt_uuid: A UUID string identifying this Prompt. (required) + :type prompt_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_prompts_used_by_list_serialize( + prompt_uuid=prompt_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_prompts_used_by_list_serialize( + self, + prompt_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if prompt_uuid is not None: + _path_params['prompt_uuid'] = prompt_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/prompt/prompts/{prompt_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_stages_create( + self, + prompt_stage_request: PromptStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PromptStage: + """stages_prompt_stages_create + + PromptStage Viewset + + :param prompt_stage_request: (required) + :type prompt_stage_request: PromptStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_create_serialize( + prompt_stage_request=prompt_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_stages_create_with_http_info( + self, + prompt_stage_request: PromptStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PromptStage]: + """stages_prompt_stages_create + + PromptStage Viewset + + :param prompt_stage_request: (required) + :type prompt_stage_request: PromptStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_create_serialize( + prompt_stage_request=prompt_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_stages_create_without_preload_content( + self, + prompt_stage_request: PromptStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_stages_create + + PromptStage Viewset + + :param prompt_stage_request: (required) + :type prompt_stage_request: PromptStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_create_serialize( + prompt_stage_request=prompt_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_stages_create_serialize( + self, + prompt_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if prompt_stage_request is not None: + _body_params = prompt_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/prompt/stages/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_stages_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_prompt_stages_destroy + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_stages_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_prompt_stages_destroy + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_stages_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_stages_destroy + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_stages_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/prompt/stages/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_stages_list( + self, + fields: Optional[List[UUID]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + validation_policies: Optional[List[UUID]] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedPromptStageList: + """stages_prompt_stages_list + + PromptStage Viewset + + :param fields: + :type fields: List[UUID] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param validation_policies: + :type validation_policies: List[UUID] + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_list_serialize( + fields=fields, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + validation_policies=validation_policies, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPromptStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_stages_list_with_http_info( + self, + fields: Optional[List[UUID]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + validation_policies: Optional[List[UUID]] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedPromptStageList]: + """stages_prompt_stages_list + + PromptStage Viewset + + :param fields: + :type fields: List[UUID] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param validation_policies: + :type validation_policies: List[UUID] + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_list_serialize( + fields=fields, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + validation_policies=validation_policies, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPromptStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_stages_list_without_preload_content( + self, + fields: Optional[List[UUID]] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + validation_policies: Optional[List[UUID]] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_stages_list + + PromptStage Viewset + + :param fields: + :type fields: List[UUID] + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param validation_policies: + :type validation_policies: List[UUID] + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_list_serialize( + fields=fields, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + validation_policies=validation_policies, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedPromptStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_stages_list_serialize( + self, + fields, + name, + ordering, + page, + page_size, + search, + stage_uuid, + validation_policies, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'fields': 'multi', + 'validation_policies': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if fields is not None: + + _query_params.append(('fields', fields)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + if validation_policies is not None: + + _query_params.append(('validation_policies', validation_policies)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/prompt/stages/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_stages_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + patched_prompt_stage_request: Optional[PatchedPromptStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PromptStage: + """stages_prompt_stages_partial_update + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param patched_prompt_stage_request: + :type patched_prompt_stage_request: PatchedPromptStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_partial_update_serialize( + stage_uuid=stage_uuid, + patched_prompt_stage_request=patched_prompt_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_stages_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + patched_prompt_stage_request: Optional[PatchedPromptStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PromptStage]: + """stages_prompt_stages_partial_update + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param patched_prompt_stage_request: + :type patched_prompt_stage_request: PatchedPromptStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_partial_update_serialize( + stage_uuid=stage_uuid, + patched_prompt_stage_request=patched_prompt_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_stages_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + patched_prompt_stage_request: Optional[PatchedPromptStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_stages_partial_update + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param patched_prompt_stage_request: + :type patched_prompt_stage_request: PatchedPromptStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_partial_update_serialize( + stage_uuid=stage_uuid, + patched_prompt_stage_request=patched_prompt_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_stages_partial_update_serialize( + self, + stage_uuid, + patched_prompt_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_prompt_stage_request is not None: + _body_params = patched_prompt_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/prompt/stages/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_stages_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PromptStage: + """stages_prompt_stages_retrieve + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_stages_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PromptStage]: + """stages_prompt_stages_retrieve + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_stages_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_stages_retrieve + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_stages_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/prompt/stages/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_stages_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + prompt_stage_request: PromptStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PromptStage: + """stages_prompt_stages_update + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param prompt_stage_request: (required) + :type prompt_stage_request: PromptStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_update_serialize( + stage_uuid=stage_uuid, + prompt_stage_request=prompt_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_stages_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + prompt_stage_request: PromptStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PromptStage]: + """stages_prompt_stages_update + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param prompt_stage_request: (required) + :type prompt_stage_request: PromptStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_update_serialize( + stage_uuid=stage_uuid, + prompt_stage_request=prompt_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_stages_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + prompt_stage_request: PromptStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_stages_update + + PromptStage Viewset + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param prompt_stage_request: (required) + :type prompt_stage_request: PromptStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_update_serialize( + stage_uuid=stage_uuid, + prompt_stage_request=prompt_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PromptStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_stages_update_serialize( + self, + stage_uuid, + prompt_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if prompt_stage_request is not None: + _body_params = prompt_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/prompt/stages/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_prompt_stages_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_prompt_stages_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_prompt_stages_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_prompt_stages_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_prompt_stages_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Prompt Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_prompt_stages_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Prompt Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_prompt_stages_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_prompt_stages_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/prompt/stages/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_redirect_create( + self, + redirect_stage_request: RedirectStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RedirectStage: + """stages_redirect_create + + RedirectStage Viewset + + :param redirect_stage_request: (required) + :type redirect_stage_request: RedirectStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_create_serialize( + redirect_stage_request=redirect_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_redirect_create_with_http_info( + self, + redirect_stage_request: RedirectStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RedirectStage]: + """stages_redirect_create + + RedirectStage Viewset + + :param redirect_stage_request: (required) + :type redirect_stage_request: RedirectStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_create_serialize( + redirect_stage_request=redirect_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_redirect_create_without_preload_content( + self, + redirect_stage_request: RedirectStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_redirect_create + + RedirectStage Viewset + + :param redirect_stage_request: (required) + :type redirect_stage_request: RedirectStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_create_serialize( + redirect_stage_request=redirect_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_redirect_create_serialize( + self, + redirect_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if redirect_stage_request is not None: + _body_params = redirect_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/redirect/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_redirect_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_redirect_destroy + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_redirect_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_redirect_destroy + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_redirect_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_redirect_destroy + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_redirect_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/redirect/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_redirect_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedRedirectStageList: + """stages_redirect_list + + RedirectStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRedirectStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_redirect_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedRedirectStageList]: + """stages_redirect_list + + RedirectStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRedirectStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_redirect_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_redirect_list + + RedirectStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedRedirectStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_redirect_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/redirect/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_redirect_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + patched_redirect_stage_request: Optional[PatchedRedirectStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RedirectStage: + """stages_redirect_partial_update + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param patched_redirect_stage_request: + :type patched_redirect_stage_request: PatchedRedirectStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_partial_update_serialize( + stage_uuid=stage_uuid, + patched_redirect_stage_request=patched_redirect_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_redirect_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + patched_redirect_stage_request: Optional[PatchedRedirectStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RedirectStage]: + """stages_redirect_partial_update + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param patched_redirect_stage_request: + :type patched_redirect_stage_request: PatchedRedirectStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_partial_update_serialize( + stage_uuid=stage_uuid, + patched_redirect_stage_request=patched_redirect_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_redirect_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + patched_redirect_stage_request: Optional[PatchedRedirectStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_redirect_partial_update + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param patched_redirect_stage_request: + :type patched_redirect_stage_request: PatchedRedirectStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_partial_update_serialize( + stage_uuid=stage_uuid, + patched_redirect_stage_request=patched_redirect_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_redirect_partial_update_serialize( + self, + stage_uuid, + patched_redirect_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_redirect_stage_request is not None: + _body_params = patched_redirect_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/redirect/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_redirect_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RedirectStage: + """stages_redirect_retrieve + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_redirect_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RedirectStage]: + """stages_redirect_retrieve + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_redirect_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_redirect_retrieve + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_redirect_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/redirect/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_redirect_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + redirect_stage_request: RedirectStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RedirectStage: + """stages_redirect_update + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param redirect_stage_request: (required) + :type redirect_stage_request: RedirectStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_update_serialize( + stage_uuid=stage_uuid, + redirect_stage_request=redirect_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_redirect_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + redirect_stage_request: RedirectStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[RedirectStage]: + """stages_redirect_update + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param redirect_stage_request: (required) + :type redirect_stage_request: RedirectStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_update_serialize( + stage_uuid=stage_uuid, + redirect_stage_request=redirect_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_redirect_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + redirect_stage_request: RedirectStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_redirect_update + + RedirectStage Viewset + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param redirect_stage_request: (required) + :type redirect_stage_request: RedirectStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_update_serialize( + stage_uuid=stage_uuid, + redirect_stage_request=redirect_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "RedirectStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_redirect_update_serialize( + self, + stage_uuid, + redirect_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if redirect_stage_request is not None: + _body_params = redirect_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/redirect/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_redirect_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_redirect_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_redirect_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_redirect_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_redirect_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Redirect Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_redirect_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Redirect Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_redirect_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_redirect_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/redirect/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_source_create( + self, + source_stage_request: SourceStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SourceStage: + """stages_source_create + + SourceStage Viewset + + :param source_stage_request: (required) + :type source_stage_request: SourceStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_create_serialize( + source_stage_request=source_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_source_create_with_http_info( + self, + source_stage_request: SourceStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SourceStage]: + """stages_source_create + + SourceStage Viewset + + :param source_stage_request: (required) + :type source_stage_request: SourceStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_create_serialize( + source_stage_request=source_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_source_create_without_preload_content( + self, + source_stage_request: SourceStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_source_create + + SourceStage Viewset + + :param source_stage_request: (required) + :type source_stage_request: SourceStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_create_serialize( + source_stage_request=source_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_source_create_serialize( + self, + source_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if source_stage_request is not None: + _body_params = source_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/source/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_source_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_source_destroy + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_source_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_source_destroy + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_source_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_source_destroy + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_source_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/source/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_source_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + resume_timeout: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source: Optional[UUID] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedSourceStageList: + """stages_source_list + + SourceStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param resume_timeout: + :type resume_timeout: str + :param search: A search term. + :type search: str + :param source: + :type source: UUID + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + resume_timeout=resume_timeout, + search=search, + source=source, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSourceStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_source_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + resume_timeout: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source: Optional[UUID] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedSourceStageList]: + """stages_source_list + + SourceStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param resume_timeout: + :type resume_timeout: str + :param search: A search term. + :type search: str + :param source: + :type source: UUID + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + resume_timeout=resume_timeout, + search=search, + source=source, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSourceStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_source_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + resume_timeout: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + source: Optional[UUID] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_source_list + + SourceStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param resume_timeout: + :type resume_timeout: str + :param search: A search term. + :type search: str + :param source: + :type source: UUID + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + resume_timeout=resume_timeout, + search=search, + source=source, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedSourceStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_source_list_serialize( + self, + name, + ordering, + page, + page_size, + resume_timeout, + search, + source, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if resume_timeout is not None: + + _query_params.append(('resume_timeout', resume_timeout)) + + if search is not None: + + _query_params.append(('search', search)) + + if source is not None: + + _query_params.append(('source', source)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/source/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_source_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + patched_source_stage_request: Optional[PatchedSourceStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SourceStage: + """stages_source_partial_update + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param patched_source_stage_request: + :type patched_source_stage_request: PatchedSourceStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_partial_update_serialize( + stage_uuid=stage_uuid, + patched_source_stage_request=patched_source_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_source_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + patched_source_stage_request: Optional[PatchedSourceStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SourceStage]: + """stages_source_partial_update + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param patched_source_stage_request: + :type patched_source_stage_request: PatchedSourceStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_partial_update_serialize( + stage_uuid=stage_uuid, + patched_source_stage_request=patched_source_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_source_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + patched_source_stage_request: Optional[PatchedSourceStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_source_partial_update + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param patched_source_stage_request: + :type patched_source_stage_request: PatchedSourceStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_partial_update_serialize( + stage_uuid=stage_uuid, + patched_source_stage_request=patched_source_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_source_partial_update_serialize( + self, + stage_uuid, + patched_source_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_source_stage_request is not None: + _body_params = patched_source_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/source/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_source_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SourceStage: + """stages_source_retrieve + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_source_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SourceStage]: + """stages_source_retrieve + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_source_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_source_retrieve + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_source_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/source/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_source_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + source_stage_request: SourceStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> SourceStage: + """stages_source_update + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param source_stage_request: (required) + :type source_stage_request: SourceStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_update_serialize( + stage_uuid=stage_uuid, + source_stage_request=source_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_source_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + source_stage_request: SourceStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[SourceStage]: + """stages_source_update + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param source_stage_request: (required) + :type source_stage_request: SourceStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_update_serialize( + stage_uuid=stage_uuid, + source_stage_request=source_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_source_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + source_stage_request: SourceStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_source_update + + SourceStage Viewset + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param source_stage_request: (required) + :type source_stage_request: SourceStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_update_serialize( + stage_uuid=stage_uuid, + source_stage_request=source_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "SourceStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_source_update_serialize( + self, + stage_uuid, + source_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if source_stage_request is not None: + _body_params = source_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/source/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_source_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_source_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_source_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_source_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_source_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this Source Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_source_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this Source Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_source_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_source_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/source/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_delete_create( + self, + user_delete_stage_request: UserDeleteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserDeleteStage: + """stages_user_delete_create + + UserDeleteStage Viewset + + :param user_delete_stage_request: (required) + :type user_delete_stage_request: UserDeleteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_create_serialize( + user_delete_stage_request=user_delete_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_delete_create_with_http_info( + self, + user_delete_stage_request: UserDeleteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserDeleteStage]: + """stages_user_delete_create + + UserDeleteStage Viewset + + :param user_delete_stage_request: (required) + :type user_delete_stage_request: UserDeleteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_create_serialize( + user_delete_stage_request=user_delete_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_delete_create_without_preload_content( + self, + user_delete_stage_request: UserDeleteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_delete_create + + UserDeleteStage Viewset + + :param user_delete_stage_request: (required) + :type user_delete_stage_request: UserDeleteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_create_serialize( + user_delete_stage_request=user_delete_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_delete_create_serialize( + self, + user_delete_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_delete_stage_request is not None: + _body_params = user_delete_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/user_delete/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_delete_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_user_delete_destroy + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_delete_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_user_delete_destroy + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_delete_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_delete_destroy + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_delete_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/user_delete/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_delete_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserDeleteStageList: + """stages_user_delete_list + + UserDeleteStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserDeleteStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_delete_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserDeleteStageList]: + """stages_user_delete_list + + UserDeleteStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserDeleteStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_delete_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_delete_list + + UserDeleteStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserDeleteStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_delete_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_delete/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_delete_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + patched_user_delete_stage_request: Optional[PatchedUserDeleteStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserDeleteStage: + """stages_user_delete_partial_update + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param patched_user_delete_stage_request: + :type patched_user_delete_stage_request: PatchedUserDeleteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_delete_stage_request=patched_user_delete_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_delete_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + patched_user_delete_stage_request: Optional[PatchedUserDeleteStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserDeleteStage]: + """stages_user_delete_partial_update + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param patched_user_delete_stage_request: + :type patched_user_delete_stage_request: PatchedUserDeleteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_delete_stage_request=patched_user_delete_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_delete_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + patched_user_delete_stage_request: Optional[PatchedUserDeleteStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_delete_partial_update + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param patched_user_delete_stage_request: + :type patched_user_delete_stage_request: PatchedUserDeleteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_delete_stage_request=patched_user_delete_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_delete_partial_update_serialize( + self, + stage_uuid, + patched_user_delete_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_delete_stage_request is not None: + _body_params = patched_user_delete_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/user_delete/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_delete_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserDeleteStage: + """stages_user_delete_retrieve + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_delete_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserDeleteStage]: + """stages_user_delete_retrieve + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_delete_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_delete_retrieve + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_delete_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_delete/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_delete_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + user_delete_stage_request: UserDeleteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserDeleteStage: + """stages_user_delete_update + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param user_delete_stage_request: (required) + :type user_delete_stage_request: UserDeleteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_update_serialize( + stage_uuid=stage_uuid, + user_delete_stage_request=user_delete_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_delete_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + user_delete_stage_request: UserDeleteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserDeleteStage]: + """stages_user_delete_update + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param user_delete_stage_request: (required) + :type user_delete_stage_request: UserDeleteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_update_serialize( + stage_uuid=stage_uuid, + user_delete_stage_request=user_delete_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_delete_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + user_delete_stage_request: UserDeleteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_delete_update + + UserDeleteStage Viewset + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param user_delete_stage_request: (required) + :type user_delete_stage_request: UserDeleteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_update_serialize( + stage_uuid=stage_uuid, + user_delete_stage_request=user_delete_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserDeleteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_delete_update_serialize( + self, + stage_uuid, + user_delete_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_delete_stage_request is not None: + _body_params = user_delete_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/user_delete/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_delete_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_user_delete_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_delete_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_user_delete_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_delete_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Delete Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_delete_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Delete Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_delete_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_delete_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_delete/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_login_create( + self, + user_login_stage_request: UserLoginStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLoginStage: + """stages_user_login_create + + UserLoginStage Viewset + + :param user_login_stage_request: (required) + :type user_login_stage_request: UserLoginStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_create_serialize( + user_login_stage_request=user_login_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_login_create_with_http_info( + self, + user_login_stage_request: UserLoginStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLoginStage]: + """stages_user_login_create + + UserLoginStage Viewset + + :param user_login_stage_request: (required) + :type user_login_stage_request: UserLoginStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_create_serialize( + user_login_stage_request=user_login_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_login_create_without_preload_content( + self, + user_login_stage_request: UserLoginStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_login_create + + UserLoginStage Viewset + + :param user_login_stage_request: (required) + :type user_login_stage_request: UserLoginStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_create_serialize( + user_login_stage_request=user_login_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_login_create_serialize( + self, + user_login_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_login_stage_request is not None: + _body_params = user_login_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/user_login/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_login_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_user_login_destroy + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_login_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_user_login_destroy + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_login_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_login_destroy + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_login_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/user_login/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_login_list( + self, + geoip_binding: Optional[Any] = None, + name: Optional[StrictStr] = None, + network_binding: Optional[Any] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + remember_device: Optional[StrictStr] = None, + remember_me_offset: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session_duration: Optional[StrictStr] = None, + stage_uuid: Optional[UUID] = None, + terminate_other_sessions: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserLoginStageList: + """stages_user_login_list + + UserLoginStage Viewset + + :param geoip_binding: + :type geoip_binding: GeoipBindingEnum + :param name: + :type name: str + :param network_binding: + :type network_binding: NetworkBindingEnum + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param remember_device: + :type remember_device: str + :param remember_me_offset: + :type remember_me_offset: str + :param search: A search term. + :type search: str + :param session_duration: + :type session_duration: str + :param stage_uuid: + :type stage_uuid: UUID + :param terminate_other_sessions: + :type terminate_other_sessions: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_list_serialize( + geoip_binding=geoip_binding, + name=name, + network_binding=network_binding, + ordering=ordering, + page=page, + page_size=page_size, + remember_device=remember_device, + remember_me_offset=remember_me_offset, + search=search, + session_duration=session_duration, + stage_uuid=stage_uuid, + terminate_other_sessions=terminate_other_sessions, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserLoginStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_login_list_with_http_info( + self, + geoip_binding: Optional[Any] = None, + name: Optional[StrictStr] = None, + network_binding: Optional[Any] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + remember_device: Optional[StrictStr] = None, + remember_me_offset: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session_duration: Optional[StrictStr] = None, + stage_uuid: Optional[UUID] = None, + terminate_other_sessions: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserLoginStageList]: + """stages_user_login_list + + UserLoginStage Viewset + + :param geoip_binding: + :type geoip_binding: GeoipBindingEnum + :param name: + :type name: str + :param network_binding: + :type network_binding: NetworkBindingEnum + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param remember_device: + :type remember_device: str + :param remember_me_offset: + :type remember_me_offset: str + :param search: A search term. + :type search: str + :param session_duration: + :type session_duration: str + :param stage_uuid: + :type stage_uuid: UUID + :param terminate_other_sessions: + :type terminate_other_sessions: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_list_serialize( + geoip_binding=geoip_binding, + name=name, + network_binding=network_binding, + ordering=ordering, + page=page, + page_size=page_size, + remember_device=remember_device, + remember_me_offset=remember_me_offset, + search=search, + session_duration=session_duration, + stage_uuid=stage_uuid, + terminate_other_sessions=terminate_other_sessions, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserLoginStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_login_list_without_preload_content( + self, + geoip_binding: Optional[Any] = None, + name: Optional[StrictStr] = None, + network_binding: Optional[Any] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + remember_device: Optional[StrictStr] = None, + remember_me_offset: Optional[StrictStr] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + session_duration: Optional[StrictStr] = None, + stage_uuid: Optional[UUID] = None, + terminate_other_sessions: Optional[StrictBool] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_login_list + + UserLoginStage Viewset + + :param geoip_binding: + :type geoip_binding: GeoipBindingEnum + :param name: + :type name: str + :param network_binding: + :type network_binding: NetworkBindingEnum + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param remember_device: + :type remember_device: str + :param remember_me_offset: + :type remember_me_offset: str + :param search: A search term. + :type search: str + :param session_duration: + :type session_duration: str + :param stage_uuid: + :type stage_uuid: UUID + :param terminate_other_sessions: + :type terminate_other_sessions: bool + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_list_serialize( + geoip_binding=geoip_binding, + name=name, + network_binding=network_binding, + ordering=ordering, + page=page, + page_size=page_size, + remember_device=remember_device, + remember_me_offset=remember_me_offset, + search=search, + session_duration=session_duration, + stage_uuid=stage_uuid, + terminate_other_sessions=terminate_other_sessions, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserLoginStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_login_list_serialize( + self, + geoip_binding, + name, + network_binding, + ordering, + page, + page_size, + remember_device, + remember_me_offset, + search, + session_duration, + stage_uuid, + terminate_other_sessions, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if geoip_binding is not None: + + _query_params.append(('geoip_binding', geoip_binding.value)) + + if name is not None: + + _query_params.append(('name', name)) + + if network_binding is not None: + + _query_params.append(('network_binding', network_binding.value)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if remember_device is not None: + + _query_params.append(('remember_device', remember_device)) + + if remember_me_offset is not None: + + _query_params.append(('remember_me_offset', remember_me_offset)) + + if search is not None: + + _query_params.append(('search', search)) + + if session_duration is not None: + + _query_params.append(('session_duration', session_duration)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + if terminate_other_sessions is not None: + + _query_params.append(('terminate_other_sessions', terminate_other_sessions)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_login/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_login_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + patched_user_login_stage_request: Optional[PatchedUserLoginStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLoginStage: + """stages_user_login_partial_update + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param patched_user_login_stage_request: + :type patched_user_login_stage_request: PatchedUserLoginStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_login_stage_request=patched_user_login_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_login_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + patched_user_login_stage_request: Optional[PatchedUserLoginStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLoginStage]: + """stages_user_login_partial_update + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param patched_user_login_stage_request: + :type patched_user_login_stage_request: PatchedUserLoginStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_login_stage_request=patched_user_login_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_login_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + patched_user_login_stage_request: Optional[PatchedUserLoginStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_login_partial_update + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param patched_user_login_stage_request: + :type patched_user_login_stage_request: PatchedUserLoginStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_login_stage_request=patched_user_login_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_login_partial_update_serialize( + self, + stage_uuid, + patched_user_login_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_login_stage_request is not None: + _body_params = patched_user_login_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/user_login/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_login_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLoginStage: + """stages_user_login_retrieve + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_login_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLoginStage]: + """stages_user_login_retrieve + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_login_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_login_retrieve + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_login_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_login/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_login_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + user_login_stage_request: UserLoginStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLoginStage: + """stages_user_login_update + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param user_login_stage_request: (required) + :type user_login_stage_request: UserLoginStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_update_serialize( + stage_uuid=stage_uuid, + user_login_stage_request=user_login_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_login_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + user_login_stage_request: UserLoginStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLoginStage]: + """stages_user_login_update + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param user_login_stage_request: (required) + :type user_login_stage_request: UserLoginStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_update_serialize( + stage_uuid=stage_uuid, + user_login_stage_request=user_login_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_login_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + user_login_stage_request: UserLoginStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_login_update + + UserLoginStage Viewset + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param user_login_stage_request: (required) + :type user_login_stage_request: UserLoginStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_update_serialize( + stage_uuid=stage_uuid, + user_login_stage_request=user_login_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLoginStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_login_update_serialize( + self, + stage_uuid, + user_login_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_login_stage_request is not None: + _body_params = user_login_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/user_login/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_login_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_user_login_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_login_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_user_login_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_login_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Login Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_login_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Login Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_login_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_login_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_login/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_logout_create( + self, + user_logout_stage_request: UserLogoutStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLogoutStage: + """stages_user_logout_create + + UserLogoutStage Viewset + + :param user_logout_stage_request: (required) + :type user_logout_stage_request: UserLogoutStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_create_serialize( + user_logout_stage_request=user_logout_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_logout_create_with_http_info( + self, + user_logout_stage_request: UserLogoutStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLogoutStage]: + """stages_user_logout_create + + UserLogoutStage Viewset + + :param user_logout_stage_request: (required) + :type user_logout_stage_request: UserLogoutStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_create_serialize( + user_logout_stage_request=user_logout_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_logout_create_without_preload_content( + self, + user_logout_stage_request: UserLogoutStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_logout_create + + UserLogoutStage Viewset + + :param user_logout_stage_request: (required) + :type user_logout_stage_request: UserLogoutStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_create_serialize( + user_logout_stage_request=user_logout_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_logout_create_serialize( + self, + user_logout_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_logout_stage_request is not None: + _body_params = user_logout_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/user_logout/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_logout_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_user_logout_destroy + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_logout_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_user_logout_destroy + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_logout_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_logout_destroy + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_logout_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/user_logout/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_logout_list( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserLogoutStageList: + """stages_user_logout_list + + UserLogoutStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserLogoutStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_logout_list_with_http_info( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserLogoutStageList]: + """stages_user_logout_list + + UserLogoutStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserLogoutStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_logout_list_without_preload_content( + self, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_logout_list + + UserLogoutStage Viewset + + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_list_serialize( + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserLogoutStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_logout_list_serialize( + self, + name, + ordering, + page, + page_size, + search, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_logout/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_logout_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + patched_user_logout_stage_request: Optional[PatchedUserLogoutStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLogoutStage: + """stages_user_logout_partial_update + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param patched_user_logout_stage_request: + :type patched_user_logout_stage_request: PatchedUserLogoutStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_logout_stage_request=patched_user_logout_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_logout_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + patched_user_logout_stage_request: Optional[PatchedUserLogoutStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLogoutStage]: + """stages_user_logout_partial_update + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param patched_user_logout_stage_request: + :type patched_user_logout_stage_request: PatchedUserLogoutStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_logout_stage_request=patched_user_logout_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_logout_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + patched_user_logout_stage_request: Optional[PatchedUserLogoutStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_logout_partial_update + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param patched_user_logout_stage_request: + :type patched_user_logout_stage_request: PatchedUserLogoutStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_logout_stage_request=patched_user_logout_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_logout_partial_update_serialize( + self, + stage_uuid, + patched_user_logout_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_logout_stage_request is not None: + _body_params = patched_user_logout_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/user_logout/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_logout_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLogoutStage: + """stages_user_logout_retrieve + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_logout_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLogoutStage]: + """stages_user_logout_retrieve + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_logout_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_logout_retrieve + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_logout_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_logout/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_logout_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + user_logout_stage_request: UserLogoutStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserLogoutStage: + """stages_user_logout_update + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param user_logout_stage_request: (required) + :type user_logout_stage_request: UserLogoutStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_update_serialize( + stage_uuid=stage_uuid, + user_logout_stage_request=user_logout_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_logout_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + user_logout_stage_request: UserLogoutStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserLogoutStage]: + """stages_user_logout_update + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param user_logout_stage_request: (required) + :type user_logout_stage_request: UserLogoutStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_update_serialize( + stage_uuid=stage_uuid, + user_logout_stage_request=user_logout_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_logout_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + user_logout_stage_request: UserLogoutStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_logout_update + + UserLogoutStage Viewset + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param user_logout_stage_request: (required) + :type user_logout_stage_request: UserLogoutStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_update_serialize( + stage_uuid=stage_uuid, + user_logout_stage_request=user_logout_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserLogoutStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_logout_update_serialize( + self, + stage_uuid, + user_logout_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_logout_stage_request is not None: + _body_params = user_logout_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/user_logout/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_logout_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_user_logout_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_logout_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_user_logout_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_logout_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Logout Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_logout_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Logout Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_logout_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_logout_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_logout/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_write_create( + self, + user_write_stage_request: UserWriteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserWriteStage: + """stages_user_write_create + + UserWriteStage Viewset + + :param user_write_stage_request: (required) + :type user_write_stage_request: UserWriteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_create_serialize( + user_write_stage_request=user_write_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_write_create_with_http_info( + self, + user_write_stage_request: UserWriteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserWriteStage]: + """stages_user_write_create + + UserWriteStage Viewset + + :param user_write_stage_request: (required) + :type user_write_stage_request: UserWriteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_create_serialize( + user_write_stage_request=user_write_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_write_create_without_preload_content( + self, + user_write_stage_request: UserWriteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_write_create + + UserWriteStage Viewset + + :param user_write_stage_request: (required) + :type user_write_stage_request: UserWriteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_create_serialize( + user_write_stage_request=user_write_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_write_create_serialize( + self, + user_write_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_write_stage_request is not None: + _body_params = user_write_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/stages/user_write/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_write_destroy( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """stages_user_write_destroy + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_write_destroy_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """stages_user_write_destroy + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_write_destroy_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_write_destroy + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_destroy_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_write_destroy_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/stages/user_write/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_write_list( + self, + create_users_as_inactive: Optional[StrictBool] = None, + create_users_group: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + user_creation_mode: Optional[UserCreationModeEnum] = None, + user_path_template: Optional[StrictStr] = None, + user_type: Optional[UserTypeEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedUserWriteStageList: + """stages_user_write_list + + UserWriteStage Viewset + + :param create_users_as_inactive: + :type create_users_as_inactive: bool + :param create_users_group: + :type create_users_group: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param user_creation_mode: + :type user_creation_mode: UserCreationModeEnum + :param user_path_template: + :type user_path_template: str + :param user_type: + :type user_type: UserTypeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_list_serialize( + create_users_as_inactive=create_users_as_inactive, + create_users_group=create_users_group, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + user_creation_mode=user_creation_mode, + user_path_template=user_path_template, + user_type=user_type, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserWriteStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_write_list_with_http_info( + self, + create_users_as_inactive: Optional[StrictBool] = None, + create_users_group: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + user_creation_mode: Optional[UserCreationModeEnum] = None, + user_path_template: Optional[StrictStr] = None, + user_type: Optional[UserTypeEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedUserWriteStageList]: + """stages_user_write_list + + UserWriteStage Viewset + + :param create_users_as_inactive: + :type create_users_as_inactive: bool + :param create_users_group: + :type create_users_group: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param user_creation_mode: + :type user_creation_mode: UserCreationModeEnum + :param user_path_template: + :type user_path_template: str + :param user_type: + :type user_type: UserTypeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_list_serialize( + create_users_as_inactive=create_users_as_inactive, + create_users_group=create_users_group, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + user_creation_mode=user_creation_mode, + user_path_template=user_path_template, + user_type=user_type, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserWriteStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_write_list_without_preload_content( + self, + create_users_as_inactive: Optional[StrictBool] = None, + create_users_group: Optional[UUID] = None, + name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + stage_uuid: Optional[UUID] = None, + user_creation_mode: Optional[UserCreationModeEnum] = None, + user_path_template: Optional[StrictStr] = None, + user_type: Optional[UserTypeEnum] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_write_list + + UserWriteStage Viewset + + :param create_users_as_inactive: + :type create_users_as_inactive: bool + :param create_users_group: + :type create_users_group: UUID + :param name: + :type name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param stage_uuid: + :type stage_uuid: UUID + :param user_creation_mode: + :type user_creation_mode: UserCreationModeEnum + :param user_path_template: + :type user_path_template: str + :param user_type: + :type user_type: UserTypeEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_list_serialize( + create_users_as_inactive=create_users_as_inactive, + create_users_group=create_users_group, + name=name, + ordering=ordering, + page=page, + page_size=page_size, + search=search, + stage_uuid=stage_uuid, + user_creation_mode=user_creation_mode, + user_path_template=user_path_template, + user_type=user_type, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedUserWriteStageList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_write_list_serialize( + self, + create_users_as_inactive, + create_users_group, + name, + ordering, + page, + page_size, + search, + stage_uuid, + user_creation_mode, + user_path_template, + user_type, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if create_users_as_inactive is not None: + + _query_params.append(('create_users_as_inactive', create_users_as_inactive)) + + if create_users_group is not None: + + _query_params.append(('create_users_group', create_users_group)) + + if name is not None: + + _query_params.append(('name', name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + if stage_uuid is not None: + + _query_params.append(('stage_uuid', stage_uuid)) + + if user_creation_mode is not None: + + _query_params.append(('user_creation_mode', user_creation_mode.value)) + + if user_path_template is not None: + + _query_params.append(('user_path_template', user_path_template)) + + if user_type is not None: + + _query_params.append(('user_type', user_type.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_write/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_write_partial_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + patched_user_write_stage_request: Optional[PatchedUserWriteStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserWriteStage: + """stages_user_write_partial_update + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param patched_user_write_stage_request: + :type patched_user_write_stage_request: PatchedUserWriteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_write_stage_request=patched_user_write_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_write_partial_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + patched_user_write_stage_request: Optional[PatchedUserWriteStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserWriteStage]: + """stages_user_write_partial_update + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param patched_user_write_stage_request: + :type patched_user_write_stage_request: PatchedUserWriteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_write_stage_request=patched_user_write_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_write_partial_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + patched_user_write_stage_request: Optional[PatchedUserWriteStageRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_write_partial_update + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param patched_user_write_stage_request: + :type patched_user_write_stage_request: PatchedUserWriteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_partial_update_serialize( + stage_uuid=stage_uuid, + patched_user_write_stage_request=patched_user_write_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_write_partial_update_serialize( + self, + stage_uuid, + patched_user_write_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_user_write_stage_request is not None: + _body_params = patched_user_write_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/stages/user_write/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_write_retrieve( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserWriteStage: + """stages_user_write_retrieve + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_write_retrieve_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserWriteStage]: + """stages_user_write_retrieve + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_write_retrieve_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_write_retrieve + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_retrieve_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_write_retrieve_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_write/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_write_update( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + user_write_stage_request: UserWriteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> UserWriteStage: + """stages_user_write_update + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param user_write_stage_request: (required) + :type user_write_stage_request: UserWriteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_update_serialize( + stage_uuid=stage_uuid, + user_write_stage_request=user_write_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_write_update_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + user_write_stage_request: UserWriteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[UserWriteStage]: + """stages_user_write_update + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param user_write_stage_request: (required) + :type user_write_stage_request: UserWriteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_update_serialize( + stage_uuid=stage_uuid, + user_write_stage_request=user_write_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_write_update_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + user_write_stage_request: UserWriteStageRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_write_update + + UserWriteStage Viewset + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param user_write_stage_request: (required) + :type user_write_stage_request: UserWriteStageRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_update_serialize( + stage_uuid=stage_uuid, + user_write_stage_request=user_write_stage_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "UserWriteStage", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_write_update_serialize( + self, + stage_uuid, + user_write_stage_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if user_write_stage_request is not None: + _body_params = user_write_stage_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/stages/user_write/{stage_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def stages_user_write_used_by_list( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[UsedBy]: + """stages_user_write_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def stages_user_write_used_by_list_with_http_info( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[UsedBy]]: + """stages_user_write_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def stages_user_write_used_by_list_without_preload_content( + self, + stage_uuid: Annotated[UUID, Field(description="A UUID string identifying this User Write Stage.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """stages_user_write_used_by_list + + Get a list of all objects that use this object + + :param stage_uuid: A UUID string identifying this User Write Stage. (required) + :type stage_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._stages_user_write_used_by_list_serialize( + stage_uuid=stage_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[UsedBy]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _stages_user_write_used_by_list_serialize( + self, + stage_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if stage_uuid is not None: + _path_params['stage_uuid'] = stage_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/stages/user_write/{stage_uuid}/used_by/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/tasks_api.py b/authentik_client/api/tasks_api.py new file mode 100644 index 000000000..b74be36ee --- /dev/null +++ b/authentik_client/api/tasks_api.py @@ -0,0 +1,3080 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictBool, StrictInt, StrictStr +from typing import Any, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.global_task_status import GlobalTaskStatus +from authentik_client.models.paginated_schedule_list import PaginatedScheduleList +from authentik_client.models.paginated_task_list import PaginatedTaskList +from authentik_client.models.patched_schedule_request import PatchedScheduleRequest +from authentik_client.models.schedule import Schedule +from authentik_client.models.schedule_request import ScheduleRequest +from authentik_client.models.task import Task +from authentik_client.models.task_aggregated_status_enum import TaskAggregatedStatusEnum +from authentik_client.models.worker import Worker + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class TasksApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def tasks_schedules_list( + self, + actor_name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + paused: Optional[StrictBool] = None, + rel_obj_content_type__app_label: Optional[StrictStr] = None, + rel_obj_content_type__model: Optional[StrictStr] = None, + rel_obj_id: Optional[StrictStr] = None, + rel_obj_id__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedScheduleList: + """tasks_schedules_list + + + :param actor_name: + :type actor_name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param paused: + :type paused: bool + :param rel_obj_content_type__app_label: + :type rel_obj_content_type__app_label: str + :param rel_obj_content_type__model: + :type rel_obj_content_type__model: str + :param rel_obj_id: + :type rel_obj_id: str + :param rel_obj_id__isnull: + :type rel_obj_id__isnull: bool + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_list_serialize( + actor_name=actor_name, + ordering=ordering, + page=page, + page_size=page_size, + paused=paused, + rel_obj_content_type__app_label=rel_obj_content_type__app_label, + rel_obj_content_type__model=rel_obj_content_type__model, + rel_obj_id=rel_obj_id, + rel_obj_id__isnull=rel_obj_id__isnull, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedScheduleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_schedules_list_with_http_info( + self, + actor_name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + paused: Optional[StrictBool] = None, + rel_obj_content_type__app_label: Optional[StrictStr] = None, + rel_obj_content_type__model: Optional[StrictStr] = None, + rel_obj_id: Optional[StrictStr] = None, + rel_obj_id__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedScheduleList]: + """tasks_schedules_list + + + :param actor_name: + :type actor_name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param paused: + :type paused: bool + :param rel_obj_content_type__app_label: + :type rel_obj_content_type__app_label: str + :param rel_obj_content_type__model: + :type rel_obj_content_type__model: str + :param rel_obj_id: + :type rel_obj_id: str + :param rel_obj_id__isnull: + :type rel_obj_id__isnull: bool + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_list_serialize( + actor_name=actor_name, + ordering=ordering, + page=page, + page_size=page_size, + paused=paused, + rel_obj_content_type__app_label=rel_obj_content_type__app_label, + rel_obj_content_type__model=rel_obj_content_type__model, + rel_obj_id=rel_obj_id, + rel_obj_id__isnull=rel_obj_id__isnull, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedScheduleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_schedules_list_without_preload_content( + self, + actor_name: Optional[StrictStr] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + paused: Optional[StrictBool] = None, + rel_obj_content_type__app_label: Optional[StrictStr] = None, + rel_obj_content_type__model: Optional[StrictStr] = None, + rel_obj_id: Optional[StrictStr] = None, + rel_obj_id__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_schedules_list + + + :param actor_name: + :type actor_name: str + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param paused: + :type paused: bool + :param rel_obj_content_type__app_label: + :type rel_obj_content_type__app_label: str + :param rel_obj_content_type__model: + :type rel_obj_content_type__model: str + :param rel_obj_id: + :type rel_obj_id: str + :param rel_obj_id__isnull: + :type rel_obj_id__isnull: bool + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_list_serialize( + actor_name=actor_name, + ordering=ordering, + page=page, + page_size=page_size, + paused=paused, + rel_obj_content_type__app_label=rel_obj_content_type__app_label, + rel_obj_content_type__model=rel_obj_content_type__model, + rel_obj_id=rel_obj_id, + rel_obj_id__isnull=rel_obj_id__isnull, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedScheduleList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_schedules_list_serialize( + self, + actor_name, + ordering, + page, + page_size, + paused, + rel_obj_content_type__app_label, + rel_obj_content_type__model, + rel_obj_id, + rel_obj_id__isnull, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if actor_name is not None: + + _query_params.append(('actor_name', actor_name)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if paused is not None: + + _query_params.append(('paused', paused)) + + if rel_obj_content_type__app_label is not None: + + _query_params.append(('rel_obj_content_type__app_label', rel_obj_content_type__app_label)) + + if rel_obj_content_type__model is not None: + + _query_params.append(('rel_obj_content_type__model', rel_obj_content_type__model)) + + if rel_obj_id is not None: + + _query_params.append(('rel_obj_id', rel_obj_id)) + + if rel_obj_id__isnull is not None: + + _query_params.append(('rel_obj_id__isnull', rel_obj_id__isnull)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tasks/schedules/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tasks_schedules_partial_update( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + patched_schedule_request: Optional[PatchedScheduleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Schedule: + """tasks_schedules_partial_update + + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param patched_schedule_request: + :type patched_schedule_request: PatchedScheduleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_partial_update_serialize( + id=id, + patched_schedule_request=patched_schedule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Schedule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_schedules_partial_update_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + patched_schedule_request: Optional[PatchedScheduleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Schedule]: + """tasks_schedules_partial_update + + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param patched_schedule_request: + :type patched_schedule_request: PatchedScheduleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_partial_update_serialize( + id=id, + patched_schedule_request=patched_schedule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Schedule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_schedules_partial_update_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + patched_schedule_request: Optional[PatchedScheduleRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_schedules_partial_update + + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param patched_schedule_request: + :type patched_schedule_request: PatchedScheduleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_partial_update_serialize( + id=id, + patched_schedule_request=patched_schedule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Schedule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_schedules_partial_update_serialize( + self, + id, + patched_schedule_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_schedule_request is not None: + _body_params = patched_schedule_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/tasks/schedules/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tasks_schedules_retrieve( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Schedule: + """tasks_schedules_retrieve + + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Schedule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_schedules_retrieve_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Schedule]: + """tasks_schedules_retrieve + + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Schedule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_schedules_retrieve_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_schedules_retrieve + + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Schedule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_schedules_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tasks/schedules/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tasks_schedules_send_create( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """tasks_schedules_send_create + + Trigger this schedule now + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_send_create_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '500': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_schedules_send_create_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """tasks_schedules_send_create + + Trigger this schedule now + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_send_create_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '500': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_schedules_send_create_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_schedules_send_create + + Trigger this schedule now + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_send_create_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '404': None, + '500': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_schedules_send_create_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/tasks/schedules/{id}/send/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tasks_schedules_update( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + schedule_request: ScheduleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Schedule: + """tasks_schedules_update + + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param schedule_request: (required) + :type schedule_request: ScheduleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_update_serialize( + id=id, + schedule_request=schedule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Schedule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_schedules_update_with_http_info( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + schedule_request: ScheduleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Schedule]: + """tasks_schedules_update + + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param schedule_request: (required) + :type schedule_request: ScheduleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_update_serialize( + id=id, + schedule_request=schedule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Schedule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_schedules_update_without_preload_content( + self, + id: Annotated[UUID, Field(description="A UUID string identifying this Schedule.")], + schedule_request: ScheduleRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_schedules_update + + + :param id: A UUID string identifying this Schedule. (required) + :type id: UUID + :param schedule_request: (required) + :type schedule_request: ScheduleRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_schedules_update_serialize( + id=id, + schedule_request=schedule_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Schedule", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_schedules_update_serialize( + self, + id, + schedule_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if schedule_request is not None: + _body_params = schedule_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/tasks/schedules/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tasks_tasks_list( + self, + actor_name: Optional[StrictStr] = None, + aggregated_status: Optional[List[TaskAggregatedStatusEnum]] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + queue_name: Optional[StrictStr] = None, + rel_obj_content_type__app_label: Optional[StrictStr] = None, + rel_obj_content_type__model: Optional[StrictStr] = None, + rel_obj_id: Optional[StrictStr] = None, + rel_obj_id__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + state: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedTaskList: + """tasks_tasks_list + + + :param actor_name: + :type actor_name: str + :param aggregated_status: + :type aggregated_status: List[TaskAggregatedStatusEnum] + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param queue_name: + :type queue_name: str + :param rel_obj_content_type__app_label: + :type rel_obj_content_type__app_label: str + :param rel_obj_content_type__model: + :type rel_obj_content_type__model: str + :param rel_obj_id: + :type rel_obj_id: str + :param rel_obj_id__isnull: + :type rel_obj_id__isnull: bool + :param search: A search term. + :type search: str + :param state: + :type state: TaskStatusEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_list_serialize( + actor_name=actor_name, + aggregated_status=aggregated_status, + ordering=ordering, + page=page, + page_size=page_size, + queue_name=queue_name, + rel_obj_content_type__app_label=rel_obj_content_type__app_label, + rel_obj_content_type__model=rel_obj_content_type__model, + rel_obj_id=rel_obj_id, + rel_obj_id__isnull=rel_obj_id__isnull, + search=search, + state=state, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTaskList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_tasks_list_with_http_info( + self, + actor_name: Optional[StrictStr] = None, + aggregated_status: Optional[List[TaskAggregatedStatusEnum]] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + queue_name: Optional[StrictStr] = None, + rel_obj_content_type__app_label: Optional[StrictStr] = None, + rel_obj_content_type__model: Optional[StrictStr] = None, + rel_obj_id: Optional[StrictStr] = None, + rel_obj_id__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + state: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedTaskList]: + """tasks_tasks_list + + + :param actor_name: + :type actor_name: str + :param aggregated_status: + :type aggregated_status: List[TaskAggregatedStatusEnum] + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param queue_name: + :type queue_name: str + :param rel_obj_content_type__app_label: + :type rel_obj_content_type__app_label: str + :param rel_obj_content_type__model: + :type rel_obj_content_type__model: str + :param rel_obj_id: + :type rel_obj_id: str + :param rel_obj_id__isnull: + :type rel_obj_id__isnull: bool + :param search: A search term. + :type search: str + :param state: + :type state: TaskStatusEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_list_serialize( + actor_name=actor_name, + aggregated_status=aggregated_status, + ordering=ordering, + page=page, + page_size=page_size, + queue_name=queue_name, + rel_obj_content_type__app_label=rel_obj_content_type__app_label, + rel_obj_content_type__model=rel_obj_content_type__model, + rel_obj_id=rel_obj_id, + rel_obj_id__isnull=rel_obj_id__isnull, + search=search, + state=state, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTaskList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_tasks_list_without_preload_content( + self, + actor_name: Optional[StrictStr] = None, + aggregated_status: Optional[List[TaskAggregatedStatusEnum]] = None, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + queue_name: Optional[StrictStr] = None, + rel_obj_content_type__app_label: Optional[StrictStr] = None, + rel_obj_content_type__model: Optional[StrictStr] = None, + rel_obj_id: Optional[StrictStr] = None, + rel_obj_id__isnull: Optional[StrictBool] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + state: Optional[Any] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_tasks_list + + + :param actor_name: + :type actor_name: str + :param aggregated_status: + :type aggregated_status: List[TaskAggregatedStatusEnum] + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param queue_name: + :type queue_name: str + :param rel_obj_content_type__app_label: + :type rel_obj_content_type__app_label: str + :param rel_obj_content_type__model: + :type rel_obj_content_type__model: str + :param rel_obj_id: + :type rel_obj_id: str + :param rel_obj_id__isnull: + :type rel_obj_id__isnull: bool + :param search: A search term. + :type search: str + :param state: + :type state: TaskStatusEnum + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_list_serialize( + actor_name=actor_name, + aggregated_status=aggregated_status, + ordering=ordering, + page=page, + page_size=page_size, + queue_name=queue_name, + rel_obj_content_type__app_label=rel_obj_content_type__app_label, + rel_obj_content_type__model=rel_obj_content_type__model, + rel_obj_id=rel_obj_id, + rel_obj_id__isnull=rel_obj_id__isnull, + search=search, + state=state, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTaskList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_tasks_list_serialize( + self, + actor_name, + aggregated_status, + ordering, + page, + page_size, + queue_name, + rel_obj_content_type__app_label, + rel_obj_content_type__model, + rel_obj_id, + rel_obj_id__isnull, + search, + state, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + 'aggregated_status': 'multi', + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if actor_name is not None: + + _query_params.append(('actor_name', actor_name)) + + if aggregated_status is not None: + + _query_params.append(('aggregated_status', aggregated_status)) + + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if queue_name is not None: + + _query_params.append(('queue_name', queue_name)) + + if rel_obj_content_type__app_label is not None: + + _query_params.append(('rel_obj_content_type__app_label', rel_obj_content_type__app_label)) + + if rel_obj_content_type__model is not None: + + _query_params.append(('rel_obj_content_type__model', rel_obj_content_type__model)) + + if rel_obj_id is not None: + + _query_params.append(('rel_obj_id', rel_obj_id)) + + if rel_obj_id__isnull is not None: + + _query_params.append(('rel_obj_id__isnull', rel_obj_id__isnull)) + + if search is not None: + + _query_params.append(('search', search)) + + if state is not None: + + _query_params.append(('state', state.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tasks/tasks/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tasks_tasks_retrieve( + self, + message_id: Annotated[UUID, Field(description="A UUID string identifying this Task.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Task: + """tasks_tasks_retrieve + + + :param message_id: A UUID string identifying this Task. (required) + :type message_id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_retrieve_serialize( + message_id=message_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Task", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_tasks_retrieve_with_http_info( + self, + message_id: Annotated[UUID, Field(description="A UUID string identifying this Task.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Task]: + """tasks_tasks_retrieve + + + :param message_id: A UUID string identifying this Task. (required) + :type message_id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_retrieve_serialize( + message_id=message_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Task", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_tasks_retrieve_without_preload_content( + self, + message_id: Annotated[UUID, Field(description="A UUID string identifying this Task.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_tasks_retrieve + + + :param message_id: A UUID string identifying this Task. (required) + :type message_id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_retrieve_serialize( + message_id=message_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Task", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_tasks_retrieve_serialize( + self, + message_id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if message_id is not None: + _path_params['message_id'] = message_id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tasks/tasks/{message_id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tasks_tasks_retry_create( + self, + message_id: Annotated[UUID, Field(description="A UUID string identifying this Task.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """tasks_tasks_retry_create + + Retry task + + :param message_id: A UUID string identifying this Task. (required) + :type message_id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_retry_create_serialize( + message_id=message_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_tasks_retry_create_with_http_info( + self, + message_id: Annotated[UUID, Field(description="A UUID string identifying this Task.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """tasks_tasks_retry_create + + Retry task + + :param message_id: A UUID string identifying this Task. (required) + :type message_id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_retry_create_serialize( + message_id=message_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_tasks_retry_create_without_preload_content( + self, + message_id: Annotated[UUID, Field(description="A UUID string identifying this Task.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_tasks_retry_create + + Retry task + + :param message_id: A UUID string identifying this Task. (required) + :type message_id: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_retry_create_serialize( + message_id=message_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_tasks_retry_create_serialize( + self, + message_id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if message_id is not None: + _path_params['message_id'] = message_id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/tasks/tasks/{message_id}/retry/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tasks_tasks_status_retrieve( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GlobalTaskStatus: + """tasks_tasks_status_retrieve + + Global status summary for all tasks + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_status_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GlobalTaskStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_tasks_status_retrieve_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GlobalTaskStatus]: + """tasks_tasks_status_retrieve + + Global status summary for all tasks + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_status_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GlobalTaskStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_tasks_status_retrieve_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_tasks_status_retrieve + + Global status summary for all tasks + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_tasks_status_retrieve_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GlobalTaskStatus", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_tasks_status_retrieve_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tasks/tasks/status/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tasks_workers_list( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> List[Worker]: + """tasks_workers_list + + Get currently connected worker count. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_workers_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[Worker]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tasks_workers_list_with_http_info( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[List[Worker]]: + """tasks_workers_list + + Get currently connected worker count. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_workers_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[Worker]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tasks_workers_list_without_preload_content( + self, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tasks_workers_list + + Get currently connected worker count. + + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tasks_workers_list_serialize( + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "List[Worker]", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tasks_workers_list_serialize( + self, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'authentik' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tasks/workers/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api/tenants_api.py b/authentik_client/api/tenants_api.py new file mode 100644 index 000000000..75461bc84 --- /dev/null +++ b/authentik_client/api/tenants_api.py @@ -0,0 +1,4080 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import warnings +from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt +from typing import Any, Dict, List, Optional, Tuple, Union +from typing_extensions import Annotated + +from pydantic import Field, StrictInt, StrictStr +from typing import Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.domain import Domain +from authentik_client.models.domain_request import DomainRequest +from authentik_client.models.paginated_domain_list import PaginatedDomainList +from authentik_client.models.paginated_tenant_list import PaginatedTenantList +from authentik_client.models.patched_domain_request import PatchedDomainRequest +from authentik_client.models.patched_tenant_request import PatchedTenantRequest +from authentik_client.models.tenant import Tenant +from authentik_client.models.tenant_admin_group_request_request import TenantAdminGroupRequestRequest +from authentik_client.models.tenant_recovery_key_request_request import TenantRecoveryKeyRequestRequest +from authentik_client.models.tenant_recovery_key_response import TenantRecoveryKeyResponse +from authentik_client.models.tenant_request import TenantRequest + +from authentik_client.api_client import ApiClient, RequestSerialized +from authentik_client.api_response import ApiResponse +from authentik_client.rest import RESTResponseType + + +class TenantsApi: + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None) -> None: + if api_client is None: + api_client = ApiClient.get_default() + self.api_client = api_client + + + @validate_call + def tenants_domains_create( + self, + domain_request: DomainRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Domain: + """tenants_domains_create + + Domain ViewSet + + :param domain_request: (required) + :type domain_request: DomainRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_create_serialize( + domain_request=domain_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_domains_create_with_http_info( + self, + domain_request: DomainRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Domain]: + """tenants_domains_create + + Domain ViewSet + + :param domain_request: (required) + :type domain_request: DomainRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_create_serialize( + domain_request=domain_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_domains_create_without_preload_content( + self, + domain_request: DomainRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_domains_create + + Domain ViewSet + + :param domain_request: (required) + :type domain_request: DomainRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_create_serialize( + domain_request=domain_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_domains_create_serialize( + self, + domain_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if domain_request is not None: + _body_params = domain_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/tenants/domains/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_domains_destroy( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """tenants_domains_destroy + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_domains_destroy_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """tenants_domains_destroy + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_domains_destroy_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_domains_destroy + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_destroy_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_domains_destroy_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/tenants/domains/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_domains_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedDomainList: + """tenants_domains_list + + Domain ViewSet + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDomainList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_domains_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedDomainList]: + """tenants_domains_list + + Domain ViewSet + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDomainList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_domains_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_domains_list + + Domain ViewSet + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedDomainList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_domains_list_serialize( + self, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tenants/domains/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_domains_partial_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + patched_domain_request: Optional[PatchedDomainRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Domain: + """tenants_domains_partial_update + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param patched_domain_request: + :type patched_domain_request: PatchedDomainRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_partial_update_serialize( + id=id, + patched_domain_request=patched_domain_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_domains_partial_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + patched_domain_request: Optional[PatchedDomainRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Domain]: + """tenants_domains_partial_update + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param patched_domain_request: + :type patched_domain_request: PatchedDomainRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_partial_update_serialize( + id=id, + patched_domain_request=patched_domain_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_domains_partial_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + patched_domain_request: Optional[PatchedDomainRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_domains_partial_update + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param patched_domain_request: + :type patched_domain_request: PatchedDomainRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_partial_update_serialize( + id=id, + patched_domain_request=patched_domain_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_domains_partial_update_serialize( + self, + id, + patched_domain_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_domain_request is not None: + _body_params = patched_domain_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/tenants/domains/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_domains_retrieve( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Domain: + """tenants_domains_retrieve + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_domains_retrieve_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Domain]: + """tenants_domains_retrieve + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_domains_retrieve_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_domains_retrieve + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_retrieve_serialize( + id=id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_domains_retrieve_serialize( + self, + id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tenants/domains/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_domains_update( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + domain_request: DomainRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Domain: + """tenants_domains_update + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param domain_request: (required) + :type domain_request: DomainRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_update_serialize( + id=id, + domain_request=domain_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_domains_update_with_http_info( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + domain_request: DomainRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Domain]: + """tenants_domains_update + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param domain_request: (required) + :type domain_request: DomainRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_update_serialize( + id=id, + domain_request=domain_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_domains_update_without_preload_content( + self, + id: Annotated[StrictInt, Field(description="A unique integer value identifying this Domain.")], + domain_request: DomainRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_domains_update + + Domain ViewSet + + :param id: A unique integer value identifying this Domain. (required) + :type id: int + :param domain_request: (required) + :type domain_request: DomainRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_domains_update_serialize( + id=id, + domain_request=domain_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Domain", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_domains_update_serialize( + self, + id, + domain_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if id is not None: + _path_params['id'] = id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if domain_request is not None: + _body_params = domain_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/tenants/domains/{id}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_tenants_create( + self, + tenant_request: TenantRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Tenant: + """tenants_tenants_create + + Tenant Viewset + + :param tenant_request: (required) + :type tenant_request: TenantRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_create_serialize( + tenant_request=tenant_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_tenants_create_with_http_info( + self, + tenant_request: TenantRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Tenant]: + """tenants_tenants_create + + Tenant Viewset + + :param tenant_request: (required) + :type tenant_request: TenantRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_create_serialize( + tenant_request=tenant_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_tenants_create_without_preload_content( + self, + tenant_request: TenantRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_tenants_create + + Tenant Viewset + + :param tenant_request: (required) + :type tenant_request: TenantRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_create_serialize( + tenant_request=tenant_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '201': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_tenants_create_serialize( + self, + tenant_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if tenant_request is not None: + _body_params = tenant_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/tenants/tenants/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_tenants_create_admin_group_create( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + tenant_admin_group_request_request: TenantAdminGroupRequestRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """tenants_tenants_create_admin_group_create + + Create admin group and add user to it. + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param tenant_admin_group_request_request: (required) + :type tenant_admin_group_request_request: TenantAdminGroupRequestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_create_admin_group_create_serialize( + tenant_uuid=tenant_uuid, + tenant_admin_group_request_request=tenant_admin_group_request_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_tenants_create_admin_group_create_with_http_info( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + tenant_admin_group_request_request: TenantAdminGroupRequestRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """tenants_tenants_create_admin_group_create + + Create admin group and add user to it. + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param tenant_admin_group_request_request: (required) + :type tenant_admin_group_request_request: TenantAdminGroupRequestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_create_admin_group_create_serialize( + tenant_uuid=tenant_uuid, + tenant_admin_group_request_request=tenant_admin_group_request_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_tenants_create_admin_group_create_without_preload_content( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + tenant_admin_group_request_request: TenantAdminGroupRequestRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_tenants_create_admin_group_create + + Create admin group and add user to it. + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param tenant_admin_group_request_request: (required) + :type tenant_admin_group_request_request: TenantAdminGroupRequestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_create_admin_group_create_serialize( + tenant_uuid=tenant_uuid, + tenant_admin_group_request_request=tenant_admin_group_request_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_tenants_create_admin_group_create_serialize( + self, + tenant_uuid, + tenant_admin_group_request_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if tenant_uuid is not None: + _path_params['tenant_uuid'] = tenant_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if tenant_admin_group_request_request is not None: + _body_params = tenant_admin_group_request_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/tenants/tenants/{tenant_uuid}/create_admin_group/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_tenants_create_recovery_key_create( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + tenant_recovery_key_request_request: TenantRecoveryKeyRequestRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> TenantRecoveryKeyResponse: + """tenants_tenants_create_recovery_key_create + + Create recovery key for user. + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param tenant_recovery_key_request_request: (required) + :type tenant_recovery_key_request_request: TenantRecoveryKeyRequestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_create_recovery_key_create_serialize( + tenant_uuid=tenant_uuid, + tenant_recovery_key_request_request=tenant_recovery_key_request_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TenantRecoveryKeyResponse", + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_tenants_create_recovery_key_create_with_http_info( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + tenant_recovery_key_request_request: TenantRecoveryKeyRequestRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[TenantRecoveryKeyResponse]: + """tenants_tenants_create_recovery_key_create + + Create recovery key for user. + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param tenant_recovery_key_request_request: (required) + :type tenant_recovery_key_request_request: TenantRecoveryKeyRequestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_create_recovery_key_create_serialize( + tenant_uuid=tenant_uuid, + tenant_recovery_key_request_request=tenant_recovery_key_request_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TenantRecoveryKeyResponse", + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_tenants_create_recovery_key_create_without_preload_content( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + tenant_recovery_key_request_request: TenantRecoveryKeyRequestRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_tenants_create_recovery_key_create + + Create recovery key for user. + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param tenant_recovery_key_request_request: (required) + :type tenant_recovery_key_request_request: TenantRecoveryKeyRequestRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_create_recovery_key_create_serialize( + tenant_uuid=tenant_uuid, + tenant_recovery_key_request_request=tenant_recovery_key_request_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "TenantRecoveryKeyResponse", + '400': None, + '404': None, + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_tenants_create_recovery_key_create_serialize( + self, + tenant_uuid, + tenant_recovery_key_request_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if tenant_uuid is not None: + _path_params['tenant_uuid'] = tenant_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if tenant_recovery_key_request_request is not None: + _body_params = tenant_recovery_key_request_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='POST', + resource_path='/tenants/tenants/{tenant_uuid}/create_recovery_key/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_tenants_destroy( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> None: + """tenants_tenants_destroy + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_destroy_serialize( + tenant_uuid=tenant_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_tenants_destroy_with_http_info( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[None]: + """tenants_tenants_destroy + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_destroy_serialize( + tenant_uuid=tenant_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_tenants_destroy_without_preload_content( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_tenants_destroy + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_destroy_serialize( + tenant_uuid=tenant_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '204': None, + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_tenants_destroy_serialize( + self, + tenant_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if tenant_uuid is not None: + _path_params['tenant_uuid'] = tenant_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/tenants/tenants/{tenant_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_tenants_list( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> PaginatedTenantList: + """tenants_tenants_list + + Tenant Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTenantList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_tenants_list_with_http_info( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[PaginatedTenantList]: + """tenants_tenants_list + + Tenant Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTenantList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_tenants_list_without_preload_content( + self, + ordering: Annotated[Optional[StrictStr], Field(description="Which field to use when ordering the results.")] = None, + page: Annotated[Optional[StrictInt], Field(description="A page number within the paginated result set.")] = None, + page_size: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None, + search: Annotated[Optional[StrictStr], Field(description="A search term.")] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_tenants_list + + Tenant Viewset + + :param ordering: Which field to use when ordering the results. + :type ordering: str + :param page: A page number within the paginated result set. + :type page: int + :param page_size: Number of results to return per page. + :type page_size: int + :param search: A search term. + :type search: str + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_list_serialize( + ordering=ordering, + page=page, + page_size=page_size, + search=search, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "PaginatedTenantList", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_tenants_list_serialize( + self, + ordering, + page, + page_size, + search, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if ordering is not None: + + _query_params.append(('ordering', ordering)) + + if page is not None: + + _query_params.append(('page', page)) + + if page_size is not None: + + _query_params.append(('page_size', page_size)) + + if search is not None: + + _query_params.append(('search', search)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tenants/tenants/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_tenants_partial_update( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + patched_tenant_request: Optional[PatchedTenantRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Tenant: + """tenants_tenants_partial_update + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param patched_tenant_request: + :type patched_tenant_request: PatchedTenantRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_partial_update_serialize( + tenant_uuid=tenant_uuid, + patched_tenant_request=patched_tenant_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_tenants_partial_update_with_http_info( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + patched_tenant_request: Optional[PatchedTenantRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Tenant]: + """tenants_tenants_partial_update + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param patched_tenant_request: + :type patched_tenant_request: PatchedTenantRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_partial_update_serialize( + tenant_uuid=tenant_uuid, + patched_tenant_request=patched_tenant_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_tenants_partial_update_without_preload_content( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + patched_tenant_request: Optional[PatchedTenantRequest] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_tenants_partial_update + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param patched_tenant_request: + :type patched_tenant_request: PatchedTenantRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_partial_update_serialize( + tenant_uuid=tenant_uuid, + patched_tenant_request=patched_tenant_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_tenants_partial_update_serialize( + self, + tenant_uuid, + patched_tenant_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if tenant_uuid is not None: + _path_params['tenant_uuid'] = tenant_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if patched_tenant_request is not None: + _body_params = patched_tenant_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='PATCH', + resource_path='/tenants/tenants/{tenant_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_tenants_retrieve( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Tenant: + """tenants_tenants_retrieve + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_retrieve_serialize( + tenant_uuid=tenant_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_tenants_retrieve_with_http_info( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Tenant]: + """tenants_tenants_retrieve + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_retrieve_serialize( + tenant_uuid=tenant_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_tenants_retrieve_without_preload_content( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_tenants_retrieve + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_retrieve_serialize( + tenant_uuid=tenant_uuid, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_tenants_retrieve_serialize( + self, + tenant_uuid, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if tenant_uuid is not None: + _path_params['tenant_uuid'] = tenant_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/tenants/tenants/{tenant_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def tenants_tenants_update( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + tenant_request: TenantRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> Tenant: + """tenants_tenants_update + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param tenant_request: (required) + :type tenant_request: TenantRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_update_serialize( + tenant_uuid=tenant_uuid, + tenant_request=tenant_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def tenants_tenants_update_with_http_info( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + tenant_request: TenantRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[Tenant]: + """tenants_tenants_update + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param tenant_request: (required) + :type tenant_request: TenantRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_update_serialize( + tenant_uuid=tenant_uuid, + tenant_request=tenant_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def tenants_tenants_update_without_preload_content( + self, + tenant_uuid: Annotated[UUID, Field(description="A UUID string identifying this Tenant.")], + tenant_request: TenantRequest, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """tenants_tenants_update + + Tenant Viewset + + :param tenant_uuid: A UUID string identifying this Tenant. (required) + :type tenant_uuid: UUID + :param tenant_request: (required) + :type tenant_request: TenantRequest + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._tenants_tenants_update_serialize( + tenant_uuid=tenant_uuid, + tenant_request=tenant_request, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "Tenant", + '400': "ValidationError", + '403': "GenericError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _tenants_tenants_update_serialize( + self, + tenant_uuid, + tenant_request, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if tenant_uuid is not None: + _path_params['tenant_uuid'] = tenant_uuid + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + if tenant_request is not None: + _body_params = tenant_request + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type + + # authentication setting + _auth_settings: List[str] = [ + ] + + return self.api_client.param_serialize( + method='PUT', + resource_path='/tenants/tenants/{tenant_uuid}/', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + diff --git a/authentik_client/api_client.py b/authentik_client/api_client.py new file mode 100644 index 000000000..9dbd8fe85 --- /dev/null +++ b/authentik_client/api_client.py @@ -0,0 +1,805 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + + +import datetime +from dateutil.parser import parse +from enum import Enum +import decimal +import json +import mimetypes +import os +import re +import tempfile +import uuid + +from urllib.parse import quote +from typing import Tuple, Optional, List, Dict, Union +from pydantic import SecretStr + +from authentik_client.configuration import Configuration +from authentik_client.api_response import ApiResponse, T as ApiResponseT +import authentik_client.models +from authentik_client import rest +from authentik_client.exceptions import ( + ApiValueError, + ApiException, + BadRequestException, + UnauthorizedException, + ForbiddenException, + NotFoundException, + ServiceException +) + +RequestSerialized = Tuple[str, str, Dict[str, str], Optional[str], List[str]] + +class ApiClient: + """Generic API client for OpenAPI client library builds. + + OpenAPI generic API client. This client handles the client- + server communication, and is invariant across implementations. Specifics of + the methods and models for each application are generated from the OpenAPI + templates. + + :param configuration: .Configuration object for this client + :param header_name: a header to pass when making calls to the API. + :param header_value: a header value to pass when making calls to + the API. + :param cookie: a cookie to include in the header when making calls + to the API + """ + + PRIMITIVE_TYPES = (float, bool, bytes, str, int) + NATIVE_TYPES_MAPPING = { + 'int': int, + 'long': int, # TODO remove as only py3 is supported? + 'float': float, + 'str': str, + 'bool': bool, + 'date': datetime.date, + 'datetime': datetime.datetime, + 'decimal': decimal.Decimal, + 'UUID': uuid.UUID, + 'object': object, + } + _pool = None + + def __init__( + self, + configuration=None, + header_name=None, + header_value=None, + cookie=None + ) -> None: + # use default configuration if none is provided + if configuration is None: + configuration = Configuration.get_default() + self.configuration = configuration + + self.rest_client = rest.RESTClientObject(configuration) + self.default_headers = {} + if header_name is not None: + self.default_headers[header_name] = header_value + self.cookie = cookie + # Set default User-Agent. + self.user_agent = 'OpenAPI-Generator/2026.5.7/python' + self.client_side_validation = configuration.client_side_validation + + def __enter__(self): + return self + + def __exit__(self, exc_type, exc_value, traceback): + pass + + @property + def user_agent(self): + """User agent for this API client""" + return self.default_headers['User-Agent'] + + @user_agent.setter + def user_agent(self, value): + self.default_headers['User-Agent'] = value + + def set_default_header(self, header_name, header_value): + self.default_headers[header_name] = header_value + + + _default = None + + @classmethod + def get_default(cls): + """Return new instance of ApiClient. + + This method returns newly created, based on default constructor, + object of ApiClient class or returns a copy of default + ApiClient. + + :return: The ApiClient object. + """ + if cls._default is None: + cls._default = ApiClient() + return cls._default + + @classmethod + def set_default(cls, default): + """Set default instance of ApiClient. + + It stores default ApiClient. + + :param default: object of ApiClient. + """ + cls._default = default + + def param_serialize( + self, + method, + resource_path, + path_params=None, + query_params=None, + header_params=None, + body=None, + post_params=None, + files=None, auth_settings=None, + collection_formats=None, + _host=None, + _request_auth=None + ) -> RequestSerialized: + + """Builds the HTTP request params needed by the request. + :param method: Method to call. + :param resource_path: Path to method endpoint. + :param path_params: Path parameters in the url. + :param query_params: Query parameters in the url. + :param header_params: Header parameters to be + placed in the request header. + :param body: Request body. + :param post_params dict: Request post form parameters, + for `application/x-www-form-urlencoded`, `multipart/form-data`. + :param auth_settings list: Auth Settings names for the request. + :param files dict: key -> filename, value -> filepath, + for `multipart/form-data`. + :param collection_formats: dict of collection formats for path, query, + header, and post parameters. + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the authentication + in the spec for a single request. + :return: tuple of form (path, http_method, query_params, header_params, + body, post_params, files) + """ + + config = self.configuration + + # header parameters + header_params = header_params or {} + header_params.update(self.default_headers) + if self.cookie: + header_params['Cookie'] = self.cookie + if header_params: + header_params = self.sanitize_for_serialization(header_params) + header_params = dict( + self.parameters_to_tuples(header_params,collection_formats) + ) + + # path parameters + if path_params: + path_params = self.sanitize_for_serialization(path_params) + path_params = self.parameters_to_tuples( + path_params, + collection_formats + ) + for k, v in path_params: + # specified safe chars, encode everything + resource_path = resource_path.replace( + '{%s}' % k, + quote(str(v), safe=config.safe_chars_for_path_param) + ) + + # post parameters + if post_params or files: + post_params = post_params if post_params else [] + post_params = self.sanitize_for_serialization(post_params) + post_params = self.parameters_to_tuples( + post_params, + collection_formats + ) + if files: + post_params.extend(self.files_parameters(files)) + + # auth setting + self.update_params_for_auth( + header_params, + query_params, + auth_settings, + resource_path, + method, + body, + request_auth=_request_auth + ) + + # body + if body: + body = self.sanitize_for_serialization(body) + + # request url + if _host is None or self.configuration.ignore_operation_servers: + url = self.configuration.host + resource_path + else: + # use server/host defined in path or operation instead + url = _host + resource_path + + # query parameters + if query_params: + query_params = self.sanitize_for_serialization(query_params) + url_query = self.parameters_to_url_query( + query_params, + collection_formats + ) + url += "?" + url_query + + return method, url, header_params, body, post_params + + + def call_api( + self, + method, + url, + header_params=None, + body=None, + post_params=None, + _request_timeout=None + ) -> rest.RESTResponse: + """Makes the HTTP request (synchronous) + :param method: Method to call. + :param url: Path to method endpoint. + :param header_params: Header parameters to be + placed in the request header. + :param body: Request body. + :param post_params dict: Request post form parameters, + for `application/x-www-form-urlencoded`, `multipart/form-data`. + :param _request_timeout: timeout setting for this request. + :return: RESTResponse + """ + + try: + # perform request and return response + response_data = self.rest_client.request( + method, url, + headers=header_params, + body=body, post_params=post_params, + _request_timeout=_request_timeout + ) + + except ApiException as e: + raise e + + return response_data + + def response_deserialize( + self, + response_data: rest.RESTResponse, + response_types_map: Optional[Dict[str, ApiResponseT]]=None + ) -> ApiResponse[ApiResponseT]: + """Deserializes response into an object. + :param response_data: RESTResponse object to be deserialized. + :param response_types_map: dict of response types. + :return: ApiResponse + """ + + msg = "RESTResponse.read() must be called before passing it to response_deserialize()" + assert response_data.data is not None, msg + + response_type = response_types_map.get(str(response_data.status), None) + if not response_type and isinstance(response_data.status, int) and 100 <= response_data.status <= 599: + # if not found, look for '1XX', '2XX', etc. + response_type = response_types_map.get(str(response_data.status)[0] + "XX", None) + + # deserialize response data + response_text = None + return_data = None + try: + if response_type in ("bytearray", "bytes"): + return_data = response_data.data + elif response_type == "file": + return_data = self.__deserialize_file(response_data) + elif response_type is not None: + match = None + content_type = response_data.headers.get('content-type') + if content_type is not None: + match = re.search(r"charset=([a-zA-Z\-\d]+)[\s;]?", content_type) + encoding = match.group(1) if match else "utf-8" + response_text = response_data.data.decode(encoding) + return_data = self.deserialize(response_text, response_type, content_type) + finally: + if not 200 <= response_data.status <= 299: + raise ApiException.from_response( + http_resp=response_data, + body=response_text, + data=return_data, + ) + + return ApiResponse( + status_code = response_data.status, + data = return_data, + headers = response_data.headers, + raw_data = response_data.data + ) + + def sanitize_for_serialization(self, obj): + """Builds a JSON POST object. + + If obj is None, return None. + If obj is SecretStr, return obj.get_secret_value() + If obj is str, int, long, float, bool, return directly. + If obj is datetime.datetime, datetime.date + convert to string in iso8601 format. + If obj is decimal.Decimal return string representation. + If obj is list, sanitize each element in the list. + If obj is dict, return the dict. + If obj is OpenAPI model, return the properties dict. + + :param obj: The data to serialize. + :return: The serialized form of data. + """ + if obj is None: + return None + elif isinstance(obj, Enum): + return obj.value + elif isinstance(obj, SecretStr): + return obj.get_secret_value() + elif isinstance(obj, self.PRIMITIVE_TYPES): + return obj + elif isinstance(obj, uuid.UUID): + return str(obj) + elif isinstance(obj, list): + return [ + self.sanitize_for_serialization(sub_obj) for sub_obj in obj + ] + elif isinstance(obj, tuple): + return tuple( + self.sanitize_for_serialization(sub_obj) for sub_obj in obj + ) + elif isinstance(obj, (datetime.datetime, datetime.date)): + return obj.isoformat() + elif isinstance(obj, decimal.Decimal): + return str(obj) + elif isinstance(obj, dict): + return { + key: self.sanitize_for_serialization(val) + for key, val in obj.items() + } + + # Convert model obj to dict except + # attributes `openapi_types`, `attribute_map` + # and attributes which value is not None. + # Convert attribute name to json key in + # model definition for request. + if hasattr(obj, 'to_dict') and callable(getattr(obj, 'to_dict')): + obj_dict = obj.to_dict() + else: + obj_dict = obj.__dict__ + + return self.sanitize_for_serialization(obj_dict) + + + def deserialize(self, response_text: str, response_type: str, content_type: Optional[str]): + """Deserializes response into an object. + + :param response: RESTResponse object to be deserialized. + :param response_type: class literal for + deserialized object, or string of class name. + :param content_type: content type of response. + + :return: deserialized object. + """ + + # fetch data from response object + if content_type is None: + try: + data = json.loads(response_text) + except ValueError: + data = response_text + elif re.match(r'^application/(json|[\w!#$&.+\-^_]+\+json)\s*(;|$)', content_type, re.IGNORECASE): + if response_text == "": + data = "" + else: + data = json.loads(response_text) + elif re.match(r'^text\/[a-z.+-]+\s*(;|$)', content_type, re.IGNORECASE): + data = response_text + else: + raise ApiException( + status=0, + reason="Unsupported content type: {0}".format(content_type) + ) + + return self.__deserialize(data, response_type) + + def __deserialize(self, data, klass): + """Deserializes dict, list, str into an object. + + :param data: dict, list or str. + :param klass: class literal, or string of class name. + + :return: object. + """ + if data is None: + return None + + if isinstance(klass, str): + if klass.startswith('List['): + m = re.match(r'List\[(.*)]', klass) + assert m is not None, "Malformed List type definition" + sub_kls = m.group(1) + return [self.__deserialize(sub_data, sub_kls) + for sub_data in data] + + if klass.startswith('Dict['): + m = re.match(r'Dict\[([^,]*), (.*)]', klass) + assert m is not None, "Malformed Dict type definition" + sub_kls = m.group(2) + return {k: self.__deserialize(v, sub_kls) + for k, v in data.items()} + + # convert str to class + if klass in self.NATIVE_TYPES_MAPPING: + klass = self.NATIVE_TYPES_MAPPING[klass] + else: + klass = getattr(authentik_client.models, klass) + + if klass in self.PRIMITIVE_TYPES: + return self.__deserialize_primitive(data, klass) + elif klass is object: + return self.__deserialize_object(data) + elif klass is datetime.date: + return self.__deserialize_date(data) + elif klass is datetime.datetime: + return self.__deserialize_datetime(data) + elif klass is decimal.Decimal: + return decimal.Decimal(data) + elif klass is uuid.UUID: + return uuid.UUID(data) + elif issubclass(klass, Enum): + return self.__deserialize_enum(data, klass) + else: + return self.__deserialize_model(data, klass) + + def parameters_to_tuples(self, params, collection_formats): + """Get parameters as list of tuples, formatting collections. + + :param params: Parameters as dict or list of two-tuples + :param dict collection_formats: Parameter collection formats + :return: Parameters as list of tuples, collections formatted + """ + new_params: List[Tuple[str, str]] = [] + if collection_formats is None: + collection_formats = {} + for k, v in params.items() if isinstance(params, dict) else params: + if k in collection_formats: + collection_format = collection_formats[k] + if collection_format == 'multi': + new_params.extend((k, value) for value in v) + else: + if collection_format == 'ssv': + delimiter = ' ' + elif collection_format == 'tsv': + delimiter = '\t' + elif collection_format == 'pipes': + delimiter = '|' + else: # csv is the default + delimiter = ',' + new_params.append( + (k, delimiter.join(str(value) for value in v))) + else: + new_params.append((k, v)) + return new_params + + def parameters_to_url_query(self, params, collection_formats): + """Get parameters as list of tuples, formatting collections. + + :param params: Parameters as dict or list of two-tuples + :param dict collection_formats: Parameter collection formats + :return: URL query string (e.g. a=Hello%20World&b=123) + """ + new_params: List[Tuple[str, str]] = [] + if collection_formats is None: + collection_formats = {} + for k, v in params.items() if isinstance(params, dict) else params: + if isinstance(v, bool): + v = str(v).lower() + if isinstance(v, (int, float)): + v = str(v) + if isinstance(v, dict): + v = json.dumps(v) + + if k in collection_formats: + collection_format = collection_formats[k] + if collection_format == 'multi': + new_params.extend((k, quote(str(value))) for value in v) + else: + if collection_format == 'ssv': + delimiter = ' ' + elif collection_format == 'tsv': + delimiter = '\t' + elif collection_format == 'pipes': + delimiter = '|' + else: # csv is the default + delimiter = ',' + new_params.append( + (k, delimiter.join(quote(str(value)) for value in v)) + ) + else: + new_params.append((k, quote(str(v)))) + + return "&".join(["=".join(map(str, item)) for item in new_params]) + + def files_parameters( + self, + files: Dict[str, Union[str, bytes, List[str], List[bytes], Tuple[str, bytes]]], + ): + """Builds form parameters. + + :param files: File parameters. + :return: Form parameters with files. + """ + params = [] + for k, v in files.items(): + if isinstance(v, str): + with open(v, 'rb') as f: + filename = os.path.basename(f.name) + filedata = f.read() + elif isinstance(v, bytes): + filename = k + filedata = v + elif isinstance(v, tuple): + filename, filedata = v + elif isinstance(v, list): + for file_param in v: + params.extend(self.files_parameters({k: file_param})) + continue + else: + raise ValueError("Unsupported file value") + mimetype = ( + mimetypes.guess_type(filename)[0] + or 'application/octet-stream' + ) + params.append( + tuple([k, tuple([filename, filedata, mimetype])]) + ) + return params + + def select_header_accept(self, accepts: List[str]) -> Optional[str]: + """Returns `Accept` based on an array of accepts provided. + + :param accepts: List of headers. + :return: Accept (e.g. application/json). + """ + if not accepts: + return None + + for accept in accepts: + if re.search('json', accept, re.IGNORECASE): + return accept + + return accepts[0] + + def select_header_content_type(self, content_types): + """Returns `Content-Type` based on an array of content_types provided. + + :param content_types: List of content-types. + :return: Content-Type (e.g. application/json). + """ + if not content_types: + return None + + for content_type in content_types: + if re.search('json', content_type, re.IGNORECASE): + return content_type + + return content_types[0] + + def update_params_for_auth( + self, + headers, + queries, + auth_settings, + resource_path, + method, + body, + request_auth=None + ) -> None: + """Updates header and query params based on authentication setting. + + :param headers: Header parameters dict to be updated. + :param queries: Query parameters tuple list to be updated. + :param auth_settings: Authentication setting identifiers list. + :resource_path: A string representation of the HTTP request resource path. + :method: A string representation of the HTTP request method. + :body: A object representing the body of the HTTP request. + The object type is the return value of sanitize_for_serialization(). + :param request_auth: if set, the provided settings will + override the token in the configuration. + """ + if not auth_settings: + return + + if request_auth: + self._apply_auth_params( + headers, + queries, + resource_path, + method, + body, + request_auth + ) + else: + for auth in auth_settings: + auth_setting = self.configuration.auth_settings().get(auth) + if auth_setting: + self._apply_auth_params( + headers, + queries, + resource_path, + method, + body, + auth_setting + ) + + def _apply_auth_params( + self, + headers, + queries, + resource_path, + method, + body, + auth_setting + ) -> None: + """Updates the request parameters based on a single auth_setting + + :param headers: Header parameters dict to be updated. + :param queries: Query parameters tuple list to be updated. + :resource_path: A string representation of the HTTP request resource path. + :method: A string representation of the HTTP request method. + :body: A object representing the body of the HTTP request. + The object type is the return value of sanitize_for_serialization(). + :param auth_setting: auth settings for the endpoint + """ + if auth_setting['in'] == 'cookie': + headers['Cookie'] = auth_setting['value'] + elif auth_setting['in'] == 'header': + if auth_setting['type'] != 'http-signature': + headers[auth_setting['key']] = auth_setting['value'] + elif auth_setting['in'] == 'query': + queries.append((auth_setting['key'], auth_setting['value'])) + else: + raise ApiValueError( + 'Authentication token must be in `query` or `header`' + ) + + def __deserialize_file(self, response): + """Deserializes body to file + + Saves response body into a file in a temporary folder, + using the filename from the `Content-Disposition` header if provided. + + handle file downloading + save response body into a tmp file and return the instance + + :param response: RESTResponse. + :return: file path. + """ + fd, path = tempfile.mkstemp(dir=self.configuration.temp_folder_path) + os.close(fd) + os.remove(path) + + content_disposition = response.headers.get("Content-Disposition") + if content_disposition: + m = re.search( + r'filename=[\'"]?([^\'"\s]+)[\'"]?', + content_disposition + ) + assert m is not None, "Unexpected 'content-disposition' header value" + filename = os.path.basename(m.group(1)) # Strip any directory traversal + if filename in ("", ".", ".."): # fall back to tmp filename + filename = os.path.basename(path) + path = os.path.join(os.path.dirname(path), filename) + + with open(path, "wb") as f: + f.write(response.data) + + return path + + def __deserialize_primitive(self, data, klass): + """Deserializes string to primitive type. + + :param data: str. + :param klass: class literal. + + :return: int, long, float, str, bool. + """ + try: + return klass(data) + except UnicodeEncodeError: + return str(data) + except TypeError: + return data + + def __deserialize_object(self, value): + """Return an original value. + + :return: object. + """ + return value + + def __deserialize_date(self, string): + """Deserializes string to date. + + :param string: str. + :return: date. + """ + try: + return parse(string).date() + except ImportError: + return string + except ValueError: + raise rest.ApiException( + status=0, + reason="Failed to parse `{0}` as date object".format(string) + ) + + def __deserialize_datetime(self, string): + """Deserializes string to datetime. + + The string should be in iso8601 datetime format. + + :param string: str. + :return: datetime. + """ + try: + return parse(string) + except ImportError: + return string + except ValueError: + raise rest.ApiException( + status=0, + reason=( + "Failed to parse `{0}` as datetime object" + .format(string) + ) + ) + + def __deserialize_enum(self, data, klass): + """Deserializes primitive type to enum. + + :param data: primitive type. + :param klass: class literal. + :return: enum value. + """ + try: + return klass(data) + except ValueError: + raise rest.ApiException( + status=0, + reason=( + "Failed to parse `{0}` as `{1}`" + .format(data, klass) + ) + ) + + def __deserialize_model(self, data, klass): + """Deserializes list or dict to model. + + :param data: dict, list. + :param klass: class literal. + :return: model object. + """ + + return klass.from_dict(data) diff --git a/authentik_client/api_response.py b/authentik_client/api_response.py new file mode 100644 index 000000000..9bc7c11f6 --- /dev/null +++ b/authentik_client/api_response.py @@ -0,0 +1,21 @@ +"""API response object.""" + +from __future__ import annotations +from typing import Optional, Generic, Mapping, TypeVar +from pydantic import Field, StrictInt, StrictBytes, BaseModel + +T = TypeVar("T") + +class ApiResponse(BaseModel, Generic[T]): + """ + API response object + """ + + status_code: StrictInt = Field(description="HTTP status code") + headers: Optional[Mapping[str, str]] = Field(None, description="HTTP headers") + data: T = Field(description="Deserialized data given the data type") + raw_data: StrictBytes = Field(description="Raw data (HTTP response body)") + + model_config = { + "arbitrary_types_allowed": True + } diff --git a/authentik_client/configuration.py b/authentik_client/configuration.py new file mode 100644 index 000000000..1b27d8798 --- /dev/null +++ b/authentik_client/configuration.py @@ -0,0 +1,622 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import copy +import http.client as httplib +import logging +from logging import FileHandler +import multiprocessing +import sys +from typing import Any, ClassVar, Dict, List, Literal, Optional, TypedDict, Union +from typing_extensions import NotRequired, Self + +import urllib3 + + +JSON_SCHEMA_VALIDATION_KEYWORDS = { + 'multipleOf', 'maximum', 'exclusiveMaximum', + 'minimum', 'exclusiveMinimum', 'maxLength', + 'minLength', 'pattern', 'maxItems', 'minItems' +} + +ServerVariablesT = Dict[str, str] + +GenericAuthSetting = TypedDict( + "GenericAuthSetting", + { + "type": str, + "in": str, + "key": str, + "value": str, + }, +) + + +OAuth2AuthSetting = TypedDict( + "OAuth2AuthSetting", + { + "type": Literal["oauth2"], + "in": Literal["header"], + "key": Literal["Authorization"], + "value": str, + }, +) + + +APIKeyAuthSetting = TypedDict( + "APIKeyAuthSetting", + { + "type": Literal["api_key"], + "in": str, + "key": str, + "value": Optional[str], + }, +) + + +BasicAuthSetting = TypedDict( + "BasicAuthSetting", + { + "type": Literal["basic"], + "in": Literal["header"], + "key": Literal["Authorization"], + "value": Optional[str], + }, +) + + +BearerFormatAuthSetting = TypedDict( + "BearerFormatAuthSetting", + { + "type": Literal["bearer"], + "in": Literal["header"], + "format": Literal["JWT"], + "key": Literal["Authorization"], + "value": str, + }, +) + + +BearerAuthSetting = TypedDict( + "BearerAuthSetting", + { + "type": Literal["bearer"], + "in": Literal["header"], + "key": Literal["Authorization"], + "value": str, + }, +) + + +HTTPSignatureAuthSetting = TypedDict( + "HTTPSignatureAuthSetting", + { + "type": Literal["http-signature"], + "in": Literal["header"], + "key": Literal["Authorization"], + "value": None, + }, +) + + +AuthSettings = TypedDict( + "AuthSettings", + { + "authentik": BearerAuthSetting, + "authentik_device_enroll": BearerAuthSetting, + "authentik_device_federation": BearerAuthSetting, + }, + total=False, +) + + +class HostSettingVariable(TypedDict): + description: str + default_value: str + enum_values: List[str] + + +class HostSetting(TypedDict): + url: str + description: str + variables: NotRequired[Dict[str, HostSettingVariable]] + + +class Configuration: + """This class contains various settings of the API client. + + :param host: Base url. + :param ignore_operation_servers + Boolean to ignore operation servers for the API client. + Config will use `host` as the base url regardless of the operation servers. + :param api_key: Dict to store API key(s). + Each entry in the dict specifies an API key. + The dict key is the name of the security scheme in the OAS specification. + The dict value is the API key secret. + :param api_key_prefix: Dict to store API prefix (e.g. Bearer). + The dict key is the name of the security scheme in the OAS specification. + The dict value is an API key prefix when generating the auth data. + :param username: Username for HTTP basic authentication. + :param password: Password for HTTP basic authentication. + :param access_token: Access token. + :param server_index: Index to servers configuration. + :param server_variables: Mapping with string values to replace variables in + templated server configuration. The validation of enums is performed for + variables with defined enum values before. + :param server_operation_index: Mapping from operation ID to an index to server + configuration. + :param server_operation_variables: Mapping from operation ID to a mapping with + string values to replace variables in templated server configuration. + The validation of enums is performed for variables with defined enum + values before. + :param verify_ssl: bool - Set this to false to skip verifying SSL certificate + when calling API from https server. + :param ssl_ca_cert: str - the path to a file of concatenated CA certificates + in PEM format. + :param retries: int | urllib3.util.retry.Retry - Retry configuration. + :param ca_cert_data: verify the peer using concatenated CA certificate data + in PEM (str) or DER (bytes) format. + :param cert_file: the path to a client certificate file, for mTLS. + :param key_file: the path to a client key file, for mTLS. + :param assert_hostname: Set this to True/False to enable/disable SSL hostname verification. + :param tls_server_name: SSL/TLS Server Name Indication (SNI). Set this to the SNI value expected by the server. + :param connection_pool_maxsize: Connection pool max size. None in the constructor is coerced to 100 for async and cpu_count * 5 for sync. + :param proxy: Proxy URL. + :param proxy_headers: Proxy headers. + :param safe_chars_for_path_param: Safe characters for path parameter encoding. + :param client_side_validation: Enable client-side validation. Default True. + :param socket_options: Options to pass down to the underlying urllib3 socket. + :param datetime_format: Datetime format string for serialization. + :param date_format: Date format string for serialization. + + :Example: + """ + + _default: ClassVar[Optional[Self]] = None + + def __init__( + self, + host: Optional[str]=None, + api_key: Optional[Dict[str, str]]=None, + api_key_prefix: Optional[Dict[str, str]]=None, + username: Optional[str]=None, + password: Optional[str]=None, + access_token: Optional[str]=None, + server_index: Optional[int]=None, + server_variables: Optional[ServerVariablesT]=None, + server_operation_index: Optional[Dict[int, int]]=None, + server_operation_variables: Optional[Dict[int, ServerVariablesT]]=None, + ignore_operation_servers: bool=False, + ssl_ca_cert: Optional[str]=None, + retries: Optional[Union[int, urllib3.util.retry.Retry]] = None, + ca_cert_data: Optional[Union[str, bytes]] = None, + cert_file: Optional[str]=None, + key_file: Optional[str]=None, + verify_ssl: bool=True, + assert_hostname: Optional[bool]=None, + tls_server_name: Optional[str]=None, + connection_pool_maxsize: Optional[int]=None, + proxy: Optional[str]=None, + proxy_headers: Optional[Any]=None, + safe_chars_for_path_param: str='', + client_side_validation: bool=True, + socket_options: Optional[Any]=None, + datetime_format: str="%Y-%m-%dT%H:%M:%S.%f%z", + date_format: str="%Y-%m-%d", + *, + debug: Optional[bool] = None, + ) -> None: + """Constructor + """ + self._base_path = "/api/v3" if host is None else host + """Default Base url + """ + self.server_index = 0 if server_index is None and host is None else server_index + self.server_operation_index = server_operation_index or {} + """Default server index + """ + self.server_variables = server_variables or {} + self.server_operation_variables = server_operation_variables or {} + """Default server variables + """ + self.ignore_operation_servers = ignore_operation_servers + """Ignore operation servers + """ + self.temp_folder_path = None + """Temp file folder for downloading files + """ + # Authentication Settings + self.api_key = {} + if api_key: + self.api_key = api_key + """dict to store API key(s) + """ + self.api_key_prefix = {} + if api_key_prefix: + self.api_key_prefix = api_key_prefix + """dict to store API prefix (e.g. Bearer) + """ + self.refresh_api_key_hook = None + """function hook to refresh API key if expired + """ + self.username = username + """Username for HTTP basic authentication + """ + self.password = password + """Password for HTTP basic authentication + """ + self.access_token = access_token + """Access token + """ + self.logger = {} + """Logging Settings + """ + self.logger["package_logger"] = logging.getLogger("authentik_client") + self.logger["urllib3_logger"] = logging.getLogger("urllib3") + self.logger_format = '%(asctime)s %(levelname)s %(message)s' + """Log format + """ + self.logger_stream_handler = None + """Log stream handler + """ + self.logger_file_handler: Optional[FileHandler] = None + """Log file handler + """ + self.logger_file = None + """Debug file location + """ + if debug is not None: + self.debug = debug + else: + self.__debug = False + """Debug switch + """ + + self.verify_ssl = verify_ssl + """SSL/TLS verification + Set this to false to skip verifying SSL certificate when calling API + from https server. + """ + self.ssl_ca_cert = ssl_ca_cert + """Set this to customize the certificate file to verify the peer. + """ + self.ca_cert_data = ca_cert_data + """Set this to verify the peer using PEM (str) or DER (bytes) + certificate data. + """ + self.cert_file = cert_file + """client certificate file + """ + self.key_file = key_file + """client key file + """ + self.assert_hostname = assert_hostname + """Set this to True/False to enable/disable SSL hostname verification. + """ + self.tls_server_name = tls_server_name + """SSL/TLS Server Name Indication (SNI) + Set this to the SNI value expected by the server. + """ + + self.connection_pool_maxsize = connection_pool_maxsize if connection_pool_maxsize is not None else multiprocessing.cpu_count() * 5 + """urllib3 connection pool's maximum number of connections saved + per pool. None in the constructor is coerced to cpu_count * 5. + """ + + self.proxy = proxy + """Proxy URL + """ + self.proxy_headers = proxy_headers + """Proxy headers + """ + self.safe_chars_for_path_param = safe_chars_for_path_param + """Safe chars for path_param + """ + self.retries = retries + """Retry configuration + """ + # Enable client side validation + self.client_side_validation = client_side_validation + + self.socket_options = socket_options + """Options to pass down to the underlying urllib3 socket + """ + + self.datetime_format = datetime_format + """datetime format + """ + + self.date_format = date_format + """date format + """ + + def __deepcopy__(self, memo: Dict[int, Any]) -> Self: + cls = self.__class__ + result = cls.__new__(cls) + memo[id(self)] = result + for k, v in self.__dict__.items(): + if k not in ('logger', 'logger_file_handler'): + setattr(result, k, copy.deepcopy(v, memo)) + # shallow copy of loggers + result.logger = copy.copy(self.logger) + # use setters to configure loggers + result.logger_file = self.logger_file + result.debug = self.debug + return result + + def __setattr__(self, name: str, value: Any) -> None: + object.__setattr__(self, name, value) + + @classmethod + def set_default(cls, default: Optional[Self]) -> None: + """Set default instance of configuration. + + It stores default configuration, which can be + returned by get_default_copy method. + + :param default: object of Configuration + """ + cls._default = default + + @classmethod + def get_default_copy(cls) -> Self: + """Deprecated. Please use `get_default` instead. + + Deprecated. Please use `get_default` instead. + + :return: The configuration object. + """ + return cls.get_default() + + @classmethod + def get_default(cls) -> Self: + """Return the default configuration. + + This method returns newly created, based on default constructor, + object of Configuration class or returns a copy of default + configuration. + + :return: The configuration object. + """ + if cls._default is None: + cls._default = cls() + return cls._default + + @property + def logger_file(self) -> Optional[str]: + """The logger file. + + If the logger_file is None, then add stream handler and remove file + handler. Otherwise, add file handler and remove stream handler. + + :param value: The logger_file path. + :type: str + """ + return self.__logger_file + + @logger_file.setter + def logger_file(self, value: Optional[str]) -> None: + """The logger file. + + If the logger_file is None, then add stream handler and remove file + handler. Otherwise, add file handler and remove stream handler. + + :param value: The logger_file path. + :type: str + """ + self.__logger_file = value + if self.__logger_file: + # If set logging file, + # then add file handler and remove stream handler. + self.logger_file_handler = logging.FileHandler(self.__logger_file) + self.logger_file_handler.setFormatter(self.logger_formatter) + for _, logger in self.logger.items(): + logger.addHandler(self.logger_file_handler) + + @property + def debug(self) -> bool: + """Debug status + + :param value: The debug status, True or False. + :type: bool + """ + return self.__debug + + @debug.setter + def debug(self, value: bool) -> None: + """Debug status + + :param value: The debug status, True or False. + :type: bool + """ + self.__debug = value + if self.__debug: + # if debug status is True, turn on debug logging + for _, logger in self.logger.items(): + logger.setLevel(logging.DEBUG) + # turn on httplib debug + httplib.HTTPConnection.debuglevel = 1 + else: + # if debug status is False, turn off debug logging, + # setting log level to default `logging.WARNING` + for _, logger in self.logger.items(): + logger.setLevel(logging.WARNING) + # turn off httplib debug + httplib.HTTPConnection.debuglevel = 0 + + @property + def logger_format(self) -> str: + """The logger format. + + The logger_formatter will be updated when sets logger_format. + + :param value: The format string. + :type: str + """ + return self.__logger_format + + @logger_format.setter + def logger_format(self, value: str) -> None: + """The logger format. + + The logger_formatter will be updated when sets logger_format. + + :param value: The format string. + :type: str + """ + self.__logger_format = value + self.logger_formatter = logging.Formatter(self.__logger_format) + + def get_api_key_with_prefix(self, identifier: str, alias: Optional[str]=None) -> Optional[str]: + """Gets API key (with prefix if set). + + :param identifier: The identifier of apiKey. + :param alias: The alternative identifier of apiKey. + :return: The token for api key authentication. + """ + if self.refresh_api_key_hook is not None: + self.refresh_api_key_hook(self) + key = self.api_key.get(identifier, self.api_key.get(alias) if alias is not None else None) + if key: + prefix = self.api_key_prefix.get(identifier) + if prefix: + return "%s %s" % (prefix, key) + else: + return key + + return None + + def get_basic_auth_token(self) -> Optional[str]: + """Gets HTTP basic authentication header (string). + + :return: The token for basic HTTP authentication. + """ + username = "" + if self.username is not None: + username = self.username + password = "" + if self.password is not None: + password = self.password + + return urllib3.util.make_headers( + basic_auth=username + ':' + password + ).get('authorization') + + def auth_settings(self)-> AuthSettings: + """Gets Auth Settings dict for api client. + + :return: The Auth Settings information dict. + """ + auth: AuthSettings = {} + if self.access_token is not None: + auth['authentik'] = { + 'type': 'bearer', + 'in': 'header', + 'key': 'Authorization', + 'value': 'Bearer ' + self.access_token + } + if self.access_token is not None: + auth['authentik_device_enroll'] = { + 'type': 'bearer', + 'in': 'header', + 'key': 'Authorization', + 'value': 'Bearer ' + self.access_token + } + if self.access_token is not None: + auth['authentik_device_federation'] = { + 'type': 'bearer', + 'in': 'header', + 'key': 'Authorization', + 'value': 'Bearer ' + self.access_token + } + return auth + + def to_debug_report(self) -> str: + """Gets the essential information for debugging. + + :return: The report for debugging. + """ + return "Python SDK Debug Report:\n"\ + "OS: {env}\n"\ + "Python Version: {pyversion}\n"\ + "Version of the API: 2026.5.7\n"\ + "SDK Package Version: 2026.5.7".\ + format(env=sys.platform, pyversion=sys.version) + + def get_host_settings(self) -> List[HostSetting]: + """Gets an array of host settings + + :return: An array of host settings + """ + return [ + { + 'url': "/api/v3", + 'description': "No description provided", + } + ] + + def get_host_from_settings( + self, + index: Optional[int], + variables: Optional[ServerVariablesT]=None, + servers: Optional[List[HostSetting]]=None, + ) -> str: + """Gets host URL based on the index and variables + :param index: array index of the host settings + :param variables: hash of variable and the corresponding value + :param servers: an array of host settings or None + :return: URL based on host settings + """ + if index is None: + return self._base_path + + variables = {} if variables is None else variables + servers = self.get_host_settings() if servers is None else servers + + try: + server = servers[index] + except IndexError: + raise ValueError( + "Invalid index {0} when selecting the host settings. " + "Must be less than {1}".format(index, len(servers))) + + url = server['url'] + + # go through variables and replace placeholders + for variable_name, variable in server.get('variables', {}).items(): + used_value = variables.get( + variable_name, variable['default_value']) + + if 'enum_values' in variable \ + and variable['enum_values'] \ + and used_value not in variable['enum_values']: + raise ValueError( + "The variable `{0}` in the host URL has invalid value " + "{1}. Must be {2}.".format( + variable_name, variables[variable_name], + variable['enum_values'])) + + url = url.replace("{" + variable_name + "}", used_value) + + return url + + @property + def host(self) -> str: + """Return generated host.""" + return self.get_host_from_settings(self.server_index, variables=self.server_variables) + + @host.setter + def host(self, value: str) -> None: + """Fix base path.""" + self._base_path = value + self.server_index = None diff --git a/authentik_client/exceptions.py b/authentik_client/exceptions.py new file mode 100644 index 000000000..f7c79701c --- /dev/null +++ b/authentik_client/exceptions.py @@ -0,0 +1,219 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from typing import Any, Optional +from typing_extensions import Self + +class OpenApiException(Exception): + """The base exception class for all OpenAPIExceptions""" + + +class ApiTypeError(OpenApiException, TypeError): + def __init__(self, msg, path_to_item=None, valid_classes=None, + key_type=None) -> None: + """ Raises an exception for TypeErrors + + Args: + msg (str): the exception message + + Keyword Args: + path_to_item (list): a list of keys an indices to get to the + current_item + None if unset + valid_classes (tuple): the primitive classes that current item + should be an instance of + None if unset + key_type (bool): False if our value is a value in a dict + True if it is a key in a dict + False if our item is an item in a list + None if unset + """ + self.path_to_item = path_to_item + self.valid_classes = valid_classes + self.key_type = key_type + full_msg = msg + if path_to_item: + full_msg = "{0} at {1}".format(msg, render_path(path_to_item)) + super(ApiTypeError, self).__init__(full_msg) + + +class ApiValueError(OpenApiException, ValueError): + def __init__(self, msg, path_to_item=None) -> None: + """ + Args: + msg (str): the exception message + + Keyword Args: + path_to_item (list) the path to the exception in the + received_data dict. None if unset + """ + + self.path_to_item = path_to_item + full_msg = msg + if path_to_item: + full_msg = "{0} at {1}".format(msg, render_path(path_to_item)) + super(ApiValueError, self).__init__(full_msg) + + +class ApiAttributeError(OpenApiException, AttributeError): + def __init__(self, msg, path_to_item=None) -> None: + """ + Raised when an attribute reference or assignment fails. + + Args: + msg (str): the exception message + + Keyword Args: + path_to_item (None/list) the path to the exception in the + received_data dict + """ + self.path_to_item = path_to_item + full_msg = msg + if path_to_item: + full_msg = "{0} at {1}".format(msg, render_path(path_to_item)) + super(ApiAttributeError, self).__init__(full_msg) + + +class ApiKeyError(OpenApiException, KeyError): + def __init__(self, msg, path_to_item=None) -> None: + """ + Args: + msg (str): the exception message + + Keyword Args: + path_to_item (None/list) the path to the exception in the + received_data dict + """ + self.path_to_item = path_to_item + full_msg = msg + if path_to_item: + full_msg = "{0} at {1}".format(msg, render_path(path_to_item)) + super(ApiKeyError, self).__init__(full_msg) + + +class ApiException(OpenApiException): + + def __init__( + self, + status=None, + reason=None, + http_resp=None, + *, + body: Optional[str] = None, + data: Optional[Any] = None, + ) -> None: + self.status = status + self.reason = reason + self.body = body + self.data = data + self.headers = None + + if http_resp: + if self.status is None: + self.status = http_resp.status + if self.reason is None: + self.reason = http_resp.reason + if self.body is None: + try: + self.body = http_resp.data.decode('utf-8') + except Exception: + pass + self.headers = http_resp.headers + + @classmethod + def from_response( + cls, + *, + http_resp, + body: Optional[str], + data: Optional[Any], + ) -> Self: + if http_resp.status == 400: + raise BadRequestException(http_resp=http_resp, body=body, data=data) + + if http_resp.status == 401: + raise UnauthorizedException(http_resp=http_resp, body=body, data=data) + + if http_resp.status == 403: + raise ForbiddenException(http_resp=http_resp, body=body, data=data) + + if http_resp.status == 404: + raise NotFoundException(http_resp=http_resp, body=body, data=data) + + # Added new conditions for 409 and 422 + if http_resp.status == 409: + raise ConflictException(http_resp=http_resp, body=body, data=data) + + if http_resp.status == 422: + raise UnprocessableEntityException(http_resp=http_resp, body=body, data=data) + + if 500 <= http_resp.status <= 599: + raise ServiceException(http_resp=http_resp, body=body, data=data) + raise ApiException(http_resp=http_resp, body=body, data=data) + + def __str__(self): + """Custom error messages for exception""" + error_message = "({0})\n"\ + "Reason: {1}\n".format(self.status, self.reason) + if self.headers: + error_message += "HTTP response headers: {0}\n".format( + self.headers) + + if self.body: + error_message += "HTTP response body: {0}\n".format(self.body) + + if self.data: + error_message += "HTTP response data: {0}\n".format(self.data) + + return error_message + + +class BadRequestException(ApiException): + pass + + +class NotFoundException(ApiException): + pass + + +class UnauthorizedException(ApiException): + pass + + +class ForbiddenException(ApiException): + pass + + +class ServiceException(ApiException): + pass + + +class ConflictException(ApiException): + """Exception for HTTP 409 Conflict.""" + pass + + +class UnprocessableEntityException(ApiException): + """Exception for HTTP 422 Unprocessable Entity.""" + pass + + +def render_path(path_to_item): + """Returns a string representation of a path""" + result = "" + for pth in path_to_item: + if isinstance(pth, int): + result += "[{0}]".format(pth) + else: + result += "['{0}']".format(pth) + return result diff --git a/authentik_client/models/__init__.py b/authentik_client/models/__init__.py new file mode 100644 index 000000000..250e1435b --- /dev/null +++ b/authentik_client/models/__init__.py @@ -0,0 +1,900 @@ +# coding: utf-8 + +# flake8: noqa +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + +# import models into model package +from authentik_client.models.access_denied_challenge import AccessDeniedChallenge +from authentik_client.models.account_lockdown_stage import AccountLockdownStage +from authentik_client.models.account_lockdown_stage_request import AccountLockdownStageRequest +from authentik_client.models.agent_authentication_response import AgentAuthenticationResponse +from authentik_client.models.agent_config import AgentConfig +from authentik_client.models.agent_connector import AgentConnector +from authentik_client.models.agent_connector_request import AgentConnectorRequest +from authentik_client.models.agent_psso_device_registration_request import AgentPSSODeviceRegistrationRequest +from authentik_client.models.agent_psso_device_registration_response import AgentPSSODeviceRegistrationResponse +from authentik_client.models.agent_psso_user_registration_request import AgentPSSOUserRegistrationRequest +from authentik_client.models.agent_token_response import AgentTokenResponse +from authentik_client.models.alg_enum import AlgEnum +from authentik_client.models.app import App +from authentik_client.models.app_enum import AppEnum +from authentik_client.models.apple_challenge_response_request import AppleChallengeResponseRequest +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave +from authentik_client.models.apple_independent_secure_enclave_request import AppleIndependentSecureEnclaveRequest +from authentik_client.models.apple_login_challenge import AppleLoginChallenge +from authentik_client.models.application import Application +from authentik_client.models.application_entitlement import ApplicationEntitlement +from authentik_client.models.application_entitlement_request import ApplicationEntitlementRequest +from authentik_client.models.application_request import ApplicationRequest +from authentik_client.models.auth_type_enum import AuthTypeEnum +from authentik_client.models.authenticated_session import AuthenticatedSession +from authentik_client.models.authenticated_session_asn import AuthenticatedSessionAsn +from authentik_client.models.authenticated_session_geo_ip import AuthenticatedSessionGeoIp +from authentik_client.models.authenticated_session_user_agent import AuthenticatedSessionUserAgent +from authentik_client.models.authenticated_session_user_agent_device import AuthenticatedSessionUserAgentDevice +from authentik_client.models.authenticated_session_user_agent_os import AuthenticatedSessionUserAgentOs +from authentik_client.models.authenticated_session_user_agent_user_agent import AuthenticatedSessionUserAgentUserAgent +from authentik_client.models.authentication_enum import AuthenticationEnum +from authentik_client.models.authenticator_attachment_enum import AuthenticatorAttachmentEnum +from authentik_client.models.authenticator_duo_challenge import AuthenticatorDuoChallenge +from authentik_client.models.authenticator_duo_challenge_response_request import AuthenticatorDuoChallengeResponseRequest +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage +from authentik_client.models.authenticator_duo_stage_device_import_response import AuthenticatorDuoStageDeviceImportResponse +from authentik_client.models.authenticator_duo_stage_manual_device_import_request import AuthenticatorDuoStageManualDeviceImportRequest +from authentik_client.models.authenticator_duo_stage_request import AuthenticatorDuoStageRequest +from authentik_client.models.authenticator_email_challenge import AuthenticatorEmailChallenge +from authentik_client.models.authenticator_email_challenge_response_request import AuthenticatorEmailChallengeResponseRequest +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage +from authentik_client.models.authenticator_email_stage_request import AuthenticatorEmailStageRequest +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage +from authentik_client.models.authenticator_endpoint_gdtc_stage_request import AuthenticatorEndpointGDTCStageRequest +from authentik_client.models.authenticator_sms_challenge import AuthenticatorSMSChallenge +from authentik_client.models.authenticator_sms_challenge_response_request import AuthenticatorSMSChallengeResponseRequest +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage +from authentik_client.models.authenticator_sms_stage_request import AuthenticatorSMSStageRequest +from authentik_client.models.authenticator_static_challenge import AuthenticatorStaticChallenge +from authentik_client.models.authenticator_static_challenge_response_request import AuthenticatorStaticChallengeResponseRequest +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage +from authentik_client.models.authenticator_static_stage_request import AuthenticatorStaticStageRequest +from authentik_client.models.authenticator_totp_challenge import AuthenticatorTOTPChallenge +from authentik_client.models.authenticator_totp_challenge_response_request import AuthenticatorTOTPChallengeResponseRequest +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage +from authentik_client.models.authenticator_totp_stage_request import AuthenticatorTOTPStageRequest +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage +from authentik_client.models.authenticator_validate_stage_request import AuthenticatorValidateStageRequest +from authentik_client.models.authenticator_validation_challenge import AuthenticatorValidationChallenge +from authentik_client.models.authenticator_validation_challenge_response_request import AuthenticatorValidationChallengeResponseRequest +from authentik_client.models.authenticator_web_authn_challenge import AuthenticatorWebAuthnChallenge +from authentik_client.models.authenticator_web_authn_challenge_response_request import AuthenticatorWebAuthnChallengeResponseRequest +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage +from authentik_client.models.authenticator_web_authn_stage_request import AuthenticatorWebAuthnStageRequest +from authentik_client.models.authorization_code_auth_method_enum import AuthorizationCodeAuthMethodEnum +from authentik_client.models.auto_submit_challenge_response_request import AutoSubmitChallengeResponseRequest +from authentik_client.models.autosubmit_challenge import AutosubmitChallenge +from authentik_client.models.backends_enum import BackendsEnum +from authentik_client.models.binding_type_enum import BindingTypeEnum +from authentik_client.models.blueprint_file import BlueprintFile +from authentik_client.models.blueprint_import_result import BlueprintImportResult +from authentik_client.models.blueprint_instance import BlueprintInstance +from authentik_client.models.blueprint_instance_request import BlueprintInstanceRequest +from authentik_client.models.blueprint_instance_status_enum import BlueprintInstanceStatusEnum +from authentik_client.models.brand import Brand +from authentik_client.models.brand_request import BrandRequest +from authentik_client.models.bulk_delete_session_response import BulkDeleteSessionResponse +from authentik_client.models.cache import Cache +from authentik_client.models.capabilities_enum import CapabilitiesEnum +from authentik_client.models.captcha_challenge import CaptchaChallenge +from authentik_client.models.captcha_challenge_response_request import CaptchaChallengeResponseRequest +from authentik_client.models.captcha_stage import CaptchaStage +from authentik_client.models.captcha_stage_request import CaptchaStageRequest +from authentik_client.models.cert_attribute_enum import CertAttributeEnum +from authentik_client.models.certificate_data import CertificateData +from authentik_client.models.certificate_generation_request import CertificateGenerationRequest +from authentik_client.models.certificate_key_pair import CertificateKeyPair +from authentik_client.models.certificate_key_pair_key_type_enum import CertificateKeyPairKeyTypeEnum +from authentik_client.models.certificate_key_pair_request import CertificateKeyPairRequest +from authentik_client.models.challenge_types import ChallengeTypes +from authentik_client.models.client_type_enum import ClientTypeEnum +from authentik_client.models.compatibility_mode_enum import CompatibilityModeEnum +from authentik_client.models.config import Config +from authentik_client.models.connection_token import ConnectionToken +from authentik_client.models.connection_token_request import ConnectionTokenRequest +from authentik_client.models.connector import Connector +from authentik_client.models.consent_challenge import ConsentChallenge +from authentik_client.models.consent_challenge_response_request import ConsentChallengeResponseRequest +from authentik_client.models.consent_mode_enum import ConsentModeEnum +from authentik_client.models.consent_permission import ConsentPermission +from authentik_client.models.consent_stage import ConsentStage +from authentik_client.models.consent_stage_request import ConsentStageRequest +from authentik_client.models.content_type import ContentType +from authentik_client.models.content_type_enum import ContentTypeEnum +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.contextual_flow_info_layout_enum import ContextualFlowInfoLayoutEnum +from authentik_client.models.country_code_enum import CountryCodeEnum +from authentik_client.models.current_brand import CurrentBrand +from authentik_client.models.current_brand_flags import CurrentBrandFlags +from authentik_client.models.data_export import DataExport +from authentik_client.models.delivery_method_enum import DeliveryMethodEnum +from authentik_client.models.denied_action_enum import DeniedActionEnum +from authentik_client.models.deny_stage import DenyStage +from authentik_client.models.deny_stage_request import DenyStageRequest +from authentik_client.models.detailed_country import DetailedCountry +from authentik_client.models.device import Device +from authentik_client.models.device_access_group import DeviceAccessGroup +from authentik_client.models.device_access_group_request import DeviceAccessGroupRequest +from authentik_client.models.device_challenge import DeviceChallenge +from authentik_client.models.device_challenge_request import DeviceChallengeRequest +from authentik_client.models.device_classes_enum import DeviceClassesEnum +from authentik_client.models.device_connection import DeviceConnection +from authentik_client.models.device_fact_snapshot import DeviceFactSnapshot +from authentik_client.models.device_facts import DeviceFacts +from authentik_client.models.device_facts_os_family import DeviceFactsOSFamily +from authentik_client.models.device_facts_request import DeviceFactsRequest +from authentik_client.models.device_group import DeviceGroup +from authentik_client.models.device_group_request import DeviceGroupRequest +from authentik_client.models.device_summary import DeviceSummary +from authentik_client.models.device_user import DeviceUser +from authentik_client.models.device_user_binding import DeviceUserBinding +from authentik_client.models.device_user_binding_request import DeviceUserBindingRequest +from authentik_client.models.device_user_request import DeviceUserRequest +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.digits_enum import DigitsEnum +from authentik_client.models.disk import Disk +from authentik_client.models.disk_request import DiskRequest +from authentik_client.models.docker_service_connection import DockerServiceConnection +from authentik_client.models.docker_service_connection_request import DockerServiceConnectionRequest +from authentik_client.models.domain import Domain +from authentik_client.models.domain_request import DomainRequest +from authentik_client.models.dummy_challenge import DummyChallenge +from authentik_client.models.dummy_challenge_response_request import DummyChallengeResponseRequest +from authentik_client.models.dummy_policy import DummyPolicy +from authentik_client.models.dummy_policy_request import DummyPolicyRequest +from authentik_client.models.dummy_stage import DummyStage +from authentik_client.models.dummy_stage_request import DummyStageRequest +from authentik_client.models.duo_device import DuoDevice +from authentik_client.models.duo_device_enrollment_status import DuoDeviceEnrollmentStatus +from authentik_client.models.duo_device_request import DuoDeviceRequest +from authentik_client.models.duo_response_enum import DuoResponseEnum +from authentik_client.models.email_challenge import EmailChallenge +from authentik_client.models.email_challenge_response_request import EmailChallengeResponseRequest +from authentik_client.models.email_device import EmailDevice +from authentik_client.models.email_device_request import EmailDeviceRequest +from authentik_client.models.email_stage import EmailStage +from authentik_client.models.email_stage_request import EmailStageRequest +from authentik_client.models.endpoint import Endpoint +from authentik_client.models.endpoint_agent_challenge import EndpointAgentChallenge +from authentik_client.models.endpoint_agent_challenge_response_request import EndpointAgentChallengeResponseRequest +from authentik_client.models.endpoint_auth_mode_enum import EndpointAuthModeEnum +from authentik_client.models.endpoint_device import EndpointDevice +from authentik_client.models.endpoint_device_details import EndpointDeviceDetails +from authentik_client.models.endpoint_device_request import EndpointDeviceRequest +from authentik_client.models.endpoint_request import EndpointRequest +from authentik_client.models.endpoint_stage import EndpointStage +from authentik_client.models.endpoint_stage_request import EndpointStageRequest +from authentik_client.models.enroll_request import EnrollRequest +from authentik_client.models.enrollment_token import EnrollmentToken +from authentik_client.models.enrollment_token_request import EnrollmentTokenRequest +from authentik_client.models.error_detail import ErrorDetail +from authentik_client.models.error_reporting_config import ErrorReportingConfig +from authentik_client.models.event import Event +from authentik_client.models.event_actions import EventActions +from authentik_client.models.event_matcher_policy import EventMatcherPolicy +from authentik_client.models.event_matcher_policy_request import EventMatcherPolicyRequest +from authentik_client.models.event_request import EventRequest +from authentik_client.models.event_stats import EventStats +from authentik_client.models.event_top_per_user import EventTopPerUser +from authentik_client.models.event_volume import EventVolume +from authentik_client.models.events_requested_enum import EventsRequestedEnum +from authentik_client.models.expiring_base_grant_model import ExpiringBaseGrantModel +from authentik_client.models.expression_policy import ExpressionPolicy +from authentik_client.models.expression_policy_request import ExpressionPolicyRequest +from authentik_client.models.extra_role_object_permission import ExtraRoleObjectPermission +from authentik_client.models.file_list import FileList +from authentik_client.models.fleet_connector import FleetConnector +from authentik_client.models.fleet_connector_request import FleetConnectorRequest +from authentik_client.models.flow import Flow +from authentik_client.models.flow_challenge_response_request import FlowChallengeResponseRequest +from authentik_client.models.flow_designation_enum import FlowDesignationEnum +from authentik_client.models.flow_diagram import FlowDiagram +from authentik_client.models.flow_error_challenge import FlowErrorChallenge +from authentik_client.models.flow_inspection import FlowInspection +from authentik_client.models.flow_inspector_plan import FlowInspectorPlan +from authentik_client.models.flow_layout_enum import FlowLayoutEnum +from authentik_client.models.flow_request import FlowRequest +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.flow_stage_binding import FlowStageBinding +from authentik_client.models.flow_stage_binding_request import FlowStageBindingRequest +from authentik_client.models.footer_link import FooterLink +from authentik_client.models.force_binding_enum import ForceBindingEnum +from authentik_client.models.format_enum import FormatEnum +from authentik_client.models.frame_challenge import FrameChallenge +from authentik_client.models.frame_challenge_response_request import FrameChallengeResponseRequest +from authentik_client.models.generic_error import GenericError +from authentik_client.models.geo_ip_policy import GeoIPPolicy +from authentik_client.models.geo_ip_policy_countries_obj_inner import GeoIPPolicyCountriesObjInner +from authentik_client.models.geo_ip_policy_request import GeoIPPolicyRequest +from authentik_client.models.geoip_binding_enum import GeoipBindingEnum +from authentik_client.models.global_task_status import GlobalTaskStatus +from authentik_client.models.google_chrome_connector import GoogleChromeConnector +from authentik_client.models.google_chrome_connector_request import GoogleChromeConnectorRequest +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice +from authentik_client.models.google_endpoint_device_request import GoogleEndpointDeviceRequest +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider +from authentik_client.models.google_workspace_provider_group import GoogleWorkspaceProviderGroup +from authentik_client.models.google_workspace_provider_group_request import GoogleWorkspaceProviderGroupRequest +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping +from authentik_client.models.google_workspace_provider_mapping_request import GoogleWorkspaceProviderMappingRequest +from authentik_client.models.google_workspace_provider_request import GoogleWorkspaceProviderRequest +from authentik_client.models.google_workspace_provider_user import GoogleWorkspaceProviderUser +from authentik_client.models.google_workspace_provider_user_request import GoogleWorkspaceProviderUserRequest +from authentik_client.models.grant_types_enum import GrantTypesEnum +from authentik_client.models.group import Group +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection +from authentik_client.models.group_kerberos_source_connection_request import GroupKerberosSourceConnectionRequest +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection +from authentik_client.models.group_ldap_source_connection_request import GroupLDAPSourceConnectionRequest +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection +from authentik_client.models.group_o_auth_source_connection_request import GroupOAuthSourceConnectionRequest +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection +from authentik_client.models.group_plex_source_connection_request import GroupPlexSourceConnectionRequest +from authentik_client.models.group_request import GroupRequest +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection +from authentik_client.models.group_saml_source_connection_request import GroupSAMLSourceConnectionRequest +from authentik_client.models.group_source_connection import GroupSourceConnection +from authentik_client.models.group_source_connection_request import GroupSourceConnectionRequest +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection +from authentik_client.models.group_telegram_source_connection_request import GroupTelegramSourceConnectionRequest +from authentik_client.models.hardware import Hardware +from authentik_client.models.hardware_request import HardwareRequest +from authentik_client.models.identification_challenge import IdentificationChallenge +from authentik_client.models.identification_challenge_response_request import IdentificationChallengeResponseRequest +from authentik_client.models.identification_stage import IdentificationStage +from authentik_client.models.identification_stage_request import IdentificationStageRequest +from authentik_client.models.iframe_logout_challenge import IframeLogoutChallenge +from authentik_client.models.iframe_logout_challenge_response_request import IframeLogoutChallengeResponseRequest +from authentik_client.models.impersonation_request import ImpersonationRequest +from authentik_client.models.initial_permissions import InitialPermissions +from authentik_client.models.initial_permissions_request import InitialPermissionsRequest +from authentik_client.models.install_id import InstallID +from authentik_client.models.intent_enum import IntentEnum +from authentik_client.models.invalid_response_action_enum import InvalidResponseActionEnum +from authentik_client.models.invitation import Invitation +from authentik_client.models.invitation_request import InvitationRequest +from authentik_client.models.invitation_send_email_request import InvitationSendEmailRequest +from authentik_client.models.invitation_stage import InvitationStage +from authentik_client.models.invitation_stage_request import InvitationStageRequest +from authentik_client.models.issuer_mode_enum import IssuerModeEnum +from authentik_client.models.kadmin_type_enum import KadminTypeEnum +from authentik_client.models.kerberos_source import KerberosSource +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping +from authentik_client.models.kerberos_source_property_mapping_request import KerberosSourcePropertyMappingRequest +from authentik_client.models.kerberos_source_request import KerberosSourceRequest +from authentik_client.models.key_type_enum import KeyTypeEnum +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection +from authentik_client.models.kubernetes_service_connection_request import KubernetesServiceConnectionRequest +from authentik_client.models.ldapapi_access_mode import LDAPAPIAccessMode +from authentik_client.models.ldap_check_access import LDAPCheckAccess +from authentik_client.models.ldap_debug import LDAPDebug +from authentik_client.models.ldap_outpost_config import LDAPOutpostConfig +from authentik_client.models.ldap_provider import LDAPProvider +from authentik_client.models.ldap_provider_request import LDAPProviderRequest +from authentik_client.models.ldap_source import LDAPSource +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping +from authentik_client.models.ldap_source_property_mapping_request import LDAPSourcePropertyMappingRequest +from authentik_client.models.ldap_source_request import LDAPSourceRequest +from authentik_client.models.lang_enum import LangEnum +from authentik_client.models.last_task_status_enum import LastTaskStatusEnum +from authentik_client.models.license import License +from authentik_client.models.license_flags_enum import LicenseFlagsEnum +from authentik_client.models.license_forecast import LicenseForecast +from authentik_client.models.license_request import LicenseRequest +from authentik_client.models.license_status_enum import LicenseStatusEnum +from authentik_client.models.license_summary import LicenseSummary +from authentik_client.models.license_summary_status_enum import LicenseSummaryStatusEnum +from authentik_client.models.lifecycle_iteration import LifecycleIteration +from authentik_client.models.lifecycle_iteration_request import LifecycleIterationRequest +from authentik_client.models.lifecycle_iteration_state_enum import LifecycleIterationStateEnum +from authentik_client.models.lifecycle_rule import LifecycleRule +from authentik_client.models.lifecycle_rule_request import LifecycleRuleRequest +from authentik_client.models.link import Link +from authentik_client.models.log_event import LogEvent +from authentik_client.models.log_level_enum import LogLevelEnum +from authentik_client.models.login_challenge_types import LoginChallengeTypes +from authentik_client.models.login_source import LoginSource +from authentik_client.models.logout_url import LogoutURL +from authentik_client.models.mdm_config_request import MDMConfigRequest +from authentik_client.models.mdm_config_response import MDMConfigResponse +from authentik_client.models.matching_mode_enum import MatchingModeEnum +from authentik_client.models.metadata import Metadata +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider +from authentik_client.models.microsoft_entra_provider_group import MicrosoftEntraProviderGroup +from authentik_client.models.microsoft_entra_provider_group_request import MicrosoftEntraProviderGroupRequest +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping +from authentik_client.models.microsoft_entra_provider_mapping_request import MicrosoftEntraProviderMappingRequest +from authentik_client.models.microsoft_entra_provider_request import MicrosoftEntraProviderRequest +from authentik_client.models.microsoft_entra_provider_user import MicrosoftEntraProviderUser +from authentik_client.models.microsoft_entra_provider_user_request import MicrosoftEntraProviderUserRequest +from authentik_client.models.model_enum import ModelEnum +from authentik_client.models.model_request import ModelRequest +from authentik_client.models.mutual_tls_stage import MutualTLSStage +from authentik_client.models.mutual_tls_stage_request import MutualTLSStageRequest +from authentik_client.models.native_logout_challenge import NativeLogoutChallenge +from authentik_client.models.native_logout_challenge_response_request import NativeLogoutChallengeResponseRequest +from authentik_client.models.network import Network +from authentik_client.models.network_binding_enum import NetworkBindingEnum +from authentik_client.models.network_interface import NetworkInterface +from authentik_client.models.network_interface_request import NetworkInterfaceRequest +from authentik_client.models.network_request import NetworkRequest +from authentik_client.models.not_configured_action_enum import NotConfiguredActionEnum +from authentik_client.models.notification import Notification +from authentik_client.models.notification_request import NotificationRequest +from authentik_client.models.notification_rule import NotificationRule +from authentik_client.models.notification_rule_request import NotificationRuleRequest +from authentik_client.models.notification_transport import NotificationTransport +from authentik_client.models.notification_transport_request import NotificationTransportRequest +from authentik_client.models.notification_transport_test import NotificationTransportTest +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping +from authentik_client.models.notification_webhook_mapping_request import NotificationWebhookMappingRequest +from authentik_client.models.o_auth2_provider import OAuth2Provider +from authentik_client.models.o_auth2_provider_logout_method_enum import OAuth2ProviderLogoutMethodEnum +from authentik_client.models.o_auth2_provider_request import OAuth2ProviderRequest +from authentik_client.models.o_auth2_provider_setup_urls import OAuth2ProviderSetupURLs +from authentik_client.models.o_auth_device_code_challenge import OAuthDeviceCodeChallenge +from authentik_client.models.o_auth_device_code_challenge_response_request import OAuthDeviceCodeChallengeResponseRequest +from authentik_client.models.o_auth_device_code_finish_challenge import OAuthDeviceCodeFinishChallenge +from authentik_client.models.o_auth_device_code_finish_challenge_response_request import OAuthDeviceCodeFinishChallengeResponseRequest +from authentik_client.models.o_auth_source import OAuthSource +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping +from authentik_client.models.o_auth_source_property_mapping_request import OAuthSourcePropertyMappingRequest +from authentik_client.models.o_auth_source_request import OAuthSourceRequest +from authentik_client.models.open_id_connect_configuration import OpenIDConnectConfiguration +from authentik_client.models.operating_system import OperatingSystem +from authentik_client.models.operating_system_request import OperatingSystemRequest +from authentik_client.models.outgoing_sync_delete_action import OutgoingSyncDeleteAction +from authentik_client.models.outpost import Outpost +from authentik_client.models.outpost_default_config import OutpostDefaultConfig +from authentik_client.models.outpost_health import OutpostHealth +from authentik_client.models.outpost_request import OutpostRequest +from authentik_client.models.outpost_type_enum import OutpostTypeEnum +from authentik_client.models.pkce_method_enum import PKCEMethodEnum +from authentik_client.models.paginated_account_lockdown_stage_list import PaginatedAccountLockdownStageList +from authentik_client.models.paginated_agent_connector_list import PaginatedAgentConnectorList +from authentik_client.models.paginated_apple_independent_secure_enclave_list import PaginatedAppleIndependentSecureEnclaveList +from authentik_client.models.paginated_application_entitlement_list import PaginatedApplicationEntitlementList +from authentik_client.models.paginated_application_list import PaginatedApplicationList +from authentik_client.models.paginated_authenticated_session_list import PaginatedAuthenticatedSessionList +from authentik_client.models.paginated_authenticator_duo_stage_list import PaginatedAuthenticatorDuoStageList +from authentik_client.models.paginated_authenticator_email_stage_list import PaginatedAuthenticatorEmailStageList +from authentik_client.models.paginated_authenticator_endpoint_gdtc_stage_list import PaginatedAuthenticatorEndpointGDTCStageList +from authentik_client.models.paginated_authenticator_sms_stage_list import PaginatedAuthenticatorSMSStageList +from authentik_client.models.paginated_authenticator_static_stage_list import PaginatedAuthenticatorStaticStageList +from authentik_client.models.paginated_authenticator_totp_stage_list import PaginatedAuthenticatorTOTPStageList +from authentik_client.models.paginated_authenticator_validate_stage_list import PaginatedAuthenticatorValidateStageList +from authentik_client.models.paginated_authenticator_web_authn_stage_list import PaginatedAuthenticatorWebAuthnStageList +from authentik_client.models.paginated_blueprint_instance_list import PaginatedBlueprintInstanceList +from authentik_client.models.paginated_brand_list import PaginatedBrandList +from authentik_client.models.paginated_captcha_stage_list import PaginatedCaptchaStageList +from authentik_client.models.paginated_certificate_key_pair_list import PaginatedCertificateKeyPairList +from authentik_client.models.paginated_connection_token_list import PaginatedConnectionTokenList +from authentik_client.models.paginated_connector_list import PaginatedConnectorList +from authentik_client.models.paginated_consent_stage_list import PaginatedConsentStageList +from authentik_client.models.paginated_data_export_list import PaginatedDataExportList +from authentik_client.models.paginated_deny_stage_list import PaginatedDenyStageList +from authentik_client.models.paginated_device_access_group_list import PaginatedDeviceAccessGroupList +from authentik_client.models.paginated_device_user_binding_list import PaginatedDeviceUserBindingList +from authentik_client.models.paginated_docker_service_connection_list import PaginatedDockerServiceConnectionList +from authentik_client.models.paginated_domain_list import PaginatedDomainList +from authentik_client.models.paginated_dummy_policy_list import PaginatedDummyPolicyList +from authentik_client.models.paginated_dummy_stage_list import PaginatedDummyStageList +from authentik_client.models.paginated_duo_device_list import PaginatedDuoDeviceList +from authentik_client.models.paginated_email_device_list import PaginatedEmailDeviceList +from authentik_client.models.paginated_email_stage_list import PaginatedEmailStageList +from authentik_client.models.paginated_endpoint_device_list import PaginatedEndpointDeviceList +from authentik_client.models.paginated_endpoint_list import PaginatedEndpointList +from authentik_client.models.paginated_endpoint_stage_list import PaginatedEndpointStageList +from authentik_client.models.paginated_enrollment_token_list import PaginatedEnrollmentTokenList +from authentik_client.models.paginated_event_list import PaginatedEventList +from authentik_client.models.paginated_event_matcher_policy_list import PaginatedEventMatcherPolicyList +from authentik_client.models.paginated_expiring_base_grant_model_list import PaginatedExpiringBaseGrantModelList +from authentik_client.models.paginated_expression_policy_list import PaginatedExpressionPolicyList +from authentik_client.models.paginated_extra_role_object_permission_list import PaginatedExtraRoleObjectPermissionList +from authentik_client.models.paginated_fleet_connector_list import PaginatedFleetConnectorList +from authentik_client.models.paginated_flow_list import PaginatedFlowList +from authentik_client.models.paginated_flow_stage_binding_list import PaginatedFlowStageBindingList +from authentik_client.models.paginated_geo_ip_policy_list import PaginatedGeoIPPolicyList +from authentik_client.models.paginated_google_chrome_connector_list import PaginatedGoogleChromeConnectorList +from authentik_client.models.paginated_google_endpoint_device_list import PaginatedGoogleEndpointDeviceList +from authentik_client.models.paginated_google_workspace_provider_group_list import PaginatedGoogleWorkspaceProviderGroupList +from authentik_client.models.paginated_google_workspace_provider_list import PaginatedGoogleWorkspaceProviderList +from authentik_client.models.paginated_google_workspace_provider_mapping_list import PaginatedGoogleWorkspaceProviderMappingList +from authentik_client.models.paginated_google_workspace_provider_user_list import PaginatedGoogleWorkspaceProviderUserList +from authentik_client.models.paginated_group_kerberos_source_connection_list import PaginatedGroupKerberosSourceConnectionList +from authentik_client.models.paginated_group_ldap_source_connection_list import PaginatedGroupLDAPSourceConnectionList +from authentik_client.models.paginated_group_list import PaginatedGroupList +from authentik_client.models.paginated_group_o_auth_source_connection_list import PaginatedGroupOAuthSourceConnectionList +from authentik_client.models.paginated_group_plex_source_connection_list import PaginatedGroupPlexSourceConnectionList +from authentik_client.models.paginated_group_saml_source_connection_list import PaginatedGroupSAMLSourceConnectionList +from authentik_client.models.paginated_group_source_connection_list import PaginatedGroupSourceConnectionList +from authentik_client.models.paginated_group_telegram_source_connection_list import PaginatedGroupTelegramSourceConnectionList +from authentik_client.models.paginated_identification_stage_list import PaginatedIdentificationStageList +from authentik_client.models.paginated_initial_permissions_list import PaginatedInitialPermissionsList +from authentik_client.models.paginated_invitation_list import PaginatedInvitationList +from authentik_client.models.paginated_invitation_stage_list import PaginatedInvitationStageList +from authentik_client.models.paginated_kerberos_source_list import PaginatedKerberosSourceList +from authentik_client.models.paginated_kerberos_source_property_mapping_list import PaginatedKerberosSourcePropertyMappingList +from authentik_client.models.paginated_kubernetes_service_connection_list import PaginatedKubernetesServiceConnectionList +from authentik_client.models.paginated_ldap_outpost_config_list import PaginatedLDAPOutpostConfigList +from authentik_client.models.paginated_ldap_provider_list import PaginatedLDAPProviderList +from authentik_client.models.paginated_ldap_source_list import PaginatedLDAPSourceList +from authentik_client.models.paginated_ldap_source_property_mapping_list import PaginatedLDAPSourcePropertyMappingList +from authentik_client.models.paginated_license_list import PaginatedLicenseList +from authentik_client.models.paginated_lifecycle_iteration_list import PaginatedLifecycleIterationList +from authentik_client.models.paginated_lifecycle_rule_list import PaginatedLifecycleRuleList +from authentik_client.models.paginated_microsoft_entra_provider_group_list import PaginatedMicrosoftEntraProviderGroupList +from authentik_client.models.paginated_microsoft_entra_provider_list import PaginatedMicrosoftEntraProviderList +from authentik_client.models.paginated_microsoft_entra_provider_mapping_list import PaginatedMicrosoftEntraProviderMappingList +from authentik_client.models.paginated_microsoft_entra_provider_user_list import PaginatedMicrosoftEntraProviderUserList +from authentik_client.models.paginated_mutual_tls_stage_list import PaginatedMutualTLSStageList +from authentik_client.models.paginated_notification_list import PaginatedNotificationList +from authentik_client.models.paginated_notification_rule_list import PaginatedNotificationRuleList +from authentik_client.models.paginated_notification_transport_list import PaginatedNotificationTransportList +from authentik_client.models.paginated_notification_webhook_mapping_list import PaginatedNotificationWebhookMappingList +from authentik_client.models.paginated_o_auth2_provider_list import PaginatedOAuth2ProviderList +from authentik_client.models.paginated_o_auth_source_list import PaginatedOAuthSourceList +from authentik_client.models.paginated_o_auth_source_property_mapping_list import PaginatedOAuthSourcePropertyMappingList +from authentik_client.models.paginated_outpost_list import PaginatedOutpostList +from authentik_client.models.paginated_password_expiry_policy_list import PaginatedPasswordExpiryPolicyList +from authentik_client.models.paginated_password_policy_list import PaginatedPasswordPolicyList +from authentik_client.models.paginated_password_stage_list import PaginatedPasswordStageList +from authentik_client.models.paginated_permission_list import PaginatedPermissionList +from authentik_client.models.paginated_plex_source_list import PaginatedPlexSourceList +from authentik_client.models.paginated_plex_source_property_mapping_list import PaginatedPlexSourcePropertyMappingList +from authentik_client.models.paginated_policy_binding_list import PaginatedPolicyBindingList +from authentik_client.models.paginated_policy_list import PaginatedPolicyList +from authentik_client.models.paginated_prompt_list import PaginatedPromptList +from authentik_client.models.paginated_prompt_stage_list import PaginatedPromptStageList +from authentik_client.models.paginated_property_mapping_list import PaginatedPropertyMappingList +from authentik_client.models.paginated_provider_list import PaginatedProviderList +from authentik_client.models.paginated_proxy_outpost_config_list import PaginatedProxyOutpostConfigList +from authentik_client.models.paginated_proxy_provider_list import PaginatedProxyProviderList +from authentik_client.models.paginated_rac_property_mapping_list import PaginatedRACPropertyMappingList +from authentik_client.models.paginated_rac_provider_list import PaginatedRACProviderList +from authentik_client.models.paginated_radius_outpost_config_list import PaginatedRadiusOutpostConfigList +from authentik_client.models.paginated_radius_provider_list import PaginatedRadiusProviderList +from authentik_client.models.paginated_radius_provider_property_mapping_list import PaginatedRadiusProviderPropertyMappingList +from authentik_client.models.paginated_redirect_stage_list import PaginatedRedirectStageList +from authentik_client.models.paginated_reputation_list import PaginatedReputationList +from authentik_client.models.paginated_reputation_policy_list import PaginatedReputationPolicyList +from authentik_client.models.paginated_role_assigned_object_permission_list import PaginatedRoleAssignedObjectPermissionList +from authentik_client.models.paginated_role_list import PaginatedRoleList +from authentik_client.models.paginated_saml_property_mapping_list import PaginatedSAMLPropertyMappingList +from authentik_client.models.paginated_saml_provider_list import PaginatedSAMLProviderList +from authentik_client.models.paginated_saml_source_list import PaginatedSAMLSourceList +from authentik_client.models.paginated_saml_source_property_mapping_list import PaginatedSAMLSourcePropertyMappingList +from authentik_client.models.paginated_scim_mapping_list import PaginatedSCIMMappingList +from authentik_client.models.paginated_scim_provider_group_list import PaginatedSCIMProviderGroupList +from authentik_client.models.paginated_scim_provider_list import PaginatedSCIMProviderList +from authentik_client.models.paginated_scim_provider_user_list import PaginatedSCIMProviderUserList +from authentik_client.models.paginated_scim_source_group_list import PaginatedSCIMSourceGroupList +from authentik_client.models.paginated_scim_source_list import PaginatedSCIMSourceList +from authentik_client.models.paginated_scim_source_property_mapping_list import PaginatedSCIMSourcePropertyMappingList +from authentik_client.models.paginated_scim_source_user_list import PaginatedSCIMSourceUserList +from authentik_client.models.paginated_sms_device_list import PaginatedSMSDeviceList +from authentik_client.models.paginated_ssf_provider_list import PaginatedSSFProviderList +from authentik_client.models.paginated_ssf_stream_list import PaginatedSSFStreamList +from authentik_client.models.paginated_schedule_list import PaginatedScheduleList +from authentik_client.models.paginated_scope_mapping_list import PaginatedScopeMappingList +from authentik_client.models.paginated_service_connection_list import PaginatedServiceConnectionList +from authentik_client.models.paginated_source_list import PaginatedSourceList +from authentik_client.models.paginated_source_stage_list import PaginatedSourceStageList +from authentik_client.models.paginated_stage_list import PaginatedStageList +from authentik_client.models.paginated_static_device_list import PaginatedStaticDeviceList +from authentik_client.models.paginated_totp_device_list import PaginatedTOTPDeviceList +from authentik_client.models.paginated_task_list import PaginatedTaskList +from authentik_client.models.paginated_telegram_source_list import PaginatedTelegramSourceList +from authentik_client.models.paginated_telegram_source_property_mapping_list import PaginatedTelegramSourcePropertyMappingList +from authentik_client.models.paginated_tenant_list import PaginatedTenantList +from authentik_client.models.paginated_token_list import PaginatedTokenList +from authentik_client.models.paginated_token_model_list import PaginatedTokenModelList +from authentik_client.models.paginated_unique_password_policy_list import PaginatedUniquePasswordPolicyList +from authentik_client.models.paginated_user_consent_list import PaginatedUserConsentList +from authentik_client.models.paginated_user_delete_stage_list import PaginatedUserDeleteStageList +from authentik_client.models.paginated_user_kerberos_source_connection_list import PaginatedUserKerberosSourceConnectionList +from authentik_client.models.paginated_user_ldap_source_connection_list import PaginatedUserLDAPSourceConnectionList +from authentik_client.models.paginated_user_list import PaginatedUserList +from authentik_client.models.paginated_user_login_stage_list import PaginatedUserLoginStageList +from authentik_client.models.paginated_user_logout_stage_list import PaginatedUserLogoutStageList +from authentik_client.models.paginated_user_o_auth_source_connection_list import PaginatedUserOAuthSourceConnectionList +from authentik_client.models.paginated_user_plex_source_connection_list import PaginatedUserPlexSourceConnectionList +from authentik_client.models.paginated_user_saml_source_connection_list import PaginatedUserSAMLSourceConnectionList +from authentik_client.models.paginated_user_source_connection_list import PaginatedUserSourceConnectionList +from authentik_client.models.paginated_user_telegram_source_connection_list import PaginatedUserTelegramSourceConnectionList +from authentik_client.models.paginated_user_write_stage_list import PaginatedUserWriteStageList +from authentik_client.models.paginated_ws_federation_provider_list import PaginatedWSFederationProviderList +from authentik_client.models.paginated_web_authn_device_list import PaginatedWebAuthnDeviceList +from authentik_client.models.paginated_web_authn_device_type_list import PaginatedWebAuthnDeviceTypeList +from authentik_client.models.pagination import Pagination +from authentik_client.models.partial_group import PartialGroup +from authentik_client.models.partial_user import PartialUser +from authentik_client.models.password_challenge import PasswordChallenge +from authentik_client.models.password_challenge_response_request import PasswordChallengeResponseRequest +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy +from authentik_client.models.password_expiry_policy_request import PasswordExpiryPolicyRequest +from authentik_client.models.password_policy import PasswordPolicy +from authentik_client.models.password_policy_request import PasswordPolicyRequest +from authentik_client.models.password_stage import PasswordStage +from authentik_client.models.password_stage_request import PasswordStageRequest +from authentik_client.models.patched_account_lockdown_stage_request import PatchedAccountLockdownStageRequest +from authentik_client.models.patched_agent_connector_request import PatchedAgentConnectorRequest +from authentik_client.models.patched_apple_independent_secure_enclave_request import PatchedAppleIndependentSecureEnclaveRequest +from authentik_client.models.patched_application_entitlement_request import PatchedApplicationEntitlementRequest +from authentik_client.models.patched_application_request import PatchedApplicationRequest +from authentik_client.models.patched_authenticator_duo_stage_request import PatchedAuthenticatorDuoStageRequest +from authentik_client.models.patched_authenticator_email_stage_request import PatchedAuthenticatorEmailStageRequest +from authentik_client.models.patched_authenticator_endpoint_gdtc_stage_request import PatchedAuthenticatorEndpointGDTCStageRequest +from authentik_client.models.patched_authenticator_sms_stage_request import PatchedAuthenticatorSMSStageRequest +from authentik_client.models.patched_authenticator_static_stage_request import PatchedAuthenticatorStaticStageRequest +from authentik_client.models.patched_authenticator_totp_stage_request import PatchedAuthenticatorTOTPStageRequest +from authentik_client.models.patched_authenticator_validate_stage_request import PatchedAuthenticatorValidateStageRequest +from authentik_client.models.patched_authenticator_web_authn_stage_request import PatchedAuthenticatorWebAuthnStageRequest +from authentik_client.models.patched_blueprint_instance_request import PatchedBlueprintInstanceRequest +from authentik_client.models.patched_brand_request import PatchedBrandRequest +from authentik_client.models.patched_captcha_stage_request import PatchedCaptchaStageRequest +from authentik_client.models.patched_certificate_key_pair_request import PatchedCertificateKeyPairRequest +from authentik_client.models.patched_connection_token_request import PatchedConnectionTokenRequest +from authentik_client.models.patched_consent_stage_request import PatchedConsentStageRequest +from authentik_client.models.patched_deny_stage_request import PatchedDenyStageRequest +from authentik_client.models.patched_device_access_group_request import PatchedDeviceAccessGroupRequest +from authentik_client.models.patched_device_user_binding_request import PatchedDeviceUserBindingRequest +from authentik_client.models.patched_docker_service_connection_request import PatchedDockerServiceConnectionRequest +from authentik_client.models.patched_domain_request import PatchedDomainRequest +from authentik_client.models.patched_dummy_policy_request import PatchedDummyPolicyRequest +from authentik_client.models.patched_dummy_stage_request import PatchedDummyStageRequest +from authentik_client.models.patched_duo_device_request import PatchedDuoDeviceRequest +from authentik_client.models.patched_email_device_request import PatchedEmailDeviceRequest +from authentik_client.models.patched_email_stage_request import PatchedEmailStageRequest +from authentik_client.models.patched_endpoint_device_request import PatchedEndpointDeviceRequest +from authentik_client.models.patched_endpoint_request import PatchedEndpointRequest +from authentik_client.models.patched_endpoint_stage_request import PatchedEndpointStageRequest +from authentik_client.models.patched_enrollment_token_request import PatchedEnrollmentTokenRequest +from authentik_client.models.patched_event_matcher_policy_request import PatchedEventMatcherPolicyRequest +from authentik_client.models.patched_event_request import PatchedEventRequest +from authentik_client.models.patched_expression_policy_request import PatchedExpressionPolicyRequest +from authentik_client.models.patched_fleet_connector_request import PatchedFleetConnectorRequest +from authentik_client.models.patched_flow_request import PatchedFlowRequest +from authentik_client.models.patched_flow_stage_binding_request import PatchedFlowStageBindingRequest +from authentik_client.models.patched_geo_ip_policy_request import PatchedGeoIPPolicyRequest +from authentik_client.models.patched_google_chrome_connector_request import PatchedGoogleChromeConnectorRequest +from authentik_client.models.patched_google_endpoint_device_request import PatchedGoogleEndpointDeviceRequest +from authentik_client.models.patched_google_workspace_provider_mapping_request import PatchedGoogleWorkspaceProviderMappingRequest +from authentik_client.models.patched_google_workspace_provider_request import PatchedGoogleWorkspaceProviderRequest +from authentik_client.models.patched_group_kerberos_source_connection_request import PatchedGroupKerberosSourceConnectionRequest +from authentik_client.models.patched_group_ldap_source_connection_request import PatchedGroupLDAPSourceConnectionRequest +from authentik_client.models.patched_group_o_auth_source_connection_request import PatchedGroupOAuthSourceConnectionRequest +from authentik_client.models.patched_group_plex_source_connection_request import PatchedGroupPlexSourceConnectionRequest +from authentik_client.models.patched_group_request import PatchedGroupRequest +from authentik_client.models.patched_group_saml_source_connection_request import PatchedGroupSAMLSourceConnectionRequest +from authentik_client.models.patched_group_source_connection_request import PatchedGroupSourceConnectionRequest +from authentik_client.models.patched_group_telegram_source_connection_request import PatchedGroupTelegramSourceConnectionRequest +from authentik_client.models.patched_identification_stage_request import PatchedIdentificationStageRequest +from authentik_client.models.patched_initial_permissions_request import PatchedInitialPermissionsRequest +from authentik_client.models.patched_invitation_request import PatchedInvitationRequest +from authentik_client.models.patched_invitation_stage_request import PatchedInvitationStageRequest +from authentik_client.models.patched_kerberos_source_property_mapping_request import PatchedKerberosSourcePropertyMappingRequest +from authentik_client.models.patched_kerberos_source_request import PatchedKerberosSourceRequest +from authentik_client.models.patched_kubernetes_service_connection_request import PatchedKubernetesServiceConnectionRequest +from authentik_client.models.patched_ldap_provider_request import PatchedLDAPProviderRequest +from authentik_client.models.patched_ldap_source_property_mapping_request import PatchedLDAPSourcePropertyMappingRequest +from authentik_client.models.patched_ldap_source_request import PatchedLDAPSourceRequest +from authentik_client.models.patched_license_request import PatchedLicenseRequest +from authentik_client.models.patched_lifecycle_rule_request import PatchedLifecycleRuleRequest +from authentik_client.models.patched_microsoft_entra_provider_mapping_request import PatchedMicrosoftEntraProviderMappingRequest +from authentik_client.models.patched_microsoft_entra_provider_request import PatchedMicrosoftEntraProviderRequest +from authentik_client.models.patched_mutual_tls_stage_request import PatchedMutualTLSStageRequest +from authentik_client.models.patched_notification_request import PatchedNotificationRequest +from authentik_client.models.patched_notification_rule_request import PatchedNotificationRuleRequest +from authentik_client.models.patched_notification_transport_request import PatchedNotificationTransportRequest +from authentik_client.models.patched_notification_webhook_mapping_request import PatchedNotificationWebhookMappingRequest +from authentik_client.models.patched_o_auth2_provider_request import PatchedOAuth2ProviderRequest +from authentik_client.models.patched_o_auth_source_property_mapping_request import PatchedOAuthSourcePropertyMappingRequest +from authentik_client.models.patched_o_auth_source_request import PatchedOAuthSourceRequest +from authentik_client.models.patched_outpost_request import PatchedOutpostRequest +from authentik_client.models.patched_password_expiry_policy_request import PatchedPasswordExpiryPolicyRequest +from authentik_client.models.patched_password_policy_request import PatchedPasswordPolicyRequest +from authentik_client.models.patched_password_stage_request import PatchedPasswordStageRequest +from authentik_client.models.patched_permission_assign_request import PatchedPermissionAssignRequest +from authentik_client.models.patched_plex_source_property_mapping_request import PatchedPlexSourcePropertyMappingRequest +from authentik_client.models.patched_plex_source_request import PatchedPlexSourceRequest +from authentik_client.models.patched_policy_binding_request import PatchedPolicyBindingRequest +from authentik_client.models.patched_prompt_request import PatchedPromptRequest +from authentik_client.models.patched_prompt_stage_request import PatchedPromptStageRequest +from authentik_client.models.patched_proxy_provider_request import PatchedProxyProviderRequest +from authentik_client.models.patched_rac_property_mapping_request import PatchedRACPropertyMappingRequest +from authentik_client.models.patched_rac_provider_request import PatchedRACProviderRequest +from authentik_client.models.patched_radius_provider_property_mapping_request import PatchedRadiusProviderPropertyMappingRequest +from authentik_client.models.patched_radius_provider_request import PatchedRadiusProviderRequest +from authentik_client.models.patched_redirect_stage_request import PatchedRedirectStageRequest +from authentik_client.models.patched_reputation_policy_request import PatchedReputationPolicyRequest +from authentik_client.models.patched_role_request import PatchedRoleRequest +from authentik_client.models.patched_saml_property_mapping_request import PatchedSAMLPropertyMappingRequest +from authentik_client.models.patched_saml_provider_request import PatchedSAMLProviderRequest +from authentik_client.models.patched_saml_source_property_mapping_request import PatchedSAMLSourcePropertyMappingRequest +from authentik_client.models.patched_saml_source_request import PatchedSAMLSourceRequest +from authentik_client.models.patched_scim_mapping_request import PatchedSCIMMappingRequest +from authentik_client.models.patched_scim_provider_request import PatchedSCIMProviderRequest +from authentik_client.models.patched_scim_source_group_request import PatchedSCIMSourceGroupRequest +from authentik_client.models.patched_scim_source_property_mapping_request import PatchedSCIMSourcePropertyMappingRequest +from authentik_client.models.patched_scim_source_request import PatchedSCIMSourceRequest +from authentik_client.models.patched_scim_source_user_request import PatchedSCIMSourceUserRequest +from authentik_client.models.patched_sms_device_request import PatchedSMSDeviceRequest +from authentik_client.models.patched_ssf_provider_request import PatchedSSFProviderRequest +from authentik_client.models.patched_schedule_request import PatchedScheduleRequest +from authentik_client.models.patched_scope_mapping_request import PatchedScopeMappingRequest +from authentik_client.models.patched_settings_request import PatchedSettingsRequest +from authentik_client.models.patched_settings_request_flags import PatchedSettingsRequestFlags +from authentik_client.models.patched_source_stage_request import PatchedSourceStageRequest +from authentik_client.models.patched_static_device_request import PatchedStaticDeviceRequest +from authentik_client.models.patched_totp_device_request import PatchedTOTPDeviceRequest +from authentik_client.models.patched_telegram_source_property_mapping_request import PatchedTelegramSourcePropertyMappingRequest +from authentik_client.models.patched_telegram_source_request import PatchedTelegramSourceRequest +from authentik_client.models.patched_tenant_request import PatchedTenantRequest +from authentik_client.models.patched_token_request import PatchedTokenRequest +from authentik_client.models.patched_unique_password_policy_request import PatchedUniquePasswordPolicyRequest +from authentik_client.models.patched_user_delete_stage_request import PatchedUserDeleteStageRequest +from authentik_client.models.patched_user_kerberos_source_connection_request import PatchedUserKerberosSourceConnectionRequest +from authentik_client.models.patched_user_ldap_source_connection_request import PatchedUserLDAPSourceConnectionRequest +from authentik_client.models.patched_user_login_stage_request import PatchedUserLoginStageRequest +from authentik_client.models.patched_user_logout_stage_request import PatchedUserLogoutStageRequest +from authentik_client.models.patched_user_o_auth_source_connection_request import PatchedUserOAuthSourceConnectionRequest +from authentik_client.models.patched_user_plex_source_connection_request import PatchedUserPlexSourceConnectionRequest +from authentik_client.models.patched_user_request import PatchedUserRequest +from authentik_client.models.patched_user_saml_source_connection_request import PatchedUserSAMLSourceConnectionRequest +from authentik_client.models.patched_user_source_connection_request import PatchedUserSourceConnectionRequest +from authentik_client.models.patched_user_telegram_source_connection_request import PatchedUserTelegramSourceConnectionRequest +from authentik_client.models.patched_user_write_stage_request import PatchedUserWriteStageRequest +from authentik_client.models.patched_ws_federation_provider_request import PatchedWSFederationProviderRequest +from authentik_client.models.patched_web_authn_device_request import PatchedWebAuthnDeviceRequest +from authentik_client.models.permission import Permission +from authentik_client.models.permission_assign_request import PermissionAssignRequest +from authentik_client.models.permission_assign_result import PermissionAssignResult +from authentik_client.models.plex_authentication_challenge import PlexAuthenticationChallenge +from authentik_client.models.plex_authentication_challenge_response_request import PlexAuthenticationChallengeResponseRequest +from authentik_client.models.plex_source import PlexSource +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping +from authentik_client.models.plex_source_property_mapping_request import PlexSourcePropertyMappingRequest +from authentik_client.models.plex_source_request import PlexSourceRequest +from authentik_client.models.plex_token_redeem_request import PlexTokenRedeemRequest +from authentik_client.models.policy import Policy +from authentik_client.models.policy_binding import PolicyBinding +from authentik_client.models.policy_binding_request import PolicyBindingRequest +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.policy_test_request import PolicyTestRequest +from authentik_client.models.policy_test_result import PolicyTestResult +from authentik_client.models.process import Process +from authentik_client.models.process_request import ProcessRequest +from authentik_client.models.prompt import Prompt +from authentik_client.models.prompt_challenge import PromptChallenge +from authentik_client.models.prompt_challenge_response_request import PromptChallengeResponseRequest +from authentik_client.models.prompt_choice import PromptChoice +from authentik_client.models.prompt_request import PromptRequest +from authentik_client.models.prompt_stage import PromptStage +from authentik_client.models.prompt_stage_request import PromptStageRequest +from authentik_client.models.prompt_type_enum import PromptTypeEnum +from authentik_client.models.property_mapping import PropertyMapping +from authentik_client.models.property_mapping_preview import PropertyMappingPreview +from authentik_client.models.property_mapping_test_request import PropertyMappingTestRequest +from authentik_client.models.property_mapping_test_result import PropertyMappingTestResult +from authentik_client.models.protocol_enum import ProtocolEnum +from authentik_client.models.provider import Provider +from authentik_client.models.provider_enum import ProviderEnum +from authentik_client.models.provider_model_enum import ProviderModelEnum +from authentik_client.models.provider_type_enum import ProviderTypeEnum +from authentik_client.models.proxy_mode import ProxyMode +from authentik_client.models.proxy_outpost_config import ProxyOutpostConfig +from authentik_client.models.proxy_provider import ProxyProvider +from authentik_client.models.proxy_provider_request import ProxyProviderRequest +from authentik_client.models.rac_property_mapping import RACPropertyMapping +from authentik_client.models.rac_property_mapping_request import RACPropertyMappingRequest +from authentik_client.models.rac_provider import RACProvider +from authentik_client.models.rac_provider_request import RACProviderRequest +from authentik_client.models.radius_check_access import RadiusCheckAccess +from authentik_client.models.radius_outpost_config import RadiusOutpostConfig +from authentik_client.models.radius_provider import RadiusProvider +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping +from authentik_client.models.radius_provider_property_mapping_request import RadiusProviderPropertyMappingRequest +from authentik_client.models.radius_provider_request import RadiusProviderRequest +from authentik_client.models.redirect_challenge import RedirectChallenge +from authentik_client.models.redirect_challenge_response_request import RedirectChallengeResponseRequest +from authentik_client.models.redirect_stage import RedirectStage +from authentik_client.models.redirect_stage_mode_enum import RedirectStageModeEnum +from authentik_client.models.redirect_stage_request import RedirectStageRequest +from authentik_client.models.redirect_uri import RedirectURI +from authentik_client.models.redirect_uri_request import RedirectURIRequest +from authentik_client.models.redirect_uri_type_enum import RedirectURITypeEnum +from authentik_client.models.related_group import RelatedGroup +from authentik_client.models.related_rule import RelatedRule +from authentik_client.models.reputation import Reputation +from authentik_client.models.reputation_policy import ReputationPolicy +from authentik_client.models.reputation_policy_request import ReputationPolicyRequest +from authentik_client.models.review import Review +from authentik_client.models.review_request import ReviewRequest +from authentik_client.models.reviewer_group import ReviewerGroup +from authentik_client.models.reviewer_user import ReviewerUser +from authentik_client.models.role import Role +from authentik_client.models.role_assigned_object_permission import RoleAssignedObjectPermission +from authentik_client.models.role_model_permission import RoleModelPermission +from authentik_client.models.role_object_permission import RoleObjectPermission +from authentik_client.models.role_request import RoleRequest +from authentik_client.models.saml_bindings_enum import SAMLBindingsEnum +from authentik_client.models.saml_logout_methods import SAMLLogoutMethods +from authentik_client.models.saml_metadata import SAMLMetadata +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping +from authentik_client.models.saml_property_mapping_request import SAMLPropertyMappingRequest +from authentik_client.models.saml_provider import SAMLProvider +from authentik_client.models.saml_provider_request import SAMLProviderRequest +from authentik_client.models.saml_source import SAMLSource +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping +from authentik_client.models.saml_source_property_mapping_request import SAMLSourcePropertyMappingRequest +from authentik_client.models.saml_source_request import SAMLSourceRequest +from authentik_client.models.scim_authentication_mode_enum import SCIMAuthenticationModeEnum +from authentik_client.models.scim_mapping import SCIMMapping +from authentik_client.models.scim_mapping_request import SCIMMappingRequest +from authentik_client.models.scim_provider import SCIMProvider +from authentik_client.models.scim_provider_group import SCIMProviderGroup +from authentik_client.models.scim_provider_group_request import SCIMProviderGroupRequest +from authentik_client.models.scim_provider_request import SCIMProviderRequest +from authentik_client.models.scim_provider_user import SCIMProviderUser +from authentik_client.models.scim_provider_user_request import SCIMProviderUserRequest +from authentik_client.models.scim_source import SCIMSource +from authentik_client.models.scim_source_group import SCIMSourceGroup +from authentik_client.models.scim_source_group_request import SCIMSourceGroupRequest +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping +from authentik_client.models.scim_source_property_mapping_request import SCIMSourcePropertyMappingRequest +from authentik_client.models.scim_source_request import SCIMSourceRequest +from authentik_client.models.scim_source_user import SCIMSourceUser +from authentik_client.models.scim_source_user_request import SCIMSourceUserRequest +from authentik_client.models.sms_device import SMSDevice +from authentik_client.models.sms_device_request import SMSDeviceRequest +from authentik_client.models.ssf_provider import SSFProvider +from authentik_client.models.ssf_provider_request import SSFProviderRequest +from authentik_client.models.ssf_stream import SSFStream +from authentik_client.models.ssf_stream_status_enum import SSFStreamStatusEnum +from authentik_client.models.schedule import Schedule +from authentik_client.models.schedule_request import ScheduleRequest +from authentik_client.models.scope_mapping import ScopeMapping +from authentik_client.models.scope_mapping_request import ScopeMappingRequest +from authentik_client.models.selectable_stage import SelectableStage +from authentik_client.models.service_connection import ServiceConnection +from authentik_client.models.service_connection_state import ServiceConnectionState +from authentik_client.models.session_end_challenge import SessionEndChallenge +from authentik_client.models.session_user import SessionUser +from authentik_client.models.settings import Settings +from authentik_client.models.settings_request import SettingsRequest +from authentik_client.models.severity_enum import SeverityEnum +from authentik_client.models.shell_challenge import ShellChallenge +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from authentik_client.models.software import Software +from authentik_client.models.software_request import SoftwareRequest +from authentik_client.models.source import Source +from authentik_client.models.source_stage import SourceStage +from authentik_client.models.source_stage_request import SourceStageRequest +from authentik_client.models.source_type import SourceType +from authentik_client.models.stage import Stage +from authentik_client.models.stage_mode_enum import StageModeEnum +from authentik_client.models.stage_prompt import StagePrompt +from authentik_client.models.static_device import StaticDevice +from authentik_client.models.static_device_request import StaticDeviceRequest +from authentik_client.models.static_device_token import StaticDeviceToken +from authentik_client.models.sub_mode_enum import SubModeEnum +from authentik_client.models.sync_object_model_enum import SyncObjectModelEnum +from authentik_client.models.sync_object_request import SyncObjectRequest +from authentik_client.models.sync_object_result import SyncObjectResult +from authentik_client.models.sync_outgoing_trigger_mode_enum import SyncOutgoingTriggerModeEnum +from authentik_client.models.sync_status import SyncStatus +from authentik_client.models.system_info import SystemInfo +from authentik_client.models.system_info_runtime import SystemInfoRuntime +from authentik_client.models.totp_device import TOTPDevice +from authentik_client.models.totp_device_request import TOTPDeviceRequest +from authentik_client.models.task import Task +from authentik_client.models.task_aggregated_status_enum import TaskAggregatedStatusEnum +from authentik_client.models.task_status_enum import TaskStatusEnum +from authentik_client.models.telegram_auth_request import TelegramAuthRequest +from authentik_client.models.telegram_challenge_response_request import TelegramChallengeResponseRequest +from authentik_client.models.telegram_login_challenge import TelegramLoginChallenge +from authentik_client.models.telegram_source import TelegramSource +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping +from authentik_client.models.telegram_source_property_mapping_request import TelegramSourcePropertyMappingRequest +from authentik_client.models.telegram_source_request import TelegramSourceRequest +from authentik_client.models.tenant import Tenant +from authentik_client.models.tenant_admin_group_request_request import TenantAdminGroupRequestRequest +from authentik_client.models.tenant_recovery_key_request_request import TenantRecoveryKeyRequestRequest +from authentik_client.models.tenant_recovery_key_response import TenantRecoveryKeyResponse +from authentik_client.models.tenant_request import TenantRequest +from authentik_client.models.themed_urls import ThemedUrls +from authentik_client.models.token import Token +from authentik_client.models.token_model import TokenModel +from authentik_client.models.token_request import TokenRequest +from authentik_client.models.token_set_key_request import TokenSetKeyRequest +from authentik_client.models.token_view import TokenView +from authentik_client.models.transaction_application_request import TransactionApplicationRequest +from authentik_client.models.transaction_application_response import TransactionApplicationResponse +from authentik_client.models.transaction_policy_binding_request import TransactionPolicyBindingRequest +from authentik_client.models.transport_mode_enum import TransportModeEnum +from authentik_client.models.type_create import TypeCreate +from authentik_client.models.ui_theme_enum import UiThemeEnum +from authentik_client.models.unique_password_policy import UniquePasswordPolicy +from authentik_client.models.unique_password_policy_request import UniquePasswordPolicyRequest +from authentik_client.models.usage_enum import UsageEnum +from authentik_client.models.used_by import UsedBy +from authentik_client.models.used_by_action_enum import UsedByActionEnum +from authentik_client.models.user import User +from authentik_client.models.user_account_lockdown_request import UserAccountLockdownRequest +from authentik_client.models.user_account_request import UserAccountRequest +from authentik_client.models.user_account_serializer_for_role_request import UserAccountSerializerForRoleRequest +from authentik_client.models.user_attribute_enum import UserAttributeEnum +from authentik_client.models.user_consent import UserConsent +from authentik_client.models.user_creation_mode_enum import UserCreationModeEnum +from authentik_client.models.user_delete_stage import UserDeleteStage +from authentik_client.models.user_delete_stage_request import UserDeleteStageRequest +from authentik_client.models.user_fields_enum import UserFieldsEnum +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection +from authentik_client.models.user_kerberos_source_connection_request import UserKerberosSourceConnectionRequest +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection +from authentik_client.models.user_ldap_source_connection_request import UserLDAPSourceConnectionRequest +from authentik_client.models.user_login_challenge import UserLoginChallenge +from authentik_client.models.user_login_challenge_response_request import UserLoginChallengeResponseRequest +from authentik_client.models.user_login_stage import UserLoginStage +from authentik_client.models.user_login_stage_request import UserLoginStageRequest +from authentik_client.models.user_logout_stage import UserLogoutStage +from authentik_client.models.user_logout_stage_request import UserLogoutStageRequest +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection +from authentik_client.models.user_o_auth_source_connection_request import UserOAuthSourceConnectionRequest +from authentik_client.models.user_password_hash_set_request import UserPasswordHashSetRequest +from authentik_client.models.user_password_set_request import UserPasswordSetRequest +from authentik_client.models.user_path import UserPath +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection +from authentik_client.models.user_plex_source_connection_request import UserPlexSourceConnectionRequest +from authentik_client.models.user_recovery_email_request import UserRecoveryEmailRequest +from authentik_client.models.user_recovery_link_request import UserRecoveryLinkRequest +from authentik_client.models.user_request import UserRequest +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection +from authentik_client.models.user_saml_source_connection_request import UserSAMLSourceConnectionRequest +from authentik_client.models.user_self import UserSelf +from authentik_client.models.user_self_groups import UserSelfGroups +from authentik_client.models.user_self_roles import UserSelfRoles +from authentik_client.models.user_service_account_request import UserServiceAccountRequest +from authentik_client.models.user_service_account_response import UserServiceAccountResponse +from authentik_client.models.user_setting import UserSetting +from authentik_client.models.user_source_connection import UserSourceConnection +from authentik_client.models.user_source_connection_request import UserSourceConnectionRequest +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection +from authentik_client.models.user_telegram_source_connection_request import UserTelegramSourceConnectionRequest +from authentik_client.models.user_type_enum import UserTypeEnum +from authentik_client.models.user_verification_enum import UserVerificationEnum +from authentik_client.models.user_write_stage import UserWriteStage +from authentik_client.models.user_write_stage_request import UserWriteStageRequest +from authentik_client.models.validation_error import ValidationError +from authentik_client.models.vendor_enum import VendorEnum +from authentik_client.models.version import Version +from authentik_client.models.version_history import VersionHistory +from authentik_client.models.ws_federation_provider import WSFederationProvider +from authentik_client.models.ws_federation_provider_request import WSFederationProviderRequest +from authentik_client.models.web_authn_device import WebAuthnDevice +from authentik_client.models.web_authn_device_request import WebAuthnDeviceRequest +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType +from authentik_client.models.web_authn_hint_enum import WebAuthnHintEnum +from authentik_client.models.worker import Worker + diff --git a/authentik_client/models/access_denied_challenge.py b/authentik_client/models/access_denied_challenge.py new file mode 100644 index 000000000..be533c48b --- /dev/null +++ b/authentik_client/models/access_denied_challenge.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AccessDeniedChallenge(BaseModel): + """ + Challenge when a flow's active stage calls `stage_invalid()`. + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-access-denied' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + error_message: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "error_message"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AccessDeniedChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AccessDeniedChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-access-denied', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "error_message": obj.get("error_message") + }) + return _obj + + diff --git a/authentik_client/models/account_lockdown_stage.py b/authentik_client/models/account_lockdown_stage.py new file mode 100644 index 000000000..d945767f4 --- /dev/null +++ b/authentik_client/models/account_lockdown_stage.py @@ -0,0 +1,137 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AccountLockdownStage(BaseModel): + """ + AccountLockdownStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + deactivate_user: Optional[StrictBool] = Field(default=None, description="Deactivate the user account (set is_active to False)") + set_unusable_password: Optional[StrictBool] = Field(default=None, description="Set an unusable password for the user") + delete_sessions: Optional[StrictBool] = Field(default=None, description="Delete all active sessions for the user") + revoke_tokens: Optional[StrictBool] = Field(default=None, description="Revoke all tokens for the user (API, app password, recovery, verification, OAuth)") + self_service_completion_flow: Optional[UUID] = Field(default=None, description="Flow to redirect users to after self-service lockdown. This flow should not require authentication since the user's session is deleted.") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "deactivate_user", "set_unusable_password", "delete_sessions", "revoke_tokens", "self_service_completion_flow"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AccountLockdownStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if self_service_completion_flow (nullable) is None + # and model_fields_set contains the field + if self.self_service_completion_flow is None and "self_service_completion_flow" in self.model_fields_set: + _dict['self_service_completion_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AccountLockdownStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "deactivate_user": obj.get("deactivate_user"), + "set_unusable_password": obj.get("set_unusable_password"), + "delete_sessions": obj.get("delete_sessions"), + "revoke_tokens": obj.get("revoke_tokens"), + "self_service_completion_flow": obj.get("self_service_completion_flow") + }) + return _obj + + diff --git a/authentik_client/models/account_lockdown_stage_request.py b/authentik_client/models/account_lockdown_stage_request.py new file mode 100644 index 000000000..e9da24711 --- /dev/null +++ b/authentik_client/models/account_lockdown_stage_request.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AccountLockdownStageRequest(BaseModel): + """ + AccountLockdownStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + deactivate_user: Optional[StrictBool] = Field(default=None, description="Deactivate the user account (set is_active to False)") + set_unusable_password: Optional[StrictBool] = Field(default=None, description="Set an unusable password for the user") + delete_sessions: Optional[StrictBool] = Field(default=None, description="Delete all active sessions for the user") + revoke_tokens: Optional[StrictBool] = Field(default=None, description="Revoke all tokens for the user (API, app password, recovery, verification, OAuth)") + self_service_completion_flow: Optional[UUID] = Field(default=None, description="Flow to redirect users to after self-service lockdown. This flow should not require authentication since the user's session is deleted.") + __properties: ClassVar[List[str]] = ["name", "deactivate_user", "set_unusable_password", "delete_sessions", "revoke_tokens", "self_service_completion_flow"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AccountLockdownStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if self_service_completion_flow (nullable) is None + # and model_fields_set contains the field + if self.self_service_completion_flow is None and "self_service_completion_flow" in self.model_fields_set: + _dict['self_service_completion_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AccountLockdownStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "deactivate_user": obj.get("deactivate_user"), + "set_unusable_password": obj.get("set_unusable_password"), + "delete_sessions": obj.get("delete_sessions"), + "revoke_tokens": obj.get("revoke_tokens"), + "self_service_completion_flow": obj.get("self_service_completion_flow") + }) + return _obj + + diff --git a/authentik_client/models/agent_authentication_response.py b/authentik_client/models/agent_authentication_response.py new file mode 100644 index 000000000..d397a9cb8 --- /dev/null +++ b/authentik_client/models/agent_authentication_response.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AgentAuthenticationResponse(BaseModel): + """ + Base serializer class which doesn't implement create/update methods + """ # noqa: E501 + url: StrictStr + __properties: ClassVar[List[str]] = ["url"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AgentAuthenticationResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AgentAuthenticationResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "url": obj.get("url") + }) + return _obj + + diff --git a/authentik_client/models/agent_config.py b/authentik_client/models/agent_config.py new file mode 100644 index 000000000..6287afd54 --- /dev/null +++ b/authentik_client/models/agent_config.py @@ -0,0 +1,141 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.config import Config +from authentik_client.models.license_status_enum import LicenseStatusEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AgentConfig(BaseModel): + """ + Base serializer class which doesn't implement create/update methods + """ # noqa: E501 + device_id: StrictStr + refresh_interval: StrictInt + authorization_flow: Optional[StrictStr] + jwks_auth: Dict[str, Any] + jwks_challenge: Optional[Dict[str, Any]] + nss_uid_offset: StrictInt + nss_gid_offset: StrictInt + auth_terminate_session_on_expiry: StrictBool + system_config: Config + license_status: Optional[LicenseStatusEnum] + __properties: ClassVar[List[str]] = ["device_id", "refresh_interval", "authorization_flow", "jwks_auth", "jwks_challenge", "nss_uid_offset", "nss_gid_offset", "auth_terminate_session_on_expiry", "system_config", "license_status"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AgentConfig from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "device_id", + "refresh_interval", + "authorization_flow", + "jwks_auth", + "jwks_challenge", + "system_config", + "license_status", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of system_config + if self.system_config: + _dict['system_config'] = self.system_config.to_dict() + # set to None if authorization_flow (nullable) is None + # and model_fields_set contains the field + if self.authorization_flow is None and "authorization_flow" in self.model_fields_set: + _dict['authorization_flow'] = None + + # set to None if jwks_challenge (nullable) is None + # and model_fields_set contains the field + if self.jwks_challenge is None and "jwks_challenge" in self.model_fields_set: + _dict['jwks_challenge'] = None + + # set to None if license_status (nullable) is None + # and model_fields_set contains the field + if self.license_status is None and "license_status" in self.model_fields_set: + _dict['license_status'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AgentConfig from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_id": obj.get("device_id"), + "refresh_interval": obj.get("refresh_interval"), + "authorization_flow": obj.get("authorization_flow"), + "jwks_auth": obj.get("jwks_auth"), + "jwks_challenge": obj.get("jwks_challenge"), + "nss_uid_offset": obj.get("nss_uid_offset"), + "nss_gid_offset": obj.get("nss_gid_offset"), + "auth_terminate_session_on_expiry": obj.get("auth_terminate_session_on_expiry"), + "system_config": Config.from_dict(obj["system_config"]) if obj.get("system_config") is not None else None, + "license_status": obj.get("license_status") + }) + return _obj + + diff --git a/authentik_client/models/agent_connector.py b/authentik_client/models/agent_connector.py new file mode 100644 index 000000000..d1325b9d5 --- /dev/null +++ b/authentik_client/models/agent_connector.py @@ -0,0 +1,143 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AgentConnector(BaseModel): + """ + AgentConnector + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: StrictStr + enabled: Optional[StrictBool] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + snapshot_expiry: Optional[StrictStr] = None + auth_session_duration: Optional[StrictStr] = None + auth_terminate_session_on_expiry: Optional[StrictBool] = None + refresh_interval: Optional[StrictStr] = None + authorization_flow: Optional[UUID] = None + nss_uid_offset: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + nss_gid_offset: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + challenge_key: Optional[UUID] = None + challenge_idle_timeout: Optional[StrictStr] = None + challenge_trigger_check_in: Optional[StrictBool] = None + jwt_federation_providers: Optional[List[StrictInt]] = None + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "snapshot_expiry", "auth_session_duration", "auth_terminate_session_on_expiry", "refresh_interval", "authorization_flow", "nss_uid_offset", "nss_gid_offset", "challenge_key", "challenge_idle_timeout", "challenge_trigger_check_in", "jwt_federation_providers"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AgentConnector from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authorization_flow (nullable) is None + # and model_fields_set contains the field + if self.authorization_flow is None and "authorization_flow" in self.model_fields_set: + _dict['authorization_flow'] = None + + # set to None if challenge_key (nullable) is None + # and model_fields_set contains the field + if self.challenge_key is None and "challenge_key" in self.model_fields_set: + _dict['challenge_key'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AgentConnector from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "snapshot_expiry": obj.get("snapshot_expiry"), + "auth_session_duration": obj.get("auth_session_duration"), + "auth_terminate_session_on_expiry": obj.get("auth_terminate_session_on_expiry"), + "refresh_interval": obj.get("refresh_interval"), + "authorization_flow": obj.get("authorization_flow"), + "nss_uid_offset": obj.get("nss_uid_offset"), + "nss_gid_offset": obj.get("nss_gid_offset"), + "challenge_key": obj.get("challenge_key"), + "challenge_idle_timeout": obj.get("challenge_idle_timeout"), + "challenge_trigger_check_in": obj.get("challenge_trigger_check_in"), + "jwt_federation_providers": obj.get("jwt_federation_providers") + }) + return _obj + + diff --git a/authentik_client/models/agent_connector_request.py b/authentik_client/models/agent_connector_request.py new file mode 100644 index 000000000..bfaa1bde1 --- /dev/null +++ b/authentik_client/models/agent_connector_request.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AgentConnectorRequest(BaseModel): + """ + AgentConnectorRequest + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: Annotated[str, Field(min_length=1, strict=True)] + enabled: Optional[StrictBool] = None + snapshot_expiry: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + auth_session_duration: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + auth_terminate_session_on_expiry: Optional[StrictBool] = None + refresh_interval: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + authorization_flow: Optional[UUID] = None + nss_uid_offset: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + nss_gid_offset: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + challenge_key: Optional[UUID] = None + challenge_idle_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + challenge_trigger_check_in: Optional[StrictBool] = None + jwt_federation_providers: Optional[List[StrictInt]] = None + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "snapshot_expiry", "auth_session_duration", "auth_terminate_session_on_expiry", "refresh_interval", "authorization_flow", "nss_uid_offset", "nss_gid_offset", "challenge_key", "challenge_idle_timeout", "challenge_trigger_check_in", "jwt_federation_providers"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AgentConnectorRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authorization_flow (nullable) is None + # and model_fields_set contains the field + if self.authorization_flow is None and "authorization_flow" in self.model_fields_set: + _dict['authorization_flow'] = None + + # set to None if challenge_key (nullable) is None + # and model_fields_set contains the field + if self.challenge_key is None and "challenge_key" in self.model_fields_set: + _dict['challenge_key'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AgentConnectorRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "snapshot_expiry": obj.get("snapshot_expiry"), + "auth_session_duration": obj.get("auth_session_duration"), + "auth_terminate_session_on_expiry": obj.get("auth_terminate_session_on_expiry"), + "refresh_interval": obj.get("refresh_interval"), + "authorization_flow": obj.get("authorization_flow"), + "nss_uid_offset": obj.get("nss_uid_offset"), + "nss_gid_offset": obj.get("nss_gid_offset"), + "challenge_key": obj.get("challenge_key"), + "challenge_idle_timeout": obj.get("challenge_idle_timeout"), + "challenge_trigger_check_in": obj.get("challenge_trigger_check_in"), + "jwt_federation_providers": obj.get("jwt_federation_providers") + }) + return _obj + + diff --git a/authentik_client/models/agent_psso_device_registration_request.py b/authentik_client/models/agent_psso_device_registration_request.py new file mode 100644 index 000000000..3ab30b358 --- /dev/null +++ b/authentik_client/models/agent_psso_device_registration_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AgentPSSODeviceRegistrationRequest(BaseModel): + """ + Register Apple device via Platform SSO + """ # noqa: E501 + device_signing_key: Annotated[str, Field(min_length=1, strict=True)] + device_encryption_key: Annotated[str, Field(min_length=1, strict=True)] + sign_key_id: Annotated[str, Field(min_length=1, strict=True)] + enc_key_id: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["device_signing_key", "device_encryption_key", "sign_key_id", "enc_key_id"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AgentPSSODeviceRegistrationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AgentPSSODeviceRegistrationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_signing_key": obj.get("device_signing_key"), + "device_encryption_key": obj.get("device_encryption_key"), + "sign_key_id": obj.get("sign_key_id"), + "enc_key_id": obj.get("enc_key_id") + }) + return _obj + + diff --git a/authentik_client/models/agent_psso_device_registration_response.py b/authentik_client/models/agent_psso_device_registration_response.py new file mode 100644 index 000000000..e5cc5c4ee --- /dev/null +++ b/authentik_client/models/agent_psso_device_registration_response.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AgentPSSODeviceRegistrationResponse(BaseModel): + """ + authentik settings for Platform SSO tokens + """ # noqa: E501 + client_id: StrictStr + issuer: StrictStr + token_endpoint: StrictStr + jwks_endpoint: StrictStr + audience: StrictStr + nonce_endpoint: StrictStr + __properties: ClassVar[List[str]] = ["client_id", "issuer", "token_endpoint", "jwks_endpoint", "audience", "nonce_endpoint"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AgentPSSODeviceRegistrationResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AgentPSSODeviceRegistrationResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "client_id": obj.get("client_id"), + "issuer": obj.get("issuer"), + "token_endpoint": obj.get("token_endpoint"), + "jwks_endpoint": obj.get("jwks_endpoint"), + "audience": obj.get("audience"), + "nonce_endpoint": obj.get("nonce_endpoint") + }) + return _obj + + diff --git a/authentik_client/models/agent_psso_user_registration_request.py b/authentik_client/models/agent_psso_user_registration_request.py new file mode 100644 index 000000000..a964f79d3 --- /dev/null +++ b/authentik_client/models/agent_psso_user_registration_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AgentPSSOUserRegistrationRequest(BaseModel): + """ + Register Apple device user via Platform SSO + """ # noqa: E501 + user_auth: Annotated[str, Field(min_length=1, strict=True)] + user_secure_enclave_key: Annotated[str, Field(min_length=1, strict=True)] + enclave_key_id: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["user_auth", "user_secure_enclave_key", "enclave_key_id"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AgentPSSOUserRegistrationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AgentPSSOUserRegistrationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user_auth": obj.get("user_auth"), + "user_secure_enclave_key": obj.get("user_secure_enclave_key"), + "enclave_key_id": obj.get("enclave_key_id") + }) + return _obj + + diff --git a/authentik_client/models/agent_token_response.py b/authentik_client/models/agent_token_response.py new file mode 100644 index 000000000..9a544ca22 --- /dev/null +++ b/authentik_client/models/agent_token_response.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AgentTokenResponse(BaseModel): + """ + Base serializer class which doesn't implement create/update methods + """ # noqa: E501 + token: StrictStr + expires_in: Optional[StrictInt] = None + __properties: ClassVar[List[str]] = ["token", "expires_in"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AgentTokenResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AgentTokenResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "token": obj.get("token"), + "expires_in": obj.get("expires_in") + }) + return _obj + + diff --git a/authentik_client/models/alg_enum.py b/authentik_client/models/alg_enum.py new file mode 100644 index 000000000..74d3eece8 --- /dev/null +++ b/authentik_client/models/alg_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class AlgEnum(str, Enum): + """ + AlgEnum + """ + + """ + allowed enum values + """ + RSA = 'rsa' + ECDSA = 'ecdsa' + ED25519 = 'ed25519' + ED448 = 'ed448' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of AlgEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/app.py b/authentik_client/models/app.py new file mode 100644 index 000000000..2f5ddc3f8 --- /dev/null +++ b/authentik_client/models/app.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class App(BaseModel): + """ + Serialize Application info + """ # noqa: E501 + name: StrictStr + label: StrictStr + __properties: ClassVar[List[str]] = ["name", "label"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of App from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of App from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "label": obj.get("label") + }) + return _obj + + diff --git a/authentik_client/models/app_enum.py b/authentik_client/models/app_enum.py new file mode 100644 index 000000000..4ef164fd0 --- /dev/null +++ b/authentik_client/models/app_enum.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class AppEnum(str, Enum): + """ + AppEnum + """ + + """ + allowed enum values + """ + AUTHENTIK_DOT_COMMANDS = 'authentik.commands' + AUTHENTIK_DOT_TENANTS = 'authentik.tenants' + AUTHENTIK_DOT_TASKS = 'authentik.tasks' + AUTHENTIK_DOT_ADMIN = 'authentik.admin' + AUTHENTIK_DOT_API = 'authentik.api' + AUTHENTIK_DOT_CORE = 'authentik.core' + AUTHENTIK_DOT_CRYPTO = 'authentik.crypto' + AUTHENTIK_DOT_ENDPOINTS = 'authentik.endpoints' + AUTHENTIK_DOT_ENDPOINTS_DOT_CONNECTORS_DOT_AGENT = 'authentik.endpoints.connectors.agent' + AUTHENTIK_DOT_ENTERPRISE = 'authentik.enterprise' + AUTHENTIK_DOT_EVENTS = 'authentik.events' + AUTHENTIK_DOT_ADMIN_DOT_FILES = 'authentik.admin.files' + AUTHENTIK_DOT_FLOWS = 'authentik.flows' + AUTHENTIK_DOT_OUTPOSTS = 'authentik.outposts' + AUTHENTIK_DOT_POLICIES_DOT_DUMMY = 'authentik.policies.dummy' + AUTHENTIK_DOT_POLICIES_DOT_EVENT_MATCHER = 'authentik.policies.event_matcher' + AUTHENTIK_DOT_POLICIES_DOT_EXPIRY = 'authentik.policies.expiry' + AUTHENTIK_DOT_POLICIES_DOT_EXPRESSION = 'authentik.policies.expression' + AUTHENTIK_DOT_POLICIES_DOT_GEOIP = 'authentik.policies.geoip' + AUTHENTIK_DOT_POLICIES_DOT_PASSWORD = 'authentik.policies.password' + AUTHENTIK_DOT_POLICIES_DOT_REPUTATION = 'authentik.policies.reputation' + AUTHENTIK_DOT_POLICIES = 'authentik.policies' + AUTHENTIK_DOT_PROVIDERS_DOT_LDAP = 'authentik.providers.ldap' + AUTHENTIK_DOT_PROVIDERS_DOT_OAUTH2 = 'authentik.providers.oauth2' + AUTHENTIK_DOT_PROVIDERS_DOT_PROXY = 'authentik.providers.proxy' + AUTHENTIK_DOT_PROVIDERS_DOT_RAC = 'authentik.providers.rac' + AUTHENTIK_DOT_PROVIDERS_DOT_RADIUS = 'authentik.providers.radius' + AUTHENTIK_DOT_PROVIDERS_DOT_SAML = 'authentik.providers.saml' + AUTHENTIK_DOT_PROVIDERS_DOT_SCIM = 'authentik.providers.scim' + AUTHENTIK_DOT_RBAC = 'authentik.rbac' + AUTHENTIK_DOT_RECOVERY = 'authentik.recovery' + AUTHENTIK_DOT_SOURCES_DOT_KERBEROS = 'authentik.sources.kerberos' + AUTHENTIK_DOT_SOURCES_DOT_LDAP = 'authentik.sources.ldap' + AUTHENTIK_DOT_SOURCES_DOT_OAUTH = 'authentik.sources.oauth' + AUTHENTIK_DOT_SOURCES_DOT_PLEX = 'authentik.sources.plex' + AUTHENTIK_DOT_SOURCES_DOT_SAML = 'authentik.sources.saml' + AUTHENTIK_DOT_SOURCES_DOT_SCIM = 'authentik.sources.scim' + AUTHENTIK_DOT_SOURCES_DOT_TELEGRAM = 'authentik.sources.telegram' + AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR = 'authentik.stages.authenticator' + AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_DUO = 'authentik.stages.authenticator_duo' + AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_EMAIL = 'authentik.stages.authenticator_email' + AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_SMS = 'authentik.stages.authenticator_sms' + AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_STATIC = 'authentik.stages.authenticator_static' + AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_TOTP = 'authentik.stages.authenticator_totp' + AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_VALIDATE = 'authentik.stages.authenticator_validate' + AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_WEBAUTHN = 'authentik.stages.authenticator_webauthn' + AUTHENTIK_DOT_STAGES_DOT_CAPTCHA = 'authentik.stages.captcha' + AUTHENTIK_DOT_STAGES_DOT_CONSENT = 'authentik.stages.consent' + AUTHENTIK_DOT_STAGES_DOT_DENY = 'authentik.stages.deny' + AUTHENTIK_DOT_STAGES_DOT_DUMMY = 'authentik.stages.dummy' + AUTHENTIK_DOT_STAGES_DOT_EMAIL = 'authentik.stages.email' + AUTHENTIK_DOT_STAGES_DOT_IDENTIFICATION = 'authentik.stages.identification' + AUTHENTIK_DOT_STAGES_DOT_INVITATION = 'authentik.stages.invitation' + AUTHENTIK_DOT_STAGES_DOT_PASSWORD = 'authentik.stages.password' + AUTHENTIK_DOT_STAGES_DOT_PROMPT = 'authentik.stages.prompt' + AUTHENTIK_DOT_STAGES_DOT_REDIRECT = 'authentik.stages.redirect' + AUTHENTIK_DOT_STAGES_DOT_USER_DELETE = 'authentik.stages.user_delete' + AUTHENTIK_DOT_STAGES_DOT_USER_LOGIN = 'authentik.stages.user_login' + AUTHENTIK_DOT_STAGES_DOT_USER_LOGOUT = 'authentik.stages.user_logout' + AUTHENTIK_DOT_STAGES_DOT_USER_WRITE = 'authentik.stages.user_write' + AUTHENTIK_DOT_TASKS_DOT_SCHEDULES = 'authentik.tasks.schedules' + AUTHENTIK_DOT_BRANDS = 'authentik.brands' + AUTHENTIK_DOT_BLUEPRINTS = 'authentik.blueprints' + AUTHENTIK_DOT_ENTERPRISE_DOT_AUDIT = 'authentik.enterprise.audit' + AUTHENTIK_DOT_ENTERPRISE_DOT_ENDPOINTS_DOT_CONNECTORS_DOT_AGENT = 'authentik.enterprise.endpoints.connectors.agent' + AUTHENTIK_DOT_ENTERPRISE_DOT_ENDPOINTS_DOT_CONNECTORS_DOT_FLEET = 'authentik.enterprise.endpoints.connectors.fleet' + AUTHENTIK_DOT_ENTERPRISE_DOT_ENDPOINTS_DOT_CONNECTORS_DOT_GOOGLE_CHROME = 'authentik.enterprise.endpoints.connectors.google_chrome' + AUTHENTIK_DOT_ENTERPRISE_DOT_LIFECYCLE = 'authentik.enterprise.lifecycle' + AUTHENTIK_DOT_ENTERPRISE_DOT_POLICIES_DOT_UNIQUE_PASSWORD = 'authentik.enterprise.policies.unique_password' + AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_GOOGLE_WORKSPACE = 'authentik.enterprise.providers.google_workspace' + AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_MICROSOFT_ENTRA = 'authentik.enterprise.providers.microsoft_entra' + AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_RADIUS = 'authentik.enterprise.providers.radius' + AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_SCIM = 'authentik.enterprise.providers.scim' + AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_SSF = 'authentik.enterprise.providers.ssf' + AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_WS_FEDERATION = 'authentik.enterprise.providers.ws_federation' + AUTHENTIK_DOT_ENTERPRISE_DOT_REPORTS = 'authentik.enterprise.reports' + AUTHENTIK_DOT_ENTERPRISE_DOT_STAGES_DOT_ACCOUNT_LOCKDOWN = 'authentik.enterprise.stages.account_lockdown' + AUTHENTIK_DOT_ENTERPRISE_DOT_STAGES_DOT_AUTHENTICATOR_ENDPOINT_GDTC = 'authentik.enterprise.stages.authenticator_endpoint_gdtc' + AUTHENTIK_DOT_ENTERPRISE_DOT_STAGES_DOT_MTLS = 'authentik.enterprise.stages.mtls' + AUTHENTIK_DOT_ENTERPRISE_DOT_STAGES_DOT_SOURCE = 'authentik.enterprise.stages.source' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of AppEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/apple_challenge_response_request.py b/authentik_client/models/apple_challenge_response_request.py new file mode 100644 index 000000000..b917f0ab6 --- /dev/null +++ b/authentik_client/models/apple_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AppleChallengeResponseRequest(BaseModel): + """ + Pseudo class for apple response + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-source-oauth-apple' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AppleChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AppleChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-source-oauth-apple' + }) + return _obj + + diff --git a/authentik_client/models/apple_independent_secure_enclave.py b/authentik_client/models/apple_independent_secure_enclave.py new file mode 100644 index 000000000..6062cf036 --- /dev/null +++ b/authentik_client/models/apple_independent_secure_enclave.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AppleIndependentSecureEnclave(BaseModel): + """ + AppleIndependentSecureEnclave + """ # noqa: E501 + uuid: Optional[UUID] = None + user: StrictInt = Field(description="The user that this device belongs to.") + apple_secure_enclave_key: StrictStr + apple_enclave_key_id: StrictStr + device_type: StrictStr + __properties: ClassVar[List[str]] = ["uuid", "user", "apple_secure_enclave_key", "apple_enclave_key_id", "device_type"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AppleIndependentSecureEnclave from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AppleIndependentSecureEnclave from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "uuid": obj.get("uuid"), + "user": obj.get("user"), + "apple_secure_enclave_key": obj.get("apple_secure_enclave_key"), + "apple_enclave_key_id": obj.get("apple_enclave_key_id"), + "device_type": obj.get("device_type") + }) + return _obj + + diff --git a/authentik_client/models/apple_independent_secure_enclave_request.py b/authentik_client/models/apple_independent_secure_enclave_request.py new file mode 100644 index 000000000..62491eb5d --- /dev/null +++ b/authentik_client/models/apple_independent_secure_enclave_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AppleIndependentSecureEnclaveRequest(BaseModel): + """ + AppleIndependentSecureEnclaveRequest + """ # noqa: E501 + uuid: Optional[UUID] = None + user: StrictInt = Field(description="The user that this device belongs to.") + apple_secure_enclave_key: Annotated[str, Field(min_length=1, strict=True)] + apple_enclave_key_id: Annotated[str, Field(min_length=1, strict=True)] + device_type: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["uuid", "user", "apple_secure_enclave_key", "apple_enclave_key_id", "device_type"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AppleIndependentSecureEnclaveRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AppleIndependentSecureEnclaveRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "uuid": obj.get("uuid"), + "user": obj.get("user"), + "apple_secure_enclave_key": obj.get("apple_secure_enclave_key"), + "apple_enclave_key_id": obj.get("apple_enclave_key_id"), + "device_type": obj.get("device_type") + }) + return _obj + + diff --git a/authentik_client/models/apple_login_challenge.py b/authentik_client/models/apple_login_challenge.py new file mode 100644 index 000000000..11a091bbe --- /dev/null +++ b/authentik_client/models/apple_login_challenge.py @@ -0,0 +1,120 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AppleLoginChallenge(BaseModel): + """ + Special challenge for apple-native authentication flow, which happens on the client. + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-source-oauth-apple' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + client_id: StrictStr + scope: StrictStr + redirect_uri: StrictStr + state: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "client_id", "scope", "redirect_uri", "state"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AppleLoginChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AppleLoginChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-source-oauth-apple', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "client_id": obj.get("client_id"), + "scope": obj.get("scope"), + "redirect_uri": obj.get("redirect_uri"), + "state": obj.get("state") + }) + return _obj + + diff --git a/authentik_client/models/application.py b/authentik_client/models/application.py new file mode 100644 index 000000000..673c100b8 --- /dev/null +++ b/authentik_client/models/application.py @@ -0,0 +1,188 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.provider import Provider +from authentik_client.models.themed_urls import ThemedUrls +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Application(BaseModel): + """ + Application Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr = Field(description="Application's display Name.") + slug: Annotated[str, Field(strict=True)] = Field(description="Internal application name, used in URLs.") + provider: Optional[StrictInt] = None + provider_obj: Optional[Provider] + backchannel_providers: Optional[List[StrictInt]] = None + backchannel_providers_obj: List[Provider] + launch_url: Optional[StrictStr] = Field(description="Allow formatting of launch URL") + open_in_new_tab: Optional[StrictBool] = Field(default=None, description="Open launch URL in a new browser tab or window.") + meta_launch_url: Optional[StrictStr] = None + meta_icon: Optional[StrictStr] = None + meta_icon_url: Optional[StrictStr] = Field(description="Get the URL to the App Icon image") + meta_icon_themed_urls: Optional[ThemedUrls] + meta_description: Optional[StrictStr] = None + meta_publisher: Optional[StrictStr] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + group: Optional[StrictStr] = None + meta_hide: Optional[StrictBool] = Field(default=None, description="Hide this application from the user's My applications page.") + __properties: ClassVar[List[str]] = ["pk", "name", "slug", "provider", "provider_obj", "backchannel_providers", "backchannel_providers_obj", "launch_url", "open_in_new_tab", "meta_launch_url", "meta_icon", "meta_icon_url", "meta_icon_themed_urls", "meta_description", "meta_publisher", "policy_engine_mode", "group", "meta_hide"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Application from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "provider_obj", + "backchannel_providers_obj", + "launch_url", + "meta_icon_url", + "meta_icon_themed_urls", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of provider_obj + if self.provider_obj: + _dict['provider_obj'] = self.provider_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in backchannel_providers_obj (list) + _items = [] + if self.backchannel_providers_obj: + for _item_backchannel_providers_obj in self.backchannel_providers_obj: + if _item_backchannel_providers_obj: + _items.append(_item_backchannel_providers_obj.to_dict()) + _dict['backchannel_providers_obj'] = _items + # override the default output from pydantic by calling `to_dict()` of meta_icon_themed_urls + if self.meta_icon_themed_urls: + _dict['meta_icon_themed_urls'] = self.meta_icon_themed_urls.to_dict() + # set to None if provider (nullable) is None + # and model_fields_set contains the field + if self.provider is None and "provider" in self.model_fields_set: + _dict['provider'] = None + + # set to None if provider_obj (nullable) is None + # and model_fields_set contains the field + if self.provider_obj is None and "provider_obj" in self.model_fields_set: + _dict['provider_obj'] = None + + # set to None if launch_url (nullable) is None + # and model_fields_set contains the field + if self.launch_url is None and "launch_url" in self.model_fields_set: + _dict['launch_url'] = None + + # set to None if meta_icon_url (nullable) is None + # and model_fields_set contains the field + if self.meta_icon_url is None and "meta_icon_url" in self.model_fields_set: + _dict['meta_icon_url'] = None + + # set to None if meta_icon_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.meta_icon_themed_urls is None and "meta_icon_themed_urls" in self.model_fields_set: + _dict['meta_icon_themed_urls'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Application from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "provider": obj.get("provider"), + "provider_obj": Provider.from_dict(obj["provider_obj"]) if obj.get("provider_obj") is not None else None, + "backchannel_providers": obj.get("backchannel_providers"), + "backchannel_providers_obj": [Provider.from_dict(_item) for _item in obj["backchannel_providers_obj"]] if obj.get("backchannel_providers_obj") is not None else None, + "launch_url": obj.get("launch_url"), + "open_in_new_tab": obj.get("open_in_new_tab"), + "meta_launch_url": obj.get("meta_launch_url"), + "meta_icon": obj.get("meta_icon"), + "meta_icon_url": obj.get("meta_icon_url"), + "meta_icon_themed_urls": ThemedUrls.from_dict(obj["meta_icon_themed_urls"]) if obj.get("meta_icon_themed_urls") is not None else None, + "meta_description": obj.get("meta_description"), + "meta_publisher": obj.get("meta_publisher"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "group": obj.get("group"), + "meta_hide": obj.get("meta_hide") + }) + return _obj + + diff --git a/authentik_client/models/application_entitlement.py b/authentik_client/models/application_entitlement.py new file mode 100644 index 000000000..a18d9de56 --- /dev/null +++ b/authentik_client/models/application_entitlement.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ApplicationEntitlement(BaseModel): + """ + ApplicationEntitlement Serializer + """ # noqa: E501 + pbm_uuid: UUID + name: StrictStr + app: UUID + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["pbm_uuid", "name", "app", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ApplicationEntitlement from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pbm_uuid", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ApplicationEntitlement from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pbm_uuid": obj.get("pbm_uuid"), + "name": obj.get("name"), + "app": obj.get("app"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/application_entitlement_request.py b/authentik_client/models/application_entitlement_request.py new file mode 100644 index 000000000..56dabdc73 --- /dev/null +++ b/authentik_client/models/application_entitlement_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ApplicationEntitlementRequest(BaseModel): + """ + ApplicationEntitlement Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + app: UUID + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["name", "app", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ApplicationEntitlementRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ApplicationEntitlementRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "app": obj.get("app"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/application_request.py b/authentik_client/models/application_request.py new file mode 100644 index 000000000..c93ce793d --- /dev/null +++ b/authentik_client/models/application_request.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ApplicationRequest(BaseModel): + """ + Application Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Application's display Name.") + slug: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Internal application name, used in URLs.") + provider: Optional[StrictInt] = None + backchannel_providers: Optional[List[StrictInt]] = None + open_in_new_tab: Optional[StrictBool] = Field(default=None, description="Open launch URL in a new browser tab or window.") + meta_launch_url: Optional[StrictStr] = None + meta_icon: Optional[StrictStr] = None + meta_description: Optional[StrictStr] = None + meta_publisher: Optional[StrictStr] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + group: Optional[StrictStr] = None + meta_hide: Optional[StrictBool] = Field(default=None, description="Hide this application from the user's My applications page.") + __properties: ClassVar[List[str]] = ["name", "slug", "provider", "backchannel_providers", "open_in_new_tab", "meta_launch_url", "meta_icon", "meta_description", "meta_publisher", "policy_engine_mode", "group", "meta_hide"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ApplicationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if provider (nullable) is None + # and model_fields_set contains the field + if self.provider is None and "provider" in self.model_fields_set: + _dict['provider'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ApplicationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "provider": obj.get("provider"), + "backchannel_providers": obj.get("backchannel_providers"), + "open_in_new_tab": obj.get("open_in_new_tab"), + "meta_launch_url": obj.get("meta_launch_url"), + "meta_icon": obj.get("meta_icon"), + "meta_description": obj.get("meta_description"), + "meta_publisher": obj.get("meta_publisher"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "group": obj.get("group"), + "meta_hide": obj.get("meta_hide") + }) + return _obj + + diff --git a/authentik_client/models/auth_type_enum.py b/authentik_client/models/auth_type_enum.py new file mode 100644 index 000000000..4d7469b3f --- /dev/null +++ b/authentik_client/models/auth_type_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class AuthTypeEnum(str, Enum): + """ + AuthTypeEnum + """ + + """ + allowed enum values + """ + BASIC = 'basic' + BEARER = 'bearer' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of AuthTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/authenticated_session.py b/authentik_client/models/authenticated_session.py new file mode 100644 index 000000000..8cb8bd386 --- /dev/null +++ b/authentik_client/models/authenticated_session.py @@ -0,0 +1,141 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.authenticated_session_asn import AuthenticatedSessionAsn +from authentik_client.models.authenticated_session_geo_ip import AuthenticatedSessionGeoIp +from authentik_client.models.authenticated_session_user_agent import AuthenticatedSessionUserAgent +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatedSession(BaseModel): + """ + AuthenticatedSession Serializer + """ # noqa: E501 + uuid: Optional[UUID] = None + current: StrictBool = Field(description="Check if session is currently active session") + user_agent: AuthenticatedSessionUserAgent + geo_ip: Optional[AuthenticatedSessionGeoIp] + asn: Optional[AuthenticatedSessionAsn] + user: StrictInt + last_ip: StrictStr + last_user_agent: StrictStr + last_used: datetime + expires: datetime + __properties: ClassVar[List[str]] = ["uuid", "current", "user_agent", "geo_ip", "asn", "user", "last_ip", "last_user_agent", "last_used", "expires"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatedSession from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "current", + "last_ip", + "last_user_agent", + "last_used", + "expires", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user_agent + if self.user_agent: + _dict['user_agent'] = self.user_agent.to_dict() + # override the default output from pydantic by calling `to_dict()` of geo_ip + if self.geo_ip: + _dict['geo_ip'] = self.geo_ip.to_dict() + # override the default output from pydantic by calling `to_dict()` of asn + if self.asn: + _dict['asn'] = self.asn.to_dict() + # set to None if geo_ip (nullable) is None + # and model_fields_set contains the field + if self.geo_ip is None and "geo_ip" in self.model_fields_set: + _dict['geo_ip'] = None + + # set to None if asn (nullable) is None + # and model_fields_set contains the field + if self.asn is None and "asn" in self.model_fields_set: + _dict['asn'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatedSession from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "uuid": obj.get("uuid"), + "current": obj.get("current"), + "user_agent": AuthenticatedSessionUserAgent.from_dict(obj["user_agent"]) if obj.get("user_agent") is not None else None, + "geo_ip": AuthenticatedSessionGeoIp.from_dict(obj["geo_ip"]) if obj.get("geo_ip") is not None else None, + "asn": AuthenticatedSessionAsn.from_dict(obj["asn"]) if obj.get("asn") is not None else None, + "user": obj.get("user"), + "last_ip": obj.get("last_ip"), + "last_user_agent": obj.get("last_user_agent"), + "last_used": obj.get("last_used"), + "expires": obj.get("expires") + }) + return _obj + + diff --git a/authentik_client/models/authenticated_session_asn.py b/authentik_client/models/authenticated_session_asn.py new file mode 100644 index 000000000..779bd5828 --- /dev/null +++ b/authentik_client/models/authenticated_session_asn.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatedSessionAsn(BaseModel): + """ + Get ASN Data + """ # noqa: E501 + asn: Optional[StrictInt] + as_org: Optional[StrictStr] + network: Optional[StrictStr] + __properties: ClassVar[List[str]] = ["asn", "as_org", "network"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatedSessionAsn from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if asn (nullable) is None + # and model_fields_set contains the field + if self.asn is None and "asn" in self.model_fields_set: + _dict['asn'] = None + + # set to None if as_org (nullable) is None + # and model_fields_set contains the field + if self.as_org is None and "as_org" in self.model_fields_set: + _dict['as_org'] = None + + # set to None if network (nullable) is None + # and model_fields_set contains the field + if self.network is None and "network" in self.model_fields_set: + _dict['network'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatedSessionAsn from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "asn": obj.get("asn"), + "as_org": obj.get("as_org"), + "network": obj.get("network") + }) + return _obj + + diff --git a/authentik_client/models/authenticated_session_geo_ip.py b/authentik_client/models/authenticated_session_geo_ip.py new file mode 100644 index 000000000..d252bc266 --- /dev/null +++ b/authentik_client/models/authenticated_session_geo_ip.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional, Union +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatedSessionGeoIp(BaseModel): + """ + Get GeoIP Data + """ # noqa: E501 + continent: Optional[StrictStr] + country: Optional[StrictStr] + lat: Optional[Union[StrictFloat, StrictInt]] + long: Optional[Union[StrictFloat, StrictInt]] + city: StrictStr + __properties: ClassVar[List[str]] = ["continent", "country", "lat", "long", "city"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatedSessionGeoIp from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if continent (nullable) is None + # and model_fields_set contains the field + if self.continent is None and "continent" in self.model_fields_set: + _dict['continent'] = None + + # set to None if country (nullable) is None + # and model_fields_set contains the field + if self.country is None and "country" in self.model_fields_set: + _dict['country'] = None + + # set to None if lat (nullable) is None + # and model_fields_set contains the field + if self.lat is None and "lat" in self.model_fields_set: + _dict['lat'] = None + + # set to None if long (nullable) is None + # and model_fields_set contains the field + if self.long is None and "long" in self.model_fields_set: + _dict['long'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatedSessionGeoIp from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "continent": obj.get("continent"), + "country": obj.get("country"), + "lat": obj.get("lat"), + "long": obj.get("long"), + "city": obj.get("city") + }) + return _obj + + diff --git a/authentik_client/models/authenticated_session_user_agent.py b/authentik_client/models/authenticated_session_user_agent.py new file mode 100644 index 000000000..b442a1da8 --- /dev/null +++ b/authentik_client/models/authenticated_session_user_agent.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticated_session_user_agent_device import AuthenticatedSessionUserAgentDevice +from authentik_client.models.authenticated_session_user_agent_os import AuthenticatedSessionUserAgentOs +from authentik_client.models.authenticated_session_user_agent_user_agent import AuthenticatedSessionUserAgentUserAgent +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatedSessionUserAgent(BaseModel): + """ + Get parsed user agent + """ # noqa: E501 + device: AuthenticatedSessionUserAgentDevice + os: AuthenticatedSessionUserAgentOs + user_agent: AuthenticatedSessionUserAgentUserAgent + string: StrictStr + __properties: ClassVar[List[str]] = ["device", "os", "user_agent", "string"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatedSessionUserAgent from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of device + if self.device: + _dict['device'] = self.device.to_dict() + # override the default output from pydantic by calling `to_dict()` of os + if self.os: + _dict['os'] = self.os.to_dict() + # override the default output from pydantic by calling `to_dict()` of user_agent + if self.user_agent: + _dict['user_agent'] = self.user_agent.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatedSessionUserAgent from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device": AuthenticatedSessionUserAgentDevice.from_dict(obj["device"]) if obj.get("device") is not None else None, + "os": AuthenticatedSessionUserAgentOs.from_dict(obj["os"]) if obj.get("os") is not None else None, + "user_agent": AuthenticatedSessionUserAgentUserAgent.from_dict(obj["user_agent"]) if obj.get("user_agent") is not None else None, + "string": obj.get("string") + }) + return _obj + + diff --git a/authentik_client/models/authenticated_session_user_agent_device.py b/authentik_client/models/authenticated_session_user_agent_device.py new file mode 100644 index 000000000..fc977fd40 --- /dev/null +++ b/authentik_client/models/authenticated_session_user_agent_device.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatedSessionUserAgentDevice(BaseModel): + """ + User agent device + """ # noqa: E501 + brand: Optional[StrictStr] + family: StrictStr + model: Optional[StrictStr] + __properties: ClassVar[List[str]] = ["brand", "family", "model"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatedSessionUserAgentDevice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if brand (nullable) is None + # and model_fields_set contains the field + if self.brand is None and "brand" in self.model_fields_set: + _dict['brand'] = None + + # set to None if model (nullable) is None + # and model_fields_set contains the field + if self.model is None and "model" in self.model_fields_set: + _dict['model'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatedSessionUserAgentDevice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "brand": obj.get("brand"), + "family": obj.get("family"), + "model": obj.get("model") + }) + return _obj + + diff --git a/authentik_client/models/authenticated_session_user_agent_os.py b/authentik_client/models/authenticated_session_user_agent_os.py new file mode 100644 index 000000000..1b4ea31ee --- /dev/null +++ b/authentik_client/models/authenticated_session_user_agent_os.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatedSessionUserAgentOs(BaseModel): + """ + User agent os + """ # noqa: E501 + family: StrictStr + major: Optional[StrictStr] + minor: Optional[StrictStr] + patch: Optional[StrictStr] + patch_minor: Optional[StrictStr] + __properties: ClassVar[List[str]] = ["family", "major", "minor", "patch", "patch_minor"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatedSessionUserAgentOs from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if major (nullable) is None + # and model_fields_set contains the field + if self.major is None and "major" in self.model_fields_set: + _dict['major'] = None + + # set to None if minor (nullable) is None + # and model_fields_set contains the field + if self.minor is None and "minor" in self.model_fields_set: + _dict['minor'] = None + + # set to None if patch (nullable) is None + # and model_fields_set contains the field + if self.patch is None and "patch" in self.model_fields_set: + _dict['patch'] = None + + # set to None if patch_minor (nullable) is None + # and model_fields_set contains the field + if self.patch_minor is None and "patch_minor" in self.model_fields_set: + _dict['patch_minor'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatedSessionUserAgentOs from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "family": obj.get("family"), + "major": obj.get("major"), + "minor": obj.get("minor"), + "patch": obj.get("patch"), + "patch_minor": obj.get("patch_minor") + }) + return _obj + + diff --git a/authentik_client/models/authenticated_session_user_agent_user_agent.py b/authentik_client/models/authenticated_session_user_agent_user_agent.py new file mode 100644 index 000000000..e67fd6364 --- /dev/null +++ b/authentik_client/models/authenticated_session_user_agent_user_agent.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatedSessionUserAgentUserAgent(BaseModel): + """ + User agent browser + """ # noqa: E501 + family: StrictStr + major: StrictStr + minor: StrictStr + patch: StrictStr + __properties: ClassVar[List[str]] = ["family", "major", "minor", "patch"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatedSessionUserAgentUserAgent from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatedSessionUserAgentUserAgent from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "family": obj.get("family"), + "major": obj.get("major"), + "minor": obj.get("minor"), + "patch": obj.get("patch") + }) + return _obj + + diff --git a/authentik_client/models/authentication_enum.py b/authentik_client/models/authentication_enum.py new file mode 100644 index 000000000..946ef0cbf --- /dev/null +++ b/authentik_client/models/authentication_enum.py @@ -0,0 +1,43 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class AuthenticationEnum(str, Enum): + """ + AuthenticationEnum + """ + + """ + allowed enum values + """ + NONE = 'none' + REQUIRE_AUTHENTICATED = 'require_authenticated' + REQUIRE_UNAUTHENTICATED = 'require_unauthenticated' + REQUIRE_SUPERUSER = 'require_superuser' + REQUIRE_REDIRECT = 'require_redirect' + REQUIRE_OUTPOST = 'require_outpost' + REQUIRE_TOKEN = 'require_token' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of AuthenticationEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/authenticator_attachment_enum.py b/authentik_client/models/authenticator_attachment_enum.py new file mode 100644 index 000000000..3b987cc2e --- /dev/null +++ b/authentik_client/models/authenticator_attachment_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class AuthenticatorAttachmentEnum(str, Enum): + """ + AuthenticatorAttachmentEnum + """ + + """ + allowed enum values + """ + PLATFORM = 'platform' + CROSS_MINUS_PLATFORM = 'cross-platform' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of AuthenticatorAttachmentEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/authenticator_duo_challenge.py b/authentik_client/models/authenticator_duo_challenge.py new file mode 100644 index 000000000..cf90f31ba --- /dev/null +++ b/authentik_client/models/authenticator_duo_challenge.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorDuoChallenge(BaseModel): + """ + Duo Challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-authenticator-duo' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + activation_barcode: StrictStr + activation_code: StrictStr + stage_uuid: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "activation_barcode", "activation_code", "stage_uuid"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorDuoChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorDuoChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-duo', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "activation_barcode": obj.get("activation_barcode"), + "activation_code": obj.get("activation_code"), + "stage_uuid": obj.get("stage_uuid") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_duo_challenge_response_request.py b/authentik_client/models/authenticator_duo_challenge_response_request.py new file mode 100644 index 000000000..d3b767f44 --- /dev/null +++ b/authentik_client/models/authenticator_duo_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorDuoChallengeResponseRequest(BaseModel): + """ + Pseudo class for duo response + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-authenticator-duo' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorDuoChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorDuoChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-duo' + }) + return _obj + + diff --git a/authentik_client/models/authenticator_duo_stage.py b/authentik_client/models/authenticator_duo_stage.py new file mode 100644 index 000000000..93f4ab815 --- /dev/null +++ b/authentik_client/models/authenticator_duo_stage.py @@ -0,0 +1,137 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorDuoStage(BaseModel): + """ + AuthenticatorDuoStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + client_id: StrictStr + api_hostname: StrictStr + admin_integration_key: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "configure_flow", "friendly_name", "client_id", "api_hostname", "admin_integration_key"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorDuoStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorDuoStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "client_id": obj.get("client_id"), + "api_hostname": obj.get("api_hostname"), + "admin_integration_key": obj.get("admin_integration_key") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_duo_stage_device_import_response.py b/authentik_client/models/authenticator_duo_stage_device_import_response.py new file mode 100644 index 000000000..9cd53bb0b --- /dev/null +++ b/authentik_client/models/authenticator_duo_stage_device_import_response.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorDuoStageDeviceImportResponse(BaseModel): + """ + AuthenticatorDuoStageDeviceImportResponse + """ # noqa: E501 + count: StrictInt + error: StrictStr + __properties: ClassVar[List[str]] = ["count", "error"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorDuoStageDeviceImportResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "count", + "error", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorDuoStageDeviceImportResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "count": obj.get("count"), + "error": obj.get("error") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_duo_stage_manual_device_import_request.py b/authentik_client/models/authenticator_duo_stage_manual_device_import_request.py new file mode 100644 index 000000000..b448edc2c --- /dev/null +++ b/authentik_client/models/authenticator_duo_stage_manual_device_import_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorDuoStageManualDeviceImportRequest(BaseModel): + """ + AuthenticatorDuoStageManualDeviceImportRequest + """ # noqa: E501 + duo_user_id: Annotated[str, Field(min_length=1, strict=True)] + username: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["duo_user_id", "username"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorDuoStageManualDeviceImportRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorDuoStageManualDeviceImportRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "duo_user_id": obj.get("duo_user_id"), + "username": obj.get("username") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_duo_stage_request.py b/authentik_client/models/authenticator_duo_stage_request.py new file mode 100644 index 000000000..64623f5ab --- /dev/null +++ b/authentik_client/models/authenticator_duo_stage_request.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorDuoStageRequest(BaseModel): + """ + AuthenticatorDuoStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + client_id: Annotated[str, Field(min_length=1, strict=True)] + client_secret: Annotated[str, Field(min_length=1, strict=True)] + api_hostname: Annotated[str, Field(min_length=1, strict=True)] + admin_integration_key: Optional[StrictStr] = None + admin_secret_key: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "client_id", "client_secret", "api_hostname", "admin_integration_key", "admin_secret_key"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorDuoStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorDuoStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "client_id": obj.get("client_id"), + "client_secret": obj.get("client_secret"), + "api_hostname": obj.get("api_hostname"), + "admin_integration_key": obj.get("admin_integration_key"), + "admin_secret_key": obj.get("admin_secret_key") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_email_challenge.py b/authentik_client/models/authenticator_email_challenge.py new file mode 100644 index 000000000..ccd331fc0 --- /dev/null +++ b/authentik_client/models/authenticator_email_challenge.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorEmailChallenge(BaseModel): + """ + Authenticator Email Setup challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-authenticator-email' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + email: Optional[StrictStr] = None + email_required: Optional[StrictBool] = True + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "email", "email_required"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorEmailChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + # set to None if email (nullable) is None + # and model_fields_set contains the field + if self.email is None and "email" in self.model_fields_set: + _dict['email'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorEmailChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-email', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "email": obj.get("email"), + "email_required": obj.get("email_required") if obj.get("email_required") is not None else True + }) + return _obj + + diff --git a/authentik_client/models/authenticator_email_challenge_response_request.py b/authentik_client/models/authenticator_email_challenge_response_request.py new file mode 100644 index 000000000..d485ccd1b --- /dev/null +++ b/authentik_client/models/authenticator_email_challenge_response_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorEmailChallengeResponseRequest(BaseModel): + """ + Authenticator Email Challenge response, device is set by get_response_instance + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-authenticator-email' + code: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + email: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["component", "code", "email"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorEmailChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorEmailChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-email', + "code": obj.get("code"), + "email": obj.get("email") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_email_stage.py b/authentik_client/models/authenticator_email_stage.py new file mode 100644 index 000000000..ef2f55931 --- /dev/null +++ b/authentik_client/models/authenticator_email_stage.py @@ -0,0 +1,154 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorEmailStage(BaseModel): + """ + AuthenticatorEmailStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + use_global_settings: Optional[StrictBool] = Field(default=None, description="When enabled, global Email connection settings will be used and connection settings below will be ignored.") + host: Optional[StrictStr] = None + port: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + username: Optional[StrictStr] = None + use_tls: Optional[StrictBool] = None + use_ssl: Optional[StrictBool] = None + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + from_address: Optional[Annotated[str, Field(strict=True, max_length=254)]] = None + subject: Optional[StrictStr] = None + token_expiry: Optional[StrictStr] = Field(default=None, description="Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).") + template: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "configure_flow", "friendly_name", "use_global_settings", "host", "port", "username", "use_tls", "use_ssl", "timeout", "from_address", "subject", "token_expiry", "template"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorEmailStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorEmailStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "use_global_settings": obj.get("use_global_settings"), + "host": obj.get("host"), + "port": obj.get("port"), + "username": obj.get("username"), + "use_tls": obj.get("use_tls"), + "use_ssl": obj.get("use_ssl"), + "timeout": obj.get("timeout"), + "from_address": obj.get("from_address"), + "subject": obj.get("subject"), + "token_expiry": obj.get("token_expiry"), + "template": obj.get("template") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_email_stage_request.py b/authentik_client/models/authenticator_email_stage_request.py new file mode 100644 index 000000000..4c5aa1ccb --- /dev/null +++ b/authentik_client/models/authenticator_email_stage_request.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorEmailStageRequest(BaseModel): + """ + AuthenticatorEmailStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + use_global_settings: Optional[StrictBool] = Field(default=None, description="When enabled, global Email connection settings will be used and connection settings below will be ignored.") + host: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + port: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + username: Optional[StrictStr] = None + password: Optional[StrictStr] = None + use_tls: Optional[StrictBool] = None + use_ssl: Optional[StrictBool] = None + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + from_address: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=254)]] = None + subject: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + token_expiry: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).") + template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "use_global_settings", "host", "port", "username", "password", "use_tls", "use_ssl", "timeout", "from_address", "subject", "token_expiry", "template"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorEmailStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorEmailStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "use_global_settings": obj.get("use_global_settings"), + "host": obj.get("host"), + "port": obj.get("port"), + "username": obj.get("username"), + "password": obj.get("password"), + "use_tls": obj.get("use_tls"), + "use_ssl": obj.get("use_ssl"), + "timeout": obj.get("timeout"), + "from_address": obj.get("from_address"), + "subject": obj.get("subject"), + "token_expiry": obj.get("token_expiry"), + "template": obj.get("template") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_endpoint_gdtc_stage.py b/authentik_client/models/authenticator_endpoint_gdtc_stage.py new file mode 100644 index 000000000..f0a036105 --- /dev/null +++ b/authentik_client/models/authenticator_endpoint_gdtc_stage.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorEndpointGDTCStage(BaseModel): + """ + AuthenticatorEndpointGDTCStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + credentials: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "configure_flow", "friendly_name", "credentials"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorEndpointGDTCStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorEndpointGDTCStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "credentials": obj.get("credentials") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_endpoint_gdtc_stage_request.py b/authentik_client/models/authenticator_endpoint_gdtc_stage_request.py new file mode 100644 index 000000000..e97972c05 --- /dev/null +++ b/authentik_client/models/authenticator_endpoint_gdtc_stage_request.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorEndpointGDTCStageRequest(BaseModel): + """ + AuthenticatorEndpointGDTCStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + credentials: Dict[str, Any] + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "credentials"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorEndpointGDTCStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorEndpointGDTCStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "credentials": obj.get("credentials") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_sms_challenge.py b/authentik_client/models/authenticator_sms_challenge.py new file mode 100644 index 000000000..dd513a3d8 --- /dev/null +++ b/authentik_client/models/authenticator_sms_challenge.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorSMSChallenge(BaseModel): + """ + SMS Setup challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-authenticator-sms' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + phone_number_required: Optional[StrictBool] = True + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "phone_number_required"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorSMSChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorSMSChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-sms', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "phone_number_required": obj.get("phone_number_required") if obj.get("phone_number_required") is not None else True + }) + return _obj + + diff --git a/authentik_client/models/authenticator_sms_challenge_response_request.py b/authentik_client/models/authenticator_sms_challenge_response_request.py new file mode 100644 index 000000000..be57fcecb --- /dev/null +++ b/authentik_client/models/authenticator_sms_challenge_response_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorSMSChallengeResponseRequest(BaseModel): + """ + SMS Challenge response, device is set by get_response_instance + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-authenticator-sms' + code: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + phone_number: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["component", "code", "phone_number"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorSMSChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorSMSChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-sms', + "code": obj.get("code"), + "phone_number": obj.get("phone_number") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_sms_stage.py b/authentik_client/models/authenticator_sms_stage.py new file mode 100644 index 000000000..2bb347959 --- /dev/null +++ b/authentik_client/models/authenticator_sms_stage.py @@ -0,0 +1,150 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.auth_type_enum import AuthTypeEnum +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.provider_enum import ProviderEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorSMSStage(BaseModel): + """ + AuthenticatorSMSStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + provider: ProviderEnum + from_number: StrictStr + account_sid: StrictStr + auth_type: Optional[AuthTypeEnum] = None + verify_only: Optional[StrictBool] = Field(default=None, description="When enabled, the Phone number is only used during enrollment to verify the users authenticity. Only a hash of the phone number is saved to ensure it is not reused in the future.") + mapping: Optional[UUID] = Field(default=None, description="Optionally modify the payload being sent to custom providers.") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "configure_flow", "friendly_name", "provider", "from_number", "account_sid", "auth_type", "verify_only", "mapping"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorSMSStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + # set to None if mapping (nullable) is None + # and model_fields_set contains the field + if self.mapping is None and "mapping" in self.model_fields_set: + _dict['mapping'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorSMSStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "provider": obj.get("provider"), + "from_number": obj.get("from_number"), + "account_sid": obj.get("account_sid"), + "auth_type": obj.get("auth_type"), + "verify_only": obj.get("verify_only"), + "mapping": obj.get("mapping") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_sms_stage_request.py b/authentik_client/models/authenticator_sms_stage_request.py new file mode 100644 index 000000000..6c9230b2e --- /dev/null +++ b/authentik_client/models/authenticator_sms_stage_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.auth_type_enum import AuthTypeEnum +from authentik_client.models.provider_enum import ProviderEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorSMSStageRequest(BaseModel): + """ + AuthenticatorSMSStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + provider: ProviderEnum + from_number: Annotated[str, Field(min_length=1, strict=True)] + account_sid: Annotated[str, Field(min_length=1, strict=True)] + auth: Annotated[str, Field(min_length=1, strict=True)] + auth_password: Optional[StrictStr] = None + auth_type: Optional[AuthTypeEnum] = None + verify_only: Optional[StrictBool] = Field(default=None, description="When enabled, the Phone number is only used during enrollment to verify the users authenticity. Only a hash of the phone number is saved to ensure it is not reused in the future.") + mapping: Optional[UUID] = Field(default=None, description="Optionally modify the payload being sent to custom providers.") + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "provider", "from_number", "account_sid", "auth", "auth_password", "auth_type", "verify_only", "mapping"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorSMSStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + # set to None if mapping (nullable) is None + # and model_fields_set contains the field + if self.mapping is None and "mapping" in self.model_fields_set: + _dict['mapping'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorSMSStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "provider": obj.get("provider"), + "from_number": obj.get("from_number"), + "account_sid": obj.get("account_sid"), + "auth": obj.get("auth"), + "auth_password": obj.get("auth_password"), + "auth_type": obj.get("auth_type"), + "verify_only": obj.get("verify_only"), + "mapping": obj.get("mapping") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_static_challenge.py b/authentik_client/models/authenticator_static_challenge.py new file mode 100644 index 000000000..c05737d2a --- /dev/null +++ b/authentik_client/models/authenticator_static_challenge.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorStaticChallenge(BaseModel): + """ + Static authenticator challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-authenticator-static' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + codes: List[StrictStr] + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "codes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorStaticChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorStaticChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-static', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "codes": obj.get("codes") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_static_challenge_response_request.py b/authentik_client/models/authenticator_static_challenge_response_request.py new file mode 100644 index 000000000..54afb2180 --- /dev/null +++ b/authentik_client/models/authenticator_static_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorStaticChallengeResponseRequest(BaseModel): + """ + Pseudo class for static response + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-authenticator-static' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorStaticChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorStaticChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-static' + }) + return _obj + + diff --git a/authentik_client/models/authenticator_static_stage.py b/authentik_client/models/authenticator_static_stage.py new file mode 100644 index 000000000..a3bb890c9 --- /dev/null +++ b/authentik_client/models/authenticator_static_stage.py @@ -0,0 +1,136 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorStaticStage(BaseModel): + """ + AuthenticatorStaticStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + token_count: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + token_length: Optional[Annotated[int, Field(le=100, strict=True, ge=0)]] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "configure_flow", "friendly_name", "token_count", "token_length"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorStaticStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorStaticStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "token_count": obj.get("token_count"), + "token_length": obj.get("token_length") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_static_stage_request.py b/authentik_client/models/authenticator_static_stage_request.py new file mode 100644 index 000000000..077925ec8 --- /dev/null +++ b/authentik_client/models/authenticator_static_stage_request.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorStaticStageRequest(BaseModel): + """ + AuthenticatorStaticStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + token_count: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + token_length: Optional[Annotated[int, Field(le=100, strict=True, ge=0)]] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "token_count", "token_length"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorStaticStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorStaticStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "token_count": obj.get("token_count"), + "token_length": obj.get("token_length") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_totp_challenge.py b/authentik_client/models/authenticator_totp_challenge.py new file mode 100644 index 000000000..5d1ed3fde --- /dev/null +++ b/authentik_client/models/authenticator_totp_challenge.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorTOTPChallenge(BaseModel): + """ + TOTP Setup challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-authenticator-totp' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + config_url: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "config_url"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorTOTPChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorTOTPChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-totp', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "config_url": obj.get("config_url") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_totp_challenge_response_request.py b/authentik_client/models/authenticator_totp_challenge_response_request.py new file mode 100644 index 000000000..51b3fb6e1 --- /dev/null +++ b/authentik_client/models/authenticator_totp_challenge_response_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorTOTPChallengeResponseRequest(BaseModel): + """ + TOTP Challenge response, device is set by get_response_instance + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-authenticator-totp' + code: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["component", "code"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorTOTPChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorTOTPChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-totp', + "code": obj.get("code") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_totp_stage.py b/authentik_client/models/authenticator_totp_stage.py new file mode 100644 index 000000000..05d483bda --- /dev/null +++ b/authentik_client/models/authenticator_totp_stage.py @@ -0,0 +1,134 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.digits_enum import DigitsEnum +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorTOTPStage(BaseModel): + """ + AuthenticatorTOTPStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + digits: DigitsEnum + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "configure_flow", "friendly_name", "digits"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorTOTPStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorTOTPStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "digits": obj.get("digits") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_totp_stage_request.py b/authentik_client/models/authenticator_totp_stage_request.py new file mode 100644 index 000000000..dae30ac04 --- /dev/null +++ b/authentik_client/models/authenticator_totp_stage_request.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.digits_enum import DigitsEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorTOTPStageRequest(BaseModel): + """ + AuthenticatorTOTPStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + digits: DigitsEnum + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "digits"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorTOTPStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorTOTPStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "digits": obj.get("digits") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_validate_stage.py b/authentik_client/models/authenticator_validate_stage.py new file mode 100644 index 000000000..1f4bb5fbb --- /dev/null +++ b/authentik_client/models/authenticator_validate_stage.py @@ -0,0 +1,160 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional, Union +from uuid import UUID +from authentik_client.models.device_classes_enum import DeviceClassesEnum +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.not_configured_action_enum import NotConfiguredActionEnum +from authentik_client.models.user_verification_enum import UserVerificationEnum +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType +from authentik_client.models.web_authn_hint_enum import WebAuthnHintEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorValidateStage(BaseModel): + """ + AuthenticatorValidateStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + not_configured_action: Optional[NotConfiguredActionEnum] = None + device_classes: Optional[List[DeviceClassesEnum]] = Field(default=None, description="Device classes which can be used to authenticate") + configuration_stages: Optional[List[UUID]] = Field(default=None, description="Stages used to configure Authenticator when user doesn't have any compatible devices. After this configuration Stage passes, the user is not prompted again.") + last_auth_threshold: Optional[StrictStr] = Field(default=None, description="If any of the user's device has been used within this threshold, this stage will be skipped") + webauthn_user_verification: Optional[UserVerificationEnum] = Field(default=None, description="Enforce user verification for WebAuthn devices.") + webauthn_hints: Optional[List[WebAuthnHintEnum]] = None + webauthn_allowed_device_types: Optional[List[UUID]] = None + webauthn_allowed_device_types_obj: List[WebAuthnDeviceType] + email_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + sms_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + totp_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + static_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "not_configured_action", "device_classes", "configuration_stages", "last_auth_threshold", "webauthn_user_verification", "webauthn_hints", "webauthn_allowed_device_types", "webauthn_allowed_device_types_obj", "email_otp_throttling_factor", "sms_otp_throttling_factor", "totp_otp_throttling_factor", "static_otp_throttling_factor"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorValidateStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + "webauthn_allowed_device_types_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in webauthn_allowed_device_types_obj (list) + _items = [] + if self.webauthn_allowed_device_types_obj: + for _item_webauthn_allowed_device_types_obj in self.webauthn_allowed_device_types_obj: + if _item_webauthn_allowed_device_types_obj: + _items.append(_item_webauthn_allowed_device_types_obj.to_dict()) + _dict['webauthn_allowed_device_types_obj'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorValidateStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "not_configured_action": obj.get("not_configured_action"), + "device_classes": obj.get("device_classes"), + "configuration_stages": obj.get("configuration_stages"), + "last_auth_threshold": obj.get("last_auth_threshold"), + "webauthn_user_verification": obj.get("webauthn_user_verification"), + "webauthn_hints": obj.get("webauthn_hints"), + "webauthn_allowed_device_types": obj.get("webauthn_allowed_device_types"), + "webauthn_allowed_device_types_obj": [WebAuthnDeviceType.from_dict(_item) for _item in obj["webauthn_allowed_device_types_obj"]] if obj.get("webauthn_allowed_device_types_obj") is not None else None, + "email_otp_throttling_factor": obj.get("email_otp_throttling_factor"), + "sms_otp_throttling_factor": obj.get("sms_otp_throttling_factor"), + "totp_otp_throttling_factor": obj.get("totp_otp_throttling_factor"), + "static_otp_throttling_factor": obj.get("static_otp_throttling_factor") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_validate_stage_request.py b/authentik_client/models/authenticator_validate_stage_request.py new file mode 100644 index 000000000..59612e8e2 --- /dev/null +++ b/authentik_client/models/authenticator_validate_stage_request.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt +from typing import Any, ClassVar, Dict, List, Optional, Union +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.device_classes_enum import DeviceClassesEnum +from authentik_client.models.not_configured_action_enum import NotConfiguredActionEnum +from authentik_client.models.user_verification_enum import UserVerificationEnum +from authentik_client.models.web_authn_hint_enum import WebAuthnHintEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorValidateStageRequest(BaseModel): + """ + AuthenticatorValidateStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + not_configured_action: Optional[NotConfiguredActionEnum] = None + device_classes: Optional[List[DeviceClassesEnum]] = Field(default=None, description="Device classes which can be used to authenticate") + configuration_stages: Optional[List[UUID]] = Field(default=None, description="Stages used to configure Authenticator when user doesn't have any compatible devices. After this configuration Stage passes, the user is not prompted again.") + last_auth_threshold: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="If any of the user's device has been used within this threshold, this stage will be skipped") + webauthn_user_verification: Optional[UserVerificationEnum] = Field(default=None, description="Enforce user verification for WebAuthn devices.") + webauthn_hints: Optional[List[WebAuthnHintEnum]] = None + webauthn_allowed_device_types: Optional[List[UUID]] = None + email_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + sms_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + totp_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + static_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + __properties: ClassVar[List[str]] = ["name", "not_configured_action", "device_classes", "configuration_stages", "last_auth_threshold", "webauthn_user_verification", "webauthn_hints", "webauthn_allowed_device_types", "email_otp_throttling_factor", "sms_otp_throttling_factor", "totp_otp_throttling_factor", "static_otp_throttling_factor"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorValidateStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorValidateStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "not_configured_action": obj.get("not_configured_action"), + "device_classes": obj.get("device_classes"), + "configuration_stages": obj.get("configuration_stages"), + "last_auth_threshold": obj.get("last_auth_threshold"), + "webauthn_user_verification": obj.get("webauthn_user_verification"), + "webauthn_hints": obj.get("webauthn_hints"), + "webauthn_allowed_device_types": obj.get("webauthn_allowed_device_types"), + "email_otp_throttling_factor": obj.get("email_otp_throttling_factor"), + "sms_otp_throttling_factor": obj.get("sms_otp_throttling_factor"), + "totp_otp_throttling_factor": obj.get("totp_otp_throttling_factor"), + "static_otp_throttling_factor": obj.get("static_otp_throttling_factor") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_validation_challenge.py b/authentik_client/models/authenticator_validation_challenge.py new file mode 100644 index 000000000..b11027fec --- /dev/null +++ b/authentik_client/models/authenticator_validation_challenge.py @@ -0,0 +1,136 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.device_challenge import DeviceChallenge +from authentik_client.models.error_detail import ErrorDetail +from authentik_client.models.selectable_stage import SelectableStage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorValidationChallenge(BaseModel): + """ + Authenticator challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-authenticator-validate' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + device_challenges: List[DeviceChallenge] + configuration_stages: List[SelectableStage] + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "device_challenges", "configuration_stages"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorValidationChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + # override the default output from pydantic by calling `to_dict()` of each item in device_challenges (list) + _items = [] + if self.device_challenges: + for _item_device_challenges in self.device_challenges: + if _item_device_challenges: + _items.append(_item_device_challenges.to_dict()) + _dict['device_challenges'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in configuration_stages (list) + _items = [] + if self.configuration_stages: + for _item_configuration_stages in self.configuration_stages: + if _item_configuration_stages: + _items.append(_item_configuration_stages.to_dict()) + _dict['configuration_stages'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorValidationChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-validate', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "device_challenges": [DeviceChallenge.from_dict(_item) for _item in obj["device_challenges"]] if obj.get("device_challenges") is not None else None, + "configuration_stages": [SelectableStage.from_dict(_item) for _item in obj["configuration_stages"]] if obj.get("configuration_stages") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/authenticator_validation_challenge_response_request.py b/authentik_client/models/authenticator_validation_challenge_response_request.py new file mode 100644 index 000000000..0f5f46ab1 --- /dev/null +++ b/authentik_client/models/authenticator_validation_challenge_response_request.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.device_challenge_request import DeviceChallengeRequest +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorValidationChallengeResponseRequest(BaseModel): + """ + Challenge used for Code-based and WebAuthn authenticators + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-authenticator-validate' + selected_challenge: Optional[DeviceChallengeRequest] = None + selected_stage: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + code: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + webauthn: Optional[Dict[str, Any]] = None + duo: Optional[StrictInt] = None + __properties: ClassVar[List[str]] = ["component", "selected_challenge", "selected_stage", "code", "webauthn", "duo"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorValidationChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of selected_challenge + if self.selected_challenge: + _dict['selected_challenge'] = self.selected_challenge.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorValidationChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-validate', + "selected_challenge": DeviceChallengeRequest.from_dict(obj["selected_challenge"]) if obj.get("selected_challenge") is not None else None, + "selected_stage": obj.get("selected_stage"), + "code": obj.get("code"), + "webauthn": obj.get("webauthn"), + "duo": obj.get("duo") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_web_authn_challenge.py b/authentik_client/models/authenticator_web_authn_challenge.py new file mode 100644 index 000000000..ca734caf2 --- /dev/null +++ b/authentik_client/models/authenticator_web_authn_challenge.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorWebAuthnChallenge(BaseModel): + """ + WebAuthn Challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-authenticator-webauthn' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + registration: Dict[str, Any] + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "registration"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorWebAuthnChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorWebAuthnChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-webauthn', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "registration": obj.get("registration") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_web_authn_challenge_response_request.py b/authentik_client/models/authenticator_web_authn_challenge_response_request.py new file mode 100644 index 000000000..ab1da5c59 --- /dev/null +++ b/authentik_client/models/authenticator_web_authn_challenge_response_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorWebAuthnChallengeResponseRequest(BaseModel): + """ + WebAuthn Challenge response + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-authenticator-webauthn' + response: Dict[str, Any] + __properties: ClassVar[List[str]] = ["component", "response"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorWebAuthnChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorWebAuthnChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-authenticator-webauthn', + "response": obj.get("response") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_web_authn_stage.py b/authentik_client/models/authenticator_web_authn_stage.py new file mode 100644 index 000000000..14cb3efe8 --- /dev/null +++ b/authentik_client/models/authenticator_web_authn_stage.py @@ -0,0 +1,166 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.authenticator_attachment_enum import AuthenticatorAttachmentEnum +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.user_verification_enum import UserVerificationEnum +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType +from authentik_client.models.web_authn_hint_enum import WebAuthnHintEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorWebAuthnStage(BaseModel): + """ + AuthenticatorWebAuthnStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + user_verification: Optional[UserVerificationEnum] = None + authenticator_attachment: Optional[AuthenticatorAttachmentEnum] = None + resident_key_requirement: Optional[UserVerificationEnum] = None + hints: Optional[List[WebAuthnHintEnum]] = None + device_type_restrictions: Optional[List[UUID]] = None + device_type_restrictions_obj: List[WebAuthnDeviceType] + prevent_duplicate_devices: Optional[StrictBool] = Field(default=None, description="When enabled, a given device can only be registered once.") + max_attempts: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "configure_flow", "friendly_name", "user_verification", "authenticator_attachment", "resident_key_requirement", "hints", "device_type_restrictions", "device_type_restrictions_obj", "prevent_duplicate_devices", "max_attempts"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorWebAuthnStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + "device_type_restrictions_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in device_type_restrictions_obj (list) + _items = [] + if self.device_type_restrictions_obj: + for _item_device_type_restrictions_obj in self.device_type_restrictions_obj: + if _item_device_type_restrictions_obj: + _items.append(_item_device_type_restrictions_obj.to_dict()) + _dict['device_type_restrictions_obj'] = _items + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + # set to None if authenticator_attachment (nullable) is None + # and model_fields_set contains the field + if self.authenticator_attachment is None and "authenticator_attachment" in self.model_fields_set: + _dict['authenticator_attachment'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorWebAuthnStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "user_verification": obj.get("user_verification"), + "authenticator_attachment": obj.get("authenticator_attachment"), + "resident_key_requirement": obj.get("resident_key_requirement"), + "hints": obj.get("hints"), + "device_type_restrictions": obj.get("device_type_restrictions"), + "device_type_restrictions_obj": [WebAuthnDeviceType.from_dict(_item) for _item in obj["device_type_restrictions_obj"]] if obj.get("device_type_restrictions_obj") is not None else None, + "prevent_duplicate_devices": obj.get("prevent_duplicate_devices"), + "max_attempts": obj.get("max_attempts") + }) + return _obj + + diff --git a/authentik_client/models/authenticator_web_authn_stage_request.py b/authentik_client/models/authenticator_web_authn_stage_request.py new file mode 100644 index 000000000..4525d988d --- /dev/null +++ b/authentik_client/models/authenticator_web_authn_stage_request.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.authenticator_attachment_enum import AuthenticatorAttachmentEnum +from authentik_client.models.user_verification_enum import UserVerificationEnum +from authentik_client.models.web_authn_hint_enum import WebAuthnHintEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AuthenticatorWebAuthnStageRequest(BaseModel): + """ + AuthenticatorWebAuthnStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + user_verification: Optional[UserVerificationEnum] = None + authenticator_attachment: Optional[AuthenticatorAttachmentEnum] = None + resident_key_requirement: Optional[UserVerificationEnum] = None + hints: Optional[List[WebAuthnHintEnum]] = None + device_type_restrictions: Optional[List[UUID]] = None + prevent_duplicate_devices: Optional[StrictBool] = Field(default=None, description="When enabled, a given device can only be registered once.") + max_attempts: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "user_verification", "authenticator_attachment", "resident_key_requirement", "hints", "device_type_restrictions", "prevent_duplicate_devices", "max_attempts"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AuthenticatorWebAuthnStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + # set to None if authenticator_attachment (nullable) is None + # and model_fields_set contains the field + if self.authenticator_attachment is None and "authenticator_attachment" in self.model_fields_set: + _dict['authenticator_attachment'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AuthenticatorWebAuthnStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "user_verification": obj.get("user_verification"), + "authenticator_attachment": obj.get("authenticator_attachment"), + "resident_key_requirement": obj.get("resident_key_requirement"), + "hints": obj.get("hints"), + "device_type_restrictions": obj.get("device_type_restrictions"), + "prevent_duplicate_devices": obj.get("prevent_duplicate_devices"), + "max_attempts": obj.get("max_attempts") + }) + return _obj + + diff --git a/authentik_client/models/authorization_code_auth_method_enum.py b/authentik_client/models/authorization_code_auth_method_enum.py new file mode 100644 index 000000000..73351e67d --- /dev/null +++ b/authentik_client/models/authorization_code_auth_method_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class AuthorizationCodeAuthMethodEnum(str, Enum): + """ + AuthorizationCodeAuthMethodEnum + """ + + """ + allowed enum values + """ + BASIC_AUTH = 'basic_auth' + POST_BODY = 'post_body' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of AuthorizationCodeAuthMethodEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/auto_submit_challenge_response_request.py b/authentik_client/models/auto_submit_challenge_response_request.py new file mode 100644 index 000000000..72b235963 --- /dev/null +++ b/authentik_client/models/auto_submit_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AutoSubmitChallengeResponseRequest(BaseModel): + """ + Pseudo class for autosubmit response + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-autosubmit' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AutoSubmitChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AutoSubmitChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-autosubmit' + }) + return _obj + + diff --git a/authentik_client/models/autosubmit_challenge.py b/authentik_client/models/autosubmit_challenge.py new file mode 100644 index 000000000..e4e58a272 --- /dev/null +++ b/authentik_client/models/autosubmit_challenge.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class AutosubmitChallenge(BaseModel): + """ + Autosubmit challenge used to send and navigate a POST request + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-autosubmit' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + url: StrictStr + attrs: Dict[str, StrictStr] + title: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "url", "attrs", "title"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of AutosubmitChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of AutosubmitChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-autosubmit', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "url": obj.get("url"), + "attrs": obj.get("attrs"), + "title": obj.get("title") + }) + return _obj + + diff --git a/authentik_client/models/backends_enum.py b/authentik_client/models/backends_enum.py new file mode 100644 index 000000000..dfb074185 --- /dev/null +++ b/authentik_client/models/backends_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class BackendsEnum(str, Enum): + """ + BackendsEnum + """ + + """ + allowed enum values + """ + AUTHENTIK_DOT_CORE_DOT_AUTH_DOT_INBUILT_BACKEND = 'authentik.core.auth.InbuiltBackend' + AUTHENTIK_DOT_CORE_DOT_AUTH_DOT_TOKEN_BACKEND = 'authentik.core.auth.TokenBackend' + AUTHENTIK_DOT_SOURCES_DOT_LDAP_DOT_AUTH_DOT_LDAP_BACKEND = 'authentik.sources.ldap.auth.LDAPBackend' + AUTHENTIK_DOT_SOURCES_DOT_KERBEROS_DOT_AUTH_DOT_KERBEROS_BACKEND = 'authentik.sources.kerberos.auth.KerberosBackend' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of BackendsEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/binding_type_enum.py b/authentik_client/models/binding_type_enum.py new file mode 100644 index 000000000..1d036e3c4 --- /dev/null +++ b/authentik_client/models/binding_type_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class BindingTypeEnum(str, Enum): + """ + BindingTypeEnum + """ + + """ + allowed enum values + """ + REDIRECT = 'REDIRECT' + POST = 'POST' + POST_AUTO = 'POST_AUTO' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of BindingTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/blueprint_file.py b/authentik_client/models/blueprint_file.py new file mode 100644 index 000000000..bbb418f12 --- /dev/null +++ b/authentik_client/models/blueprint_file.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from authentik_client.models.metadata import Metadata +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class BlueprintFile(BaseModel): + """ + BlueprintFile + """ # noqa: E501 + path: StrictStr + last_m: datetime + hash: StrictStr + meta: Metadata + __properties: ClassVar[List[str]] = ["path", "last_m", "hash", "meta"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of BlueprintFile from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "meta", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of meta + if self.meta: + _dict['meta'] = self.meta.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of BlueprintFile from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "path": obj.get("path"), + "last_m": obj.get("last_m"), + "hash": obj.get("hash"), + "meta": Metadata.from_dict(obj["meta"]) if obj.get("meta") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/blueprint_import_result.py b/authentik_client/models/blueprint_import_result.py new file mode 100644 index 000000000..33124f47d --- /dev/null +++ b/authentik_client/models/blueprint_import_result.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool +from typing import Any, ClassVar, Dict, List +from authentik_client.models.log_event import LogEvent +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class BlueprintImportResult(BaseModel): + """ + Logs of an attempted blueprint import + """ # noqa: E501 + logs: List[LogEvent] + success: StrictBool + __properties: ClassVar[List[str]] = ["logs", "success"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of BlueprintImportResult from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "logs", + "success", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in logs (list) + _items = [] + if self.logs: + for _item_logs in self.logs: + if _item_logs: + _items.append(_item_logs.to_dict()) + _dict['logs'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of BlueprintImportResult from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "logs": [LogEvent.from_dict(_item) for _item in obj["logs"]] if obj.get("logs") is not None else None, + "success": obj.get("success") + }) + return _obj + + diff --git a/authentik_client/models/blueprint_instance.py b/authentik_client/models/blueprint_instance.py new file mode 100644 index 000000000..27ca85110 --- /dev/null +++ b/authentik_client/models/blueprint_instance.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.blueprint_instance_status_enum import BlueprintInstanceStatusEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class BlueprintInstance(BaseModel): + """ + Info about a single blueprint instance file + """ # noqa: E501 + pk: UUID + name: StrictStr + path: Optional[StrictStr] = '' + context: Optional[Dict[str, Any]] = None + last_applied: datetime + last_applied_hash: StrictStr + status: BlueprintInstanceStatusEnum + enabled: Optional[StrictBool] = None + managed_models: List[StrictStr] + metadata: Dict[str, Any] + content: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["pk", "name", "path", "context", "last_applied", "last_applied_hash", "status", "enabled", "managed_models", "metadata", "content"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of BlueprintInstance from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "last_applied", + "last_applied_hash", + "status", + "managed_models", + "metadata", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of BlueprintInstance from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "path": obj.get("path") if obj.get("path") is not None else '', + "context": obj.get("context"), + "last_applied": obj.get("last_applied"), + "last_applied_hash": obj.get("last_applied_hash"), + "status": obj.get("status"), + "enabled": obj.get("enabled"), + "managed_models": obj.get("managed_models"), + "metadata": obj.get("metadata"), + "content": obj.get("content") + }) + return _obj + + diff --git a/authentik_client/models/blueprint_instance_request.py b/authentik_client/models/blueprint_instance_request.py new file mode 100644 index 000000000..2e15624d8 --- /dev/null +++ b/authentik_client/models/blueprint_instance_request.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class BlueprintInstanceRequest(BaseModel): + """ + Info about a single blueprint instance file + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + path: Optional[StrictStr] = '' + context: Optional[Dict[str, Any]] = None + enabled: Optional[StrictBool] = None + content: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "path", "context", "enabled", "content"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of BlueprintInstanceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of BlueprintInstanceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "path": obj.get("path") if obj.get("path") is not None else '', + "context": obj.get("context"), + "enabled": obj.get("enabled"), + "content": obj.get("content") + }) + return _obj + + diff --git a/authentik_client/models/blueprint_instance_status_enum.py b/authentik_client/models/blueprint_instance_status_enum.py new file mode 100644 index 000000000..f6cec0839 --- /dev/null +++ b/authentik_client/models/blueprint_instance_status_enum.py @@ -0,0 +1,41 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class BlueprintInstanceStatusEnum(str, Enum): + """ + BlueprintInstanceStatusEnum + """ + + """ + allowed enum values + """ + SUCCESSFUL = 'successful' + WARNING = 'warning' + ERROR = 'error' + ORPHANED = 'orphaned' + UNKNOWN = 'unknown' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of BlueprintInstanceStatusEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/brand.py b/authentik_client/models/brand.py new file mode 100644 index 000000000..7feee25cf --- /dev/null +++ b/authentik_client/models/brand.py @@ -0,0 +1,173 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Brand(BaseModel): + """ + Brand Serializer + """ # noqa: E501 + brand_uuid: UUID + domain: StrictStr = Field(description="Domain that activates this brand. Can be a superset, i.e. `a.b` for `aa.b` and `ba.b`") + default: Optional[StrictBool] = None + branding_title: Optional[StrictStr] = None + branding_logo: Optional[StrictStr] = None + branding_favicon: Optional[StrictStr] = None + branding_custom_css: Optional[StrictStr] = None + branding_default_flow_background: Optional[StrictStr] = None + flow_authentication: Optional[UUID] = None + flow_invalidation: Optional[UUID] = None + flow_recovery: Optional[UUID] = None + flow_unenrollment: Optional[UUID] = None + flow_user_settings: Optional[UUID] = None + flow_device_code: Optional[UUID] = None + flow_lockdown: Optional[UUID] = None + default_application: Optional[UUID] = Field(default=None, description="When set, external users will be redirected to this application after authenticating.") + web_certificate: Optional[UUID] = Field(default=None, description="Web Certificate used by the authentik Core webserver.") + client_certificates: Optional[List[UUID]] = Field(default=None, description="Certificates used for client authentication.") + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["brand_uuid", "domain", "default", "branding_title", "branding_logo", "branding_favicon", "branding_custom_css", "branding_default_flow_background", "flow_authentication", "flow_invalidation", "flow_recovery", "flow_unenrollment", "flow_user_settings", "flow_device_code", "flow_lockdown", "default_application", "web_certificate", "client_certificates", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Brand from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "brand_uuid", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if flow_authentication (nullable) is None + # and model_fields_set contains the field + if self.flow_authentication is None and "flow_authentication" in self.model_fields_set: + _dict['flow_authentication'] = None + + # set to None if flow_invalidation (nullable) is None + # and model_fields_set contains the field + if self.flow_invalidation is None and "flow_invalidation" in self.model_fields_set: + _dict['flow_invalidation'] = None + + # set to None if flow_recovery (nullable) is None + # and model_fields_set contains the field + if self.flow_recovery is None and "flow_recovery" in self.model_fields_set: + _dict['flow_recovery'] = None + + # set to None if flow_unenrollment (nullable) is None + # and model_fields_set contains the field + if self.flow_unenrollment is None and "flow_unenrollment" in self.model_fields_set: + _dict['flow_unenrollment'] = None + + # set to None if flow_user_settings (nullable) is None + # and model_fields_set contains the field + if self.flow_user_settings is None and "flow_user_settings" in self.model_fields_set: + _dict['flow_user_settings'] = None + + # set to None if flow_device_code (nullable) is None + # and model_fields_set contains the field + if self.flow_device_code is None and "flow_device_code" in self.model_fields_set: + _dict['flow_device_code'] = None + + # set to None if flow_lockdown (nullable) is None + # and model_fields_set contains the field + if self.flow_lockdown is None and "flow_lockdown" in self.model_fields_set: + _dict['flow_lockdown'] = None + + # set to None if default_application (nullable) is None + # and model_fields_set contains the field + if self.default_application is None and "default_application" in self.model_fields_set: + _dict['default_application'] = None + + # set to None if web_certificate (nullable) is None + # and model_fields_set contains the field + if self.web_certificate is None and "web_certificate" in self.model_fields_set: + _dict['web_certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Brand from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "brand_uuid": obj.get("brand_uuid"), + "domain": obj.get("domain"), + "default": obj.get("default"), + "branding_title": obj.get("branding_title"), + "branding_logo": obj.get("branding_logo"), + "branding_favicon": obj.get("branding_favicon"), + "branding_custom_css": obj.get("branding_custom_css"), + "branding_default_flow_background": obj.get("branding_default_flow_background"), + "flow_authentication": obj.get("flow_authentication"), + "flow_invalidation": obj.get("flow_invalidation"), + "flow_recovery": obj.get("flow_recovery"), + "flow_unenrollment": obj.get("flow_unenrollment"), + "flow_user_settings": obj.get("flow_user_settings"), + "flow_device_code": obj.get("flow_device_code"), + "flow_lockdown": obj.get("flow_lockdown"), + "default_application": obj.get("default_application"), + "web_certificate": obj.get("web_certificate"), + "client_certificates": obj.get("client_certificates"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/brand_request.py b/authentik_client/models/brand_request.py new file mode 100644 index 000000000..c047d7e9a --- /dev/null +++ b/authentik_client/models/brand_request.py @@ -0,0 +1,170 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class BrandRequest(BaseModel): + """ + Brand Serializer + """ # noqa: E501 + domain: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Domain that activates this brand. Can be a superset, i.e. `a.b` for `aa.b` and `ba.b`") + default: Optional[StrictBool] = None + branding_title: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + branding_logo: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + branding_favicon: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + branding_custom_css: Optional[StrictStr] = None + branding_default_flow_background: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + flow_authentication: Optional[UUID] = None + flow_invalidation: Optional[UUID] = None + flow_recovery: Optional[UUID] = None + flow_unenrollment: Optional[UUID] = None + flow_user_settings: Optional[UUID] = None + flow_device_code: Optional[UUID] = None + flow_lockdown: Optional[UUID] = None + default_application: Optional[UUID] = Field(default=None, description="When set, external users will be redirected to this application after authenticating.") + web_certificate: Optional[UUID] = Field(default=None, description="Web Certificate used by the authentik Core webserver.") + client_certificates: Optional[List[UUID]] = Field(default=None, description="Certificates used for client authentication.") + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["domain", "default", "branding_title", "branding_logo", "branding_favicon", "branding_custom_css", "branding_default_flow_background", "flow_authentication", "flow_invalidation", "flow_recovery", "flow_unenrollment", "flow_user_settings", "flow_device_code", "flow_lockdown", "default_application", "web_certificate", "client_certificates", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of BrandRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if flow_authentication (nullable) is None + # and model_fields_set contains the field + if self.flow_authentication is None and "flow_authentication" in self.model_fields_set: + _dict['flow_authentication'] = None + + # set to None if flow_invalidation (nullable) is None + # and model_fields_set contains the field + if self.flow_invalidation is None and "flow_invalidation" in self.model_fields_set: + _dict['flow_invalidation'] = None + + # set to None if flow_recovery (nullable) is None + # and model_fields_set contains the field + if self.flow_recovery is None and "flow_recovery" in self.model_fields_set: + _dict['flow_recovery'] = None + + # set to None if flow_unenrollment (nullable) is None + # and model_fields_set contains the field + if self.flow_unenrollment is None and "flow_unenrollment" in self.model_fields_set: + _dict['flow_unenrollment'] = None + + # set to None if flow_user_settings (nullable) is None + # and model_fields_set contains the field + if self.flow_user_settings is None and "flow_user_settings" in self.model_fields_set: + _dict['flow_user_settings'] = None + + # set to None if flow_device_code (nullable) is None + # and model_fields_set contains the field + if self.flow_device_code is None and "flow_device_code" in self.model_fields_set: + _dict['flow_device_code'] = None + + # set to None if flow_lockdown (nullable) is None + # and model_fields_set contains the field + if self.flow_lockdown is None and "flow_lockdown" in self.model_fields_set: + _dict['flow_lockdown'] = None + + # set to None if default_application (nullable) is None + # and model_fields_set contains the field + if self.default_application is None and "default_application" in self.model_fields_set: + _dict['default_application'] = None + + # set to None if web_certificate (nullable) is None + # and model_fields_set contains the field + if self.web_certificate is None and "web_certificate" in self.model_fields_set: + _dict['web_certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of BrandRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "domain": obj.get("domain"), + "default": obj.get("default"), + "branding_title": obj.get("branding_title"), + "branding_logo": obj.get("branding_logo"), + "branding_favicon": obj.get("branding_favicon"), + "branding_custom_css": obj.get("branding_custom_css"), + "branding_default_flow_background": obj.get("branding_default_flow_background"), + "flow_authentication": obj.get("flow_authentication"), + "flow_invalidation": obj.get("flow_invalidation"), + "flow_recovery": obj.get("flow_recovery"), + "flow_unenrollment": obj.get("flow_unenrollment"), + "flow_user_settings": obj.get("flow_user_settings"), + "flow_device_code": obj.get("flow_device_code"), + "flow_lockdown": obj.get("flow_lockdown"), + "default_application": obj.get("default_application"), + "web_certificate": obj.get("web_certificate"), + "client_certificates": obj.get("client_certificates"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/bulk_delete_session_response.py b/authentik_client/models/bulk_delete_session_response.py new file mode 100644 index 000000000..1bc9e50d6 --- /dev/null +++ b/authentik_client/models/bulk_delete_session_response.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class BulkDeleteSessionResponse(BaseModel): + """ + BulkDeleteSessionResponse + """ # noqa: E501 + deleted: StrictInt + __properties: ClassVar[List[str]] = ["deleted"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of BulkDeleteSessionResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of BulkDeleteSessionResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "deleted": obj.get("deleted") + }) + return _obj + + diff --git a/authentik_client/models/cache.py b/authentik_client/models/cache.py new file mode 100644 index 000000000..f4467d1b8 --- /dev/null +++ b/authentik_client/models/cache.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Cache(BaseModel): + """ + Generic cache stats for an object + """ # noqa: E501 + count: StrictInt + __properties: ClassVar[List[str]] = ["count"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Cache from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "count", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Cache from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "count": obj.get("count") + }) + return _obj + + diff --git a/authentik_client/models/capabilities_enum.py b/authentik_client/models/capabilities_enum.py new file mode 100644 index 000000000..3c4cc1e74 --- /dev/null +++ b/authentik_client/models/capabilities_enum.py @@ -0,0 +1,43 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class CapabilitiesEnum(str, Enum): + """ + CapabilitiesEnum + """ + + """ + allowed enum values + """ + CAN_SAVE_MEDIA = 'can_save_media' + CAN_SAVE_REPORTS = 'can_save_reports' + CAN_GEO_IP = 'can_geo_ip' + CAN_ASN = 'can_asn' + CAN_IMPERSONATE = 'can_impersonate' + CAN_DEBUG = 'can_debug' + IS_ENTERPRISE = 'is_enterprise' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of CapabilitiesEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/captcha_challenge.py b/authentik_client/models/captcha_challenge.py new file mode 100644 index 000000000..88cab7c81 --- /dev/null +++ b/authentik_client/models/captcha_challenge.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CaptchaChallenge(BaseModel): + """ + Site public key + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-captcha' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + site_key: StrictStr + js_url: StrictStr + interactive: StrictBool + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "site_key", "js_url", "interactive"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CaptchaChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CaptchaChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-captcha', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "site_key": obj.get("site_key"), + "js_url": obj.get("js_url"), + "interactive": obj.get("interactive") + }) + return _obj + + diff --git a/authentik_client/models/captcha_challenge_response_request.py b/authentik_client/models/captcha_challenge_response_request.py new file mode 100644 index 000000000..d2dca7bbf --- /dev/null +++ b/authentik_client/models/captcha_challenge_response_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CaptchaChallengeResponseRequest(BaseModel): + """ + Validate captcha token + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-captcha' + token: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["component", "token"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CaptchaChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CaptchaChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-captcha', + "token": obj.get("token") + }) + return _obj + + diff --git a/authentik_client/models/captcha_stage.py b/authentik_client/models/captcha_stage.py new file mode 100644 index 000000000..447fca61a --- /dev/null +++ b/authentik_client/models/captcha_stage.py @@ -0,0 +1,136 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional, Union +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CaptchaStage(BaseModel): + """ + CaptchaStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + public_key: StrictStr = Field(description="Public key, acquired your captcha Provider.") + js_url: Optional[StrictStr] = None + api_url: Optional[StrictStr] = None + interactive: Optional[StrictBool] = None + score_min_threshold: Optional[Union[StrictFloat, StrictInt]] = None + score_max_threshold: Optional[Union[StrictFloat, StrictInt]] = None + error_on_invalid_score: Optional[StrictBool] = Field(default=None, description="When enabled and the received captcha score is outside of the given threshold, the stage will show an error message. When not enabled, the flow will continue, but the data from the captcha will be available in the context for policy decisions") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "public_key", "js_url", "api_url", "interactive", "score_min_threshold", "score_max_threshold", "error_on_invalid_score"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CaptchaStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CaptchaStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "public_key": obj.get("public_key"), + "js_url": obj.get("js_url"), + "api_url": obj.get("api_url"), + "interactive": obj.get("interactive"), + "score_min_threshold": obj.get("score_min_threshold"), + "score_max_threshold": obj.get("score_max_threshold"), + "error_on_invalid_score": obj.get("error_on_invalid_score") + }) + return _obj + + diff --git a/authentik_client/models/captcha_stage_request.py b/authentik_client/models/captcha_stage_request.py new file mode 100644 index 000000000..d5f9efbe3 --- /dev/null +++ b/authentik_client/models/captcha_stage_request.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt +from typing import Any, ClassVar, Dict, List, Optional, Union +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CaptchaStageRequest(BaseModel): + """ + CaptchaStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + public_key: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Public key, acquired your captcha Provider.") + private_key: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Private key, acquired your captcha Provider.") + js_url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + api_url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + interactive: Optional[StrictBool] = None + score_min_threshold: Optional[Union[StrictFloat, StrictInt]] = None + score_max_threshold: Optional[Union[StrictFloat, StrictInt]] = None + error_on_invalid_score: Optional[StrictBool] = Field(default=None, description="When enabled and the received captcha score is outside of the given threshold, the stage will show an error message. When not enabled, the flow will continue, but the data from the captcha will be available in the context for policy decisions") + __properties: ClassVar[List[str]] = ["name", "public_key", "private_key", "js_url", "api_url", "interactive", "score_min_threshold", "score_max_threshold", "error_on_invalid_score"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CaptchaStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CaptchaStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "public_key": obj.get("public_key"), + "private_key": obj.get("private_key"), + "js_url": obj.get("js_url"), + "api_url": obj.get("api_url"), + "interactive": obj.get("interactive"), + "score_min_threshold": obj.get("score_min_threshold"), + "score_max_threshold": obj.get("score_max_threshold"), + "error_on_invalid_score": obj.get("error_on_invalid_score") + }) + return _obj + + diff --git a/authentik_client/models/cert_attribute_enum.py b/authentik_client/models/cert_attribute_enum.py new file mode 100644 index 000000000..35af19fb8 --- /dev/null +++ b/authentik_client/models/cert_attribute_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class CertAttributeEnum(str, Enum): + """ + CertAttributeEnum + """ + + """ + allowed enum values + """ + SUBJECT = 'subject' + COMMON_NAME = 'common_name' + EMAIL = 'email' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of CertAttributeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/certificate_data.py b/authentik_client/models/certificate_data.py new file mode 100644 index 000000000..413613bf5 --- /dev/null +++ b/authentik_client/models/certificate_data.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CertificateData(BaseModel): + """ + Get CertificateKeyPair's data + """ # noqa: E501 + data: StrictStr + __properties: ClassVar[List[str]] = ["data"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CertificateData from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "data", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CertificateData from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "data": obj.get("data") + }) + return _obj + + diff --git a/authentik_client/models/certificate_generation_request.py b/authentik_client/models/certificate_generation_request.py new file mode 100644 index 000000000..0570aa157 --- /dev/null +++ b/authentik_client/models/certificate_generation_request.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.alg_enum import AlgEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CertificateGenerationRequest(BaseModel): + """ + Certificate generation parameters + """ # noqa: E501 + common_name: Annotated[str, Field(min_length=1, strict=True)] + subject_alt_name: Optional[StrictStr] = None + validity_days: StrictInt + alg: Optional[AlgEnum] = None + __properties: ClassVar[List[str]] = ["common_name", "subject_alt_name", "validity_days", "alg"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CertificateGenerationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CertificateGenerationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "common_name": obj.get("common_name"), + "subject_alt_name": obj.get("subject_alt_name"), + "validity_days": obj.get("validity_days"), + "alg": obj.get("alg") + }) + return _obj + + diff --git a/authentik_client/models/certificate_key_pair.py b/authentik_client/models/certificate_key_pair.py new file mode 100644 index 000000000..a115f5184 --- /dev/null +++ b/authentik_client/models/certificate_key_pair.py @@ -0,0 +1,162 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.certificate_key_pair_key_type_enum import CertificateKeyPairKeyTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CertificateKeyPair(BaseModel): + """ + CertificateKeyPair Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + fingerprint_sha256: Optional[StrictStr] = Field(description="SHA256 fingerprint of the certificate") + fingerprint_sha1: Optional[StrictStr] = Field(description="SHA1 fingerprint of the certificate") + cert_expiry: Optional[datetime] = Field(description="Certificate expiry date") + cert_subject: Optional[StrictStr] = Field(description="Certificate subject as RFC4514 string") + private_key_available: StrictBool = Field(description="Show if this keypair has a private key configured or not") + key_type: Optional[CertificateKeyPairKeyTypeEnum] = Field(description="Key algorithm type detected from the certificate's public key") + certificate_download_url: StrictStr = Field(description="Get URL to download certificate") + private_key_download_url: StrictStr = Field(description="Get URL to download private key") + managed: Optional[StrictStr] = Field(description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + __properties: ClassVar[List[str]] = ["pk", "name", "fingerprint_sha256", "fingerprint_sha1", "cert_expiry", "cert_subject", "private_key_available", "key_type", "certificate_download_url", "private_key_download_url", "managed"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CertificateKeyPair from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "fingerprint_sha256", + "fingerprint_sha1", + "cert_expiry", + "cert_subject", + "private_key_available", + "key_type", + "certificate_download_url", + "private_key_download_url", + "managed", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if fingerprint_sha256 (nullable) is None + # and model_fields_set contains the field + if self.fingerprint_sha256 is None and "fingerprint_sha256" in self.model_fields_set: + _dict['fingerprint_sha256'] = None + + # set to None if fingerprint_sha1 (nullable) is None + # and model_fields_set contains the field + if self.fingerprint_sha1 is None and "fingerprint_sha1" in self.model_fields_set: + _dict['fingerprint_sha1'] = None + + # set to None if cert_expiry (nullable) is None + # and model_fields_set contains the field + if self.cert_expiry is None and "cert_expiry" in self.model_fields_set: + _dict['cert_expiry'] = None + + # set to None if cert_subject (nullable) is None + # and model_fields_set contains the field + if self.cert_subject is None and "cert_subject" in self.model_fields_set: + _dict['cert_subject'] = None + + # set to None if key_type (nullable) is None + # and model_fields_set contains the field + if self.key_type is None and "key_type" in self.model_fields_set: + _dict['key_type'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CertificateKeyPair from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "fingerprint_sha256": obj.get("fingerprint_sha256"), + "fingerprint_sha1": obj.get("fingerprint_sha1"), + "cert_expiry": obj.get("cert_expiry"), + "cert_subject": obj.get("cert_subject"), + "private_key_available": obj.get("private_key_available"), + "key_type": obj.get("key_type"), + "certificate_download_url": obj.get("certificate_download_url"), + "private_key_download_url": obj.get("private_key_download_url"), + "managed": obj.get("managed") + }) + return _obj + + diff --git a/authentik_client/models/certificate_key_pair_key_type_enum.py b/authentik_client/models/certificate_key_pair_key_type_enum.py new file mode 100644 index 000000000..8a4880006 --- /dev/null +++ b/authentik_client/models/certificate_key_pair_key_type_enum.py @@ -0,0 +1,41 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class CertificateKeyPairKeyTypeEnum(str, Enum): + """ + CertificateKeyPairKeyTypeEnum + """ + + """ + allowed enum values + """ + RSA = 'rsa' + EC = 'ec' + DSA = 'dsa' + ED25519 = 'ed25519' + ED448 = 'ed448' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of CertificateKeyPairKeyTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/certificate_key_pair_request.py b/authentik_client/models/certificate_key_pair_request.py new file mode 100644 index 000000000..7a09673da --- /dev/null +++ b/authentik_client/models/certificate_key_pair_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CertificateKeyPairRequest(BaseModel): + """ + CertificateKeyPair Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + certificate_data: Annotated[str, Field(min_length=1, strict=True)] = Field(description="PEM-encoded Certificate data") + key_data: Optional[StrictStr] = Field(default=None, description="Optional Private Key. If this is set, you can use this keypair for encryption.") + __properties: ClassVar[List[str]] = ["name", "certificate_data", "key_data"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CertificateKeyPairRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CertificateKeyPairRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "certificate_data": obj.get("certificate_data"), + "key_data": obj.get("key_data") + }) + return _obj + + diff --git a/authentik_client/models/challenge_types.py b/authentik_client/models/challenge_types.py new file mode 100644 index 000000000..d913644a3 --- /dev/null +++ b/authentik_client/models/challenge_types.py @@ -0,0 +1,533 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +import pprint +from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator +from typing import Any, List, Optional +from authentik_client.models.access_denied_challenge import AccessDeniedChallenge +from authentik_client.models.apple_login_challenge import AppleLoginChallenge +from authentik_client.models.authenticator_duo_challenge import AuthenticatorDuoChallenge +from authentik_client.models.authenticator_email_challenge import AuthenticatorEmailChallenge +from authentik_client.models.authenticator_sms_challenge import AuthenticatorSMSChallenge +from authentik_client.models.authenticator_static_challenge import AuthenticatorStaticChallenge +from authentik_client.models.authenticator_totp_challenge import AuthenticatorTOTPChallenge +from authentik_client.models.authenticator_validation_challenge import AuthenticatorValidationChallenge +from authentik_client.models.authenticator_web_authn_challenge import AuthenticatorWebAuthnChallenge +from authentik_client.models.autosubmit_challenge import AutosubmitChallenge +from authentik_client.models.captcha_challenge import CaptchaChallenge +from authentik_client.models.consent_challenge import ConsentChallenge +from authentik_client.models.dummy_challenge import DummyChallenge +from authentik_client.models.email_challenge import EmailChallenge +from authentik_client.models.endpoint_agent_challenge import EndpointAgentChallenge +from authentik_client.models.flow_error_challenge import FlowErrorChallenge +from authentik_client.models.frame_challenge import FrameChallenge +from authentik_client.models.identification_challenge import IdentificationChallenge +from authentik_client.models.iframe_logout_challenge import IframeLogoutChallenge +from authentik_client.models.native_logout_challenge import NativeLogoutChallenge +from authentik_client.models.o_auth_device_code_challenge import OAuthDeviceCodeChallenge +from authentik_client.models.o_auth_device_code_finish_challenge import OAuthDeviceCodeFinishChallenge +from authentik_client.models.password_challenge import PasswordChallenge +from authentik_client.models.plex_authentication_challenge import PlexAuthenticationChallenge +from authentik_client.models.prompt_challenge import PromptChallenge +from authentik_client.models.redirect_challenge import RedirectChallenge +from authentik_client.models.session_end_challenge import SessionEndChallenge +from authentik_client.models.shell_challenge import ShellChallenge +from authentik_client.models.telegram_login_challenge import TelegramLoginChallenge +from authentik_client.models.user_login_challenge import UserLoginChallenge +from pydantic import StrictStr, Field +from typing import Union, List, Set, Optional, Dict +from typing_extensions import Literal, Self + +CHALLENGETYPES_ONE_OF_SCHEMAS = ["AccessDeniedChallenge", "AppleLoginChallenge", "AuthenticatorDuoChallenge", "AuthenticatorEmailChallenge", "AuthenticatorSMSChallenge", "AuthenticatorStaticChallenge", "AuthenticatorTOTPChallenge", "AuthenticatorValidationChallenge", "AuthenticatorWebAuthnChallenge", "AutosubmitChallenge", "CaptchaChallenge", "ConsentChallenge", "DummyChallenge", "EmailChallenge", "EndpointAgentChallenge", "FlowErrorChallenge", "FrameChallenge", "IdentificationChallenge", "IframeLogoutChallenge", "NativeLogoutChallenge", "OAuthDeviceCodeChallenge", "OAuthDeviceCodeFinishChallenge", "PasswordChallenge", "PlexAuthenticationChallenge", "PromptChallenge", "RedirectChallenge", "SessionEndChallenge", "ShellChallenge", "TelegramLoginChallenge", "UserLoginChallenge"] + +class ChallengeTypes(BaseModel): + """ + ChallengeTypes + """ + # data type: AccessDeniedChallenge + oneof_schema_1_validator: Optional[AccessDeniedChallenge] = None + # data type: AppleLoginChallenge + oneof_schema_2_validator: Optional[AppleLoginChallenge] = None + # data type: AuthenticatorDuoChallenge + oneof_schema_3_validator: Optional[AuthenticatorDuoChallenge] = None + # data type: AuthenticatorEmailChallenge + oneof_schema_4_validator: Optional[AuthenticatorEmailChallenge] = None + # data type: AuthenticatorSMSChallenge + oneof_schema_5_validator: Optional[AuthenticatorSMSChallenge] = None + # data type: AuthenticatorStaticChallenge + oneof_schema_6_validator: Optional[AuthenticatorStaticChallenge] = None + # data type: AuthenticatorTOTPChallenge + oneof_schema_7_validator: Optional[AuthenticatorTOTPChallenge] = None + # data type: AuthenticatorValidationChallenge + oneof_schema_8_validator: Optional[AuthenticatorValidationChallenge] = None + # data type: AuthenticatorWebAuthnChallenge + oneof_schema_9_validator: Optional[AuthenticatorWebAuthnChallenge] = None + # data type: AutosubmitChallenge + oneof_schema_10_validator: Optional[AutosubmitChallenge] = None + # data type: CaptchaChallenge + oneof_schema_11_validator: Optional[CaptchaChallenge] = None + # data type: ConsentChallenge + oneof_schema_12_validator: Optional[ConsentChallenge] = None + # data type: DummyChallenge + oneof_schema_13_validator: Optional[DummyChallenge] = None + # data type: EmailChallenge + oneof_schema_14_validator: Optional[EmailChallenge] = None + # data type: EndpointAgentChallenge + oneof_schema_15_validator: Optional[EndpointAgentChallenge] = None + # data type: FlowErrorChallenge + oneof_schema_16_validator: Optional[FlowErrorChallenge] = None + # data type: FrameChallenge + oneof_schema_17_validator: Optional[FrameChallenge] = None + # data type: IdentificationChallenge + oneof_schema_18_validator: Optional[IdentificationChallenge] = None + # data type: IframeLogoutChallenge + oneof_schema_19_validator: Optional[IframeLogoutChallenge] = None + # data type: NativeLogoutChallenge + oneof_schema_20_validator: Optional[NativeLogoutChallenge] = None + # data type: OAuthDeviceCodeChallenge + oneof_schema_21_validator: Optional[OAuthDeviceCodeChallenge] = None + # data type: OAuthDeviceCodeFinishChallenge + oneof_schema_22_validator: Optional[OAuthDeviceCodeFinishChallenge] = None + # data type: PasswordChallenge + oneof_schema_23_validator: Optional[PasswordChallenge] = None + # data type: PlexAuthenticationChallenge + oneof_schema_24_validator: Optional[PlexAuthenticationChallenge] = None + # data type: PromptChallenge + oneof_schema_25_validator: Optional[PromptChallenge] = None + # data type: RedirectChallenge + oneof_schema_26_validator: Optional[RedirectChallenge] = None + # data type: SessionEndChallenge + oneof_schema_27_validator: Optional[SessionEndChallenge] = None + # data type: ShellChallenge + oneof_schema_28_validator: Optional[ShellChallenge] = None + # data type: TelegramLoginChallenge + oneof_schema_29_validator: Optional[TelegramLoginChallenge] = None + # data type: UserLoginChallenge + oneof_schema_30_validator: Optional[UserLoginChallenge] = None + actual_instance: Optional[Union[AccessDeniedChallenge, AppleLoginChallenge, AuthenticatorDuoChallenge, AuthenticatorEmailChallenge, AuthenticatorSMSChallenge, AuthenticatorStaticChallenge, AuthenticatorTOTPChallenge, AuthenticatorValidationChallenge, AuthenticatorWebAuthnChallenge, AutosubmitChallenge, CaptchaChallenge, ConsentChallenge, DummyChallenge, EmailChallenge, EndpointAgentChallenge, FlowErrorChallenge, FrameChallenge, IdentificationChallenge, IframeLogoutChallenge, NativeLogoutChallenge, OAuthDeviceCodeChallenge, OAuthDeviceCodeFinishChallenge, PasswordChallenge, PlexAuthenticationChallenge, PromptChallenge, RedirectChallenge, SessionEndChallenge, ShellChallenge, TelegramLoginChallenge, UserLoginChallenge]] = None + one_of_schemas: Set[str] = { "AccessDeniedChallenge", "AppleLoginChallenge", "AuthenticatorDuoChallenge", "AuthenticatorEmailChallenge", "AuthenticatorSMSChallenge", "AuthenticatorStaticChallenge", "AuthenticatorTOTPChallenge", "AuthenticatorValidationChallenge", "AuthenticatorWebAuthnChallenge", "AutosubmitChallenge", "CaptchaChallenge", "ConsentChallenge", "DummyChallenge", "EmailChallenge", "EndpointAgentChallenge", "FlowErrorChallenge", "FrameChallenge", "IdentificationChallenge", "IframeLogoutChallenge", "NativeLogoutChallenge", "OAuthDeviceCodeChallenge", "OAuthDeviceCodeFinishChallenge", "PasswordChallenge", "PlexAuthenticationChallenge", "PromptChallenge", "RedirectChallenge", "SessionEndChallenge", "ShellChallenge", "TelegramLoginChallenge", "UserLoginChallenge" } + + model_config = ConfigDict( + validate_assignment=True, + protected_namespaces=(), + ) + + + discriminator_value_class_map: Dict[str, str] = { + } + + def __init__(self, *args, **kwargs) -> None: + if args: + if len(args) > 1: + raise ValueError("If a position argument is used, only 1 is allowed to set `actual_instance`") + if kwargs: + raise ValueError("If a position argument is used, keyword arguments cannot be used.") + super().__init__(actual_instance=args[0]) + else: + super().__init__(**kwargs) + + @field_validator('actual_instance') + def actual_instance_must_validate_oneof(cls, v): + instance = ChallengeTypes.model_construct() + error_messages = [] + match = 0 + # validate data type: AccessDeniedChallenge + if not isinstance(v, AccessDeniedChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AccessDeniedChallenge`") + else: + match += 1 + # validate data type: AppleLoginChallenge + if not isinstance(v, AppleLoginChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AppleLoginChallenge`") + else: + match += 1 + # validate data type: AuthenticatorDuoChallenge + if not isinstance(v, AuthenticatorDuoChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorDuoChallenge`") + else: + match += 1 + # validate data type: AuthenticatorEmailChallenge + if not isinstance(v, AuthenticatorEmailChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorEmailChallenge`") + else: + match += 1 + # validate data type: AuthenticatorSMSChallenge + if not isinstance(v, AuthenticatorSMSChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorSMSChallenge`") + else: + match += 1 + # validate data type: AuthenticatorStaticChallenge + if not isinstance(v, AuthenticatorStaticChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorStaticChallenge`") + else: + match += 1 + # validate data type: AuthenticatorTOTPChallenge + if not isinstance(v, AuthenticatorTOTPChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorTOTPChallenge`") + else: + match += 1 + # validate data type: AuthenticatorValidationChallenge + if not isinstance(v, AuthenticatorValidationChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorValidationChallenge`") + else: + match += 1 + # validate data type: AuthenticatorWebAuthnChallenge + if not isinstance(v, AuthenticatorWebAuthnChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorWebAuthnChallenge`") + else: + match += 1 + # validate data type: AutosubmitChallenge + if not isinstance(v, AutosubmitChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AutosubmitChallenge`") + else: + match += 1 + # validate data type: CaptchaChallenge + if not isinstance(v, CaptchaChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `CaptchaChallenge`") + else: + match += 1 + # validate data type: ConsentChallenge + if not isinstance(v, ConsentChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `ConsentChallenge`") + else: + match += 1 + # validate data type: DummyChallenge + if not isinstance(v, DummyChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `DummyChallenge`") + else: + match += 1 + # validate data type: EmailChallenge + if not isinstance(v, EmailChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `EmailChallenge`") + else: + match += 1 + # validate data type: EndpointAgentChallenge + if not isinstance(v, EndpointAgentChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `EndpointAgentChallenge`") + else: + match += 1 + # validate data type: FlowErrorChallenge + if not isinstance(v, FlowErrorChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `FlowErrorChallenge`") + else: + match += 1 + # validate data type: FrameChallenge + if not isinstance(v, FrameChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `FrameChallenge`") + else: + match += 1 + # validate data type: IdentificationChallenge + if not isinstance(v, IdentificationChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `IdentificationChallenge`") + else: + match += 1 + # validate data type: IframeLogoutChallenge + if not isinstance(v, IframeLogoutChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `IframeLogoutChallenge`") + else: + match += 1 + # validate data type: NativeLogoutChallenge + if not isinstance(v, NativeLogoutChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `NativeLogoutChallenge`") + else: + match += 1 + # validate data type: OAuthDeviceCodeChallenge + if not isinstance(v, OAuthDeviceCodeChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `OAuthDeviceCodeChallenge`") + else: + match += 1 + # validate data type: OAuthDeviceCodeFinishChallenge + if not isinstance(v, OAuthDeviceCodeFinishChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `OAuthDeviceCodeFinishChallenge`") + else: + match += 1 + # validate data type: PasswordChallenge + if not isinstance(v, PasswordChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `PasswordChallenge`") + else: + match += 1 + # validate data type: PlexAuthenticationChallenge + if not isinstance(v, PlexAuthenticationChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `PlexAuthenticationChallenge`") + else: + match += 1 + # validate data type: PromptChallenge + if not isinstance(v, PromptChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `PromptChallenge`") + else: + match += 1 + # validate data type: RedirectChallenge + if not isinstance(v, RedirectChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `RedirectChallenge`") + else: + match += 1 + # validate data type: SessionEndChallenge + if not isinstance(v, SessionEndChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `SessionEndChallenge`") + else: + match += 1 + # validate data type: ShellChallenge + if not isinstance(v, ShellChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `ShellChallenge`") + else: + match += 1 + # validate data type: TelegramLoginChallenge + if not isinstance(v, TelegramLoginChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `TelegramLoginChallenge`") + else: + match += 1 + # validate data type: UserLoginChallenge + if not isinstance(v, UserLoginChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `UserLoginChallenge`") + else: + match += 1 + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when setting `actual_instance` in ChallengeTypes with oneOf schemas: AccessDeniedChallenge, AppleLoginChallenge, AuthenticatorDuoChallenge, AuthenticatorEmailChallenge, AuthenticatorSMSChallenge, AuthenticatorStaticChallenge, AuthenticatorTOTPChallenge, AuthenticatorValidationChallenge, AuthenticatorWebAuthnChallenge, AutosubmitChallenge, CaptchaChallenge, ConsentChallenge, DummyChallenge, EmailChallenge, EndpointAgentChallenge, FlowErrorChallenge, FrameChallenge, IdentificationChallenge, IframeLogoutChallenge, NativeLogoutChallenge, OAuthDeviceCodeChallenge, OAuthDeviceCodeFinishChallenge, PasswordChallenge, PlexAuthenticationChallenge, PromptChallenge, RedirectChallenge, SessionEndChallenge, ShellChallenge, TelegramLoginChallenge, UserLoginChallenge. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when setting `actual_instance` in ChallengeTypes with oneOf schemas: AccessDeniedChallenge, AppleLoginChallenge, AuthenticatorDuoChallenge, AuthenticatorEmailChallenge, AuthenticatorSMSChallenge, AuthenticatorStaticChallenge, AuthenticatorTOTPChallenge, AuthenticatorValidationChallenge, AuthenticatorWebAuthnChallenge, AutosubmitChallenge, CaptchaChallenge, ConsentChallenge, DummyChallenge, EmailChallenge, EndpointAgentChallenge, FlowErrorChallenge, FrameChallenge, IdentificationChallenge, IframeLogoutChallenge, NativeLogoutChallenge, OAuthDeviceCodeChallenge, OAuthDeviceCodeFinishChallenge, PasswordChallenge, PlexAuthenticationChallenge, PromptChallenge, RedirectChallenge, SessionEndChallenge, ShellChallenge, TelegramLoginChallenge, UserLoginChallenge. Details: " + ", ".join(error_messages)) + else: + return v + + @classmethod + def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self: + return cls.from_json(json.dumps(obj)) + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Returns the object represented by the json string""" + instance = cls.model_construct() + error_messages = [] + match = 0 + + # deserialize data into AccessDeniedChallenge + try: + instance.actual_instance = AccessDeniedChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AppleLoginChallenge + try: + instance.actual_instance = AppleLoginChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorDuoChallenge + try: + instance.actual_instance = AuthenticatorDuoChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorEmailChallenge + try: + instance.actual_instance = AuthenticatorEmailChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorSMSChallenge + try: + instance.actual_instance = AuthenticatorSMSChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorStaticChallenge + try: + instance.actual_instance = AuthenticatorStaticChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorTOTPChallenge + try: + instance.actual_instance = AuthenticatorTOTPChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorValidationChallenge + try: + instance.actual_instance = AuthenticatorValidationChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorWebAuthnChallenge + try: + instance.actual_instance = AuthenticatorWebAuthnChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AutosubmitChallenge + try: + instance.actual_instance = AutosubmitChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into CaptchaChallenge + try: + instance.actual_instance = CaptchaChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into ConsentChallenge + try: + instance.actual_instance = ConsentChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into DummyChallenge + try: + instance.actual_instance = DummyChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into EmailChallenge + try: + instance.actual_instance = EmailChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into EndpointAgentChallenge + try: + instance.actual_instance = EndpointAgentChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into FlowErrorChallenge + try: + instance.actual_instance = FlowErrorChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into FrameChallenge + try: + instance.actual_instance = FrameChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into IdentificationChallenge + try: + instance.actual_instance = IdentificationChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into IframeLogoutChallenge + try: + instance.actual_instance = IframeLogoutChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into NativeLogoutChallenge + try: + instance.actual_instance = NativeLogoutChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into OAuthDeviceCodeChallenge + try: + instance.actual_instance = OAuthDeviceCodeChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into OAuthDeviceCodeFinishChallenge + try: + instance.actual_instance = OAuthDeviceCodeFinishChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into PasswordChallenge + try: + instance.actual_instance = PasswordChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into PlexAuthenticationChallenge + try: + instance.actual_instance = PlexAuthenticationChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into PromptChallenge + try: + instance.actual_instance = PromptChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into RedirectChallenge + try: + instance.actual_instance = RedirectChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into SessionEndChallenge + try: + instance.actual_instance = SessionEndChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into ShellChallenge + try: + instance.actual_instance = ShellChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into TelegramLoginChallenge + try: + instance.actual_instance = TelegramLoginChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into UserLoginChallenge + try: + instance.actual_instance = UserLoginChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when deserializing the JSON string into ChallengeTypes with oneOf schemas: AccessDeniedChallenge, AppleLoginChallenge, AuthenticatorDuoChallenge, AuthenticatorEmailChallenge, AuthenticatorSMSChallenge, AuthenticatorStaticChallenge, AuthenticatorTOTPChallenge, AuthenticatorValidationChallenge, AuthenticatorWebAuthnChallenge, AutosubmitChallenge, CaptchaChallenge, ConsentChallenge, DummyChallenge, EmailChallenge, EndpointAgentChallenge, FlowErrorChallenge, FrameChallenge, IdentificationChallenge, IframeLogoutChallenge, NativeLogoutChallenge, OAuthDeviceCodeChallenge, OAuthDeviceCodeFinishChallenge, PasswordChallenge, PlexAuthenticationChallenge, PromptChallenge, RedirectChallenge, SessionEndChallenge, ShellChallenge, TelegramLoginChallenge, UserLoginChallenge. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when deserializing the JSON string into ChallengeTypes with oneOf schemas: AccessDeniedChallenge, AppleLoginChallenge, AuthenticatorDuoChallenge, AuthenticatorEmailChallenge, AuthenticatorSMSChallenge, AuthenticatorStaticChallenge, AuthenticatorTOTPChallenge, AuthenticatorValidationChallenge, AuthenticatorWebAuthnChallenge, AutosubmitChallenge, CaptchaChallenge, ConsentChallenge, DummyChallenge, EmailChallenge, EndpointAgentChallenge, FlowErrorChallenge, FrameChallenge, IdentificationChallenge, IframeLogoutChallenge, NativeLogoutChallenge, OAuthDeviceCodeChallenge, OAuthDeviceCodeFinishChallenge, PasswordChallenge, PlexAuthenticationChallenge, PromptChallenge, RedirectChallenge, SessionEndChallenge, ShellChallenge, TelegramLoginChallenge, UserLoginChallenge. Details: " + ", ".join(error_messages)) + else: + return instance + + def to_json(self) -> str: + """Returns the JSON representation of the actual instance""" + if self.actual_instance is None: + return "null" + + if hasattr(self.actual_instance, "to_json") and callable(self.actual_instance.to_json): + return self.actual_instance.to_json() + else: + return json.dumps(self.actual_instance) + + def to_dict(self) -> Optional[Union[Dict[str, Any], AccessDeniedChallenge, AppleLoginChallenge, AuthenticatorDuoChallenge, AuthenticatorEmailChallenge, AuthenticatorSMSChallenge, AuthenticatorStaticChallenge, AuthenticatorTOTPChallenge, AuthenticatorValidationChallenge, AuthenticatorWebAuthnChallenge, AutosubmitChallenge, CaptchaChallenge, ConsentChallenge, DummyChallenge, EmailChallenge, EndpointAgentChallenge, FlowErrorChallenge, FrameChallenge, IdentificationChallenge, IframeLogoutChallenge, NativeLogoutChallenge, OAuthDeviceCodeChallenge, OAuthDeviceCodeFinishChallenge, PasswordChallenge, PlexAuthenticationChallenge, PromptChallenge, RedirectChallenge, SessionEndChallenge, ShellChallenge, TelegramLoginChallenge, UserLoginChallenge]]: + """Returns the dict representation of the actual instance""" + if self.actual_instance is None: + return None + + if hasattr(self.actual_instance, "to_dict") and callable(self.actual_instance.to_dict): + return self.actual_instance.to_dict() + else: + # primitive type + return self.actual_instance + + def to_str(self) -> str: + """Returns the string representation of the actual instance""" + return pprint.pformat(self.model_dump()) + + diff --git a/authentik_client/models/client_type_enum.py b/authentik_client/models/client_type_enum.py new file mode 100644 index 000000000..c94f2bb3e --- /dev/null +++ b/authentik_client/models/client_type_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ClientTypeEnum(str, Enum): + """ + ClientTypeEnum + """ + + """ + allowed enum values + """ + CONFIDENTIAL = 'confidential' + PUBLIC = 'public' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ClientTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/compatibility_mode_enum.py b/authentik_client/models/compatibility_mode_enum.py new file mode 100644 index 000000000..cb36c23cb --- /dev/null +++ b/authentik_client/models/compatibility_mode_enum.py @@ -0,0 +1,42 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class CompatibilityModeEnum(str, Enum): + """ + CompatibilityModeEnum + """ + + """ + allowed enum values + """ + DEFAULT = 'default' + AWS = 'aws' + SLACK = 'slack' + SFDC = 'sfdc' + WEBEX = 'webex' + VCENTER = 'vcenter' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of CompatibilityModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/config.py b/authentik_client/models/config.py new file mode 100644 index 000000000..36c972c99 --- /dev/null +++ b/authentik_client/models/config.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from authentik_client.models.capabilities_enum import CapabilitiesEnum +from authentik_client.models.error_reporting_config import ErrorReportingConfig +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Config(BaseModel): + """ + Serialize authentik Config into DRF Object + """ # noqa: E501 + error_reporting: ErrorReportingConfig + capabilities: List[CapabilitiesEnum] + cache_timeout: StrictInt + cache_timeout_flows: StrictInt + cache_timeout_policies: StrictInt + __properties: ClassVar[List[str]] = ["error_reporting", "capabilities", "cache_timeout", "cache_timeout_flows", "cache_timeout_policies"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Config from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of error_reporting + if self.error_reporting: + _dict['error_reporting'] = self.error_reporting.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Config from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "error_reporting": ErrorReportingConfig.from_dict(obj["error_reporting"]) if obj.get("error_reporting") is not None else None, + "capabilities": obj.get("capabilities"), + "cache_timeout": obj.get("cache_timeout"), + "cache_timeout_flows": obj.get("cache_timeout_flows"), + "cache_timeout_policies": obj.get("cache_timeout_policies") + }) + return _obj + + diff --git a/authentik_client/models/connection_token.py b/authentik_client/models/connection_token.py new file mode 100644 index 000000000..cc6475220 --- /dev/null +++ b/authentik_client/models/connection_token.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.endpoint import Endpoint +from authentik_client.models.partial_user import PartialUser +from authentik_client.models.rac_provider import RACProvider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ConnectionToken(BaseModel): + """ + ConnectionToken Serializer + """ # noqa: E501 + pk: Optional[UUID] = None + provider: StrictInt + provider_obj: RACProvider + endpoint: UUID + endpoint_obj: Endpoint + user: PartialUser + __properties: ClassVar[List[str]] = ["pk", "provider", "provider_obj", "endpoint", "endpoint_obj", "user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ConnectionToken from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "provider_obj", + "endpoint_obj", + "user", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of provider_obj + if self.provider_obj: + _dict['provider_obj'] = self.provider_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of endpoint_obj + if self.endpoint_obj: + _dict['endpoint_obj'] = self.endpoint_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ConnectionToken from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "provider": obj.get("provider"), + "provider_obj": RACProvider.from_dict(obj["provider_obj"]) if obj.get("provider_obj") is not None else None, + "endpoint": obj.get("endpoint"), + "endpoint_obj": Endpoint.from_dict(obj["endpoint_obj"]) if obj.get("endpoint_obj") is not None else None, + "user": PartialUser.from_dict(obj["user"]) if obj.get("user") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/connection_token_request.py b/authentik_client/models/connection_token_request.py new file mode 100644 index 000000000..172a78c5d --- /dev/null +++ b/authentik_client/models/connection_token_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ConnectionTokenRequest(BaseModel): + """ + ConnectionToken Serializer + """ # noqa: E501 + pk: Optional[UUID] = None + provider: StrictInt + endpoint: UUID + __properties: ClassVar[List[str]] = ["pk", "provider", "endpoint"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ConnectionTokenRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ConnectionTokenRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "provider": obj.get("provider"), + "endpoint": obj.get("endpoint") + }) + return _obj + + diff --git a/authentik_client/models/connector.py b/authentik_client/models/connector.py new file mode 100644 index 000000000..b3e68f6a2 --- /dev/null +++ b/authentik_client/models/connector.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Connector(BaseModel): + """ + Connector + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: StrictStr + enabled: Optional[StrictBool] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Connector from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Connector from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/consent_challenge.py b/authentik_client/models/consent_challenge.py new file mode 100644 index 000000000..222a2811f --- /dev/null +++ b/authentik_client/models/consent_challenge.py @@ -0,0 +1,139 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.consent_permission import ConsentPermission +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ConsentChallenge(BaseModel): + """ + Challenge info for consent screens + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-consent' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + header_text: Optional[StrictStr] = None + permissions: List[ConsentPermission] + additional_permissions: List[ConsentPermission] + token: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "header_text", "permissions", "additional_permissions", "token"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ConsentChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + # override the default output from pydantic by calling `to_dict()` of each item in permissions (list) + _items = [] + if self.permissions: + for _item_permissions in self.permissions: + if _item_permissions: + _items.append(_item_permissions.to_dict()) + _dict['permissions'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in additional_permissions (list) + _items = [] + if self.additional_permissions: + for _item_additional_permissions in self.additional_permissions: + if _item_additional_permissions: + _items.append(_item_additional_permissions.to_dict()) + _dict['additional_permissions'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ConsentChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-consent', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "header_text": obj.get("header_text"), + "permissions": [ConsentPermission.from_dict(_item) for _item in obj["permissions"]] if obj.get("permissions") is not None else None, + "additional_permissions": [ConsentPermission.from_dict(_item) for _item in obj["additional_permissions"]] if obj.get("additional_permissions") is not None else None, + "token": obj.get("token") + }) + return _obj + + diff --git a/authentik_client/models/consent_challenge_response_request.py b/authentik_client/models/consent_challenge_response_request.py new file mode 100644 index 000000000..fffd93bae --- /dev/null +++ b/authentik_client/models/consent_challenge_response_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ConsentChallengeResponseRequest(BaseModel): + """ + Consent challenge response, any valid response request is valid + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-consent' + token: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["component", "token"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ConsentChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ConsentChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-consent', + "token": obj.get("token") + }) + return _obj + + diff --git a/authentik_client/models/consent_mode_enum.py b/authentik_client/models/consent_mode_enum.py new file mode 100644 index 000000000..2ace2ba4b --- /dev/null +++ b/authentik_client/models/consent_mode_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ConsentModeEnum(str, Enum): + """ + ConsentModeEnum + """ + + """ + allowed enum values + """ + ALWAYS_REQUIRE = 'always_require' + PERMANENT = 'permanent' + EXPIRING = 'expiring' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ConsentModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/consent_permission.py b/authentik_client/models/consent_permission.py new file mode 100644 index 000000000..ad483bd11 --- /dev/null +++ b/authentik_client/models/consent_permission.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ConsentPermission(BaseModel): + """ + Permission used for consent + """ # noqa: E501 + name: StrictStr + id: StrictStr + __properties: ClassVar[List[str]] = ["name", "id"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ConsentPermission from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ConsentPermission from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "id": obj.get("id") + }) + return _obj + + diff --git a/authentik_client/models/consent_stage.py b/authentik_client/models/consent_stage.py new file mode 100644 index 000000000..2a253f866 --- /dev/null +++ b/authentik_client/models/consent_stage.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.consent_mode_enum import ConsentModeEnum +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ConsentStage(BaseModel): + """ + ConsentStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + mode: Optional[ConsentModeEnum] = None + consent_expire_in: Optional[StrictStr] = Field(default=None, description="Offset after which consent expires. (Format: hours=1;minutes=2;seconds=3).") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "mode", "consent_expire_in"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ConsentStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ConsentStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "mode": obj.get("mode"), + "consent_expire_in": obj.get("consent_expire_in") + }) + return _obj + + diff --git a/authentik_client/models/consent_stage_request.py b/authentik_client/models/consent_stage_request.py new file mode 100644 index 000000000..15816cfa5 --- /dev/null +++ b/authentik_client/models/consent_stage_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.consent_mode_enum import ConsentModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ConsentStageRequest(BaseModel): + """ + ConsentStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + mode: Optional[ConsentModeEnum] = None + consent_expire_in: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Offset after which consent expires. (Format: hours=1;minutes=2;seconds=3).") + __properties: ClassVar[List[str]] = ["name", "mode", "consent_expire_in"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ConsentStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ConsentStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "mode": obj.get("mode"), + "consent_expire_in": obj.get("consent_expire_in") + }) + return _obj + + diff --git a/authentik_client/models/content_type.py b/authentik_client/models/content_type.py new file mode 100644 index 000000000..849a4b900 --- /dev/null +++ b/authentik_client/models/content_type.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ContentType(BaseModel): + """ + ContentType + """ # noqa: E501 + id: StrictInt + app_label: StrictStr + model: StrictStr + verbose_name_plural: StrictStr + __properties: ClassVar[List[str]] = ["id", "app_label", "model", "verbose_name_plural"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ContentType from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "app_label", + "model", + "verbose_name_plural", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ContentType from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "app_label": obj.get("app_label"), + "model": obj.get("model"), + "verbose_name_plural": obj.get("verbose_name_plural") + }) + return _obj + + diff --git a/authentik_client/models/content_type_enum.py b/authentik_client/models/content_type_enum.py new file mode 100644 index 000000000..1fb7966dc --- /dev/null +++ b/authentik_client/models/content_type_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ContentTypeEnum(str, Enum): + """ + ContentTypeEnum + """ + + """ + allowed enum values + """ + AUTHENTIK_CORE_DOT_APPLICATION = 'authentik_core.application' + AUTHENTIK_CORE_DOT_GROUP = 'authentik_core.group' + AUTHENTIK_RBAC_DOT_ROLE = 'authentik_rbac.role' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ContentTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/contextual_flow_info.py b/authentik_client/models/contextual_flow_info.py new file mode 100644 index 000000000..d3cfbbfea --- /dev/null +++ b/authentik_client/models/contextual_flow_info.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info_layout_enum import ContextualFlowInfoLayoutEnum +from authentik_client.models.themed_urls import ThemedUrls +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ContextualFlowInfo(BaseModel): + """ + Contextual flow information for a challenge + """ # noqa: E501 + title: Optional[StrictStr] = None + background: Optional[StrictStr] = None + background_themed_urls: Optional[ThemedUrls] = None + cancel_url: StrictStr + layout: ContextualFlowInfoLayoutEnum + __properties: ClassVar[List[str]] = ["title", "background", "background_themed_urls", "cancel_url", "layout"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ContextualFlowInfo from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of background_themed_urls + if self.background_themed_urls: + _dict['background_themed_urls'] = self.background_themed_urls.to_dict() + # set to None if background_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.background_themed_urls is None and "background_themed_urls" in self.model_fields_set: + _dict['background_themed_urls'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ContextualFlowInfo from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "title": obj.get("title"), + "background": obj.get("background"), + "background_themed_urls": ThemedUrls.from_dict(obj["background_themed_urls"]) if obj.get("background_themed_urls") is not None else None, + "cancel_url": obj.get("cancel_url"), + "layout": obj.get("layout") + }) + return _obj + + diff --git a/authentik_client/models/contextual_flow_info_layout_enum.py b/authentik_client/models/contextual_flow_info_layout_enum.py new file mode 100644 index 000000000..203ece8fe --- /dev/null +++ b/authentik_client/models/contextual_flow_info_layout_enum.py @@ -0,0 +1,43 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ContextualFlowInfoLayoutEnum(str, Enum): + """ + ContextualFlowInfoLayoutEnum + """ + + """ + allowed enum values + """ + STACKED = 'stacked' + CONTENT_LEFT = 'content_left' + CONTENT_RIGHT = 'content_right' + SIDEBAR_LEFT = 'sidebar_left' + SIDEBAR_RIGHT = 'sidebar_right' + SIDEBAR_LEFT_FRAME_BACKGROUND = 'sidebar_left_frame_background' + SIDEBAR_RIGHT_FRAME_BACKGROUND = 'sidebar_right_frame_background' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ContextualFlowInfoLayoutEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/country_code_enum.py b/authentik_client/models/country_code_enum.py new file mode 100644 index 000000000..8c5774e8a --- /dev/null +++ b/authentik_client/models/country_code_enum.py @@ -0,0 +1,285 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class CountryCodeEnum(str, Enum): + """ + CountryCodeEnum + """ + + """ + allowed enum values + """ + AF = 'AF' + AX = 'AX' + AL = 'AL' + DZ = 'DZ' + AS = 'AS' + AD = 'AD' + AO = 'AO' + AI = 'AI' + AQ = 'AQ' + AG = 'AG' + AR = 'AR' + AM = 'AM' + AW = 'AW' + AU = 'AU' + AT = 'AT' + AZ = 'AZ' + BS = 'BS' + BH = 'BH' + BD = 'BD' + BB = 'BB' + BY = 'BY' + BE = 'BE' + BZ = 'BZ' + BJ = 'BJ' + BM = 'BM' + BT = 'BT' + BO = 'BO' + BQ = 'BQ' + BA = 'BA' + BW = 'BW' + BV = 'BV' + BR = 'BR' + IO = 'IO' + BN = 'BN' + BG = 'BG' + BF = 'BF' + BI = 'BI' + CV = 'CV' + KH = 'KH' + CM = 'CM' + CA = 'CA' + KY = 'KY' + CF = 'CF' + TD = 'TD' + CL = 'CL' + CN = 'CN' + CX = 'CX' + CC = 'CC' + CO = 'CO' + KM = 'KM' + CG = 'CG' + CK = 'CK' + CR = 'CR' + CI = 'CI' + HR = 'HR' + CU = 'CU' + CW = 'CW' + CY = 'CY' + CZ = 'CZ' + CD = 'CD' + DK = 'DK' + DJ = 'DJ' + DM = 'DM' + DO = 'DO' + EC = 'EC' + EG = 'EG' + SV = 'SV' + GQ = 'GQ' + ER = 'ER' + EE = 'EE' + SZ = 'SZ' + ET = 'ET' + FK = 'FK' + FO = 'FO' + FJ = 'FJ' + FI = 'FI' + FR = 'FR' + GF = 'GF' + PF = 'PF' + TF = 'TF' + GA = 'GA' + GM = 'GM' + GE = 'GE' + DE = 'DE' + GH = 'GH' + GI = 'GI' + GR = 'GR' + GL = 'GL' + GD = 'GD' + GP = 'GP' + GU = 'GU' + GT = 'GT' + GG = 'GG' + GN = 'GN' + GW = 'GW' + GY = 'GY' + HT = 'HT' + HM = 'HM' + HN = 'HN' + HK = 'HK' + HU = 'HU' + IS = 'IS' + IN = 'IN' + ID = 'ID' + IR = 'IR' + IQ = 'IQ' + IE = 'IE' + IM = 'IM' + IL = 'IL' + IT = 'IT' + JM = 'JM' + JP = 'JP' + JE = 'JE' + JO = 'JO' + KZ = 'KZ' + KE = 'KE' + KI = 'KI' + KW = 'KW' + KG = 'KG' + LA = 'LA' + LV = 'LV' + LB = 'LB' + LS = 'LS' + LR = 'LR' + LY = 'LY' + LI = 'LI' + LT = 'LT' + LU = 'LU' + MO = 'MO' + MG = 'MG' + MW = 'MW' + MY = 'MY' + MV = 'MV' + ML = 'ML' + MT = 'MT' + MH = 'MH' + MQ = 'MQ' + MR = 'MR' + MU = 'MU' + YT = 'YT' + MX = 'MX' + FM = 'FM' + MD = 'MD' + MC = 'MC' + MN = 'MN' + ME = 'ME' + MS = 'MS' + MA = 'MA' + MZ = 'MZ' + MM = 'MM' + NA = 'NA' + NR = 'NR' + NP = 'NP' + NL = 'NL' + NC = 'NC' + NZ = 'NZ' + NI = 'NI' + NE = 'NE' + NG = 'NG' + NU = 'NU' + NF = 'NF' + KP = 'KP' + MK = 'MK' + MP = 'MP' + NO = 'NO' + OM = 'OM' + PK = 'PK' + PW = 'PW' + PS = 'PS' + PA = 'PA' + PG = 'PG' + PY = 'PY' + PE = 'PE' + PH = 'PH' + PN = 'PN' + PL = 'PL' + PT = 'PT' + PR = 'PR' + QA = 'QA' + RE = 'RE' + RO = 'RO' + RU = 'RU' + RW = 'RW' + BL = 'BL' + SH = 'SH' + KN = 'KN' + LC = 'LC' + MF = 'MF' + PM = 'PM' + VC = 'VC' + WS = 'WS' + SM = 'SM' + ST = 'ST' + SA = 'SA' + SN = 'SN' + RS = 'RS' + SC = 'SC' + SL = 'SL' + SG = 'SG' + SX = 'SX' + SK = 'SK' + SI = 'SI' + SB = 'SB' + SO = 'SO' + ZA = 'ZA' + GS = 'GS' + KR = 'KR' + SS = 'SS' + ES = 'ES' + LK = 'LK' + SD = 'SD' + SR = 'SR' + SJ = 'SJ' + SE = 'SE' + CH = 'CH' + SY = 'SY' + TW = 'TW' + TJ = 'TJ' + TZ = 'TZ' + TH = 'TH' + TL = 'TL' + TG = 'TG' + TK = 'TK' + TO = 'TO' + TT = 'TT' + TN = 'TN' + TR = 'TR' + TM = 'TM' + TC = 'TC' + TV = 'TV' + UG = 'UG' + UA = 'UA' + AE = 'AE' + GB = 'GB' + UM = 'UM' + US = 'US' + UY = 'UY' + UZ = 'UZ' + VU = 'VU' + VA = 'VA' + VE = 'VE' + VN = 'VN' + VG = 'VG' + VI = 'VI' + WF = 'WF' + EH = 'EH' + YE = 'YE' + ZM = 'ZM' + ZW = 'ZW' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of CountryCodeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/current_brand.py b/authentik_client/models/current_brand.py new file mode 100644 index 000000000..6a8c62303 --- /dev/null +++ b/authentik_client/models/current_brand.py @@ -0,0 +1,163 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.current_brand_flags import CurrentBrandFlags +from authentik_client.models.footer_link import FooterLink +from authentik_client.models.themed_urls import ThemedUrls +from authentik_client.models.ui_theme_enum import UiThemeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CurrentBrand(BaseModel): + """ + Partial brand information for styling + """ # noqa: E501 + matched_domain: StrictStr + branding_title: StrictStr + branding_logo: StrictStr + branding_logo_themed_urls: Optional[ThemedUrls] + branding_favicon: StrictStr + branding_favicon_themed_urls: Optional[ThemedUrls] + branding_custom_css: StrictStr + ui_footer_links: List[FooterLink] + ui_theme: UiThemeEnum + flow_authentication: Optional[StrictStr] = None + flow_invalidation: Optional[StrictStr] = None + flow_recovery: Optional[StrictStr] = None + flow_unenrollment: Optional[StrictStr] = None + flow_user_settings: Optional[StrictStr] = None + flow_device_code: Optional[StrictStr] = None + flow_lockdown: Optional[StrictStr] = None + default_locale: StrictStr + flags: CurrentBrandFlags + __properties: ClassVar[List[str]] = ["matched_domain", "branding_title", "branding_logo", "branding_logo_themed_urls", "branding_favicon", "branding_favicon_themed_urls", "branding_custom_css", "ui_footer_links", "ui_theme", "flow_authentication", "flow_invalidation", "flow_recovery", "flow_unenrollment", "flow_user_settings", "flow_device_code", "flow_lockdown", "default_locale", "flags"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CurrentBrand from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "branding_logo_themed_urls", + "branding_favicon_themed_urls", + "ui_footer_links", + "ui_theme", + "default_locale", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of branding_logo_themed_urls + if self.branding_logo_themed_urls: + _dict['branding_logo_themed_urls'] = self.branding_logo_themed_urls.to_dict() + # override the default output from pydantic by calling `to_dict()` of branding_favicon_themed_urls + if self.branding_favicon_themed_urls: + _dict['branding_favicon_themed_urls'] = self.branding_favicon_themed_urls.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in ui_footer_links (list) + _items = [] + if self.ui_footer_links: + for _item_ui_footer_links in self.ui_footer_links: + if _item_ui_footer_links: + _items.append(_item_ui_footer_links.to_dict()) + _dict['ui_footer_links'] = _items + # override the default output from pydantic by calling `to_dict()` of flags + if self.flags: + _dict['flags'] = self.flags.to_dict() + # set to None if branding_logo_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.branding_logo_themed_urls is None and "branding_logo_themed_urls" in self.model_fields_set: + _dict['branding_logo_themed_urls'] = None + + # set to None if branding_favicon_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.branding_favicon_themed_urls is None and "branding_favicon_themed_urls" in self.model_fields_set: + _dict['branding_favicon_themed_urls'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CurrentBrand from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "matched_domain": obj.get("matched_domain"), + "branding_title": obj.get("branding_title"), + "branding_logo": obj.get("branding_logo"), + "branding_logo_themed_urls": ThemedUrls.from_dict(obj["branding_logo_themed_urls"]) if obj.get("branding_logo_themed_urls") is not None else None, + "branding_favicon": obj.get("branding_favicon"), + "branding_favicon_themed_urls": ThemedUrls.from_dict(obj["branding_favicon_themed_urls"]) if obj.get("branding_favicon_themed_urls") is not None else None, + "branding_custom_css": obj.get("branding_custom_css"), + "ui_footer_links": [FooterLink.from_dict(_item) for _item in obj["ui_footer_links"]] if obj.get("ui_footer_links") is not None else None, + "ui_theme": obj.get("ui_theme"), + "flow_authentication": obj.get("flow_authentication"), + "flow_invalidation": obj.get("flow_invalidation"), + "flow_recovery": obj.get("flow_recovery"), + "flow_unenrollment": obj.get("flow_unenrollment"), + "flow_user_settings": obj.get("flow_user_settings"), + "flow_device_code": obj.get("flow_device_code"), + "flow_lockdown": obj.get("flow_lockdown"), + "default_locale": obj.get("default_locale"), + "flags": CurrentBrandFlags.from_dict(obj["flags"]) if obj.get("flags") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/current_brand_flags.py b/authentik_client/models/current_brand_flags.py new file mode 100644 index 000000000..bcf580e7c --- /dev/null +++ b/authentik_client/models/current_brand_flags.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class CurrentBrandFlags(BaseModel): + """ + CurrentBrandFlags + """ # noqa: E501 + flows_continuous_login: StrictBool = Field(description="Upon successful authentication, re-start authentication in other open tabs.") + flows_refresh_others: StrictBool = Field(description="Refresh other tabs after successful authentication.") + __properties: ClassVar[List[str]] = ["flows_continuous_login", "flows_refresh_others"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of CurrentBrandFlags from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of CurrentBrandFlags from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flows_continuous_login": obj.get("flows_continuous_login"), + "flows_refresh_others": obj.get("flows_refresh_others") + }) + return _obj + + diff --git a/authentik_client/models/data_export.py b/authentik_client/models/data_export.py new file mode 100644 index 000000000..b93fdc189 --- /dev/null +++ b/authentik_client/models/data_export.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.content_type import ContentType +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DataExport(BaseModel): + """ + Mixin to validate that a valid enterprise license exists before allowing to save the object + """ # noqa: E501 + id: UUID + requested_by: PartialUser + requested_on: datetime + content_type: ContentType + var_query_params: Dict[str, Any] = Field(alias="query_params") + file_url: StrictStr + completed: StrictBool + __properties: ClassVar[List[str]] = ["id", "requested_by", "requested_on", "content_type", "query_params", "file_url", "completed"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DataExport from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "requested_by", + "requested_on", + "content_type", + "file_url", + "completed", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of requested_by + if self.requested_by: + _dict['requested_by'] = self.requested_by.to_dict() + # override the default output from pydantic by calling `to_dict()` of content_type + if self.content_type: + _dict['content_type'] = self.content_type.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DataExport from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "requested_by": PartialUser.from_dict(obj["requested_by"]) if obj.get("requested_by") is not None else None, + "requested_on": obj.get("requested_on"), + "content_type": ContentType.from_dict(obj["content_type"]) if obj.get("content_type") is not None else None, + "query_params": obj.get("query_params"), + "file_url": obj.get("file_url"), + "completed": obj.get("completed") + }) + return _obj + + diff --git a/authentik_client/models/delivery_method_enum.py b/authentik_client/models/delivery_method_enum.py new file mode 100644 index 000000000..9b26bdc8c --- /dev/null +++ b/authentik_client/models/delivery_method_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class DeliveryMethodEnum(str, Enum): + """ + DeliveryMethodEnum + """ + + """ + allowed enum values + """ + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_RISC_SLASH_DELIVERY_MINUS_METHOD_SLASH_PUSH = 'https://schemas.openid.net/secevent/risc/delivery-method/push' + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_RISC_SLASH_DELIVERY_MINUS_METHOD_SLASH_POLL = 'https://schemas.openid.net/secevent/risc/delivery-method/poll' + URN_COLON_IETF_COLON_RFC_COLON_8935 = 'urn:ietf:rfc:8935' + URN_COLON_IETF_COLON_RFC_COLON_8936 = 'urn:ietf:rfc:8936' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of DeliveryMethodEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/denied_action_enum.py b/authentik_client/models/denied_action_enum.py new file mode 100644 index 000000000..4c4c30e5c --- /dev/null +++ b/authentik_client/models/denied_action_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class DeniedActionEnum(str, Enum): + """ + DeniedActionEnum + """ + + """ + allowed enum values + """ + MESSAGE_CONTINUE = 'message_continue' + MESSAGE = 'message' + CONTINUE = 'continue' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of DeniedActionEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/deny_stage.py b/authentik_client/models/deny_stage.py new file mode 100644 index 000000000..1eac99fb1 --- /dev/null +++ b/authentik_client/models/deny_stage.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DenyStage(BaseModel): + """ + DenyStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + deny_message: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "deny_message"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DenyStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DenyStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "deny_message": obj.get("deny_message") + }) + return _obj + + diff --git a/authentik_client/models/deny_stage_request.py b/authentik_client/models/deny_stage_request.py new file mode 100644 index 000000000..76a12ccc9 --- /dev/null +++ b/authentik_client/models/deny_stage_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DenyStageRequest(BaseModel): + """ + DenyStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + deny_message: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "deny_message"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DenyStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DenyStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "deny_message": obj.get("deny_message") + }) + return _obj + + diff --git a/authentik_client/models/detailed_country.py b/authentik_client/models/detailed_country.py new file mode 100644 index 000000000..1f4373635 --- /dev/null +++ b/authentik_client/models/detailed_country.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from authentik_client.models.country_code_enum import CountryCodeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DetailedCountry(BaseModel): + """ + DetailedCountry + """ # noqa: E501 + code: CountryCodeEnum + name: StrictStr + __properties: ClassVar[List[str]] = ["code", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DetailedCountry from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DetailedCountry from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "code": obj.get("code"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/device.py b/authentik_client/models/device.py new file mode 100644 index 000000000..a4beabbd0 --- /dev/null +++ b/authentik_client/models/device.py @@ -0,0 +1,145 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Device(BaseModel): + """ + Serializer for authenticator devices + """ # noqa: E501 + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + pk: StrictStr + name: StrictStr + type: StrictStr = Field(description="Get type of device") + confirmed: StrictBool + created: datetime + last_updated: datetime + last_used: Optional[datetime] + extra_description: Optional[StrictStr] = Field(description="Get extra description") + external_id: Optional[StrictStr] = Field(description="Get external Device ID") + __properties: ClassVar[List[str]] = ["verbose_name", "verbose_name_plural", "meta_model_name", "pk", "name", "type", "confirmed", "created", "last_updated", "last_used", "extra_description", "external_id"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Device from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "type", + "created", + "last_updated", + "last_used", + "extra_description", + "external_id", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if last_used (nullable) is None + # and model_fields_set contains the field + if self.last_used is None and "last_used" in self.model_fields_set: + _dict['last_used'] = None + + # set to None if extra_description (nullable) is None + # and model_fields_set contains the field + if self.extra_description is None and "extra_description" in self.model_fields_set: + _dict['extra_description'] = None + + # set to None if external_id (nullable) is None + # and model_fields_set contains the field + if self.external_id is None and "external_id" in self.model_fields_set: + _dict['external_id'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Device from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "pk": obj.get("pk"), + "name": obj.get("name"), + "type": obj.get("type"), + "confirmed": obj.get("confirmed"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated"), + "last_used": obj.get("last_used"), + "extra_description": obj.get("extra_description"), + "external_id": obj.get("external_id") + }) + return _obj + + diff --git a/authentik_client/models/device_access_group.py b/authentik_client/models/device_access_group.py new file mode 100644 index 000000000..a0fbf0d24 --- /dev/null +++ b/authentik_client/models/device_access_group.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceAccessGroup(BaseModel): + """ + DeviceAccessGroup + """ # noqa: E501 + pbm_uuid: UUID + name: StrictStr + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["pbm_uuid", "name", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceAccessGroup from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pbm_uuid", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceAccessGroup from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pbm_uuid": obj.get("pbm_uuid"), + "name": obj.get("name"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/device_access_group_request.py b/authentik_client/models/device_access_group_request.py new file mode 100644 index 000000000..310ceb57d --- /dev/null +++ b/authentik_client/models/device_access_group_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceAccessGroupRequest(BaseModel): + """ + DeviceAccessGroupRequest + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["name", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceAccessGroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceAccessGroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/device_challenge.py b/authentik_client/models/device_challenge.py new file mode 100644 index 000000000..6cb7c808f --- /dev/null +++ b/authentik_client/models/device_challenge.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.device_classes_enum import DeviceClassesEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceChallenge(BaseModel): + """ + Single device challenge + """ # noqa: E501 + device_class: DeviceClassesEnum + device_uid: StrictStr + challenge: Dict[str, Any] + last_used: Optional[datetime] + __properties: ClassVar[List[str]] = ["device_class", "device_uid", "challenge", "last_used"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if last_used (nullable) is None + # and model_fields_set contains the field + if self.last_used is None and "last_used" in self.model_fields_set: + _dict['last_used'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_class": obj.get("device_class"), + "device_uid": obj.get("device_uid"), + "challenge": obj.get("challenge"), + "last_used": obj.get("last_used") + }) + return _obj + + diff --git a/authentik_client/models/device_challenge_request.py b/authentik_client/models/device_challenge_request.py new file mode 100644 index 000000000..e9365895a --- /dev/null +++ b/authentik_client/models/device_challenge_request.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.device_classes_enum import DeviceClassesEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceChallengeRequest(BaseModel): + """ + Single device challenge + """ # noqa: E501 + device_class: DeviceClassesEnum + device_uid: Annotated[str, Field(min_length=1, strict=True)] + challenge: Dict[str, Any] + last_used: Optional[datetime] + __properties: ClassVar[List[str]] = ["device_class", "device_uid", "challenge", "last_used"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceChallengeRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if last_used (nullable) is None + # and model_fields_set contains the field + if self.last_used is None and "last_used" in self.model_fields_set: + _dict['last_used'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceChallengeRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_class": obj.get("device_class"), + "device_uid": obj.get("device_uid"), + "challenge": obj.get("challenge"), + "last_used": obj.get("last_used") + }) + return _obj + + diff --git a/authentik_client/models/device_classes_enum.py b/authentik_client/models/device_classes_enum.py new file mode 100644 index 000000000..72e0898c1 --- /dev/null +++ b/authentik_client/models/device_classes_enum.py @@ -0,0 +1,42 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class DeviceClassesEnum(str, Enum): + """ + DeviceClassesEnum + """ + + """ + allowed enum values + """ + STATIC = 'static' + TOTP = 'totp' + WEBAUTHN = 'webauthn' + DUO = 'duo' + SMS = 'sms' + EMAIL = 'email' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of DeviceClassesEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/device_connection.py b/authentik_client/models/device_connection.py new file mode 100644 index 000000000..4f9fa0203 --- /dev/null +++ b/authentik_client/models/device_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.connector import Connector +from authentik_client.models.device_fact_snapshot import DeviceFactSnapshot +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceConnection(BaseModel): + """ + DeviceConnection + """ # noqa: E501 + device: UUID + connector: UUID + connector_obj: Connector + latest_snapshot: Optional[DeviceFactSnapshot] + __properties: ClassVar[List[str]] = ["device", "connector", "connector_obj", "latest_snapshot"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "connector_obj", + "latest_snapshot", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of connector_obj + if self.connector_obj: + _dict['connector_obj'] = self.connector_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of latest_snapshot + if self.latest_snapshot: + _dict['latest_snapshot'] = self.latest_snapshot.to_dict() + # set to None if latest_snapshot (nullable) is None + # and model_fields_set contains the field + if self.latest_snapshot is None and "latest_snapshot" in self.model_fields_set: + _dict['latest_snapshot'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device": obj.get("device"), + "connector": obj.get("connector"), + "connector_obj": Connector.from_dict(obj["connector_obj"]) if obj.get("connector_obj") is not None else None, + "latest_snapshot": DeviceFactSnapshot.from_dict(obj["latest_snapshot"]) if obj.get("latest_snapshot") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/device_fact_snapshot.py b/authentik_client/models/device_fact_snapshot.py new file mode 100644 index 000000000..91785adf4 --- /dev/null +++ b/authentik_client/models/device_fact_snapshot.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.device_facts import DeviceFacts +from authentik_client.models.vendor_enum import VendorEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceFactSnapshot(BaseModel): + """ + DeviceFactSnapshot + """ # noqa: E501 + data: DeviceFacts + connection: UUID + created: datetime + expires: Optional[datetime] + vendor: VendorEnum + __properties: ClassVar[List[str]] = ["data", "connection", "created", "expires", "vendor"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceFactSnapshot from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "created", + "expires", + "vendor", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of data + if self.data: + _dict['data'] = self.data.to_dict() + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceFactSnapshot from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "data": DeviceFacts.from_dict(obj["data"]) if obj.get("data") is not None else None, + "connection": obj.get("connection"), + "created": obj.get("created"), + "expires": obj.get("expires"), + "vendor": obj.get("vendor") + }) + return _obj + + diff --git a/authentik_client/models/device_facts.py b/authentik_client/models/device_facts.py new file mode 100644 index 000000000..19a0a25f2 --- /dev/null +++ b/authentik_client/models/device_facts.py @@ -0,0 +1,197 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.device_group import DeviceGroup +from authentik_client.models.device_user import DeviceUser +from authentik_client.models.disk import Disk +from authentik_client.models.hardware import Hardware +from authentik_client.models.network import Network +from authentik_client.models.operating_system import OperatingSystem +from authentik_client.models.process import Process +from authentik_client.models.software import Software +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceFacts(BaseModel): + """ + DeviceFacts + """ # noqa: E501 + os: Optional[OperatingSystem] = None + disks: Optional[List[Disk]] = None + network: Optional[Network] = None + hardware: Optional[Hardware] = None + software: Optional[List[Software]] = None + processes: Optional[List[Process]] = None + users: Optional[List[DeviceUser]] = None + groups: Optional[List[DeviceGroup]] = None + vendor: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["os", "disks", "network", "hardware", "software", "processes", "users", "groups", "vendor"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceFacts from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of os + if self.os: + _dict['os'] = self.os.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in disks (list) + _items = [] + if self.disks: + for _item_disks in self.disks: + if _item_disks: + _items.append(_item_disks.to_dict()) + _dict['disks'] = _items + # override the default output from pydantic by calling `to_dict()` of network + if self.network: + _dict['network'] = self.network.to_dict() + # override the default output from pydantic by calling `to_dict()` of hardware + if self.hardware: + _dict['hardware'] = self.hardware.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in software (list) + _items = [] + if self.software: + for _item_software in self.software: + if _item_software: + _items.append(_item_software.to_dict()) + _dict['software'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in processes (list) + _items = [] + if self.processes: + for _item_processes in self.processes: + if _item_processes: + _items.append(_item_processes.to_dict()) + _dict['processes'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in users (list) + _items = [] + if self.users: + for _item_users in self.users: + if _item_users: + _items.append(_item_users.to_dict()) + _dict['users'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in groups (list) + _items = [] + if self.groups: + for _item_groups in self.groups: + if _item_groups: + _items.append(_item_groups.to_dict()) + _dict['groups'] = _items + # set to None if os (nullable) is None + # and model_fields_set contains the field + if self.os is None and "os" in self.model_fields_set: + _dict['os'] = None + + # set to None if disks (nullable) is None + # and model_fields_set contains the field + if self.disks is None and "disks" in self.model_fields_set: + _dict['disks'] = None + + # set to None if network (nullable) is None + # and model_fields_set contains the field + if self.network is None and "network" in self.model_fields_set: + _dict['network'] = None + + # set to None if hardware (nullable) is None + # and model_fields_set contains the field + if self.hardware is None and "hardware" in self.model_fields_set: + _dict['hardware'] = None + + # set to None if software (nullable) is None + # and model_fields_set contains the field + if self.software is None and "software" in self.model_fields_set: + _dict['software'] = None + + # set to None if processes (nullable) is None + # and model_fields_set contains the field + if self.processes is None and "processes" in self.model_fields_set: + _dict['processes'] = None + + # set to None if users (nullable) is None + # and model_fields_set contains the field + if self.users is None and "users" in self.model_fields_set: + _dict['users'] = None + + # set to None if groups (nullable) is None + # and model_fields_set contains the field + if self.groups is None and "groups" in self.model_fields_set: + _dict['groups'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceFacts from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "os": OperatingSystem.from_dict(obj["os"]) if obj.get("os") is not None else None, + "disks": [Disk.from_dict(_item) for _item in obj["disks"]] if obj.get("disks") is not None else None, + "network": Network.from_dict(obj["network"]) if obj.get("network") is not None else None, + "hardware": Hardware.from_dict(obj["hardware"]) if obj.get("hardware") is not None else None, + "software": [Software.from_dict(_item) for _item in obj["software"]] if obj.get("software") is not None else None, + "processes": [Process.from_dict(_item) for _item in obj["processes"]] if obj.get("processes") is not None else None, + "users": [DeviceUser.from_dict(_item) for _item in obj["users"]] if obj.get("users") is not None else None, + "groups": [DeviceGroup.from_dict(_item) for _item in obj["groups"]] if obj.get("groups") is not None else None, + "vendor": obj.get("vendor") + }) + return _obj + + diff --git a/authentik_client/models/device_facts_os_family.py b/authentik_client/models/device_facts_os_family.py new file mode 100644 index 000000000..43b07ba4f --- /dev/null +++ b/authentik_client/models/device_facts_os_family.py @@ -0,0 +1,44 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class DeviceFactsOSFamily(str, Enum): + """ + DeviceFactsOSFamily + """ + + """ + allowed enum values + """ + LINUX = 'linux' + UNIX = 'unix' + BSD = 'bsd' + WINDOWS = 'windows' + MAC_OS = 'mac_os' + ANDROID = 'android' + I_OS = 'i_os' + OTHER = 'other' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of DeviceFactsOSFamily from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/device_facts_request.py b/authentik_client/models/device_facts_request.py new file mode 100644 index 000000000..67e3f6f00 --- /dev/null +++ b/authentik_client/models/device_facts_request.py @@ -0,0 +1,197 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.device_group_request import DeviceGroupRequest +from authentik_client.models.device_user_request import DeviceUserRequest +from authentik_client.models.disk_request import DiskRequest +from authentik_client.models.hardware_request import HardwareRequest +from authentik_client.models.network_request import NetworkRequest +from authentik_client.models.operating_system_request import OperatingSystemRequest +from authentik_client.models.process_request import ProcessRequest +from authentik_client.models.software_request import SoftwareRequest +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceFactsRequest(BaseModel): + """ + DeviceFactsRequest + """ # noqa: E501 + os: Optional[OperatingSystemRequest] = None + disks: Optional[List[DiskRequest]] = None + network: Optional[NetworkRequest] = None + hardware: Optional[HardwareRequest] = None + software: Optional[List[SoftwareRequest]] = None + processes: Optional[List[ProcessRequest]] = None + users: Optional[List[DeviceUserRequest]] = None + groups: Optional[List[DeviceGroupRequest]] = None + vendor: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["os", "disks", "network", "hardware", "software", "processes", "users", "groups", "vendor"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceFactsRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of os + if self.os: + _dict['os'] = self.os.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in disks (list) + _items = [] + if self.disks: + for _item_disks in self.disks: + if _item_disks: + _items.append(_item_disks.to_dict()) + _dict['disks'] = _items + # override the default output from pydantic by calling `to_dict()` of network + if self.network: + _dict['network'] = self.network.to_dict() + # override the default output from pydantic by calling `to_dict()` of hardware + if self.hardware: + _dict['hardware'] = self.hardware.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in software (list) + _items = [] + if self.software: + for _item_software in self.software: + if _item_software: + _items.append(_item_software.to_dict()) + _dict['software'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in processes (list) + _items = [] + if self.processes: + for _item_processes in self.processes: + if _item_processes: + _items.append(_item_processes.to_dict()) + _dict['processes'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in users (list) + _items = [] + if self.users: + for _item_users in self.users: + if _item_users: + _items.append(_item_users.to_dict()) + _dict['users'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in groups (list) + _items = [] + if self.groups: + for _item_groups in self.groups: + if _item_groups: + _items.append(_item_groups.to_dict()) + _dict['groups'] = _items + # set to None if os (nullable) is None + # and model_fields_set contains the field + if self.os is None and "os" in self.model_fields_set: + _dict['os'] = None + + # set to None if disks (nullable) is None + # and model_fields_set contains the field + if self.disks is None and "disks" in self.model_fields_set: + _dict['disks'] = None + + # set to None if network (nullable) is None + # and model_fields_set contains the field + if self.network is None and "network" in self.model_fields_set: + _dict['network'] = None + + # set to None if hardware (nullable) is None + # and model_fields_set contains the field + if self.hardware is None and "hardware" in self.model_fields_set: + _dict['hardware'] = None + + # set to None if software (nullable) is None + # and model_fields_set contains the field + if self.software is None and "software" in self.model_fields_set: + _dict['software'] = None + + # set to None if processes (nullable) is None + # and model_fields_set contains the field + if self.processes is None and "processes" in self.model_fields_set: + _dict['processes'] = None + + # set to None if users (nullable) is None + # and model_fields_set contains the field + if self.users is None and "users" in self.model_fields_set: + _dict['users'] = None + + # set to None if groups (nullable) is None + # and model_fields_set contains the field + if self.groups is None and "groups" in self.model_fields_set: + _dict['groups'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceFactsRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "os": OperatingSystemRequest.from_dict(obj["os"]) if obj.get("os") is not None else None, + "disks": [DiskRequest.from_dict(_item) for _item in obj["disks"]] if obj.get("disks") is not None else None, + "network": NetworkRequest.from_dict(obj["network"]) if obj.get("network") is not None else None, + "hardware": HardwareRequest.from_dict(obj["hardware"]) if obj.get("hardware") is not None else None, + "software": [SoftwareRequest.from_dict(_item) for _item in obj["software"]] if obj.get("software") is not None else None, + "processes": [ProcessRequest.from_dict(_item) for _item in obj["processes"]] if obj.get("processes") is not None else None, + "users": [DeviceUserRequest.from_dict(_item) for _item in obj["users"]] if obj.get("users") is not None else None, + "groups": [DeviceGroupRequest.from_dict(_item) for _item in obj["groups"]] if obj.get("groups") is not None else None, + "vendor": obj.get("vendor") + }) + return _obj + + diff --git a/authentik_client/models/device_group.py b/authentik_client/models/device_group.py new file mode 100644 index 000000000..e7aaafb06 --- /dev/null +++ b/authentik_client/models/device_group.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceGroup(BaseModel): + """ + DeviceGroup + """ # noqa: E501 + id: StrictStr + name: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["id", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceGroup from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceGroup from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/device_group_request.py b/authentik_client/models/device_group_request.py new file mode 100644 index 000000000..f8eead7a7 --- /dev/null +++ b/authentik_client/models/device_group_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceGroupRequest(BaseModel): + """ + DeviceGroupRequest + """ # noqa: E501 + id: Annotated[str, Field(min_length=1, strict=True)] + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["id", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceGroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceGroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/device_summary.py b/authentik_client/models/device_summary.py new file mode 100644 index 000000000..420a04524 --- /dev/null +++ b/authentik_client/models/device_summary.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceSummary(BaseModel): + """ + Summary of registered devices + """ # noqa: E501 + total_count: StrictInt + unreachable_count: StrictInt + outdated_agent_count: StrictInt + __properties: ClassVar[List[str]] = ["total_count", "unreachable_count", "outdated_agent_count"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceSummary from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceSummary from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "total_count": obj.get("total_count"), + "unreachable_count": obj.get("unreachable_count"), + "outdated_agent_count": obj.get("outdated_agent_count") + }) + return _obj + + diff --git a/authentik_client/models/device_user.py b/authentik_client/models/device_user.py new file mode 100644 index 000000000..7625fff65 --- /dev/null +++ b/authentik_client/models/device_user.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceUser(BaseModel): + """ + DeviceUser + """ # noqa: E501 + id: StrictStr + username: Optional[StrictStr] = None + name: Optional[StrictStr] = None + home: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["id", "username", "name", "home"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceUser from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceUser from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "username": obj.get("username"), + "name": obj.get("name"), + "home": obj.get("home") + }) + return _obj + + diff --git a/authentik_client/models/device_user_binding.py b/authentik_client/models/device_user_binding.py new file mode 100644 index 000000000..a97efdac4 --- /dev/null +++ b/authentik_client/models/device_user_binding.py @@ -0,0 +1,184 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.connector import Connector +from authentik_client.models.partial_group import PartialGroup +from authentik_client.models.partial_user import PartialUser +from authentik_client.models.policy import Policy +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceUserBinding(BaseModel): + """ + PolicyBinding Serializer + """ # noqa: E501 + pk: UUID + policy: Optional[UUID] = None + group: Optional[UUID] = None + user: Optional[StrictInt] = None + policy_obj: Optional[Policy] + group_obj: Optional[PartialGroup] + user_obj: Optional[PartialUser] + target: UUID + negate: Optional[StrictBool] = Field(default=None, description="Negates the outcome of the policy. Messages are unaffected.") + enabled: Optional[StrictBool] = None + order: Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)] + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Timeout after which Policy execution is terminated.") + failure_result: Optional[StrictBool] = Field(default=None, description="Result if the Policy execution fails.") + is_primary: Optional[StrictBool] = None + connector: Optional[UUID] + connector_obj: Connector + __properties: ClassVar[List[str]] = ["pk", "policy", "group", "user", "policy_obj", "group_obj", "user_obj", "target", "negate", "enabled", "order", "timeout", "failure_result", "is_primary", "connector", "connector_obj"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceUserBinding from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "policy_obj", + "group_obj", + "user_obj", + "connector", + "connector_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of policy_obj + if self.policy_obj: + _dict['policy_obj'] = self.policy_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of group_obj + if self.group_obj: + _dict['group_obj'] = self.group_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of user_obj + if self.user_obj: + _dict['user_obj'] = self.user_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of connector_obj + if self.connector_obj: + _dict['connector_obj'] = self.connector_obj.to_dict() + # set to None if policy (nullable) is None + # and model_fields_set contains the field + if self.policy is None and "policy" in self.model_fields_set: + _dict['policy'] = None + + # set to None if group (nullable) is None + # and model_fields_set contains the field + if self.group is None and "group" in self.model_fields_set: + _dict['group'] = None + + # set to None if user (nullable) is None + # and model_fields_set contains the field + if self.user is None and "user" in self.model_fields_set: + _dict['user'] = None + + # set to None if policy_obj (nullable) is None + # and model_fields_set contains the field + if self.policy_obj is None and "policy_obj" in self.model_fields_set: + _dict['policy_obj'] = None + + # set to None if group_obj (nullable) is None + # and model_fields_set contains the field + if self.group_obj is None and "group_obj" in self.model_fields_set: + _dict['group_obj'] = None + + # set to None if user_obj (nullable) is None + # and model_fields_set contains the field + if self.user_obj is None and "user_obj" in self.model_fields_set: + _dict['user_obj'] = None + + # set to None if connector (nullable) is None + # and model_fields_set contains the field + if self.connector is None and "connector" in self.model_fields_set: + _dict['connector'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceUserBinding from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "policy": obj.get("policy"), + "group": obj.get("group"), + "user": obj.get("user"), + "policy_obj": Policy.from_dict(obj["policy_obj"]) if obj.get("policy_obj") is not None else None, + "group_obj": PartialGroup.from_dict(obj["group_obj"]) if obj.get("group_obj") is not None else None, + "user_obj": PartialUser.from_dict(obj["user_obj"]) if obj.get("user_obj") is not None else None, + "target": obj.get("target"), + "negate": obj.get("negate"), + "enabled": obj.get("enabled"), + "order": obj.get("order"), + "timeout": obj.get("timeout"), + "failure_result": obj.get("failure_result"), + "is_primary": obj.get("is_primary"), + "connector": obj.get("connector"), + "connector_obj": Connector.from_dict(obj["connector_obj"]) if obj.get("connector_obj") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/device_user_binding_request.py b/authentik_client/models/device_user_binding_request.py new file mode 100644 index 000000000..520e06ff8 --- /dev/null +++ b/authentik_client/models/device_user_binding_request.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceUserBindingRequest(BaseModel): + """ + PolicyBinding Serializer + """ # noqa: E501 + policy: Optional[UUID] = None + group: Optional[UUID] = None + user: Optional[StrictInt] = None + target: UUID + negate: Optional[StrictBool] = Field(default=None, description="Negates the outcome of the policy. Messages are unaffected.") + enabled: Optional[StrictBool] = None + order: Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)] + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Timeout after which Policy execution is terminated.") + failure_result: Optional[StrictBool] = Field(default=None, description="Result if the Policy execution fails.") + is_primary: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["policy", "group", "user", "target", "negate", "enabled", "order", "timeout", "failure_result", "is_primary"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceUserBindingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if policy (nullable) is None + # and model_fields_set contains the field + if self.policy is None and "policy" in self.model_fields_set: + _dict['policy'] = None + + # set to None if group (nullable) is None + # and model_fields_set contains the field + if self.group is None and "group" in self.model_fields_set: + _dict['group'] = None + + # set to None if user (nullable) is None + # and model_fields_set contains the field + if self.user is None and "user" in self.model_fields_set: + _dict['user'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceUserBindingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "policy": obj.get("policy"), + "group": obj.get("group"), + "user": obj.get("user"), + "target": obj.get("target"), + "negate": obj.get("negate"), + "enabled": obj.get("enabled"), + "order": obj.get("order"), + "timeout": obj.get("timeout"), + "failure_result": obj.get("failure_result"), + "is_primary": obj.get("is_primary") + }) + return _obj + + diff --git a/authentik_client/models/device_user_request.py b/authentik_client/models/device_user_request.py new file mode 100644 index 000000000..dd4c67dd1 --- /dev/null +++ b/authentik_client/models/device_user_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DeviceUserRequest(BaseModel): + """ + DeviceUserRequest + """ # noqa: E501 + id: Annotated[str, Field(min_length=1, strict=True)] + username: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + home: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["id", "username", "name", "home"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeviceUserRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeviceUserRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "username": obj.get("username"), + "name": obj.get("name"), + "home": obj.get("home") + }) + return _obj + + diff --git a/authentik_client/models/digest_algorithm_enum.py b/authentik_client/models/digest_algorithm_enum.py new file mode 100644 index 000000000..a7bf0e991 --- /dev/null +++ b/authentik_client/models/digest_algorithm_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class DigestAlgorithmEnum(str, Enum): + """ + DigestAlgorithmEnum + """ + + """ + allowed enum values + """ + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2000_SLASH_09_SLASH_XMLDSIG_HASH_SHA1 = 'http://www.w3.org/2000/09/xmldsig#sha1' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLENC_HASH_SHA256 = 'http://www.w3.org/2001/04/xmlenc#sha256' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_SHA384 = 'http://www.w3.org/2001/04/xmldsig-more#sha384' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLENC_HASH_SHA512 = 'http://www.w3.org/2001/04/xmlenc#sha512' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of DigestAlgorithmEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/digits_enum.py b/authentik_client/models/digits_enum.py new file mode 100644 index 000000000..8728c6d72 --- /dev/null +++ b/authentik_client/models/digits_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class DigitsEnum(str, Enum): + """ + DigitsEnum + """ + + """ + allowed enum values + """ + ENUM_6 = '6' + ENUM_8 = '8' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of DigitsEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/disk.py b/authentik_client/models/disk.py new file mode 100644 index 000000000..192321fd2 --- /dev/null +++ b/authentik_client/models/disk.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Disk(BaseModel): + """ + Disk + """ # noqa: E501 + name: StrictStr + mountpoint: StrictStr + label: Optional[StrictStr] = None + capacity_total_bytes: Optional[StrictInt] = None + capacity_used_bytes: Optional[StrictInt] = None + encryption_enabled: Optional[StrictBool] = False + __properties: ClassVar[List[str]] = ["name", "mountpoint", "label", "capacity_total_bytes", "capacity_used_bytes", "encryption_enabled"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Disk from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Disk from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "mountpoint": obj.get("mountpoint"), + "label": obj.get("label"), + "capacity_total_bytes": obj.get("capacity_total_bytes"), + "capacity_used_bytes": obj.get("capacity_used_bytes"), + "encryption_enabled": obj.get("encryption_enabled") if obj.get("encryption_enabled") is not None else False + }) + return _obj + + diff --git a/authentik_client/models/disk_request.py b/authentik_client/models/disk_request.py new file mode 100644 index 000000000..b1c06d685 --- /dev/null +++ b/authentik_client/models/disk_request.py @@ -0,0 +1,100 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DiskRequest(BaseModel): + """ + DiskRequest + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + mountpoint: Annotated[str, Field(min_length=1, strict=True)] + label: Optional[StrictStr] = None + capacity_total_bytes: Optional[StrictInt] = None + capacity_used_bytes: Optional[StrictInt] = None + encryption_enabled: Optional[StrictBool] = False + __properties: ClassVar[List[str]] = ["name", "mountpoint", "label", "capacity_total_bytes", "capacity_used_bytes", "encryption_enabled"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DiskRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DiskRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "mountpoint": obj.get("mountpoint"), + "label": obj.get("label"), + "capacity_total_bytes": obj.get("capacity_total_bytes"), + "capacity_used_bytes": obj.get("capacity_used_bytes"), + "encryption_enabled": obj.get("encryption_enabled") if obj.get("encryption_enabled") is not None else False + }) + return _obj + + diff --git a/authentik_client/models/docker_service_connection.py b/authentik_client/models/docker_service_connection.py new file mode 100644 index 000000000..271246e8d --- /dev/null +++ b/authentik_client/models/docker_service_connection.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DockerServiceConnection(BaseModel): + """ + DockerServiceConnection Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + local: Optional[StrictBool] = Field(default=None, description="If enabled, use the local connection. Required Docker socket/Kubernetes Integration") + component: StrictStr + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + url: StrictStr = Field(description="Can be in the format of 'unix://' when connecting to a local docker daemon, or 'https://:2376' when connecting to a remote system.") + tls_verification: Optional[UUID] = Field(default=None, description="CA which the endpoint's Certificate is verified against. Can be left empty for no validation.") + tls_authentication: Optional[UUID] = Field(default=None, description="Certificate/Key used for authentication. Can be left empty for no authentication.") + __properties: ClassVar[List[str]] = ["pk", "name", "local", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "url", "tls_verification", "tls_authentication"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DockerServiceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if tls_verification (nullable) is None + # and model_fields_set contains the field + if self.tls_verification is None and "tls_verification" in self.model_fields_set: + _dict['tls_verification'] = None + + # set to None if tls_authentication (nullable) is None + # and model_fields_set contains the field + if self.tls_authentication is None and "tls_authentication" in self.model_fields_set: + _dict['tls_authentication'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DockerServiceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "local": obj.get("local"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "url": obj.get("url"), + "tls_verification": obj.get("tls_verification"), + "tls_authentication": obj.get("tls_authentication") + }) + return _obj + + diff --git a/authentik_client/models/docker_service_connection_request.py b/authentik_client/models/docker_service_connection_request.py new file mode 100644 index 000000000..6a4926e47 --- /dev/null +++ b/authentik_client/models/docker_service_connection_request.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DockerServiceConnectionRequest(BaseModel): + """ + DockerServiceConnection Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + local: Optional[StrictBool] = Field(default=None, description="If enabled, use the local connection. Required Docker socket/Kubernetes Integration") + url: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Can be in the format of 'unix://' when connecting to a local docker daemon, or 'https://:2376' when connecting to a remote system.") + tls_verification: Optional[UUID] = Field(default=None, description="CA which the endpoint's Certificate is verified against. Can be left empty for no validation.") + tls_authentication: Optional[UUID] = Field(default=None, description="Certificate/Key used for authentication. Can be left empty for no authentication.") + __properties: ClassVar[List[str]] = ["name", "local", "url", "tls_verification", "tls_authentication"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DockerServiceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if tls_verification (nullable) is None + # and model_fields_set contains the field + if self.tls_verification is None and "tls_verification" in self.model_fields_set: + _dict['tls_verification'] = None + + # set to None if tls_authentication (nullable) is None + # and model_fields_set contains the field + if self.tls_authentication is None and "tls_authentication" in self.model_fields_set: + _dict['tls_authentication'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DockerServiceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "local": obj.get("local"), + "url": obj.get("url"), + "tls_verification": obj.get("tls_verification"), + "tls_authentication": obj.get("tls_authentication") + }) + return _obj + + diff --git a/authentik_client/models/domain.py b/authentik_client/models/domain.py new file mode 100644 index 000000000..29708a6b8 --- /dev/null +++ b/authentik_client/models/domain.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Domain(BaseModel): + """ + Domain Serializer + """ # noqa: E501 + id: StrictInt + domain: Annotated[str, Field(strict=True, max_length=253)] + is_primary: Optional[StrictBool] = None + tenant: UUID + __properties: ClassVar[List[str]] = ["id", "domain", "is_primary", "tenant"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Domain from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Domain from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "domain": obj.get("domain"), + "is_primary": obj.get("is_primary"), + "tenant": obj.get("tenant") + }) + return _obj + + diff --git a/authentik_client/models/domain_request.py b/authentik_client/models/domain_request.py new file mode 100644 index 000000000..1785b5330 --- /dev/null +++ b/authentik_client/models/domain_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DomainRequest(BaseModel): + """ + Domain Serializer + """ # noqa: E501 + domain: Annotated[str, Field(min_length=1, strict=True, max_length=253)] + is_primary: Optional[StrictBool] = None + tenant: UUID + __properties: ClassVar[List[str]] = ["domain", "is_primary", "tenant"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DomainRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DomainRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "domain": obj.get("domain"), + "is_primary": obj.get("is_primary"), + "tenant": obj.get("tenant") + }) + return _obj + + diff --git a/authentik_client/models/dummy_challenge.py b/authentik_client/models/dummy_challenge.py new file mode 100644 index 000000000..f16641993 --- /dev/null +++ b/authentik_client/models/dummy_challenge.py @@ -0,0 +1,114 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DummyChallenge(BaseModel): + """ + Dummy challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-dummy' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + name: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DummyChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DummyChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-dummy', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/dummy_challenge_response_request.py b/authentik_client/models/dummy_challenge_response_request.py new file mode 100644 index 000000000..2a8cdda4b --- /dev/null +++ b/authentik_client/models/dummy_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DummyChallengeResponseRequest(BaseModel): + """ + Dummy challenge response + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-dummy' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DummyChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DummyChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-dummy' + }) + return _obj + + diff --git a/authentik_client/models/dummy_policy.py b/authentik_client/models/dummy_policy.py new file mode 100644 index 000000000..6e32b497b --- /dev/null +++ b/authentik_client/models/dummy_policy.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DummyPolicy(BaseModel): + """ + Dummy Policy Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + bound_to: StrictInt = Field(description="Return objects policy is bound to") + result: Optional[StrictBool] = None + wait_min: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + wait_max: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + __properties: ClassVar[List[str]] = ["pk", "name", "execution_logging", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "bound_to", "result", "wait_min", "wait_max"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DummyPolicy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "bound_to", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DummyPolicy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "bound_to": obj.get("bound_to"), + "result": obj.get("result"), + "wait_min": obj.get("wait_min"), + "wait_max": obj.get("wait_max") + }) + return _obj + + diff --git a/authentik_client/models/dummy_policy_request.py b/authentik_client/models/dummy_policy_request.py new file mode 100644 index 000000000..d3b58a563 --- /dev/null +++ b/authentik_client/models/dummy_policy_request.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DummyPolicyRequest(BaseModel): + """ + Dummy Policy Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + result: Optional[StrictBool] = None + wait_min: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + wait_max: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "result", "wait_min", "wait_max"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DummyPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DummyPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "result": obj.get("result"), + "wait_min": obj.get("wait_min"), + "wait_max": obj.get("wait_max") + }) + return _obj + + diff --git a/authentik_client/models/dummy_stage.py b/authentik_client/models/dummy_stage.py new file mode 100644 index 000000000..2e9fda1e9 --- /dev/null +++ b/authentik_client/models/dummy_stage.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DummyStage(BaseModel): + """ + DummyStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + throw_error: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "throw_error"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DummyStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DummyStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "throw_error": obj.get("throw_error") + }) + return _obj + + diff --git a/authentik_client/models/dummy_stage_request.py b/authentik_client/models/dummy_stage_request.py new file mode 100644 index 000000000..9c6ed1aec --- /dev/null +++ b/authentik_client/models/dummy_stage_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DummyStageRequest(BaseModel): + """ + DummyStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + throw_error: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "throw_error"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DummyStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DummyStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "throw_error": obj.get("throw_error") + }) + return _obj + + diff --git a/authentik_client/models/duo_device.py b/authentik_client/models/duo_device.py new file mode 100644 index 000000000..580e9c3fb --- /dev/null +++ b/authentik_client/models/duo_device.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DuoDevice(BaseModel): + """ + Serializer for Duo authenticator devices + """ # noqa: E501 + pk: StrictInt + name: Annotated[str, Field(strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + user: PartialUser + __properties: ClassVar[List[str]] = ["pk", "name", "user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DuoDevice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DuoDevice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "user": PartialUser.from_dict(obj["user"]) if obj.get("user") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/duo_device_enrollment_status.py b/authentik_client/models/duo_device_enrollment_status.py new file mode 100644 index 000000000..e00ca509f --- /dev/null +++ b/authentik_client/models/duo_device_enrollment_status.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.duo_response_enum import DuoResponseEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DuoDeviceEnrollmentStatus(BaseModel): + """ + DuoDeviceEnrollmentStatus + """ # noqa: E501 + duo_response: DuoResponseEnum + __properties: ClassVar[List[str]] = ["duo_response"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DuoDeviceEnrollmentStatus from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DuoDeviceEnrollmentStatus from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "duo_response": obj.get("duo_response") + }) + return _obj + + diff --git a/authentik_client/models/duo_device_request.py b/authentik_client/models/duo_device_request.py new file mode 100644 index 000000000..17aff33e4 --- /dev/null +++ b/authentik_client/models/duo_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class DuoDeviceRequest(BaseModel): + """ + Serializer for Duo authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DuoDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DuoDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/duo_response_enum.py b/authentik_client/models/duo_response_enum.py new file mode 100644 index 000000000..d60ba9995 --- /dev/null +++ b/authentik_client/models/duo_response_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class DuoResponseEnum(str, Enum): + """ + DuoResponseEnum + """ + + """ + allowed enum values + """ + SUCCESS = 'success' + WAITING = 'waiting' + INVALID = 'invalid' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of DuoResponseEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/email_challenge.py b/authentik_client/models/email_challenge.py new file mode 100644 index 000000000..52fa46dea --- /dev/null +++ b/authentik_client/models/email_challenge.py @@ -0,0 +1,112 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EmailChallenge(BaseModel): + """ + Email challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-email' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EmailChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EmailChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-email', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None + }) + return _obj + + diff --git a/authentik_client/models/email_challenge_response_request.py b/authentik_client/models/email_challenge_response_request.py new file mode 100644 index 000000000..e1d271c2a --- /dev/null +++ b/authentik_client/models/email_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EmailChallengeResponseRequest(BaseModel): + """ + Email challenge resposen. No fields. This challenge is always declared invalid to give the user a chance to retry + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-email' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EmailChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EmailChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-email' + }) + return _obj + + diff --git a/authentik_client/models/email_device.py b/authentik_client/models/email_device.py new file mode 100644 index 000000000..c34f2aba4 --- /dev/null +++ b/authentik_client/models/email_device.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EmailDevice(BaseModel): + """ + Serializer for email authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + pk: StrictInt + email: StrictStr + user: PartialUser + __properties: ClassVar[List[str]] = ["name", "pk", "email", "user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EmailDevice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "email", + "user", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EmailDevice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "pk": obj.get("pk"), + "email": obj.get("email"), + "user": PartialUser.from_dict(obj["user"]) if obj.get("user") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/email_device_request.py b/authentik_client/models/email_device_request.py new file mode 100644 index 000000000..1337a4e88 --- /dev/null +++ b/authentik_client/models/email_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EmailDeviceRequest(BaseModel): + """ + Serializer for email authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EmailDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EmailDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/email_stage.py b/authentik_client/models/email_stage.py new file mode 100644 index 000000000..3acca60ed --- /dev/null +++ b/authentik_client/models/email_stage.py @@ -0,0 +1,151 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EmailStage(BaseModel): + """ + EmailStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + use_global_settings: Optional[StrictBool] = Field(default=None, description="When enabled, global Email connection settings will be used and connection settings below will be ignored.") + host: Optional[StrictStr] = None + port: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + username: Optional[StrictStr] = None + use_tls: Optional[StrictBool] = None + use_ssl: Optional[StrictBool] = None + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + from_address: Optional[Annotated[str, Field(strict=True, max_length=254)]] = None + token_expiry: Optional[StrictStr] = Field(default=None, description="Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).") + subject: Optional[StrictStr] = None + template: Optional[StrictStr] = None + activate_user_on_success: Optional[StrictBool] = Field(default=None, description="Activate users upon completion of stage.") + recovery_max_attempts: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + recovery_cache_timeout: Optional[StrictStr] = Field(default=None, description="The time window used to count recent account recovery attempts. If the number of attempts exceed recovery_max_attempts within this period, further attempts will be rate-limited. (Format: hours=1;minutes=2;seconds=3).") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "use_global_settings", "host", "port", "username", "use_tls", "use_ssl", "timeout", "from_address", "token_expiry", "subject", "template", "activate_user_on_success", "recovery_max_attempts", "recovery_cache_timeout"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EmailStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EmailStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "use_global_settings": obj.get("use_global_settings"), + "host": obj.get("host"), + "port": obj.get("port"), + "username": obj.get("username"), + "use_tls": obj.get("use_tls"), + "use_ssl": obj.get("use_ssl"), + "timeout": obj.get("timeout"), + "from_address": obj.get("from_address"), + "token_expiry": obj.get("token_expiry"), + "subject": obj.get("subject"), + "template": obj.get("template"), + "activate_user_on_success": obj.get("activate_user_on_success"), + "recovery_max_attempts": obj.get("recovery_max_attempts"), + "recovery_cache_timeout": obj.get("recovery_cache_timeout") + }) + return _obj + + diff --git a/authentik_client/models/email_stage_request.py b/authentik_client/models/email_stage_request.py new file mode 100644 index 000000000..f33fe8eaf --- /dev/null +++ b/authentik_client/models/email_stage_request.py @@ -0,0 +1,120 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EmailStageRequest(BaseModel): + """ + EmailStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + use_global_settings: Optional[StrictBool] = Field(default=None, description="When enabled, global Email connection settings will be used and connection settings below will be ignored.") + host: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + port: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + username: Optional[StrictStr] = None + password: Optional[StrictStr] = None + use_tls: Optional[StrictBool] = None + use_ssl: Optional[StrictBool] = None + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + from_address: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=254)]] = None + token_expiry: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).") + subject: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + activate_user_on_success: Optional[StrictBool] = Field(default=None, description="Activate users upon completion of stage.") + recovery_max_attempts: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + recovery_cache_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="The time window used to count recent account recovery attempts. If the number of attempts exceed recovery_max_attempts within this period, further attempts will be rate-limited. (Format: hours=1;minutes=2;seconds=3).") + __properties: ClassVar[List[str]] = ["name", "use_global_settings", "host", "port", "username", "password", "use_tls", "use_ssl", "timeout", "from_address", "token_expiry", "subject", "template", "activate_user_on_success", "recovery_max_attempts", "recovery_cache_timeout"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EmailStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EmailStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "use_global_settings": obj.get("use_global_settings"), + "host": obj.get("host"), + "port": obj.get("port"), + "username": obj.get("username"), + "password": obj.get("password"), + "use_tls": obj.get("use_tls"), + "use_ssl": obj.get("use_ssl"), + "timeout": obj.get("timeout"), + "from_address": obj.get("from_address"), + "token_expiry": obj.get("token_expiry"), + "subject": obj.get("subject"), + "template": obj.get("template"), + "activate_user_on_success": obj.get("activate_user_on_success"), + "recovery_max_attempts": obj.get("recovery_max_attempts"), + "recovery_cache_timeout": obj.get("recovery_cache_timeout") + }) + return _obj + + diff --git a/authentik_client/models/endpoint.py b/authentik_client/models/endpoint.py new file mode 100644 index 000000000..177b13df8 --- /dev/null +++ b/authentik_client/models/endpoint.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.endpoint_auth_mode_enum import EndpointAuthModeEnum +from authentik_client.models.protocol_enum import ProtocolEnum +from authentik_client.models.rac_provider import RACProvider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Endpoint(BaseModel): + """ + Endpoint Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + provider: StrictInt + provider_obj: RACProvider + protocol: ProtocolEnum + host: StrictStr + settings: Optional[Dict[str, Any]] = None + property_mappings: Optional[List[UUID]] = None + auth_mode: EndpointAuthModeEnum + launch_url: Optional[StrictStr] = Field(description="Build actual launch URL (the provider itself does not have one, just individual endpoints)") + maximum_connections: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + __properties: ClassVar[List[str]] = ["pk", "name", "provider", "provider_obj", "protocol", "host", "settings", "property_mappings", "auth_mode", "launch_url", "maximum_connections"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Endpoint from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "provider_obj", + "launch_url", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of provider_obj + if self.provider_obj: + _dict['provider_obj'] = self.provider_obj.to_dict() + # set to None if launch_url (nullable) is None + # and model_fields_set contains the field + if self.launch_url is None and "launch_url" in self.model_fields_set: + _dict['launch_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Endpoint from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "provider": obj.get("provider"), + "provider_obj": RACProvider.from_dict(obj["provider_obj"]) if obj.get("provider_obj") is not None else None, + "protocol": obj.get("protocol"), + "host": obj.get("host"), + "settings": obj.get("settings"), + "property_mappings": obj.get("property_mappings"), + "auth_mode": obj.get("auth_mode"), + "launch_url": obj.get("launch_url"), + "maximum_connections": obj.get("maximum_connections") + }) + return _obj + + diff --git a/authentik_client/models/endpoint_agent_challenge.py b/authentik_client/models/endpoint_agent_challenge.py new file mode 100644 index 000000000..ea88f8182 --- /dev/null +++ b/authentik_client/models/endpoint_agent_challenge.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EndpointAgentChallenge(BaseModel): + """ + Signed challenge for authentik agent to respond to + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-endpoint-agent' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + challenge: StrictStr + challenge_idle_timeout: StrictInt + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "challenge", "challenge_idle_timeout"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EndpointAgentChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EndpointAgentChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-endpoint-agent', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "challenge": obj.get("challenge"), + "challenge_idle_timeout": obj.get("challenge_idle_timeout") + }) + return _obj + + diff --git a/authentik_client/models/endpoint_agent_challenge_response_request.py b/authentik_client/models/endpoint_agent_challenge_response_request.py new file mode 100644 index 000000000..29fbc36a0 --- /dev/null +++ b/authentik_client/models/endpoint_agent_challenge_response_request.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EndpointAgentChallengeResponseRequest(BaseModel): + """ + Response to signed challenge + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-endpoint-agent' + response: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["component", "response"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EndpointAgentChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if response (nullable) is None + # and model_fields_set contains the field + if self.response is None and "response" in self.model_fields_set: + _dict['response'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EndpointAgentChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-endpoint-agent', + "response": obj.get("response") + }) + return _obj + + diff --git a/authentik_client/models/endpoint_auth_mode_enum.py b/authentik_client/models/endpoint_auth_mode_enum.py new file mode 100644 index 000000000..be8b430b3 --- /dev/null +++ b/authentik_client/models/endpoint_auth_mode_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class EndpointAuthModeEnum(str, Enum): + """ + EndpointAuthModeEnum + """ + + """ + allowed enum values + """ + STATIC = 'static' + PROMPT = 'prompt' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of EndpointAuthModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/endpoint_device.py b/authentik_client/models/endpoint_device.py new file mode 100644 index 000000000..e6bcc1aaa --- /dev/null +++ b/authentik_client/models/endpoint_device.py @@ -0,0 +1,134 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.device_access_group import DeviceAccessGroup +from authentik_client.models.device_fact_snapshot import DeviceFactSnapshot +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EndpointDevice(BaseModel): + """ + EndpointDevice + """ # noqa: E501 + device_uuid: Optional[UUID] = None + pbm_uuid: UUID + name: StrictStr + access_group: Optional[UUID] = None + access_group_obj: Optional[DeviceAccessGroup] = None + expiring: Optional[StrictBool] = None + expires: Optional[datetime] = None + facts: Optional[DeviceFactSnapshot] + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["device_uuid", "pbm_uuid", "name", "access_group", "access_group_obj", "expiring", "expires", "facts", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EndpointDevice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pbm_uuid", + "facts", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of access_group_obj + if self.access_group_obj: + _dict['access_group_obj'] = self.access_group_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of facts + if self.facts: + _dict['facts'] = self.facts.to_dict() + # set to None if access_group (nullable) is None + # and model_fields_set contains the field + if self.access_group is None and "access_group" in self.model_fields_set: + _dict['access_group'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + # set to None if facts (nullable) is None + # and model_fields_set contains the field + if self.facts is None and "facts" in self.model_fields_set: + _dict['facts'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EndpointDevice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_uuid": obj.get("device_uuid"), + "pbm_uuid": obj.get("pbm_uuid"), + "name": obj.get("name"), + "access_group": obj.get("access_group"), + "access_group_obj": DeviceAccessGroup.from_dict(obj["access_group_obj"]) if obj.get("access_group_obj") is not None else None, + "expiring": obj.get("expiring"), + "expires": obj.get("expires"), + "facts": DeviceFactSnapshot.from_dict(obj["facts"]) if obj.get("facts") is not None else None, + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/endpoint_device_details.py b/authentik_client/models/endpoint_device_details.py new file mode 100644 index 000000000..c9737c757 --- /dev/null +++ b/authentik_client/models/endpoint_device_details.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.device_access_group import DeviceAccessGroup +from authentik_client.models.device_connection import DeviceConnection +from authentik_client.models.device_fact_snapshot import DeviceFactSnapshot +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EndpointDeviceDetails(BaseModel): + """ + EndpointDeviceDetails + """ # noqa: E501 + device_uuid: Optional[UUID] = None + pbm_uuid: UUID + name: StrictStr + access_group: Optional[UUID] = None + access_group_obj: Optional[DeviceAccessGroup] = None + expiring: Optional[StrictBool] = None + expires: Optional[datetime] = None + facts: Optional[DeviceFactSnapshot] + attributes: Optional[Dict[str, Any]] = None + connections_obj: List[DeviceConnection] + policies: List[UUID] + connections: List[UUID] + __properties: ClassVar[List[str]] = ["device_uuid", "pbm_uuid", "name", "access_group", "access_group_obj", "expiring", "expires", "facts", "attributes", "connections_obj", "policies", "connections"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EndpointDeviceDetails from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pbm_uuid", + "facts", + "policies", + "connections", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of access_group_obj + if self.access_group_obj: + _dict['access_group_obj'] = self.access_group_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of facts + if self.facts: + _dict['facts'] = self.facts.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in connections_obj (list) + _items = [] + if self.connections_obj: + for _item_connections_obj in self.connections_obj: + if _item_connections_obj: + _items.append(_item_connections_obj.to_dict()) + _dict['connections_obj'] = _items + # set to None if access_group (nullable) is None + # and model_fields_set contains the field + if self.access_group is None and "access_group" in self.model_fields_set: + _dict['access_group'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + # set to None if facts (nullable) is None + # and model_fields_set contains the field + if self.facts is None and "facts" in self.model_fields_set: + _dict['facts'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EndpointDeviceDetails from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_uuid": obj.get("device_uuid"), + "pbm_uuid": obj.get("pbm_uuid"), + "name": obj.get("name"), + "access_group": obj.get("access_group"), + "access_group_obj": DeviceAccessGroup.from_dict(obj["access_group_obj"]) if obj.get("access_group_obj") is not None else None, + "expiring": obj.get("expiring"), + "expires": obj.get("expires"), + "facts": DeviceFactSnapshot.from_dict(obj["facts"]) if obj.get("facts") is not None else None, + "attributes": obj.get("attributes"), + "connections_obj": [DeviceConnection.from_dict(_item) for _item in obj["connections_obj"]] if obj.get("connections_obj") is not None else None, + "policies": obj.get("policies"), + "connections": obj.get("connections") + }) + return _obj + + diff --git a/authentik_client/models/endpoint_device_request.py b/authentik_client/models/endpoint_device_request.py new file mode 100644 index 000000000..aed181cc4 --- /dev/null +++ b/authentik_client/models/endpoint_device_request.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.device_access_group_request import DeviceAccessGroupRequest +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EndpointDeviceRequest(BaseModel): + """ + EndpointDeviceRequest + """ # noqa: E501 + device_uuid: Optional[UUID] = None + name: Annotated[str, Field(min_length=1, strict=True)] + access_group: Optional[UUID] = None + access_group_obj: Optional[DeviceAccessGroupRequest] = None + expiring: Optional[StrictBool] = None + expires: Optional[datetime] = None + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["device_uuid", "name", "access_group", "access_group_obj", "expiring", "expires", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EndpointDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of access_group_obj + if self.access_group_obj: + _dict['access_group_obj'] = self.access_group_obj.to_dict() + # set to None if access_group (nullable) is None + # and model_fields_set contains the field + if self.access_group is None and "access_group" in self.model_fields_set: + _dict['access_group'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EndpointDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_uuid": obj.get("device_uuid"), + "name": obj.get("name"), + "access_group": obj.get("access_group"), + "access_group_obj": DeviceAccessGroupRequest.from_dict(obj["access_group_obj"]) if obj.get("access_group_obj") is not None else None, + "expiring": obj.get("expiring"), + "expires": obj.get("expires"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/endpoint_request.py b/authentik_client/models/endpoint_request.py new file mode 100644 index 000000000..857b7721b --- /dev/null +++ b/authentik_client/models/endpoint_request.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.endpoint_auth_mode_enum import EndpointAuthModeEnum +from authentik_client.models.protocol_enum import ProtocolEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EndpointRequest(BaseModel): + """ + Endpoint Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + provider: StrictInt + protocol: ProtocolEnum + host: Annotated[str, Field(min_length=1, strict=True)] + settings: Optional[Dict[str, Any]] = None + property_mappings: Optional[List[UUID]] = None + auth_mode: EndpointAuthModeEnum + maximum_connections: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + __properties: ClassVar[List[str]] = ["name", "provider", "protocol", "host", "settings", "property_mappings", "auth_mode", "maximum_connections"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EndpointRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EndpointRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "provider": obj.get("provider"), + "protocol": obj.get("protocol"), + "host": obj.get("host"), + "settings": obj.get("settings"), + "property_mappings": obj.get("property_mappings"), + "auth_mode": obj.get("auth_mode"), + "maximum_connections": obj.get("maximum_connections") + }) + return _obj + + diff --git a/authentik_client/models/endpoint_stage.py b/authentik_client/models/endpoint_stage.py new file mode 100644 index 000000000..06b0c228b --- /dev/null +++ b/authentik_client/models/endpoint_stage.py @@ -0,0 +1,135 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.connector import Connector +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.stage_mode_enum import StageModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EndpointStage(BaseModel): + """ + EndpointStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + connector: UUID + connector_obj: Connector + mode: Optional[StageModeEnum] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "connector", "connector_obj", "mode"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EndpointStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + "connector_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # override the default output from pydantic by calling `to_dict()` of connector_obj + if self.connector_obj: + _dict['connector_obj'] = self.connector_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EndpointStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "connector": obj.get("connector"), + "connector_obj": Connector.from_dict(obj["connector_obj"]) if obj.get("connector_obj") is not None else None, + "mode": obj.get("mode") + }) + return _obj + + diff --git a/authentik_client/models/endpoint_stage_request.py b/authentik_client/models/endpoint_stage_request.py new file mode 100644 index 000000000..088bf624d --- /dev/null +++ b/authentik_client/models/endpoint_stage_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.stage_mode_enum import StageModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EndpointStageRequest(BaseModel): + """ + EndpointStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + connector: UUID + mode: Optional[StageModeEnum] = None + __properties: ClassVar[List[str]] = ["name", "connector", "mode"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EndpointStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EndpointStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "connector": obj.get("connector"), + "mode": obj.get("mode") + }) + return _obj + + diff --git a/authentik_client/models/enroll_request.py b/authentik_client/models/enroll_request.py new file mode 100644 index 000000000..db976c1d5 --- /dev/null +++ b/authentik_client/models/enroll_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EnrollRequest(BaseModel): + """ + Base serializer class which doesn't implement create/update methods + """ # noqa: E501 + device_serial: Annotated[str, Field(min_length=1, strict=True)] + device_name: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["device_serial", "device_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EnrollRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EnrollRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_serial": obj.get("device_serial"), + "device_name": obj.get("device_name") + }) + return _obj + + diff --git a/authentik_client/models/enrollment_token.py b/authentik_client/models/enrollment_token.py new file mode 100644 index 000000000..0b55c8e31 --- /dev/null +++ b/authentik_client/models/enrollment_token.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.device_access_group import DeviceAccessGroup +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EnrollmentToken(BaseModel): + """ + EnrollmentToken + """ # noqa: E501 + token_uuid: UUID + device_group: Optional[UUID] = None + device_group_obj: Optional[DeviceAccessGroup] + connector: UUID + name: StrictStr + expiring: Optional[StrictBool] = None + expires: Optional[datetime] = None + __properties: ClassVar[List[str]] = ["token_uuid", "device_group", "device_group_obj", "connector", "name", "expiring", "expires"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EnrollmentToken from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "token_uuid", + "device_group_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of device_group_obj + if self.device_group_obj: + _dict['device_group_obj'] = self.device_group_obj.to_dict() + # set to None if device_group (nullable) is None + # and model_fields_set contains the field + if self.device_group is None and "device_group" in self.model_fields_set: + _dict['device_group'] = None + + # set to None if device_group_obj (nullable) is None + # and model_fields_set contains the field + if self.device_group_obj is None and "device_group_obj" in self.model_fields_set: + _dict['device_group_obj'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EnrollmentToken from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "token_uuid": obj.get("token_uuid"), + "device_group": obj.get("device_group"), + "device_group_obj": DeviceAccessGroup.from_dict(obj["device_group_obj"]) if obj.get("device_group_obj") is not None else None, + "connector": obj.get("connector"), + "name": obj.get("name"), + "expiring": obj.get("expiring"), + "expires": obj.get("expires") + }) + return _obj + + diff --git a/authentik_client/models/enrollment_token_request.py b/authentik_client/models/enrollment_token_request.py new file mode 100644 index 000000000..357e74730 --- /dev/null +++ b/authentik_client/models/enrollment_token_request.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EnrollmentTokenRequest(BaseModel): + """ + EnrollmentTokenRequest + """ # noqa: E501 + device_group: Optional[UUID] = None + connector: UUID + name: Annotated[str, Field(min_length=1, strict=True)] + expiring: Optional[StrictBool] = None + expires: Optional[datetime] = None + __properties: ClassVar[List[str]] = ["device_group", "connector", "name", "expiring", "expires"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EnrollmentTokenRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if device_group (nullable) is None + # and model_fields_set contains the field + if self.device_group is None and "device_group" in self.model_fields_set: + _dict['device_group'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EnrollmentTokenRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_group": obj.get("device_group"), + "connector": obj.get("connector"), + "name": obj.get("name"), + "expiring": obj.get("expiring"), + "expires": obj.get("expires") + }) + return _obj + + diff --git a/authentik_client/models/error_detail.py b/authentik_client/models/error_detail.py new file mode 100644 index 000000000..f48c2da84 --- /dev/null +++ b/authentik_client/models/error_detail.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ErrorDetail(BaseModel): + """ + Serializer for rest_framework's error messages + """ # noqa: E501 + string: StrictStr + code: StrictStr + __properties: ClassVar[List[str]] = ["string", "code"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ErrorDetail from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ErrorDetail from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "string": obj.get("string"), + "code": obj.get("code") + }) + return _obj + + diff --git a/authentik_client/models/error_reporting_config.py b/authentik_client/models/error_reporting_config.py new file mode 100644 index 000000000..4b79fd1a5 --- /dev/null +++ b/authentik_client/models/error_reporting_config.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Union +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ErrorReportingConfig(BaseModel): + """ + Config for error reporting + """ # noqa: E501 + enabled: StrictBool + sentry_dsn: StrictStr + environment: StrictStr + send_pii: StrictBool + traces_sample_rate: Union[StrictFloat, StrictInt] + __properties: ClassVar[List[str]] = ["enabled", "sentry_dsn", "environment", "send_pii", "traces_sample_rate"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ErrorReportingConfig from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "enabled", + "sentry_dsn", + "environment", + "send_pii", + "traces_sample_rate", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ErrorReportingConfig from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "enabled": obj.get("enabled"), + "sentry_dsn": obj.get("sentry_dsn"), + "environment": obj.get("environment"), + "send_pii": obj.get("send_pii"), + "traces_sample_rate": obj.get("traces_sample_rate") + }) + return _obj + + diff --git a/authentik_client/models/event.py b/authentik_client/models/event.py new file mode 100644 index 000000000..3b216fd23 --- /dev/null +++ b/authentik_client/models/event.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.event_actions import EventActions +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Event(BaseModel): + """ + Event Serializer + """ # noqa: E501 + pk: UUID + user: Optional[Dict[str, Any]] = None + action: EventActions + app: StrictStr + context: Optional[Dict[str, Any]] = None + client_ip: Optional[StrictStr] = None + created: datetime + expires: Optional[datetime] = None + brand: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["pk", "user", "action", "app", "context", "client_ip", "created", "expires", "brand"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Event from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "created", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if client_ip (nullable) is None + # and model_fields_set contains the field + if self.client_ip is None and "client_ip" in self.model_fields_set: + _dict['client_ip'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Event from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "user": obj.get("user"), + "action": obj.get("action"), + "app": obj.get("app"), + "context": obj.get("context"), + "client_ip": obj.get("client_ip"), + "created": obj.get("created"), + "expires": obj.get("expires"), + "brand": obj.get("brand") + }) + return _obj + + diff --git a/authentik_client/models/event_actions.py b/authentik_client/models/event_actions.py new file mode 100644 index 000000000..0e87799cd --- /dev/null +++ b/authentik_client/models/event_actions.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class EventActions(str, Enum): + """ + EventActions + """ + + """ + allowed enum values + """ + LOGIN = 'login' + LOGIN_FAILED = 'login_failed' + LOGOUT = 'logout' + USER_WRITE = 'user_write' + SUSPICIOUS_REQUEST = 'suspicious_request' + PASSWORD_SET = 'password_set' + SECRET_VIEW = 'secret_view' + SECRET_ROTATE = 'secret_rotate' + INVITATION_USED = 'invitation_used' + AUTHORIZE_APPLICATION = 'authorize_application' + SOURCE_LINKED = 'source_linked' + IMPERSONATION_STARTED = 'impersonation_started' + IMPERSONATION_ENDED = 'impersonation_ended' + FLOW_EXECUTION = 'flow_execution' + POLICY_EXECUTION = 'policy_execution' + POLICY_EXCEPTION = 'policy_exception' + PROPERTY_MAPPING_EXCEPTION = 'property_mapping_exception' + SYSTEM_TASK_EXECUTION = 'system_task_execution' + SYSTEM_TASK_EXCEPTION = 'system_task_exception' + SYSTEM_EXCEPTION = 'system_exception' + CONFIGURATION_ERROR = 'configuration_error' + CONFIGURATION_WARNING = 'configuration_warning' + MODEL_CREATED = 'model_created' + MODEL_UPDATED = 'model_updated' + MODEL_DELETED = 'model_deleted' + EMAIL_SENT = 'email_sent' + UPDATE_AVAILABLE = 'update_available' + EXPORT_READY = 'export_ready' + REVIEW_INITIATED = 'review_initiated' + REVIEW_OVERDUE = 'review_overdue' + REVIEW_ATTESTED = 'review_attested' + REVIEW_COMPLETED = 'review_completed' + CUSTOM = 'custom_' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of EventActions from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/event_matcher_policy.py b/authentik_client/models/event_matcher_policy.py new file mode 100644 index 000000000..ee793ddec --- /dev/null +++ b/authentik_client/models/event_matcher_policy.py @@ -0,0 +1,154 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.app_enum import AppEnum +from authentik_client.models.event_actions import EventActions +from authentik_client.models.model_enum import ModelEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EventMatcherPolicy(BaseModel): + """ + Event Matcher Policy Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + bound_to: StrictInt = Field(description="Return objects policy is bound to") + action: Optional[EventActions] = Field(default=None, description="Match created events with this action type. When left empty, all action types will be matched.") + client_ip: Optional[StrictStr] = Field(default=None, description="Matches Event's Client IP (strict matching, for network matching use an Expression Policy)") + app: Optional[AppEnum] = Field(default=None, description="Match events created by selected application. When left empty, all applications are matched.") + model: Optional[ModelEnum] = Field(default=None, description="Match events created by selected model. When left empty, all models are matched. When an app is selected, all the application's models are matched.") + query: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["pk", "name", "execution_logging", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "bound_to", "action", "client_ip", "app", "model", "query"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EventMatcherPolicy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "bound_to", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if action (nullable) is None + # and model_fields_set contains the field + if self.action is None and "action" in self.model_fields_set: + _dict['action'] = None + + # set to None if client_ip (nullable) is None + # and model_fields_set contains the field + if self.client_ip is None and "client_ip" in self.model_fields_set: + _dict['client_ip'] = None + + # set to None if app (nullable) is None + # and model_fields_set contains the field + if self.app is None and "app" in self.model_fields_set: + _dict['app'] = None + + # set to None if model (nullable) is None + # and model_fields_set contains the field + if self.model is None and "model" in self.model_fields_set: + _dict['model'] = None + + # set to None if query (nullable) is None + # and model_fields_set contains the field + if self.query is None and "query" in self.model_fields_set: + _dict['query'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EventMatcherPolicy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "bound_to": obj.get("bound_to"), + "action": obj.get("action"), + "client_ip": obj.get("client_ip"), + "app": obj.get("app"), + "model": obj.get("model"), + "query": obj.get("query") + }) + return _obj + + diff --git a/authentik_client/models/event_matcher_policy_request.py b/authentik_client/models/event_matcher_policy_request.py new file mode 100644 index 000000000..281765a6d --- /dev/null +++ b/authentik_client/models/event_matcher_policy_request.py @@ -0,0 +1,130 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.app_enum import AppEnum +from authentik_client.models.event_actions import EventActions +from authentik_client.models.model_enum import ModelEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EventMatcherPolicyRequest(BaseModel): + """ + Event Matcher Policy Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + action: Optional[EventActions] = Field(default=None, description="Match created events with this action type. When left empty, all action types will be matched.") + client_ip: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Matches Event's Client IP (strict matching, for network matching use an Expression Policy)") + app: Optional[AppEnum] = Field(default=None, description="Match events created by selected application. When left empty, all applications are matched.") + model: Optional[ModelEnum] = Field(default=None, description="Match events created by selected model. When left empty, all models are matched. When an app is selected, all the application's models are matched.") + query: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "action", "client_ip", "app", "model", "query"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EventMatcherPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if action (nullable) is None + # and model_fields_set contains the field + if self.action is None and "action" in self.model_fields_set: + _dict['action'] = None + + # set to None if client_ip (nullable) is None + # and model_fields_set contains the field + if self.client_ip is None and "client_ip" in self.model_fields_set: + _dict['client_ip'] = None + + # set to None if app (nullable) is None + # and model_fields_set contains the field + if self.app is None and "app" in self.model_fields_set: + _dict['app'] = None + + # set to None if model (nullable) is None + # and model_fields_set contains the field + if self.model is None and "model" in self.model_fields_set: + _dict['model'] = None + + # set to None if query (nullable) is None + # and model_fields_set contains the field + if self.query is None and "query" in self.model_fields_set: + _dict['query'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EventMatcherPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "action": obj.get("action"), + "client_ip": obj.get("client_ip"), + "app": obj.get("app"), + "model": obj.get("model"), + "query": obj.get("query") + }) + return _obj + + diff --git a/authentik_client/models/event_request.py b/authentik_client/models/event_request.py new file mode 100644 index 000000000..ee82c15af --- /dev/null +++ b/authentik_client/models/event_request.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.event_actions import EventActions +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EventRequest(BaseModel): + """ + Event Serializer + """ # noqa: E501 + user: Optional[Dict[str, Any]] = None + action: EventActions + app: Annotated[str, Field(min_length=1, strict=True)] + context: Optional[Dict[str, Any]] = None + client_ip: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expires: Optional[datetime] = None + brand: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["user", "action", "app", "context", "client_ip", "expires", "brand"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EventRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if client_ip (nullable) is None + # and model_fields_set contains the field + if self.client_ip is None and "client_ip" in self.model_fields_set: + _dict['client_ip'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EventRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user": obj.get("user"), + "action": obj.get("action"), + "app": obj.get("app"), + "context": obj.get("context"), + "client_ip": obj.get("client_ip"), + "expires": obj.get("expires"), + "brand": obj.get("brand") + }) + return _obj + + diff --git a/authentik_client/models/event_stats.py b/authentik_client/models/event_stats.py new file mode 100644 index 000000000..74de0040e --- /dev/null +++ b/authentik_client/models/event_stats.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EventStats(BaseModel): + """ + Count of unique users in events and aggregated counts per specified deltas + """ # noqa: E501 + unique_users: StrictInt + count_step: Dict[str, Any] + __properties: ClassVar[List[str]] = ["unique_users", "count_step"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EventStats from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EventStats from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "unique_users": obj.get("unique_users"), + "count_step": obj.get("count_step") + }) + return _obj + + diff --git a/authentik_client/models/event_top_per_user.py b/authentik_client/models/event_top_per_user.py new file mode 100644 index 000000000..16d20401c --- /dev/null +++ b/authentik_client/models/event_top_per_user.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EventTopPerUser(BaseModel): + """ + Response object of Event's top_per_user + """ # noqa: E501 + application: Dict[str, Any] + counted_events: StrictInt + unique_users: StrictInt + __properties: ClassVar[List[str]] = ["application", "counted_events", "unique_users"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EventTopPerUser from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EventTopPerUser from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "application": obj.get("application"), + "counted_events": obj.get("counted_events"), + "unique_users": obj.get("unique_users") + }) + return _obj + + diff --git a/authentik_client/models/event_volume.py b/authentik_client/models/event_volume.py new file mode 100644 index 000000000..5a8510ed2 --- /dev/null +++ b/authentik_client/models/event_volume.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from authentik_client.models.event_actions import EventActions +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class EventVolume(BaseModel): + """ + Count of events of action created on day for a single event action + """ # noqa: E501 + action: EventActions + time: datetime + count: StrictInt + __properties: ClassVar[List[str]] = ["action", "time", "count"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of EventVolume from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of EventVolume from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "action": obj.get("action"), + "time": obj.get("time"), + "count": obj.get("count") + }) + return _obj + + diff --git a/authentik_client/models/events_requested_enum.py b/authentik_client/models/events_requested_enum.py new file mode 100644 index 000000000..a5bec30ea --- /dev/null +++ b/authentik_client/models/events_requested_enum.py @@ -0,0 +1,45 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class EventsRequestedEnum(str, Enum): + """ + EventsRequestedEnum + """ + + """ + allowed enum values + """ + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_SESSION_MINUS_REVOKED = 'https://schemas.openid.net/secevent/caep/event-type/session-revoked' + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_TOKEN_MINUS_CLAIMS_MINUS_CHANGE = 'https://schemas.openid.net/secevent/caep/event-type/token-claims-change' + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_CREDENTIAL_MINUS_CHANGE = 'https://schemas.openid.net/secevent/caep/event-type/credential-change' + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_ASSURANCE_MINUS_LEVEL_MINUS_CHANGE = 'https://schemas.openid.net/secevent/caep/event-type/assurance-level-change' + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_DEVICE_MINUS_COMPLIANCE_MINUS_CHANGE = 'https://schemas.openid.net/secevent/caep/event-type/device-compliance-change' + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_SESSION_MINUS_ESTABLISHED = 'https://schemas.openid.net/secevent/caep/event-type/session-established' + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_SESSION_MINUS_PRESENTED = 'https://schemas.openid.net/secevent/caep/event-type/session-presented' + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_RISK_MINUS_LEVEL_MINUS_CHANGE = 'https://schemas.openid.net/secevent/caep/event-type/risk-level-change' + HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_SSF_SLASH_EVENT_MINUS_TYPE_SLASH_VERIFICATION = 'https://schemas.openid.net/secevent/ssf/event-type/verification' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of EventsRequestedEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/expiring_base_grant_model.py b/authentik_client/models/expiring_base_grant_model.py new file mode 100644 index 000000000..d7ad334ab --- /dev/null +++ b/authentik_client/models/expiring_base_grant_model.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.provider import Provider +from authentik_client.models.user import User +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ExpiringBaseGrantModel(BaseModel): + """ + Serializer for BaseGrantModel and ExpiringBaseGrant + """ # noqa: E501 + pk: StrictInt + provider: Provider + user: User + is_expired: StrictBool = Field(description="Check if token is expired yet.") + expires: Optional[datetime] = None + scope: List[StrictStr] + __properties: ClassVar[List[str]] = ["pk", "provider", "user", "is_expired", "expires", "scope"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ExpiringBaseGrantModel from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "is_expired", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of provider + if self.provider: + _dict['provider'] = self.provider.to_dict() + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ExpiringBaseGrantModel from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "provider": Provider.from_dict(obj["provider"]) if obj.get("provider") is not None else None, + "user": User.from_dict(obj["user"]) if obj.get("user") is not None else None, + "is_expired": obj.get("is_expired"), + "expires": obj.get("expires"), + "scope": obj.get("scope") + }) + return _obj + + diff --git a/authentik_client/models/expression_policy.py b/authentik_client/models/expression_policy.py new file mode 100644 index 000000000..e1632843f --- /dev/null +++ b/authentik_client/models/expression_policy.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ExpressionPolicy(BaseModel): + """ + Group Membership Policy Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + bound_to: StrictInt = Field(description="Return objects policy is bound to") + expression: StrictStr + __properties: ClassVar[List[str]] = ["pk", "name", "execution_logging", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "bound_to", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ExpressionPolicy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "bound_to", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ExpressionPolicy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "bound_to": obj.get("bound_to"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/expression_policy_request.py b/authentik_client/models/expression_policy_request.py new file mode 100644 index 000000000..88dc84104 --- /dev/null +++ b/authentik_client/models/expression_policy_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ExpressionPolicyRequest(BaseModel): + """ + Group Membership Policy Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["name", "execution_logging", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ExpressionPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ExpressionPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/extra_role_object_permission.py b/authentik_client/models/extra_role_object_permission.py new file mode 100644 index 000000000..d92bae548 --- /dev/null +++ b/authentik_client/models/extra_role_object_permission.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ExtraRoleObjectPermission(BaseModel): + """ + Role permission with additional object-related data + """ # noqa: E501 + id: StrictInt + codename: StrictStr + model: StrictStr + app_label: StrictStr + object_pk: StrictStr + name: StrictStr + app_label_verbose: StrictStr = Field(description="Get app label from permission's model") + model_verbose: StrictStr = Field(description="Get model label from permission's model") + object_description: Optional[StrictStr] = Field(description="Get model description from attached model. This operation takes at least one additional query, and the description is only shown if the role has the view_ permission on the object") + __properties: ClassVar[List[str]] = ["id", "codename", "model", "app_label", "object_pk", "name", "app_label_verbose", "model_verbose", "object_description"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ExtraRoleObjectPermission from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "codename", + "model", + "app_label", + "name", + "app_label_verbose", + "model_verbose", + "object_description", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if object_description (nullable) is None + # and model_fields_set contains the field + if self.object_description is None and "object_description" in self.model_fields_set: + _dict['object_description'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ExtraRoleObjectPermission from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "codename": obj.get("codename"), + "model": obj.get("model"), + "app_label": obj.get("app_label"), + "object_pk": obj.get("object_pk"), + "name": obj.get("name"), + "app_label_verbose": obj.get("app_label_verbose"), + "model_verbose": obj.get("model_verbose"), + "object_description": obj.get("object_description") + }) + return _obj + + diff --git a/authentik_client/models/file_list.py b/authentik_client/models/file_list.py new file mode 100644 index 000000000..2d6bdcb1b --- /dev/null +++ b/authentik_client/models/file_list.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.themed_urls import ThemedUrls +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FileList(BaseModel): + """ + Base serializer class which doesn't implement create/update methods + """ # noqa: E501 + name: StrictStr + mime_type: StrictStr + url: StrictStr + themed_urls: Optional[ThemedUrls] = None + __properties: ClassVar[List[str]] = ["name", "mime_type", "url", "themed_urls"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FileList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of themed_urls + if self.themed_urls: + _dict['themed_urls'] = self.themed_urls.to_dict() + # set to None if themed_urls (nullable) is None + # and model_fields_set contains the field + if self.themed_urls is None and "themed_urls" in self.model_fields_set: + _dict['themed_urls'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FileList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "mime_type": obj.get("mime_type"), + "url": obj.get("url"), + "themed_urls": ThemedUrls.from_dict(obj["themed_urls"]) if obj.get("themed_urls") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/fleet_connector.py b/authentik_client/models/fleet_connector.py new file mode 100644 index 000000000..1e7291999 --- /dev/null +++ b/authentik_client/models/fleet_connector.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FleetConnector(BaseModel): + """ + FleetConnector Serializer + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: StrictStr + enabled: Optional[StrictBool] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + url: Annotated[str, Field(strict=True, max_length=200)] + headers_mapping: Optional[UUID] = Field(default=None, description="Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs") + map_users: Optional[StrictBool] = None + map_teams_access_group: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "url", "headers_mapping", "map_users", "map_teams_access_group"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FleetConnector from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if headers_mapping (nullable) is None + # and model_fields_set contains the field + if self.headers_mapping is None and "headers_mapping" in self.model_fields_set: + _dict['headers_mapping'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FleetConnector from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "url": obj.get("url"), + "headers_mapping": obj.get("headers_mapping"), + "map_users": obj.get("map_users"), + "map_teams_access_group": obj.get("map_teams_access_group") + }) + return _obj + + diff --git a/authentik_client/models/fleet_connector_request.py b/authentik_client/models/fleet_connector_request.py new file mode 100644 index 000000000..4c5cf59eb --- /dev/null +++ b/authentik_client/models/fleet_connector_request.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FleetConnectorRequest(BaseModel): + """ + FleetConnector Serializer + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: Annotated[str, Field(min_length=1, strict=True)] + enabled: Optional[StrictBool] = None + url: Annotated[str, Field(min_length=1, strict=True, max_length=200)] + token: Annotated[str, Field(min_length=1, strict=True)] + headers_mapping: Optional[UUID] = Field(default=None, description="Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs") + map_users: Optional[StrictBool] = None + map_teams_access_group: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "url", "token", "headers_mapping", "map_users", "map_teams_access_group"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FleetConnectorRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if headers_mapping (nullable) is None + # and model_fields_set contains the field + if self.headers_mapping is None and "headers_mapping" in self.model_fields_set: + _dict['headers_mapping'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FleetConnectorRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "url": obj.get("url"), + "token": obj.get("token"), + "headers_mapping": obj.get("headers_mapping"), + "map_users": obj.get("map_users"), + "map_teams_access_group": obj.get("map_teams_access_group") + }) + return _obj + + diff --git a/authentik_client/models/flow.py b/authentik_client/models/flow.py new file mode 100644 index 000000000..d476ac10b --- /dev/null +++ b/authentik_client/models/flow.py @@ -0,0 +1,165 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.authentication_enum import AuthenticationEnum +from authentik_client.models.denied_action_enum import DeniedActionEnum +from authentik_client.models.flow_designation_enum import FlowDesignationEnum +from authentik_client.models.flow_layout_enum import FlowLayoutEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.themed_urls import ThemedUrls +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Flow(BaseModel): + """ + Flow Serializer + """ # noqa: E501 + pk: UUID + policybindingmodel_ptr_id: UUID + name: StrictStr + slug: Annotated[str, Field(strict=True)] = Field(description="Visible in the URL.") + title: StrictStr = Field(description="Shown as the Title in Flow pages.") + designation: FlowDesignationEnum = Field(description="Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik.") + background: Optional[StrictStr] = Field(default=None, description="Background shown during execution") + background_url: StrictStr = Field(description="Get the URL to the background image") + background_themed_urls: Optional[ThemedUrls] + stages: List[UUID] + policies: List[UUID] + cache_count: StrictInt = Field(description="Get count of cached flows") + policy_engine_mode: Optional[PolicyEngineMode] = None + compatibility_mode: Optional[StrictBool] = Field(default=None, description="Enable compatibility mode, increases compatibility with password managers on mobile devices.") + export_url: StrictStr = Field(description="Get export URL for flow") + layout: Optional[FlowLayoutEnum] = None + denied_action: Optional[DeniedActionEnum] = Field(default=None, description="Configure what should happen when a flow denies access to a user.") + authentication: Optional[AuthenticationEnum] = Field(default=None, description="Required level of authentication and authorization to access a flow.") + __properties: ClassVar[List[str]] = ["pk", "policybindingmodel_ptr_id", "name", "slug", "title", "designation", "background", "background_url", "background_themed_urls", "stages", "policies", "cache_count", "policy_engine_mode", "compatibility_mode", "export_url", "layout", "denied_action", "authentication"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Flow from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "policybindingmodel_ptr_id", + "background_url", + "background_themed_urls", + "stages", + "policies", + "cache_count", + "export_url", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of background_themed_urls + if self.background_themed_urls: + _dict['background_themed_urls'] = self.background_themed_urls.to_dict() + # set to None if background_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.background_themed_urls is None and "background_themed_urls" in self.model_fields_set: + _dict['background_themed_urls'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Flow from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "policybindingmodel_ptr_id": obj.get("policybindingmodel_ptr_id"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "title": obj.get("title"), + "designation": obj.get("designation"), + "background": obj.get("background"), + "background_url": obj.get("background_url"), + "background_themed_urls": ThemedUrls.from_dict(obj["background_themed_urls"]) if obj.get("background_themed_urls") is not None else None, + "stages": obj.get("stages"), + "policies": obj.get("policies"), + "cache_count": obj.get("cache_count"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "compatibility_mode": obj.get("compatibility_mode"), + "export_url": obj.get("export_url"), + "layout": obj.get("layout"), + "denied_action": obj.get("denied_action"), + "authentication": obj.get("authentication") + }) + return _obj + + diff --git a/authentik_client/models/flow_challenge_response_request.py b/authentik_client/models/flow_challenge_response_request.py new file mode 100644 index 000000000..c28f7ab44 --- /dev/null +++ b/authentik_client/models/flow_challenge_response_request.py @@ -0,0 +1,477 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +import pprint +from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator +from typing import Any, List, Optional +from authentik_client.models.apple_challenge_response_request import AppleChallengeResponseRequest +from authentik_client.models.authenticator_duo_challenge_response_request import AuthenticatorDuoChallengeResponseRequest +from authentik_client.models.authenticator_email_challenge_response_request import AuthenticatorEmailChallengeResponseRequest +from authentik_client.models.authenticator_sms_challenge_response_request import AuthenticatorSMSChallengeResponseRequest +from authentik_client.models.authenticator_static_challenge_response_request import AuthenticatorStaticChallengeResponseRequest +from authentik_client.models.authenticator_totp_challenge_response_request import AuthenticatorTOTPChallengeResponseRequest +from authentik_client.models.authenticator_validation_challenge_response_request import AuthenticatorValidationChallengeResponseRequest +from authentik_client.models.authenticator_web_authn_challenge_response_request import AuthenticatorWebAuthnChallengeResponseRequest +from authentik_client.models.auto_submit_challenge_response_request import AutoSubmitChallengeResponseRequest +from authentik_client.models.captcha_challenge_response_request import CaptchaChallengeResponseRequest +from authentik_client.models.consent_challenge_response_request import ConsentChallengeResponseRequest +from authentik_client.models.dummy_challenge_response_request import DummyChallengeResponseRequest +from authentik_client.models.email_challenge_response_request import EmailChallengeResponseRequest +from authentik_client.models.endpoint_agent_challenge_response_request import EndpointAgentChallengeResponseRequest +from authentik_client.models.frame_challenge_response_request import FrameChallengeResponseRequest +from authentik_client.models.identification_challenge_response_request import IdentificationChallengeResponseRequest +from authentik_client.models.iframe_logout_challenge_response_request import IframeLogoutChallengeResponseRequest +from authentik_client.models.native_logout_challenge_response_request import NativeLogoutChallengeResponseRequest +from authentik_client.models.o_auth_device_code_challenge_response_request import OAuthDeviceCodeChallengeResponseRequest +from authentik_client.models.o_auth_device_code_finish_challenge_response_request import OAuthDeviceCodeFinishChallengeResponseRequest +from authentik_client.models.password_challenge_response_request import PasswordChallengeResponseRequest +from authentik_client.models.plex_authentication_challenge_response_request import PlexAuthenticationChallengeResponseRequest +from authentik_client.models.prompt_challenge_response_request import PromptChallengeResponseRequest +from authentik_client.models.redirect_challenge_response_request import RedirectChallengeResponseRequest +from authentik_client.models.telegram_challenge_response_request import TelegramChallengeResponseRequest +from authentik_client.models.user_login_challenge_response_request import UserLoginChallengeResponseRequest +from pydantic import StrictStr, Field +from typing import Union, List, Set, Optional, Dict +from typing_extensions import Literal, Self + +FLOWCHALLENGERESPONSEREQUEST_ONE_OF_SCHEMAS = ["AppleChallengeResponseRequest", "AuthenticatorDuoChallengeResponseRequest", "AuthenticatorEmailChallengeResponseRequest", "AuthenticatorSMSChallengeResponseRequest", "AuthenticatorStaticChallengeResponseRequest", "AuthenticatorTOTPChallengeResponseRequest", "AuthenticatorValidationChallengeResponseRequest", "AuthenticatorWebAuthnChallengeResponseRequest", "AutoSubmitChallengeResponseRequest", "CaptchaChallengeResponseRequest", "ConsentChallengeResponseRequest", "DummyChallengeResponseRequest", "EmailChallengeResponseRequest", "EndpointAgentChallengeResponseRequest", "FrameChallengeResponseRequest", "IdentificationChallengeResponseRequest", "IframeLogoutChallengeResponseRequest", "NativeLogoutChallengeResponseRequest", "OAuthDeviceCodeChallengeResponseRequest", "OAuthDeviceCodeFinishChallengeResponseRequest", "PasswordChallengeResponseRequest", "PlexAuthenticationChallengeResponseRequest", "PromptChallengeResponseRequest", "RedirectChallengeResponseRequest", "TelegramChallengeResponseRequest", "UserLoginChallengeResponseRequest"] + +class FlowChallengeResponseRequest(BaseModel): + """ + FlowChallengeResponseRequest + """ + # data type: AppleChallengeResponseRequest + oneof_schema_1_validator: Optional[AppleChallengeResponseRequest] = None + # data type: AuthenticatorDuoChallengeResponseRequest + oneof_schema_2_validator: Optional[AuthenticatorDuoChallengeResponseRequest] = None + # data type: AuthenticatorEmailChallengeResponseRequest + oneof_schema_3_validator: Optional[AuthenticatorEmailChallengeResponseRequest] = None + # data type: AuthenticatorSMSChallengeResponseRequest + oneof_schema_4_validator: Optional[AuthenticatorSMSChallengeResponseRequest] = None + # data type: AuthenticatorStaticChallengeResponseRequest + oneof_schema_5_validator: Optional[AuthenticatorStaticChallengeResponseRequest] = None + # data type: AuthenticatorTOTPChallengeResponseRequest + oneof_schema_6_validator: Optional[AuthenticatorTOTPChallengeResponseRequest] = None + # data type: AuthenticatorValidationChallengeResponseRequest + oneof_schema_7_validator: Optional[AuthenticatorValidationChallengeResponseRequest] = None + # data type: AuthenticatorWebAuthnChallengeResponseRequest + oneof_schema_8_validator: Optional[AuthenticatorWebAuthnChallengeResponseRequest] = None + # data type: AutoSubmitChallengeResponseRequest + oneof_schema_9_validator: Optional[AutoSubmitChallengeResponseRequest] = None + # data type: CaptchaChallengeResponseRequest + oneof_schema_10_validator: Optional[CaptchaChallengeResponseRequest] = None + # data type: ConsentChallengeResponseRequest + oneof_schema_11_validator: Optional[ConsentChallengeResponseRequest] = None + # data type: DummyChallengeResponseRequest + oneof_schema_12_validator: Optional[DummyChallengeResponseRequest] = None + # data type: EmailChallengeResponseRequest + oneof_schema_13_validator: Optional[EmailChallengeResponseRequest] = None + # data type: EndpointAgentChallengeResponseRequest + oneof_schema_14_validator: Optional[EndpointAgentChallengeResponseRequest] = None + # data type: FrameChallengeResponseRequest + oneof_schema_15_validator: Optional[FrameChallengeResponseRequest] = None + # data type: IdentificationChallengeResponseRequest + oneof_schema_16_validator: Optional[IdentificationChallengeResponseRequest] = None + # data type: IframeLogoutChallengeResponseRequest + oneof_schema_17_validator: Optional[IframeLogoutChallengeResponseRequest] = None + # data type: NativeLogoutChallengeResponseRequest + oneof_schema_18_validator: Optional[NativeLogoutChallengeResponseRequest] = None + # data type: OAuthDeviceCodeChallengeResponseRequest + oneof_schema_19_validator: Optional[OAuthDeviceCodeChallengeResponseRequest] = None + # data type: OAuthDeviceCodeFinishChallengeResponseRequest + oneof_schema_20_validator: Optional[OAuthDeviceCodeFinishChallengeResponseRequest] = None + # data type: PasswordChallengeResponseRequest + oneof_schema_21_validator: Optional[PasswordChallengeResponseRequest] = None + # data type: PlexAuthenticationChallengeResponseRequest + oneof_schema_22_validator: Optional[PlexAuthenticationChallengeResponseRequest] = None + # data type: PromptChallengeResponseRequest + oneof_schema_23_validator: Optional[PromptChallengeResponseRequest] = None + # data type: RedirectChallengeResponseRequest + oneof_schema_24_validator: Optional[RedirectChallengeResponseRequest] = None + # data type: TelegramChallengeResponseRequest + oneof_schema_25_validator: Optional[TelegramChallengeResponseRequest] = None + # data type: UserLoginChallengeResponseRequest + oneof_schema_26_validator: Optional[UserLoginChallengeResponseRequest] = None + actual_instance: Optional[Union[AppleChallengeResponseRequest, AuthenticatorDuoChallengeResponseRequest, AuthenticatorEmailChallengeResponseRequest, AuthenticatorSMSChallengeResponseRequest, AuthenticatorStaticChallengeResponseRequest, AuthenticatorTOTPChallengeResponseRequest, AuthenticatorValidationChallengeResponseRequest, AuthenticatorWebAuthnChallengeResponseRequest, AutoSubmitChallengeResponseRequest, CaptchaChallengeResponseRequest, ConsentChallengeResponseRequest, DummyChallengeResponseRequest, EmailChallengeResponseRequest, EndpointAgentChallengeResponseRequest, FrameChallengeResponseRequest, IdentificationChallengeResponseRequest, IframeLogoutChallengeResponseRequest, NativeLogoutChallengeResponseRequest, OAuthDeviceCodeChallengeResponseRequest, OAuthDeviceCodeFinishChallengeResponseRequest, PasswordChallengeResponseRequest, PlexAuthenticationChallengeResponseRequest, PromptChallengeResponseRequest, RedirectChallengeResponseRequest, TelegramChallengeResponseRequest, UserLoginChallengeResponseRequest]] = None + one_of_schemas: Set[str] = { "AppleChallengeResponseRequest", "AuthenticatorDuoChallengeResponseRequest", "AuthenticatorEmailChallengeResponseRequest", "AuthenticatorSMSChallengeResponseRequest", "AuthenticatorStaticChallengeResponseRequest", "AuthenticatorTOTPChallengeResponseRequest", "AuthenticatorValidationChallengeResponseRequest", "AuthenticatorWebAuthnChallengeResponseRequest", "AutoSubmitChallengeResponseRequest", "CaptchaChallengeResponseRequest", "ConsentChallengeResponseRequest", "DummyChallengeResponseRequest", "EmailChallengeResponseRequest", "EndpointAgentChallengeResponseRequest", "FrameChallengeResponseRequest", "IdentificationChallengeResponseRequest", "IframeLogoutChallengeResponseRequest", "NativeLogoutChallengeResponseRequest", "OAuthDeviceCodeChallengeResponseRequest", "OAuthDeviceCodeFinishChallengeResponseRequest", "PasswordChallengeResponseRequest", "PlexAuthenticationChallengeResponseRequest", "PromptChallengeResponseRequest", "RedirectChallengeResponseRequest", "TelegramChallengeResponseRequest", "UserLoginChallengeResponseRequest" } + + model_config = ConfigDict( + validate_assignment=True, + protected_namespaces=(), + ) + + + discriminator_value_class_map: Dict[str, str] = { + } + + def __init__(self, *args, **kwargs) -> None: + if args: + if len(args) > 1: + raise ValueError("If a position argument is used, only 1 is allowed to set `actual_instance`") + if kwargs: + raise ValueError("If a position argument is used, keyword arguments cannot be used.") + super().__init__(actual_instance=args[0]) + else: + super().__init__(**kwargs) + + @field_validator('actual_instance') + def actual_instance_must_validate_oneof(cls, v): + instance = FlowChallengeResponseRequest.model_construct() + error_messages = [] + match = 0 + # validate data type: AppleChallengeResponseRequest + if not isinstance(v, AppleChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `AppleChallengeResponseRequest`") + else: + match += 1 + # validate data type: AuthenticatorDuoChallengeResponseRequest + if not isinstance(v, AuthenticatorDuoChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorDuoChallengeResponseRequest`") + else: + match += 1 + # validate data type: AuthenticatorEmailChallengeResponseRequest + if not isinstance(v, AuthenticatorEmailChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorEmailChallengeResponseRequest`") + else: + match += 1 + # validate data type: AuthenticatorSMSChallengeResponseRequest + if not isinstance(v, AuthenticatorSMSChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorSMSChallengeResponseRequest`") + else: + match += 1 + # validate data type: AuthenticatorStaticChallengeResponseRequest + if not isinstance(v, AuthenticatorStaticChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorStaticChallengeResponseRequest`") + else: + match += 1 + # validate data type: AuthenticatorTOTPChallengeResponseRequest + if not isinstance(v, AuthenticatorTOTPChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorTOTPChallengeResponseRequest`") + else: + match += 1 + # validate data type: AuthenticatorValidationChallengeResponseRequest + if not isinstance(v, AuthenticatorValidationChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorValidationChallengeResponseRequest`") + else: + match += 1 + # validate data type: AuthenticatorWebAuthnChallengeResponseRequest + if not isinstance(v, AuthenticatorWebAuthnChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `AuthenticatorWebAuthnChallengeResponseRequest`") + else: + match += 1 + # validate data type: AutoSubmitChallengeResponseRequest + if not isinstance(v, AutoSubmitChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `AutoSubmitChallengeResponseRequest`") + else: + match += 1 + # validate data type: CaptchaChallengeResponseRequest + if not isinstance(v, CaptchaChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `CaptchaChallengeResponseRequest`") + else: + match += 1 + # validate data type: ConsentChallengeResponseRequest + if not isinstance(v, ConsentChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `ConsentChallengeResponseRequest`") + else: + match += 1 + # validate data type: DummyChallengeResponseRequest + if not isinstance(v, DummyChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `DummyChallengeResponseRequest`") + else: + match += 1 + # validate data type: EmailChallengeResponseRequest + if not isinstance(v, EmailChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `EmailChallengeResponseRequest`") + else: + match += 1 + # validate data type: EndpointAgentChallengeResponseRequest + if not isinstance(v, EndpointAgentChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `EndpointAgentChallengeResponseRequest`") + else: + match += 1 + # validate data type: FrameChallengeResponseRequest + if not isinstance(v, FrameChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `FrameChallengeResponseRequest`") + else: + match += 1 + # validate data type: IdentificationChallengeResponseRequest + if not isinstance(v, IdentificationChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `IdentificationChallengeResponseRequest`") + else: + match += 1 + # validate data type: IframeLogoutChallengeResponseRequest + if not isinstance(v, IframeLogoutChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `IframeLogoutChallengeResponseRequest`") + else: + match += 1 + # validate data type: NativeLogoutChallengeResponseRequest + if not isinstance(v, NativeLogoutChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `NativeLogoutChallengeResponseRequest`") + else: + match += 1 + # validate data type: OAuthDeviceCodeChallengeResponseRequest + if not isinstance(v, OAuthDeviceCodeChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `OAuthDeviceCodeChallengeResponseRequest`") + else: + match += 1 + # validate data type: OAuthDeviceCodeFinishChallengeResponseRequest + if not isinstance(v, OAuthDeviceCodeFinishChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `OAuthDeviceCodeFinishChallengeResponseRequest`") + else: + match += 1 + # validate data type: PasswordChallengeResponseRequest + if not isinstance(v, PasswordChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `PasswordChallengeResponseRequest`") + else: + match += 1 + # validate data type: PlexAuthenticationChallengeResponseRequest + if not isinstance(v, PlexAuthenticationChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `PlexAuthenticationChallengeResponseRequest`") + else: + match += 1 + # validate data type: PromptChallengeResponseRequest + if not isinstance(v, PromptChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `PromptChallengeResponseRequest`") + else: + match += 1 + # validate data type: RedirectChallengeResponseRequest + if not isinstance(v, RedirectChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `RedirectChallengeResponseRequest`") + else: + match += 1 + # validate data type: TelegramChallengeResponseRequest + if not isinstance(v, TelegramChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `TelegramChallengeResponseRequest`") + else: + match += 1 + # validate data type: UserLoginChallengeResponseRequest + if not isinstance(v, UserLoginChallengeResponseRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `UserLoginChallengeResponseRequest`") + else: + match += 1 + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when setting `actual_instance` in FlowChallengeResponseRequest with oneOf schemas: AppleChallengeResponseRequest, AuthenticatorDuoChallengeResponseRequest, AuthenticatorEmailChallengeResponseRequest, AuthenticatorSMSChallengeResponseRequest, AuthenticatorStaticChallengeResponseRequest, AuthenticatorTOTPChallengeResponseRequest, AuthenticatorValidationChallengeResponseRequest, AuthenticatorWebAuthnChallengeResponseRequest, AutoSubmitChallengeResponseRequest, CaptchaChallengeResponseRequest, ConsentChallengeResponseRequest, DummyChallengeResponseRequest, EmailChallengeResponseRequest, EndpointAgentChallengeResponseRequest, FrameChallengeResponseRequest, IdentificationChallengeResponseRequest, IframeLogoutChallengeResponseRequest, NativeLogoutChallengeResponseRequest, OAuthDeviceCodeChallengeResponseRequest, OAuthDeviceCodeFinishChallengeResponseRequest, PasswordChallengeResponseRequest, PlexAuthenticationChallengeResponseRequest, PromptChallengeResponseRequest, RedirectChallengeResponseRequest, TelegramChallengeResponseRequest, UserLoginChallengeResponseRequest. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when setting `actual_instance` in FlowChallengeResponseRequest with oneOf schemas: AppleChallengeResponseRequest, AuthenticatorDuoChallengeResponseRequest, AuthenticatorEmailChallengeResponseRequest, AuthenticatorSMSChallengeResponseRequest, AuthenticatorStaticChallengeResponseRequest, AuthenticatorTOTPChallengeResponseRequest, AuthenticatorValidationChallengeResponseRequest, AuthenticatorWebAuthnChallengeResponseRequest, AutoSubmitChallengeResponseRequest, CaptchaChallengeResponseRequest, ConsentChallengeResponseRequest, DummyChallengeResponseRequest, EmailChallengeResponseRequest, EndpointAgentChallengeResponseRequest, FrameChallengeResponseRequest, IdentificationChallengeResponseRequest, IframeLogoutChallengeResponseRequest, NativeLogoutChallengeResponseRequest, OAuthDeviceCodeChallengeResponseRequest, OAuthDeviceCodeFinishChallengeResponseRequest, PasswordChallengeResponseRequest, PlexAuthenticationChallengeResponseRequest, PromptChallengeResponseRequest, RedirectChallengeResponseRequest, TelegramChallengeResponseRequest, UserLoginChallengeResponseRequest. Details: " + ", ".join(error_messages)) + else: + return v + + @classmethod + def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self: + return cls.from_json(json.dumps(obj)) + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Returns the object represented by the json string""" + instance = cls.model_construct() + error_messages = [] + match = 0 + + # deserialize data into AppleChallengeResponseRequest + try: + instance.actual_instance = AppleChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorDuoChallengeResponseRequest + try: + instance.actual_instance = AuthenticatorDuoChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorEmailChallengeResponseRequest + try: + instance.actual_instance = AuthenticatorEmailChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorSMSChallengeResponseRequest + try: + instance.actual_instance = AuthenticatorSMSChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorStaticChallengeResponseRequest + try: + instance.actual_instance = AuthenticatorStaticChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorTOTPChallengeResponseRequest + try: + instance.actual_instance = AuthenticatorTOTPChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorValidationChallengeResponseRequest + try: + instance.actual_instance = AuthenticatorValidationChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AuthenticatorWebAuthnChallengeResponseRequest + try: + instance.actual_instance = AuthenticatorWebAuthnChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AutoSubmitChallengeResponseRequest + try: + instance.actual_instance = AutoSubmitChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into CaptchaChallengeResponseRequest + try: + instance.actual_instance = CaptchaChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into ConsentChallengeResponseRequest + try: + instance.actual_instance = ConsentChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into DummyChallengeResponseRequest + try: + instance.actual_instance = DummyChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into EmailChallengeResponseRequest + try: + instance.actual_instance = EmailChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into EndpointAgentChallengeResponseRequest + try: + instance.actual_instance = EndpointAgentChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into FrameChallengeResponseRequest + try: + instance.actual_instance = FrameChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into IdentificationChallengeResponseRequest + try: + instance.actual_instance = IdentificationChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into IframeLogoutChallengeResponseRequest + try: + instance.actual_instance = IframeLogoutChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into NativeLogoutChallengeResponseRequest + try: + instance.actual_instance = NativeLogoutChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into OAuthDeviceCodeChallengeResponseRequest + try: + instance.actual_instance = OAuthDeviceCodeChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into OAuthDeviceCodeFinishChallengeResponseRequest + try: + instance.actual_instance = OAuthDeviceCodeFinishChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into PasswordChallengeResponseRequest + try: + instance.actual_instance = PasswordChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into PlexAuthenticationChallengeResponseRequest + try: + instance.actual_instance = PlexAuthenticationChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into PromptChallengeResponseRequest + try: + instance.actual_instance = PromptChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into RedirectChallengeResponseRequest + try: + instance.actual_instance = RedirectChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into TelegramChallengeResponseRequest + try: + instance.actual_instance = TelegramChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into UserLoginChallengeResponseRequest + try: + instance.actual_instance = UserLoginChallengeResponseRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when deserializing the JSON string into FlowChallengeResponseRequest with oneOf schemas: AppleChallengeResponseRequest, AuthenticatorDuoChallengeResponseRequest, AuthenticatorEmailChallengeResponseRequest, AuthenticatorSMSChallengeResponseRequest, AuthenticatorStaticChallengeResponseRequest, AuthenticatorTOTPChallengeResponseRequest, AuthenticatorValidationChallengeResponseRequest, AuthenticatorWebAuthnChallengeResponseRequest, AutoSubmitChallengeResponseRequest, CaptchaChallengeResponseRequest, ConsentChallengeResponseRequest, DummyChallengeResponseRequest, EmailChallengeResponseRequest, EndpointAgentChallengeResponseRequest, FrameChallengeResponseRequest, IdentificationChallengeResponseRequest, IframeLogoutChallengeResponseRequest, NativeLogoutChallengeResponseRequest, OAuthDeviceCodeChallengeResponseRequest, OAuthDeviceCodeFinishChallengeResponseRequest, PasswordChallengeResponseRequest, PlexAuthenticationChallengeResponseRequest, PromptChallengeResponseRequest, RedirectChallengeResponseRequest, TelegramChallengeResponseRequest, UserLoginChallengeResponseRequest. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when deserializing the JSON string into FlowChallengeResponseRequest with oneOf schemas: AppleChallengeResponseRequest, AuthenticatorDuoChallengeResponseRequest, AuthenticatorEmailChallengeResponseRequest, AuthenticatorSMSChallengeResponseRequest, AuthenticatorStaticChallengeResponseRequest, AuthenticatorTOTPChallengeResponseRequest, AuthenticatorValidationChallengeResponseRequest, AuthenticatorWebAuthnChallengeResponseRequest, AutoSubmitChallengeResponseRequest, CaptchaChallengeResponseRequest, ConsentChallengeResponseRequest, DummyChallengeResponseRequest, EmailChallengeResponseRequest, EndpointAgentChallengeResponseRequest, FrameChallengeResponseRequest, IdentificationChallengeResponseRequest, IframeLogoutChallengeResponseRequest, NativeLogoutChallengeResponseRequest, OAuthDeviceCodeChallengeResponseRequest, OAuthDeviceCodeFinishChallengeResponseRequest, PasswordChallengeResponseRequest, PlexAuthenticationChallengeResponseRequest, PromptChallengeResponseRequest, RedirectChallengeResponseRequest, TelegramChallengeResponseRequest, UserLoginChallengeResponseRequest. Details: " + ", ".join(error_messages)) + else: + return instance + + def to_json(self) -> str: + """Returns the JSON representation of the actual instance""" + if self.actual_instance is None: + return "null" + + if hasattr(self.actual_instance, "to_json") and callable(self.actual_instance.to_json): + return self.actual_instance.to_json() + else: + return json.dumps(self.actual_instance) + + def to_dict(self) -> Optional[Union[Dict[str, Any], AppleChallengeResponseRequest, AuthenticatorDuoChallengeResponseRequest, AuthenticatorEmailChallengeResponseRequest, AuthenticatorSMSChallengeResponseRequest, AuthenticatorStaticChallengeResponseRequest, AuthenticatorTOTPChallengeResponseRequest, AuthenticatorValidationChallengeResponseRequest, AuthenticatorWebAuthnChallengeResponseRequest, AutoSubmitChallengeResponseRequest, CaptchaChallengeResponseRequest, ConsentChallengeResponseRequest, DummyChallengeResponseRequest, EmailChallengeResponseRequest, EndpointAgentChallengeResponseRequest, FrameChallengeResponseRequest, IdentificationChallengeResponseRequest, IframeLogoutChallengeResponseRequest, NativeLogoutChallengeResponseRequest, OAuthDeviceCodeChallengeResponseRequest, OAuthDeviceCodeFinishChallengeResponseRequest, PasswordChallengeResponseRequest, PlexAuthenticationChallengeResponseRequest, PromptChallengeResponseRequest, RedirectChallengeResponseRequest, TelegramChallengeResponseRequest, UserLoginChallengeResponseRequest]]: + """Returns the dict representation of the actual instance""" + if self.actual_instance is None: + return None + + if hasattr(self.actual_instance, "to_dict") and callable(self.actual_instance.to_dict): + return self.actual_instance.to_dict() + else: + # primitive type + return self.actual_instance + + def to_str(self) -> str: + """Returns the string representation of the actual instance""" + return pprint.pformat(self.model_dump()) + + diff --git a/authentik_client/models/flow_designation_enum.py b/authentik_client/models/flow_designation_enum.py new file mode 100644 index 000000000..b76051d3e --- /dev/null +++ b/authentik_client/models/flow_designation_enum.py @@ -0,0 +1,43 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class FlowDesignationEnum(str, Enum): + """ + FlowDesignationEnum + """ + + """ + allowed enum values + """ + AUTHENTICATION = 'authentication' + AUTHORIZATION = 'authorization' + INVALIDATION = 'invalidation' + ENROLLMENT = 'enrollment' + UNENROLLMENT = 'unenrollment' + RECOVERY = 'recovery' + STAGE_CONFIGURATION = 'stage_configuration' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of FlowDesignationEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/flow_diagram.py b/authentik_client/models/flow_diagram.py new file mode 100644 index 000000000..c2e36a633 --- /dev/null +++ b/authentik_client/models/flow_diagram.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FlowDiagram(BaseModel): + """ + response of the flow's diagram action + """ # noqa: E501 + diagram: StrictStr + __properties: ClassVar[List[str]] = ["diagram"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FlowDiagram from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "diagram", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FlowDiagram from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "diagram": obj.get("diagram") + }) + return _obj + + diff --git a/authentik_client/models/flow_error_challenge.py b/authentik_client/models/flow_error_challenge.py new file mode 100644 index 000000000..70fb8bfdb --- /dev/null +++ b/authentik_client/models/flow_error_challenge.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FlowErrorChallenge(BaseModel): + """ + Challenge class when an unhandled error occurs during a stage. Normal users are shown an error message, superusers are shown a full stacktrace. + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-flow-error' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + request_id: StrictStr + error: Optional[StrictStr] = None + traceback: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "request_id", "error", "traceback"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FlowErrorChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FlowErrorChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-flow-error', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "request_id": obj.get("request_id"), + "error": obj.get("error"), + "traceback": obj.get("traceback") + }) + return _obj + + diff --git a/authentik_client/models/flow_inspection.py b/authentik_client/models/flow_inspection.py new file mode 100644 index 000000000..f10c2ad7a --- /dev/null +++ b/authentik_client/models/flow_inspection.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.flow_inspector_plan import FlowInspectorPlan +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FlowInspection(BaseModel): + """ + Serializer for inspect endpoint + """ # noqa: E501 + plans: List[FlowInspectorPlan] + current_plan: Optional[FlowInspectorPlan] = None + is_completed: StrictBool + __properties: ClassVar[List[str]] = ["plans", "current_plan", "is_completed"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FlowInspection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in plans (list) + _items = [] + if self.plans: + for _item_plans in self.plans: + if _item_plans: + _items.append(_item_plans.to_dict()) + _dict['plans'] = _items + # override the default output from pydantic by calling `to_dict()` of current_plan + if self.current_plan: + _dict['current_plan'] = self.current_plan.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FlowInspection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "plans": [FlowInspectorPlan.from_dict(_item) for _item in obj["plans"]] if obj.get("plans") is not None else None, + "current_plan": FlowInspectorPlan.from_dict(obj["current_plan"]) if obj.get("current_plan") is not None else None, + "is_completed": obj.get("is_completed") + }) + return _obj + + diff --git a/authentik_client/models/flow_inspector_plan.py b/authentik_client/models/flow_inspector_plan.py new file mode 100644 index 000000000..47c0c9bf8 --- /dev/null +++ b/authentik_client/models/flow_inspector_plan.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List +from authentik_client.models.flow_stage_binding import FlowStageBinding +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FlowInspectorPlan(BaseModel): + """ + Serializer for an active FlowPlan + """ # noqa: E501 + current_stage: FlowStageBinding + next_planned_stage: FlowStageBinding + plan_context: Dict[str, Any] = Field(description="Get the plan's context, sanitized") + session_id: StrictStr = Field(description="Get a unique session ID") + __properties: ClassVar[List[str]] = ["current_stage", "next_planned_stage", "plan_context", "session_id"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FlowInspectorPlan from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "current_stage", + "next_planned_stage", + "plan_context", + "session_id", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of current_stage + if self.current_stage: + _dict['current_stage'] = self.current_stage.to_dict() + # override the default output from pydantic by calling `to_dict()` of next_planned_stage + if self.next_planned_stage: + _dict['next_planned_stage'] = self.next_planned_stage.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FlowInspectorPlan from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "current_stage": FlowStageBinding.from_dict(obj["current_stage"]) if obj.get("current_stage") is not None else None, + "next_planned_stage": FlowStageBinding.from_dict(obj["next_planned_stage"]) if obj.get("next_planned_stage") is not None else None, + "plan_context": obj.get("plan_context"), + "session_id": obj.get("session_id") + }) + return _obj + + diff --git a/authentik_client/models/flow_layout_enum.py b/authentik_client/models/flow_layout_enum.py new file mode 100644 index 000000000..fb82da5e6 --- /dev/null +++ b/authentik_client/models/flow_layout_enum.py @@ -0,0 +1,43 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class FlowLayoutEnum(str, Enum): + """ + FlowLayoutEnum + """ + + """ + allowed enum values + """ + STACKED = 'stacked' + CONTENT_LEFT = 'content_left' + CONTENT_RIGHT = 'content_right' + SIDEBAR_LEFT = 'sidebar_left' + SIDEBAR_RIGHT = 'sidebar_right' + SIDEBAR_LEFT_FRAME_BACKGROUND = 'sidebar_left_frame_background' + SIDEBAR_RIGHT_FRAME_BACKGROUND = 'sidebar_right_frame_background' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of FlowLayoutEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/flow_request.py b/authentik_client/models/flow_request.py new file mode 100644 index 000000000..c9cadde33 --- /dev/null +++ b/authentik_client/models/flow_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.authentication_enum import AuthenticationEnum +from authentik_client.models.denied_action_enum import DeniedActionEnum +from authentik_client.models.flow_designation_enum import FlowDesignationEnum +from authentik_client.models.flow_layout_enum import FlowLayoutEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FlowRequest(BaseModel): + """ + Flow Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + slug: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Visible in the URL.") + title: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Shown as the Title in Flow pages.") + designation: FlowDesignationEnum = Field(description="Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik.") + background: Optional[StrictStr] = Field(default=None, description="Background shown during execution") + policy_engine_mode: Optional[PolicyEngineMode] = None + compatibility_mode: Optional[StrictBool] = Field(default=None, description="Enable compatibility mode, increases compatibility with password managers on mobile devices.") + layout: Optional[FlowLayoutEnum] = None + denied_action: Optional[DeniedActionEnum] = Field(default=None, description="Configure what should happen when a flow denies access to a user.") + authentication: Optional[AuthenticationEnum] = Field(default=None, description="Required level of authentication and authorization to access a flow.") + __properties: ClassVar[List[str]] = ["name", "slug", "title", "designation", "background", "policy_engine_mode", "compatibility_mode", "layout", "denied_action", "authentication"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FlowRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FlowRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "title": obj.get("title"), + "designation": obj.get("designation"), + "background": obj.get("background"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "compatibility_mode": obj.get("compatibility_mode"), + "layout": obj.get("layout"), + "denied_action": obj.get("denied_action"), + "authentication": obj.get("authentication") + }) + return _obj + + diff --git a/authentik_client/models/flow_set.py b/authentik_client/models/flow_set.py new file mode 100644 index 000000000..f332ba703 --- /dev/null +++ b/authentik_client/models/flow_set.py @@ -0,0 +1,135 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.denied_action_enum import DeniedActionEnum +from authentik_client.models.flow_designation_enum import FlowDesignationEnum +from authentik_client.models.flow_layout_enum import FlowLayoutEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FlowSet(BaseModel): + """ + Stripped down flow serializer + """ # noqa: E501 + pk: UUID + policybindingmodel_ptr_id: UUID + name: StrictStr + slug: Annotated[str, Field(strict=True)] = Field(description="Visible in the URL.") + title: StrictStr = Field(description="Shown as the Title in Flow pages.") + designation: FlowDesignationEnum = Field(description="Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik.") + background_url: StrictStr = Field(description="Get the URL to the background image") + policy_engine_mode: Optional[PolicyEngineMode] = None + compatibility_mode: Optional[StrictBool] = Field(default=None, description="Enable compatibility mode, increases compatibility with password managers on mobile devices.") + export_url: StrictStr = Field(description="Get export URL for flow") + layout: Optional[FlowLayoutEnum] = None + denied_action: Optional[DeniedActionEnum] = Field(default=None, description="Configure what should happen when a flow denies access to a user.") + __properties: ClassVar[List[str]] = ["pk", "policybindingmodel_ptr_id", "name", "slug", "title", "designation", "background_url", "policy_engine_mode", "compatibility_mode", "export_url", "layout", "denied_action"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FlowSet from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "policybindingmodel_ptr_id", + "background_url", + "export_url", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FlowSet from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "policybindingmodel_ptr_id": obj.get("policybindingmodel_ptr_id"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "title": obj.get("title"), + "designation": obj.get("designation"), + "background_url": obj.get("background_url"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "compatibility_mode": obj.get("compatibility_mode"), + "export_url": obj.get("export_url"), + "layout": obj.get("layout"), + "denied_action": obj.get("denied_action") + }) + return _obj + + diff --git a/authentik_client/models/flow_stage_binding.py b/authentik_client/models/flow_stage_binding.py new file mode 100644 index 000000000..6b9a7500d --- /dev/null +++ b/authentik_client/models/flow_stage_binding.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.invalid_response_action_enum import InvalidResponseActionEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.stage import Stage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FlowStageBinding(BaseModel): + """ + FlowStageBinding Serializer + """ # noqa: E501 + pk: UUID + policybindingmodel_ptr_id: UUID + target: UUID + stage: UUID + stage_obj: Stage + evaluate_on_plan: Optional[StrictBool] = Field(default=None, description="Evaluate policies during the Flow planning process.") + re_evaluate_policies: Optional[StrictBool] = Field(default=None, description="Evaluate policies when the Stage is presented to the user.") + order: Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)] + policy_engine_mode: Optional[PolicyEngineMode] = None + invalid_response_action: Optional[InvalidResponseActionEnum] = Field(default=None, description="Configure how the flow executor should handle an invalid response to a challenge. RETRY returns the error message and a similar challenge to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT restarts the flow while keeping the current context.") + __properties: ClassVar[List[str]] = ["pk", "policybindingmodel_ptr_id", "target", "stage", "stage_obj", "evaluate_on_plan", "re_evaluate_policies", "order", "policy_engine_mode", "invalid_response_action"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FlowStageBinding from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "policybindingmodel_ptr_id", + "stage_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of stage_obj + if self.stage_obj: + _dict['stage_obj'] = self.stage_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FlowStageBinding from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "policybindingmodel_ptr_id": obj.get("policybindingmodel_ptr_id"), + "target": obj.get("target"), + "stage": obj.get("stage"), + "stage_obj": Stage.from_dict(obj["stage_obj"]) if obj.get("stage_obj") is not None else None, + "evaluate_on_plan": obj.get("evaluate_on_plan"), + "re_evaluate_policies": obj.get("re_evaluate_policies"), + "order": obj.get("order"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "invalid_response_action": obj.get("invalid_response_action") + }) + return _obj + + diff --git a/authentik_client/models/flow_stage_binding_request.py b/authentik_client/models/flow_stage_binding_request.py new file mode 100644 index 000000000..ac94094cf --- /dev/null +++ b/authentik_client/models/flow_stage_binding_request.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.invalid_response_action_enum import InvalidResponseActionEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FlowStageBindingRequest(BaseModel): + """ + FlowStageBinding Serializer + """ # noqa: E501 + target: UUID + stage: UUID + evaluate_on_plan: Optional[StrictBool] = Field(default=None, description="Evaluate policies during the Flow planning process.") + re_evaluate_policies: Optional[StrictBool] = Field(default=None, description="Evaluate policies when the Stage is presented to the user.") + order: Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)] + policy_engine_mode: Optional[PolicyEngineMode] = None + invalid_response_action: Optional[InvalidResponseActionEnum] = Field(default=None, description="Configure how the flow executor should handle an invalid response to a challenge. RETRY returns the error message and a similar challenge to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT restarts the flow while keeping the current context.") + __properties: ClassVar[List[str]] = ["target", "stage", "evaluate_on_plan", "re_evaluate_policies", "order", "policy_engine_mode", "invalid_response_action"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FlowStageBindingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FlowStageBindingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "target": obj.get("target"), + "stage": obj.get("stage"), + "evaluate_on_plan": obj.get("evaluate_on_plan"), + "re_evaluate_policies": obj.get("re_evaluate_policies"), + "order": obj.get("order"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "invalid_response_action": obj.get("invalid_response_action") + }) + return _obj + + diff --git a/authentik_client/models/footer_link.py b/authentik_client/models/footer_link.py new file mode 100644 index 000000000..d1a28e3c9 --- /dev/null +++ b/authentik_client/models/footer_link.py @@ -0,0 +1,100 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FooterLink(BaseModel): + """ + Links returned in Config API + """ # noqa: E501 + href: Optional[StrictStr] + name: StrictStr + __properties: ClassVar[List[str]] = ["href", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FooterLink from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "href", + "name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if href (nullable) is None + # and model_fields_set contains the field + if self.href is None and "href" in self.model_fields_set: + _dict['href'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FooterLink from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "href": obj.get("href"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/force_binding_enum.py b/authentik_client/models/force_binding_enum.py new file mode 100644 index 000000000..f71eeac89 --- /dev/null +++ b/authentik_client/models/force_binding_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ForceBindingEnum(str, Enum): + """ + ForceBindingEnum + """ + + """ + allowed enum values + """ + URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_BINDINGS_COLON_HTTP_MINUS_POST = 'urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST' + URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_BINDINGS_COLON_HTTP_MINUS_REDIRECT = 'urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ForceBindingEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/format_enum.py b/authentik_client/models/format_enum.py new file mode 100644 index 000000000..90b189dde --- /dev/null +++ b/authentik_client/models/format_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class FormatEnum(str, Enum): + """ + FormatEnum + """ + + """ + allowed enum values + """ + JSON = 'json' + YAML = 'yaml' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of FormatEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/frame_challenge.py b/authentik_client/models/frame_challenge.py new file mode 100644 index 000000000..19bef7f89 --- /dev/null +++ b/authentik_client/models/frame_challenge.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FrameChallenge(BaseModel): + """ + Challenge type to render a frame + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'xak-flow-frame' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + url: StrictStr + loading_overlay: Optional[StrictBool] = False + loading_text: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "url", "loading_overlay", "loading_text"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FrameChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FrameChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'xak-flow-frame', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "url": obj.get("url"), + "loading_overlay": obj.get("loading_overlay") if obj.get("loading_overlay") is not None else False, + "loading_text": obj.get("loading_text") + }) + return _obj + + diff --git a/authentik_client/models/frame_challenge_response_request.py b/authentik_client/models/frame_challenge_response_request.py new file mode 100644 index 000000000..4ff41dbcb --- /dev/null +++ b/authentik_client/models/frame_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class FrameChallengeResponseRequest(BaseModel): + """ + Base class for all challenge responses + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'xak-flow-frame' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of FrameChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of FrameChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'xak-flow-frame' + }) + return _obj + + diff --git a/authentik_client/models/generic_error.py b/authentik_client/models/generic_error.py new file mode 100644 index 000000000..679b0e3d3 --- /dev/null +++ b/authentik_client/models/generic_error.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GenericError(BaseModel): + """ + Generic API Error + """ # noqa: E501 + detail: StrictStr + code: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["detail", "code"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GenericError from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GenericError from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "detail": obj.get("detail"), + "code": obj.get("code") + }) + return _obj + + diff --git a/authentik_client/models/geo_ip_policy.py b/authentik_client/models/geo_ip_policy.py new file mode 100644 index 000000000..5df900839 --- /dev/null +++ b/authentik_client/models/geo_ip_policy.py @@ -0,0 +1,146 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.country_code_enum import CountryCodeEnum +from authentik_client.models.geo_ip_policy_countries_obj_inner import GeoIPPolicyCountriesObjInner +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GeoIPPolicy(BaseModel): + """ + GeoIP Policy Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + bound_to: StrictInt = Field(description="Return objects policy is bound to") + asns: Optional[List[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]]] = None + countries: Annotated[List[CountryCodeEnum], Field(max_length=249)] + countries_obj: List[GeoIPPolicyCountriesObjInner] + check_history_distance: Optional[StrictBool] = None + history_max_distance_km: Optional[Annotated[int, Field(le=9223372036854775807, strict=True, ge=0)]] = None + distance_tolerance_km: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + history_login_count: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + check_impossible_travel: Optional[StrictBool] = None + impossible_tolerance_km: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + __properties: ClassVar[List[str]] = ["pk", "name", "execution_logging", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "bound_to", "asns", "countries", "countries_obj", "check_history_distance", "history_max_distance_km", "distance_tolerance_km", "history_login_count", "check_impossible_travel", "impossible_tolerance_km"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GeoIPPolicy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "bound_to", + "countries_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in countries_obj (list) + _items = [] + if self.countries_obj: + for _item_countries_obj in self.countries_obj: + if _item_countries_obj: + _items.append(_item_countries_obj.to_dict()) + _dict['countries_obj'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GeoIPPolicy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "bound_to": obj.get("bound_to"), + "asns": obj.get("asns"), + "countries": obj.get("countries"), + "countries_obj": [GeoIPPolicyCountriesObjInner.from_dict(_item) for _item in obj["countries_obj"]] if obj.get("countries_obj") is not None else None, + "check_history_distance": obj.get("check_history_distance"), + "history_max_distance_km": obj.get("history_max_distance_km"), + "distance_tolerance_km": obj.get("distance_tolerance_km"), + "history_login_count": obj.get("history_login_count"), + "check_impossible_travel": obj.get("check_impossible_travel"), + "impossible_tolerance_km": obj.get("impossible_tolerance_km") + }) + return _obj + + diff --git a/authentik_client/models/geo_ip_policy_countries_obj_inner.py b/authentik_client/models/geo_ip_policy_countries_obj_inner.py new file mode 100644 index 000000000..12ef179a8 --- /dev/null +++ b/authentik_client/models/geo_ip_policy_countries_obj_inner.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GeoIPPolicyCountriesObjInner(BaseModel): + """ + GeoIPPolicyCountriesObjInner + """ # noqa: E501 + code: Annotated[str, Field(min_length=2, strict=True, max_length=2)] + name: StrictStr + __properties: ClassVar[List[str]] = ["code", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GeoIPPolicyCountriesObjInner from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GeoIPPolicyCountriesObjInner from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "code": obj.get("code"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/geo_ip_policy_request.py b/authentik_client/models/geo_ip_policy_request.py new file mode 100644 index 000000000..b7b9e615d --- /dev/null +++ b/authentik_client/models/geo_ip_policy_request.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.country_code_enum import CountryCodeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GeoIPPolicyRequest(BaseModel): + """ + GeoIP Policy Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + asns: Optional[List[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]]] = None + countries: Annotated[List[CountryCodeEnum], Field(max_length=249)] + check_history_distance: Optional[StrictBool] = None + history_max_distance_km: Optional[Annotated[int, Field(le=9223372036854775807, strict=True, ge=0)]] = None + distance_tolerance_km: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + history_login_count: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + check_impossible_travel: Optional[StrictBool] = None + impossible_tolerance_km: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "asns", "countries", "check_history_distance", "history_max_distance_km", "distance_tolerance_km", "history_login_count", "check_impossible_travel", "impossible_tolerance_km"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GeoIPPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GeoIPPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "asns": obj.get("asns"), + "countries": obj.get("countries"), + "check_history_distance": obj.get("check_history_distance"), + "history_max_distance_km": obj.get("history_max_distance_km"), + "distance_tolerance_km": obj.get("distance_tolerance_km"), + "history_login_count": obj.get("history_login_count"), + "check_impossible_travel": obj.get("check_impossible_travel"), + "impossible_tolerance_km": obj.get("impossible_tolerance_km") + }) + return _obj + + diff --git a/authentik_client/models/geoip_binding_enum.py b/authentik_client/models/geoip_binding_enum.py new file mode 100644 index 000000000..e8a0a7771 --- /dev/null +++ b/authentik_client/models/geoip_binding_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class GeoipBindingEnum(str, Enum): + """ + GeoipBindingEnum + """ + + """ + allowed enum values + """ + NO_BINDING = 'no_binding' + BIND_CONTINENT = 'bind_continent' + BIND_CONTINENT_COUNTRY = 'bind_continent_country' + BIND_CONTINENT_COUNTRY_CITY = 'bind_continent_country_city' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of GeoipBindingEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/global_task_status.py b/authentik_client/models/global_task_status.py new file mode 100644 index 000000000..85fe76be0 --- /dev/null +++ b/authentik_client/models/global_task_status.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GlobalTaskStatus(BaseModel): + """ + GlobalTaskStatus + """ # noqa: E501 + queued: StrictInt + consumed: StrictInt + preprocess: StrictInt + running: StrictInt + postprocess: StrictInt + rejected: StrictInt + done: StrictInt + info: StrictInt + warning: StrictInt + error: StrictInt + __properties: ClassVar[List[str]] = ["queued", "consumed", "preprocess", "running", "postprocess", "rejected", "done", "info", "warning", "error"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GlobalTaskStatus from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "queued", + "consumed", + "preprocess", + "running", + "postprocess", + "rejected", + "done", + "info", + "warning", + "error", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GlobalTaskStatus from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "queued": obj.get("queued"), + "consumed": obj.get("consumed"), + "preprocess": obj.get("preprocess"), + "running": obj.get("running"), + "postprocess": obj.get("postprocess"), + "rejected": obj.get("rejected"), + "done": obj.get("done"), + "info": obj.get("info"), + "warning": obj.get("warning"), + "error": obj.get("error") + }) + return _obj + + diff --git a/authentik_client/models/google_chrome_connector.py b/authentik_client/models/google_chrome_connector.py new file mode 100644 index 000000000..be809db3f --- /dev/null +++ b/authentik_client/models/google_chrome_connector.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleChromeConnector(BaseModel): + """ + GoogleChromeConnector Serializer + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: StrictStr + enabled: Optional[StrictBool] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + credentials: Dict[str, Any] + chrome_url: Optional[StrictStr] = Field(description="Full URL to be used in Google Workspace configuration") + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "credentials", "chrome_url"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleChromeConnector from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "chrome_url", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if chrome_url (nullable) is None + # and model_fields_set contains the field + if self.chrome_url is None and "chrome_url" in self.model_fields_set: + _dict['chrome_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleChromeConnector from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "credentials": obj.get("credentials"), + "chrome_url": obj.get("chrome_url") + }) + return _obj + + diff --git a/authentik_client/models/google_chrome_connector_request.py b/authentik_client/models/google_chrome_connector_request.py new file mode 100644 index 000000000..da464dc66 --- /dev/null +++ b/authentik_client/models/google_chrome_connector_request.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleChromeConnectorRequest(BaseModel): + """ + GoogleChromeConnector Serializer + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: Annotated[str, Field(min_length=1, strict=True)] + enabled: Optional[StrictBool] = None + credentials: Dict[str, Any] + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "credentials"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleChromeConnectorRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleChromeConnectorRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "credentials": obj.get("credentials") + }) + return _obj + + diff --git a/authentik_client/models/google_endpoint_device.py b/authentik_client/models/google_endpoint_device.py new file mode 100644 index 000000000..e2a1efe54 --- /dev/null +++ b/authentik_client/models/google_endpoint_device.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleEndpointDevice(BaseModel): + """ + Serializer for Endpoint authenticator devices + """ # noqa: E501 + pk: Optional[UUID] = None + name: Annotated[str, Field(strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["pk", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleEndpointDevice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleEndpointDevice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/google_endpoint_device_request.py b/authentik_client/models/google_endpoint_device_request.py new file mode 100644 index 000000000..53a16f1f3 --- /dev/null +++ b/authentik_client/models/google_endpoint_device_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleEndpointDeviceRequest(BaseModel): + """ + Serializer for Endpoint authenticator devices + """ # noqa: E501 + pk: Optional[UUID] = None + name: Annotated[str, Field(min_length=1, strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["pk", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleEndpointDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleEndpointDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/google_workspace_provider.py b/authentik_client/models/google_workspace_provider.py new file mode 100644 index 000000000..1114c7990 --- /dev/null +++ b/authentik_client/models/google_workspace_provider.py @@ -0,0 +1,161 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.outgoing_sync_delete_action import OutgoingSyncDeleteAction +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleWorkspaceProvider(BaseModel): + """ + GoogleWorkspaceProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + property_mappings: Optional[List[UUID]] = None + property_mappings_group: Optional[List[UUID]] = Field(default=None, description="Property mappings used for group creation/updating.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + delegated_subject: Annotated[str, Field(strict=True, max_length=254)] + credentials: Dict[str, Any] + scopes: Optional[StrictStr] = None + exclude_users_service_account: Optional[StrictBool] = None + filter_group: Optional[UUID] = None + user_delete_action: Optional[OutgoingSyncDeleteAction] = None + group_delete_action: Optional[OutgoingSyncDeleteAction] = None + default_group_email_domain: StrictStr + sync_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Controls the number of objects synced in a single task") + sync_page_timeout: Optional[StrictStr] = Field(default=None, description="Timeout for synchronization of a single page") + dry_run: Optional[StrictBool] = Field(default=None, description="When enabled, provider will not modify or create objects in the remote system.") + __properties: ClassVar[List[str]] = ["pk", "name", "property_mappings", "property_mappings_group", "component", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "delegated_subject", "credentials", "scopes", "exclude_users_service_account", "filter_group", "user_delete_action", "group_delete_action", "default_group_email_domain", "sync_page_size", "sync_page_timeout", "dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + # set to None if filter_group (nullable) is None + # and model_fields_set contains the field + if self.filter_group is None and "filter_group" in self.model_fields_set: + _dict['filter_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "property_mappings": obj.get("property_mappings"), + "property_mappings_group": obj.get("property_mappings_group"), + "component": obj.get("component"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "delegated_subject": obj.get("delegated_subject"), + "credentials": obj.get("credentials"), + "scopes": obj.get("scopes"), + "exclude_users_service_account": obj.get("exclude_users_service_account"), + "filter_group": obj.get("filter_group"), + "user_delete_action": obj.get("user_delete_action"), + "group_delete_action": obj.get("group_delete_action"), + "default_group_email_domain": obj.get("default_group_email_domain"), + "sync_page_size": obj.get("sync_page_size"), + "sync_page_timeout": obj.get("sync_page_timeout"), + "dry_run": obj.get("dry_run") + }) + return _obj + + diff --git a/authentik_client/models/google_workspace_provider_group.py b/authentik_client/models/google_workspace_provider_group.py new file mode 100644 index 000000000..95b0ef4d8 --- /dev/null +++ b/authentik_client/models/google_workspace_provider_group.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.partial_group import PartialGroup +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleWorkspaceProviderGroup(BaseModel): + """ + GoogleWorkspaceProviderGroup Serializer + """ # noqa: E501 + id: UUID + google_id: StrictStr + group: UUID + group_obj: PartialGroup + provider: StrictInt + attributes: Dict[str, Any] + __properties: ClassVar[List[str]] = ["id", "google_id", "group", "group_obj", "provider", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderGroup from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "group_obj", + "attributes", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of group_obj + if self.group_obj: + _dict['group_obj'] = self.group_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderGroup from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "google_id": obj.get("google_id"), + "group": obj.get("group"), + "group_obj": PartialGroup.from_dict(obj["group_obj"]) if obj.get("group_obj") is not None else None, + "provider": obj.get("provider"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/google_workspace_provider_group_request.py b/authentik_client/models/google_workspace_provider_group_request.py new file mode 100644 index 000000000..76b229fbc --- /dev/null +++ b/authentik_client/models/google_workspace_provider_group_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleWorkspaceProviderGroupRequest(BaseModel): + """ + GoogleWorkspaceProviderGroup Serializer + """ # noqa: E501 + google_id: Annotated[str, Field(min_length=1, strict=True)] + group: UUID + provider: StrictInt + __properties: ClassVar[List[str]] = ["google_id", "group", "provider"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderGroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderGroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "google_id": obj.get("google_id"), + "group": obj.get("group"), + "provider": obj.get("provider") + }) + return _obj + + diff --git a/authentik_client/models/google_workspace_provider_mapping.py b/authentik_client/models/google_workspace_provider_mapping.py new file mode 100644 index 000000000..314814703 --- /dev/null +++ b/authentik_client/models/google_workspace_provider_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleWorkspaceProviderMapping(BaseModel): + """ + GoogleWorkspaceProviderMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/google_workspace_provider_mapping_request.py b/authentik_client/models/google_workspace_provider_mapping_request.py new file mode 100644 index 000000000..281a96f98 --- /dev/null +++ b/authentik_client/models/google_workspace_provider_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleWorkspaceProviderMappingRequest(BaseModel): + """ + GoogleWorkspaceProviderMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/google_workspace_provider_request.py b/authentik_client/models/google_workspace_provider_request.py new file mode 100644 index 000000000..bae32c285 --- /dev/null +++ b/authentik_client/models/google_workspace_provider_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.outgoing_sync_delete_action import OutgoingSyncDeleteAction +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleWorkspaceProviderRequest(BaseModel): + """ + GoogleWorkspaceProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + property_mappings: Optional[List[UUID]] = None + property_mappings_group: Optional[List[UUID]] = Field(default=None, description="Property mappings used for group creation/updating.") + delegated_subject: Annotated[str, Field(min_length=1, strict=True, max_length=254)] + credentials: Dict[str, Any] + scopes: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + exclude_users_service_account: Optional[StrictBool] = None + filter_group: Optional[UUID] = None + user_delete_action: Optional[OutgoingSyncDeleteAction] = None + group_delete_action: Optional[OutgoingSyncDeleteAction] = None + default_group_email_domain: Annotated[str, Field(min_length=1, strict=True)] + sync_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Controls the number of objects synced in a single task") + sync_page_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Timeout for synchronization of a single page") + dry_run: Optional[StrictBool] = Field(default=None, description="When enabled, provider will not modify or create objects in the remote system.") + __properties: ClassVar[List[str]] = ["name", "property_mappings", "property_mappings_group", "delegated_subject", "credentials", "scopes", "exclude_users_service_account", "filter_group", "user_delete_action", "group_delete_action", "default_group_email_domain", "sync_page_size", "sync_page_timeout", "dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if filter_group (nullable) is None + # and model_fields_set contains the field + if self.filter_group is None and "filter_group" in self.model_fields_set: + _dict['filter_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "property_mappings": obj.get("property_mappings"), + "property_mappings_group": obj.get("property_mappings_group"), + "delegated_subject": obj.get("delegated_subject"), + "credentials": obj.get("credentials"), + "scopes": obj.get("scopes"), + "exclude_users_service_account": obj.get("exclude_users_service_account"), + "filter_group": obj.get("filter_group"), + "user_delete_action": obj.get("user_delete_action"), + "group_delete_action": obj.get("group_delete_action"), + "default_group_email_domain": obj.get("default_group_email_domain"), + "sync_page_size": obj.get("sync_page_size"), + "sync_page_timeout": obj.get("sync_page_timeout"), + "dry_run": obj.get("dry_run") + }) + return _obj + + diff --git a/authentik_client/models/google_workspace_provider_user.py b/authentik_client/models/google_workspace_provider_user.py new file mode 100644 index 000000000..832f159ed --- /dev/null +++ b/authentik_client/models/google_workspace_provider_user.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleWorkspaceProviderUser(BaseModel): + """ + GoogleWorkspaceProviderUser Serializer + """ # noqa: E501 + id: UUID + google_id: StrictStr + user: StrictInt + user_obj: PartialUser + provider: StrictInt + attributes: Dict[str, Any] + __properties: ClassVar[List[str]] = ["id", "google_id", "user", "user_obj", "provider", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderUser from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "user_obj", + "attributes", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user_obj + if self.user_obj: + _dict['user_obj'] = self.user_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderUser from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "google_id": obj.get("google_id"), + "user": obj.get("user"), + "user_obj": PartialUser.from_dict(obj["user_obj"]) if obj.get("user_obj") is not None else None, + "provider": obj.get("provider"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/google_workspace_provider_user_request.py b/authentik_client/models/google_workspace_provider_user_request.py new file mode 100644 index 000000000..b5694f1df --- /dev/null +++ b/authentik_client/models/google_workspace_provider_user_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GoogleWorkspaceProviderUserRequest(BaseModel): + """ + GoogleWorkspaceProviderUser Serializer + """ # noqa: E501 + google_id: Annotated[str, Field(min_length=1, strict=True)] + user: StrictInt + provider: StrictInt + __properties: ClassVar[List[str]] = ["google_id", "user", "provider"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderUserRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GoogleWorkspaceProviderUserRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "google_id": obj.get("google_id"), + "user": obj.get("user"), + "provider": obj.get("provider") + }) + return _obj + + diff --git a/authentik_client/models/grant_types_enum.py b/authentik_client/models/grant_types_enum.py new file mode 100644 index 000000000..f620960c7 --- /dev/null +++ b/authentik_client/models/grant_types_enum.py @@ -0,0 +1,43 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class GrantTypesEnum(str, Enum): + """ + GrantTypesEnum + """ + + """ + allowed enum values + """ + AUTHORIZATION_CODE = 'authorization_code' + IMPLICIT = 'implicit' + HYBRID = 'hybrid' + REFRESH_TOKEN = 'refresh_token' + CLIENT_CREDENTIALS = 'client_credentials' + PASSWORD = 'password' + URN_COLON_IETF_COLON_PARAMS_COLON_OAUTH_COLON_GRANT_MINUS_TYPE_COLON_DEVICE_CODE = 'urn:ietf:params:oauth:grant-type:device_code' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of GrantTypesEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/group.py b/authentik_client/models/group.py new file mode 100644 index 000000000..96865de2c --- /dev/null +++ b/authentik_client/models/group.py @@ -0,0 +1,190 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.partial_user import PartialUser +from authentik_client.models.related_group import RelatedGroup +from authentik_client.models.role import Role +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Group(BaseModel): + """ + Group Serializer + """ # noqa: E501 + pk: UUID + num_pk: StrictInt + name: StrictStr + is_superuser: Optional[StrictBool] = Field(default=None, description="Users added to this group will be superusers.") + parents: Optional[List[UUID]] = None + parents_obj: Optional[List[RelatedGroup]] + users: Optional[List[StrictInt]] = None + users_obj: Optional[List[PartialUser]] + attributes: Optional[Dict[str, Any]] = None + roles: Optional[List[UUID]] = None + roles_obj: List[Role] + inherited_roles_obj: Optional[List[Role]] + children: List[UUID] + children_obj: Optional[List[RelatedGroup]] + __properties: ClassVar[List[str]] = ["pk", "num_pk", "name", "is_superuser", "parents", "parents_obj", "users", "users_obj", "attributes", "roles", "roles_obj", "inherited_roles_obj", "children", "children_obj"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Group from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "num_pk", + "parents_obj", + "users_obj", + "roles_obj", + "inherited_roles_obj", + "children", + "children_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in parents_obj (list) + _items = [] + if self.parents_obj: + for _item_parents_obj in self.parents_obj: + if _item_parents_obj: + _items.append(_item_parents_obj.to_dict()) + _dict['parents_obj'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in users_obj (list) + _items = [] + if self.users_obj: + for _item_users_obj in self.users_obj: + if _item_users_obj: + _items.append(_item_users_obj.to_dict()) + _dict['users_obj'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in roles_obj (list) + _items = [] + if self.roles_obj: + for _item_roles_obj in self.roles_obj: + if _item_roles_obj: + _items.append(_item_roles_obj.to_dict()) + _dict['roles_obj'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in inherited_roles_obj (list) + _items = [] + if self.inherited_roles_obj: + for _item_inherited_roles_obj in self.inherited_roles_obj: + if _item_inherited_roles_obj: + _items.append(_item_inherited_roles_obj.to_dict()) + _dict['inherited_roles_obj'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in children_obj (list) + _items = [] + if self.children_obj: + for _item_children_obj in self.children_obj: + if _item_children_obj: + _items.append(_item_children_obj.to_dict()) + _dict['children_obj'] = _items + # set to None if parents_obj (nullable) is None + # and model_fields_set contains the field + if self.parents_obj is None and "parents_obj" in self.model_fields_set: + _dict['parents_obj'] = None + + # set to None if users_obj (nullable) is None + # and model_fields_set contains the field + if self.users_obj is None and "users_obj" in self.model_fields_set: + _dict['users_obj'] = None + + # set to None if inherited_roles_obj (nullable) is None + # and model_fields_set contains the field + if self.inherited_roles_obj is None and "inherited_roles_obj" in self.model_fields_set: + _dict['inherited_roles_obj'] = None + + # set to None if children_obj (nullable) is None + # and model_fields_set contains the field + if self.children_obj is None and "children_obj" in self.model_fields_set: + _dict['children_obj'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Group from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "num_pk": obj.get("num_pk"), + "name": obj.get("name"), + "is_superuser": obj.get("is_superuser"), + "parents": obj.get("parents"), + "parents_obj": [RelatedGroup.from_dict(_item) for _item in obj["parents_obj"]] if obj.get("parents_obj") is not None else None, + "users": obj.get("users"), + "users_obj": [PartialUser.from_dict(_item) for _item in obj["users_obj"]] if obj.get("users_obj") is not None else None, + "attributes": obj.get("attributes"), + "roles": obj.get("roles"), + "roles_obj": [Role.from_dict(_item) for _item in obj["roles_obj"]] if obj.get("roles_obj") is not None else None, + "inherited_roles_obj": [Role.from_dict(_item) for _item in obj["inherited_roles_obj"]] if obj.get("inherited_roles_obj") is not None else None, + "children": obj.get("children"), + "children_obj": [RelatedGroup.from_dict(_item) for _item in obj["children_obj"]] if obj.get("children_obj") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/group_kerberos_source_connection.py b/authentik_client/models/group_kerberos_source_connection.py new file mode 100644 index 000000000..d81bf36bd --- /dev/null +++ b/authentik_client/models/group_kerberos_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupKerberosSourceConnection(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + pk: StrictInt + group: UUID + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "group", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupKerberosSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "group", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupKerberosSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "group": obj.get("group"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/group_kerberos_source_connection_request.py b/authentik_client/models/group_kerberos_source_connection_request.py new file mode 100644 index 000000000..580f1d3ea --- /dev/null +++ b/authentik_client/models/group_kerberos_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupKerberosSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupKerberosSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupKerberosSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/group_ldap_source_connection.py b/authentik_client/models/group_ldap_source_connection.py new file mode 100644 index 000000000..1f6473143 --- /dev/null +++ b/authentik_client/models/group_ldap_source_connection.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.partial_group import PartialGroup +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupLDAPSourceConnection(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + pk: StrictInt + group: UUID + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + group_obj: PartialGroup + __properties: ClassVar[List[str]] = ["pk", "group", "source", "source_obj", "identifier", "created", "last_updated", "group_obj"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupLDAPSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "group", + "source_obj", + "created", + "last_updated", + "group_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of group_obj + if self.group_obj: + _dict['group_obj'] = self.group_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupLDAPSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "group": obj.get("group"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated"), + "group_obj": PartialGroup.from_dict(obj["group_obj"]) if obj.get("group_obj") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/group_ldap_source_connection_request.py b/authentik_client/models/group_ldap_source_connection_request.py new file mode 100644 index 000000000..a9adeadd2 --- /dev/null +++ b/authentik_client/models/group_ldap_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupLDAPSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupLDAPSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupLDAPSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/group_matching_mode_enum.py b/authentik_client/models/group_matching_mode_enum.py new file mode 100644 index 000000000..6a5538989 --- /dev/null +++ b/authentik_client/models/group_matching_mode_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class GroupMatchingModeEnum(str, Enum): + """ + GroupMatchingModeEnum + """ + + """ + allowed enum values + """ + IDENTIFIER = 'identifier' + NAME_LINK = 'name_link' + NAME_DENY = 'name_deny' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of GroupMatchingModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/group_o_auth_source_connection.py b/authentik_client/models/group_o_auth_source_connection.py new file mode 100644 index 000000000..4db325ce1 --- /dev/null +++ b/authentik_client/models/group_o_auth_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupOAuthSourceConnection(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + pk: StrictInt + group: UUID + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "group", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupOAuthSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "group", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupOAuthSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "group": obj.get("group"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/group_o_auth_source_connection_request.py b/authentik_client/models/group_o_auth_source_connection_request.py new file mode 100644 index 000000000..e40b2c60b --- /dev/null +++ b/authentik_client/models/group_o_auth_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupOAuthSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupOAuthSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupOAuthSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/group_plex_source_connection.py b/authentik_client/models/group_plex_source_connection.py new file mode 100644 index 000000000..8f59f1e66 --- /dev/null +++ b/authentik_client/models/group_plex_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupPlexSourceConnection(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + pk: StrictInt + group: UUID + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "group", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupPlexSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "group", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupPlexSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "group": obj.get("group"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/group_plex_source_connection_request.py b/authentik_client/models/group_plex_source_connection_request.py new file mode 100644 index 000000000..97a2a5dc2 --- /dev/null +++ b/authentik_client/models/group_plex_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupPlexSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupPlexSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupPlexSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/group_request.py b/authentik_client/models/group_request.py new file mode 100644 index 000000000..707545072 --- /dev/null +++ b/authentik_client/models/group_request.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupRequest(BaseModel): + """ + Group Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + is_superuser: Optional[StrictBool] = Field(default=None, description="Users added to this group will be superusers.") + parents: Optional[List[UUID]] = None + users: Optional[List[StrictInt]] = None + attributes: Optional[Dict[str, Any]] = None + roles: Optional[List[UUID]] = None + __properties: ClassVar[List[str]] = ["name", "is_superuser", "parents", "users", "attributes", "roles"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "is_superuser": obj.get("is_superuser"), + "parents": obj.get("parents"), + "users": obj.get("users"), + "attributes": obj.get("attributes"), + "roles": obj.get("roles") + }) + return _obj + + diff --git a/authentik_client/models/group_saml_source_connection.py b/authentik_client/models/group_saml_source_connection.py new file mode 100644 index 000000000..e5648d550 --- /dev/null +++ b/authentik_client/models/group_saml_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupSAMLSourceConnection(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + pk: StrictInt + group: UUID + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "group", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupSAMLSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "group", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupSAMLSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "group": obj.get("group"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/group_saml_source_connection_request.py b/authentik_client/models/group_saml_source_connection_request.py new file mode 100644 index 000000000..4c742eada --- /dev/null +++ b/authentik_client/models/group_saml_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupSAMLSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupSAMLSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupSAMLSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/group_source_connection.py b/authentik_client/models/group_source_connection.py new file mode 100644 index 000000000..850bc0bf9 --- /dev/null +++ b/authentik_client/models/group_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupSourceConnection(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + pk: StrictInt + group: UUID + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "group", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "group", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "group": obj.get("group"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/group_source_connection_request.py b/authentik_client/models/group_source_connection_request.py new file mode 100644 index 000000000..7c1230b39 --- /dev/null +++ b/authentik_client/models/group_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/group_telegram_source_connection.py b/authentik_client/models/group_telegram_source_connection.py new file mode 100644 index 000000000..681bbd1ff --- /dev/null +++ b/authentik_client/models/group_telegram_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupTelegramSourceConnection(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + pk: StrictInt + group: UUID + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "group", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupTelegramSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "group", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupTelegramSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "group": obj.get("group"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/group_telegram_source_connection_request.py b/authentik_client/models/group_telegram_source_connection_request.py new file mode 100644 index 000000000..ce887efac --- /dev/null +++ b/authentik_client/models/group_telegram_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class GroupTelegramSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GroupTelegramSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GroupTelegramSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/hardware.py b/authentik_client/models/hardware.py new file mode 100644 index 000000000..543d78e8d --- /dev/null +++ b/authentik_client/models/hardware.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Hardware(BaseModel): + """ + Hardware + """ # noqa: E501 + model: Optional[StrictStr] = None + manufacturer: Optional[StrictStr] = None + serial: StrictStr + cpu_name: Optional[StrictStr] = None + cpu_count: Optional[StrictInt] = None + memory_bytes: Optional[StrictInt] = None + __properties: ClassVar[List[str]] = ["model", "manufacturer", "serial", "cpu_name", "cpu_count", "memory_bytes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Hardware from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Hardware from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "model": obj.get("model"), + "manufacturer": obj.get("manufacturer"), + "serial": obj.get("serial"), + "cpu_name": obj.get("cpu_name"), + "cpu_count": obj.get("cpu_count"), + "memory_bytes": obj.get("memory_bytes") + }) + return _obj + + diff --git a/authentik_client/models/hardware_request.py b/authentik_client/models/hardware_request.py new file mode 100644 index 000000000..6cd5d3712 --- /dev/null +++ b/authentik_client/models/hardware_request.py @@ -0,0 +1,100 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class HardwareRequest(BaseModel): + """ + HardwareRequest + """ # noqa: E501 + model: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + manufacturer: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + serial: Annotated[str, Field(min_length=1, strict=True)] + cpu_name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + cpu_count: Optional[StrictInt] = None + memory_bytes: Optional[StrictInt] = None + __properties: ClassVar[List[str]] = ["model", "manufacturer", "serial", "cpu_name", "cpu_count", "memory_bytes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of HardwareRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of HardwareRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "model": obj.get("model"), + "manufacturer": obj.get("manufacturer"), + "serial": obj.get("serial"), + "cpu_name": obj.get("cpu_name"), + "cpu_count": obj.get("cpu_count"), + "memory_bytes": obj.get("memory_bytes") + }) + return _obj + + diff --git a/authentik_client/models/identification_challenge.py b/authentik_client/models/identification_challenge.py new file mode 100644 index 000000000..9ac35a798 --- /dev/null +++ b/authentik_client/models/identification_challenge.py @@ -0,0 +1,177 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.captcha_challenge import CaptchaChallenge +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from authentik_client.models.flow_designation_enum import FlowDesignationEnum +from authentik_client.models.login_source import LoginSource +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class IdentificationChallenge(BaseModel): + """ + Identification challenges with all UI elements + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-identification' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + user_fields: Optional[List[StrictStr]] + pending_user_identifier: Optional[StrictStr] = None + password_fields: StrictBool + allow_show_password: Optional[StrictBool] = False + application_pre: Optional[StrictStr] = None + application_pre_launch: Optional[StrictStr] = None + flow_designation: FlowDesignationEnum + captcha_stage: Optional[CaptchaChallenge] = None + enroll_url: Optional[StrictStr] = None + recovery_url: Optional[StrictStr] = None + passwordless_url: Optional[StrictStr] = None + primary_action: StrictStr + sources: Optional[List[LoginSource]] = None + show_source_labels: StrictBool + enable_remember_me: Optional[StrictBool] = True + passkey_challenge: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "user_fields", "pending_user_identifier", "password_fields", "allow_show_password", "application_pre", "application_pre_launch", "flow_designation", "captcha_stage", "enroll_url", "recovery_url", "passwordless_url", "primary_action", "sources", "show_source_labels", "enable_remember_me", "passkey_challenge"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of IdentificationChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + # override the default output from pydantic by calling `to_dict()` of captcha_stage + if self.captcha_stage: + _dict['captcha_stage'] = self.captcha_stage.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in sources (list) + _items = [] + if self.sources: + for _item_sources in self.sources: + if _item_sources: + _items.append(_item_sources.to_dict()) + _dict['sources'] = _items + # set to None if user_fields (nullable) is None + # and model_fields_set contains the field + if self.user_fields is None and "user_fields" in self.model_fields_set: + _dict['user_fields'] = None + + # set to None if pending_user_identifier (nullable) is None + # and model_fields_set contains the field + if self.pending_user_identifier is None and "pending_user_identifier" in self.model_fields_set: + _dict['pending_user_identifier'] = None + + # set to None if captcha_stage (nullable) is None + # and model_fields_set contains the field + if self.captcha_stage is None and "captcha_stage" in self.model_fields_set: + _dict['captcha_stage'] = None + + # set to None if passkey_challenge (nullable) is None + # and model_fields_set contains the field + if self.passkey_challenge is None and "passkey_challenge" in self.model_fields_set: + _dict['passkey_challenge'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of IdentificationChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-identification', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "user_fields": obj.get("user_fields"), + "pending_user_identifier": obj.get("pending_user_identifier"), + "password_fields": obj.get("password_fields"), + "allow_show_password": obj.get("allow_show_password") if obj.get("allow_show_password") is not None else False, + "application_pre": obj.get("application_pre"), + "application_pre_launch": obj.get("application_pre_launch"), + "flow_designation": obj.get("flow_designation"), + "captcha_stage": CaptchaChallenge.from_dict(obj["captcha_stage"]) if obj.get("captcha_stage") is not None else None, + "enroll_url": obj.get("enroll_url"), + "recovery_url": obj.get("recovery_url"), + "passwordless_url": obj.get("passwordless_url"), + "primary_action": obj.get("primary_action"), + "sources": [LoginSource.from_dict(_item) for _item in obj["sources"]] if obj.get("sources") is not None else None, + "show_source_labels": obj.get("show_source_labels"), + "enable_remember_me": obj.get("enable_remember_me") if obj.get("enable_remember_me") is not None else True, + "passkey_challenge": obj.get("passkey_challenge") + }) + return _obj + + diff --git a/authentik_client/models/identification_challenge_response_request.py b/authentik_client/models/identification_challenge_response_request.py new file mode 100644 index 000000000..0fe7dabcd --- /dev/null +++ b/authentik_client/models/identification_challenge_response_request.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class IdentificationChallengeResponseRequest(BaseModel): + """ + Identification challenge + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-identification' + uid_field: Optional[StrictStr] = None + password: Optional[StrictStr] = None + captcha_token: Optional[StrictStr] = None + passkey: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["component", "uid_field", "password", "captcha_token", "passkey"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of IdentificationChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if uid_field (nullable) is None + # and model_fields_set contains the field + if self.uid_field is None and "uid_field" in self.model_fields_set: + _dict['uid_field'] = None + + # set to None if password (nullable) is None + # and model_fields_set contains the field + if self.password is None and "password" in self.model_fields_set: + _dict['password'] = None + + # set to None if captcha_token (nullable) is None + # and model_fields_set contains the field + if self.captcha_token is None and "captcha_token" in self.model_fields_set: + _dict['captcha_token'] = None + + # set to None if passkey (nullable) is None + # and model_fields_set contains the field + if self.passkey is None and "passkey" in self.model_fields_set: + _dict['passkey'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of IdentificationChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-identification', + "uid_field": obj.get("uid_field"), + "password": obj.get("password"), + "captcha_token": obj.get("captcha_token"), + "passkey": obj.get("passkey") + }) + return _obj + + diff --git a/authentik_client/models/identification_stage.py b/authentik_client/models/identification_stage.py new file mode 100644 index 000000000..054955501 --- /dev/null +++ b/authentik_client/models/identification_stage.py @@ -0,0 +1,179 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.user_fields_enum import UserFieldsEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class IdentificationStage(BaseModel): + """ + IdentificationStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + user_fields: Optional[List[UserFieldsEnum]] = Field(default=None, description="Fields of the user object to match against. (Hold shift to select multiple options)") + password_stage: Optional[UUID] = Field(default=None, description="When set, shows a password field, instead of showing the password field as separate step.") + captcha_stage: Optional[UUID] = Field(default=None, description="When set, adds functionality exactly like a Captcha stage, but baked into the Identification stage.") + case_insensitive_matching: Optional[StrictBool] = Field(default=None, description="When enabled, user fields are matched regardless of their casing.") + show_matched_user: Optional[StrictBool] = Field(default=None, description="When a valid username/email has been entered, and this option is enabled, the user's username and avatar will be shown. Otherwise, the text that the user entered will be shown") + enrollment_flow: Optional[UUID] = Field(default=None, description="Optional enrollment flow, which is linked at the bottom of the page.") + recovery_flow: Optional[UUID] = Field(default=None, description="Optional recovery flow, which is linked at the bottom of the page.") + passwordless_flow: Optional[UUID] = Field(default=None, description="Optional passwordless flow, which is linked at the bottom of the page.") + sources: Optional[List[UUID]] = Field(default=None, description="Specify which sources should be shown.") + show_source_labels: Optional[StrictBool] = None + pretend_user_exists: Optional[StrictBool] = Field(default=None, description="When enabled, the stage will succeed and continue even when incorrect user info is entered.") + enable_remember_me: Optional[StrictBool] = Field(default=None, description="Show the user the 'Remember me on this device' toggle, allowing repeat users to skip straight to entering their password.") + webauthn_stage: Optional[UUID] = Field(default=None, description="When set, and conditional WebAuthn is available, allow the user to use their passkey as a first factor.") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "user_fields", "password_stage", "captcha_stage", "case_insensitive_matching", "show_matched_user", "enrollment_flow", "recovery_flow", "passwordless_flow", "sources", "show_source_labels", "pretend_user_exists", "enable_remember_me", "webauthn_stage"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of IdentificationStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if password_stage (nullable) is None + # and model_fields_set contains the field + if self.password_stage is None and "password_stage" in self.model_fields_set: + _dict['password_stage'] = None + + # set to None if captcha_stage (nullable) is None + # and model_fields_set contains the field + if self.captcha_stage is None and "captcha_stage" in self.model_fields_set: + _dict['captcha_stage'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if recovery_flow (nullable) is None + # and model_fields_set contains the field + if self.recovery_flow is None and "recovery_flow" in self.model_fields_set: + _dict['recovery_flow'] = None + + # set to None if passwordless_flow (nullable) is None + # and model_fields_set contains the field + if self.passwordless_flow is None and "passwordless_flow" in self.model_fields_set: + _dict['passwordless_flow'] = None + + # set to None if webauthn_stage (nullable) is None + # and model_fields_set contains the field + if self.webauthn_stage is None and "webauthn_stage" in self.model_fields_set: + _dict['webauthn_stage'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of IdentificationStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "user_fields": obj.get("user_fields"), + "password_stage": obj.get("password_stage"), + "captcha_stage": obj.get("captcha_stage"), + "case_insensitive_matching": obj.get("case_insensitive_matching"), + "show_matched_user": obj.get("show_matched_user"), + "enrollment_flow": obj.get("enrollment_flow"), + "recovery_flow": obj.get("recovery_flow"), + "passwordless_flow": obj.get("passwordless_flow"), + "sources": obj.get("sources"), + "show_source_labels": obj.get("show_source_labels"), + "pretend_user_exists": obj.get("pretend_user_exists"), + "enable_remember_me": obj.get("enable_remember_me"), + "webauthn_stage": obj.get("webauthn_stage") + }) + return _obj + + diff --git a/authentik_client/models/identification_stage_request.py b/authentik_client/models/identification_stage_request.py new file mode 100644 index 000000000..308754ab0 --- /dev/null +++ b/authentik_client/models/identification_stage_request.py @@ -0,0 +1,148 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.user_fields_enum import UserFieldsEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class IdentificationStageRequest(BaseModel): + """ + IdentificationStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + user_fields: Optional[List[UserFieldsEnum]] = Field(default=None, description="Fields of the user object to match against. (Hold shift to select multiple options)") + password_stage: Optional[UUID] = Field(default=None, description="When set, shows a password field, instead of showing the password field as separate step.") + captcha_stage: Optional[UUID] = Field(default=None, description="When set, adds functionality exactly like a Captcha stage, but baked into the Identification stage.") + case_insensitive_matching: Optional[StrictBool] = Field(default=None, description="When enabled, user fields are matched regardless of their casing.") + show_matched_user: Optional[StrictBool] = Field(default=None, description="When a valid username/email has been entered, and this option is enabled, the user's username and avatar will be shown. Otherwise, the text that the user entered will be shown") + enrollment_flow: Optional[UUID] = Field(default=None, description="Optional enrollment flow, which is linked at the bottom of the page.") + recovery_flow: Optional[UUID] = Field(default=None, description="Optional recovery flow, which is linked at the bottom of the page.") + passwordless_flow: Optional[UUID] = Field(default=None, description="Optional passwordless flow, which is linked at the bottom of the page.") + sources: Optional[List[UUID]] = Field(default=None, description="Specify which sources should be shown.") + show_source_labels: Optional[StrictBool] = None + pretend_user_exists: Optional[StrictBool] = Field(default=None, description="When enabled, the stage will succeed and continue even when incorrect user info is entered.") + enable_remember_me: Optional[StrictBool] = Field(default=None, description="Show the user the 'Remember me on this device' toggle, allowing repeat users to skip straight to entering their password.") + webauthn_stage: Optional[UUID] = Field(default=None, description="When set, and conditional WebAuthn is available, allow the user to use their passkey as a first factor.") + __properties: ClassVar[List[str]] = ["name", "user_fields", "password_stage", "captcha_stage", "case_insensitive_matching", "show_matched_user", "enrollment_flow", "recovery_flow", "passwordless_flow", "sources", "show_source_labels", "pretend_user_exists", "enable_remember_me", "webauthn_stage"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of IdentificationStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if password_stage (nullable) is None + # and model_fields_set contains the field + if self.password_stage is None and "password_stage" in self.model_fields_set: + _dict['password_stage'] = None + + # set to None if captcha_stage (nullable) is None + # and model_fields_set contains the field + if self.captcha_stage is None and "captcha_stage" in self.model_fields_set: + _dict['captcha_stage'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if recovery_flow (nullable) is None + # and model_fields_set contains the field + if self.recovery_flow is None and "recovery_flow" in self.model_fields_set: + _dict['recovery_flow'] = None + + # set to None if passwordless_flow (nullable) is None + # and model_fields_set contains the field + if self.passwordless_flow is None and "passwordless_flow" in self.model_fields_set: + _dict['passwordless_flow'] = None + + # set to None if webauthn_stage (nullable) is None + # and model_fields_set contains the field + if self.webauthn_stage is None and "webauthn_stage" in self.model_fields_set: + _dict['webauthn_stage'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of IdentificationStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "user_fields": obj.get("user_fields"), + "password_stage": obj.get("password_stage"), + "captcha_stage": obj.get("captcha_stage"), + "case_insensitive_matching": obj.get("case_insensitive_matching"), + "show_matched_user": obj.get("show_matched_user"), + "enrollment_flow": obj.get("enrollment_flow"), + "recovery_flow": obj.get("recovery_flow"), + "passwordless_flow": obj.get("passwordless_flow"), + "sources": obj.get("sources"), + "show_source_labels": obj.get("show_source_labels"), + "pretend_user_exists": obj.get("pretend_user_exists"), + "enable_remember_me": obj.get("enable_remember_me"), + "webauthn_stage": obj.get("webauthn_stage") + }) + return _obj + + diff --git a/authentik_client/models/iframe_logout_challenge.py b/authentik_client/models/iframe_logout_challenge.py new file mode 100644 index 000000000..c81e0cafd --- /dev/null +++ b/authentik_client/models/iframe_logout_challenge.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from authentik_client.models.logout_url import LogoutURL +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class IframeLogoutChallenge(BaseModel): + """ + Challenge for iframe logout + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-provider-iframe-logout' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + logout_urls: Optional[List[LogoutURL]] = None + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "logout_urls"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of IframeLogoutChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + # override the default output from pydantic by calling `to_dict()` of each item in logout_urls (list) + _items = [] + if self.logout_urls: + for _item_logout_urls in self.logout_urls: + if _item_logout_urls: + _items.append(_item_logout_urls.to_dict()) + _dict['logout_urls'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of IframeLogoutChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-provider-iframe-logout', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "logout_urls": [LogoutURL.from_dict(_item) for _item in obj["logout_urls"]] if obj.get("logout_urls") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/iframe_logout_challenge_response_request.py b/authentik_client/models/iframe_logout_challenge_response_request.py new file mode 100644 index 000000000..504ec1da4 --- /dev/null +++ b/authentik_client/models/iframe_logout_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class IframeLogoutChallengeResponseRequest(BaseModel): + """ + Response for iframe logout + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-provider-iframe-logout' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of IframeLogoutChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of IframeLogoutChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-provider-iframe-logout' + }) + return _obj + + diff --git a/authentik_client/models/impersonation_request.py b/authentik_client/models/impersonation_request.py new file mode 100644 index 000000000..13137a194 --- /dev/null +++ b/authentik_client/models/impersonation_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ImpersonationRequest(BaseModel): + """ + ImpersonationRequest + """ # noqa: E501 + reason: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["reason"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ImpersonationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ImpersonationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "reason": obj.get("reason") + }) + return _obj + + diff --git a/authentik_client/models/initial_permissions.py b/authentik_client/models/initial_permissions.py new file mode 100644 index 000000000..f80bf03a0 --- /dev/null +++ b/authentik_client/models/initial_permissions.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.permission import Permission +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class InitialPermissions(BaseModel): + """ + InitialPermissions serializer + """ # noqa: E501 + pk: StrictInt + name: Annotated[str, Field(strict=True, max_length=150)] + role: UUID + permissions: Optional[List[StrictInt]] = None + permissions_obj: List[Permission] + __properties: ClassVar[List[str]] = ["pk", "name", "role", "permissions", "permissions_obj"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of InitialPermissions from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "permissions_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in permissions_obj (list) + _items = [] + if self.permissions_obj: + for _item_permissions_obj in self.permissions_obj: + if _item_permissions_obj: + _items.append(_item_permissions_obj.to_dict()) + _dict['permissions_obj'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of InitialPermissions from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "role": obj.get("role"), + "permissions": obj.get("permissions"), + "permissions_obj": [Permission.from_dict(_item) for _item in obj["permissions_obj"]] if obj.get("permissions_obj") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/initial_permissions_request.py b/authentik_client/models/initial_permissions_request.py new file mode 100644 index 000000000..abef59e38 --- /dev/null +++ b/authentik_client/models/initial_permissions_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class InitialPermissionsRequest(BaseModel): + """ + InitialPermissions serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True, max_length=150)] + role: UUID + permissions: Optional[List[StrictInt]] = None + __properties: ClassVar[List[str]] = ["name", "role", "permissions"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of InitialPermissionsRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of InitialPermissionsRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "role": obj.get("role"), + "permissions": obj.get("permissions") + }) + return _obj + + diff --git a/authentik_client/models/install_id.py b/authentik_client/models/install_id.py new file mode 100644 index 000000000..87f7618ae --- /dev/null +++ b/authentik_client/models/install_id.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class InstallID(BaseModel): + """ + InstallID + """ # noqa: E501 + install_id: StrictStr + __properties: ClassVar[List[str]] = ["install_id"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of InstallID from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of InstallID from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "install_id": obj.get("install_id") + }) + return _obj + + diff --git a/authentik_client/models/intent_enum.py b/authentik_client/models/intent_enum.py new file mode 100644 index 000000000..76d792f40 --- /dev/null +++ b/authentik_client/models/intent_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class IntentEnum(str, Enum): + """ + IntentEnum + """ + + """ + allowed enum values + """ + VERIFICATION = 'verification' + API = 'api' + RECOVERY = 'recovery' + APP_PASSWORD = 'app_password' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of IntentEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/invalid_response_action_enum.py b/authentik_client/models/invalid_response_action_enum.py new file mode 100644 index 000000000..51c560e5e --- /dev/null +++ b/authentik_client/models/invalid_response_action_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class InvalidResponseActionEnum(str, Enum): + """ + InvalidResponseActionEnum + """ + + """ + allowed enum values + """ + RETRY = 'retry' + RESTART = 'restart' + RESTART_WITH_CONTEXT = 'restart_with_context' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of InvalidResponseActionEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/invitation.py b/authentik_client/models/invitation.py new file mode 100644 index 000000000..fa237eea4 --- /dev/null +++ b/authentik_client/models/invitation.py @@ -0,0 +1,140 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.flow import Flow +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Invitation(BaseModel): + """ + Invitation Serializer + """ # noqa: E501 + pk: UUID + name: Annotated[str, Field(strict=True)] + expires: Optional[datetime] = None + fixed_data: Optional[Dict[str, Any]] = None + created_by: PartialUser + single_use: Optional[StrictBool] = Field(default=None, description="When enabled, the invitation will be deleted after usage.") + flow: Optional[UUID] = Field(default=None, description="When set, only the configured flow can use this invitation.") + flow_obj: Flow + __properties: ClassVar[List[str]] = ["pk", "name", "expires", "fixed_data", "created_by", "single_use", "flow", "flow_obj"] + + @field_validator('name') + def name_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Invitation from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "created_by", + "flow_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of created_by + if self.created_by: + _dict['created_by'] = self.created_by.to_dict() + # override the default output from pydantic by calling `to_dict()` of flow_obj + if self.flow_obj: + _dict['flow_obj'] = self.flow_obj.to_dict() + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + # set to None if flow (nullable) is None + # and model_fields_set contains the field + if self.flow is None and "flow" in self.model_fields_set: + _dict['flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Invitation from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "expires": obj.get("expires"), + "fixed_data": obj.get("fixed_data"), + "created_by": PartialUser.from_dict(obj["created_by"]) if obj.get("created_by") is not None else None, + "single_use": obj.get("single_use"), + "flow": obj.get("flow"), + "flow_obj": Flow.from_dict(obj["flow_obj"]) if obj.get("flow_obj") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/invitation_request.py b/authentik_client/models/invitation_request.py new file mode 100644 index 000000000..967f64893 --- /dev/null +++ b/authentik_client/models/invitation_request.py @@ -0,0 +1,120 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class InvitationRequest(BaseModel): + """ + Invitation Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + expires: Optional[datetime] = None + fixed_data: Optional[Dict[str, Any]] = None + single_use: Optional[StrictBool] = Field(default=None, description="When enabled, the invitation will be deleted after usage.") + flow: Optional[UUID] = Field(default=None, description="When set, only the configured flow can use this invitation.") + __properties: ClassVar[List[str]] = ["name", "expires", "fixed_data", "single_use", "flow"] + + @field_validator('name') + def name_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of InvitationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + # set to None if flow (nullable) is None + # and model_fields_set contains the field + if self.flow is None and "flow" in self.model_fields_set: + _dict['flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of InvitationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "expires": obj.get("expires"), + "fixed_data": obj.get("fixed_data"), + "single_use": obj.get("single_use"), + "flow": obj.get("flow") + }) + return _obj + + diff --git a/authentik_client/models/invitation_send_email_request.py b/authentik_client/models/invitation_send_email_request.py new file mode 100644 index 000000000..fb26961ad --- /dev/null +++ b/authentik_client/models/invitation_send_email_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class InvitationSendEmailRequest(BaseModel): + """ + Serializer for sending invitation emails + """ # noqa: E501 + email_addresses: List[Any] + cc_addresses: Optional[List[Any]] = None + bcc_addresses: Optional[List[Any]] = None + template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'invitation' + __properties: ClassVar[List[str]] = ["email_addresses", "cc_addresses", "bcc_addresses", "template"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of InvitationSendEmailRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of InvitationSendEmailRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "email_addresses": obj.get("email_addresses"), + "cc_addresses": obj.get("cc_addresses"), + "bcc_addresses": obj.get("bcc_addresses"), + "template": obj.get("template") if obj.get("template") is not None else 'invitation' + }) + return _obj + + diff --git a/authentik_client/models/invitation_stage.py b/authentik_client/models/invitation_stage.py new file mode 100644 index 000000000..e25b3c9fd --- /dev/null +++ b/authentik_client/models/invitation_stage.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class InvitationStage(BaseModel): + """ + InvitationStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + continue_flow_without_invitation: Optional[StrictBool] = Field(default=None, description="If this flag is set, this Stage will jump to the next Stage when no Invitation is given. By default this Stage will cancel the Flow when no invitation is given.") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "continue_flow_without_invitation"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of InvitationStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of InvitationStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "continue_flow_without_invitation": obj.get("continue_flow_without_invitation") + }) + return _obj + + diff --git a/authentik_client/models/invitation_stage_request.py b/authentik_client/models/invitation_stage_request.py new file mode 100644 index 000000000..26654cde1 --- /dev/null +++ b/authentik_client/models/invitation_stage_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class InvitationStageRequest(BaseModel): + """ + InvitationStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + continue_flow_without_invitation: Optional[StrictBool] = Field(default=None, description="If this flag is set, this Stage will jump to the next Stage when no Invitation is given. By default this Stage will cancel the Flow when no invitation is given.") + __properties: ClassVar[List[str]] = ["name", "continue_flow_without_invitation"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of InvitationStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of InvitationStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "continue_flow_without_invitation": obj.get("continue_flow_without_invitation") + }) + return _obj + + diff --git a/authentik_client/models/issuer_mode_enum.py b/authentik_client/models/issuer_mode_enum.py new file mode 100644 index 000000000..ac794d256 --- /dev/null +++ b/authentik_client/models/issuer_mode_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class IssuerModeEnum(str, Enum): + """ + IssuerModeEnum + """ + + """ + allowed enum values + """ + GLOBAL = 'global' + PER_PROVIDER = 'per_provider' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of IssuerModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/kadmin_type_enum.py b/authentik_client/models/kadmin_type_enum.py new file mode 100644 index 000000000..0168a3f46 --- /dev/null +++ b/authentik_client/models/kadmin_type_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class KadminTypeEnum(str, Enum): + """ + KadminTypeEnum + """ + + """ + allowed enum values + """ + MIT = 'MIT' + HEIMDAL = 'Heimdal' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of KadminTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/kerberos_source.py b/authentik_client/models/kerberos_source.py new file mode 100644 index 000000000..fcfd1fc65 --- /dev/null +++ b/authentik_client/models/kerberos_source.py @@ -0,0 +1,213 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.kadmin_type_enum import KadminTypeEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.sync_outgoing_trigger_mode_enum import SyncOutgoingTriggerModeEnum +from authentik_client.models.themed_urls import ThemedUrls +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class KerberosSource(BaseModel): + """ + Kerberos Source Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr = Field(description="Source's display Name.") + slug: Annotated[str, Field(strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + managed: Optional[StrictStr] = Field(description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + user_path_template: Optional[StrictStr] = None + icon: Optional[StrictStr] = None + icon_url: StrictStr + icon_themed_urls: Optional[ThemedUrls] + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + realm: StrictStr = Field(description="Kerberos realm") + krb5_conf: Optional[StrictStr] = Field(default=None, description="Custom krb5.conf to use. Uses the system one by default") + kadmin_type: Optional[KadminTypeEnum] = Field(default=None, description="KAdmin server type") + sync_users: Optional[StrictBool] = Field(default=None, description="Sync users from Kerberos into authentik") + sync_users_password: Optional[StrictBool] = Field(default=None, description="When a user changes their password, sync it back to Kerberos") + sync_principal: Optional[StrictStr] = Field(default=None, description="Principal to authenticate to kadmin for sync.") + connectivity: Optional[Dict[str, StrictStr]] = Field(description="Get cached source connectivity") + spnego_server_name: Optional[StrictStr] = Field(default=None, description="Force the use of a specific server name for SPNEGO. Must be in the form HTTP@hostname") + password_login_update_internal_password: Optional[StrictBool] = Field(default=None, description="If enabled, the authentik-stored password will be updated upon login with the Kerberos password backend") + sync_outgoing_trigger_mode: Optional[SyncOutgoingTriggerModeEnum] = Field(default=None, description="When to trigger sync for outgoing providers") + __properties: ClassVar[List[str]] = ["pk", "name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "policy_engine_mode", "user_matching_mode", "managed", "user_path_template", "icon", "icon_url", "icon_themed_urls", "group_matching_mode", "realm", "krb5_conf", "kadmin_type", "sync_users", "sync_users_password", "sync_principal", "connectivity", "spnego_server_name", "password_login_update_internal_password", "sync_outgoing_trigger_mode"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of KerberosSource from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "managed", + "icon_url", + "icon_themed_urls", + "connectivity", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of icon_themed_urls + if self.icon_themed_urls: + _dict['icon_themed_urls'] = self.icon_themed_urls.to_dict() + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if icon_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.icon_themed_urls is None and "icon_themed_urls" in self.model_fields_set: + _dict['icon_themed_urls'] = None + + # set to None if connectivity (nullable) is None + # and model_fields_set contains the field + if self.connectivity is None and "connectivity" in self.model_fields_set: + _dict['connectivity'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of KerberosSource from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "managed": obj.get("managed"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "icon_url": obj.get("icon_url"), + "icon_themed_urls": ThemedUrls.from_dict(obj["icon_themed_urls"]) if obj.get("icon_themed_urls") is not None else None, + "group_matching_mode": obj.get("group_matching_mode"), + "realm": obj.get("realm"), + "krb5_conf": obj.get("krb5_conf"), + "kadmin_type": obj.get("kadmin_type"), + "sync_users": obj.get("sync_users"), + "sync_users_password": obj.get("sync_users_password"), + "sync_principal": obj.get("sync_principal"), + "connectivity": obj.get("connectivity"), + "spnego_server_name": obj.get("spnego_server_name"), + "password_login_update_internal_password": obj.get("password_login_update_internal_password"), + "sync_outgoing_trigger_mode": obj.get("sync_outgoing_trigger_mode") + }) + return _obj + + diff --git a/authentik_client/models/kerberos_source_property_mapping.py b/authentik_client/models/kerberos_source_property_mapping.py new file mode 100644 index 000000000..2efcdb9ea --- /dev/null +++ b/authentik_client/models/kerberos_source_property_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class KerberosSourcePropertyMapping(BaseModel): + """ + Kerberos PropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of KerberosSourcePropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of KerberosSourcePropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/kerberos_source_property_mapping_request.py b/authentik_client/models/kerberos_source_property_mapping_request.py new file mode 100644 index 000000000..5a6d757c2 --- /dev/null +++ b/authentik_client/models/kerberos_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class KerberosSourcePropertyMappingRequest(BaseModel): + """ + Kerberos PropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of KerberosSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of KerberosSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/kerberos_source_request.py b/authentik_client/models/kerberos_source_request.py new file mode 100644 index 000000000..6da009dc3 --- /dev/null +++ b/authentik_client/models/kerberos_source_request.py @@ -0,0 +1,168 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.kadmin_type_enum import KadminTypeEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.sync_outgoing_trigger_mode_enum import SyncOutgoingTriggerModeEnum +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class KerberosSourceRequest(BaseModel): + """ + Kerberos Source Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Source's display Name.") + slug: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + realm: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Kerberos realm") + krb5_conf: Optional[StrictStr] = Field(default=None, description="Custom krb5.conf to use. Uses the system one by default") + kadmin_type: Optional[KadminTypeEnum] = Field(default=None, description="KAdmin server type") + sync_users: Optional[StrictBool] = Field(default=None, description="Sync users from Kerberos into authentik") + sync_users_password: Optional[StrictBool] = Field(default=None, description="When a user changes their password, sync it back to Kerberos") + sync_principal: Optional[StrictStr] = Field(default=None, description="Principal to authenticate to kadmin for sync.") + sync_password: Optional[StrictStr] = Field(default=None, description="Password to authenticate to kadmin for sync") + sync_keytab: Optional[StrictStr] = Field(default=None, description="Keytab to authenticate to kadmin for sync. Must be base64-encoded or in the form TYPE:residual") + sync_ccache: Optional[StrictStr] = Field(default=None, description="Credentials cache to authenticate to kadmin for sync. Must be in the form TYPE:residual") + spnego_server_name: Optional[StrictStr] = Field(default=None, description="Force the use of a specific server name for SPNEGO. Must be in the form HTTP@hostname") + spnego_keytab: Optional[StrictStr] = Field(default=None, description="SPNEGO keytab base64-encoded or path to keytab in the form FILE:path") + spnego_ccache: Optional[StrictStr] = Field(default=None, description="Credential cache to use for SPNEGO in form type:residual") + password_login_update_internal_password: Optional[StrictBool] = Field(default=None, description="If enabled, the authentik-stored password will be updated upon login with the Kerberos password backend") + sync_outgoing_trigger_mode: Optional[SyncOutgoingTriggerModeEnum] = Field(default=None, description="When to trigger sync for outgoing providers") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "group_matching_mode", "realm", "krb5_conf", "kadmin_type", "sync_users", "sync_users_password", "sync_principal", "sync_password", "sync_keytab", "sync_ccache", "spnego_server_name", "spnego_keytab", "spnego_ccache", "password_login_update_internal_password", "sync_outgoing_trigger_mode"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of KerberosSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of KerberosSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "group_matching_mode": obj.get("group_matching_mode"), + "realm": obj.get("realm"), + "krb5_conf": obj.get("krb5_conf"), + "kadmin_type": obj.get("kadmin_type"), + "sync_users": obj.get("sync_users"), + "sync_users_password": obj.get("sync_users_password"), + "sync_principal": obj.get("sync_principal"), + "sync_password": obj.get("sync_password"), + "sync_keytab": obj.get("sync_keytab"), + "sync_ccache": obj.get("sync_ccache"), + "spnego_server_name": obj.get("spnego_server_name"), + "spnego_keytab": obj.get("spnego_keytab"), + "spnego_ccache": obj.get("spnego_ccache"), + "password_login_update_internal_password": obj.get("password_login_update_internal_password"), + "sync_outgoing_trigger_mode": obj.get("sync_outgoing_trigger_mode") + }) + return _obj + + diff --git a/authentik_client/models/key_type_enum.py b/authentik_client/models/key_type_enum.py new file mode 100644 index 000000000..fbcc07967 --- /dev/null +++ b/authentik_client/models/key_type_enum.py @@ -0,0 +1,41 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class KeyTypeEnum(str, Enum): + """ + KeyTypeEnum + """ + + """ + allowed enum values + """ + DSA = 'dsa' + EC = 'ec' + ED25519 = 'ed25519' + ED448 = 'ed448' + RSA = 'rsa' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of KeyTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/kubernetes_service_connection.py b/authentik_client/models/kubernetes_service_connection.py new file mode 100644 index 000000000..3f36b7642 --- /dev/null +++ b/authentik_client/models/kubernetes_service_connection.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class KubernetesServiceConnection(BaseModel): + """ + KubernetesServiceConnection Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + local: Optional[StrictBool] = Field(default=None, description="If enabled, use the local connection. Required Docker socket/Kubernetes Integration") + component: StrictStr + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + kubeconfig: Optional[Dict[str, Any]] = Field(default=None, description="Paste your kubeconfig here. authentik will automatically use the currently selected context.") + verify_ssl: Optional[StrictBool] = Field(default=None, description="Verify SSL Certificates of the Kubernetes API endpoint") + __properties: ClassVar[List[str]] = ["pk", "name", "local", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "kubeconfig", "verify_ssl"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of KubernetesServiceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of KubernetesServiceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "local": obj.get("local"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "kubeconfig": obj.get("kubeconfig"), + "verify_ssl": obj.get("verify_ssl") + }) + return _obj + + diff --git a/authentik_client/models/kubernetes_service_connection_request.py b/authentik_client/models/kubernetes_service_connection_request.py new file mode 100644 index 000000000..7d937d7bd --- /dev/null +++ b/authentik_client/models/kubernetes_service_connection_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class KubernetesServiceConnectionRequest(BaseModel): + """ + KubernetesServiceConnection Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + local: Optional[StrictBool] = Field(default=None, description="If enabled, use the local connection. Required Docker socket/Kubernetes Integration") + kubeconfig: Optional[Dict[str, Any]] = Field(default=None, description="Paste your kubeconfig here. authentik will automatically use the currently selected context.") + verify_ssl: Optional[StrictBool] = Field(default=None, description="Verify SSL Certificates of the Kubernetes API endpoint") + __properties: ClassVar[List[str]] = ["name", "local", "kubeconfig", "verify_ssl"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of KubernetesServiceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of KubernetesServiceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "local": obj.get("local"), + "kubeconfig": obj.get("kubeconfig"), + "verify_ssl": obj.get("verify_ssl") + }) + return _obj + + diff --git a/authentik_client/models/lang_enum.py b/authentik_client/models/lang_enum.py new file mode 100644 index 000000000..0cb7c787e --- /dev/null +++ b/authentik_client/models/lang_enum.py @@ -0,0 +1,135 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class LangEnum(str, Enum): + """ + LangEnum + """ + + """ + allowed enum values + """ + AF = 'af' + AR = 'ar' + AR_MINUS_DZ = 'ar-dz' + AST = 'ast' + AZ = 'az' + BE = 'be' + BG = 'bg' + BN = 'bn' + BR = 'br' + BS = 'bs' + CA = 'ca' + CKB = 'ckb' + CS = 'cs' + CY = 'cy' + DA = 'da' + DE = 'de' + DSB = 'dsb' + EL = 'el' + EN = 'en' + EN_MINUS_AU = 'en-au' + EN_MINUS_GB = 'en-gb' + EO = 'eo' + ES = 'es' + ES_MINUS_AR = 'es-ar' + ES_MINUS_CO = 'es-co' + ES_MINUS_MX = 'es-mx' + ES_MINUS_NI = 'es-ni' + ES_MINUS_VE = 'es-ve' + ET = 'et' + EU = 'eu' + FA = 'fa' + FI = 'fi' + FR = 'fr' + FY = 'fy' + GA = 'ga' + GD = 'gd' + GL = 'gl' + HE = 'he' + HI = 'hi' + HR = 'hr' + HSB = 'hsb' + HU = 'hu' + HY = 'hy' + IA = 'ia' + ID = 'id' + IG = 'ig' + IO = 'io' + IS = 'is' + IT = 'it' + JA = 'ja' + KA = 'ka' + KAB = 'kab' + KK = 'kk' + KM = 'km' + KN = 'kn' + KO = 'ko' + KY = 'ky' + LB = 'lb' + LT = 'lt' + LV = 'lv' + MK = 'mk' + ML = 'ml' + MN = 'mn' + MR = 'mr' + MS = 'ms' + MY = 'my' + NB = 'nb' + NE = 'ne' + NL = 'nl' + NN = 'nn' + OS = 'os' + PA = 'pa' + PL = 'pl' + PT = 'pt' + PT_MINUS_BR = 'pt-br' + RO = 'ro' + RU = 'ru' + SK = 'sk' + SL = 'sl' + SQ = 'sq' + SR = 'sr' + SR_MINUS_LATN = 'sr-latn' + SV = 'sv' + SW = 'sw' + TA = 'ta' + TE = 'te' + TG = 'tg' + TH = 'th' + TK = 'tk' + TR = 'tr' + TT = 'tt' + UDM = 'udm' + UG = 'ug' + UK = 'uk' + UR = 'ur' + UZ = 'uz' + VI = 'vi' + ZH_MINUS_HANS = 'zh-hans' + ZH_MINUS_HANT = 'zh-hant' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of LangEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/last_task_status_enum.py b/authentik_client/models/last_task_status_enum.py new file mode 100644 index 000000000..abd4d6662 --- /dev/null +++ b/authentik_client/models/last_task_status_enum.py @@ -0,0 +1,46 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class LastTaskStatusEnum(str, Enum): + """ + LastTaskStatusEnum + """ + + """ + allowed enum values + """ + QUEUED = 'queued' + CONSUMED = 'consumed' + PREPROCESS = 'preprocess' + RUNNING = 'running' + POSTPROCESS = 'postprocess' + REJECTED = 'rejected' + DONE = 'done' + INFO = 'info' + WARNING = 'warning' + ERROR = 'error' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of LastTaskStatusEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/ldap_check_access.py b/authentik_client/models/ldap_check_access.py new file mode 100644 index 000000000..8752771b8 --- /dev/null +++ b/authentik_client/models/ldap_check_access.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.policy_test_result import PolicyTestResult +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LDAPCheckAccess(BaseModel): + """ + Base serializer class which doesn't implement create/update methods + """ # noqa: E501 + has_search_permission: Optional[StrictBool] = None + access: PolicyTestResult + __properties: ClassVar[List[str]] = ["has_search_permission", "access"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LDAPCheckAccess from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of access + if self.access: + _dict['access'] = self.access.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LDAPCheckAccess from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "has_search_permission": obj.get("has_search_permission"), + "access": PolicyTestResult.from_dict(obj["access"]) if obj.get("access") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/ldap_debug.py b/authentik_client/models/ldap_debug.py new file mode 100644 index 000000000..113461b66 --- /dev/null +++ b/authentik_client/models/ldap_debug.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LDAPDebug(BaseModel): + """ + LDAPDebug + """ # noqa: E501 + user: List[Dict[str, Any]] + group: List[Dict[str, Any]] + membership: List[Dict[str, Any]] + __properties: ClassVar[List[str]] = ["user", "group", "membership"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LDAPDebug from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "user", + "group", + "membership", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LDAPDebug from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user": obj.get("user"), + "group": obj.get("group"), + "membership": obj.get("membership") + }) + return _obj + + diff --git a/authentik_client/models/ldap_outpost_config.py b/authentik_client/models/ldap_outpost_config.py new file mode 100644 index 000000000..c8f7b4b6b --- /dev/null +++ b/authentik_client/models/ldap_outpost_config.py @@ -0,0 +1,132 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.ldapapi_access_mode import LDAPAPIAccessMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LDAPOutpostConfig(BaseModel): + """ + LDAPProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + base_dn: Optional[StrictStr] = Field(default=None, description="DN under which objects are accessible.") + bind_flow_slug: StrictStr + unbind_flow_slug: Optional[StrictStr] = Field(description="Get slug for unbind flow, defaulting to brand's default flow.") + application_slug: StrictStr = Field(description="Prioritise backchannel slug over direct application slug") + certificate: Optional[UUID] = None + tls_server_name: Optional[StrictStr] = None + uid_start_number: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber") + gid_start_number: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber") + search_mode: Optional[LDAPAPIAccessMode] = None + bind_mode: Optional[LDAPAPIAccessMode] = None + mfa_support: Optional[StrictBool] = Field(default=None, description="When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.") + __properties: ClassVar[List[str]] = ["pk", "name", "base_dn", "bind_flow_slug", "unbind_flow_slug", "application_slug", "certificate", "tls_server_name", "uid_start_number", "gid_start_number", "search_mode", "bind_mode", "mfa_support"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LDAPOutpostConfig from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "unbind_flow_slug", + "application_slug", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if unbind_flow_slug (nullable) is None + # and model_fields_set contains the field + if self.unbind_flow_slug is None and "unbind_flow_slug" in self.model_fields_set: + _dict['unbind_flow_slug'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LDAPOutpostConfig from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "base_dn": obj.get("base_dn"), + "bind_flow_slug": obj.get("bind_flow_slug"), + "unbind_flow_slug": obj.get("unbind_flow_slug"), + "application_slug": obj.get("application_slug"), + "certificate": obj.get("certificate"), + "tls_server_name": obj.get("tls_server_name"), + "uid_start_number": obj.get("uid_start_number"), + "gid_start_number": obj.get("gid_start_number"), + "search_mode": obj.get("search_mode"), + "bind_mode": obj.get("bind_mode"), + "mfa_support": obj.get("mfa_support") + }) + return _obj + + diff --git a/authentik_client/models/ldap_provider.py b/authentik_client/models/ldap_provider.py new file mode 100644 index 000000000..a8c138db4 --- /dev/null +++ b/authentik_client/models/ldap_provider.py @@ -0,0 +1,186 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.ldapapi_access_mode import LDAPAPIAccessMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LDAPProvider(BaseModel): + """ + LDAPProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + base_dn: Optional[StrictStr] = Field(default=None, description="DN under which objects are accessible.") + certificate: Optional[UUID] = None + tls_server_name: Optional[StrictStr] = None + uid_start_number: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber") + gid_start_number: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber") + outpost_set: List[StrictStr] + search_mode: Optional[LDAPAPIAccessMode] = None + bind_mode: Optional[LDAPAPIAccessMode] = None + mfa_support: Optional[StrictBool] = Field(default=None, description="When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.") + __properties: ClassVar[List[str]] = ["pk", "name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "component", "assigned_application_slug", "assigned_application_name", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "base_dn", "certificate", "tls_server_name", "uid_start_number", "gid_start_number", "outpost_set", "search_mode", "bind_mode", "mfa_support"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LDAPProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_application_slug", + "assigned_application_name", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "outpost_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if assigned_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_slug is None and "assigned_application_slug" in self.model_fields_set: + _dict['assigned_application_slug'] = None + + # set to None if assigned_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_name is None and "assigned_application_name" in self.model_fields_set: + _dict['assigned_application_name'] = None + + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LDAPProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "component": obj.get("component"), + "assigned_application_slug": obj.get("assigned_application_slug"), + "assigned_application_name": obj.get("assigned_application_name"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "base_dn": obj.get("base_dn"), + "certificate": obj.get("certificate"), + "tls_server_name": obj.get("tls_server_name"), + "uid_start_number": obj.get("uid_start_number"), + "gid_start_number": obj.get("gid_start_number"), + "outpost_set": obj.get("outpost_set"), + "search_mode": obj.get("search_mode"), + "bind_mode": obj.get("bind_mode"), + "mfa_support": obj.get("mfa_support") + }) + return _obj + + diff --git a/authentik_client/models/ldap_provider_request.py b/authentik_client/models/ldap_provider_request.py new file mode 100644 index 000000000..512143117 --- /dev/null +++ b/authentik_client/models/ldap_provider_request.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.ldapapi_access_mode import LDAPAPIAccessMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LDAPProviderRequest(BaseModel): + """ + LDAPProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + base_dn: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="DN under which objects are accessible.") + certificate: Optional[UUID] = None + tls_server_name: Optional[StrictStr] = None + uid_start_number: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber") + gid_start_number: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber") + search_mode: Optional[LDAPAPIAccessMode] = None + bind_mode: Optional[LDAPAPIAccessMode] = None + mfa_support: Optional[StrictBool] = Field(default=None, description="When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.") + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "base_dn", "certificate", "tls_server_name", "uid_start_number", "gid_start_number", "search_mode", "bind_mode", "mfa_support"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LDAPProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LDAPProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "base_dn": obj.get("base_dn"), + "certificate": obj.get("certificate"), + "tls_server_name": obj.get("tls_server_name"), + "uid_start_number": obj.get("uid_start_number"), + "gid_start_number": obj.get("gid_start_number"), + "search_mode": obj.get("search_mode"), + "bind_mode": obj.get("bind_mode"), + "mfa_support": obj.get("mfa_support") + }) + return _obj + + diff --git a/authentik_client/models/ldap_source.py b/authentik_client/models/ldap_source.py new file mode 100644 index 000000000..0853427dc --- /dev/null +++ b/authentik_client/models/ldap_source.py @@ -0,0 +1,250 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.sync_outgoing_trigger_mode_enum import SyncOutgoingTriggerModeEnum +from authentik_client.models.themed_urls import ThemedUrls +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LDAPSource(BaseModel): + """ + LDAP Source Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr = Field(description="Source's display Name.") + slug: Annotated[str, Field(strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + managed: Optional[StrictStr] = Field(description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + user_path_template: Optional[StrictStr] = None + icon: Optional[StrictStr] = None + icon_url: StrictStr + icon_themed_urls: Optional[ThemedUrls] + server_uri: StrictStr + peer_certificate: Optional[UUID] = Field(default=None, description="Optionally verify the LDAP Server's Certificate against the CA Chain in this keypair.") + client_certificate: Optional[UUID] = Field(default=None, description="Client certificate to authenticate against the LDAP Server's Certificate.") + bind_cn: Optional[StrictStr] = None + start_tls: Optional[StrictBool] = None + sni: Optional[StrictBool] = None + base_dn: StrictStr + additional_user_dn: Optional[StrictStr] = Field(default=None, description="Prepended to Base DN for User-queries.") + additional_group_dn: Optional[StrictStr] = Field(default=None, description="Prepended to Base DN for Group-queries.") + user_object_filter: Optional[StrictStr] = Field(default=None, description="Consider Objects matching this filter to be Users.") + group_object_filter: Optional[StrictStr] = Field(default=None, description="Consider Objects matching this filter to be Groups.") + group_membership_field: Optional[StrictStr] = Field(default=None, description="Field which contains members of a group.") + user_membership_attribute: Optional[StrictStr] = Field(default=None, description="Attribute which matches the value of `group_membership_field`.") + object_uniqueness_field: Optional[StrictStr] = Field(default=None, description="Field which contains a unique Identifier.") + password_login_update_internal_password: Optional[StrictBool] = Field(default=None, description="Update internal authentik password when login succeeds with LDAP") + sync_users: Optional[StrictBool] = None + sync_users_password: Optional[StrictBool] = Field(default=None, description="When a user changes their password, sync it back to LDAP. This can only be enabled on a single LDAP source.") + sync_groups: Optional[StrictBool] = None + sync_parent_group: Optional[UUID] = None + connectivity: Optional[Dict[str, Dict[str, StrictStr]]] = Field(description="Get cached source connectivity") + lookup_groups_from_user: Optional[StrictBool] = Field(default=None, description="Lookup group membership based on a user attribute instead of a group attribute. This allows nested group resolution on systems like FreeIPA and Active Directory") + delete_not_found_objects: Optional[StrictBool] = Field(default=None, description="Delete authentik users and groups which were previously supplied by this source, but are now missing from it.") + sync_outgoing_trigger_mode: Optional[SyncOutgoingTriggerModeEnum] = Field(default=None, description="When to trigger sync for outgoing providers") + __properties: ClassVar[List[str]] = ["pk", "name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "policy_engine_mode", "user_matching_mode", "managed", "user_path_template", "icon", "icon_url", "icon_themed_urls", "server_uri", "peer_certificate", "client_certificate", "bind_cn", "start_tls", "sni", "base_dn", "additional_user_dn", "additional_group_dn", "user_object_filter", "group_object_filter", "group_membership_field", "user_membership_attribute", "object_uniqueness_field", "password_login_update_internal_password", "sync_users", "sync_users_password", "sync_groups", "sync_parent_group", "connectivity", "lookup_groups_from_user", "delete_not_found_objects", "sync_outgoing_trigger_mode"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LDAPSource from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "managed", + "icon_url", + "icon_themed_urls", + "connectivity", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of icon_themed_urls + if self.icon_themed_urls: + _dict['icon_themed_urls'] = self.icon_themed_urls.to_dict() + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if icon_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.icon_themed_urls is None and "icon_themed_urls" in self.model_fields_set: + _dict['icon_themed_urls'] = None + + # set to None if peer_certificate (nullable) is None + # and model_fields_set contains the field + if self.peer_certificate is None and "peer_certificate" in self.model_fields_set: + _dict['peer_certificate'] = None + + # set to None if client_certificate (nullable) is None + # and model_fields_set contains the field + if self.client_certificate is None and "client_certificate" in self.model_fields_set: + _dict['client_certificate'] = None + + # set to None if sync_parent_group (nullable) is None + # and model_fields_set contains the field + if self.sync_parent_group is None and "sync_parent_group" in self.model_fields_set: + _dict['sync_parent_group'] = None + + # set to None if connectivity (nullable) is None + # and model_fields_set contains the field + if self.connectivity is None and "connectivity" in self.model_fields_set: + _dict['connectivity'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LDAPSource from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "managed": obj.get("managed"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "icon_url": obj.get("icon_url"), + "icon_themed_urls": ThemedUrls.from_dict(obj["icon_themed_urls"]) if obj.get("icon_themed_urls") is not None else None, + "server_uri": obj.get("server_uri"), + "peer_certificate": obj.get("peer_certificate"), + "client_certificate": obj.get("client_certificate"), + "bind_cn": obj.get("bind_cn"), + "start_tls": obj.get("start_tls"), + "sni": obj.get("sni"), + "base_dn": obj.get("base_dn"), + "additional_user_dn": obj.get("additional_user_dn"), + "additional_group_dn": obj.get("additional_group_dn"), + "user_object_filter": obj.get("user_object_filter"), + "group_object_filter": obj.get("group_object_filter"), + "group_membership_field": obj.get("group_membership_field"), + "user_membership_attribute": obj.get("user_membership_attribute"), + "object_uniqueness_field": obj.get("object_uniqueness_field"), + "password_login_update_internal_password": obj.get("password_login_update_internal_password"), + "sync_users": obj.get("sync_users"), + "sync_users_password": obj.get("sync_users_password"), + "sync_groups": obj.get("sync_groups"), + "sync_parent_group": obj.get("sync_parent_group"), + "connectivity": obj.get("connectivity"), + "lookup_groups_from_user": obj.get("lookup_groups_from_user"), + "delete_not_found_objects": obj.get("delete_not_found_objects"), + "sync_outgoing_trigger_mode": obj.get("sync_outgoing_trigger_mode") + }) + return _obj + + diff --git a/authentik_client/models/ldap_source_property_mapping.py b/authentik_client/models/ldap_source_property_mapping.py new file mode 100644 index 000000000..01427bd3c --- /dev/null +++ b/authentik_client/models/ldap_source_property_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LDAPSourcePropertyMapping(BaseModel): + """ + LDAP PropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LDAPSourcePropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LDAPSourcePropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/ldap_source_property_mapping_request.py b/authentik_client/models/ldap_source_property_mapping_request.py new file mode 100644 index 000000000..866098098 --- /dev/null +++ b/authentik_client/models/ldap_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LDAPSourcePropertyMappingRequest(BaseModel): + """ + LDAP PropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LDAPSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LDAPSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/ldap_source_request.py b/authentik_client/models/ldap_source_request.py new file mode 100644 index 000000000..cd65b6c5f --- /dev/null +++ b/authentik_client/models/ldap_source_request.py @@ -0,0 +1,197 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.sync_outgoing_trigger_mode_enum import SyncOutgoingTriggerModeEnum +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LDAPSourceRequest(BaseModel): + """ + LDAP Source Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Source's display Name.") + slug: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + server_uri: Annotated[str, Field(min_length=1, strict=True)] + peer_certificate: Optional[UUID] = Field(default=None, description="Optionally verify the LDAP Server's Certificate against the CA Chain in this keypair.") + client_certificate: Optional[UUID] = Field(default=None, description="Client certificate to authenticate against the LDAP Server's Certificate.") + bind_cn: Optional[StrictStr] = None + bind_password: Optional[StrictStr] = None + start_tls: Optional[StrictBool] = None + sni: Optional[StrictBool] = None + base_dn: Annotated[str, Field(min_length=1, strict=True)] + additional_user_dn: Optional[StrictStr] = Field(default=None, description="Prepended to Base DN for User-queries.") + additional_group_dn: Optional[StrictStr] = Field(default=None, description="Prepended to Base DN for Group-queries.") + user_object_filter: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Consider Objects matching this filter to be Users.") + group_object_filter: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Consider Objects matching this filter to be Groups.") + group_membership_field: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Field which contains members of a group.") + user_membership_attribute: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Attribute which matches the value of `group_membership_field`.") + object_uniqueness_field: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Field which contains a unique Identifier.") + password_login_update_internal_password: Optional[StrictBool] = Field(default=None, description="Update internal authentik password when login succeeds with LDAP") + sync_users: Optional[StrictBool] = None + sync_users_password: Optional[StrictBool] = Field(default=None, description="When a user changes their password, sync it back to LDAP. This can only be enabled on a single LDAP source.") + sync_groups: Optional[StrictBool] = None + sync_parent_group: Optional[UUID] = None + lookup_groups_from_user: Optional[StrictBool] = Field(default=None, description="Lookup group membership based on a user attribute instead of a group attribute. This allows nested group resolution on systems like FreeIPA and Active Directory") + delete_not_found_objects: Optional[StrictBool] = Field(default=None, description="Delete authentik users and groups which were previously supplied by this source, but are now missing from it.") + sync_outgoing_trigger_mode: Optional[SyncOutgoingTriggerModeEnum] = Field(default=None, description="When to trigger sync for outgoing providers") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "server_uri", "peer_certificate", "client_certificate", "bind_cn", "bind_password", "start_tls", "sni", "base_dn", "additional_user_dn", "additional_group_dn", "user_object_filter", "group_object_filter", "group_membership_field", "user_membership_attribute", "object_uniqueness_field", "password_login_update_internal_password", "sync_users", "sync_users_password", "sync_groups", "sync_parent_group", "lookup_groups_from_user", "delete_not_found_objects", "sync_outgoing_trigger_mode"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LDAPSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if peer_certificate (nullable) is None + # and model_fields_set contains the field + if self.peer_certificate is None and "peer_certificate" in self.model_fields_set: + _dict['peer_certificate'] = None + + # set to None if client_certificate (nullable) is None + # and model_fields_set contains the field + if self.client_certificate is None and "client_certificate" in self.model_fields_set: + _dict['client_certificate'] = None + + # set to None if sync_parent_group (nullable) is None + # and model_fields_set contains the field + if self.sync_parent_group is None and "sync_parent_group" in self.model_fields_set: + _dict['sync_parent_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LDAPSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "server_uri": obj.get("server_uri"), + "peer_certificate": obj.get("peer_certificate"), + "client_certificate": obj.get("client_certificate"), + "bind_cn": obj.get("bind_cn"), + "bind_password": obj.get("bind_password"), + "start_tls": obj.get("start_tls"), + "sni": obj.get("sni"), + "base_dn": obj.get("base_dn"), + "additional_user_dn": obj.get("additional_user_dn"), + "additional_group_dn": obj.get("additional_group_dn"), + "user_object_filter": obj.get("user_object_filter"), + "group_object_filter": obj.get("group_object_filter"), + "group_membership_field": obj.get("group_membership_field"), + "user_membership_attribute": obj.get("user_membership_attribute"), + "object_uniqueness_field": obj.get("object_uniqueness_field"), + "password_login_update_internal_password": obj.get("password_login_update_internal_password"), + "sync_users": obj.get("sync_users"), + "sync_users_password": obj.get("sync_users_password"), + "sync_groups": obj.get("sync_groups"), + "sync_parent_group": obj.get("sync_parent_group"), + "lookup_groups_from_user": obj.get("lookup_groups_from_user"), + "delete_not_found_objects": obj.get("delete_not_found_objects"), + "sync_outgoing_trigger_mode": obj.get("sync_outgoing_trigger_mode") + }) + return _obj + + diff --git a/authentik_client/models/ldapapi_access_mode.py b/authentik_client/models/ldapapi_access_mode.py new file mode 100644 index 000000000..96567f981 --- /dev/null +++ b/authentik_client/models/ldapapi_access_mode.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class LDAPAPIAccessMode(str, Enum): + """ + LDAPAPIAccessMode + """ + + """ + allowed enum values + """ + DIRECT = 'direct' + CACHED = 'cached' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of LDAPAPIAccessMode from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/license.py b/authentik_client/models/license.py new file mode 100644 index 000000000..07e3cfafb --- /dev/null +++ b/authentik_client/models/license.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class License(BaseModel): + """ + License Serializer + """ # noqa: E501 + license_uuid: UUID + name: StrictStr + key: StrictStr + expiry: datetime + internal_users: StrictInt + external_users: StrictInt + __properties: ClassVar[List[str]] = ["license_uuid", "name", "key", "expiry", "internal_users", "external_users"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of License from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "license_uuid", + "name", + "expiry", + "internal_users", + "external_users", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of License from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "license_uuid": obj.get("license_uuid"), + "name": obj.get("name"), + "key": obj.get("key"), + "expiry": obj.get("expiry"), + "internal_users": obj.get("internal_users"), + "external_users": obj.get("external_users") + }) + return _obj + + diff --git a/authentik_client/models/license_flags_enum.py b/authentik_client/models/license_flags_enum.py new file mode 100644 index 000000000..8615ae80e --- /dev/null +++ b/authentik_client/models/license_flags_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class LicenseFlagsEnum(str, Enum): + """ + LicenseFlagsEnum + """ + + """ + allowed enum values + """ + TRIAL = 'trial' + NON_PRODUCTION = 'non_production' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of LicenseFlagsEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/license_forecast.py b/authentik_client/models/license_forecast.py new file mode 100644 index 000000000..e6d4149d5 --- /dev/null +++ b/authentik_client/models/license_forecast.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LicenseForecast(BaseModel): + """ + Serializer for license forecast + """ # noqa: E501 + internal_users: StrictInt + external_users: StrictInt + forecasted_internal_users: StrictInt + forecasted_external_users: StrictInt + __properties: ClassVar[List[str]] = ["internal_users", "external_users", "forecasted_internal_users", "forecasted_external_users"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LicenseForecast from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LicenseForecast from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "internal_users": obj.get("internal_users"), + "external_users": obj.get("external_users"), + "forecasted_internal_users": obj.get("forecasted_internal_users"), + "forecasted_external_users": obj.get("forecasted_external_users") + }) + return _obj + + diff --git a/authentik_client/models/license_request.py b/authentik_client/models/license_request.py new file mode 100644 index 000000000..69badf55c --- /dev/null +++ b/authentik_client/models/license_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LicenseRequest(BaseModel): + """ + License Serializer + """ # noqa: E501 + key: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["key"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LicenseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LicenseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "key": obj.get("key") + }) + return _obj + + diff --git a/authentik_client/models/license_status_enum.py b/authentik_client/models/license_status_enum.py new file mode 100644 index 000000000..1955d0e62 --- /dev/null +++ b/authentik_client/models/license_status_enum.py @@ -0,0 +1,43 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class LicenseStatusEnum(str, Enum): + """ + LicenseStatusEnum + """ + + """ + allowed enum values + """ + UNLICENSED = 'unlicensed' + VALID = 'valid' + EXPIRED = 'expired' + EXPIRY_SOON = 'expiry_soon' + LIMIT_EXCEEDED_ADMIN = 'limit_exceeded_admin' + LIMIT_EXCEEDED_USER = 'limit_exceeded_user' + READ_ONLY = 'read_only' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of LicenseStatusEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/license_summary.py b/authentik_client/models/license_summary.py new file mode 100644 index 000000000..16a6e5374 --- /dev/null +++ b/authentik_client/models/license_summary.py @@ -0,0 +1,100 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from authentik_client.models.license_flags_enum import LicenseFlagsEnum +from authentik_client.models.license_summary_status_enum import LicenseSummaryStatusEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LicenseSummary(BaseModel): + """ + Serializer for license status + """ # noqa: E501 + internal_users: StrictInt + external_users: StrictInt + status: LicenseSummaryStatusEnum + latest_valid: datetime + license_flags: List[LicenseFlagsEnum] + __properties: ClassVar[List[str]] = ["internal_users", "external_users", "status", "latest_valid", "license_flags"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LicenseSummary from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LicenseSummary from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "internal_users": obj.get("internal_users"), + "external_users": obj.get("external_users"), + "status": obj.get("status"), + "latest_valid": obj.get("latest_valid"), + "license_flags": obj.get("license_flags") + }) + return _obj + + diff --git a/authentik_client/models/license_summary_status_enum.py b/authentik_client/models/license_summary_status_enum.py new file mode 100644 index 000000000..b9f5e8799 --- /dev/null +++ b/authentik_client/models/license_summary_status_enum.py @@ -0,0 +1,43 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class LicenseSummaryStatusEnum(str, Enum): + """ + LicenseSummaryStatusEnum + """ + + """ + allowed enum values + """ + UNLICENSED = 'unlicensed' + VALID = 'valid' + EXPIRED = 'expired' + EXPIRY_SOON = 'expiry_soon' + LIMIT_EXCEEDED_ADMIN = 'limit_exceeded_admin' + LIMIT_EXCEEDED_USER = 'limit_exceeded_user' + READ_ONLY = 'read_only' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of LicenseSummaryStatusEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/lifecycle_iteration.py b/authentik_client/models/lifecycle_iteration.py new file mode 100644 index 000000000..b9c0dce28 --- /dev/null +++ b/authentik_client/models/lifecycle_iteration.py @@ -0,0 +1,149 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.content_type_enum import ContentTypeEnum +from authentik_client.models.lifecycle_iteration_state_enum import LifecycleIterationStateEnum +from authentik_client.models.related_rule import RelatedRule +from authentik_client.models.review import Review +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LifecycleIteration(BaseModel): + """ + Mixin to validate that a valid enterprise license exists before allowing to save the object + """ # noqa: E501 + id: UUID + content_type: ContentTypeEnum + object_id: StrictStr + object_verbose: StrictStr + object_admin_url: StrictStr + state: LifecycleIterationStateEnum + opened_on: datetime + grace_period_end: datetime + next_review_date: datetime + reviews: List[Review] + rule: RelatedRule + user_can_review: StrictBool + __properties: ClassVar[List[str]] = ["id", "content_type", "object_id", "object_verbose", "object_admin_url", "state", "opened_on", "grace_period_end", "next_review_date", "reviews", "rule", "user_can_review"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LifecycleIteration from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "object_id", + "object_verbose", + "object_admin_url", + "state", + "opened_on", + "grace_period_end", + "next_review_date", + "reviews", + "rule", + "user_can_review", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in reviews (list) + _items = [] + if self.reviews: + for _item_reviews in self.reviews: + if _item_reviews: + _items.append(_item_reviews.to_dict()) + _dict['reviews'] = _items + # override the default output from pydantic by calling `to_dict()` of rule + if self.rule: + _dict['rule'] = self.rule.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LifecycleIteration from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "content_type": obj.get("content_type"), + "object_id": obj.get("object_id"), + "object_verbose": obj.get("object_verbose"), + "object_admin_url": obj.get("object_admin_url"), + "state": obj.get("state"), + "opened_on": obj.get("opened_on"), + "grace_period_end": obj.get("grace_period_end"), + "next_review_date": obj.get("next_review_date"), + "reviews": [Review.from_dict(_item) for _item in obj["reviews"]] if obj.get("reviews") is not None else None, + "rule": RelatedRule.from_dict(obj["rule"]) if obj.get("rule") is not None else None, + "user_can_review": obj.get("user_can_review") + }) + return _obj + + diff --git a/authentik_client/models/lifecycle_iteration_request.py b/authentik_client/models/lifecycle_iteration_request.py new file mode 100644 index 000000000..07213ba41 --- /dev/null +++ b/authentik_client/models/lifecycle_iteration_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.content_type_enum import ContentTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LifecycleIterationRequest(BaseModel): + """ + Mixin to validate that a valid enterprise license exists before allowing to save the object + """ # noqa: E501 + content_type: ContentTypeEnum + __properties: ClassVar[List[str]] = ["content_type"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LifecycleIterationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LifecycleIterationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "content_type": obj.get("content_type") + }) + return _obj + + diff --git a/authentik_client/models/lifecycle_iteration_state_enum.py b/authentik_client/models/lifecycle_iteration_state_enum.py new file mode 100644 index 000000000..b7b468043 --- /dev/null +++ b/authentik_client/models/lifecycle_iteration_state_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class LifecycleIterationStateEnum(str, Enum): + """ + LifecycleIterationStateEnum + """ + + """ + allowed enum values + """ + REVIEWED = 'REVIEWED' + PENDING = 'PENDING' + OVERDUE = 'OVERDUE' + CANCELED = 'CANCELED' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of LifecycleIterationStateEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/lifecycle_rule.py b/authentik_client/models/lifecycle_rule.py new file mode 100644 index 000000000..6e591c8a5 --- /dev/null +++ b/authentik_client/models/lifecycle_rule.py @@ -0,0 +1,147 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.content_type_enum import ContentTypeEnum +from authentik_client.models.reviewer_group import ReviewerGroup +from authentik_client.models.reviewer_user import ReviewerUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LifecycleRule(BaseModel): + """ + Mixin to validate that a valid enterprise license exists before allowing to save the object + """ # noqa: E501 + id: UUID + name: StrictStr + content_type: ContentTypeEnum + object_id: Optional[StrictStr] = None + interval: Optional[StrictStr] = None + grace_period: Optional[StrictStr] = None + reviewer_groups: Optional[List[UUID]] = None + reviewer_groups_obj: List[ReviewerGroup] + min_reviewers: Optional[Annotated[int, Field(le=32767, strict=True, ge=0)]] = None + min_reviewers_is_per_group: Optional[StrictBool] = None + reviewers: List[UUID] + reviewers_obj: List[ReviewerUser] + notification_transports: Optional[List[UUID]] = Field(default=None, description="Select which transports should be used to notify the reviewers. If none are selected, the notification will only be shown in the authentik UI.") + target_verbose: StrictStr + __properties: ClassVar[List[str]] = ["id", "name", "content_type", "object_id", "interval", "grace_period", "reviewer_groups", "reviewer_groups_obj", "min_reviewers", "min_reviewers_is_per_group", "reviewers", "reviewers_obj", "notification_transports", "target_verbose"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LifecycleRule from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "reviewer_groups_obj", + "reviewers_obj", + "target_verbose", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in reviewer_groups_obj (list) + _items = [] + if self.reviewer_groups_obj: + for _item_reviewer_groups_obj in self.reviewer_groups_obj: + if _item_reviewer_groups_obj: + _items.append(_item_reviewer_groups_obj.to_dict()) + _dict['reviewer_groups_obj'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in reviewers_obj (list) + _items = [] + if self.reviewers_obj: + for _item_reviewers_obj in self.reviewers_obj: + if _item_reviewers_obj: + _items.append(_item_reviewers_obj.to_dict()) + _dict['reviewers_obj'] = _items + # set to None if object_id (nullable) is None + # and model_fields_set contains the field + if self.object_id is None and "object_id" in self.model_fields_set: + _dict['object_id'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LifecycleRule from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "name": obj.get("name"), + "content_type": obj.get("content_type"), + "object_id": obj.get("object_id"), + "interval": obj.get("interval"), + "grace_period": obj.get("grace_period"), + "reviewer_groups": obj.get("reviewer_groups"), + "reviewer_groups_obj": [ReviewerGroup.from_dict(_item) for _item in obj["reviewer_groups_obj"]] if obj.get("reviewer_groups_obj") is not None else None, + "min_reviewers": obj.get("min_reviewers"), + "min_reviewers_is_per_group": obj.get("min_reviewers_is_per_group"), + "reviewers": obj.get("reviewers"), + "reviewers_obj": [ReviewerUser.from_dict(_item) for _item in obj["reviewers_obj"]] if obj.get("reviewers_obj") is not None else None, + "notification_transports": obj.get("notification_transports"), + "target_verbose": obj.get("target_verbose") + }) + return _obj + + diff --git a/authentik_client/models/lifecycle_rule_request.py b/authentik_client/models/lifecycle_rule_request.py new file mode 100644 index 000000000..d28966795 --- /dev/null +++ b/authentik_client/models/lifecycle_rule_request.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.content_type_enum import ContentTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LifecycleRuleRequest(BaseModel): + """ + Mixin to validate that a valid enterprise license exists before allowing to save the object + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + content_type: ContentTypeEnum + object_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + interval: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + grace_period: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + reviewer_groups: Optional[List[UUID]] = None + min_reviewers: Optional[Annotated[int, Field(le=32767, strict=True, ge=0)]] = None + min_reviewers_is_per_group: Optional[StrictBool] = None + reviewers: List[UUID] + notification_transports: Optional[List[UUID]] = Field(default=None, description="Select which transports should be used to notify the reviewers. If none are selected, the notification will only be shown in the authentik UI.") + __properties: ClassVar[List[str]] = ["name", "content_type", "object_id", "interval", "grace_period", "reviewer_groups", "min_reviewers", "min_reviewers_is_per_group", "reviewers", "notification_transports"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LifecycleRuleRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if object_id (nullable) is None + # and model_fields_set contains the field + if self.object_id is None and "object_id" in self.model_fields_set: + _dict['object_id'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LifecycleRuleRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "content_type": obj.get("content_type"), + "object_id": obj.get("object_id"), + "interval": obj.get("interval"), + "grace_period": obj.get("grace_period"), + "reviewer_groups": obj.get("reviewer_groups"), + "min_reviewers": obj.get("min_reviewers"), + "min_reviewers_is_per_group": obj.get("min_reviewers_is_per_group"), + "reviewers": obj.get("reviewers"), + "notification_transports": obj.get("notification_transports") + }) + return _obj + + diff --git a/authentik_client/models/link.py b/authentik_client/models/link.py new file mode 100644 index 000000000..a4a898bc7 --- /dev/null +++ b/authentik_client/models/link.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Link(BaseModel): + """ + Returns a single link + """ # noqa: E501 + link: StrictStr + __properties: ClassVar[List[str]] = ["link"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Link from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Link from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "link": obj.get("link") + }) + return _obj + + diff --git a/authentik_client/models/log_event.py b/authentik_client/models/log_event.py new file mode 100644 index 000000000..fb9da94dd --- /dev/null +++ b/authentik_client/models/log_event.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from authentik_client.models.log_level_enum import LogLevelEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LogEvent(BaseModel): + """ + Single log message with all context logged. + """ # noqa: E501 + timestamp: datetime + log_level: LogLevelEnum + logger: StrictStr + event: StrictStr + attributes: Dict[str, Any] + __properties: ClassVar[List[str]] = ["timestamp", "log_level", "logger", "event", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LogEvent from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LogEvent from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "timestamp": obj.get("timestamp"), + "log_level": obj.get("log_level"), + "logger": obj.get("logger"), + "event": obj.get("event"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/log_level_enum.py b/authentik_client/models/log_level_enum.py new file mode 100644 index 000000000..4ab9cad32 --- /dev/null +++ b/authentik_client/models/log_level_enum.py @@ -0,0 +1,44 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class LogLevelEnum(str, Enum): + """ + LogLevelEnum + """ + + """ + allowed enum values + """ + CRITICAL = 'critical' + EXCEPTION = 'exception' + ERROR = 'error' + WARN = 'warn' + WARNING = 'warning' + INFO = 'info' + DEBUG = 'debug' + NOTSET = 'notset' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of LogLevelEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/login_challenge_types.py b/authentik_client/models/login_challenge_types.py new file mode 100644 index 000000000..c9b215c4e --- /dev/null +++ b/authentik_client/models/login_challenge_types.py @@ -0,0 +1,169 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +import pprint +from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator +from typing import Any, List, Optional +from authentik_client.models.apple_login_challenge import AppleLoginChallenge +from authentik_client.models.plex_authentication_challenge import PlexAuthenticationChallenge +from authentik_client.models.redirect_challenge import RedirectChallenge +from authentik_client.models.telegram_login_challenge import TelegramLoginChallenge +from pydantic import StrictStr, Field +from typing import Union, List, Set, Optional, Dict +from typing_extensions import Literal, Self + +LOGINCHALLENGETYPES_ONE_OF_SCHEMAS = ["AppleLoginChallenge", "PlexAuthenticationChallenge", "RedirectChallenge", "TelegramLoginChallenge"] + +class LoginChallengeTypes(BaseModel): + """ + LoginChallengeTypes + """ + # data type: RedirectChallenge + oneof_schema_1_validator: Optional[RedirectChallenge] = None + # data type: AppleLoginChallenge + oneof_schema_2_validator: Optional[AppleLoginChallenge] = None + # data type: PlexAuthenticationChallenge + oneof_schema_3_validator: Optional[PlexAuthenticationChallenge] = None + # data type: TelegramLoginChallenge + oneof_schema_4_validator: Optional[TelegramLoginChallenge] = None + actual_instance: Optional[Union[AppleLoginChallenge, PlexAuthenticationChallenge, RedirectChallenge, TelegramLoginChallenge]] = None + one_of_schemas: Set[str] = { "AppleLoginChallenge", "PlexAuthenticationChallenge", "RedirectChallenge", "TelegramLoginChallenge" } + + model_config = ConfigDict( + validate_assignment=True, + protected_namespaces=(), + ) + + + discriminator_value_class_map: Dict[str, str] = { + } + + def __init__(self, *args, **kwargs) -> None: + if args: + if len(args) > 1: + raise ValueError("If a position argument is used, only 1 is allowed to set `actual_instance`") + if kwargs: + raise ValueError("If a position argument is used, keyword arguments cannot be used.") + super().__init__(actual_instance=args[0]) + else: + super().__init__(**kwargs) + + @field_validator('actual_instance') + def actual_instance_must_validate_oneof(cls, v): + instance = LoginChallengeTypes.model_construct() + error_messages = [] + match = 0 + # validate data type: RedirectChallenge + if not isinstance(v, RedirectChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `RedirectChallenge`") + else: + match += 1 + # validate data type: AppleLoginChallenge + if not isinstance(v, AppleLoginChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `AppleLoginChallenge`") + else: + match += 1 + # validate data type: PlexAuthenticationChallenge + if not isinstance(v, PlexAuthenticationChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `PlexAuthenticationChallenge`") + else: + match += 1 + # validate data type: TelegramLoginChallenge + if not isinstance(v, TelegramLoginChallenge): + error_messages.append(f"Error! Input type `{type(v)}` is not `TelegramLoginChallenge`") + else: + match += 1 + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when setting `actual_instance` in LoginChallengeTypes with oneOf schemas: AppleLoginChallenge, PlexAuthenticationChallenge, RedirectChallenge, TelegramLoginChallenge. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when setting `actual_instance` in LoginChallengeTypes with oneOf schemas: AppleLoginChallenge, PlexAuthenticationChallenge, RedirectChallenge, TelegramLoginChallenge. Details: " + ", ".join(error_messages)) + else: + return v + + @classmethod + def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self: + return cls.from_json(json.dumps(obj)) + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Returns the object represented by the json string""" + instance = cls.model_construct() + error_messages = [] + match = 0 + + # deserialize data into RedirectChallenge + try: + instance.actual_instance = RedirectChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into AppleLoginChallenge + try: + instance.actual_instance = AppleLoginChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into PlexAuthenticationChallenge + try: + instance.actual_instance = PlexAuthenticationChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into TelegramLoginChallenge + try: + instance.actual_instance = TelegramLoginChallenge.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when deserializing the JSON string into LoginChallengeTypes with oneOf schemas: AppleLoginChallenge, PlexAuthenticationChallenge, RedirectChallenge, TelegramLoginChallenge. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when deserializing the JSON string into LoginChallengeTypes with oneOf schemas: AppleLoginChallenge, PlexAuthenticationChallenge, RedirectChallenge, TelegramLoginChallenge. Details: " + ", ".join(error_messages)) + else: + return instance + + def to_json(self) -> str: + """Returns the JSON representation of the actual instance""" + if self.actual_instance is None: + return "null" + + if hasattr(self.actual_instance, "to_json") and callable(self.actual_instance.to_json): + return self.actual_instance.to_json() + else: + return json.dumps(self.actual_instance) + + def to_dict(self) -> Optional[Union[Dict[str, Any], AppleLoginChallenge, PlexAuthenticationChallenge, RedirectChallenge, TelegramLoginChallenge]]: + """Returns the dict representation of the actual instance""" + if self.actual_instance is None: + return None + + if hasattr(self.actual_instance, "to_dict") and callable(self.actual_instance.to_dict): + return self.actual_instance.to_dict() + else: + # primitive type + return self.actual_instance + + def to_str(self) -> str: + """Returns the string representation of the actual instance""" + return pprint.pformat(self.model_dump()) + + diff --git a/authentik_client/models/login_source.py b/authentik_client/models/login_source.py new file mode 100644 index 000000000..e627f37ff --- /dev/null +++ b/authentik_client/models/login_source.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.login_challenge_types import LoginChallengeTypes +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LoginSource(BaseModel): + """ + Serializer for Login buttons of sources + """ # noqa: E501 + name: StrictStr + icon_url: Optional[StrictStr] = None + promoted: Optional[StrictBool] = False + challenge: LoginChallengeTypes + __properties: ClassVar[List[str]] = ["name", "icon_url", "promoted", "challenge"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LoginSource from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of challenge + if self.challenge: + _dict['challenge'] = self.challenge.to_dict() + # set to None if icon_url (nullable) is None + # and model_fields_set contains the field + if self.icon_url is None and "icon_url" in self.model_fields_set: + _dict['icon_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LoginSource from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "icon_url": obj.get("icon_url"), + "promoted": obj.get("promoted") if obj.get("promoted") is not None else False, + "challenge": LoginChallengeTypes.from_dict(obj["challenge"]) if obj.get("challenge") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/logout_url.py b/authentik_client/models/logout_url.py new file mode 100644 index 000000000..eb2f2e654 --- /dev/null +++ b/authentik_client/models/logout_url.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class LogoutURL(BaseModel): + """ + Data for a single logout URL + """ # noqa: E501 + url: StrictStr + provider_name: Optional[StrictStr] = None + binding: Optional[StrictStr] = None + saml_request: Optional[StrictStr] = None + saml_response: Optional[StrictStr] = None + saml_relay_state: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["url", "provider_name", "binding", "saml_request", "saml_response", "saml_relay_state"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of LogoutURL from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if provider_name (nullable) is None + # and model_fields_set contains the field + if self.provider_name is None and "provider_name" in self.model_fields_set: + _dict['provider_name'] = None + + # set to None if binding (nullable) is None + # and model_fields_set contains the field + if self.binding is None and "binding" in self.model_fields_set: + _dict['binding'] = None + + # set to None if saml_request (nullable) is None + # and model_fields_set contains the field + if self.saml_request is None and "saml_request" in self.model_fields_set: + _dict['saml_request'] = None + + # set to None if saml_response (nullable) is None + # and model_fields_set contains the field + if self.saml_response is None and "saml_response" in self.model_fields_set: + _dict['saml_response'] = None + + # set to None if saml_relay_state (nullable) is None + # and model_fields_set contains the field + if self.saml_relay_state is None and "saml_relay_state" in self.model_fields_set: + _dict['saml_relay_state'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of LogoutURL from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "url": obj.get("url"), + "provider_name": obj.get("provider_name"), + "binding": obj.get("binding"), + "saml_request": obj.get("saml_request"), + "saml_response": obj.get("saml_response"), + "saml_relay_state": obj.get("saml_relay_state") + }) + return _obj + + diff --git a/authentik_client/models/matching_mode_enum.py b/authentik_client/models/matching_mode_enum.py new file mode 100644 index 000000000..a4e550d2e --- /dev/null +++ b/authentik_client/models/matching_mode_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class MatchingModeEnum(str, Enum): + """ + MatchingModeEnum + """ + + """ + allowed enum values + """ + STRICT = 'strict' + REGEX = 'regex' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of MatchingModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/mdm_config_request.py b/authentik_client/models/mdm_config_request.py new file mode 100644 index 000000000..c61e429cf --- /dev/null +++ b/authentik_client/models/mdm_config_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.device_facts_os_family import DeviceFactsOSFamily +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MDMConfigRequest(BaseModel): + """ + Base serializer class which doesn't implement create/update methods + """ # noqa: E501 + platform: DeviceFactsOSFamily + enrollment_token: UUID + __properties: ClassVar[List[str]] = ["platform", "enrollment_token"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MDMConfigRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MDMConfigRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "platform": obj.get("platform"), + "enrollment_token": obj.get("enrollment_token") + }) + return _obj + + diff --git a/authentik_client/models/mdm_config_response.py b/authentik_client/models/mdm_config_response.py new file mode 100644 index 000000000..12cf13cb1 --- /dev/null +++ b/authentik_client/models/mdm_config_response.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MDMConfigResponse(BaseModel): + """ + Base serializer class which doesn't implement create/update methods + """ # noqa: E501 + config: StrictStr + mime_type: StrictStr + filename: StrictStr + __properties: ClassVar[List[str]] = ["config", "mime_type", "filename"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MDMConfigResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MDMConfigResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "config": obj.get("config"), + "mime_type": obj.get("mime_type"), + "filename": obj.get("filename") + }) + return _obj + + diff --git a/authentik_client/models/metadata.py b/authentik_client/models/metadata.py new file mode 100644 index 000000000..c5268b115 --- /dev/null +++ b/authentik_client/models/metadata.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Metadata(BaseModel): + """ + Serializer for blueprint metadata + """ # noqa: E501 + name: StrictStr + labels: Dict[str, Any] + __properties: ClassVar[List[str]] = ["name", "labels"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Metadata from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Metadata from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "labels": obj.get("labels") + }) + return _obj + + diff --git a/authentik_client/models/microsoft_entra_provider.py b/authentik_client/models/microsoft_entra_provider.py new file mode 100644 index 000000000..ffb99075f --- /dev/null +++ b/authentik_client/models/microsoft_entra_provider.py @@ -0,0 +1,157 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.outgoing_sync_delete_action import OutgoingSyncDeleteAction +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MicrosoftEntraProvider(BaseModel): + """ + MicrosoftEntraProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + property_mappings: Optional[List[UUID]] = None + property_mappings_group: Optional[List[UUID]] = Field(default=None, description="Property mappings used for group creation/updating.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + client_id: StrictStr + tenant_id: StrictStr + exclude_users_service_account: Optional[StrictBool] = None + filter_group: Optional[UUID] = None + user_delete_action: Optional[OutgoingSyncDeleteAction] = None + group_delete_action: Optional[OutgoingSyncDeleteAction] = None + sync_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Controls the number of objects synced in a single task") + sync_page_timeout: Optional[StrictStr] = Field(default=None, description="Timeout for synchronization of a single page") + dry_run: Optional[StrictBool] = Field(default=None, description="When enabled, provider will not modify or create objects in the remote system.") + __properties: ClassVar[List[str]] = ["pk", "name", "property_mappings", "property_mappings_group", "component", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "client_id", "tenant_id", "exclude_users_service_account", "filter_group", "user_delete_action", "group_delete_action", "sync_page_size", "sync_page_timeout", "dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MicrosoftEntraProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + # set to None if filter_group (nullable) is None + # and model_fields_set contains the field + if self.filter_group is None and "filter_group" in self.model_fields_set: + _dict['filter_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MicrosoftEntraProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "property_mappings": obj.get("property_mappings"), + "property_mappings_group": obj.get("property_mappings_group"), + "component": obj.get("component"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "client_id": obj.get("client_id"), + "tenant_id": obj.get("tenant_id"), + "exclude_users_service_account": obj.get("exclude_users_service_account"), + "filter_group": obj.get("filter_group"), + "user_delete_action": obj.get("user_delete_action"), + "group_delete_action": obj.get("group_delete_action"), + "sync_page_size": obj.get("sync_page_size"), + "sync_page_timeout": obj.get("sync_page_timeout"), + "dry_run": obj.get("dry_run") + }) + return _obj + + diff --git a/authentik_client/models/microsoft_entra_provider_group.py b/authentik_client/models/microsoft_entra_provider_group.py new file mode 100644 index 000000000..fe012d3e1 --- /dev/null +++ b/authentik_client/models/microsoft_entra_provider_group.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.partial_group import PartialGroup +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MicrosoftEntraProviderGroup(BaseModel): + """ + MicrosoftEntraProviderGroup Serializer + """ # noqa: E501 + id: UUID + microsoft_id: StrictStr + group: UUID + group_obj: PartialGroup + provider: StrictInt + attributes: Dict[str, Any] + __properties: ClassVar[List[str]] = ["id", "microsoft_id", "group", "group_obj", "provider", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderGroup from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "group_obj", + "attributes", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of group_obj + if self.group_obj: + _dict['group_obj'] = self.group_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderGroup from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "microsoft_id": obj.get("microsoft_id"), + "group": obj.get("group"), + "group_obj": PartialGroup.from_dict(obj["group_obj"]) if obj.get("group_obj") is not None else None, + "provider": obj.get("provider"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/microsoft_entra_provider_group_request.py b/authentik_client/models/microsoft_entra_provider_group_request.py new file mode 100644 index 000000000..f81a6ff18 --- /dev/null +++ b/authentik_client/models/microsoft_entra_provider_group_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MicrosoftEntraProviderGroupRequest(BaseModel): + """ + MicrosoftEntraProviderGroup Serializer + """ # noqa: E501 + microsoft_id: Annotated[str, Field(min_length=1, strict=True)] + group: UUID + provider: StrictInt + __properties: ClassVar[List[str]] = ["microsoft_id", "group", "provider"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderGroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderGroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "microsoft_id": obj.get("microsoft_id"), + "group": obj.get("group"), + "provider": obj.get("provider") + }) + return _obj + + diff --git a/authentik_client/models/microsoft_entra_provider_mapping.py b/authentik_client/models/microsoft_entra_provider_mapping.py new file mode 100644 index 000000000..475b06e50 --- /dev/null +++ b/authentik_client/models/microsoft_entra_provider_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MicrosoftEntraProviderMapping(BaseModel): + """ + MicrosoftEntraProviderMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/microsoft_entra_provider_mapping_request.py b/authentik_client/models/microsoft_entra_provider_mapping_request.py new file mode 100644 index 000000000..b5c3a4271 --- /dev/null +++ b/authentik_client/models/microsoft_entra_provider_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MicrosoftEntraProviderMappingRequest(BaseModel): + """ + MicrosoftEntraProviderMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/microsoft_entra_provider_request.py b/authentik_client/models/microsoft_entra_provider_request.py new file mode 100644 index 000000000..7e5d72e4b --- /dev/null +++ b/authentik_client/models/microsoft_entra_provider_request.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.outgoing_sync_delete_action import OutgoingSyncDeleteAction +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MicrosoftEntraProviderRequest(BaseModel): + """ + MicrosoftEntraProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + property_mappings: Optional[List[UUID]] = None + property_mappings_group: Optional[List[UUID]] = Field(default=None, description="Property mappings used for group creation/updating.") + client_id: Annotated[str, Field(min_length=1, strict=True)] + client_secret: Annotated[str, Field(min_length=1, strict=True)] + tenant_id: Annotated[str, Field(min_length=1, strict=True)] + exclude_users_service_account: Optional[StrictBool] = None + filter_group: Optional[UUID] = None + user_delete_action: Optional[OutgoingSyncDeleteAction] = None + group_delete_action: Optional[OutgoingSyncDeleteAction] = None + sync_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Controls the number of objects synced in a single task") + sync_page_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Timeout for synchronization of a single page") + dry_run: Optional[StrictBool] = Field(default=None, description="When enabled, provider will not modify or create objects in the remote system.") + __properties: ClassVar[List[str]] = ["name", "property_mappings", "property_mappings_group", "client_id", "client_secret", "tenant_id", "exclude_users_service_account", "filter_group", "user_delete_action", "group_delete_action", "sync_page_size", "sync_page_timeout", "dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if filter_group (nullable) is None + # and model_fields_set contains the field + if self.filter_group is None and "filter_group" in self.model_fields_set: + _dict['filter_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "property_mappings": obj.get("property_mappings"), + "property_mappings_group": obj.get("property_mappings_group"), + "client_id": obj.get("client_id"), + "client_secret": obj.get("client_secret"), + "tenant_id": obj.get("tenant_id"), + "exclude_users_service_account": obj.get("exclude_users_service_account"), + "filter_group": obj.get("filter_group"), + "user_delete_action": obj.get("user_delete_action"), + "group_delete_action": obj.get("group_delete_action"), + "sync_page_size": obj.get("sync_page_size"), + "sync_page_timeout": obj.get("sync_page_timeout"), + "dry_run": obj.get("dry_run") + }) + return _obj + + diff --git a/authentik_client/models/microsoft_entra_provider_user.py b/authentik_client/models/microsoft_entra_provider_user.py new file mode 100644 index 000000000..b6a1bbe09 --- /dev/null +++ b/authentik_client/models/microsoft_entra_provider_user.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MicrosoftEntraProviderUser(BaseModel): + """ + MicrosoftEntraProviderUser Serializer + """ # noqa: E501 + id: UUID + microsoft_id: StrictStr + user: StrictInt + user_obj: PartialUser + provider: StrictInt + attributes: Dict[str, Any] + __properties: ClassVar[List[str]] = ["id", "microsoft_id", "user", "user_obj", "provider", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderUser from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "user_obj", + "attributes", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user_obj + if self.user_obj: + _dict['user_obj'] = self.user_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderUser from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "microsoft_id": obj.get("microsoft_id"), + "user": obj.get("user"), + "user_obj": PartialUser.from_dict(obj["user_obj"]) if obj.get("user_obj") is not None else None, + "provider": obj.get("provider"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/microsoft_entra_provider_user_request.py b/authentik_client/models/microsoft_entra_provider_user_request.py new file mode 100644 index 000000000..22f7b40e9 --- /dev/null +++ b/authentik_client/models/microsoft_entra_provider_user_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MicrosoftEntraProviderUserRequest(BaseModel): + """ + MicrosoftEntraProviderUser Serializer + """ # noqa: E501 + microsoft_id: Annotated[str, Field(min_length=1, strict=True)] + user: StrictInt + provider: StrictInt + __properties: ClassVar[List[str]] = ["microsoft_id", "user", "provider"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderUserRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MicrosoftEntraProviderUserRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "microsoft_id": obj.get("microsoft_id"), + "user": obj.get("user"), + "provider": obj.get("provider") + }) + return _obj + + diff --git a/authentik_client/models/model_enum.py b/authentik_client/models/model_enum.py new file mode 100644 index 000000000..1d46952ad --- /dev/null +++ b/authentik_client/models/model_enum.py @@ -0,0 +1,158 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ModelEnum(str, Enum): + """ + ModelEnum + """ + + """ + allowed enum values + """ + AUTHENTIK_TENANTS_DOT_DOMAIN = 'authentik_tenants.domain' + AUTHENTIK_CORE_DOT_GROUP = 'authentik_core.group' + AUTHENTIK_CORE_DOT_USER = 'authentik_core.user' + AUTHENTIK_CORE_DOT_APPLICATION = 'authentik_core.application' + AUTHENTIK_CORE_DOT_APPLICATIONENTITLEMENT = 'authentik_core.applicationentitlement' + AUTHENTIK_CORE_DOT_TOKEN = 'authentik_core.token' + AUTHENTIK_CRYPTO_DOT_CERTIFICATEKEYPAIR = 'authentik_crypto.certificatekeypair' + AUTHENTIK_ENDPOINTS_DOT_DEVICEUSERBINDING = 'authentik_endpoints.deviceuserbinding' + AUTHENTIK_ENDPOINTS_DOT_DEVICEACCESSGROUP = 'authentik_endpoints.deviceaccessgroup' + AUTHENTIK_ENDPOINTS_DOT_ENDPOINTSTAGE = 'authentik_endpoints.endpointstage' + AUTHENTIK_ENDPOINTS_CONNECTORS_AGENT_DOT_AGENTCONNECTOR = 'authentik_endpoints_connectors_agent.agentconnector' + AUTHENTIK_ENDPOINTS_CONNECTORS_AGENT_DOT_AGENTDEVICEUSERBINDING = 'authentik_endpoints_connectors_agent.agentdeviceuserbinding' + AUTHENTIK_ENDPOINTS_CONNECTORS_AGENT_DOT_ENROLLMENTTOKEN = 'authentik_endpoints_connectors_agent.enrollmenttoken' + AUTHENTIK_ENTERPRISE_DOT_LICENSE = 'authentik_enterprise.license' + AUTHENTIK_EVENTS_DOT_EVENT = 'authentik_events.event' + AUTHENTIK_EVENTS_DOT_NOTIFICATIONTRANSPORT = 'authentik_events.notificationtransport' + AUTHENTIK_EVENTS_DOT_NOTIFICATION = 'authentik_events.notification' + AUTHENTIK_EVENTS_DOT_NOTIFICATIONRULE = 'authentik_events.notificationrule' + AUTHENTIK_EVENTS_DOT_NOTIFICATIONWEBHOOKMAPPING = 'authentik_events.notificationwebhookmapping' + AUTHENTIK_FLOWS_DOT_FLOW = 'authentik_flows.flow' + AUTHENTIK_FLOWS_DOT_FLOWSTAGEBINDING = 'authentik_flows.flowstagebinding' + AUTHENTIK_OUTPOSTS_DOT_DOCKERSERVICECONNECTION = 'authentik_outposts.dockerserviceconnection' + AUTHENTIK_OUTPOSTS_DOT_KUBERNETESSERVICECONNECTION = 'authentik_outposts.kubernetesserviceconnection' + AUTHENTIK_OUTPOSTS_DOT_OUTPOST = 'authentik_outposts.outpost' + AUTHENTIK_POLICIES_DUMMY_DOT_DUMMYPOLICY = 'authentik_policies_dummy.dummypolicy' + AUTHENTIK_POLICIES_EVENT_MATCHER_DOT_EVENTMATCHERPOLICY = 'authentik_policies_event_matcher.eventmatcherpolicy' + AUTHENTIK_POLICIES_EXPIRY_DOT_PASSWORDEXPIRYPOLICY = 'authentik_policies_expiry.passwordexpirypolicy' + AUTHENTIK_POLICIES_EXPRESSION_DOT_EXPRESSIONPOLICY = 'authentik_policies_expression.expressionpolicy' + AUTHENTIK_POLICIES_GEOIP_DOT_GEOIPPOLICY = 'authentik_policies_geoip.geoippolicy' + AUTHENTIK_POLICIES_PASSWORD_DOT_PASSWORDPOLICY = 'authentik_policies_password.passwordpolicy' + AUTHENTIK_POLICIES_REPUTATION_DOT_REPUTATIONPOLICY = 'authentik_policies_reputation.reputationpolicy' + AUTHENTIK_POLICIES_DOT_POLICYBINDING = 'authentik_policies.policybinding' + AUTHENTIK_PROVIDERS_LDAP_DOT_LDAPPROVIDER = 'authentik_providers_ldap.ldapprovider' + AUTHENTIK_PROVIDERS_OAUTH2_DOT_SCOPEMAPPING = 'authentik_providers_oauth2.scopemapping' + AUTHENTIK_PROVIDERS_OAUTH2_DOT_OAUTH2PROVIDER = 'authentik_providers_oauth2.oauth2provider' + AUTHENTIK_PROVIDERS_PROXY_DOT_PROXYPROVIDER = 'authentik_providers_proxy.proxyprovider' + AUTHENTIK_PROVIDERS_RAC_DOT_RACPROVIDER = 'authentik_providers_rac.racprovider' + AUTHENTIK_PROVIDERS_RAC_DOT_ENDPOINT = 'authentik_providers_rac.endpoint' + AUTHENTIK_PROVIDERS_RAC_DOT_RACPROPERTYMAPPING = 'authentik_providers_rac.racpropertymapping' + AUTHENTIK_PROVIDERS_RADIUS_DOT_RADIUSPROVIDER = 'authentik_providers_radius.radiusprovider' + AUTHENTIK_PROVIDERS_RADIUS_DOT_RADIUSPROVIDERPROPERTYMAPPING = 'authentik_providers_radius.radiusproviderpropertymapping' + AUTHENTIK_PROVIDERS_SAML_DOT_SAMLPROVIDER = 'authentik_providers_saml.samlprovider' + AUTHENTIK_PROVIDERS_SAML_DOT_SAMLPROPERTYMAPPING = 'authentik_providers_saml.samlpropertymapping' + AUTHENTIK_PROVIDERS_SCIM_DOT_SCIMPROVIDER = 'authentik_providers_scim.scimprovider' + AUTHENTIK_PROVIDERS_SCIM_DOT_SCIMMAPPING = 'authentik_providers_scim.scimmapping' + AUTHENTIK_RBAC_DOT_ROLE = 'authentik_rbac.role' + AUTHENTIK_RBAC_DOT_INITIALPERMISSIONS = 'authentik_rbac.initialpermissions' + AUTHENTIK_SOURCES_KERBEROS_DOT_KERBEROSSOURCE = 'authentik_sources_kerberos.kerberossource' + AUTHENTIK_SOURCES_KERBEROS_DOT_KERBEROSSOURCEPROPERTYMAPPING = 'authentik_sources_kerberos.kerberossourcepropertymapping' + AUTHENTIK_SOURCES_KERBEROS_DOT_USERKERBEROSSOURCECONNECTION = 'authentik_sources_kerberos.userkerberossourceconnection' + AUTHENTIK_SOURCES_KERBEROS_DOT_GROUPKERBEROSSOURCECONNECTION = 'authentik_sources_kerberos.groupkerberossourceconnection' + AUTHENTIK_SOURCES_LDAP_DOT_LDAPSOURCE = 'authentik_sources_ldap.ldapsource' + AUTHENTIK_SOURCES_LDAP_DOT_LDAPSOURCEPROPERTYMAPPING = 'authentik_sources_ldap.ldapsourcepropertymapping' + AUTHENTIK_SOURCES_LDAP_DOT_USERLDAPSOURCECONNECTION = 'authentik_sources_ldap.userldapsourceconnection' + AUTHENTIK_SOURCES_LDAP_DOT_GROUPLDAPSOURCECONNECTION = 'authentik_sources_ldap.groupldapsourceconnection' + AUTHENTIK_SOURCES_OAUTH_DOT_OAUTHSOURCE = 'authentik_sources_oauth.oauthsource' + AUTHENTIK_SOURCES_OAUTH_DOT_OAUTHSOURCEPROPERTYMAPPING = 'authentik_sources_oauth.oauthsourcepropertymapping' + AUTHENTIK_SOURCES_OAUTH_DOT_USEROAUTHSOURCECONNECTION = 'authentik_sources_oauth.useroauthsourceconnection' + AUTHENTIK_SOURCES_OAUTH_DOT_GROUPOAUTHSOURCECONNECTION = 'authentik_sources_oauth.groupoauthsourceconnection' + AUTHENTIK_SOURCES_PLEX_DOT_PLEXSOURCE = 'authentik_sources_plex.plexsource' + AUTHENTIK_SOURCES_PLEX_DOT_PLEXSOURCEPROPERTYMAPPING = 'authentik_sources_plex.plexsourcepropertymapping' + AUTHENTIK_SOURCES_PLEX_DOT_USERPLEXSOURCECONNECTION = 'authentik_sources_plex.userplexsourceconnection' + AUTHENTIK_SOURCES_PLEX_DOT_GROUPPLEXSOURCECONNECTION = 'authentik_sources_plex.groupplexsourceconnection' + AUTHENTIK_SOURCES_SAML_DOT_SAMLSOURCE = 'authentik_sources_saml.samlsource' + AUTHENTIK_SOURCES_SAML_DOT_SAMLSOURCEPROPERTYMAPPING = 'authentik_sources_saml.samlsourcepropertymapping' + AUTHENTIK_SOURCES_SAML_DOT_USERSAMLSOURCECONNECTION = 'authentik_sources_saml.usersamlsourceconnection' + AUTHENTIK_SOURCES_SAML_DOT_GROUPSAMLSOURCECONNECTION = 'authentik_sources_saml.groupsamlsourceconnection' + AUTHENTIK_SOURCES_SCIM_DOT_SCIMSOURCE = 'authentik_sources_scim.scimsource' + AUTHENTIK_SOURCES_SCIM_DOT_SCIMSOURCEPROPERTYMAPPING = 'authentik_sources_scim.scimsourcepropertymapping' + AUTHENTIK_SOURCES_TELEGRAM_DOT_TELEGRAMSOURCE = 'authentik_sources_telegram.telegramsource' + AUTHENTIK_SOURCES_TELEGRAM_DOT_TELEGRAMSOURCEPROPERTYMAPPING = 'authentik_sources_telegram.telegramsourcepropertymapping' + AUTHENTIK_SOURCES_TELEGRAM_DOT_USERTELEGRAMSOURCECONNECTION = 'authentik_sources_telegram.usertelegramsourceconnection' + AUTHENTIK_SOURCES_TELEGRAM_DOT_GROUPTELEGRAMSOURCECONNECTION = 'authentik_sources_telegram.grouptelegramsourceconnection' + AUTHENTIK_STAGES_AUTHENTICATOR_DUO_DOT_AUTHENTICATORDUOSTAGE = 'authentik_stages_authenticator_duo.authenticatorduostage' + AUTHENTIK_STAGES_AUTHENTICATOR_DUO_DOT_DUODEVICE = 'authentik_stages_authenticator_duo.duodevice' + AUTHENTIK_STAGES_AUTHENTICATOR_EMAIL_DOT_AUTHENTICATOREMAILSTAGE = 'authentik_stages_authenticator_email.authenticatoremailstage' + AUTHENTIK_STAGES_AUTHENTICATOR_EMAIL_DOT_EMAILDEVICE = 'authentik_stages_authenticator_email.emaildevice' + AUTHENTIK_STAGES_AUTHENTICATOR_SMS_DOT_AUTHENTICATORSMSSTAGE = 'authentik_stages_authenticator_sms.authenticatorsmsstage' + AUTHENTIK_STAGES_AUTHENTICATOR_SMS_DOT_SMSDEVICE = 'authentik_stages_authenticator_sms.smsdevice' + AUTHENTIK_STAGES_AUTHENTICATOR_STATIC_DOT_AUTHENTICATORSTATICSTAGE = 'authentik_stages_authenticator_static.authenticatorstaticstage' + AUTHENTIK_STAGES_AUTHENTICATOR_STATIC_DOT_STATICDEVICE = 'authentik_stages_authenticator_static.staticdevice' + AUTHENTIK_STAGES_AUTHENTICATOR_TOTP_DOT_AUTHENTICATORTOTPSTAGE = 'authentik_stages_authenticator_totp.authenticatortotpstage' + AUTHENTIK_STAGES_AUTHENTICATOR_TOTP_DOT_TOTPDEVICE = 'authentik_stages_authenticator_totp.totpdevice' + AUTHENTIK_STAGES_AUTHENTICATOR_VALIDATE_DOT_AUTHENTICATORVALIDATESTAGE = 'authentik_stages_authenticator_validate.authenticatorvalidatestage' + AUTHENTIK_STAGES_AUTHENTICATOR_WEBAUTHN_DOT_AUTHENTICATORWEBAUTHNSTAGE = 'authentik_stages_authenticator_webauthn.authenticatorwebauthnstage' + AUTHENTIK_STAGES_AUTHENTICATOR_WEBAUTHN_DOT_WEBAUTHNDEVICE = 'authentik_stages_authenticator_webauthn.webauthndevice' + AUTHENTIK_STAGES_CAPTCHA_DOT_CAPTCHASTAGE = 'authentik_stages_captcha.captchastage' + AUTHENTIK_STAGES_CONSENT_DOT_CONSENTSTAGE = 'authentik_stages_consent.consentstage' + AUTHENTIK_STAGES_DENY_DOT_DENYSTAGE = 'authentik_stages_deny.denystage' + AUTHENTIK_STAGES_DUMMY_DOT_DUMMYSTAGE = 'authentik_stages_dummy.dummystage' + AUTHENTIK_STAGES_EMAIL_DOT_EMAILSTAGE = 'authentik_stages_email.emailstage' + AUTHENTIK_STAGES_IDENTIFICATION_DOT_IDENTIFICATIONSTAGE = 'authentik_stages_identification.identificationstage' + AUTHENTIK_STAGES_INVITATION_DOT_INVITATIONSTAGE = 'authentik_stages_invitation.invitationstage' + AUTHENTIK_STAGES_INVITATION_DOT_INVITATION = 'authentik_stages_invitation.invitation' + AUTHENTIK_STAGES_PASSWORD_DOT_PASSWORDSTAGE = 'authentik_stages_password.passwordstage' + AUTHENTIK_STAGES_PROMPT_DOT_PROMPT = 'authentik_stages_prompt.prompt' + AUTHENTIK_STAGES_PROMPT_DOT_PROMPTSTAGE = 'authentik_stages_prompt.promptstage' + AUTHENTIK_STAGES_REDIRECT_DOT_REDIRECTSTAGE = 'authentik_stages_redirect.redirectstage' + AUTHENTIK_STAGES_USER_DELETE_DOT_USERDELETESTAGE = 'authentik_stages_user_delete.userdeletestage' + AUTHENTIK_STAGES_USER_LOGIN_DOT_USERLOGINSTAGE = 'authentik_stages_user_login.userloginstage' + AUTHENTIK_STAGES_USER_LOGOUT_DOT_USERLOGOUTSTAGE = 'authentik_stages_user_logout.userlogoutstage' + AUTHENTIK_STAGES_USER_WRITE_DOT_USERWRITESTAGE = 'authentik_stages_user_write.userwritestage' + AUTHENTIK_TASKS_SCHEDULES_DOT_SCHEDULE = 'authentik_tasks_schedules.schedule' + AUTHENTIK_BRANDS_DOT_BRAND = 'authentik_brands.brand' + AUTHENTIK_BLUEPRINTS_DOT_BLUEPRINTINSTANCE = 'authentik_blueprints.blueprintinstance' + AUTHENTIK_ENDPOINTS_CONNECTORS_FLEET_DOT_FLEETCONNECTOR = 'authentik_endpoints_connectors_fleet.fleetconnector' + AUTHENTIK_ENDPOINTS_CONNECTORS_GOOGLE_CHROME_DOT_GOOGLECHROMECONNECTOR = 'authentik_endpoints_connectors_google_chrome.googlechromeconnector' + AUTHENTIK_LIFECYCLE_DOT_LIFECYCLERULE = 'authentik_lifecycle.lifecyclerule' + AUTHENTIK_LIFECYCLE_DOT_LIFECYCLEITERATION = 'authentik_lifecycle.lifecycleiteration' + AUTHENTIK_LIFECYCLE_DOT_REVIEW = 'authentik_lifecycle.review' + AUTHENTIK_POLICIES_UNIQUE_PASSWORD_DOT_UNIQUEPASSWORDPOLICY = 'authentik_policies_unique_password.uniquepasswordpolicy' + AUTHENTIK_PROVIDERS_GOOGLE_WORKSPACE_DOT_GOOGLEWORKSPACEPROVIDER = 'authentik_providers_google_workspace.googleworkspaceprovider' + AUTHENTIK_PROVIDERS_GOOGLE_WORKSPACE_DOT_GOOGLEWORKSPACEPROVIDERMAPPING = 'authentik_providers_google_workspace.googleworkspaceprovidermapping' + AUTHENTIK_PROVIDERS_MICROSOFT_ENTRA_DOT_MICROSOFTENTRAPROVIDER = 'authentik_providers_microsoft_entra.microsoftentraprovider' + AUTHENTIK_PROVIDERS_MICROSOFT_ENTRA_DOT_MICROSOFTENTRAPROVIDERMAPPING = 'authentik_providers_microsoft_entra.microsoftentraprovidermapping' + AUTHENTIK_PROVIDERS_SSF_DOT_SSFPROVIDER = 'authentik_providers_ssf.ssfprovider' + AUTHENTIK_PROVIDERS_WS_FEDERATION_DOT_WSFEDERATIONPROVIDER = 'authentik_providers_ws_federation.wsfederationprovider' + AUTHENTIK_REPORTS_DOT_DATAEXPORT = 'authentik_reports.dataexport' + AUTHENTIK_STAGES_ACCOUNT_LOCKDOWN_DOT_ACCOUNTLOCKDOWNSTAGE = 'authentik_stages_account_lockdown.accountlockdownstage' + AUTHENTIK_STAGES_AUTHENTICATOR_ENDPOINT_GDTC_DOT_AUTHENTICATORENDPOINTGDTCSTAGE = 'authentik_stages_authenticator_endpoint_gdtc.authenticatorendpointgdtcstage' + AUTHENTIK_STAGES_MTLS_DOT_MUTUALTLSSTAGE = 'authentik_stages_mtls.mutualtlsstage' + AUTHENTIK_STAGES_SOURCE_DOT_SOURCESTAGE = 'authentik_stages_source.sourcestage' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ModelEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/model_request.py b/authentik_client/models/model_request.py new file mode 100644 index 000000000..7d02d2c80 --- /dev/null +++ b/authentik_client/models/model_request.py @@ -0,0 +1,267 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +import pprint +from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator +from typing import Any, List, Optional +from authentik_client.models.google_workspace_provider_request import GoogleWorkspaceProviderRequest +from authentik_client.models.ldap_provider_request import LDAPProviderRequest +from authentik_client.models.microsoft_entra_provider_request import MicrosoftEntraProviderRequest +from authentik_client.models.o_auth2_provider_request import OAuth2ProviderRequest +from authentik_client.models.proxy_provider_request import ProxyProviderRequest +from authentik_client.models.rac_provider_request import RACProviderRequest +from authentik_client.models.radius_provider_request import RadiusProviderRequest +from authentik_client.models.saml_provider_request import SAMLProviderRequest +from authentik_client.models.scim_provider_request import SCIMProviderRequest +from authentik_client.models.ssf_provider_request import SSFProviderRequest +from authentik_client.models.ws_federation_provider_request import WSFederationProviderRequest +from pydantic import StrictStr, Field +from typing import Union, List, Set, Optional, Dict +from typing_extensions import Literal, Self + +MODELREQUEST_ONE_OF_SCHEMAS = ["GoogleWorkspaceProviderRequest", "LDAPProviderRequest", "MicrosoftEntraProviderRequest", "OAuth2ProviderRequest", "ProxyProviderRequest", "RACProviderRequest", "RadiusProviderRequest", "SAMLProviderRequest", "SCIMProviderRequest", "SSFProviderRequest", "WSFederationProviderRequest"] + +class ModelRequest(BaseModel): + """ + ModelRequest + """ + # data type: GoogleWorkspaceProviderRequest + oneof_schema_1_validator: Optional[GoogleWorkspaceProviderRequest] = None + # data type: LDAPProviderRequest + oneof_schema_2_validator: Optional[LDAPProviderRequest] = None + # data type: MicrosoftEntraProviderRequest + oneof_schema_3_validator: Optional[MicrosoftEntraProviderRequest] = None + # data type: OAuth2ProviderRequest + oneof_schema_4_validator: Optional[OAuth2ProviderRequest] = None + # data type: ProxyProviderRequest + oneof_schema_5_validator: Optional[ProxyProviderRequest] = None + # data type: RACProviderRequest + oneof_schema_6_validator: Optional[RACProviderRequest] = None + # data type: RadiusProviderRequest + oneof_schema_7_validator: Optional[RadiusProviderRequest] = None + # data type: SAMLProviderRequest + oneof_schema_8_validator: Optional[SAMLProviderRequest] = None + # data type: SCIMProviderRequest + oneof_schema_9_validator: Optional[SCIMProviderRequest] = None + # data type: SSFProviderRequest + oneof_schema_10_validator: Optional[SSFProviderRequest] = None + # data type: WSFederationProviderRequest + oneof_schema_11_validator: Optional[WSFederationProviderRequest] = None + actual_instance: Optional[Union[GoogleWorkspaceProviderRequest, LDAPProviderRequest, MicrosoftEntraProviderRequest, OAuth2ProviderRequest, ProxyProviderRequest, RACProviderRequest, RadiusProviderRequest, SAMLProviderRequest, SCIMProviderRequest, SSFProviderRequest, WSFederationProviderRequest]] = None + one_of_schemas: Set[str] = { "GoogleWorkspaceProviderRequest", "LDAPProviderRequest", "MicrosoftEntraProviderRequest", "OAuth2ProviderRequest", "ProxyProviderRequest", "RACProviderRequest", "RadiusProviderRequest", "SAMLProviderRequest", "SCIMProviderRequest", "SSFProviderRequest", "WSFederationProviderRequest" } + + model_config = ConfigDict( + validate_assignment=True, + protected_namespaces=(), + ) + + + discriminator_value_class_map: Dict[str, str] = { + } + + def __init__(self, *args, **kwargs) -> None: + if args: + if len(args) > 1: + raise ValueError("If a position argument is used, only 1 is allowed to set `actual_instance`") + if kwargs: + raise ValueError("If a position argument is used, keyword arguments cannot be used.") + super().__init__(actual_instance=args[0]) + else: + super().__init__(**kwargs) + + @field_validator('actual_instance') + def actual_instance_must_validate_oneof(cls, v): + instance = ModelRequest.model_construct() + error_messages = [] + match = 0 + # validate data type: GoogleWorkspaceProviderRequest + if not isinstance(v, GoogleWorkspaceProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `GoogleWorkspaceProviderRequest`") + else: + match += 1 + # validate data type: LDAPProviderRequest + if not isinstance(v, LDAPProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `LDAPProviderRequest`") + else: + match += 1 + # validate data type: MicrosoftEntraProviderRequest + if not isinstance(v, MicrosoftEntraProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `MicrosoftEntraProviderRequest`") + else: + match += 1 + # validate data type: OAuth2ProviderRequest + if not isinstance(v, OAuth2ProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `OAuth2ProviderRequest`") + else: + match += 1 + # validate data type: ProxyProviderRequest + if not isinstance(v, ProxyProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `ProxyProviderRequest`") + else: + match += 1 + # validate data type: RACProviderRequest + if not isinstance(v, RACProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `RACProviderRequest`") + else: + match += 1 + # validate data type: RadiusProviderRequest + if not isinstance(v, RadiusProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `RadiusProviderRequest`") + else: + match += 1 + # validate data type: SAMLProviderRequest + if not isinstance(v, SAMLProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `SAMLProviderRequest`") + else: + match += 1 + # validate data type: SCIMProviderRequest + if not isinstance(v, SCIMProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `SCIMProviderRequest`") + else: + match += 1 + # validate data type: SSFProviderRequest + if not isinstance(v, SSFProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `SSFProviderRequest`") + else: + match += 1 + # validate data type: WSFederationProviderRequest + if not isinstance(v, WSFederationProviderRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `WSFederationProviderRequest`") + else: + match += 1 + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when setting `actual_instance` in ModelRequest with oneOf schemas: GoogleWorkspaceProviderRequest, LDAPProviderRequest, MicrosoftEntraProviderRequest, OAuth2ProviderRequest, ProxyProviderRequest, RACProviderRequest, RadiusProviderRequest, SAMLProviderRequest, SCIMProviderRequest, SSFProviderRequest, WSFederationProviderRequest. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when setting `actual_instance` in ModelRequest with oneOf schemas: GoogleWorkspaceProviderRequest, LDAPProviderRequest, MicrosoftEntraProviderRequest, OAuth2ProviderRequest, ProxyProviderRequest, RACProviderRequest, RadiusProviderRequest, SAMLProviderRequest, SCIMProviderRequest, SSFProviderRequest, WSFederationProviderRequest. Details: " + ", ".join(error_messages)) + else: + return v + + @classmethod + def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self: + return cls.from_json(json.dumps(obj)) + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Returns the object represented by the json string""" + instance = cls.model_construct() + error_messages = [] + match = 0 + + # deserialize data into GoogleWorkspaceProviderRequest + try: + instance.actual_instance = GoogleWorkspaceProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into LDAPProviderRequest + try: + instance.actual_instance = LDAPProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into MicrosoftEntraProviderRequest + try: + instance.actual_instance = MicrosoftEntraProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into OAuth2ProviderRequest + try: + instance.actual_instance = OAuth2ProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into ProxyProviderRequest + try: + instance.actual_instance = ProxyProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into RACProviderRequest + try: + instance.actual_instance = RACProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into RadiusProviderRequest + try: + instance.actual_instance = RadiusProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into SAMLProviderRequest + try: + instance.actual_instance = SAMLProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into SCIMProviderRequest + try: + instance.actual_instance = SCIMProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into SSFProviderRequest + try: + instance.actual_instance = SSFProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + # deserialize data into WSFederationProviderRequest + try: + instance.actual_instance = WSFederationProviderRequest.from_json(json_str) + match += 1 + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) + + if match > 1: + # more than 1 match + raise ValueError("Multiple matches found when deserializing the JSON string into ModelRequest with oneOf schemas: GoogleWorkspaceProviderRequest, LDAPProviderRequest, MicrosoftEntraProviderRequest, OAuth2ProviderRequest, ProxyProviderRequest, RACProviderRequest, RadiusProviderRequest, SAMLProviderRequest, SCIMProviderRequest, SSFProviderRequest, WSFederationProviderRequest. Details: " + ", ".join(error_messages)) + elif match == 0: + # no match + raise ValueError("No match found when deserializing the JSON string into ModelRequest with oneOf schemas: GoogleWorkspaceProviderRequest, LDAPProviderRequest, MicrosoftEntraProviderRequest, OAuth2ProviderRequest, ProxyProviderRequest, RACProviderRequest, RadiusProviderRequest, SAMLProviderRequest, SCIMProviderRequest, SSFProviderRequest, WSFederationProviderRequest. Details: " + ", ".join(error_messages)) + else: + return instance + + def to_json(self) -> str: + """Returns the JSON representation of the actual instance""" + if self.actual_instance is None: + return "null" + + if hasattr(self.actual_instance, "to_json") and callable(self.actual_instance.to_json): + return self.actual_instance.to_json() + else: + return json.dumps(self.actual_instance) + + def to_dict(self) -> Optional[Union[Dict[str, Any], GoogleWorkspaceProviderRequest, LDAPProviderRequest, MicrosoftEntraProviderRequest, OAuth2ProviderRequest, ProxyProviderRequest, RACProviderRequest, RadiusProviderRequest, SAMLProviderRequest, SCIMProviderRequest, SSFProviderRequest, WSFederationProviderRequest]]: + """Returns the dict representation of the actual instance""" + if self.actual_instance is None: + return None + + if hasattr(self.actual_instance, "to_dict") and callable(self.actual_instance.to_dict): + return self.actual_instance.to_dict() + else: + # primitive type + return self.actual_instance + + def to_str(self) -> str: + """Returns the string representation of the actual instance""" + return pprint.pformat(self.model_dump()) + + diff --git a/authentik_client/models/mutual_tls_stage.py b/authentik_client/models/mutual_tls_stage.py new file mode 100644 index 000000000..6e404c64b --- /dev/null +++ b/authentik_client/models/mutual_tls_stage.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.cert_attribute_enum import CertAttributeEnum +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.stage_mode_enum import StageModeEnum +from authentik_client.models.user_attribute_enum import UserAttributeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MutualTLSStage(BaseModel): + """ + MutualTLSStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + mode: StageModeEnum + certificate_authorities: Optional[List[UUID]] = Field(default=None, description="Configure certificate authorities to validate the certificate against. This option has a higher priority than the `client_certificate` option on `Brand`.") + cert_attribute: CertAttributeEnum + user_attribute: UserAttributeEnum + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "mode", "certificate_authorities", "cert_attribute", "user_attribute"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MutualTLSStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MutualTLSStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "mode": obj.get("mode"), + "certificate_authorities": obj.get("certificate_authorities"), + "cert_attribute": obj.get("cert_attribute"), + "user_attribute": obj.get("user_attribute") + }) + return _obj + + diff --git a/authentik_client/models/mutual_tls_stage_request.py b/authentik_client/models/mutual_tls_stage_request.py new file mode 100644 index 000000000..150453033 --- /dev/null +++ b/authentik_client/models/mutual_tls_stage_request.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.cert_attribute_enum import CertAttributeEnum +from authentik_client.models.stage_mode_enum import StageModeEnum +from authentik_client.models.user_attribute_enum import UserAttributeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class MutualTLSStageRequest(BaseModel): + """ + MutualTLSStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + mode: StageModeEnum + certificate_authorities: Optional[List[UUID]] = Field(default=None, description="Configure certificate authorities to validate the certificate against. This option has a higher priority than the `client_certificate` option on `Brand`.") + cert_attribute: CertAttributeEnum + user_attribute: UserAttributeEnum + __properties: ClassVar[List[str]] = ["name", "mode", "certificate_authorities", "cert_attribute", "user_attribute"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of MutualTLSStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of MutualTLSStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "mode": obj.get("mode"), + "certificate_authorities": obj.get("certificate_authorities"), + "cert_attribute": obj.get("cert_attribute"), + "user_attribute": obj.get("user_attribute") + }) + return _obj + + diff --git a/authentik_client/models/native_logout_challenge.py b/authentik_client/models/native_logout_challenge.py new file mode 100644 index 000000000..d70168ad3 --- /dev/null +++ b/authentik_client/models/native_logout_challenge.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from authentik_client.models.saml_bindings_enum import SAMLBindingsEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NativeLogoutChallenge(BaseModel): + """ + Challenge for native browser logout + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-provider-saml-native-logout' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + provider_name: Optional[StrictStr] = None + is_complete: Optional[StrictBool] = False + post_url: Optional[StrictStr] = None + redirect_url: Optional[StrictStr] = None + saml_binding: Optional[SAMLBindingsEnum] = None + saml_request: Optional[StrictStr] = None + saml_response: Optional[StrictStr] = None + saml_relay_state: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "provider_name", "is_complete", "post_url", "redirect_url", "saml_binding", "saml_request", "saml_response", "saml_relay_state"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NativeLogoutChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NativeLogoutChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-provider-saml-native-logout', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "provider_name": obj.get("provider_name"), + "is_complete": obj.get("is_complete") if obj.get("is_complete") is not None else False, + "post_url": obj.get("post_url"), + "redirect_url": obj.get("redirect_url"), + "saml_binding": obj.get("saml_binding"), + "saml_request": obj.get("saml_request"), + "saml_response": obj.get("saml_response"), + "saml_relay_state": obj.get("saml_relay_state") + }) + return _obj + + diff --git a/authentik_client/models/native_logout_challenge_response_request.py b/authentik_client/models/native_logout_challenge_response_request.py new file mode 100644 index 000000000..8dc880305 --- /dev/null +++ b/authentik_client/models/native_logout_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NativeLogoutChallengeResponseRequest(BaseModel): + """ + Response for native browser logout + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-provider-saml-native-logout' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NativeLogoutChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NativeLogoutChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-provider-saml-native-logout' + }) + return _obj + + diff --git a/authentik_client/models/network.py b/authentik_client/models/network.py new file mode 100644 index 000000000..922713f52 --- /dev/null +++ b/authentik_client/models/network.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.network_interface import NetworkInterface +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Network(BaseModel): + """ + Network + """ # noqa: E501 + hostname: StrictStr + firewall_enabled: Optional[StrictBool] = None + interfaces: List[NetworkInterface] + gateway: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["hostname", "firewall_enabled", "interfaces", "gateway"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Network from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in interfaces (list) + _items = [] + if self.interfaces: + for _item_interfaces in self.interfaces: + if _item_interfaces: + _items.append(_item_interfaces.to_dict()) + _dict['interfaces'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Network from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "hostname": obj.get("hostname"), + "firewall_enabled": obj.get("firewall_enabled"), + "interfaces": [NetworkInterface.from_dict(_item) for _item in obj["interfaces"]] if obj.get("interfaces") is not None else None, + "gateway": obj.get("gateway") + }) + return _obj + + diff --git a/authentik_client/models/network_binding_enum.py b/authentik_client/models/network_binding_enum.py new file mode 100644 index 000000000..5af3f8a9f --- /dev/null +++ b/authentik_client/models/network_binding_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class NetworkBindingEnum(str, Enum): + """ + NetworkBindingEnum + """ + + """ + allowed enum values + """ + NO_BINDING = 'no_binding' + BIND_ASN = 'bind_asn' + BIND_ASN_NETWORK = 'bind_asn_network' + BIND_ASN_NETWORK_IP = 'bind_asn_network_ip' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of NetworkBindingEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/network_interface.py b/authentik_client/models/network_interface.py new file mode 100644 index 000000000..999c24b25 --- /dev/null +++ b/authentik_client/models/network_interface.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NetworkInterface(BaseModel): + """ + NetworkInterface + """ # noqa: E501 + name: StrictStr + hardware_address: StrictStr + ip_addresses: Optional[List[StrictStr]] = None + dns_servers: Optional[List[StrictStr]] = None + __properties: ClassVar[List[str]] = ["name", "hardware_address", "ip_addresses", "dns_servers"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NetworkInterface from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NetworkInterface from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "hardware_address": obj.get("hardware_address"), + "ip_addresses": obj.get("ip_addresses"), + "dns_servers": obj.get("dns_servers") + }) + return _obj + + diff --git a/authentik_client/models/network_interface_request.py b/authentik_client/models/network_interface_request.py new file mode 100644 index 000000000..469413173 --- /dev/null +++ b/authentik_client/models/network_interface_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NetworkInterfaceRequest(BaseModel): + """ + NetworkInterfaceRequest + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + hardware_address: Annotated[str, Field(min_length=1, strict=True)] + ip_addresses: Optional[List[Annotated[str, Field(min_length=1, strict=True)]]] = None + dns_servers: Optional[List[Annotated[str, Field(min_length=1, strict=True)]]] = None + __properties: ClassVar[List[str]] = ["name", "hardware_address", "ip_addresses", "dns_servers"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NetworkInterfaceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NetworkInterfaceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "hardware_address": obj.get("hardware_address"), + "ip_addresses": obj.get("ip_addresses"), + "dns_servers": obj.get("dns_servers") + }) + return _obj + + diff --git a/authentik_client/models/network_request.py b/authentik_client/models/network_request.py new file mode 100644 index 000000000..d7960660f --- /dev/null +++ b/authentik_client/models/network_request.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.network_interface_request import NetworkInterfaceRequest +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NetworkRequest(BaseModel): + """ + NetworkRequest + """ # noqa: E501 + hostname: Annotated[str, Field(min_length=1, strict=True)] + firewall_enabled: Optional[StrictBool] = None + interfaces: List[NetworkInterfaceRequest] + gateway: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["hostname", "firewall_enabled", "interfaces", "gateway"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NetworkRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in interfaces (list) + _items = [] + if self.interfaces: + for _item_interfaces in self.interfaces: + if _item_interfaces: + _items.append(_item_interfaces.to_dict()) + _dict['interfaces'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NetworkRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "hostname": obj.get("hostname"), + "firewall_enabled": obj.get("firewall_enabled"), + "interfaces": [NetworkInterfaceRequest.from_dict(_item) for _item in obj["interfaces"]] if obj.get("interfaces") is not None else None, + "gateway": obj.get("gateway") + }) + return _obj + + diff --git a/authentik_client/models/not_configured_action_enum.py b/authentik_client/models/not_configured_action_enum.py new file mode 100644 index 000000000..25656ec70 --- /dev/null +++ b/authentik_client/models/not_configured_action_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class NotConfiguredActionEnum(str, Enum): + """ + NotConfiguredActionEnum + """ + + """ + allowed enum values + """ + SKIP = 'skip' + DENY = 'deny' + CONFIGURE = 'configure' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of NotConfiguredActionEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/notification.py b/authentik_client/models/notification.py new file mode 100644 index 000000000..4f4b0bc40 --- /dev/null +++ b/authentik_client/models/notification.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.event import Event +from authentik_client.models.severity_enum import SeverityEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Notification(BaseModel): + """ + Notification Serializer + """ # noqa: E501 + pk: UUID + severity: SeverityEnum + body: StrictStr + hyperlink: Optional[Annotated[str, Field(strict=True, max_length=4096)]] = None + hyperlink_label: Optional[StrictStr] = None + created: datetime + event: Optional[Event] = None + seen: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["pk", "severity", "body", "hyperlink", "hyperlink_label", "created", "event", "seen"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Notification from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "severity", + "body", + "created", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of event + if self.event: + _dict['event'] = self.event.to_dict() + # set to None if hyperlink (nullable) is None + # and model_fields_set contains the field + if self.hyperlink is None and "hyperlink" in self.model_fields_set: + _dict['hyperlink'] = None + + # set to None if hyperlink_label (nullable) is None + # and model_fields_set contains the field + if self.hyperlink_label is None and "hyperlink_label" in self.model_fields_set: + _dict['hyperlink_label'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Notification from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "severity": obj.get("severity"), + "body": obj.get("body"), + "hyperlink": obj.get("hyperlink"), + "hyperlink_label": obj.get("hyperlink_label"), + "created": obj.get("created"), + "event": Event.from_dict(obj["event"]) if obj.get("event") is not None else None, + "seen": obj.get("seen") + }) + return _obj + + diff --git a/authentik_client/models/notification_request.py b/authentik_client/models/notification_request.py new file mode 100644 index 000000000..478444109 --- /dev/null +++ b/authentik_client/models/notification_request.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.event_request import EventRequest +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NotificationRequest(BaseModel): + """ + Notification Serializer + """ # noqa: E501 + hyperlink: Optional[Annotated[str, Field(strict=True, max_length=4096)]] = None + hyperlink_label: Optional[StrictStr] = None + event: Optional[EventRequest] = None + seen: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["hyperlink", "hyperlink_label", "event", "seen"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NotificationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of event + if self.event: + _dict['event'] = self.event.to_dict() + # set to None if hyperlink (nullable) is None + # and model_fields_set contains the field + if self.hyperlink is None and "hyperlink" in self.model_fields_set: + _dict['hyperlink'] = None + + # set to None if hyperlink_label (nullable) is None + # and model_fields_set contains the field + if self.hyperlink_label is None and "hyperlink_label" in self.model_fields_set: + _dict['hyperlink_label'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NotificationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "hyperlink": obj.get("hyperlink"), + "hyperlink_label": obj.get("hyperlink_label"), + "event": EventRequest.from_dict(obj["event"]) if obj.get("event") is not None else None, + "seen": obj.get("seen") + }) + return _obj + + diff --git a/authentik_client/models/notification_rule.py b/authentik_client/models/notification_rule.py new file mode 100644 index 000000000..e0a89eb19 --- /dev/null +++ b/authentik_client/models/notification_rule.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.group import Group +from authentik_client.models.severity_enum import SeverityEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NotificationRule(BaseModel): + """ + NotificationRule Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + transports: Optional[List[UUID]] = Field(default=None, description="Select which transports should be used to notify the user. If none are selected, the notification will only be shown in the authentik UI.") + severity: Optional[SeverityEnum] = Field(default=None, description="Controls which severity level the created notifications will have.") + destination_group: Optional[UUID] = Field(default=None, description="Define which group of users this notification should be sent and shown to. If left empty, Notification won't ben sent.") + destination_group_obj: Optional[Group] + destination_event_user: Optional[StrictBool] = Field(default=None, description="When enabled, notification will be sent to user the user that triggered the event.When destination_group is configured, notification is sent to both.") + __properties: ClassVar[List[str]] = ["pk", "name", "transports", "severity", "destination_group", "destination_group_obj", "destination_event_user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NotificationRule from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "destination_group_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of destination_group_obj + if self.destination_group_obj: + _dict['destination_group_obj'] = self.destination_group_obj.to_dict() + # set to None if destination_group (nullable) is None + # and model_fields_set contains the field + if self.destination_group is None and "destination_group" in self.model_fields_set: + _dict['destination_group'] = None + + # set to None if destination_group_obj (nullable) is None + # and model_fields_set contains the field + if self.destination_group_obj is None and "destination_group_obj" in self.model_fields_set: + _dict['destination_group_obj'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NotificationRule from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "transports": obj.get("transports"), + "severity": obj.get("severity"), + "destination_group": obj.get("destination_group"), + "destination_group_obj": Group.from_dict(obj["destination_group_obj"]) if obj.get("destination_group_obj") is not None else None, + "destination_event_user": obj.get("destination_event_user") + }) + return _obj + + diff --git a/authentik_client/models/notification_rule_request.py b/authentik_client/models/notification_rule_request.py new file mode 100644 index 000000000..03018b66d --- /dev/null +++ b/authentik_client/models/notification_rule_request.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.severity_enum import SeverityEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NotificationRuleRequest(BaseModel): + """ + NotificationRule Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + transports: Optional[List[UUID]] = Field(default=None, description="Select which transports should be used to notify the user. If none are selected, the notification will only be shown in the authentik UI.") + severity: Optional[SeverityEnum] = Field(default=None, description="Controls which severity level the created notifications will have.") + destination_group: Optional[UUID] = Field(default=None, description="Define which group of users this notification should be sent and shown to. If left empty, Notification won't ben sent.") + destination_event_user: Optional[StrictBool] = Field(default=None, description="When enabled, notification will be sent to user the user that triggered the event.When destination_group is configured, notification is sent to both.") + __properties: ClassVar[List[str]] = ["name", "transports", "severity", "destination_group", "destination_event_user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NotificationRuleRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if destination_group (nullable) is None + # and model_fields_set contains the field + if self.destination_group is None and "destination_group" in self.model_fields_set: + _dict['destination_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NotificationRuleRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "transports": obj.get("transports"), + "severity": obj.get("severity"), + "destination_group": obj.get("destination_group"), + "destination_event_user": obj.get("destination_event_user") + }) + return _obj + + diff --git a/authentik_client/models/notification_transport.py b/authentik_client/models/notification_transport.py new file mode 100644 index 000000000..f21eb8d43 --- /dev/null +++ b/authentik_client/models/notification_transport.py @@ -0,0 +1,130 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.transport_mode_enum import TransportModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NotificationTransport(BaseModel): + """ + NotificationTransport Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + mode: Optional[TransportModeEnum] = None + mode_verbose: StrictStr = Field(description="Return selected mode with a UI Label") + webhook_url: Optional[StrictStr] = None + webhook_ca: Optional[UUID] = Field(default=None, description="When set, the selected certificate is used to validate the certificate of the webhook server.") + webhook_mapping_body: Optional[UUID] = Field(default=None, description="Customize the body of the request. Mapping should return data that is JSON-serializable.") + webhook_mapping_headers: Optional[UUID] = Field(default=None, description="Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs") + email_subject_prefix: Optional[StrictStr] = None + email_template: Optional[StrictStr] = None + send_once: Optional[StrictBool] = Field(default=None, description="Only send notification once, for example when sending a webhook into a chat channel.") + __properties: ClassVar[List[str]] = ["pk", "name", "mode", "mode_verbose", "webhook_url", "webhook_ca", "webhook_mapping_body", "webhook_mapping_headers", "email_subject_prefix", "email_template", "send_once"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NotificationTransport from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "mode_verbose", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if webhook_ca (nullable) is None + # and model_fields_set contains the field + if self.webhook_ca is None and "webhook_ca" in self.model_fields_set: + _dict['webhook_ca'] = None + + # set to None if webhook_mapping_body (nullable) is None + # and model_fields_set contains the field + if self.webhook_mapping_body is None and "webhook_mapping_body" in self.model_fields_set: + _dict['webhook_mapping_body'] = None + + # set to None if webhook_mapping_headers (nullable) is None + # and model_fields_set contains the field + if self.webhook_mapping_headers is None and "webhook_mapping_headers" in self.model_fields_set: + _dict['webhook_mapping_headers'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NotificationTransport from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "mode": obj.get("mode"), + "mode_verbose": obj.get("mode_verbose"), + "webhook_url": obj.get("webhook_url"), + "webhook_ca": obj.get("webhook_ca"), + "webhook_mapping_body": obj.get("webhook_mapping_body"), + "webhook_mapping_headers": obj.get("webhook_mapping_headers"), + "email_subject_prefix": obj.get("email_subject_prefix"), + "email_template": obj.get("email_template"), + "send_once": obj.get("send_once") + }) + return _obj + + diff --git a/authentik_client/models/notification_transport_request.py b/authentik_client/models/notification_transport_request.py new file mode 100644 index 000000000..c56180526 --- /dev/null +++ b/authentik_client/models/notification_transport_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.transport_mode_enum import TransportModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NotificationTransportRequest(BaseModel): + """ + NotificationTransport Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + mode: Optional[TransportModeEnum] = None + webhook_url: Optional[StrictStr] = None + webhook_ca: Optional[UUID] = Field(default=None, description="When set, the selected certificate is used to validate the certificate of the webhook server.") + webhook_mapping_body: Optional[UUID] = Field(default=None, description="Customize the body of the request. Mapping should return data that is JSON-serializable.") + webhook_mapping_headers: Optional[UUID] = Field(default=None, description="Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs") + email_subject_prefix: Optional[StrictStr] = None + email_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + send_once: Optional[StrictBool] = Field(default=None, description="Only send notification once, for example when sending a webhook into a chat channel.") + __properties: ClassVar[List[str]] = ["name", "mode", "webhook_url", "webhook_ca", "webhook_mapping_body", "webhook_mapping_headers", "email_subject_prefix", "email_template", "send_once"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NotificationTransportRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if webhook_ca (nullable) is None + # and model_fields_set contains the field + if self.webhook_ca is None and "webhook_ca" in self.model_fields_set: + _dict['webhook_ca'] = None + + # set to None if webhook_mapping_body (nullable) is None + # and model_fields_set contains the field + if self.webhook_mapping_body is None and "webhook_mapping_body" in self.model_fields_set: + _dict['webhook_mapping_body'] = None + + # set to None if webhook_mapping_headers (nullable) is None + # and model_fields_set contains the field + if self.webhook_mapping_headers is None and "webhook_mapping_headers" in self.model_fields_set: + _dict['webhook_mapping_headers'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NotificationTransportRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "mode": obj.get("mode"), + "webhook_url": obj.get("webhook_url"), + "webhook_ca": obj.get("webhook_ca"), + "webhook_mapping_body": obj.get("webhook_mapping_body"), + "webhook_mapping_headers": obj.get("webhook_mapping_headers"), + "email_subject_prefix": obj.get("email_subject_prefix"), + "email_template": obj.get("email_template"), + "send_once": obj.get("send_once") + }) + return _obj + + diff --git a/authentik_client/models/notification_transport_test.py b/authentik_client/models/notification_transport_test.py new file mode 100644 index 000000000..8fe8266c7 --- /dev/null +++ b/authentik_client/models/notification_transport_test.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NotificationTransportTest(BaseModel): + """ + Notification test serializer + """ # noqa: E501 + messages: List[StrictStr] + __properties: ClassVar[List[str]] = ["messages"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NotificationTransportTest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NotificationTransportTest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "messages": obj.get("messages") + }) + return _obj + + diff --git a/authentik_client/models/notification_webhook_mapping.py b/authentik_client/models/notification_webhook_mapping.py new file mode 100644 index 000000000..891b0d4ff --- /dev/null +++ b/authentik_client/models/notification_webhook_mapping.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NotificationWebhookMapping(BaseModel): + """ + NotificationWebhookMapping Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + expression: StrictStr + __properties: ClassVar[List[str]] = ["pk", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NotificationWebhookMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NotificationWebhookMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/notification_webhook_mapping_request.py b/authentik_client/models/notification_webhook_mapping_request.py new file mode 100644 index 000000000..6ff42870c --- /dev/null +++ b/authentik_client/models/notification_webhook_mapping_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class NotificationWebhookMappingRequest(BaseModel): + """ + NotificationWebhookMapping Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of NotificationWebhookMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of NotificationWebhookMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/o_auth2_provider.py b/authentik_client/models/o_auth2_provider.py new file mode 100644 index 000000000..91a9fa193 --- /dev/null +++ b/authentik_client/models/o_auth2_provider.py @@ -0,0 +1,219 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.client_type_enum import ClientTypeEnum +from authentik_client.models.grant_types_enum import GrantTypesEnum +from authentik_client.models.issuer_mode_enum import IssuerModeEnum +from authentik_client.models.o_auth2_provider_logout_method_enum import OAuth2ProviderLogoutMethodEnum +from authentik_client.models.redirect_uri import RedirectURI +from authentik_client.models.sub_mode_enum import SubModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuth2Provider(BaseModel): + """ + OAuth2Provider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + client_type: Optional[ClientTypeEnum] = Field(default=None, description="Confidential clients are capable of maintaining the confidentiality of their credentials. Public clients are incapable") + grant_types: Optional[List[GrantTypesEnum]] = None + client_id: Optional[Annotated[str, Field(strict=True, max_length=255)]] = None + client_secret: Optional[Annotated[str, Field(strict=True, max_length=255)]] = None + access_code_validity: Optional[StrictStr] = Field(default=None, description="Access codes not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + access_token_validity: Optional[StrictStr] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + refresh_token_validity: Optional[StrictStr] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + refresh_token_threshold: Optional[StrictStr] = Field(default=None, description="When refreshing a token, if the refresh token is valid for less than this duration, it will be renewed. When set to seconds=0, token will always be renewed. (Format: hours=1;minutes=2;seconds=3).") + include_claims_in_id_token: Optional[StrictBool] = Field(default=None, description="Include User claims from scopes in the id_token, for applications that don't access the userinfo endpoint.") + signing_key: Optional[UUID] = Field(default=None, description="Key used to sign the tokens.") + encryption_key: Optional[UUID] = Field(default=None, description="Key used to encrypt the tokens. When set, tokens will be encrypted and returned as JWEs.") + redirect_uris: List[RedirectURI] + logout_uri: Optional[StrictStr] = None + logout_method: Optional[OAuth2ProviderLogoutMethodEnum] = Field(default=None, description="Backchannel logs out with server to server calls. Frontchannel uses iframes in your browser") + sub_mode: Optional[SubModeEnum] = Field(default=None, description="Configure what data should be used as unique User Identifier. For most cases, the default should be fine.") + issuer_mode: Optional[IssuerModeEnum] = Field(default=None, description="Configure how the issuer field of the ID Token should be filled.") + jwt_federation_sources: Optional[List[UUID]] = None + jwt_federation_providers: Optional[List[StrictInt]] = None + __properties: ClassVar[List[str]] = ["pk", "name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "component", "assigned_application_slug", "assigned_application_name", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "client_type", "grant_types", "client_id", "client_secret", "access_code_validity", "access_token_validity", "refresh_token_validity", "refresh_token_threshold", "include_claims_in_id_token", "signing_key", "encryption_key", "redirect_uris", "logout_uri", "logout_method", "sub_mode", "issuer_mode", "jwt_federation_sources", "jwt_federation_providers"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuth2Provider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_application_slug", + "assigned_application_name", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in redirect_uris (list) + _items = [] + if self.redirect_uris: + for _item_redirect_uris in self.redirect_uris: + if _item_redirect_uris: + _items.append(_item_redirect_uris.to_dict()) + _dict['redirect_uris'] = _items + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if assigned_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_slug is None and "assigned_application_slug" in self.model_fields_set: + _dict['assigned_application_slug'] = None + + # set to None if assigned_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_name is None and "assigned_application_name" in self.model_fields_set: + _dict['assigned_application_name'] = None + + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + # set to None if signing_key (nullable) is None + # and model_fields_set contains the field + if self.signing_key is None and "signing_key" in self.model_fields_set: + _dict['signing_key'] = None + + # set to None if encryption_key (nullable) is None + # and model_fields_set contains the field + if self.encryption_key is None and "encryption_key" in self.model_fields_set: + _dict['encryption_key'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuth2Provider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "component": obj.get("component"), + "assigned_application_slug": obj.get("assigned_application_slug"), + "assigned_application_name": obj.get("assigned_application_name"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "client_type": obj.get("client_type"), + "grant_types": obj.get("grant_types"), + "client_id": obj.get("client_id"), + "client_secret": obj.get("client_secret"), + "access_code_validity": obj.get("access_code_validity"), + "access_token_validity": obj.get("access_token_validity"), + "refresh_token_validity": obj.get("refresh_token_validity"), + "refresh_token_threshold": obj.get("refresh_token_threshold"), + "include_claims_in_id_token": obj.get("include_claims_in_id_token"), + "signing_key": obj.get("signing_key"), + "encryption_key": obj.get("encryption_key"), + "redirect_uris": [RedirectURI.from_dict(_item) for _item in obj["redirect_uris"]] if obj.get("redirect_uris") is not None else None, + "logout_uri": obj.get("logout_uri"), + "logout_method": obj.get("logout_method"), + "sub_mode": obj.get("sub_mode"), + "issuer_mode": obj.get("issuer_mode"), + "jwt_federation_sources": obj.get("jwt_federation_sources"), + "jwt_federation_providers": obj.get("jwt_federation_providers") + }) + return _obj + + diff --git a/authentik_client/models/o_auth2_provider_logout_method_enum.py b/authentik_client/models/o_auth2_provider_logout_method_enum.py new file mode 100644 index 000000000..be1e615f4 --- /dev/null +++ b/authentik_client/models/o_auth2_provider_logout_method_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class OAuth2ProviderLogoutMethodEnum(str, Enum): + """ + OAuth2ProviderLogoutMethodEnum + """ + + """ + allowed enum values + """ + BACKCHANNEL = 'backchannel' + FRONTCHANNEL = 'frontchannel' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of OAuth2ProviderLogoutMethodEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/o_auth2_provider_request.py b/authentik_client/models/o_auth2_provider_request.py new file mode 100644 index 000000000..ac789da04 --- /dev/null +++ b/authentik_client/models/o_auth2_provider_request.py @@ -0,0 +1,163 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.client_type_enum import ClientTypeEnum +from authentik_client.models.grant_types_enum import GrantTypesEnum +from authentik_client.models.issuer_mode_enum import IssuerModeEnum +from authentik_client.models.o_auth2_provider_logout_method_enum import OAuth2ProviderLogoutMethodEnum +from authentik_client.models.redirect_uri_request import RedirectURIRequest +from authentik_client.models.sub_mode_enum import SubModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuth2ProviderRequest(BaseModel): + """ + OAuth2Provider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + client_type: Optional[ClientTypeEnum] = Field(default=None, description="Confidential clients are capable of maintaining the confidentiality of their credentials. Public clients are incapable") + grant_types: Optional[List[GrantTypesEnum]] = None + client_id: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=255)]] = None + client_secret: Optional[Annotated[str, Field(strict=True, max_length=255)]] = None + access_code_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Access codes not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + access_token_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + refresh_token_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + refresh_token_threshold: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="When refreshing a token, if the refresh token is valid for less than this duration, it will be renewed. When set to seconds=0, token will always be renewed. (Format: hours=1;minutes=2;seconds=3).") + include_claims_in_id_token: Optional[StrictBool] = Field(default=None, description="Include User claims from scopes in the id_token, for applications that don't access the userinfo endpoint.") + signing_key: Optional[UUID] = Field(default=None, description="Key used to sign the tokens.") + encryption_key: Optional[UUID] = Field(default=None, description="Key used to encrypt the tokens. When set, tokens will be encrypted and returned as JWEs.") + redirect_uris: List[RedirectURIRequest] + logout_uri: Optional[StrictStr] = None + logout_method: Optional[OAuth2ProviderLogoutMethodEnum] = Field(default=None, description="Backchannel logs out with server to server calls. Frontchannel uses iframes in your browser") + sub_mode: Optional[SubModeEnum] = Field(default=None, description="Configure what data should be used as unique User Identifier. For most cases, the default should be fine.") + issuer_mode: Optional[IssuerModeEnum] = Field(default=None, description="Configure how the issuer field of the ID Token should be filled.") + jwt_federation_sources: Optional[List[UUID]] = None + jwt_federation_providers: Optional[List[StrictInt]] = None + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "client_type", "grant_types", "client_id", "client_secret", "access_code_validity", "access_token_validity", "refresh_token_validity", "refresh_token_threshold", "include_claims_in_id_token", "signing_key", "encryption_key", "redirect_uris", "logout_uri", "logout_method", "sub_mode", "issuer_mode", "jwt_federation_sources", "jwt_federation_providers"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuth2ProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in redirect_uris (list) + _items = [] + if self.redirect_uris: + for _item_redirect_uris in self.redirect_uris: + if _item_redirect_uris: + _items.append(_item_redirect_uris.to_dict()) + _dict['redirect_uris'] = _items + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if signing_key (nullable) is None + # and model_fields_set contains the field + if self.signing_key is None and "signing_key" in self.model_fields_set: + _dict['signing_key'] = None + + # set to None if encryption_key (nullable) is None + # and model_fields_set contains the field + if self.encryption_key is None and "encryption_key" in self.model_fields_set: + _dict['encryption_key'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuth2ProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "client_type": obj.get("client_type"), + "grant_types": obj.get("grant_types"), + "client_id": obj.get("client_id"), + "client_secret": obj.get("client_secret"), + "access_code_validity": obj.get("access_code_validity"), + "access_token_validity": obj.get("access_token_validity"), + "refresh_token_validity": obj.get("refresh_token_validity"), + "refresh_token_threshold": obj.get("refresh_token_threshold"), + "include_claims_in_id_token": obj.get("include_claims_in_id_token"), + "signing_key": obj.get("signing_key"), + "encryption_key": obj.get("encryption_key"), + "redirect_uris": [RedirectURIRequest.from_dict(_item) for _item in obj["redirect_uris"]] if obj.get("redirect_uris") is not None else None, + "logout_uri": obj.get("logout_uri"), + "logout_method": obj.get("logout_method"), + "sub_mode": obj.get("sub_mode"), + "issuer_mode": obj.get("issuer_mode"), + "jwt_federation_sources": obj.get("jwt_federation_sources"), + "jwt_federation_providers": obj.get("jwt_federation_providers") + }) + return _obj + + diff --git a/authentik_client/models/o_auth2_provider_setup_urls.py b/authentik_client/models/o_auth2_provider_setup_urls.py new file mode 100644 index 000000000..adee7d634 --- /dev/null +++ b/authentik_client/models/o_auth2_provider_setup_urls.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuth2ProviderSetupURLs(BaseModel): + """ + OAuth2 Provider Metadata serializer + """ # noqa: E501 + issuer: StrictStr + authorize: StrictStr + token: StrictStr + user_info: StrictStr + provider_info: StrictStr + logout: StrictStr + jwks: StrictStr + __properties: ClassVar[List[str]] = ["issuer", "authorize", "token", "user_info", "provider_info", "logout", "jwks"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuth2ProviderSetupURLs from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "issuer", + "authorize", + "token", + "user_info", + "provider_info", + "logout", + "jwks", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuth2ProviderSetupURLs from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "issuer": obj.get("issuer"), + "authorize": obj.get("authorize"), + "token": obj.get("token"), + "user_info": obj.get("user_info"), + "provider_info": obj.get("provider_info"), + "logout": obj.get("logout"), + "jwks": obj.get("jwks") + }) + return _obj + + diff --git a/authentik_client/models/o_auth_device_code_challenge.py b/authentik_client/models/o_auth_device_code_challenge.py new file mode 100644 index 000000000..f636a5234 --- /dev/null +++ b/authentik_client/models/o_auth_device_code_challenge.py @@ -0,0 +1,112 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuthDeviceCodeChallenge(BaseModel): + """ + OAuth Device code challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-provider-oauth2-device-code' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuthDeviceCodeChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuthDeviceCodeChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-provider-oauth2-device-code', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None + }) + return _obj + + diff --git a/authentik_client/models/o_auth_device_code_challenge_response_request.py b/authentik_client/models/o_auth_device_code_challenge_response_request.py new file mode 100644 index 000000000..780bc528c --- /dev/null +++ b/authentik_client/models/o_auth_device_code_challenge_response_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuthDeviceCodeChallengeResponseRequest(BaseModel): + """ + Response that includes the user-entered device code + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-provider-oauth2-device-code' + code: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["component", "code"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuthDeviceCodeChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuthDeviceCodeChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-provider-oauth2-device-code', + "code": obj.get("code") + }) + return _obj + + diff --git a/authentik_client/models/o_auth_device_code_finish_challenge.py b/authentik_client/models/o_auth_device_code_finish_challenge.py new file mode 100644 index 000000000..027bb66d9 --- /dev/null +++ b/authentik_client/models/o_auth_device_code_finish_challenge.py @@ -0,0 +1,112 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuthDeviceCodeFinishChallenge(BaseModel): + """ + Final challenge after user enters their code + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-provider-oauth2-device-code-finish' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuthDeviceCodeFinishChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuthDeviceCodeFinishChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-provider-oauth2-device-code-finish', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None + }) + return _obj + + diff --git a/authentik_client/models/o_auth_device_code_finish_challenge_response_request.py b/authentik_client/models/o_auth_device_code_finish_challenge_response_request.py new file mode 100644 index 000000000..59415292f --- /dev/null +++ b/authentik_client/models/o_auth_device_code_finish_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuthDeviceCodeFinishChallengeResponseRequest(BaseModel): + """ + Response that device has been authenticated and tab can be closed + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-provider-oauth2-device-code-finish' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuthDeviceCodeFinishChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuthDeviceCodeFinishChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-provider-oauth2-device-code-finish' + }) + return _obj + + diff --git a/authentik_client/models/o_auth_source.py b/authentik_client/models/o_auth_source.py new file mode 100644 index 000000000..51d0ac1ff --- /dev/null +++ b/authentik_client/models/o_auth_source.py @@ -0,0 +1,248 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.authorization_code_auth_method_enum import AuthorizationCodeAuthMethodEnum +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.pkce_method_enum import PKCEMethodEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.provider_type_enum import ProviderTypeEnum +from authentik_client.models.source_type import SourceType +from authentik_client.models.themed_urls import ThemedUrls +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuthSource(BaseModel): + """ + OAuth Source Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr = Field(description="Source's display Name.") + slug: Annotated[str, Field(strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + managed: Optional[StrictStr] = Field(description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + user_path_template: Optional[StrictStr] = None + icon: Optional[StrictStr] = None + icon_url: Optional[StrictStr] + icon_themed_urls: Optional[ThemedUrls] + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + provider_type: ProviderTypeEnum + request_token_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL used to request the initial token. This URL is only required for OAuth 1.") + authorization_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL the user is redirect to to conest the flow.") + access_token_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL used by authentik to retrieve tokens.") + profile_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL used by authentik to get user information.") + pkce: Optional[PKCEMethodEnum] = None + consumer_key: StrictStr + callback_url: StrictStr = Field(description="Get OAuth Callback URL") + additional_scopes: Optional[StrictStr] = None + type: SourceType + oidc_well_known_url: Optional[StrictStr] = None + oidc_jwks_url: Optional[StrictStr] = None + oidc_jwks: Optional[Dict[str, Any]] = None + authorization_code_auth_method: Optional[AuthorizationCodeAuthMethodEnum] = Field(default=None, description="How to perform authentication during an authorization_code token request flow") + __properties: ClassVar[List[str]] = ["pk", "name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "policy_engine_mode", "user_matching_mode", "managed", "user_path_template", "icon", "icon_url", "icon_themed_urls", "group_matching_mode", "provider_type", "request_token_url", "authorization_url", "access_token_url", "profile_url", "pkce", "consumer_key", "callback_url", "additional_scopes", "type", "oidc_well_known_url", "oidc_jwks_url", "oidc_jwks", "authorization_code_auth_method"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuthSource from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "managed", + "icon_url", + "icon_themed_urls", + "callback_url", + "type", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of icon_themed_urls + if self.icon_themed_urls: + _dict['icon_themed_urls'] = self.icon_themed_urls.to_dict() + # override the default output from pydantic by calling `to_dict()` of type + if self.type: + _dict['type'] = self.type.to_dict() + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if icon_url (nullable) is None + # and model_fields_set contains the field + if self.icon_url is None and "icon_url" in self.model_fields_set: + _dict['icon_url'] = None + + # set to None if icon_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.icon_themed_urls is None and "icon_themed_urls" in self.model_fields_set: + _dict['icon_themed_urls'] = None + + # set to None if request_token_url (nullable) is None + # and model_fields_set contains the field + if self.request_token_url is None and "request_token_url" in self.model_fields_set: + _dict['request_token_url'] = None + + # set to None if authorization_url (nullable) is None + # and model_fields_set contains the field + if self.authorization_url is None and "authorization_url" in self.model_fields_set: + _dict['authorization_url'] = None + + # set to None if access_token_url (nullable) is None + # and model_fields_set contains the field + if self.access_token_url is None and "access_token_url" in self.model_fields_set: + _dict['access_token_url'] = None + + # set to None if profile_url (nullable) is None + # and model_fields_set contains the field + if self.profile_url is None and "profile_url" in self.model_fields_set: + _dict['profile_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuthSource from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "managed": obj.get("managed"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "icon_url": obj.get("icon_url"), + "icon_themed_urls": ThemedUrls.from_dict(obj["icon_themed_urls"]) if obj.get("icon_themed_urls") is not None else None, + "group_matching_mode": obj.get("group_matching_mode"), + "provider_type": obj.get("provider_type"), + "request_token_url": obj.get("request_token_url"), + "authorization_url": obj.get("authorization_url"), + "access_token_url": obj.get("access_token_url"), + "profile_url": obj.get("profile_url"), + "pkce": obj.get("pkce"), + "consumer_key": obj.get("consumer_key"), + "callback_url": obj.get("callback_url"), + "additional_scopes": obj.get("additional_scopes"), + "type": SourceType.from_dict(obj["type"]) if obj.get("type") is not None else None, + "oidc_well_known_url": obj.get("oidc_well_known_url"), + "oidc_jwks_url": obj.get("oidc_jwks_url"), + "oidc_jwks": obj.get("oidc_jwks"), + "authorization_code_auth_method": obj.get("authorization_code_auth_method") + }) + return _obj + + diff --git a/authentik_client/models/o_auth_source_property_mapping.py b/authentik_client/models/o_auth_source_property_mapping.py new file mode 100644 index 000000000..acd8b3964 --- /dev/null +++ b/authentik_client/models/o_auth_source_property_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuthSourcePropertyMapping(BaseModel): + """ + OAuthSourcePropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuthSourcePropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuthSourcePropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/o_auth_source_property_mapping_request.py b/authentik_client/models/o_auth_source_property_mapping_request.py new file mode 100644 index 000000000..b5bf2d4d1 --- /dev/null +++ b/authentik_client/models/o_auth_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuthSourcePropertyMappingRequest(BaseModel): + """ + OAuthSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuthSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuthSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/o_auth_source_request.py b/authentik_client/models/o_auth_source_request.py new file mode 100644 index 000000000..b6e38ee1f --- /dev/null +++ b/authentik_client/models/o_auth_source_request.py @@ -0,0 +1,187 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.authorization_code_auth_method_enum import AuthorizationCodeAuthMethodEnum +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.pkce_method_enum import PKCEMethodEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.provider_type_enum import ProviderTypeEnum +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OAuthSourceRequest(BaseModel): + """ + OAuth Source Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Source's display Name.") + slug: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + provider_type: ProviderTypeEnum + request_token_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL used to request the initial token. This URL is only required for OAuth 1.") + authorization_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL the user is redirect to to conest the flow.") + access_token_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL used by authentik to retrieve tokens.") + profile_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL used by authentik to get user information.") + pkce: Optional[PKCEMethodEnum] = None + consumer_key: Annotated[str, Field(min_length=1, strict=True)] + consumer_secret: Annotated[str, Field(min_length=1, strict=True)] + additional_scopes: Optional[StrictStr] = None + oidc_well_known_url: Optional[StrictStr] = None + oidc_jwks_url: Optional[StrictStr] = None + oidc_jwks: Optional[Dict[str, Any]] = None + authorization_code_auth_method: Optional[AuthorizationCodeAuthMethodEnum] = Field(default=None, description="How to perform authentication during an authorization_code token request flow") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "group_matching_mode", "provider_type", "request_token_url", "authorization_url", "access_token_url", "profile_url", "pkce", "consumer_key", "consumer_secret", "additional_scopes", "oidc_well_known_url", "oidc_jwks_url", "oidc_jwks", "authorization_code_auth_method"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OAuthSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if request_token_url (nullable) is None + # and model_fields_set contains the field + if self.request_token_url is None and "request_token_url" in self.model_fields_set: + _dict['request_token_url'] = None + + # set to None if authorization_url (nullable) is None + # and model_fields_set contains the field + if self.authorization_url is None and "authorization_url" in self.model_fields_set: + _dict['authorization_url'] = None + + # set to None if access_token_url (nullable) is None + # and model_fields_set contains the field + if self.access_token_url is None and "access_token_url" in self.model_fields_set: + _dict['access_token_url'] = None + + # set to None if profile_url (nullable) is None + # and model_fields_set contains the field + if self.profile_url is None and "profile_url" in self.model_fields_set: + _dict['profile_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OAuthSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "group_matching_mode": obj.get("group_matching_mode"), + "provider_type": obj.get("provider_type"), + "request_token_url": obj.get("request_token_url"), + "authorization_url": obj.get("authorization_url"), + "access_token_url": obj.get("access_token_url"), + "profile_url": obj.get("profile_url"), + "pkce": obj.get("pkce"), + "consumer_key": obj.get("consumer_key"), + "consumer_secret": obj.get("consumer_secret"), + "additional_scopes": obj.get("additional_scopes"), + "oidc_well_known_url": obj.get("oidc_well_known_url"), + "oidc_jwks_url": obj.get("oidc_jwks_url"), + "oidc_jwks": obj.get("oidc_jwks"), + "authorization_code_auth_method": obj.get("authorization_code_auth_method") + }) + return _obj + + diff --git a/authentik_client/models/open_id_connect_configuration.py b/authentik_client/models/open_id_connect_configuration.py new file mode 100644 index 000000000..c1c662698 --- /dev/null +++ b/authentik_client/models/open_id_connect_configuration.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OpenIDConnectConfiguration(BaseModel): + """ + rest_framework Serializer for OIDC Configuration + """ # noqa: E501 + issuer: StrictStr + authorization_endpoint: StrictStr + token_endpoint: StrictStr + userinfo_endpoint: StrictStr + end_session_endpoint: StrictStr + introspection_endpoint: StrictStr + jwks_uri: StrictStr + response_types_supported: List[StrictStr] + id_token_signing_alg_values_supported: List[StrictStr] + subject_types_supported: List[StrictStr] + token_endpoint_auth_methods_supported: List[StrictStr] + __properties: ClassVar[List[str]] = ["issuer", "authorization_endpoint", "token_endpoint", "userinfo_endpoint", "end_session_endpoint", "introspection_endpoint", "jwks_uri", "response_types_supported", "id_token_signing_alg_values_supported", "subject_types_supported", "token_endpoint_auth_methods_supported"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OpenIDConnectConfiguration from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OpenIDConnectConfiguration from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "issuer": obj.get("issuer"), + "authorization_endpoint": obj.get("authorization_endpoint"), + "token_endpoint": obj.get("token_endpoint"), + "userinfo_endpoint": obj.get("userinfo_endpoint"), + "end_session_endpoint": obj.get("end_session_endpoint"), + "introspection_endpoint": obj.get("introspection_endpoint"), + "jwks_uri": obj.get("jwks_uri"), + "response_types_supported": obj.get("response_types_supported"), + "id_token_signing_alg_values_supported": obj.get("id_token_signing_alg_values_supported"), + "subject_types_supported": obj.get("subject_types_supported"), + "token_endpoint_auth_methods_supported": obj.get("token_endpoint_auth_methods_supported") + }) + return _obj + + diff --git a/authentik_client/models/operating_system.py b/authentik_client/models/operating_system.py new file mode 100644 index 000000000..d4c6485bf --- /dev/null +++ b/authentik_client/models/operating_system.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.device_facts_os_family import DeviceFactsOSFamily +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OperatingSystem(BaseModel): + """ + For example: {\"family\":\"linux\",\"name\":\"Ubuntu\",\"version\":\"24.04.3 LTS (Noble Numbat)\",\"arch\":\"amd64\"} {\"family\": \"windows\",\"name\":\"Server 2022 Datacenter\",\"version\":\"10.0.20348.4405\",\"arch\":\"amd64\"} {\"family\": \"windows\",\"name\":\"Server 2022 Datacenter\",\"version\":\"10.0.20348.4405\",\"arch\":\"amd64\"} {\"family\": \"mac_os\", \"name\": \"\", \"version\": \"26.2\", \"arch\": \"arm64\"} + """ # noqa: E501 + family: DeviceFactsOSFamily + name: Optional[StrictStr] = Field(default=None, description="Operating System name, such as 'Server 2022' or 'Ubuntu'") + version: Optional[StrictStr] = Field(default=None, description="Operating System version, must always be the version number but may contain build name") + arch: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["family", "name", "version", "arch"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OperatingSystem from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OperatingSystem from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "family": obj.get("family"), + "name": obj.get("name"), + "version": obj.get("version"), + "arch": obj.get("arch") + }) + return _obj + + diff --git a/authentik_client/models/operating_system_request.py b/authentik_client/models/operating_system_request.py new file mode 100644 index 000000000..a1366578a --- /dev/null +++ b/authentik_client/models/operating_system_request.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.device_facts_os_family import DeviceFactsOSFamily +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OperatingSystemRequest(BaseModel): + """ + For example: {\"family\":\"linux\",\"name\":\"Ubuntu\",\"version\":\"24.04.3 LTS (Noble Numbat)\",\"arch\":\"amd64\"} {\"family\": \"windows\",\"name\":\"Server 2022 Datacenter\",\"version\":\"10.0.20348.4405\",\"arch\":\"amd64\"} {\"family\": \"windows\",\"name\":\"Server 2022 Datacenter\",\"version\":\"10.0.20348.4405\",\"arch\":\"amd64\"} {\"family\": \"mac_os\", \"name\": \"\", \"version\": \"26.2\", \"arch\": \"arm64\"} + """ # noqa: E501 + family: DeviceFactsOSFamily + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Operating System name, such as 'Server 2022' or 'Ubuntu'") + version: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Operating System version, must always be the version number but may contain build name") + arch: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["family", "name", "version", "arch"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OperatingSystemRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OperatingSystemRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "family": obj.get("family"), + "name": obj.get("name"), + "version": obj.get("version"), + "arch": obj.get("arch") + }) + return _obj + + diff --git a/authentik_client/models/outgoing_sync_delete_action.py b/authentik_client/models/outgoing_sync_delete_action.py new file mode 100644 index 000000000..5696588bd --- /dev/null +++ b/authentik_client/models/outgoing_sync_delete_action.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class OutgoingSyncDeleteAction(str, Enum): + """ + OutgoingSyncDeleteAction + """ + + """ + allowed enum values + """ + DO_NOTHING = 'do_nothing' + DELETE = 'delete' + SUSPEND = 'suspend' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of OutgoingSyncDeleteAction from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/outpost.py b/authentik_client/models/outpost.py new file mode 100644 index 000000000..abe202abe --- /dev/null +++ b/authentik_client/models/outpost.py @@ -0,0 +1,148 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.outpost_type_enum import OutpostTypeEnum +from authentik_client.models.provider import Provider +from authentik_client.models.service_connection import ServiceConnection +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Outpost(BaseModel): + """ + Outpost Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + type: OutpostTypeEnum + providers: List[StrictInt] + providers_obj: List[Provider] + service_connection: Optional[UUID] = Field(default=None, description="Select Service-Connection authentik should use to manage this outpost. Leave empty if authentik should not handle the deployment.") + service_connection_obj: Optional[ServiceConnection] + refresh_interval_s: StrictInt + token_identifier: StrictStr = Field(description="Get Token identifier") + config: Dict[str, Any] + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + __properties: ClassVar[List[str]] = ["pk", "name", "type", "providers", "providers_obj", "service_connection", "service_connection_obj", "refresh_interval_s", "token_identifier", "config", "managed"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Outpost from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "providers_obj", + "service_connection_obj", + "refresh_interval_s", + "token_identifier", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in providers_obj (list) + _items = [] + if self.providers_obj: + for _item_providers_obj in self.providers_obj: + if _item_providers_obj: + _items.append(_item_providers_obj.to_dict()) + _dict['providers_obj'] = _items + # override the default output from pydantic by calling `to_dict()` of service_connection_obj + if self.service_connection_obj: + _dict['service_connection_obj'] = self.service_connection_obj.to_dict() + # set to None if service_connection (nullable) is None + # and model_fields_set contains the field + if self.service_connection is None and "service_connection" in self.model_fields_set: + _dict['service_connection'] = None + + # set to None if service_connection_obj (nullable) is None + # and model_fields_set contains the field + if self.service_connection_obj is None and "service_connection_obj" in self.model_fields_set: + _dict['service_connection_obj'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Outpost from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "type": obj.get("type"), + "providers": obj.get("providers"), + "providers_obj": [Provider.from_dict(_item) for _item in obj["providers_obj"]] if obj.get("providers_obj") is not None else None, + "service_connection": obj.get("service_connection"), + "service_connection_obj": ServiceConnection.from_dict(obj["service_connection_obj"]) if obj.get("service_connection_obj") is not None else None, + "refresh_interval_s": obj.get("refresh_interval_s"), + "token_identifier": obj.get("token_identifier"), + "config": obj.get("config"), + "managed": obj.get("managed") + }) + return _obj + + diff --git a/authentik_client/models/outpost_default_config.py b/authentik_client/models/outpost_default_config.py new file mode 100644 index 000000000..d41008b79 --- /dev/null +++ b/authentik_client/models/outpost_default_config.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OutpostDefaultConfig(BaseModel): + """ + Global default outpost config + """ # noqa: E501 + config: Dict[str, Any] + __properties: ClassVar[List[str]] = ["config"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OutpostDefaultConfig from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "config", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OutpostDefaultConfig from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "config": obj.get("config") + }) + return _obj + + diff --git a/authentik_client/models/outpost_health.py b/authentik_client/models/outpost_health.py new file mode 100644 index 000000000..4074c754c --- /dev/null +++ b/authentik_client/models/outpost_health.py @@ -0,0 +1,141 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OutpostHealth(BaseModel): + """ + Outpost health status + """ # noqa: E501 + uid: StrictStr + last_seen: datetime + version: StrictStr + golang_version: StrictStr + openssl_enabled: StrictBool + openssl_version: StrictStr + fips_enabled: Optional[StrictBool] = Field(description="Get FIPS enabled") + version_should: StrictStr + version_outdated: StrictBool + build_hash: StrictStr + build_hash_should: StrictStr + hostname: StrictStr + __properties: ClassVar[List[str]] = ["uid", "last_seen", "version", "golang_version", "openssl_enabled", "openssl_version", "fips_enabled", "version_should", "version_outdated", "build_hash", "build_hash_should", "hostname"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OutpostHealth from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "uid", + "last_seen", + "version", + "golang_version", + "openssl_enabled", + "openssl_version", + "fips_enabled", + "version_should", + "version_outdated", + "build_hash", + "build_hash_should", + "hostname", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if fips_enabled (nullable) is None + # and model_fields_set contains the field + if self.fips_enabled is None and "fips_enabled" in self.model_fields_set: + _dict['fips_enabled'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OutpostHealth from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "uid": obj.get("uid"), + "last_seen": obj.get("last_seen"), + "version": obj.get("version"), + "golang_version": obj.get("golang_version"), + "openssl_enabled": obj.get("openssl_enabled"), + "openssl_version": obj.get("openssl_version"), + "fips_enabled": obj.get("fips_enabled"), + "version_should": obj.get("version_should"), + "version_outdated": obj.get("version_outdated"), + "build_hash": obj.get("build_hash"), + "build_hash_should": obj.get("build_hash_should"), + "hostname": obj.get("hostname") + }) + return _obj + + diff --git a/authentik_client/models/outpost_request.py b/authentik_client/models/outpost_request.py new file mode 100644 index 000000000..a70804982 --- /dev/null +++ b/authentik_client/models/outpost_request.py @@ -0,0 +1,112 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.outpost_type_enum import OutpostTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class OutpostRequest(BaseModel): + """ + Outpost Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + type: OutpostTypeEnum + providers: List[StrictInt] + service_connection: Optional[UUID] = Field(default=None, description="Select Service-Connection authentik should use to manage this outpost. Leave empty if authentik should not handle the deployment.") + config: Dict[str, Any] + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + __properties: ClassVar[List[str]] = ["name", "type", "providers", "service_connection", "config", "managed"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of OutpostRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if service_connection (nullable) is None + # and model_fields_set contains the field + if self.service_connection is None and "service_connection" in self.model_fields_set: + _dict['service_connection'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of OutpostRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "type": obj.get("type"), + "providers": obj.get("providers"), + "service_connection": obj.get("service_connection"), + "config": obj.get("config"), + "managed": obj.get("managed") + }) + return _obj + + diff --git a/authentik_client/models/outpost_type_enum.py b/authentik_client/models/outpost_type_enum.py new file mode 100644 index 000000000..142ca25c7 --- /dev/null +++ b/authentik_client/models/outpost_type_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class OutpostTypeEnum(str, Enum): + """ + OutpostTypeEnum + """ + + """ + allowed enum values + """ + PROXY = 'proxy' + LDAP = 'ldap' + RADIUS = 'radius' + RAC = 'rac' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of OutpostTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/paginated_account_lockdown_stage_list.py b/authentik_client/models/paginated_account_lockdown_stage_list.py new file mode 100644 index 000000000..d221007b1 --- /dev/null +++ b/authentik_client/models/paginated_account_lockdown_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.account_lockdown_stage import AccountLockdownStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAccountLockdownStageList(BaseModel): + """ + PaginatedAccountLockdownStageList + """ # noqa: E501 + pagination: Pagination + results: List[AccountLockdownStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAccountLockdownStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAccountLockdownStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AccountLockdownStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_agent_connector_list.py b/authentik_client/models/paginated_agent_connector_list.py new file mode 100644 index 000000000..a977b66ab --- /dev/null +++ b/authentik_client/models/paginated_agent_connector_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.agent_connector import AgentConnector +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAgentConnectorList(BaseModel): + """ + PaginatedAgentConnectorList + """ # noqa: E501 + pagination: Pagination + results: List[AgentConnector] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAgentConnectorList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAgentConnectorList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AgentConnector.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_apple_independent_secure_enclave_list.py b/authentik_client/models/paginated_apple_independent_secure_enclave_list.py new file mode 100644 index 000000000..4c3c934bb --- /dev/null +++ b/authentik_client/models/paginated_apple_independent_secure_enclave_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAppleIndependentSecureEnclaveList(BaseModel): + """ + PaginatedAppleIndependentSecureEnclaveList + """ # noqa: E501 + pagination: Pagination + results: List[AppleIndependentSecureEnclave] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAppleIndependentSecureEnclaveList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAppleIndependentSecureEnclaveList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AppleIndependentSecureEnclave.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_application_entitlement_list.py b/authentik_client/models/paginated_application_entitlement_list.py new file mode 100644 index 000000000..cfa52dd9c --- /dev/null +++ b/authentik_client/models/paginated_application_entitlement_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.application_entitlement import ApplicationEntitlement +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedApplicationEntitlementList(BaseModel): + """ + PaginatedApplicationEntitlementList + """ # noqa: E501 + pagination: Pagination + results: List[ApplicationEntitlement] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedApplicationEntitlementList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedApplicationEntitlementList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ApplicationEntitlement.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_application_list.py b/authentik_client/models/paginated_application_list.py new file mode 100644 index 000000000..cced99a3b --- /dev/null +++ b/authentik_client/models/paginated_application_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.application import Application +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedApplicationList(BaseModel): + """ + PaginatedApplicationList + """ # noqa: E501 + pagination: Pagination + results: List[Application] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedApplicationList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedApplicationList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Application.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_authenticated_session_list.py b/authentik_client/models/paginated_authenticated_session_list.py new file mode 100644 index 000000000..2abff2bc7 --- /dev/null +++ b/authentik_client/models/paginated_authenticated_session_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticated_session import AuthenticatedSession +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAuthenticatedSessionList(BaseModel): + """ + PaginatedAuthenticatedSessionList + """ # noqa: E501 + pagination: Pagination + results: List[AuthenticatedSession] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatedSessionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatedSessionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AuthenticatedSession.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_authenticator_duo_stage_list.py b/authentik_client/models/paginated_authenticator_duo_stage_list.py new file mode 100644 index 000000000..dc17fc116 --- /dev/null +++ b/authentik_client/models/paginated_authenticator_duo_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAuthenticatorDuoStageList(BaseModel): + """ + PaginatedAuthenticatorDuoStageList + """ # noqa: E501 + pagination: Pagination + results: List[AuthenticatorDuoStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorDuoStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorDuoStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AuthenticatorDuoStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_authenticator_email_stage_list.py b/authentik_client/models/paginated_authenticator_email_stage_list.py new file mode 100644 index 000000000..0d5315dff --- /dev/null +++ b/authentik_client/models/paginated_authenticator_email_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAuthenticatorEmailStageList(BaseModel): + """ + PaginatedAuthenticatorEmailStageList + """ # noqa: E501 + pagination: Pagination + results: List[AuthenticatorEmailStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorEmailStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorEmailStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AuthenticatorEmailStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_authenticator_endpoint_gdtc_stage_list.py b/authentik_client/models/paginated_authenticator_endpoint_gdtc_stage_list.py new file mode 100644 index 000000000..d143ad2b4 --- /dev/null +++ b/authentik_client/models/paginated_authenticator_endpoint_gdtc_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAuthenticatorEndpointGDTCStageList(BaseModel): + """ + PaginatedAuthenticatorEndpointGDTCStageList + """ # noqa: E501 + pagination: Pagination + results: List[AuthenticatorEndpointGDTCStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorEndpointGDTCStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorEndpointGDTCStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AuthenticatorEndpointGDTCStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_authenticator_sms_stage_list.py b/authentik_client/models/paginated_authenticator_sms_stage_list.py new file mode 100644 index 000000000..95c7f4e9b --- /dev/null +++ b/authentik_client/models/paginated_authenticator_sms_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAuthenticatorSMSStageList(BaseModel): + """ + PaginatedAuthenticatorSMSStageList + """ # noqa: E501 + pagination: Pagination + results: List[AuthenticatorSMSStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorSMSStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorSMSStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AuthenticatorSMSStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_authenticator_static_stage_list.py b/authentik_client/models/paginated_authenticator_static_stage_list.py new file mode 100644 index 000000000..666a757bd --- /dev/null +++ b/authentik_client/models/paginated_authenticator_static_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAuthenticatorStaticStageList(BaseModel): + """ + PaginatedAuthenticatorStaticStageList + """ # noqa: E501 + pagination: Pagination + results: List[AuthenticatorStaticStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorStaticStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorStaticStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AuthenticatorStaticStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_authenticator_totp_stage_list.py b/authentik_client/models/paginated_authenticator_totp_stage_list.py new file mode 100644 index 000000000..806772cd4 --- /dev/null +++ b/authentik_client/models/paginated_authenticator_totp_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAuthenticatorTOTPStageList(BaseModel): + """ + PaginatedAuthenticatorTOTPStageList + """ # noqa: E501 + pagination: Pagination + results: List[AuthenticatorTOTPStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorTOTPStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorTOTPStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AuthenticatorTOTPStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_authenticator_validate_stage_list.py b/authentik_client/models/paginated_authenticator_validate_stage_list.py new file mode 100644 index 000000000..a8f89a152 --- /dev/null +++ b/authentik_client/models/paginated_authenticator_validate_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAuthenticatorValidateStageList(BaseModel): + """ + PaginatedAuthenticatorValidateStageList + """ # noqa: E501 + pagination: Pagination + results: List[AuthenticatorValidateStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorValidateStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorValidateStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AuthenticatorValidateStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_authenticator_web_authn_stage_list.py b/authentik_client/models/paginated_authenticator_web_authn_stage_list.py new file mode 100644 index 000000000..40ad098b6 --- /dev/null +++ b/authentik_client/models/paginated_authenticator_web_authn_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedAuthenticatorWebAuthnStageList(BaseModel): + """ + PaginatedAuthenticatorWebAuthnStageList + """ # noqa: E501 + pagination: Pagination + results: List[AuthenticatorWebAuthnStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorWebAuthnStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedAuthenticatorWebAuthnStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [AuthenticatorWebAuthnStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_blueprint_instance_list.py b/authentik_client/models/paginated_blueprint_instance_list.py new file mode 100644 index 000000000..cc0508569 --- /dev/null +++ b/authentik_client/models/paginated_blueprint_instance_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.blueprint_instance import BlueprintInstance +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedBlueprintInstanceList(BaseModel): + """ + PaginatedBlueprintInstanceList + """ # noqa: E501 + pagination: Pagination + results: List[BlueprintInstance] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedBlueprintInstanceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedBlueprintInstanceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [BlueprintInstance.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_brand_list.py b/authentik_client/models/paginated_brand_list.py new file mode 100644 index 000000000..3883a63c0 --- /dev/null +++ b/authentik_client/models/paginated_brand_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.brand import Brand +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedBrandList(BaseModel): + """ + PaginatedBrandList + """ # noqa: E501 + pagination: Pagination + results: List[Brand] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedBrandList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedBrandList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Brand.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_captcha_stage_list.py b/authentik_client/models/paginated_captcha_stage_list.py new file mode 100644 index 000000000..a2a983a5c --- /dev/null +++ b/authentik_client/models/paginated_captcha_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.captcha_stage import CaptchaStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedCaptchaStageList(BaseModel): + """ + PaginatedCaptchaStageList + """ # noqa: E501 + pagination: Pagination + results: List[CaptchaStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedCaptchaStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedCaptchaStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [CaptchaStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_certificate_key_pair_list.py b/authentik_client/models/paginated_certificate_key_pair_list.py new file mode 100644 index 000000000..c5e65bcbd --- /dev/null +++ b/authentik_client/models/paginated_certificate_key_pair_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.certificate_key_pair import CertificateKeyPair +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedCertificateKeyPairList(BaseModel): + """ + PaginatedCertificateKeyPairList + """ # noqa: E501 + pagination: Pagination + results: List[CertificateKeyPair] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedCertificateKeyPairList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedCertificateKeyPairList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [CertificateKeyPair.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_connection_token_list.py b/authentik_client/models/paginated_connection_token_list.py new file mode 100644 index 000000000..2bf8a3d31 --- /dev/null +++ b/authentik_client/models/paginated_connection_token_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.connection_token import ConnectionToken +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedConnectionTokenList(BaseModel): + """ + PaginatedConnectionTokenList + """ # noqa: E501 + pagination: Pagination + results: List[ConnectionToken] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedConnectionTokenList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedConnectionTokenList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ConnectionToken.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_connector_list.py b/authentik_client/models/paginated_connector_list.py new file mode 100644 index 000000000..9fd3dfe1d --- /dev/null +++ b/authentik_client/models/paginated_connector_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.connector import Connector +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedConnectorList(BaseModel): + """ + PaginatedConnectorList + """ # noqa: E501 + pagination: Pagination + results: List[Connector] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedConnectorList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedConnectorList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Connector.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_consent_stage_list.py b/authentik_client/models/paginated_consent_stage_list.py new file mode 100644 index 000000000..e93d3cccf --- /dev/null +++ b/authentik_client/models/paginated_consent_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.consent_stage import ConsentStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedConsentStageList(BaseModel): + """ + PaginatedConsentStageList + """ # noqa: E501 + pagination: Pagination + results: List[ConsentStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedConsentStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedConsentStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ConsentStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_data_export_list.py b/authentik_client/models/paginated_data_export_list.py new file mode 100644 index 000000000..999d36a56 --- /dev/null +++ b/authentik_client/models/paginated_data_export_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.data_export import DataExport +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedDataExportList(BaseModel): + """ + PaginatedDataExportList + """ # noqa: E501 + pagination: Pagination + results: List[DataExport] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedDataExportList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedDataExportList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [DataExport.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_deny_stage_list.py b/authentik_client/models/paginated_deny_stage_list.py new file mode 100644 index 000000000..d838f299f --- /dev/null +++ b/authentik_client/models/paginated_deny_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.deny_stage import DenyStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedDenyStageList(BaseModel): + """ + PaginatedDenyStageList + """ # noqa: E501 + pagination: Pagination + results: List[DenyStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedDenyStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedDenyStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [DenyStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_device_access_group_list.py b/authentik_client/models/paginated_device_access_group_list.py new file mode 100644 index 000000000..b7586d617 --- /dev/null +++ b/authentik_client/models/paginated_device_access_group_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.device_access_group import DeviceAccessGroup +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedDeviceAccessGroupList(BaseModel): + """ + PaginatedDeviceAccessGroupList + """ # noqa: E501 + pagination: Pagination + results: List[DeviceAccessGroup] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedDeviceAccessGroupList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedDeviceAccessGroupList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [DeviceAccessGroup.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_device_user_binding_list.py b/authentik_client/models/paginated_device_user_binding_list.py new file mode 100644 index 000000000..e0fa84c29 --- /dev/null +++ b/authentik_client/models/paginated_device_user_binding_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.device_user_binding import DeviceUserBinding +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedDeviceUserBindingList(BaseModel): + """ + PaginatedDeviceUserBindingList + """ # noqa: E501 + pagination: Pagination + results: List[DeviceUserBinding] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedDeviceUserBindingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedDeviceUserBindingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [DeviceUserBinding.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_docker_service_connection_list.py b/authentik_client/models/paginated_docker_service_connection_list.py new file mode 100644 index 000000000..d31eaad4c --- /dev/null +++ b/authentik_client/models/paginated_docker_service_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.docker_service_connection import DockerServiceConnection +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedDockerServiceConnectionList(BaseModel): + """ + PaginatedDockerServiceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[DockerServiceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedDockerServiceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedDockerServiceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [DockerServiceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_domain_list.py b/authentik_client/models/paginated_domain_list.py new file mode 100644 index 000000000..c03be9382 --- /dev/null +++ b/authentik_client/models/paginated_domain_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.domain import Domain +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedDomainList(BaseModel): + """ + PaginatedDomainList + """ # noqa: E501 + pagination: Pagination + results: List[Domain] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedDomainList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedDomainList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Domain.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_dummy_policy_list.py b/authentik_client/models/paginated_dummy_policy_list.py new file mode 100644 index 000000000..ad3f79b78 --- /dev/null +++ b/authentik_client/models/paginated_dummy_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.dummy_policy import DummyPolicy +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedDummyPolicyList(BaseModel): + """ + PaginatedDummyPolicyList + """ # noqa: E501 + pagination: Pagination + results: List[DummyPolicy] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedDummyPolicyList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedDummyPolicyList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [DummyPolicy.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_dummy_stage_list.py b/authentik_client/models/paginated_dummy_stage_list.py new file mode 100644 index 000000000..6975d2e2c --- /dev/null +++ b/authentik_client/models/paginated_dummy_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.dummy_stage import DummyStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedDummyStageList(BaseModel): + """ + PaginatedDummyStageList + """ # noqa: E501 + pagination: Pagination + results: List[DummyStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedDummyStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedDummyStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [DummyStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_duo_device_list.py b/authentik_client/models/paginated_duo_device_list.py new file mode 100644 index 000000000..044f4a9b0 --- /dev/null +++ b/authentik_client/models/paginated_duo_device_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.duo_device import DuoDevice +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedDuoDeviceList(BaseModel): + """ + PaginatedDuoDeviceList + """ # noqa: E501 + pagination: Pagination + results: List[DuoDevice] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedDuoDeviceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedDuoDeviceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [DuoDevice.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_email_device_list.py b/authentik_client/models/paginated_email_device_list.py new file mode 100644 index 000000000..2682c2c91 --- /dev/null +++ b/authentik_client/models/paginated_email_device_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.email_device import EmailDevice +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedEmailDeviceList(BaseModel): + """ + PaginatedEmailDeviceList + """ # noqa: E501 + pagination: Pagination + results: List[EmailDevice] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedEmailDeviceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedEmailDeviceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [EmailDevice.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_email_stage_list.py b/authentik_client/models/paginated_email_stage_list.py new file mode 100644 index 000000000..e0f65176d --- /dev/null +++ b/authentik_client/models/paginated_email_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.email_stage import EmailStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedEmailStageList(BaseModel): + """ + PaginatedEmailStageList + """ # noqa: E501 + pagination: Pagination + results: List[EmailStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedEmailStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedEmailStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [EmailStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_endpoint_device_list.py b/authentik_client/models/paginated_endpoint_device_list.py new file mode 100644 index 000000000..55a15d51c --- /dev/null +++ b/authentik_client/models/paginated_endpoint_device_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.endpoint_device import EndpointDevice +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedEndpointDeviceList(BaseModel): + """ + PaginatedEndpointDeviceList + """ # noqa: E501 + pagination: Pagination + results: List[EndpointDevice] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedEndpointDeviceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedEndpointDeviceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [EndpointDevice.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_endpoint_list.py b/authentik_client/models/paginated_endpoint_list.py new file mode 100644 index 000000000..f3398329d --- /dev/null +++ b/authentik_client/models/paginated_endpoint_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.endpoint import Endpoint +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedEndpointList(BaseModel): + """ + PaginatedEndpointList + """ # noqa: E501 + pagination: Pagination + results: List[Endpoint] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedEndpointList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedEndpointList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Endpoint.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_endpoint_stage_list.py b/authentik_client/models/paginated_endpoint_stage_list.py new file mode 100644 index 000000000..53735c827 --- /dev/null +++ b/authentik_client/models/paginated_endpoint_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.endpoint_stage import EndpointStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedEndpointStageList(BaseModel): + """ + PaginatedEndpointStageList + """ # noqa: E501 + pagination: Pagination + results: List[EndpointStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedEndpointStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedEndpointStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [EndpointStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_enrollment_token_list.py b/authentik_client/models/paginated_enrollment_token_list.py new file mode 100644 index 000000000..8469f6eee --- /dev/null +++ b/authentik_client/models/paginated_enrollment_token_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.enrollment_token import EnrollmentToken +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedEnrollmentTokenList(BaseModel): + """ + PaginatedEnrollmentTokenList + """ # noqa: E501 + pagination: Pagination + results: List[EnrollmentToken] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedEnrollmentTokenList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedEnrollmentTokenList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [EnrollmentToken.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_event_list.py b/authentik_client/models/paginated_event_list.py new file mode 100644 index 000000000..14254491a --- /dev/null +++ b/authentik_client/models/paginated_event_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.event import Event +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedEventList(BaseModel): + """ + PaginatedEventList + """ # noqa: E501 + pagination: Pagination + results: List[Event] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedEventList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedEventList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Event.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_event_matcher_policy_list.py b/authentik_client/models/paginated_event_matcher_policy_list.py new file mode 100644 index 000000000..7a71e0a1f --- /dev/null +++ b/authentik_client/models/paginated_event_matcher_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.event_matcher_policy import EventMatcherPolicy +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedEventMatcherPolicyList(BaseModel): + """ + PaginatedEventMatcherPolicyList + """ # noqa: E501 + pagination: Pagination + results: List[EventMatcherPolicy] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedEventMatcherPolicyList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedEventMatcherPolicyList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [EventMatcherPolicy.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_expiring_base_grant_model_list.py b/authentik_client/models/paginated_expiring_base_grant_model_list.py new file mode 100644 index 000000000..23f139e1e --- /dev/null +++ b/authentik_client/models/paginated_expiring_base_grant_model_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.expiring_base_grant_model import ExpiringBaseGrantModel +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedExpiringBaseGrantModelList(BaseModel): + """ + PaginatedExpiringBaseGrantModelList + """ # noqa: E501 + pagination: Pagination + results: List[ExpiringBaseGrantModel] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedExpiringBaseGrantModelList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedExpiringBaseGrantModelList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ExpiringBaseGrantModel.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_expression_policy_list.py b/authentik_client/models/paginated_expression_policy_list.py new file mode 100644 index 000000000..667f24613 --- /dev/null +++ b/authentik_client/models/paginated_expression_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.expression_policy import ExpressionPolicy +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedExpressionPolicyList(BaseModel): + """ + PaginatedExpressionPolicyList + """ # noqa: E501 + pagination: Pagination + results: List[ExpressionPolicy] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedExpressionPolicyList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedExpressionPolicyList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ExpressionPolicy.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_extra_role_object_permission_list.py b/authentik_client/models/paginated_extra_role_object_permission_list.py new file mode 100644 index 000000000..b48a78d4d --- /dev/null +++ b/authentik_client/models/paginated_extra_role_object_permission_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.extra_role_object_permission import ExtraRoleObjectPermission +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedExtraRoleObjectPermissionList(BaseModel): + """ + PaginatedExtraRoleObjectPermissionList + """ # noqa: E501 + pagination: Pagination + results: List[ExtraRoleObjectPermission] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedExtraRoleObjectPermissionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedExtraRoleObjectPermissionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ExtraRoleObjectPermission.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_fleet_connector_list.py b/authentik_client/models/paginated_fleet_connector_list.py new file mode 100644 index 000000000..c382ad278 --- /dev/null +++ b/authentik_client/models/paginated_fleet_connector_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.fleet_connector import FleetConnector +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedFleetConnectorList(BaseModel): + """ + PaginatedFleetConnectorList + """ # noqa: E501 + pagination: Pagination + results: List[FleetConnector] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedFleetConnectorList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedFleetConnectorList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [FleetConnector.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_flow_list.py b/authentik_client/models/paginated_flow_list.py new file mode 100644 index 000000000..983ea98d1 --- /dev/null +++ b/authentik_client/models/paginated_flow_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.flow import Flow +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedFlowList(BaseModel): + """ + PaginatedFlowList + """ # noqa: E501 + pagination: Pagination + results: List[Flow] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedFlowList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedFlowList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Flow.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_flow_stage_binding_list.py b/authentik_client/models/paginated_flow_stage_binding_list.py new file mode 100644 index 000000000..92dc55f2c --- /dev/null +++ b/authentik_client/models/paginated_flow_stage_binding_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.flow_stage_binding import FlowStageBinding +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedFlowStageBindingList(BaseModel): + """ + PaginatedFlowStageBindingList + """ # noqa: E501 + pagination: Pagination + results: List[FlowStageBinding] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedFlowStageBindingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedFlowStageBindingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [FlowStageBinding.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_geo_ip_policy_list.py b/authentik_client/models/paginated_geo_ip_policy_list.py new file mode 100644 index 000000000..00a7bad32 --- /dev/null +++ b/authentik_client/models/paginated_geo_ip_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.geo_ip_policy import GeoIPPolicy +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGeoIPPolicyList(BaseModel): + """ + PaginatedGeoIPPolicyList + """ # noqa: E501 + pagination: Pagination + results: List[GeoIPPolicy] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGeoIPPolicyList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGeoIPPolicyList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GeoIPPolicy.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_google_chrome_connector_list.py b/authentik_client/models/paginated_google_chrome_connector_list.py new file mode 100644 index 000000000..242e17401 --- /dev/null +++ b/authentik_client/models/paginated_google_chrome_connector_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.google_chrome_connector import GoogleChromeConnector +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGoogleChromeConnectorList(BaseModel): + """ + PaginatedGoogleChromeConnectorList + """ # noqa: E501 + pagination: Pagination + results: List[GoogleChromeConnector] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGoogleChromeConnectorList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGoogleChromeConnectorList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GoogleChromeConnector.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_google_endpoint_device_list.py b/authentik_client/models/paginated_google_endpoint_device_list.py new file mode 100644 index 000000000..74f3c15dd --- /dev/null +++ b/authentik_client/models/paginated_google_endpoint_device_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGoogleEndpointDeviceList(BaseModel): + """ + PaginatedGoogleEndpointDeviceList + """ # noqa: E501 + pagination: Pagination + results: List[GoogleEndpointDevice] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGoogleEndpointDeviceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGoogleEndpointDeviceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GoogleEndpointDevice.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_google_workspace_provider_group_list.py b/authentik_client/models/paginated_google_workspace_provider_group_list.py new file mode 100644 index 000000000..17605d03e --- /dev/null +++ b/authentik_client/models/paginated_google_workspace_provider_group_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.google_workspace_provider_group import GoogleWorkspaceProviderGroup +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGoogleWorkspaceProviderGroupList(BaseModel): + """ + PaginatedGoogleWorkspaceProviderGroupList + """ # noqa: E501 + pagination: Pagination + results: List[GoogleWorkspaceProviderGroup] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGoogleWorkspaceProviderGroupList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGoogleWorkspaceProviderGroupList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GoogleWorkspaceProviderGroup.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_google_workspace_provider_list.py b/authentik_client/models/paginated_google_workspace_provider_list.py new file mode 100644 index 000000000..eb6b78f80 --- /dev/null +++ b/authentik_client/models/paginated_google_workspace_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGoogleWorkspaceProviderList(BaseModel): + """ + PaginatedGoogleWorkspaceProviderList + """ # noqa: E501 + pagination: Pagination + results: List[GoogleWorkspaceProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGoogleWorkspaceProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGoogleWorkspaceProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GoogleWorkspaceProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_google_workspace_provider_mapping_list.py b/authentik_client/models/paginated_google_workspace_provider_mapping_list.py new file mode 100644 index 000000000..ccc7f0b1a --- /dev/null +++ b/authentik_client/models/paginated_google_workspace_provider_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGoogleWorkspaceProviderMappingList(BaseModel): + """ + PaginatedGoogleWorkspaceProviderMappingList + """ # noqa: E501 + pagination: Pagination + results: List[GoogleWorkspaceProviderMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGoogleWorkspaceProviderMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGoogleWorkspaceProviderMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GoogleWorkspaceProviderMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_google_workspace_provider_user_list.py b/authentik_client/models/paginated_google_workspace_provider_user_list.py new file mode 100644 index 000000000..6a8215eae --- /dev/null +++ b/authentik_client/models/paginated_google_workspace_provider_user_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.google_workspace_provider_user import GoogleWorkspaceProviderUser +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGoogleWorkspaceProviderUserList(BaseModel): + """ + PaginatedGoogleWorkspaceProviderUserList + """ # noqa: E501 + pagination: Pagination + results: List[GoogleWorkspaceProviderUser] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGoogleWorkspaceProviderUserList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGoogleWorkspaceProviderUserList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GoogleWorkspaceProviderUser.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_group_kerberos_source_connection_list.py b/authentik_client/models/paginated_group_kerberos_source_connection_list.py new file mode 100644 index 000000000..3a327f20a --- /dev/null +++ b/authentik_client/models/paginated_group_kerberos_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGroupKerberosSourceConnectionList(BaseModel): + """ + PaginatedGroupKerberosSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[GroupKerberosSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGroupKerberosSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGroupKerberosSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GroupKerberosSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_group_ldap_source_connection_list.py b/authentik_client/models/paginated_group_ldap_source_connection_list.py new file mode 100644 index 000000000..c6aac739c --- /dev/null +++ b/authentik_client/models/paginated_group_ldap_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGroupLDAPSourceConnectionList(BaseModel): + """ + PaginatedGroupLDAPSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[GroupLDAPSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGroupLDAPSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGroupLDAPSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GroupLDAPSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_group_list.py b/authentik_client/models/paginated_group_list.py new file mode 100644 index 000000000..6f3d13a4f --- /dev/null +++ b/authentik_client/models/paginated_group_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.group import Group +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGroupList(BaseModel): + """ + PaginatedGroupList + """ # noqa: E501 + pagination: Pagination + results: List[Group] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGroupList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGroupList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Group.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_group_o_auth_source_connection_list.py b/authentik_client/models/paginated_group_o_auth_source_connection_list.py new file mode 100644 index 000000000..6cf1ae44a --- /dev/null +++ b/authentik_client/models/paginated_group_o_auth_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGroupOAuthSourceConnectionList(BaseModel): + """ + PaginatedGroupOAuthSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[GroupOAuthSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGroupOAuthSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGroupOAuthSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GroupOAuthSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_group_plex_source_connection_list.py b/authentik_client/models/paginated_group_plex_source_connection_list.py new file mode 100644 index 000000000..f16be8ed3 --- /dev/null +++ b/authentik_client/models/paginated_group_plex_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGroupPlexSourceConnectionList(BaseModel): + """ + PaginatedGroupPlexSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[GroupPlexSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGroupPlexSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGroupPlexSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GroupPlexSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_group_saml_source_connection_list.py b/authentik_client/models/paginated_group_saml_source_connection_list.py new file mode 100644 index 000000000..1f8677b06 --- /dev/null +++ b/authentik_client/models/paginated_group_saml_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGroupSAMLSourceConnectionList(BaseModel): + """ + PaginatedGroupSAMLSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[GroupSAMLSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGroupSAMLSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGroupSAMLSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GroupSAMLSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_group_source_connection_list.py b/authentik_client/models/paginated_group_source_connection_list.py new file mode 100644 index 000000000..3169a90f7 --- /dev/null +++ b/authentik_client/models/paginated_group_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.group_source_connection import GroupSourceConnection +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGroupSourceConnectionList(BaseModel): + """ + PaginatedGroupSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[GroupSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGroupSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGroupSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GroupSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_group_telegram_source_connection_list.py b/authentik_client/models/paginated_group_telegram_source_connection_list.py new file mode 100644 index 000000000..1c40c24e9 --- /dev/null +++ b/authentik_client/models/paginated_group_telegram_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedGroupTelegramSourceConnectionList(BaseModel): + """ + PaginatedGroupTelegramSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[GroupTelegramSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedGroupTelegramSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedGroupTelegramSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [GroupTelegramSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_identification_stage_list.py b/authentik_client/models/paginated_identification_stage_list.py new file mode 100644 index 000000000..6f5e929d2 --- /dev/null +++ b/authentik_client/models/paginated_identification_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.identification_stage import IdentificationStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedIdentificationStageList(BaseModel): + """ + PaginatedIdentificationStageList + """ # noqa: E501 + pagination: Pagination + results: List[IdentificationStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedIdentificationStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedIdentificationStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [IdentificationStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_initial_permissions_list.py b/authentik_client/models/paginated_initial_permissions_list.py new file mode 100644 index 000000000..57642e59c --- /dev/null +++ b/authentik_client/models/paginated_initial_permissions_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.initial_permissions import InitialPermissions +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedInitialPermissionsList(BaseModel): + """ + PaginatedInitialPermissionsList + """ # noqa: E501 + pagination: Pagination + results: List[InitialPermissions] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedInitialPermissionsList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedInitialPermissionsList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [InitialPermissions.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_invitation_list.py b/authentik_client/models/paginated_invitation_list.py new file mode 100644 index 000000000..244930061 --- /dev/null +++ b/authentik_client/models/paginated_invitation_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.invitation import Invitation +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedInvitationList(BaseModel): + """ + PaginatedInvitationList + """ # noqa: E501 + pagination: Pagination + results: List[Invitation] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedInvitationList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedInvitationList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Invitation.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_invitation_stage_list.py b/authentik_client/models/paginated_invitation_stage_list.py new file mode 100644 index 000000000..67a68449b --- /dev/null +++ b/authentik_client/models/paginated_invitation_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.invitation_stage import InvitationStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedInvitationStageList(BaseModel): + """ + PaginatedInvitationStageList + """ # noqa: E501 + pagination: Pagination + results: List[InvitationStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedInvitationStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedInvitationStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [InvitationStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_kerberos_source_list.py b/authentik_client/models/paginated_kerberos_source_list.py new file mode 100644 index 000000000..f23849a22 --- /dev/null +++ b/authentik_client/models/paginated_kerberos_source_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.kerberos_source import KerberosSource +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedKerberosSourceList(BaseModel): + """ + PaginatedKerberosSourceList + """ # noqa: E501 + pagination: Pagination + results: List[KerberosSource] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedKerberosSourceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedKerberosSourceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [KerberosSource.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_kerberos_source_property_mapping_list.py b/authentik_client/models/paginated_kerberos_source_property_mapping_list.py new file mode 100644 index 000000000..8fa41c587 --- /dev/null +++ b/authentik_client/models/paginated_kerberos_source_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedKerberosSourcePropertyMappingList(BaseModel): + """ + PaginatedKerberosSourcePropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[KerberosSourcePropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedKerberosSourcePropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedKerberosSourcePropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [KerberosSourcePropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_kubernetes_service_connection_list.py b/authentik_client/models/paginated_kubernetes_service_connection_list.py new file mode 100644 index 000000000..5a4764b52 --- /dev/null +++ b/authentik_client/models/paginated_kubernetes_service_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedKubernetesServiceConnectionList(BaseModel): + """ + PaginatedKubernetesServiceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[KubernetesServiceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedKubernetesServiceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedKubernetesServiceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [KubernetesServiceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_ldap_outpost_config_list.py b/authentik_client/models/paginated_ldap_outpost_config_list.py new file mode 100644 index 000000000..b10811cfc --- /dev/null +++ b/authentik_client/models/paginated_ldap_outpost_config_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.ldap_outpost_config import LDAPOutpostConfig +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedLDAPOutpostConfigList(BaseModel): + """ + PaginatedLDAPOutpostConfigList + """ # noqa: E501 + pagination: Pagination + results: List[LDAPOutpostConfig] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedLDAPOutpostConfigList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedLDAPOutpostConfigList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [LDAPOutpostConfig.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_ldap_provider_list.py b/authentik_client/models/paginated_ldap_provider_list.py new file mode 100644 index 000000000..fd008439a --- /dev/null +++ b/authentik_client/models/paginated_ldap_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.ldap_provider import LDAPProvider +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedLDAPProviderList(BaseModel): + """ + PaginatedLDAPProviderList + """ # noqa: E501 + pagination: Pagination + results: List[LDAPProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedLDAPProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedLDAPProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [LDAPProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_ldap_source_list.py b/authentik_client/models/paginated_ldap_source_list.py new file mode 100644 index 000000000..6969e9da1 --- /dev/null +++ b/authentik_client/models/paginated_ldap_source_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.ldap_source import LDAPSource +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedLDAPSourceList(BaseModel): + """ + PaginatedLDAPSourceList + """ # noqa: E501 + pagination: Pagination + results: List[LDAPSource] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedLDAPSourceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedLDAPSourceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [LDAPSource.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_ldap_source_property_mapping_list.py b/authentik_client/models/paginated_ldap_source_property_mapping_list.py new file mode 100644 index 000000000..2b83e626a --- /dev/null +++ b/authentik_client/models/paginated_ldap_source_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedLDAPSourcePropertyMappingList(BaseModel): + """ + PaginatedLDAPSourcePropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[LDAPSourcePropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedLDAPSourcePropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedLDAPSourcePropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [LDAPSourcePropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_license_list.py b/authentik_client/models/paginated_license_list.py new file mode 100644 index 000000000..2162f90c9 --- /dev/null +++ b/authentik_client/models/paginated_license_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.license import License +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedLicenseList(BaseModel): + """ + PaginatedLicenseList + """ # noqa: E501 + pagination: Pagination + results: List[License] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedLicenseList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedLicenseList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [License.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_lifecycle_iteration_list.py b/authentik_client/models/paginated_lifecycle_iteration_list.py new file mode 100644 index 000000000..8cf212dc0 --- /dev/null +++ b/authentik_client/models/paginated_lifecycle_iteration_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.lifecycle_iteration import LifecycleIteration +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedLifecycleIterationList(BaseModel): + """ + PaginatedLifecycleIterationList + """ # noqa: E501 + pagination: Pagination + results: List[LifecycleIteration] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedLifecycleIterationList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedLifecycleIterationList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [LifecycleIteration.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_lifecycle_rule_list.py b/authentik_client/models/paginated_lifecycle_rule_list.py new file mode 100644 index 000000000..ee6f4834c --- /dev/null +++ b/authentik_client/models/paginated_lifecycle_rule_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.lifecycle_rule import LifecycleRule +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedLifecycleRuleList(BaseModel): + """ + PaginatedLifecycleRuleList + """ # noqa: E501 + pagination: Pagination + results: List[LifecycleRule] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedLifecycleRuleList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedLifecycleRuleList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [LifecycleRule.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_microsoft_entra_provider_group_list.py b/authentik_client/models/paginated_microsoft_entra_provider_group_list.py new file mode 100644 index 000000000..5aa043998 --- /dev/null +++ b/authentik_client/models/paginated_microsoft_entra_provider_group_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.microsoft_entra_provider_group import MicrosoftEntraProviderGroup +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedMicrosoftEntraProviderGroupList(BaseModel): + """ + PaginatedMicrosoftEntraProviderGroupList + """ # noqa: E501 + pagination: Pagination + results: List[MicrosoftEntraProviderGroup] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedMicrosoftEntraProviderGroupList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedMicrosoftEntraProviderGroupList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [MicrosoftEntraProviderGroup.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_microsoft_entra_provider_list.py b/authentik_client/models/paginated_microsoft_entra_provider_list.py new file mode 100644 index 000000000..09730cbc4 --- /dev/null +++ b/authentik_client/models/paginated_microsoft_entra_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedMicrosoftEntraProviderList(BaseModel): + """ + PaginatedMicrosoftEntraProviderList + """ # noqa: E501 + pagination: Pagination + results: List[MicrosoftEntraProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedMicrosoftEntraProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedMicrosoftEntraProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [MicrosoftEntraProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_microsoft_entra_provider_mapping_list.py b/authentik_client/models/paginated_microsoft_entra_provider_mapping_list.py new file mode 100644 index 000000000..c73f36497 --- /dev/null +++ b/authentik_client/models/paginated_microsoft_entra_provider_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedMicrosoftEntraProviderMappingList(BaseModel): + """ + PaginatedMicrosoftEntraProviderMappingList + """ # noqa: E501 + pagination: Pagination + results: List[MicrosoftEntraProviderMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedMicrosoftEntraProviderMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedMicrosoftEntraProviderMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [MicrosoftEntraProviderMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_microsoft_entra_provider_user_list.py b/authentik_client/models/paginated_microsoft_entra_provider_user_list.py new file mode 100644 index 000000000..9095b2208 --- /dev/null +++ b/authentik_client/models/paginated_microsoft_entra_provider_user_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.microsoft_entra_provider_user import MicrosoftEntraProviderUser +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedMicrosoftEntraProviderUserList(BaseModel): + """ + PaginatedMicrosoftEntraProviderUserList + """ # noqa: E501 + pagination: Pagination + results: List[MicrosoftEntraProviderUser] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedMicrosoftEntraProviderUserList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedMicrosoftEntraProviderUserList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [MicrosoftEntraProviderUser.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_mutual_tls_stage_list.py b/authentik_client/models/paginated_mutual_tls_stage_list.py new file mode 100644 index 000000000..1b45b7702 --- /dev/null +++ b/authentik_client/models/paginated_mutual_tls_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.mutual_tls_stage import MutualTLSStage +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedMutualTLSStageList(BaseModel): + """ + PaginatedMutualTLSStageList + """ # noqa: E501 + pagination: Pagination + results: List[MutualTLSStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedMutualTLSStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedMutualTLSStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [MutualTLSStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_notification_list.py b/authentik_client/models/paginated_notification_list.py new file mode 100644 index 000000000..157327bfe --- /dev/null +++ b/authentik_client/models/paginated_notification_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.notification import Notification +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedNotificationList(BaseModel): + """ + PaginatedNotificationList + """ # noqa: E501 + pagination: Pagination + results: List[Notification] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedNotificationList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedNotificationList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Notification.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_notification_rule_list.py b/authentik_client/models/paginated_notification_rule_list.py new file mode 100644 index 000000000..73ce5e963 --- /dev/null +++ b/authentik_client/models/paginated_notification_rule_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.notification_rule import NotificationRule +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedNotificationRuleList(BaseModel): + """ + PaginatedNotificationRuleList + """ # noqa: E501 + pagination: Pagination + results: List[NotificationRule] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedNotificationRuleList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedNotificationRuleList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [NotificationRule.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_notification_transport_list.py b/authentik_client/models/paginated_notification_transport_list.py new file mode 100644 index 000000000..c1b7dc71a --- /dev/null +++ b/authentik_client/models/paginated_notification_transport_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.notification_transport import NotificationTransport +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedNotificationTransportList(BaseModel): + """ + PaginatedNotificationTransportList + """ # noqa: E501 + pagination: Pagination + results: List[NotificationTransport] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedNotificationTransportList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedNotificationTransportList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [NotificationTransport.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_notification_webhook_mapping_list.py b/authentik_client/models/paginated_notification_webhook_mapping_list.py new file mode 100644 index 000000000..d7bac46a3 --- /dev/null +++ b/authentik_client/models/paginated_notification_webhook_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedNotificationWebhookMappingList(BaseModel): + """ + PaginatedNotificationWebhookMappingList + """ # noqa: E501 + pagination: Pagination + results: List[NotificationWebhookMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedNotificationWebhookMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedNotificationWebhookMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [NotificationWebhookMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_o_auth2_provider_list.py b/authentik_client/models/paginated_o_auth2_provider_list.py new file mode 100644 index 000000000..94e72ff02 --- /dev/null +++ b/authentik_client/models/paginated_o_auth2_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.o_auth2_provider import OAuth2Provider +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedOAuth2ProviderList(BaseModel): + """ + PaginatedOAuth2ProviderList + """ # noqa: E501 + pagination: Pagination + results: List[OAuth2Provider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedOAuth2ProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedOAuth2ProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [OAuth2Provider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_o_auth_source_list.py b/authentik_client/models/paginated_o_auth_source_list.py new file mode 100644 index 000000000..6c5dca3d7 --- /dev/null +++ b/authentik_client/models/paginated_o_auth_source_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.o_auth_source import OAuthSource +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedOAuthSourceList(BaseModel): + """ + PaginatedOAuthSourceList + """ # noqa: E501 + pagination: Pagination + results: List[OAuthSource] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedOAuthSourceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedOAuthSourceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [OAuthSource.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_o_auth_source_property_mapping_list.py b/authentik_client/models/paginated_o_auth_source_property_mapping_list.py new file mode 100644 index 000000000..b8d50d7b7 --- /dev/null +++ b/authentik_client/models/paginated_o_auth_source_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedOAuthSourcePropertyMappingList(BaseModel): + """ + PaginatedOAuthSourcePropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[OAuthSourcePropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedOAuthSourcePropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedOAuthSourcePropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [OAuthSourcePropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_outpost_list.py b/authentik_client/models/paginated_outpost_list.py new file mode 100644 index 000000000..0f9465f25 --- /dev/null +++ b/authentik_client/models/paginated_outpost_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.outpost import Outpost +from authentik_client.models.pagination import Pagination +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedOutpostList(BaseModel): + """ + PaginatedOutpostList + """ # noqa: E501 + pagination: Pagination + results: List[Outpost] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedOutpostList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedOutpostList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Outpost.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_password_expiry_policy_list.py b/authentik_client/models/paginated_password_expiry_policy_list.py new file mode 100644 index 000000000..a0d0f792b --- /dev/null +++ b/authentik_client/models/paginated_password_expiry_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPasswordExpiryPolicyList(BaseModel): + """ + PaginatedPasswordExpiryPolicyList + """ # noqa: E501 + pagination: Pagination + results: List[PasswordExpiryPolicy] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPasswordExpiryPolicyList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPasswordExpiryPolicyList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [PasswordExpiryPolicy.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_password_policy_list.py b/authentik_client/models/paginated_password_policy_list.py new file mode 100644 index 000000000..c922449db --- /dev/null +++ b/authentik_client/models/paginated_password_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.password_policy import PasswordPolicy +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPasswordPolicyList(BaseModel): + """ + PaginatedPasswordPolicyList + """ # noqa: E501 + pagination: Pagination + results: List[PasswordPolicy] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPasswordPolicyList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPasswordPolicyList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [PasswordPolicy.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_password_stage_list.py b/authentik_client/models/paginated_password_stage_list.py new file mode 100644 index 000000000..86511808c --- /dev/null +++ b/authentik_client/models/paginated_password_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.password_stage import PasswordStage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPasswordStageList(BaseModel): + """ + PaginatedPasswordStageList + """ # noqa: E501 + pagination: Pagination + results: List[PasswordStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPasswordStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPasswordStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [PasswordStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_permission_list.py b/authentik_client/models/paginated_permission_list.py new file mode 100644 index 000000000..35c37e84f --- /dev/null +++ b/authentik_client/models/paginated_permission_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.permission import Permission +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPermissionList(BaseModel): + """ + PaginatedPermissionList + """ # noqa: E501 + pagination: Pagination + results: List[Permission] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPermissionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPermissionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Permission.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_plex_source_list.py b/authentik_client/models/paginated_plex_source_list.py new file mode 100644 index 000000000..9887599f6 --- /dev/null +++ b/authentik_client/models/paginated_plex_source_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.plex_source import PlexSource +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPlexSourceList(BaseModel): + """ + PaginatedPlexSourceList + """ # noqa: E501 + pagination: Pagination + results: List[PlexSource] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPlexSourceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPlexSourceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [PlexSource.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_plex_source_property_mapping_list.py b/authentik_client/models/paginated_plex_source_property_mapping_list.py new file mode 100644 index 000000000..309794f62 --- /dev/null +++ b/authentik_client/models/paginated_plex_source_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPlexSourcePropertyMappingList(BaseModel): + """ + PaginatedPlexSourcePropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[PlexSourcePropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPlexSourcePropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPlexSourcePropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [PlexSourcePropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_policy_binding_list.py b/authentik_client/models/paginated_policy_binding_list.py new file mode 100644 index 000000000..42e131219 --- /dev/null +++ b/authentik_client/models/paginated_policy_binding_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.policy_binding import PolicyBinding +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPolicyBindingList(BaseModel): + """ + PaginatedPolicyBindingList + """ # noqa: E501 + pagination: Pagination + results: List[PolicyBinding] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPolicyBindingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPolicyBindingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [PolicyBinding.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_policy_list.py b/authentik_client/models/paginated_policy_list.py new file mode 100644 index 000000000..13a146134 --- /dev/null +++ b/authentik_client/models/paginated_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.policy import Policy +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPolicyList(BaseModel): + """ + PaginatedPolicyList + """ # noqa: E501 + pagination: Pagination + results: List[Policy] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPolicyList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPolicyList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Policy.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_prompt_list.py b/authentik_client/models/paginated_prompt_list.py new file mode 100644 index 000000000..360db8128 --- /dev/null +++ b/authentik_client/models/paginated_prompt_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.prompt import Prompt +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPromptList(BaseModel): + """ + PaginatedPromptList + """ # noqa: E501 + pagination: Pagination + results: List[Prompt] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPromptList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPromptList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Prompt.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_prompt_stage_list.py b/authentik_client/models/paginated_prompt_stage_list.py new file mode 100644 index 000000000..f42909177 --- /dev/null +++ b/authentik_client/models/paginated_prompt_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.prompt_stage import PromptStage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPromptStageList(BaseModel): + """ + PaginatedPromptStageList + """ # noqa: E501 + pagination: Pagination + results: List[PromptStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPromptStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPromptStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [PromptStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_property_mapping_list.py b/authentik_client/models/paginated_property_mapping_list.py new file mode 100644 index 000000000..6e422bafa --- /dev/null +++ b/authentik_client/models/paginated_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.property_mapping import PropertyMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedPropertyMappingList(BaseModel): + """ + PaginatedPropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[PropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedPropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedPropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [PropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_provider_list.py b/authentik_client/models/paginated_provider_list.py new file mode 100644 index 000000000..0227f967d --- /dev/null +++ b/authentik_client/models/paginated_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.provider import Provider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedProviderList(BaseModel): + """ + PaginatedProviderList + """ # noqa: E501 + pagination: Pagination + results: List[Provider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Provider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_proxy_outpost_config_list.py b/authentik_client/models/paginated_proxy_outpost_config_list.py new file mode 100644 index 000000000..904a1ce4b --- /dev/null +++ b/authentik_client/models/paginated_proxy_outpost_config_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.proxy_outpost_config import ProxyOutpostConfig +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedProxyOutpostConfigList(BaseModel): + """ + PaginatedProxyOutpostConfigList + """ # noqa: E501 + pagination: Pagination + results: List[ProxyOutpostConfig] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedProxyOutpostConfigList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedProxyOutpostConfigList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ProxyOutpostConfig.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_proxy_provider_list.py b/authentik_client/models/paginated_proxy_provider_list.py new file mode 100644 index 000000000..155d81e7a --- /dev/null +++ b/authentik_client/models/paginated_proxy_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.proxy_provider import ProxyProvider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedProxyProviderList(BaseModel): + """ + PaginatedProxyProviderList + """ # noqa: E501 + pagination: Pagination + results: List[ProxyProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedProxyProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedProxyProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ProxyProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_rac_property_mapping_list.py b/authentik_client/models/paginated_rac_property_mapping_list.py new file mode 100644 index 000000000..bd60fc30f --- /dev/null +++ b/authentik_client/models/paginated_rac_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.rac_property_mapping import RACPropertyMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedRACPropertyMappingList(BaseModel): + """ + PaginatedRACPropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[RACPropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedRACPropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedRACPropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [RACPropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_rac_provider_list.py b/authentik_client/models/paginated_rac_provider_list.py new file mode 100644 index 000000000..d8662c2b1 --- /dev/null +++ b/authentik_client/models/paginated_rac_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.rac_provider import RACProvider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedRACProviderList(BaseModel): + """ + PaginatedRACProviderList + """ # noqa: E501 + pagination: Pagination + results: List[RACProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedRACProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedRACProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [RACProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_radius_outpost_config_list.py b/authentik_client/models/paginated_radius_outpost_config_list.py new file mode 100644 index 000000000..4913f9d72 --- /dev/null +++ b/authentik_client/models/paginated_radius_outpost_config_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.radius_outpost_config import RadiusOutpostConfig +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedRadiusOutpostConfigList(BaseModel): + """ + PaginatedRadiusOutpostConfigList + """ # noqa: E501 + pagination: Pagination + results: List[RadiusOutpostConfig] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedRadiusOutpostConfigList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedRadiusOutpostConfigList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [RadiusOutpostConfig.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_radius_provider_list.py b/authentik_client/models/paginated_radius_provider_list.py new file mode 100644 index 000000000..fb3276a0a --- /dev/null +++ b/authentik_client/models/paginated_radius_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.radius_provider import RadiusProvider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedRadiusProviderList(BaseModel): + """ + PaginatedRadiusProviderList + """ # noqa: E501 + pagination: Pagination + results: List[RadiusProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedRadiusProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedRadiusProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [RadiusProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_radius_provider_property_mapping_list.py b/authentik_client/models/paginated_radius_provider_property_mapping_list.py new file mode 100644 index 000000000..8c2f386e0 --- /dev/null +++ b/authentik_client/models/paginated_radius_provider_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedRadiusProviderPropertyMappingList(BaseModel): + """ + PaginatedRadiusProviderPropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[RadiusProviderPropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedRadiusProviderPropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedRadiusProviderPropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [RadiusProviderPropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_redirect_stage_list.py b/authentik_client/models/paginated_redirect_stage_list.py new file mode 100644 index 000000000..39e343cd1 --- /dev/null +++ b/authentik_client/models/paginated_redirect_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.redirect_stage import RedirectStage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedRedirectStageList(BaseModel): + """ + PaginatedRedirectStageList + """ # noqa: E501 + pagination: Pagination + results: List[RedirectStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedRedirectStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedRedirectStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [RedirectStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_reputation_list.py b/authentik_client/models/paginated_reputation_list.py new file mode 100644 index 000000000..88276465b --- /dev/null +++ b/authentik_client/models/paginated_reputation_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.reputation import Reputation +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedReputationList(BaseModel): + """ + PaginatedReputationList + """ # noqa: E501 + pagination: Pagination + results: List[Reputation] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedReputationList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedReputationList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Reputation.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_reputation_policy_list.py b/authentik_client/models/paginated_reputation_policy_list.py new file mode 100644 index 000000000..8e01c6b44 --- /dev/null +++ b/authentik_client/models/paginated_reputation_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.reputation_policy import ReputationPolicy +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedReputationPolicyList(BaseModel): + """ + PaginatedReputationPolicyList + """ # noqa: E501 + pagination: Pagination + results: List[ReputationPolicy] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedReputationPolicyList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedReputationPolicyList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ReputationPolicy.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_role_assigned_object_permission_list.py b/authentik_client/models/paginated_role_assigned_object_permission_list.py new file mode 100644 index 000000000..5707de01b --- /dev/null +++ b/authentik_client/models/paginated_role_assigned_object_permission_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.role_assigned_object_permission import RoleAssignedObjectPermission +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedRoleAssignedObjectPermissionList(BaseModel): + """ + PaginatedRoleAssignedObjectPermissionList + """ # noqa: E501 + pagination: Pagination + results: List[RoleAssignedObjectPermission] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedRoleAssignedObjectPermissionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedRoleAssignedObjectPermissionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [RoleAssignedObjectPermission.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_role_list.py b/authentik_client/models/paginated_role_list.py new file mode 100644 index 000000000..ba8f953a5 --- /dev/null +++ b/authentik_client/models/paginated_role_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.role import Role +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedRoleList(BaseModel): + """ + PaginatedRoleList + """ # noqa: E501 + pagination: Pagination + results: List[Role] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedRoleList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedRoleList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Role.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_saml_property_mapping_list.py b/authentik_client/models/paginated_saml_property_mapping_list.py new file mode 100644 index 000000000..b80944a1f --- /dev/null +++ b/authentik_client/models/paginated_saml_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSAMLPropertyMappingList(BaseModel): + """ + PaginatedSAMLPropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[SAMLPropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSAMLPropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSAMLPropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SAMLPropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_saml_provider_list.py b/authentik_client/models/paginated_saml_provider_list.py new file mode 100644 index 000000000..ba807deb3 --- /dev/null +++ b/authentik_client/models/paginated_saml_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.saml_provider import SAMLProvider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSAMLProviderList(BaseModel): + """ + PaginatedSAMLProviderList + """ # noqa: E501 + pagination: Pagination + results: List[SAMLProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSAMLProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSAMLProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SAMLProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_saml_source_list.py b/authentik_client/models/paginated_saml_source_list.py new file mode 100644 index 000000000..17273a596 --- /dev/null +++ b/authentik_client/models/paginated_saml_source_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.saml_source import SAMLSource +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSAMLSourceList(BaseModel): + """ + PaginatedSAMLSourceList + """ # noqa: E501 + pagination: Pagination + results: List[SAMLSource] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSAMLSourceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSAMLSourceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SAMLSource.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_saml_source_property_mapping_list.py b/authentik_client/models/paginated_saml_source_property_mapping_list.py new file mode 100644 index 000000000..b64ef8cb5 --- /dev/null +++ b/authentik_client/models/paginated_saml_source_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSAMLSourcePropertyMappingList(BaseModel): + """ + PaginatedSAMLSourcePropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[SAMLSourcePropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSAMLSourcePropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSAMLSourcePropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SAMLSourcePropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_schedule_list.py b/authentik_client/models/paginated_schedule_list.py new file mode 100644 index 000000000..59a94154c --- /dev/null +++ b/authentik_client/models/paginated_schedule_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.schedule import Schedule +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedScheduleList(BaseModel): + """ + PaginatedScheduleList + """ # noqa: E501 + pagination: Pagination + results: List[Schedule] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedScheduleList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedScheduleList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Schedule.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_scim_mapping_list.py b/authentik_client/models/paginated_scim_mapping_list.py new file mode 100644 index 000000000..409d8c0f5 --- /dev/null +++ b/authentik_client/models/paginated_scim_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.scim_mapping import SCIMMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSCIMMappingList(BaseModel): + """ + PaginatedSCIMMappingList + """ # noqa: E501 + pagination: Pagination + results: List[SCIMMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSCIMMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSCIMMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SCIMMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_scim_provider_group_list.py b/authentik_client/models/paginated_scim_provider_group_list.py new file mode 100644 index 000000000..b255b0290 --- /dev/null +++ b/authentik_client/models/paginated_scim_provider_group_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.scim_provider_group import SCIMProviderGroup +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSCIMProviderGroupList(BaseModel): + """ + PaginatedSCIMProviderGroupList + """ # noqa: E501 + pagination: Pagination + results: List[SCIMProviderGroup] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSCIMProviderGroupList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSCIMProviderGroupList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SCIMProviderGroup.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_scim_provider_list.py b/authentik_client/models/paginated_scim_provider_list.py new file mode 100644 index 000000000..68e66788a --- /dev/null +++ b/authentik_client/models/paginated_scim_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.scim_provider import SCIMProvider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSCIMProviderList(BaseModel): + """ + PaginatedSCIMProviderList + """ # noqa: E501 + pagination: Pagination + results: List[SCIMProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSCIMProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSCIMProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SCIMProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_scim_provider_user_list.py b/authentik_client/models/paginated_scim_provider_user_list.py new file mode 100644 index 000000000..fdbfc0307 --- /dev/null +++ b/authentik_client/models/paginated_scim_provider_user_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.scim_provider_user import SCIMProviderUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSCIMProviderUserList(BaseModel): + """ + PaginatedSCIMProviderUserList + """ # noqa: E501 + pagination: Pagination + results: List[SCIMProviderUser] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSCIMProviderUserList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSCIMProviderUserList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SCIMProviderUser.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_scim_source_group_list.py b/authentik_client/models/paginated_scim_source_group_list.py new file mode 100644 index 000000000..bdf4bd786 --- /dev/null +++ b/authentik_client/models/paginated_scim_source_group_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.scim_source_group import SCIMSourceGroup +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSCIMSourceGroupList(BaseModel): + """ + PaginatedSCIMSourceGroupList + """ # noqa: E501 + pagination: Pagination + results: List[SCIMSourceGroup] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSCIMSourceGroupList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSCIMSourceGroupList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SCIMSourceGroup.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_scim_source_list.py b/authentik_client/models/paginated_scim_source_list.py new file mode 100644 index 000000000..0b9308dde --- /dev/null +++ b/authentik_client/models/paginated_scim_source_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.scim_source import SCIMSource +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSCIMSourceList(BaseModel): + """ + PaginatedSCIMSourceList + """ # noqa: E501 + pagination: Pagination + results: List[SCIMSource] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSCIMSourceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSCIMSourceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SCIMSource.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_scim_source_property_mapping_list.py b/authentik_client/models/paginated_scim_source_property_mapping_list.py new file mode 100644 index 000000000..cfdc62c33 --- /dev/null +++ b/authentik_client/models/paginated_scim_source_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSCIMSourcePropertyMappingList(BaseModel): + """ + PaginatedSCIMSourcePropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[SCIMSourcePropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSCIMSourcePropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSCIMSourcePropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SCIMSourcePropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_scim_source_user_list.py b/authentik_client/models/paginated_scim_source_user_list.py new file mode 100644 index 000000000..cb52564ba --- /dev/null +++ b/authentik_client/models/paginated_scim_source_user_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.scim_source_user import SCIMSourceUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSCIMSourceUserList(BaseModel): + """ + PaginatedSCIMSourceUserList + """ # noqa: E501 + pagination: Pagination + results: List[SCIMSourceUser] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSCIMSourceUserList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSCIMSourceUserList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SCIMSourceUser.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_scope_mapping_list.py b/authentik_client/models/paginated_scope_mapping_list.py new file mode 100644 index 000000000..e11e90354 --- /dev/null +++ b/authentik_client/models/paginated_scope_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.scope_mapping import ScopeMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedScopeMappingList(BaseModel): + """ + PaginatedScopeMappingList + """ # noqa: E501 + pagination: Pagination + results: List[ScopeMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedScopeMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedScopeMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ScopeMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_service_connection_list.py b/authentik_client/models/paginated_service_connection_list.py new file mode 100644 index 000000000..48753080a --- /dev/null +++ b/authentik_client/models/paginated_service_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.service_connection import ServiceConnection +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedServiceConnectionList(BaseModel): + """ + PaginatedServiceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[ServiceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedServiceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedServiceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [ServiceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_sms_device_list.py b/authentik_client/models/paginated_sms_device_list.py new file mode 100644 index 000000000..2dc3d16fb --- /dev/null +++ b/authentik_client/models/paginated_sms_device_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.sms_device import SMSDevice +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSMSDeviceList(BaseModel): + """ + PaginatedSMSDeviceList + """ # noqa: E501 + pagination: Pagination + results: List[SMSDevice] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSMSDeviceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSMSDeviceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SMSDevice.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_source_list.py b/authentik_client/models/paginated_source_list.py new file mode 100644 index 000000000..b2c69aa60 --- /dev/null +++ b/authentik_client/models/paginated_source_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSourceList(BaseModel): + """ + PaginatedSourceList + """ # noqa: E501 + pagination: Pagination + results: List[Source] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSourceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSourceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Source.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_source_stage_list.py b/authentik_client/models/paginated_source_stage_list.py new file mode 100644 index 000000000..b2d4c3780 --- /dev/null +++ b/authentik_client/models/paginated_source_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.source_stage import SourceStage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSourceStageList(BaseModel): + """ + PaginatedSourceStageList + """ # noqa: E501 + pagination: Pagination + results: List[SourceStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSourceStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSourceStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SourceStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_ssf_provider_list.py b/authentik_client/models/paginated_ssf_provider_list.py new file mode 100644 index 000000000..e909bcfdf --- /dev/null +++ b/authentik_client/models/paginated_ssf_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.ssf_provider import SSFProvider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSSFProviderList(BaseModel): + """ + PaginatedSSFProviderList + """ # noqa: E501 + pagination: Pagination + results: List[SSFProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSSFProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSSFProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SSFProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_ssf_stream_list.py b/authentik_client/models/paginated_ssf_stream_list.py new file mode 100644 index 000000000..d53d6fa75 --- /dev/null +++ b/authentik_client/models/paginated_ssf_stream_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.ssf_stream import SSFStream +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedSSFStreamList(BaseModel): + """ + PaginatedSSFStreamList + """ # noqa: E501 + pagination: Pagination + results: List[SSFStream] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedSSFStreamList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedSSFStreamList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [SSFStream.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_stage_list.py b/authentik_client/models/paginated_stage_list.py new file mode 100644 index 000000000..b01e0885d --- /dev/null +++ b/authentik_client/models/paginated_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.stage import Stage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedStageList(BaseModel): + """ + PaginatedStageList + """ # noqa: E501 + pagination: Pagination + results: List[Stage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Stage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_static_device_list.py b/authentik_client/models/paginated_static_device_list.py new file mode 100644 index 000000000..9049c74d8 --- /dev/null +++ b/authentik_client/models/paginated_static_device_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.static_device import StaticDevice +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedStaticDeviceList(BaseModel): + """ + PaginatedStaticDeviceList + """ # noqa: E501 + pagination: Pagination + results: List[StaticDevice] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedStaticDeviceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedStaticDeviceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [StaticDevice.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_task_list.py b/authentik_client/models/paginated_task_list.py new file mode 100644 index 000000000..d0dbf258b --- /dev/null +++ b/authentik_client/models/paginated_task_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.task import Task +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedTaskList(BaseModel): + """ + PaginatedTaskList + """ # noqa: E501 + pagination: Pagination + results: List[Task] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedTaskList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedTaskList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Task.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_telegram_source_list.py b/authentik_client/models/paginated_telegram_source_list.py new file mode 100644 index 000000000..55081c96e --- /dev/null +++ b/authentik_client/models/paginated_telegram_source_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.telegram_source import TelegramSource +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedTelegramSourceList(BaseModel): + """ + PaginatedTelegramSourceList + """ # noqa: E501 + pagination: Pagination + results: List[TelegramSource] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedTelegramSourceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedTelegramSourceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [TelegramSource.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_telegram_source_property_mapping_list.py b/authentik_client/models/paginated_telegram_source_property_mapping_list.py new file mode 100644 index 000000000..fbf4cc69c --- /dev/null +++ b/authentik_client/models/paginated_telegram_source_property_mapping_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedTelegramSourcePropertyMappingList(BaseModel): + """ + PaginatedTelegramSourcePropertyMappingList + """ # noqa: E501 + pagination: Pagination + results: List[TelegramSourcePropertyMapping] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedTelegramSourcePropertyMappingList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedTelegramSourcePropertyMappingList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [TelegramSourcePropertyMapping.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_tenant_list.py b/authentik_client/models/paginated_tenant_list.py new file mode 100644 index 000000000..26c7b423e --- /dev/null +++ b/authentik_client/models/paginated_tenant_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.tenant import Tenant +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedTenantList(BaseModel): + """ + PaginatedTenantList + """ # noqa: E501 + pagination: Pagination + results: List[Tenant] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedTenantList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedTenantList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Tenant.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_token_list.py b/authentik_client/models/paginated_token_list.py new file mode 100644 index 000000000..260a3b426 --- /dev/null +++ b/authentik_client/models/paginated_token_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.token import Token +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedTokenList(BaseModel): + """ + PaginatedTokenList + """ # noqa: E501 + pagination: Pagination + results: List[Token] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedTokenList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedTokenList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [Token.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_token_model_list.py b/authentik_client/models/paginated_token_model_list.py new file mode 100644 index 000000000..ed06c1b4f --- /dev/null +++ b/authentik_client/models/paginated_token_model_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.token_model import TokenModel +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedTokenModelList(BaseModel): + """ + PaginatedTokenModelList + """ # noqa: E501 + pagination: Pagination + results: List[TokenModel] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedTokenModelList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedTokenModelList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [TokenModel.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_totp_device_list.py b/authentik_client/models/paginated_totp_device_list.py new file mode 100644 index 000000000..f51704e93 --- /dev/null +++ b/authentik_client/models/paginated_totp_device_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.totp_device import TOTPDevice +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedTOTPDeviceList(BaseModel): + """ + PaginatedTOTPDeviceList + """ # noqa: E501 + pagination: Pagination + results: List[TOTPDevice] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedTOTPDeviceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedTOTPDeviceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [TOTPDevice.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_unique_password_policy_list.py b/authentik_client/models/paginated_unique_password_policy_list.py new file mode 100644 index 000000000..7174f22a9 --- /dev/null +++ b/authentik_client/models/paginated_unique_password_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.unique_password_policy import UniquePasswordPolicy +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUniquePasswordPolicyList(BaseModel): + """ + PaginatedUniquePasswordPolicyList + """ # noqa: E501 + pagination: Pagination + results: List[UniquePasswordPolicy] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUniquePasswordPolicyList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUniquePasswordPolicyList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UniquePasswordPolicy.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_consent_list.py b/authentik_client/models/paginated_user_consent_list.py new file mode 100644 index 000000000..73b113070 --- /dev/null +++ b/authentik_client/models/paginated_user_consent_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_consent import UserConsent +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserConsentList(BaseModel): + """ + PaginatedUserConsentList + """ # noqa: E501 + pagination: Pagination + results: List[UserConsent] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserConsentList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserConsentList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserConsent.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_delete_stage_list.py b/authentik_client/models/paginated_user_delete_stage_list.py new file mode 100644 index 000000000..8c91f66c4 --- /dev/null +++ b/authentik_client/models/paginated_user_delete_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_delete_stage import UserDeleteStage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserDeleteStageList(BaseModel): + """ + PaginatedUserDeleteStageList + """ # noqa: E501 + pagination: Pagination + results: List[UserDeleteStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserDeleteStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserDeleteStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserDeleteStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_kerberos_source_connection_list.py b/authentik_client/models/paginated_user_kerberos_source_connection_list.py new file mode 100644 index 000000000..8e11525c1 --- /dev/null +++ b/authentik_client/models/paginated_user_kerberos_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserKerberosSourceConnectionList(BaseModel): + """ + PaginatedUserKerberosSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[UserKerberosSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserKerberosSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserKerberosSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserKerberosSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_ldap_source_connection_list.py b/authentik_client/models/paginated_user_ldap_source_connection_list.py new file mode 100644 index 000000000..10fb7c62a --- /dev/null +++ b/authentik_client/models/paginated_user_ldap_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserLDAPSourceConnectionList(BaseModel): + """ + PaginatedUserLDAPSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[UserLDAPSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserLDAPSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserLDAPSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserLDAPSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_list.py b/authentik_client/models/paginated_user_list.py new file mode 100644 index 000000000..960421e1c --- /dev/null +++ b/authentik_client/models/paginated_user_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user import User +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserList(BaseModel): + """ + PaginatedUserList + """ # noqa: E501 + pagination: Pagination + results: List[User] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [User.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_login_stage_list.py b/authentik_client/models/paginated_user_login_stage_list.py new file mode 100644 index 000000000..0cf6dbfc6 --- /dev/null +++ b/authentik_client/models/paginated_user_login_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_login_stage import UserLoginStage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserLoginStageList(BaseModel): + """ + PaginatedUserLoginStageList + """ # noqa: E501 + pagination: Pagination + results: List[UserLoginStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserLoginStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserLoginStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserLoginStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_logout_stage_list.py b/authentik_client/models/paginated_user_logout_stage_list.py new file mode 100644 index 000000000..daaf9690d --- /dev/null +++ b/authentik_client/models/paginated_user_logout_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_logout_stage import UserLogoutStage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserLogoutStageList(BaseModel): + """ + PaginatedUserLogoutStageList + """ # noqa: E501 + pagination: Pagination + results: List[UserLogoutStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserLogoutStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserLogoutStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserLogoutStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_o_auth_source_connection_list.py b/authentik_client/models/paginated_user_o_auth_source_connection_list.py new file mode 100644 index 000000000..dea9fefd0 --- /dev/null +++ b/authentik_client/models/paginated_user_o_auth_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserOAuthSourceConnectionList(BaseModel): + """ + PaginatedUserOAuthSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[UserOAuthSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserOAuthSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserOAuthSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserOAuthSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_plex_source_connection_list.py b/authentik_client/models/paginated_user_plex_source_connection_list.py new file mode 100644 index 000000000..35916a81e --- /dev/null +++ b/authentik_client/models/paginated_user_plex_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserPlexSourceConnectionList(BaseModel): + """ + PaginatedUserPlexSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[UserPlexSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserPlexSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserPlexSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserPlexSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_saml_source_connection_list.py b/authentik_client/models/paginated_user_saml_source_connection_list.py new file mode 100644 index 000000000..64dfc2ff6 --- /dev/null +++ b/authentik_client/models/paginated_user_saml_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserSAMLSourceConnectionList(BaseModel): + """ + PaginatedUserSAMLSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[UserSAMLSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserSAMLSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserSAMLSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserSAMLSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_source_connection_list.py b/authentik_client/models/paginated_user_source_connection_list.py new file mode 100644 index 000000000..c4210653a --- /dev/null +++ b/authentik_client/models/paginated_user_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_source_connection import UserSourceConnection +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserSourceConnectionList(BaseModel): + """ + PaginatedUserSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[UserSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_telegram_source_connection_list.py b/authentik_client/models/paginated_user_telegram_source_connection_list.py new file mode 100644 index 000000000..d41eaafb1 --- /dev/null +++ b/authentik_client/models/paginated_user_telegram_source_connection_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserTelegramSourceConnectionList(BaseModel): + """ + PaginatedUserTelegramSourceConnectionList + """ # noqa: E501 + pagination: Pagination + results: List[UserTelegramSourceConnection] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserTelegramSourceConnectionList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserTelegramSourceConnectionList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserTelegramSourceConnection.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_user_write_stage_list.py b/authentik_client/models/paginated_user_write_stage_list.py new file mode 100644 index 000000000..0192f4418 --- /dev/null +++ b/authentik_client/models/paginated_user_write_stage_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.user_write_stage import UserWriteStage +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedUserWriteStageList(BaseModel): + """ + PaginatedUserWriteStageList + """ # noqa: E501 + pagination: Pagination + results: List[UserWriteStage] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedUserWriteStageList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedUserWriteStageList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [UserWriteStage.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_web_authn_device_list.py b/authentik_client/models/paginated_web_authn_device_list.py new file mode 100644 index 000000000..1f522f0c4 --- /dev/null +++ b/authentik_client/models/paginated_web_authn_device_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.web_authn_device import WebAuthnDevice +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedWebAuthnDeviceList(BaseModel): + """ + PaginatedWebAuthnDeviceList + """ # noqa: E501 + pagination: Pagination + results: List[WebAuthnDevice] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedWebAuthnDeviceList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedWebAuthnDeviceList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [WebAuthnDevice.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_web_authn_device_type_list.py b/authentik_client/models/paginated_web_authn_device_type_list.py new file mode 100644 index 000000000..8540dc4b9 --- /dev/null +++ b/authentik_client/models/paginated_web_authn_device_type_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedWebAuthnDeviceTypeList(BaseModel): + """ + PaginatedWebAuthnDeviceTypeList + """ # noqa: E501 + pagination: Pagination + results: List[WebAuthnDeviceType] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedWebAuthnDeviceTypeList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedWebAuthnDeviceTypeList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [WebAuthnDeviceType.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/paginated_ws_federation_provider_list.py b/authentik_client/models/paginated_ws_federation_provider_list.py new file mode 100644 index 000000000..ba4732dae --- /dev/null +++ b/authentik_client/models/paginated_ws_federation_provider_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.pagination import Pagination +from authentik_client.models.ws_federation_provider import WSFederationProvider +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PaginatedWSFederationProviderList(BaseModel): + """ + PaginatedWSFederationProviderList + """ # noqa: E501 + pagination: Pagination + results: List[WSFederationProvider] + autocomplete: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pagination", "results", "autocomplete"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PaginatedWSFederationProviderList from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of pagination + if self.pagination: + _dict['pagination'] = self.pagination.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in results (list) + _items = [] + if self.results: + for _item_results in self.results: + if _item_results: + _items.append(_item_results.to_dict()) + _dict['results'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PaginatedWSFederationProviderList from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pagination": Pagination.from_dict(obj["pagination"]) if obj.get("pagination") is not None else None, + "results": [WSFederationProvider.from_dict(_item) for _item in obj["results"]] if obj.get("results") is not None else None, + "autocomplete": obj.get("autocomplete") + }) + return _obj + + diff --git a/authentik_client/models/pagination.py b/authentik_client/models/pagination.py new file mode 100644 index 000000000..fdef77add --- /dev/null +++ b/authentik_client/models/pagination.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictFloat, StrictInt +from typing import Any, ClassVar, Dict, List, Union +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Pagination(BaseModel): + """ + Pagination + """ # noqa: E501 + next: Union[StrictFloat, StrictInt] + previous: Union[StrictFloat, StrictInt] + count: Union[StrictFloat, StrictInt] + current: Union[StrictFloat, StrictInt] + total_pages: Union[StrictFloat, StrictInt] + start_index: Union[StrictFloat, StrictInt] + end_index: Union[StrictFloat, StrictInt] + __properties: ClassVar[List[str]] = ["next", "previous", "count", "current", "total_pages", "start_index", "end_index"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Pagination from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Pagination from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "next": obj.get("next"), + "previous": obj.get("previous"), + "count": obj.get("count"), + "current": obj.get("current"), + "total_pages": obj.get("total_pages"), + "start_index": obj.get("start_index"), + "end_index": obj.get("end_index") + }) + return _obj + + diff --git a/authentik_client/models/partial_group.py b/authentik_client/models/partial_group.py new file mode 100644 index 000000000..1be0d0aba --- /dev/null +++ b/authentik_client/models/partial_group.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PartialGroup(BaseModel): + """ + Partial Group Serializer, does not include child relations. + """ # noqa: E501 + pk: UUID + num_pk: StrictInt = Field(description="Get a numerical, int32 ID for the group") + name: StrictStr + is_superuser: Optional[StrictBool] = Field(default=None, description="Users added to this group will be superusers.") + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["pk", "num_pk", "name", "is_superuser", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PartialGroup from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "num_pk", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PartialGroup from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "num_pk": obj.get("num_pk"), + "name": obj.get("name"), + "is_superuser": obj.get("is_superuser"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/partial_user.py b/authentik_client/models/partial_user.py new file mode 100644 index 000000000..b02d5bf5a --- /dev/null +++ b/authentik_client/models/partial_user.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PartialUser(BaseModel): + """ + Partial User Serializer, does not include child relations. + """ # noqa: E501 + pk: StrictInt + username: Annotated[str, Field(strict=True, max_length=150)] = Field(description="Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.") + name: StrictStr = Field(description="User's display name.") + is_active: Optional[StrictBool] = Field(default=None, description="Designates whether this user should be treated as active. Unselect this instead of deleting accounts.") + last_login: Optional[datetime] = None + email: Optional[Annotated[str, Field(strict=True, max_length=254)]] = None + attributes: Optional[Dict[str, Any]] = None + uid: StrictStr + __properties: ClassVar[List[str]] = ["pk", "username", "name", "is_active", "last_login", "email", "attributes", "uid"] + + @field_validator('username') + def username_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[\w.@+-]+$", value): + raise ValueError(r"must validate the regular expression /^[\w.@+-]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PartialUser from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "uid", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if last_login (nullable) is None + # and model_fields_set contains the field + if self.last_login is None and "last_login" in self.model_fields_set: + _dict['last_login'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PartialUser from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "username": obj.get("username"), + "name": obj.get("name"), + "is_active": obj.get("is_active"), + "last_login": obj.get("last_login"), + "email": obj.get("email"), + "attributes": obj.get("attributes"), + "uid": obj.get("uid") + }) + return _obj + + diff --git a/authentik_client/models/password_challenge.py b/authentik_client/models/password_challenge.py new file mode 100644 index 000000000..fb2a5e92e --- /dev/null +++ b/authentik_client/models/password_challenge.py @@ -0,0 +1,120 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PasswordChallenge(BaseModel): + """ + Password challenge UI fields + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-password' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + recovery_url: Optional[StrictStr] = None + allow_show_password: Optional[StrictBool] = False + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "recovery_url", "allow_show_password"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PasswordChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-password', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "recovery_url": obj.get("recovery_url"), + "allow_show_password": obj.get("allow_show_password") if obj.get("allow_show_password") is not None else False + }) + return _obj + + diff --git a/authentik_client/models/password_challenge_response_request.py b/authentik_client/models/password_challenge_response_request.py new file mode 100644 index 000000000..00c244820 --- /dev/null +++ b/authentik_client/models/password_challenge_response_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PasswordChallengeResponseRequest(BaseModel): + """ + Password challenge response + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-password' + password: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["component", "password"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PasswordChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-password', + "password": obj.get("password") + }) + return _obj + + diff --git a/authentik_client/models/password_expiry_policy.py b/authentik_client/models/password_expiry_policy.py new file mode 100644 index 000000000..4c4586141 --- /dev/null +++ b/authentik_client/models/password_expiry_policy.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PasswordExpiryPolicy(BaseModel): + """ + Password Expiry Policy Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + bound_to: StrictInt = Field(description="Return objects policy is bound to") + days: Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)] + deny_only: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["pk", "name", "execution_logging", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "bound_to", "days", "deny_only"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordExpiryPolicy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "bound_to", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PasswordExpiryPolicy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "bound_to": obj.get("bound_to"), + "days": obj.get("days"), + "deny_only": obj.get("deny_only") + }) + return _obj + + diff --git a/authentik_client/models/password_expiry_policy_request.py b/authentik_client/models/password_expiry_policy_request.py new file mode 100644 index 000000000..601db82ae --- /dev/null +++ b/authentik_client/models/password_expiry_policy_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PasswordExpiryPolicyRequest(BaseModel): + """ + Password Expiry Policy Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + days: Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)] + deny_only: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "days", "deny_only"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordExpiryPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PasswordExpiryPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "days": obj.get("days"), + "deny_only": obj.get("deny_only") + }) + return _obj + + diff --git a/authentik_client/models/password_policy.py b/authentik_client/models/password_policy.py new file mode 100644 index 000000000..43917ba23 --- /dev/null +++ b/authentik_client/models/password_policy.py @@ -0,0 +1,143 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PasswordPolicy(BaseModel): + """ + Password Policy Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + bound_to: StrictInt = Field(description="Return objects policy is bound to") + password_field: Optional[StrictStr] = Field(default=None, description="Field key to check, field keys defined in Prompt stages are available.") + amount_digits: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + amount_uppercase: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + amount_lowercase: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + amount_symbols: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + length_min: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + symbol_charset: Optional[StrictStr] = None + error_message: Optional[StrictStr] = None + check_static_rules: Optional[StrictBool] = None + check_have_i_been_pwned: Optional[StrictBool] = None + check_zxcvbn: Optional[StrictBool] = None + hibp_allowed_count: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="How many times the password hash is allowed to be on haveibeenpwned") + zxcvbn_score_threshold: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="If the zxcvbn score is equal or less than this value, the policy will fail.") + __properties: ClassVar[List[str]] = ["pk", "name", "execution_logging", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "bound_to", "password_field", "amount_digits", "amount_uppercase", "amount_lowercase", "amount_symbols", "length_min", "symbol_charset", "error_message", "check_static_rules", "check_have_i_been_pwned", "check_zxcvbn", "hibp_allowed_count", "zxcvbn_score_threshold"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordPolicy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "bound_to", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PasswordPolicy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "bound_to": obj.get("bound_to"), + "password_field": obj.get("password_field"), + "amount_digits": obj.get("amount_digits"), + "amount_uppercase": obj.get("amount_uppercase"), + "amount_lowercase": obj.get("amount_lowercase"), + "amount_symbols": obj.get("amount_symbols"), + "length_min": obj.get("length_min"), + "symbol_charset": obj.get("symbol_charset"), + "error_message": obj.get("error_message"), + "check_static_rules": obj.get("check_static_rules"), + "check_have_i_been_pwned": obj.get("check_have_i_been_pwned"), + "check_zxcvbn": obj.get("check_zxcvbn"), + "hibp_allowed_count": obj.get("hibp_allowed_count"), + "zxcvbn_score_threshold": obj.get("zxcvbn_score_threshold") + }) + return _obj + + diff --git a/authentik_client/models/password_policy_request.py b/authentik_client/models/password_policy_request.py new file mode 100644 index 000000000..110afa381 --- /dev/null +++ b/authentik_client/models/password_policy_request.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PasswordPolicyRequest(BaseModel): + """ + Password Policy Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + password_field: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Field key to check, field keys defined in Prompt stages are available.") + amount_digits: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + amount_uppercase: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + amount_lowercase: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + amount_symbols: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + length_min: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + symbol_charset: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + error_message: Optional[StrictStr] = None + check_static_rules: Optional[StrictBool] = None + check_have_i_been_pwned: Optional[StrictBool] = None + check_zxcvbn: Optional[StrictBool] = None + hibp_allowed_count: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="How many times the password hash is allowed to be on haveibeenpwned") + zxcvbn_score_threshold: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="If the zxcvbn score is equal or less than this value, the policy will fail.") + __properties: ClassVar[List[str]] = ["name", "execution_logging", "password_field", "amount_digits", "amount_uppercase", "amount_lowercase", "amount_symbols", "length_min", "symbol_charset", "error_message", "check_static_rules", "check_have_i_been_pwned", "check_zxcvbn", "hibp_allowed_count", "zxcvbn_score_threshold"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PasswordPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "password_field": obj.get("password_field"), + "amount_digits": obj.get("amount_digits"), + "amount_uppercase": obj.get("amount_uppercase"), + "amount_lowercase": obj.get("amount_lowercase"), + "amount_symbols": obj.get("amount_symbols"), + "length_min": obj.get("length_min"), + "symbol_charset": obj.get("symbol_charset"), + "error_message": obj.get("error_message"), + "check_static_rules": obj.get("check_static_rules"), + "check_have_i_been_pwned": obj.get("check_have_i_been_pwned"), + "check_zxcvbn": obj.get("check_zxcvbn"), + "hibp_allowed_count": obj.get("hibp_allowed_count"), + "zxcvbn_score_threshold": obj.get("zxcvbn_score_threshold") + }) + return _obj + + diff --git a/authentik_client/models/password_stage.py b/authentik_client/models/password_stage.py new file mode 100644 index 000000000..20a7e0790 --- /dev/null +++ b/authentik_client/models/password_stage.py @@ -0,0 +1,137 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.backends_enum import BackendsEnum +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PasswordStage(BaseModel): + """ + PasswordStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + backends: List[BackendsEnum] = Field(description="Selection of backends to test the password against.") + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + failed_attempts_before_cancel: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="How many attempts a user has before the flow is canceled. To lock the user out, use a reputation policy and a user_write stage.") + allow_show_password: Optional[StrictBool] = Field(default=None, description="When enabled, provides a 'show password' button with the password input field.") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "backends", "configure_flow", "failed_attempts_before_cancel", "allow_show_password"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PasswordStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "backends": obj.get("backends"), + "configure_flow": obj.get("configure_flow"), + "failed_attempts_before_cancel": obj.get("failed_attempts_before_cancel"), + "allow_show_password": obj.get("allow_show_password") + }) + return _obj + + diff --git a/authentik_client/models/password_stage_request.py b/authentik_client/models/password_stage_request.py new file mode 100644 index 000000000..aaa5fb9f4 --- /dev/null +++ b/authentik_client/models/password_stage_request.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.backends_enum import BackendsEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PasswordStageRequest(BaseModel): + """ + PasswordStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + backends: List[BackendsEnum] = Field(description="Selection of backends to test the password against.") + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + failed_attempts_before_cancel: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="How many attempts a user has before the flow is canceled. To lock the user out, use a reputation policy and a user_write stage.") + allow_show_password: Optional[StrictBool] = Field(default=None, description="When enabled, provides a 'show password' button with the password input field.") + __properties: ClassVar[List[str]] = ["name", "backends", "configure_flow", "failed_attempts_before_cancel", "allow_show_password"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PasswordStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PasswordStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "backends": obj.get("backends"), + "configure_flow": obj.get("configure_flow"), + "failed_attempts_before_cancel": obj.get("failed_attempts_before_cancel"), + "allow_show_password": obj.get("allow_show_password") + }) + return _obj + + diff --git a/authentik_client/models/patched_account_lockdown_stage_request.py b/authentik_client/models/patched_account_lockdown_stage_request.py new file mode 100644 index 000000000..cc1c02d18 --- /dev/null +++ b/authentik_client/models/patched_account_lockdown_stage_request.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAccountLockdownStageRequest(BaseModel): + """ + AccountLockdownStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + deactivate_user: Optional[StrictBool] = Field(default=None, description="Deactivate the user account (set is_active to False)") + set_unusable_password: Optional[StrictBool] = Field(default=None, description="Set an unusable password for the user") + delete_sessions: Optional[StrictBool] = Field(default=None, description="Delete all active sessions for the user") + revoke_tokens: Optional[StrictBool] = Field(default=None, description="Revoke all tokens for the user (API, app password, recovery, verification, OAuth)") + self_service_completion_flow: Optional[UUID] = Field(default=None, description="Flow to redirect users to after self-service lockdown. This flow should not require authentication since the user's session is deleted.") + __properties: ClassVar[List[str]] = ["name", "deactivate_user", "set_unusable_password", "delete_sessions", "revoke_tokens", "self_service_completion_flow"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAccountLockdownStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if self_service_completion_flow (nullable) is None + # and model_fields_set contains the field + if self.self_service_completion_flow is None and "self_service_completion_flow" in self.model_fields_set: + _dict['self_service_completion_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAccountLockdownStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "deactivate_user": obj.get("deactivate_user"), + "set_unusable_password": obj.get("set_unusable_password"), + "delete_sessions": obj.get("delete_sessions"), + "revoke_tokens": obj.get("revoke_tokens"), + "self_service_completion_flow": obj.get("self_service_completion_flow") + }) + return _obj + + diff --git a/authentik_client/models/patched_agent_connector_request.py b/authentik_client/models/patched_agent_connector_request.py new file mode 100644 index 000000000..3469cca88 --- /dev/null +++ b/authentik_client/models/patched_agent_connector_request.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAgentConnectorRequest(BaseModel): + """ + PatchedAgentConnectorRequest + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + enabled: Optional[StrictBool] = None + snapshot_expiry: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + auth_session_duration: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + auth_terminate_session_on_expiry: Optional[StrictBool] = None + refresh_interval: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + authorization_flow: Optional[UUID] = None + nss_uid_offset: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + nss_gid_offset: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + challenge_key: Optional[UUID] = None + challenge_idle_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + challenge_trigger_check_in: Optional[StrictBool] = None + jwt_federation_providers: Optional[List[StrictInt]] = None + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "snapshot_expiry", "auth_session_duration", "auth_terminate_session_on_expiry", "refresh_interval", "authorization_flow", "nss_uid_offset", "nss_gid_offset", "challenge_key", "challenge_idle_timeout", "challenge_trigger_check_in", "jwt_federation_providers"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAgentConnectorRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authorization_flow (nullable) is None + # and model_fields_set contains the field + if self.authorization_flow is None and "authorization_flow" in self.model_fields_set: + _dict['authorization_flow'] = None + + # set to None if challenge_key (nullable) is None + # and model_fields_set contains the field + if self.challenge_key is None and "challenge_key" in self.model_fields_set: + _dict['challenge_key'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAgentConnectorRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "snapshot_expiry": obj.get("snapshot_expiry"), + "auth_session_duration": obj.get("auth_session_duration"), + "auth_terminate_session_on_expiry": obj.get("auth_terminate_session_on_expiry"), + "refresh_interval": obj.get("refresh_interval"), + "authorization_flow": obj.get("authorization_flow"), + "nss_uid_offset": obj.get("nss_uid_offset"), + "nss_gid_offset": obj.get("nss_gid_offset"), + "challenge_key": obj.get("challenge_key"), + "challenge_idle_timeout": obj.get("challenge_idle_timeout"), + "challenge_trigger_check_in": obj.get("challenge_trigger_check_in"), + "jwt_federation_providers": obj.get("jwt_federation_providers") + }) + return _obj + + diff --git a/authentik_client/models/patched_apple_independent_secure_enclave_request.py b/authentik_client/models/patched_apple_independent_secure_enclave_request.py new file mode 100644 index 000000000..b10a62031 --- /dev/null +++ b/authentik_client/models/patched_apple_independent_secure_enclave_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAppleIndependentSecureEnclaveRequest(BaseModel): + """ + PatchedAppleIndependentSecureEnclaveRequest + """ # noqa: E501 + uuid: Optional[UUID] = None + user: Optional[StrictInt] = Field(default=None, description="The user that this device belongs to.") + apple_secure_enclave_key: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + apple_enclave_key_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + device_type: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["uuid", "user", "apple_secure_enclave_key", "apple_enclave_key_id", "device_type"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAppleIndependentSecureEnclaveRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAppleIndependentSecureEnclaveRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "uuid": obj.get("uuid"), + "user": obj.get("user"), + "apple_secure_enclave_key": obj.get("apple_secure_enclave_key"), + "apple_enclave_key_id": obj.get("apple_enclave_key_id"), + "device_type": obj.get("device_type") + }) + return _obj + + diff --git a/authentik_client/models/patched_application_entitlement_request.py b/authentik_client/models/patched_application_entitlement_request.py new file mode 100644 index 000000000..e6224c5f1 --- /dev/null +++ b/authentik_client/models/patched_application_entitlement_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedApplicationEntitlementRequest(BaseModel): + """ + ApplicationEntitlement Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + app: Optional[UUID] = None + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["name", "app", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedApplicationEntitlementRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedApplicationEntitlementRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "app": obj.get("app"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/patched_application_request.py b/authentik_client/models/patched_application_request.py new file mode 100644 index 000000000..cdcc1421c --- /dev/null +++ b/authentik_client/models/patched_application_request.py @@ -0,0 +1,131 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedApplicationRequest(BaseModel): + """ + Application Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Application's display Name.") + slug: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Internal application name, used in URLs.") + provider: Optional[StrictInt] = None + backchannel_providers: Optional[List[StrictInt]] = None + open_in_new_tab: Optional[StrictBool] = Field(default=None, description="Open launch URL in a new browser tab or window.") + meta_launch_url: Optional[StrictStr] = None + meta_icon: Optional[StrictStr] = None + meta_description: Optional[StrictStr] = None + meta_publisher: Optional[StrictStr] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + group: Optional[StrictStr] = None + meta_hide: Optional[StrictBool] = Field(default=None, description="Hide this application from the user's My applications page.") + __properties: ClassVar[List[str]] = ["name", "slug", "provider", "backchannel_providers", "open_in_new_tab", "meta_launch_url", "meta_icon", "meta_description", "meta_publisher", "policy_engine_mode", "group", "meta_hide"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedApplicationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if provider (nullable) is None + # and model_fields_set contains the field + if self.provider is None and "provider" in self.model_fields_set: + _dict['provider'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedApplicationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "provider": obj.get("provider"), + "backchannel_providers": obj.get("backchannel_providers"), + "open_in_new_tab": obj.get("open_in_new_tab"), + "meta_launch_url": obj.get("meta_launch_url"), + "meta_icon": obj.get("meta_icon"), + "meta_description": obj.get("meta_description"), + "meta_publisher": obj.get("meta_publisher"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "group": obj.get("group"), + "meta_hide": obj.get("meta_hide") + }) + return _obj + + diff --git a/authentik_client/models/patched_authenticator_duo_stage_request.py b/authentik_client/models/patched_authenticator_duo_stage_request.py new file mode 100644 index 000000000..ec5edac4d --- /dev/null +++ b/authentik_client/models/patched_authenticator_duo_stage_request.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAuthenticatorDuoStageRequest(BaseModel): + """ + AuthenticatorDuoStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + client_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + client_secret: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + api_hostname: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + admin_integration_key: Optional[StrictStr] = None + admin_secret_key: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "client_id", "client_secret", "api_hostname", "admin_integration_key", "admin_secret_key"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorDuoStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorDuoStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "client_id": obj.get("client_id"), + "client_secret": obj.get("client_secret"), + "api_hostname": obj.get("api_hostname"), + "admin_integration_key": obj.get("admin_integration_key"), + "admin_secret_key": obj.get("admin_secret_key") + }) + return _obj + + diff --git a/authentik_client/models/patched_authenticator_email_stage_request.py b/authentik_client/models/patched_authenticator_email_stage_request.py new file mode 100644 index 000000000..be1f7c969 --- /dev/null +++ b/authentik_client/models/patched_authenticator_email_stage_request.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAuthenticatorEmailStageRequest(BaseModel): + """ + AuthenticatorEmailStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + use_global_settings: Optional[StrictBool] = Field(default=None, description="When enabled, global Email connection settings will be used and connection settings below will be ignored.") + host: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + port: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + username: Optional[StrictStr] = None + password: Optional[StrictStr] = None + use_tls: Optional[StrictBool] = None + use_ssl: Optional[StrictBool] = None + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + from_address: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=254)]] = None + subject: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + token_expiry: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).") + template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "use_global_settings", "host", "port", "username", "password", "use_tls", "use_ssl", "timeout", "from_address", "subject", "token_expiry", "template"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorEmailStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorEmailStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "use_global_settings": obj.get("use_global_settings"), + "host": obj.get("host"), + "port": obj.get("port"), + "username": obj.get("username"), + "password": obj.get("password"), + "use_tls": obj.get("use_tls"), + "use_ssl": obj.get("use_ssl"), + "timeout": obj.get("timeout"), + "from_address": obj.get("from_address"), + "subject": obj.get("subject"), + "token_expiry": obj.get("token_expiry"), + "template": obj.get("template") + }) + return _obj + + diff --git a/authentik_client/models/patched_authenticator_endpoint_gdtc_stage_request.py b/authentik_client/models/patched_authenticator_endpoint_gdtc_stage_request.py new file mode 100644 index 000000000..03f345baf --- /dev/null +++ b/authentik_client/models/patched_authenticator_endpoint_gdtc_stage_request.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAuthenticatorEndpointGDTCStageRequest(BaseModel): + """ + AuthenticatorEndpointGDTCStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + credentials: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "credentials"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorEndpointGDTCStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorEndpointGDTCStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "credentials": obj.get("credentials") + }) + return _obj + + diff --git a/authentik_client/models/patched_authenticator_sms_stage_request.py b/authentik_client/models/patched_authenticator_sms_stage_request.py new file mode 100644 index 000000000..05dbbfa54 --- /dev/null +++ b/authentik_client/models/patched_authenticator_sms_stage_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.auth_type_enum import AuthTypeEnum +from authentik_client.models.provider_enum import ProviderEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAuthenticatorSMSStageRequest(BaseModel): + """ + AuthenticatorSMSStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + provider: Optional[ProviderEnum] = None + from_number: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + account_sid: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + auth: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + auth_password: Optional[StrictStr] = None + auth_type: Optional[AuthTypeEnum] = None + verify_only: Optional[StrictBool] = Field(default=None, description="When enabled, the Phone number is only used during enrollment to verify the users authenticity. Only a hash of the phone number is saved to ensure it is not reused in the future.") + mapping: Optional[UUID] = Field(default=None, description="Optionally modify the payload being sent to custom providers.") + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "provider", "from_number", "account_sid", "auth", "auth_password", "auth_type", "verify_only", "mapping"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorSMSStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + # set to None if mapping (nullable) is None + # and model_fields_set contains the field + if self.mapping is None and "mapping" in self.model_fields_set: + _dict['mapping'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorSMSStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "provider": obj.get("provider"), + "from_number": obj.get("from_number"), + "account_sid": obj.get("account_sid"), + "auth": obj.get("auth"), + "auth_password": obj.get("auth_password"), + "auth_type": obj.get("auth_type"), + "verify_only": obj.get("verify_only"), + "mapping": obj.get("mapping") + }) + return _obj + + diff --git a/authentik_client/models/patched_authenticator_static_stage_request.py b/authentik_client/models/patched_authenticator_static_stage_request.py new file mode 100644 index 000000000..506d73f85 --- /dev/null +++ b/authentik_client/models/patched_authenticator_static_stage_request.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAuthenticatorStaticStageRequest(BaseModel): + """ + AuthenticatorStaticStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + token_count: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + token_length: Optional[Annotated[int, Field(le=100, strict=True, ge=0)]] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "token_count", "token_length"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorStaticStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorStaticStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "token_count": obj.get("token_count"), + "token_length": obj.get("token_length") + }) + return _obj + + diff --git a/authentik_client/models/patched_authenticator_totp_stage_request.py b/authentik_client/models/patched_authenticator_totp_stage_request.py new file mode 100644 index 000000000..b6e6df46c --- /dev/null +++ b/authentik_client/models/patched_authenticator_totp_stage_request.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.digits_enum import DigitsEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAuthenticatorTOTPStageRequest(BaseModel): + """ + AuthenticatorTOTPStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + digits: Optional[DigitsEnum] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "digits"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorTOTPStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorTOTPStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "digits": obj.get("digits") + }) + return _obj + + diff --git a/authentik_client/models/patched_authenticator_validate_stage_request.py b/authentik_client/models/patched_authenticator_validate_stage_request.py new file mode 100644 index 000000000..f3a83bf7c --- /dev/null +++ b/authentik_client/models/patched_authenticator_validate_stage_request.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt +from typing import Any, ClassVar, Dict, List, Optional, Union +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.device_classes_enum import DeviceClassesEnum +from authentik_client.models.not_configured_action_enum import NotConfiguredActionEnum +from authentik_client.models.user_verification_enum import UserVerificationEnum +from authentik_client.models.web_authn_hint_enum import WebAuthnHintEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAuthenticatorValidateStageRequest(BaseModel): + """ + AuthenticatorValidateStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + not_configured_action: Optional[NotConfiguredActionEnum] = None + device_classes: Optional[List[DeviceClassesEnum]] = Field(default=None, description="Device classes which can be used to authenticate") + configuration_stages: Optional[List[UUID]] = Field(default=None, description="Stages used to configure Authenticator when user doesn't have any compatible devices. After this configuration Stage passes, the user is not prompted again.") + last_auth_threshold: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="If any of the user's device has been used within this threshold, this stage will be skipped") + webauthn_user_verification: Optional[UserVerificationEnum] = Field(default=None, description="Enforce user verification for WebAuthn devices.") + webauthn_hints: Optional[List[WebAuthnHintEnum]] = None + webauthn_allowed_device_types: Optional[List[UUID]] = None + email_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + sms_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + totp_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + static_otp_throttling_factor: Optional[Union[StrictFloat, StrictInt]] = None + __properties: ClassVar[List[str]] = ["name", "not_configured_action", "device_classes", "configuration_stages", "last_auth_threshold", "webauthn_user_verification", "webauthn_hints", "webauthn_allowed_device_types", "email_otp_throttling_factor", "sms_otp_throttling_factor", "totp_otp_throttling_factor", "static_otp_throttling_factor"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorValidateStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorValidateStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "not_configured_action": obj.get("not_configured_action"), + "device_classes": obj.get("device_classes"), + "configuration_stages": obj.get("configuration_stages"), + "last_auth_threshold": obj.get("last_auth_threshold"), + "webauthn_user_verification": obj.get("webauthn_user_verification"), + "webauthn_hints": obj.get("webauthn_hints"), + "webauthn_allowed_device_types": obj.get("webauthn_allowed_device_types"), + "email_otp_throttling_factor": obj.get("email_otp_throttling_factor"), + "sms_otp_throttling_factor": obj.get("sms_otp_throttling_factor"), + "totp_otp_throttling_factor": obj.get("totp_otp_throttling_factor"), + "static_otp_throttling_factor": obj.get("static_otp_throttling_factor") + }) + return _obj + + diff --git a/authentik_client/models/patched_authenticator_web_authn_stage_request.py b/authentik_client/models/patched_authenticator_web_authn_stage_request.py new file mode 100644 index 000000000..fd8ce1087 --- /dev/null +++ b/authentik_client/models/patched_authenticator_web_authn_stage_request.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.authenticator_attachment_enum import AuthenticatorAttachmentEnum +from authentik_client.models.user_verification_enum import UserVerificationEnum +from authentik_client.models.web_authn_hint_enum import WebAuthnHintEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedAuthenticatorWebAuthnStageRequest(BaseModel): + """ + AuthenticatorWebAuthnStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + friendly_name: Optional[StrictStr] = None + user_verification: Optional[UserVerificationEnum] = None + authenticator_attachment: Optional[AuthenticatorAttachmentEnum] = None + resident_key_requirement: Optional[UserVerificationEnum] = None + hints: Optional[List[WebAuthnHintEnum]] = None + device_type_restrictions: Optional[List[UUID]] = None + prevent_duplicate_devices: Optional[StrictBool] = Field(default=None, description="When enabled, a given device can only be registered once.") + max_attempts: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + __properties: ClassVar[List[str]] = ["name", "configure_flow", "friendly_name", "user_verification", "authenticator_attachment", "resident_key_requirement", "hints", "device_type_restrictions", "prevent_duplicate_devices", "max_attempts"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorWebAuthnStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + # set to None if authenticator_attachment (nullable) is None + # and model_fields_set contains the field + if self.authenticator_attachment is None and "authenticator_attachment" in self.model_fields_set: + _dict['authenticator_attachment'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedAuthenticatorWebAuthnStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "configure_flow": obj.get("configure_flow"), + "friendly_name": obj.get("friendly_name"), + "user_verification": obj.get("user_verification"), + "authenticator_attachment": obj.get("authenticator_attachment"), + "resident_key_requirement": obj.get("resident_key_requirement"), + "hints": obj.get("hints"), + "device_type_restrictions": obj.get("device_type_restrictions"), + "prevent_duplicate_devices": obj.get("prevent_duplicate_devices"), + "max_attempts": obj.get("max_attempts") + }) + return _obj + + diff --git a/authentik_client/models/patched_blueprint_instance_request.py b/authentik_client/models/patched_blueprint_instance_request.py new file mode 100644 index 000000000..ff6e09103 --- /dev/null +++ b/authentik_client/models/patched_blueprint_instance_request.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedBlueprintInstanceRequest(BaseModel): + """ + Info about a single blueprint instance file + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + path: Optional[StrictStr] = '' + context: Optional[Dict[str, Any]] = None + enabled: Optional[StrictBool] = None + content: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "path", "context", "enabled", "content"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedBlueprintInstanceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedBlueprintInstanceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "path": obj.get("path") if obj.get("path") is not None else '', + "context": obj.get("context"), + "enabled": obj.get("enabled"), + "content": obj.get("content") + }) + return _obj + + diff --git a/authentik_client/models/patched_brand_request.py b/authentik_client/models/patched_brand_request.py new file mode 100644 index 000000000..90a1c7737 --- /dev/null +++ b/authentik_client/models/patched_brand_request.py @@ -0,0 +1,170 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedBrandRequest(BaseModel): + """ + Brand Serializer + """ # noqa: E501 + domain: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Domain that activates this brand. Can be a superset, i.e. `a.b` for `aa.b` and `ba.b`") + default: Optional[StrictBool] = None + branding_title: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + branding_logo: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + branding_favicon: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + branding_custom_css: Optional[StrictStr] = None + branding_default_flow_background: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + flow_authentication: Optional[UUID] = None + flow_invalidation: Optional[UUID] = None + flow_recovery: Optional[UUID] = None + flow_unenrollment: Optional[UUID] = None + flow_user_settings: Optional[UUID] = None + flow_device_code: Optional[UUID] = None + flow_lockdown: Optional[UUID] = None + default_application: Optional[UUID] = Field(default=None, description="When set, external users will be redirected to this application after authenticating.") + web_certificate: Optional[UUID] = Field(default=None, description="Web Certificate used by the authentik Core webserver.") + client_certificates: Optional[List[UUID]] = Field(default=None, description="Certificates used for client authentication.") + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["domain", "default", "branding_title", "branding_logo", "branding_favicon", "branding_custom_css", "branding_default_flow_background", "flow_authentication", "flow_invalidation", "flow_recovery", "flow_unenrollment", "flow_user_settings", "flow_device_code", "flow_lockdown", "default_application", "web_certificate", "client_certificates", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedBrandRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if flow_authentication (nullable) is None + # and model_fields_set contains the field + if self.flow_authentication is None and "flow_authentication" in self.model_fields_set: + _dict['flow_authentication'] = None + + # set to None if flow_invalidation (nullable) is None + # and model_fields_set contains the field + if self.flow_invalidation is None and "flow_invalidation" in self.model_fields_set: + _dict['flow_invalidation'] = None + + # set to None if flow_recovery (nullable) is None + # and model_fields_set contains the field + if self.flow_recovery is None and "flow_recovery" in self.model_fields_set: + _dict['flow_recovery'] = None + + # set to None if flow_unenrollment (nullable) is None + # and model_fields_set contains the field + if self.flow_unenrollment is None and "flow_unenrollment" in self.model_fields_set: + _dict['flow_unenrollment'] = None + + # set to None if flow_user_settings (nullable) is None + # and model_fields_set contains the field + if self.flow_user_settings is None and "flow_user_settings" in self.model_fields_set: + _dict['flow_user_settings'] = None + + # set to None if flow_device_code (nullable) is None + # and model_fields_set contains the field + if self.flow_device_code is None and "flow_device_code" in self.model_fields_set: + _dict['flow_device_code'] = None + + # set to None if flow_lockdown (nullable) is None + # and model_fields_set contains the field + if self.flow_lockdown is None and "flow_lockdown" in self.model_fields_set: + _dict['flow_lockdown'] = None + + # set to None if default_application (nullable) is None + # and model_fields_set contains the field + if self.default_application is None and "default_application" in self.model_fields_set: + _dict['default_application'] = None + + # set to None if web_certificate (nullable) is None + # and model_fields_set contains the field + if self.web_certificate is None and "web_certificate" in self.model_fields_set: + _dict['web_certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedBrandRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "domain": obj.get("domain"), + "default": obj.get("default"), + "branding_title": obj.get("branding_title"), + "branding_logo": obj.get("branding_logo"), + "branding_favicon": obj.get("branding_favicon"), + "branding_custom_css": obj.get("branding_custom_css"), + "branding_default_flow_background": obj.get("branding_default_flow_background"), + "flow_authentication": obj.get("flow_authentication"), + "flow_invalidation": obj.get("flow_invalidation"), + "flow_recovery": obj.get("flow_recovery"), + "flow_unenrollment": obj.get("flow_unenrollment"), + "flow_user_settings": obj.get("flow_user_settings"), + "flow_device_code": obj.get("flow_device_code"), + "flow_lockdown": obj.get("flow_lockdown"), + "default_application": obj.get("default_application"), + "web_certificate": obj.get("web_certificate"), + "client_certificates": obj.get("client_certificates"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/patched_captcha_stage_request.py b/authentik_client/models/patched_captcha_stage_request.py new file mode 100644 index 000000000..e9a51bc00 --- /dev/null +++ b/authentik_client/models/patched_captcha_stage_request.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt +from typing import Any, ClassVar, Dict, List, Optional, Union +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedCaptchaStageRequest(BaseModel): + """ + CaptchaStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + public_key: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Public key, acquired your captcha Provider.") + private_key: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Private key, acquired your captcha Provider.") + js_url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + api_url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + interactive: Optional[StrictBool] = None + score_min_threshold: Optional[Union[StrictFloat, StrictInt]] = None + score_max_threshold: Optional[Union[StrictFloat, StrictInt]] = None + error_on_invalid_score: Optional[StrictBool] = Field(default=None, description="When enabled and the received captcha score is outside of the given threshold, the stage will show an error message. When not enabled, the flow will continue, but the data from the captcha will be available in the context for policy decisions") + __properties: ClassVar[List[str]] = ["name", "public_key", "private_key", "js_url", "api_url", "interactive", "score_min_threshold", "score_max_threshold", "error_on_invalid_score"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedCaptchaStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedCaptchaStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "public_key": obj.get("public_key"), + "private_key": obj.get("private_key"), + "js_url": obj.get("js_url"), + "api_url": obj.get("api_url"), + "interactive": obj.get("interactive"), + "score_min_threshold": obj.get("score_min_threshold"), + "score_max_threshold": obj.get("score_max_threshold"), + "error_on_invalid_score": obj.get("error_on_invalid_score") + }) + return _obj + + diff --git a/authentik_client/models/patched_certificate_key_pair_request.py b/authentik_client/models/patched_certificate_key_pair_request.py new file mode 100644 index 000000000..007591a8f --- /dev/null +++ b/authentik_client/models/patched_certificate_key_pair_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedCertificateKeyPairRequest(BaseModel): + """ + CertificateKeyPair Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + certificate_data: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="PEM-encoded Certificate data") + key_data: Optional[StrictStr] = Field(default=None, description="Optional Private Key. If this is set, you can use this keypair for encryption.") + __properties: ClassVar[List[str]] = ["name", "certificate_data", "key_data"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedCertificateKeyPairRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedCertificateKeyPairRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "certificate_data": obj.get("certificate_data"), + "key_data": obj.get("key_data") + }) + return _obj + + diff --git a/authentik_client/models/patched_connection_token_request.py b/authentik_client/models/patched_connection_token_request.py new file mode 100644 index 000000000..93956898c --- /dev/null +++ b/authentik_client/models/patched_connection_token_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedConnectionTokenRequest(BaseModel): + """ + ConnectionToken Serializer + """ # noqa: E501 + pk: Optional[UUID] = None + provider: Optional[StrictInt] = None + endpoint: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["pk", "provider", "endpoint"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedConnectionTokenRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedConnectionTokenRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "provider": obj.get("provider"), + "endpoint": obj.get("endpoint") + }) + return _obj + + diff --git a/authentik_client/models/patched_consent_stage_request.py b/authentik_client/models/patched_consent_stage_request.py new file mode 100644 index 000000000..f583f1cdf --- /dev/null +++ b/authentik_client/models/patched_consent_stage_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.consent_mode_enum import ConsentModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedConsentStageRequest(BaseModel): + """ + ConsentStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + mode: Optional[ConsentModeEnum] = None + consent_expire_in: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Offset after which consent expires. (Format: hours=1;minutes=2;seconds=3).") + __properties: ClassVar[List[str]] = ["name", "mode", "consent_expire_in"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedConsentStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedConsentStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "mode": obj.get("mode"), + "consent_expire_in": obj.get("consent_expire_in") + }) + return _obj + + diff --git a/authentik_client/models/patched_deny_stage_request.py b/authentik_client/models/patched_deny_stage_request.py new file mode 100644 index 000000000..8074aac01 --- /dev/null +++ b/authentik_client/models/patched_deny_stage_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedDenyStageRequest(BaseModel): + """ + DenyStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + deny_message: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "deny_message"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedDenyStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedDenyStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "deny_message": obj.get("deny_message") + }) + return _obj + + diff --git a/authentik_client/models/patched_device_access_group_request.py b/authentik_client/models/patched_device_access_group_request.py new file mode 100644 index 000000000..6f6e1fc81 --- /dev/null +++ b/authentik_client/models/patched_device_access_group_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedDeviceAccessGroupRequest(BaseModel): + """ + PatchedDeviceAccessGroupRequest + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["name", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedDeviceAccessGroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedDeviceAccessGroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/patched_device_user_binding_request.py b/authentik_client/models/patched_device_user_binding_request.py new file mode 100644 index 000000000..d92e6254e --- /dev/null +++ b/authentik_client/models/patched_device_user_binding_request.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedDeviceUserBindingRequest(BaseModel): + """ + PolicyBinding Serializer + """ # noqa: E501 + policy: Optional[UUID] = None + group: Optional[UUID] = None + user: Optional[StrictInt] = None + target: Optional[UUID] = None + negate: Optional[StrictBool] = Field(default=None, description="Negates the outcome of the policy. Messages are unaffected.") + enabled: Optional[StrictBool] = None + order: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Timeout after which Policy execution is terminated.") + failure_result: Optional[StrictBool] = Field(default=None, description="Result if the Policy execution fails.") + is_primary: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["policy", "group", "user", "target", "negate", "enabled", "order", "timeout", "failure_result", "is_primary"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedDeviceUserBindingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if policy (nullable) is None + # and model_fields_set contains the field + if self.policy is None and "policy" in self.model_fields_set: + _dict['policy'] = None + + # set to None if group (nullable) is None + # and model_fields_set contains the field + if self.group is None and "group" in self.model_fields_set: + _dict['group'] = None + + # set to None if user (nullable) is None + # and model_fields_set contains the field + if self.user is None and "user" in self.model_fields_set: + _dict['user'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedDeviceUserBindingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "policy": obj.get("policy"), + "group": obj.get("group"), + "user": obj.get("user"), + "target": obj.get("target"), + "negate": obj.get("negate"), + "enabled": obj.get("enabled"), + "order": obj.get("order"), + "timeout": obj.get("timeout"), + "failure_result": obj.get("failure_result"), + "is_primary": obj.get("is_primary") + }) + return _obj + + diff --git a/authentik_client/models/patched_docker_service_connection_request.py b/authentik_client/models/patched_docker_service_connection_request.py new file mode 100644 index 000000000..dd73e01f6 --- /dev/null +++ b/authentik_client/models/patched_docker_service_connection_request.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedDockerServiceConnectionRequest(BaseModel): + """ + DockerServiceConnection Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + local: Optional[StrictBool] = Field(default=None, description="If enabled, use the local connection. Required Docker socket/Kubernetes Integration") + url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Can be in the format of 'unix://' when connecting to a local docker daemon, or 'https://:2376' when connecting to a remote system.") + tls_verification: Optional[UUID] = Field(default=None, description="CA which the endpoint's Certificate is verified against. Can be left empty for no validation.") + tls_authentication: Optional[UUID] = Field(default=None, description="Certificate/Key used for authentication. Can be left empty for no authentication.") + __properties: ClassVar[List[str]] = ["name", "local", "url", "tls_verification", "tls_authentication"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedDockerServiceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if tls_verification (nullable) is None + # and model_fields_set contains the field + if self.tls_verification is None and "tls_verification" in self.model_fields_set: + _dict['tls_verification'] = None + + # set to None if tls_authentication (nullable) is None + # and model_fields_set contains the field + if self.tls_authentication is None and "tls_authentication" in self.model_fields_set: + _dict['tls_authentication'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedDockerServiceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "local": obj.get("local"), + "url": obj.get("url"), + "tls_verification": obj.get("tls_verification"), + "tls_authentication": obj.get("tls_authentication") + }) + return _obj + + diff --git a/authentik_client/models/patched_domain_request.py b/authentik_client/models/patched_domain_request.py new file mode 100644 index 000000000..602aa8002 --- /dev/null +++ b/authentik_client/models/patched_domain_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedDomainRequest(BaseModel): + """ + Domain Serializer + """ # noqa: E501 + domain: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=253)]] = None + is_primary: Optional[StrictBool] = None + tenant: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["domain", "is_primary", "tenant"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedDomainRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedDomainRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "domain": obj.get("domain"), + "is_primary": obj.get("is_primary"), + "tenant": obj.get("tenant") + }) + return _obj + + diff --git a/authentik_client/models/patched_dummy_policy_request.py b/authentik_client/models/patched_dummy_policy_request.py new file mode 100644 index 000000000..8a344005c --- /dev/null +++ b/authentik_client/models/patched_dummy_policy_request.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedDummyPolicyRequest(BaseModel): + """ + Dummy Policy Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + result: Optional[StrictBool] = None + wait_min: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + wait_max: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "result", "wait_min", "wait_max"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedDummyPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedDummyPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "result": obj.get("result"), + "wait_min": obj.get("wait_min"), + "wait_max": obj.get("wait_max") + }) + return _obj + + diff --git a/authentik_client/models/patched_dummy_stage_request.py b/authentik_client/models/patched_dummy_stage_request.py new file mode 100644 index 000000000..7984fa24e --- /dev/null +++ b/authentik_client/models/patched_dummy_stage_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedDummyStageRequest(BaseModel): + """ + DummyStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + throw_error: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "throw_error"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedDummyStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedDummyStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "throw_error": obj.get("throw_error") + }) + return _obj + + diff --git a/authentik_client/models/patched_duo_device_request.py b/authentik_client/models/patched_duo_device_request.py new file mode 100644 index 000000000..00cbd075b --- /dev/null +++ b/authentik_client/models/patched_duo_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedDuoDeviceRequest(BaseModel): + """ + Serializer for Duo authenticator devices + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=64)]] = Field(default=None, description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedDuoDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedDuoDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_email_device_request.py b/authentik_client/models/patched_email_device_request.py new file mode 100644 index 000000000..00fdea663 --- /dev/null +++ b/authentik_client/models/patched_email_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedEmailDeviceRequest(BaseModel): + """ + Serializer for email authenticator devices + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=64)]] = Field(default=None, description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedEmailDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedEmailDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_email_stage_request.py b/authentik_client/models/patched_email_stage_request.py new file mode 100644 index 000000000..bde8f346e --- /dev/null +++ b/authentik_client/models/patched_email_stage_request.py @@ -0,0 +1,120 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedEmailStageRequest(BaseModel): + """ + EmailStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + use_global_settings: Optional[StrictBool] = Field(default=None, description="When enabled, global Email connection settings will be used and connection settings below will be ignored.") + host: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + port: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + username: Optional[StrictStr] = None + password: Optional[StrictStr] = None + use_tls: Optional[StrictBool] = None + use_ssl: Optional[StrictBool] = None + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + from_address: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=254)]] = None + token_expiry: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).") + subject: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + activate_user_on_success: Optional[StrictBool] = Field(default=None, description="Activate users upon completion of stage.") + recovery_max_attempts: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + recovery_cache_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="The time window used to count recent account recovery attempts. If the number of attempts exceed recovery_max_attempts within this period, further attempts will be rate-limited. (Format: hours=1;minutes=2;seconds=3).") + __properties: ClassVar[List[str]] = ["name", "use_global_settings", "host", "port", "username", "password", "use_tls", "use_ssl", "timeout", "from_address", "token_expiry", "subject", "template", "activate_user_on_success", "recovery_max_attempts", "recovery_cache_timeout"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedEmailStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedEmailStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "use_global_settings": obj.get("use_global_settings"), + "host": obj.get("host"), + "port": obj.get("port"), + "username": obj.get("username"), + "password": obj.get("password"), + "use_tls": obj.get("use_tls"), + "use_ssl": obj.get("use_ssl"), + "timeout": obj.get("timeout"), + "from_address": obj.get("from_address"), + "token_expiry": obj.get("token_expiry"), + "subject": obj.get("subject"), + "template": obj.get("template"), + "activate_user_on_success": obj.get("activate_user_on_success"), + "recovery_max_attempts": obj.get("recovery_max_attempts"), + "recovery_cache_timeout": obj.get("recovery_cache_timeout") + }) + return _obj + + diff --git a/authentik_client/models/patched_endpoint_device_request.py b/authentik_client/models/patched_endpoint_device_request.py new file mode 100644 index 000000000..68106dd0a --- /dev/null +++ b/authentik_client/models/patched_endpoint_device_request.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.device_access_group_request import DeviceAccessGroupRequest +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedEndpointDeviceRequest(BaseModel): + """ + PatchedEndpointDeviceRequest + """ # noqa: E501 + device_uuid: Optional[UUID] = None + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + access_group: Optional[UUID] = None + access_group_obj: Optional[DeviceAccessGroupRequest] = None + expiring: Optional[StrictBool] = None + expires: Optional[datetime] = None + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["device_uuid", "name", "access_group", "access_group_obj", "expiring", "expires", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedEndpointDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of access_group_obj + if self.access_group_obj: + _dict['access_group_obj'] = self.access_group_obj.to_dict() + # set to None if access_group (nullable) is None + # and model_fields_set contains the field + if self.access_group is None and "access_group" in self.model_fields_set: + _dict['access_group'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedEndpointDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_uuid": obj.get("device_uuid"), + "name": obj.get("name"), + "access_group": obj.get("access_group"), + "access_group_obj": DeviceAccessGroupRequest.from_dict(obj["access_group_obj"]) if obj.get("access_group_obj") is not None else None, + "expiring": obj.get("expiring"), + "expires": obj.get("expires"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/patched_endpoint_request.py b/authentik_client/models/patched_endpoint_request.py new file mode 100644 index 000000000..98d5c5ba2 --- /dev/null +++ b/authentik_client/models/patched_endpoint_request.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.endpoint_auth_mode_enum import EndpointAuthModeEnum +from authentik_client.models.protocol_enum import ProtocolEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedEndpointRequest(BaseModel): + """ + Endpoint Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + provider: Optional[StrictInt] = None + protocol: Optional[ProtocolEnum] = None + host: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + settings: Optional[Dict[str, Any]] = None + property_mappings: Optional[List[UUID]] = None + auth_mode: Optional[EndpointAuthModeEnum] = None + maximum_connections: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + __properties: ClassVar[List[str]] = ["name", "provider", "protocol", "host", "settings", "property_mappings", "auth_mode", "maximum_connections"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedEndpointRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedEndpointRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "provider": obj.get("provider"), + "protocol": obj.get("protocol"), + "host": obj.get("host"), + "settings": obj.get("settings"), + "property_mappings": obj.get("property_mappings"), + "auth_mode": obj.get("auth_mode"), + "maximum_connections": obj.get("maximum_connections") + }) + return _obj + + diff --git a/authentik_client/models/patched_endpoint_stage_request.py b/authentik_client/models/patched_endpoint_stage_request.py new file mode 100644 index 000000000..361ab13a5 --- /dev/null +++ b/authentik_client/models/patched_endpoint_stage_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.stage_mode_enum import StageModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedEndpointStageRequest(BaseModel): + """ + EndpointStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + connector: Optional[UUID] = None + mode: Optional[StageModeEnum] = None + __properties: ClassVar[List[str]] = ["name", "connector", "mode"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedEndpointStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedEndpointStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "connector": obj.get("connector"), + "mode": obj.get("mode") + }) + return _obj + + diff --git a/authentik_client/models/patched_enrollment_token_request.py b/authentik_client/models/patched_enrollment_token_request.py new file mode 100644 index 000000000..7e6aa51b2 --- /dev/null +++ b/authentik_client/models/patched_enrollment_token_request.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedEnrollmentTokenRequest(BaseModel): + """ + PatchedEnrollmentTokenRequest + """ # noqa: E501 + device_group: Optional[UUID] = None + connector: Optional[UUID] = None + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expiring: Optional[StrictBool] = None + expires: Optional[datetime] = None + __properties: ClassVar[List[str]] = ["device_group", "connector", "name", "expiring", "expires"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedEnrollmentTokenRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if device_group (nullable) is None + # and model_fields_set contains the field + if self.device_group is None and "device_group" in self.model_fields_set: + _dict['device_group'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedEnrollmentTokenRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "device_group": obj.get("device_group"), + "connector": obj.get("connector"), + "name": obj.get("name"), + "expiring": obj.get("expiring"), + "expires": obj.get("expires") + }) + return _obj + + diff --git a/authentik_client/models/patched_event_matcher_policy_request.py b/authentik_client/models/patched_event_matcher_policy_request.py new file mode 100644 index 000000000..202587f88 --- /dev/null +++ b/authentik_client/models/patched_event_matcher_policy_request.py @@ -0,0 +1,130 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.app_enum import AppEnum +from authentik_client.models.event_actions import EventActions +from authentik_client.models.model_enum import ModelEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedEventMatcherPolicyRequest(BaseModel): + """ + Event Matcher Policy Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + action: Optional[EventActions] = Field(default=None, description="Match created events with this action type. When left empty, all action types will be matched.") + client_ip: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Matches Event's Client IP (strict matching, for network matching use an Expression Policy)") + app: Optional[AppEnum] = Field(default=None, description="Match events created by selected application. When left empty, all applications are matched.") + model: Optional[ModelEnum] = Field(default=None, description="Match events created by selected model. When left empty, all models are matched. When an app is selected, all the application's models are matched.") + query: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "action", "client_ip", "app", "model", "query"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedEventMatcherPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if action (nullable) is None + # and model_fields_set contains the field + if self.action is None and "action" in self.model_fields_set: + _dict['action'] = None + + # set to None if client_ip (nullable) is None + # and model_fields_set contains the field + if self.client_ip is None and "client_ip" in self.model_fields_set: + _dict['client_ip'] = None + + # set to None if app (nullable) is None + # and model_fields_set contains the field + if self.app is None and "app" in self.model_fields_set: + _dict['app'] = None + + # set to None if model (nullable) is None + # and model_fields_set contains the field + if self.model is None and "model" in self.model_fields_set: + _dict['model'] = None + + # set to None if query (nullable) is None + # and model_fields_set contains the field + if self.query is None and "query" in self.model_fields_set: + _dict['query'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedEventMatcherPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "action": obj.get("action"), + "client_ip": obj.get("client_ip"), + "app": obj.get("app"), + "model": obj.get("model"), + "query": obj.get("query") + }) + return _obj + + diff --git a/authentik_client/models/patched_event_request.py b/authentik_client/models/patched_event_request.py new file mode 100644 index 000000000..59d37f923 --- /dev/null +++ b/authentik_client/models/patched_event_request.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.event_actions import EventActions +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedEventRequest(BaseModel): + """ + Event Serializer + """ # noqa: E501 + user: Optional[Dict[str, Any]] = None + action: Optional[EventActions] = None + app: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + context: Optional[Dict[str, Any]] = None + client_ip: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expires: Optional[datetime] = None + brand: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["user", "action", "app", "context", "client_ip", "expires", "brand"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedEventRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if client_ip (nullable) is None + # and model_fields_set contains the field + if self.client_ip is None and "client_ip" in self.model_fields_set: + _dict['client_ip'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedEventRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user": obj.get("user"), + "action": obj.get("action"), + "app": obj.get("app"), + "context": obj.get("context"), + "client_ip": obj.get("client_ip"), + "expires": obj.get("expires"), + "brand": obj.get("brand") + }) + return _obj + + diff --git a/authentik_client/models/patched_expression_policy_request.py b/authentik_client/models/patched_expression_policy_request.py new file mode 100644 index 000000000..52e794693 --- /dev/null +++ b/authentik_client/models/patched_expression_policy_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedExpressionPolicyRequest(BaseModel): + """ + Group Membership Policy Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedExpressionPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedExpressionPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_fleet_connector_request.py b/authentik_client/models/patched_fleet_connector_request.py new file mode 100644 index 000000000..141e5242d --- /dev/null +++ b/authentik_client/models/patched_fleet_connector_request.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedFleetConnectorRequest(BaseModel): + """ + FleetConnector Serializer + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + enabled: Optional[StrictBool] = None + url: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=200)]] = None + token: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + headers_mapping: Optional[UUID] = Field(default=None, description="Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs") + map_users: Optional[StrictBool] = None + map_teams_access_group: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "url", "token", "headers_mapping", "map_users", "map_teams_access_group"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedFleetConnectorRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if headers_mapping (nullable) is None + # and model_fields_set contains the field + if self.headers_mapping is None and "headers_mapping" in self.model_fields_set: + _dict['headers_mapping'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedFleetConnectorRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "url": obj.get("url"), + "token": obj.get("token"), + "headers_mapping": obj.get("headers_mapping"), + "map_users": obj.get("map_users"), + "map_teams_access_group": obj.get("map_teams_access_group") + }) + return _obj + + diff --git a/authentik_client/models/patched_flow_request.py b/authentik_client/models/patched_flow_request.py new file mode 100644 index 000000000..6f700f87d --- /dev/null +++ b/authentik_client/models/patched_flow_request.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.authentication_enum import AuthenticationEnum +from authentik_client.models.denied_action_enum import DeniedActionEnum +from authentik_client.models.flow_designation_enum import FlowDesignationEnum +from authentik_client.models.flow_layout_enum import FlowLayoutEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedFlowRequest(BaseModel): + """ + Flow Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + slug: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Visible in the URL.") + title: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Shown as the Title in Flow pages.") + designation: Optional[FlowDesignationEnum] = Field(default=None, description="Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik.") + background: Optional[StrictStr] = Field(default=None, description="Background shown during execution") + policy_engine_mode: Optional[PolicyEngineMode] = None + compatibility_mode: Optional[StrictBool] = Field(default=None, description="Enable compatibility mode, increases compatibility with password managers on mobile devices.") + layout: Optional[FlowLayoutEnum] = None + denied_action: Optional[DeniedActionEnum] = Field(default=None, description="Configure what should happen when a flow denies access to a user.") + authentication: Optional[AuthenticationEnum] = Field(default=None, description="Required level of authentication and authorization to access a flow.") + __properties: ClassVar[List[str]] = ["name", "slug", "title", "designation", "background", "policy_engine_mode", "compatibility_mode", "layout", "denied_action", "authentication"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedFlowRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedFlowRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "title": obj.get("title"), + "designation": obj.get("designation"), + "background": obj.get("background"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "compatibility_mode": obj.get("compatibility_mode"), + "layout": obj.get("layout"), + "denied_action": obj.get("denied_action"), + "authentication": obj.get("authentication") + }) + return _obj + + diff --git a/authentik_client/models/patched_flow_stage_binding_request.py b/authentik_client/models/patched_flow_stage_binding_request.py new file mode 100644 index 000000000..b00d1ce7b --- /dev/null +++ b/authentik_client/models/patched_flow_stage_binding_request.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.invalid_response_action_enum import InvalidResponseActionEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedFlowStageBindingRequest(BaseModel): + """ + FlowStageBinding Serializer + """ # noqa: E501 + target: Optional[UUID] = None + stage: Optional[UUID] = None + evaluate_on_plan: Optional[StrictBool] = Field(default=None, description="Evaluate policies during the Flow planning process.") + re_evaluate_policies: Optional[StrictBool] = Field(default=None, description="Evaluate policies when the Stage is presented to the user.") + order: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + invalid_response_action: Optional[InvalidResponseActionEnum] = Field(default=None, description="Configure how the flow executor should handle an invalid response to a challenge. RETRY returns the error message and a similar challenge to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT restarts the flow while keeping the current context.") + __properties: ClassVar[List[str]] = ["target", "stage", "evaluate_on_plan", "re_evaluate_policies", "order", "policy_engine_mode", "invalid_response_action"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedFlowStageBindingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedFlowStageBindingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "target": obj.get("target"), + "stage": obj.get("stage"), + "evaluate_on_plan": obj.get("evaluate_on_plan"), + "re_evaluate_policies": obj.get("re_evaluate_policies"), + "order": obj.get("order"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "invalid_response_action": obj.get("invalid_response_action") + }) + return _obj + + diff --git a/authentik_client/models/patched_geo_ip_policy_request.py b/authentik_client/models/patched_geo_ip_policy_request.py new file mode 100644 index 000000000..1cf8e4135 --- /dev/null +++ b/authentik_client/models/patched_geo_ip_policy_request.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.country_code_enum import CountryCodeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGeoIPPolicyRequest(BaseModel): + """ + GeoIP Policy Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + asns: Optional[List[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]]] = None + countries: Optional[Annotated[List[CountryCodeEnum], Field(max_length=249)]] = None + check_history_distance: Optional[StrictBool] = None + history_max_distance_km: Optional[Annotated[int, Field(le=9223372036854775807, strict=True, ge=0)]] = None + distance_tolerance_km: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + history_login_count: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + check_impossible_travel: Optional[StrictBool] = None + impossible_tolerance_km: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "asns", "countries", "check_history_distance", "history_max_distance_km", "distance_tolerance_km", "history_login_count", "check_impossible_travel", "impossible_tolerance_km"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGeoIPPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGeoIPPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "asns": obj.get("asns"), + "countries": obj.get("countries"), + "check_history_distance": obj.get("check_history_distance"), + "history_max_distance_km": obj.get("history_max_distance_km"), + "distance_tolerance_km": obj.get("distance_tolerance_km"), + "history_login_count": obj.get("history_login_count"), + "check_impossible_travel": obj.get("check_impossible_travel"), + "impossible_tolerance_km": obj.get("impossible_tolerance_km") + }) + return _obj + + diff --git a/authentik_client/models/patched_google_chrome_connector_request.py b/authentik_client/models/patched_google_chrome_connector_request.py new file mode 100644 index 000000000..37bac659a --- /dev/null +++ b/authentik_client/models/patched_google_chrome_connector_request.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGoogleChromeConnectorRequest(BaseModel): + """ + GoogleChromeConnector Serializer + """ # noqa: E501 + connector_uuid: Optional[UUID] = None + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + enabled: Optional[StrictBool] = None + credentials: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["connector_uuid", "name", "enabled", "credentials"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGoogleChromeConnectorRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGoogleChromeConnectorRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "connector_uuid": obj.get("connector_uuid"), + "name": obj.get("name"), + "enabled": obj.get("enabled"), + "credentials": obj.get("credentials") + }) + return _obj + + diff --git a/authentik_client/models/patched_google_endpoint_device_request.py b/authentik_client/models/patched_google_endpoint_device_request.py new file mode 100644 index 000000000..91ccea5c7 --- /dev/null +++ b/authentik_client/models/patched_google_endpoint_device_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGoogleEndpointDeviceRequest(BaseModel): + """ + Serializer for Endpoint authenticator devices + """ # noqa: E501 + pk: Optional[UUID] = None + name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=64)]] = Field(default=None, description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["pk", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGoogleEndpointDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGoogleEndpointDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_google_workspace_provider_mapping_request.py b/authentik_client/models/patched_google_workspace_provider_mapping_request.py new file mode 100644 index 000000000..536e77c6c --- /dev/null +++ b/authentik_client/models/patched_google_workspace_provider_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGoogleWorkspaceProviderMappingRequest(BaseModel): + """ + GoogleWorkspaceProviderMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGoogleWorkspaceProviderMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGoogleWorkspaceProviderMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_google_workspace_provider_request.py b/authentik_client/models/patched_google_workspace_provider_request.py new file mode 100644 index 000000000..45698704a --- /dev/null +++ b/authentik_client/models/patched_google_workspace_provider_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.outgoing_sync_delete_action import OutgoingSyncDeleteAction +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGoogleWorkspaceProviderRequest(BaseModel): + """ + GoogleWorkspaceProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + property_mappings: Optional[List[UUID]] = None + property_mappings_group: Optional[List[UUID]] = Field(default=None, description="Property mappings used for group creation/updating.") + delegated_subject: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=254)]] = None + credentials: Optional[Dict[str, Any]] = None + scopes: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + exclude_users_service_account: Optional[StrictBool] = None + filter_group: Optional[UUID] = None + user_delete_action: Optional[OutgoingSyncDeleteAction] = None + group_delete_action: Optional[OutgoingSyncDeleteAction] = None + default_group_email_domain: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + sync_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Controls the number of objects synced in a single task") + sync_page_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Timeout for synchronization of a single page") + dry_run: Optional[StrictBool] = Field(default=None, description="When enabled, provider will not modify or create objects in the remote system.") + __properties: ClassVar[List[str]] = ["name", "property_mappings", "property_mappings_group", "delegated_subject", "credentials", "scopes", "exclude_users_service_account", "filter_group", "user_delete_action", "group_delete_action", "default_group_email_domain", "sync_page_size", "sync_page_timeout", "dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGoogleWorkspaceProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if filter_group (nullable) is None + # and model_fields_set contains the field + if self.filter_group is None and "filter_group" in self.model_fields_set: + _dict['filter_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGoogleWorkspaceProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "property_mappings": obj.get("property_mappings"), + "property_mappings_group": obj.get("property_mappings_group"), + "delegated_subject": obj.get("delegated_subject"), + "credentials": obj.get("credentials"), + "scopes": obj.get("scopes"), + "exclude_users_service_account": obj.get("exclude_users_service_account"), + "filter_group": obj.get("filter_group"), + "user_delete_action": obj.get("user_delete_action"), + "group_delete_action": obj.get("group_delete_action"), + "default_group_email_domain": obj.get("default_group_email_domain"), + "sync_page_size": obj.get("sync_page_size"), + "sync_page_timeout": obj.get("sync_page_timeout"), + "dry_run": obj.get("dry_run") + }) + return _obj + + diff --git a/authentik_client/models/patched_group_kerberos_source_connection_request.py b/authentik_client/models/patched_group_kerberos_source_connection_request.py new file mode 100644 index 000000000..dbe035878 --- /dev/null +++ b/authentik_client/models/patched_group_kerberos_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGroupKerberosSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGroupKerberosSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGroupKerberosSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_group_ldap_source_connection_request.py b/authentik_client/models/patched_group_ldap_source_connection_request.py new file mode 100644 index 000000000..a05f1755a --- /dev/null +++ b/authentik_client/models/patched_group_ldap_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGroupLDAPSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGroupLDAPSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGroupLDAPSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_group_o_auth_source_connection_request.py b/authentik_client/models/patched_group_o_auth_source_connection_request.py new file mode 100644 index 000000000..94a3b67f4 --- /dev/null +++ b/authentik_client/models/patched_group_o_auth_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGroupOAuthSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGroupOAuthSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGroupOAuthSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_group_plex_source_connection_request.py b/authentik_client/models/patched_group_plex_source_connection_request.py new file mode 100644 index 000000000..ff448f339 --- /dev/null +++ b/authentik_client/models/patched_group_plex_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGroupPlexSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGroupPlexSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGroupPlexSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_group_request.py b/authentik_client/models/patched_group_request.py new file mode 100644 index 000000000..f48a15318 --- /dev/null +++ b/authentik_client/models/patched_group_request.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGroupRequest(BaseModel): + """ + Group Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + is_superuser: Optional[StrictBool] = Field(default=None, description="Users added to this group will be superusers.") + parents: Optional[List[UUID]] = None + users: Optional[List[StrictInt]] = None + attributes: Optional[Dict[str, Any]] = None + roles: Optional[List[UUID]] = None + __properties: ClassVar[List[str]] = ["name", "is_superuser", "parents", "users", "attributes", "roles"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "is_superuser": obj.get("is_superuser"), + "parents": obj.get("parents"), + "users": obj.get("users"), + "attributes": obj.get("attributes"), + "roles": obj.get("roles") + }) + return _obj + + diff --git a/authentik_client/models/patched_group_saml_source_connection_request.py b/authentik_client/models/patched_group_saml_source_connection_request.py new file mode 100644 index 000000000..a72090165 --- /dev/null +++ b/authentik_client/models/patched_group_saml_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGroupSAMLSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGroupSAMLSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGroupSAMLSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_group_source_connection_request.py b/authentik_client/models/patched_group_source_connection_request.py new file mode 100644 index 000000000..f3af4becd --- /dev/null +++ b/authentik_client/models/patched_group_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGroupSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGroupSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGroupSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_group_telegram_source_connection_request.py b/authentik_client/models/patched_group_telegram_source_connection_request.py new file mode 100644 index 000000000..ba7e73e6e --- /dev/null +++ b/authentik_client/models/patched_group_telegram_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedGroupTelegramSourceConnectionRequest(BaseModel): + """ + Group Source Connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedGroupTelegramSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedGroupTelegramSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_identification_stage_request.py b/authentik_client/models/patched_identification_stage_request.py new file mode 100644 index 000000000..a16ebfae4 --- /dev/null +++ b/authentik_client/models/patched_identification_stage_request.py @@ -0,0 +1,148 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.user_fields_enum import UserFieldsEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedIdentificationStageRequest(BaseModel): + """ + IdentificationStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + user_fields: Optional[List[UserFieldsEnum]] = Field(default=None, description="Fields of the user object to match against. (Hold shift to select multiple options)") + password_stage: Optional[UUID] = Field(default=None, description="When set, shows a password field, instead of showing the password field as separate step.") + captcha_stage: Optional[UUID] = Field(default=None, description="When set, adds functionality exactly like a Captcha stage, but baked into the Identification stage.") + case_insensitive_matching: Optional[StrictBool] = Field(default=None, description="When enabled, user fields are matched regardless of their casing.") + show_matched_user: Optional[StrictBool] = Field(default=None, description="When a valid username/email has been entered, and this option is enabled, the user's username and avatar will be shown. Otherwise, the text that the user entered will be shown") + enrollment_flow: Optional[UUID] = Field(default=None, description="Optional enrollment flow, which is linked at the bottom of the page.") + recovery_flow: Optional[UUID] = Field(default=None, description="Optional recovery flow, which is linked at the bottom of the page.") + passwordless_flow: Optional[UUID] = Field(default=None, description="Optional passwordless flow, which is linked at the bottom of the page.") + sources: Optional[List[UUID]] = Field(default=None, description="Specify which sources should be shown.") + show_source_labels: Optional[StrictBool] = None + pretend_user_exists: Optional[StrictBool] = Field(default=None, description="When enabled, the stage will succeed and continue even when incorrect user info is entered.") + enable_remember_me: Optional[StrictBool] = Field(default=None, description="Show the user the 'Remember me on this device' toggle, allowing repeat users to skip straight to entering their password.") + webauthn_stage: Optional[UUID] = Field(default=None, description="When set, and conditional WebAuthn is available, allow the user to use their passkey as a first factor.") + __properties: ClassVar[List[str]] = ["name", "user_fields", "password_stage", "captcha_stage", "case_insensitive_matching", "show_matched_user", "enrollment_flow", "recovery_flow", "passwordless_flow", "sources", "show_source_labels", "pretend_user_exists", "enable_remember_me", "webauthn_stage"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedIdentificationStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if password_stage (nullable) is None + # and model_fields_set contains the field + if self.password_stage is None and "password_stage" in self.model_fields_set: + _dict['password_stage'] = None + + # set to None if captcha_stage (nullable) is None + # and model_fields_set contains the field + if self.captcha_stage is None and "captcha_stage" in self.model_fields_set: + _dict['captcha_stage'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if recovery_flow (nullable) is None + # and model_fields_set contains the field + if self.recovery_flow is None and "recovery_flow" in self.model_fields_set: + _dict['recovery_flow'] = None + + # set to None if passwordless_flow (nullable) is None + # and model_fields_set contains the field + if self.passwordless_flow is None and "passwordless_flow" in self.model_fields_set: + _dict['passwordless_flow'] = None + + # set to None if webauthn_stage (nullable) is None + # and model_fields_set contains the field + if self.webauthn_stage is None and "webauthn_stage" in self.model_fields_set: + _dict['webauthn_stage'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedIdentificationStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "user_fields": obj.get("user_fields"), + "password_stage": obj.get("password_stage"), + "captcha_stage": obj.get("captcha_stage"), + "case_insensitive_matching": obj.get("case_insensitive_matching"), + "show_matched_user": obj.get("show_matched_user"), + "enrollment_flow": obj.get("enrollment_flow"), + "recovery_flow": obj.get("recovery_flow"), + "passwordless_flow": obj.get("passwordless_flow"), + "sources": obj.get("sources"), + "show_source_labels": obj.get("show_source_labels"), + "pretend_user_exists": obj.get("pretend_user_exists"), + "enable_remember_me": obj.get("enable_remember_me"), + "webauthn_stage": obj.get("webauthn_stage") + }) + return _obj + + diff --git a/authentik_client/models/patched_initial_permissions_request.py b/authentik_client/models/patched_initial_permissions_request.py new file mode 100644 index 000000000..1be8efbbf --- /dev/null +++ b/authentik_client/models/patched_initial_permissions_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedInitialPermissionsRequest(BaseModel): + """ + InitialPermissions serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=150)]] = None + role: Optional[UUID] = None + permissions: Optional[List[StrictInt]] = None + __properties: ClassVar[List[str]] = ["name", "role", "permissions"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedInitialPermissionsRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedInitialPermissionsRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "role": obj.get("role"), + "permissions": obj.get("permissions") + }) + return _obj + + diff --git a/authentik_client/models/patched_invitation_request.py b/authentik_client/models/patched_invitation_request.py new file mode 100644 index 000000000..943a8672f --- /dev/null +++ b/authentik_client/models/patched_invitation_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedInvitationRequest(BaseModel): + """ + Invitation Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expires: Optional[datetime] = None + fixed_data: Optional[Dict[str, Any]] = None + single_use: Optional[StrictBool] = Field(default=None, description="When enabled, the invitation will be deleted after usage.") + flow: Optional[UUID] = Field(default=None, description="When set, only the configured flow can use this invitation.") + __properties: ClassVar[List[str]] = ["name", "expires", "fixed_data", "single_use", "flow"] + + @field_validator('name') + def name_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedInvitationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + # set to None if flow (nullable) is None + # and model_fields_set contains the field + if self.flow is None and "flow" in self.model_fields_set: + _dict['flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedInvitationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "expires": obj.get("expires"), + "fixed_data": obj.get("fixed_data"), + "single_use": obj.get("single_use"), + "flow": obj.get("flow") + }) + return _obj + + diff --git a/authentik_client/models/patched_invitation_stage_request.py b/authentik_client/models/patched_invitation_stage_request.py new file mode 100644 index 000000000..a6c0cb555 --- /dev/null +++ b/authentik_client/models/patched_invitation_stage_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedInvitationStageRequest(BaseModel): + """ + InvitationStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + continue_flow_without_invitation: Optional[StrictBool] = Field(default=None, description="If this flag is set, this Stage will jump to the next Stage when no Invitation is given. By default this Stage will cancel the Flow when no invitation is given.") + __properties: ClassVar[List[str]] = ["name", "continue_flow_without_invitation"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedInvitationStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedInvitationStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "continue_flow_without_invitation": obj.get("continue_flow_without_invitation") + }) + return _obj + + diff --git a/authentik_client/models/patched_kerberos_source_property_mapping_request.py b/authentik_client/models/patched_kerberos_source_property_mapping_request.py new file mode 100644 index 000000000..9f6514c38 --- /dev/null +++ b/authentik_client/models/patched_kerberos_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedKerberosSourcePropertyMappingRequest(BaseModel): + """ + Kerberos PropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedKerberosSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedKerberosSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_kerberos_source_request.py b/authentik_client/models/patched_kerberos_source_request.py new file mode 100644 index 000000000..74325f8ab --- /dev/null +++ b/authentik_client/models/patched_kerberos_source_request.py @@ -0,0 +1,171 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.kadmin_type_enum import KadminTypeEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.sync_outgoing_trigger_mode_enum import SyncOutgoingTriggerModeEnum +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedKerberosSourceRequest(BaseModel): + """ + Kerberos Source Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Source's display Name.") + slug: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + realm: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Kerberos realm") + krb5_conf: Optional[StrictStr] = Field(default=None, description="Custom krb5.conf to use. Uses the system one by default") + kadmin_type: Optional[KadminTypeEnum] = Field(default=None, description="KAdmin server type") + sync_users: Optional[StrictBool] = Field(default=None, description="Sync users from Kerberos into authentik") + sync_users_password: Optional[StrictBool] = Field(default=None, description="When a user changes their password, sync it back to Kerberos") + sync_principal: Optional[StrictStr] = Field(default=None, description="Principal to authenticate to kadmin for sync.") + sync_password: Optional[StrictStr] = Field(default=None, description="Password to authenticate to kadmin for sync") + sync_keytab: Optional[StrictStr] = Field(default=None, description="Keytab to authenticate to kadmin for sync. Must be base64-encoded or in the form TYPE:residual") + sync_ccache: Optional[StrictStr] = Field(default=None, description="Credentials cache to authenticate to kadmin for sync. Must be in the form TYPE:residual") + spnego_server_name: Optional[StrictStr] = Field(default=None, description="Force the use of a specific server name for SPNEGO. Must be in the form HTTP@hostname") + spnego_keytab: Optional[StrictStr] = Field(default=None, description="SPNEGO keytab base64-encoded or path to keytab in the form FILE:path") + spnego_ccache: Optional[StrictStr] = Field(default=None, description="Credential cache to use for SPNEGO in form type:residual") + password_login_update_internal_password: Optional[StrictBool] = Field(default=None, description="If enabled, the authentik-stored password will be updated upon login with the Kerberos password backend") + sync_outgoing_trigger_mode: Optional[SyncOutgoingTriggerModeEnum] = Field(default=None, description="When to trigger sync for outgoing providers") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "group_matching_mode", "realm", "krb5_conf", "kadmin_type", "sync_users", "sync_users_password", "sync_principal", "sync_password", "sync_keytab", "sync_ccache", "spnego_server_name", "spnego_keytab", "spnego_ccache", "password_login_update_internal_password", "sync_outgoing_trigger_mode"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedKerberosSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedKerberosSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "group_matching_mode": obj.get("group_matching_mode"), + "realm": obj.get("realm"), + "krb5_conf": obj.get("krb5_conf"), + "kadmin_type": obj.get("kadmin_type"), + "sync_users": obj.get("sync_users"), + "sync_users_password": obj.get("sync_users_password"), + "sync_principal": obj.get("sync_principal"), + "sync_password": obj.get("sync_password"), + "sync_keytab": obj.get("sync_keytab"), + "sync_ccache": obj.get("sync_ccache"), + "spnego_server_name": obj.get("spnego_server_name"), + "spnego_keytab": obj.get("spnego_keytab"), + "spnego_ccache": obj.get("spnego_ccache"), + "password_login_update_internal_password": obj.get("password_login_update_internal_password"), + "sync_outgoing_trigger_mode": obj.get("sync_outgoing_trigger_mode") + }) + return _obj + + diff --git a/authentik_client/models/patched_kubernetes_service_connection_request.py b/authentik_client/models/patched_kubernetes_service_connection_request.py new file mode 100644 index 000000000..c87efe876 --- /dev/null +++ b/authentik_client/models/patched_kubernetes_service_connection_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedKubernetesServiceConnectionRequest(BaseModel): + """ + KubernetesServiceConnection Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + local: Optional[StrictBool] = Field(default=None, description="If enabled, use the local connection. Required Docker socket/Kubernetes Integration") + kubeconfig: Optional[Dict[str, Any]] = Field(default=None, description="Paste your kubeconfig here. authentik will automatically use the currently selected context.") + verify_ssl: Optional[StrictBool] = Field(default=None, description="Verify SSL Certificates of the Kubernetes API endpoint") + __properties: ClassVar[List[str]] = ["name", "local", "kubeconfig", "verify_ssl"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedKubernetesServiceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedKubernetesServiceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "local": obj.get("local"), + "kubeconfig": obj.get("kubeconfig"), + "verify_ssl": obj.get("verify_ssl") + }) + return _obj + + diff --git a/authentik_client/models/patched_ldap_provider_request.py b/authentik_client/models/patched_ldap_provider_request.py new file mode 100644 index 000000000..0ecb809f1 --- /dev/null +++ b/authentik_client/models/patched_ldap_provider_request.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.ldapapi_access_mode import LDAPAPIAccessMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedLDAPProviderRequest(BaseModel): + """ + LDAPProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: Optional[UUID] = Field(default=None, description="Flow used when authorizing this provider.") + invalidation_flow: Optional[UUID] = Field(default=None, description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + base_dn: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="DN under which objects are accessible.") + certificate: Optional[UUID] = None + tls_server_name: Optional[StrictStr] = None + uid_start_number: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber") + gid_start_number: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber") + search_mode: Optional[LDAPAPIAccessMode] = None + bind_mode: Optional[LDAPAPIAccessMode] = None + mfa_support: Optional[StrictBool] = Field(default=None, description="When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.") + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "base_dn", "certificate", "tls_server_name", "uid_start_number", "gid_start_number", "search_mode", "bind_mode", "mfa_support"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedLDAPProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedLDAPProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "base_dn": obj.get("base_dn"), + "certificate": obj.get("certificate"), + "tls_server_name": obj.get("tls_server_name"), + "uid_start_number": obj.get("uid_start_number"), + "gid_start_number": obj.get("gid_start_number"), + "search_mode": obj.get("search_mode"), + "bind_mode": obj.get("bind_mode"), + "mfa_support": obj.get("mfa_support") + }) + return _obj + + diff --git a/authentik_client/models/patched_ldap_source_property_mapping_request.py b/authentik_client/models/patched_ldap_source_property_mapping_request.py new file mode 100644 index 000000000..19bcdb855 --- /dev/null +++ b/authentik_client/models/patched_ldap_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedLDAPSourcePropertyMappingRequest(BaseModel): + """ + LDAP PropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedLDAPSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedLDAPSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_ldap_source_request.py b/authentik_client/models/patched_ldap_source_request.py new file mode 100644 index 000000000..4fc8fd5e9 --- /dev/null +++ b/authentik_client/models/patched_ldap_source_request.py @@ -0,0 +1,200 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.sync_outgoing_trigger_mode_enum import SyncOutgoingTriggerModeEnum +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedLDAPSourceRequest(BaseModel): + """ + LDAP Source Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Source's display Name.") + slug: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + server_uri: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + peer_certificate: Optional[UUID] = Field(default=None, description="Optionally verify the LDAP Server's Certificate against the CA Chain in this keypair.") + client_certificate: Optional[UUID] = Field(default=None, description="Client certificate to authenticate against the LDAP Server's Certificate.") + bind_cn: Optional[StrictStr] = None + bind_password: Optional[StrictStr] = None + start_tls: Optional[StrictBool] = None + sni: Optional[StrictBool] = None + base_dn: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + additional_user_dn: Optional[StrictStr] = Field(default=None, description="Prepended to Base DN for User-queries.") + additional_group_dn: Optional[StrictStr] = Field(default=None, description="Prepended to Base DN for Group-queries.") + user_object_filter: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Consider Objects matching this filter to be Users.") + group_object_filter: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Consider Objects matching this filter to be Groups.") + group_membership_field: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Field which contains members of a group.") + user_membership_attribute: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Attribute which matches the value of `group_membership_field`.") + object_uniqueness_field: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Field which contains a unique Identifier.") + password_login_update_internal_password: Optional[StrictBool] = Field(default=None, description="Update internal authentik password when login succeeds with LDAP") + sync_users: Optional[StrictBool] = None + sync_users_password: Optional[StrictBool] = Field(default=None, description="When a user changes their password, sync it back to LDAP. This can only be enabled on a single LDAP source.") + sync_groups: Optional[StrictBool] = None + sync_parent_group: Optional[UUID] = None + lookup_groups_from_user: Optional[StrictBool] = Field(default=None, description="Lookup group membership based on a user attribute instead of a group attribute. This allows nested group resolution on systems like FreeIPA and Active Directory") + delete_not_found_objects: Optional[StrictBool] = Field(default=None, description="Delete authentik users and groups which were previously supplied by this source, but are now missing from it.") + sync_outgoing_trigger_mode: Optional[SyncOutgoingTriggerModeEnum] = Field(default=None, description="When to trigger sync for outgoing providers") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "server_uri", "peer_certificate", "client_certificate", "bind_cn", "bind_password", "start_tls", "sni", "base_dn", "additional_user_dn", "additional_group_dn", "user_object_filter", "group_object_filter", "group_membership_field", "user_membership_attribute", "object_uniqueness_field", "password_login_update_internal_password", "sync_users", "sync_users_password", "sync_groups", "sync_parent_group", "lookup_groups_from_user", "delete_not_found_objects", "sync_outgoing_trigger_mode"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedLDAPSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if peer_certificate (nullable) is None + # and model_fields_set contains the field + if self.peer_certificate is None and "peer_certificate" in self.model_fields_set: + _dict['peer_certificate'] = None + + # set to None if client_certificate (nullable) is None + # and model_fields_set contains the field + if self.client_certificate is None and "client_certificate" in self.model_fields_set: + _dict['client_certificate'] = None + + # set to None if sync_parent_group (nullable) is None + # and model_fields_set contains the field + if self.sync_parent_group is None and "sync_parent_group" in self.model_fields_set: + _dict['sync_parent_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedLDAPSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "server_uri": obj.get("server_uri"), + "peer_certificate": obj.get("peer_certificate"), + "client_certificate": obj.get("client_certificate"), + "bind_cn": obj.get("bind_cn"), + "bind_password": obj.get("bind_password"), + "start_tls": obj.get("start_tls"), + "sni": obj.get("sni"), + "base_dn": obj.get("base_dn"), + "additional_user_dn": obj.get("additional_user_dn"), + "additional_group_dn": obj.get("additional_group_dn"), + "user_object_filter": obj.get("user_object_filter"), + "group_object_filter": obj.get("group_object_filter"), + "group_membership_field": obj.get("group_membership_field"), + "user_membership_attribute": obj.get("user_membership_attribute"), + "object_uniqueness_field": obj.get("object_uniqueness_field"), + "password_login_update_internal_password": obj.get("password_login_update_internal_password"), + "sync_users": obj.get("sync_users"), + "sync_users_password": obj.get("sync_users_password"), + "sync_groups": obj.get("sync_groups"), + "sync_parent_group": obj.get("sync_parent_group"), + "lookup_groups_from_user": obj.get("lookup_groups_from_user"), + "delete_not_found_objects": obj.get("delete_not_found_objects"), + "sync_outgoing_trigger_mode": obj.get("sync_outgoing_trigger_mode") + }) + return _obj + + diff --git a/authentik_client/models/patched_license_request.py b/authentik_client/models/patched_license_request.py new file mode 100644 index 000000000..f455b918f --- /dev/null +++ b/authentik_client/models/patched_license_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedLicenseRequest(BaseModel): + """ + License Serializer + """ # noqa: E501 + key: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["key"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedLicenseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedLicenseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "key": obj.get("key") + }) + return _obj + + diff --git a/authentik_client/models/patched_lifecycle_rule_request.py b/authentik_client/models/patched_lifecycle_rule_request.py new file mode 100644 index 000000000..bd6171c07 --- /dev/null +++ b/authentik_client/models/patched_lifecycle_rule_request.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.content_type_enum import ContentTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedLifecycleRuleRequest(BaseModel): + """ + Mixin to validate that a valid enterprise license exists before allowing to save the object + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + content_type: Optional[ContentTypeEnum] = None + object_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + interval: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + grace_period: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + reviewer_groups: Optional[List[UUID]] = None + min_reviewers: Optional[Annotated[int, Field(le=32767, strict=True, ge=0)]] = None + min_reviewers_is_per_group: Optional[StrictBool] = None + reviewers: Optional[List[UUID]] = None + notification_transports: Optional[List[UUID]] = Field(default=None, description="Select which transports should be used to notify the reviewers. If none are selected, the notification will only be shown in the authentik UI.") + __properties: ClassVar[List[str]] = ["name", "content_type", "object_id", "interval", "grace_period", "reviewer_groups", "min_reviewers", "min_reviewers_is_per_group", "reviewers", "notification_transports"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedLifecycleRuleRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if object_id (nullable) is None + # and model_fields_set contains the field + if self.object_id is None and "object_id" in self.model_fields_set: + _dict['object_id'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedLifecycleRuleRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "content_type": obj.get("content_type"), + "object_id": obj.get("object_id"), + "interval": obj.get("interval"), + "grace_period": obj.get("grace_period"), + "reviewer_groups": obj.get("reviewer_groups"), + "min_reviewers": obj.get("min_reviewers"), + "min_reviewers_is_per_group": obj.get("min_reviewers_is_per_group"), + "reviewers": obj.get("reviewers"), + "notification_transports": obj.get("notification_transports") + }) + return _obj + + diff --git a/authentik_client/models/patched_microsoft_entra_provider_mapping_request.py b/authentik_client/models/patched_microsoft_entra_provider_mapping_request.py new file mode 100644 index 000000000..2d96a609b --- /dev/null +++ b/authentik_client/models/patched_microsoft_entra_provider_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedMicrosoftEntraProviderMappingRequest(BaseModel): + """ + MicrosoftEntraProviderMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedMicrosoftEntraProviderMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedMicrosoftEntraProviderMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_microsoft_entra_provider_request.py b/authentik_client/models/patched_microsoft_entra_provider_request.py new file mode 100644 index 000000000..497da6f27 --- /dev/null +++ b/authentik_client/models/patched_microsoft_entra_provider_request.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.outgoing_sync_delete_action import OutgoingSyncDeleteAction +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedMicrosoftEntraProviderRequest(BaseModel): + """ + MicrosoftEntraProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + property_mappings: Optional[List[UUID]] = None + property_mappings_group: Optional[List[UUID]] = Field(default=None, description="Property mappings used for group creation/updating.") + client_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + client_secret: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + tenant_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + exclude_users_service_account: Optional[StrictBool] = None + filter_group: Optional[UUID] = None + user_delete_action: Optional[OutgoingSyncDeleteAction] = None + group_delete_action: Optional[OutgoingSyncDeleteAction] = None + sync_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Controls the number of objects synced in a single task") + sync_page_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Timeout for synchronization of a single page") + dry_run: Optional[StrictBool] = Field(default=None, description="When enabled, provider will not modify or create objects in the remote system.") + __properties: ClassVar[List[str]] = ["name", "property_mappings", "property_mappings_group", "client_id", "client_secret", "tenant_id", "exclude_users_service_account", "filter_group", "user_delete_action", "group_delete_action", "sync_page_size", "sync_page_timeout", "dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedMicrosoftEntraProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if filter_group (nullable) is None + # and model_fields_set contains the field + if self.filter_group is None and "filter_group" in self.model_fields_set: + _dict['filter_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedMicrosoftEntraProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "property_mappings": obj.get("property_mappings"), + "property_mappings_group": obj.get("property_mappings_group"), + "client_id": obj.get("client_id"), + "client_secret": obj.get("client_secret"), + "tenant_id": obj.get("tenant_id"), + "exclude_users_service_account": obj.get("exclude_users_service_account"), + "filter_group": obj.get("filter_group"), + "user_delete_action": obj.get("user_delete_action"), + "group_delete_action": obj.get("group_delete_action"), + "sync_page_size": obj.get("sync_page_size"), + "sync_page_timeout": obj.get("sync_page_timeout"), + "dry_run": obj.get("dry_run") + }) + return _obj + + diff --git a/authentik_client/models/patched_mutual_tls_stage_request.py b/authentik_client/models/patched_mutual_tls_stage_request.py new file mode 100644 index 000000000..3b465fccd --- /dev/null +++ b/authentik_client/models/patched_mutual_tls_stage_request.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.cert_attribute_enum import CertAttributeEnum +from authentik_client.models.stage_mode_enum import StageModeEnum +from authentik_client.models.user_attribute_enum import UserAttributeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedMutualTLSStageRequest(BaseModel): + """ + MutualTLSStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + mode: Optional[StageModeEnum] = None + certificate_authorities: Optional[List[UUID]] = Field(default=None, description="Configure certificate authorities to validate the certificate against. This option has a higher priority than the `client_certificate` option on `Brand`.") + cert_attribute: Optional[CertAttributeEnum] = None + user_attribute: Optional[UserAttributeEnum] = None + __properties: ClassVar[List[str]] = ["name", "mode", "certificate_authorities", "cert_attribute", "user_attribute"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedMutualTLSStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedMutualTLSStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "mode": obj.get("mode"), + "certificate_authorities": obj.get("certificate_authorities"), + "cert_attribute": obj.get("cert_attribute"), + "user_attribute": obj.get("user_attribute") + }) + return _obj + + diff --git a/authentik_client/models/patched_notification_request.py b/authentik_client/models/patched_notification_request.py new file mode 100644 index 000000000..459575317 --- /dev/null +++ b/authentik_client/models/patched_notification_request.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.event_request import EventRequest +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedNotificationRequest(BaseModel): + """ + Notification Serializer + """ # noqa: E501 + hyperlink: Optional[Annotated[str, Field(strict=True, max_length=4096)]] = None + hyperlink_label: Optional[StrictStr] = None + event: Optional[EventRequest] = None + seen: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["hyperlink", "hyperlink_label", "event", "seen"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedNotificationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of event + if self.event: + _dict['event'] = self.event.to_dict() + # set to None if hyperlink (nullable) is None + # and model_fields_set contains the field + if self.hyperlink is None and "hyperlink" in self.model_fields_set: + _dict['hyperlink'] = None + + # set to None if hyperlink_label (nullable) is None + # and model_fields_set contains the field + if self.hyperlink_label is None and "hyperlink_label" in self.model_fields_set: + _dict['hyperlink_label'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedNotificationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "hyperlink": obj.get("hyperlink"), + "hyperlink_label": obj.get("hyperlink_label"), + "event": EventRequest.from_dict(obj["event"]) if obj.get("event") is not None else None, + "seen": obj.get("seen") + }) + return _obj + + diff --git a/authentik_client/models/patched_notification_rule_request.py b/authentik_client/models/patched_notification_rule_request.py new file mode 100644 index 000000000..16c94c444 --- /dev/null +++ b/authentik_client/models/patched_notification_rule_request.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.severity_enum import SeverityEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedNotificationRuleRequest(BaseModel): + """ + NotificationRule Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + transports: Optional[List[UUID]] = Field(default=None, description="Select which transports should be used to notify the user. If none are selected, the notification will only be shown in the authentik UI.") + severity: Optional[SeverityEnum] = Field(default=None, description="Controls which severity level the created notifications will have.") + destination_group: Optional[UUID] = Field(default=None, description="Define which group of users this notification should be sent and shown to. If left empty, Notification won't ben sent.") + destination_event_user: Optional[StrictBool] = Field(default=None, description="When enabled, notification will be sent to user the user that triggered the event.When destination_group is configured, notification is sent to both.") + __properties: ClassVar[List[str]] = ["name", "transports", "severity", "destination_group", "destination_event_user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedNotificationRuleRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if destination_group (nullable) is None + # and model_fields_set contains the field + if self.destination_group is None and "destination_group" in self.model_fields_set: + _dict['destination_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedNotificationRuleRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "transports": obj.get("transports"), + "severity": obj.get("severity"), + "destination_group": obj.get("destination_group"), + "destination_event_user": obj.get("destination_event_user") + }) + return _obj + + diff --git a/authentik_client/models/patched_notification_transport_request.py b/authentik_client/models/patched_notification_transport_request.py new file mode 100644 index 000000000..fa7a8a3a1 --- /dev/null +++ b/authentik_client/models/patched_notification_transport_request.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.transport_mode_enum import TransportModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedNotificationTransportRequest(BaseModel): + """ + NotificationTransport Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + mode: Optional[TransportModeEnum] = None + webhook_url: Optional[StrictStr] = None + webhook_ca: Optional[UUID] = Field(default=None, description="When set, the selected certificate is used to validate the certificate of the webhook server.") + webhook_mapping_body: Optional[UUID] = Field(default=None, description="Customize the body of the request. Mapping should return data that is JSON-serializable.") + webhook_mapping_headers: Optional[UUID] = Field(default=None, description="Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs") + email_subject_prefix: Optional[StrictStr] = None + email_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + send_once: Optional[StrictBool] = Field(default=None, description="Only send notification once, for example when sending a webhook into a chat channel.") + __properties: ClassVar[List[str]] = ["name", "mode", "webhook_url", "webhook_ca", "webhook_mapping_body", "webhook_mapping_headers", "email_subject_prefix", "email_template", "send_once"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedNotificationTransportRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if webhook_ca (nullable) is None + # and model_fields_set contains the field + if self.webhook_ca is None and "webhook_ca" in self.model_fields_set: + _dict['webhook_ca'] = None + + # set to None if webhook_mapping_body (nullable) is None + # and model_fields_set contains the field + if self.webhook_mapping_body is None and "webhook_mapping_body" in self.model_fields_set: + _dict['webhook_mapping_body'] = None + + # set to None if webhook_mapping_headers (nullable) is None + # and model_fields_set contains the field + if self.webhook_mapping_headers is None and "webhook_mapping_headers" in self.model_fields_set: + _dict['webhook_mapping_headers'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedNotificationTransportRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "mode": obj.get("mode"), + "webhook_url": obj.get("webhook_url"), + "webhook_ca": obj.get("webhook_ca"), + "webhook_mapping_body": obj.get("webhook_mapping_body"), + "webhook_mapping_headers": obj.get("webhook_mapping_headers"), + "email_subject_prefix": obj.get("email_subject_prefix"), + "email_template": obj.get("email_template"), + "send_once": obj.get("send_once") + }) + return _obj + + diff --git a/authentik_client/models/patched_notification_webhook_mapping_request.py b/authentik_client/models/patched_notification_webhook_mapping_request.py new file mode 100644 index 000000000..bee0d2134 --- /dev/null +++ b/authentik_client/models/patched_notification_webhook_mapping_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedNotificationWebhookMappingRequest(BaseModel): + """ + NotificationWebhookMapping Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedNotificationWebhookMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedNotificationWebhookMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_o_auth2_provider_request.py b/authentik_client/models/patched_o_auth2_provider_request.py new file mode 100644 index 000000000..c483ee948 --- /dev/null +++ b/authentik_client/models/patched_o_auth2_provider_request.py @@ -0,0 +1,163 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.client_type_enum import ClientTypeEnum +from authentik_client.models.grant_types_enum import GrantTypesEnum +from authentik_client.models.issuer_mode_enum import IssuerModeEnum +from authentik_client.models.o_auth2_provider_logout_method_enum import OAuth2ProviderLogoutMethodEnum +from authentik_client.models.redirect_uri_request import RedirectURIRequest +from authentik_client.models.sub_mode_enum import SubModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedOAuth2ProviderRequest(BaseModel): + """ + OAuth2Provider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: Optional[UUID] = Field(default=None, description="Flow used when authorizing this provider.") + invalidation_flow: Optional[UUID] = Field(default=None, description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + client_type: Optional[ClientTypeEnum] = Field(default=None, description="Confidential clients are capable of maintaining the confidentiality of their credentials. Public clients are incapable") + grant_types: Optional[List[GrantTypesEnum]] = None + client_id: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=255)]] = None + client_secret: Optional[Annotated[str, Field(strict=True, max_length=255)]] = None + access_code_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Access codes not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + access_token_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + refresh_token_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + refresh_token_threshold: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="When refreshing a token, if the refresh token is valid for less than this duration, it will be renewed. When set to seconds=0, token will always be renewed. (Format: hours=1;minutes=2;seconds=3).") + include_claims_in_id_token: Optional[StrictBool] = Field(default=None, description="Include User claims from scopes in the id_token, for applications that don't access the userinfo endpoint.") + signing_key: Optional[UUID] = Field(default=None, description="Key used to sign the tokens.") + encryption_key: Optional[UUID] = Field(default=None, description="Key used to encrypt the tokens. When set, tokens will be encrypted and returned as JWEs.") + redirect_uris: Optional[List[RedirectURIRequest]] = None + logout_uri: Optional[StrictStr] = None + logout_method: Optional[OAuth2ProviderLogoutMethodEnum] = Field(default=None, description="Backchannel logs out with server to server calls. Frontchannel uses iframes in your browser") + sub_mode: Optional[SubModeEnum] = Field(default=None, description="Configure what data should be used as unique User Identifier. For most cases, the default should be fine.") + issuer_mode: Optional[IssuerModeEnum] = Field(default=None, description="Configure how the issuer field of the ID Token should be filled.") + jwt_federation_sources: Optional[List[UUID]] = None + jwt_federation_providers: Optional[List[StrictInt]] = None + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "client_type", "grant_types", "client_id", "client_secret", "access_code_validity", "access_token_validity", "refresh_token_validity", "refresh_token_threshold", "include_claims_in_id_token", "signing_key", "encryption_key", "redirect_uris", "logout_uri", "logout_method", "sub_mode", "issuer_mode", "jwt_federation_sources", "jwt_federation_providers"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedOAuth2ProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in redirect_uris (list) + _items = [] + if self.redirect_uris: + for _item_redirect_uris in self.redirect_uris: + if _item_redirect_uris: + _items.append(_item_redirect_uris.to_dict()) + _dict['redirect_uris'] = _items + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if signing_key (nullable) is None + # and model_fields_set contains the field + if self.signing_key is None and "signing_key" in self.model_fields_set: + _dict['signing_key'] = None + + # set to None if encryption_key (nullable) is None + # and model_fields_set contains the field + if self.encryption_key is None and "encryption_key" in self.model_fields_set: + _dict['encryption_key'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedOAuth2ProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "client_type": obj.get("client_type"), + "grant_types": obj.get("grant_types"), + "client_id": obj.get("client_id"), + "client_secret": obj.get("client_secret"), + "access_code_validity": obj.get("access_code_validity"), + "access_token_validity": obj.get("access_token_validity"), + "refresh_token_validity": obj.get("refresh_token_validity"), + "refresh_token_threshold": obj.get("refresh_token_threshold"), + "include_claims_in_id_token": obj.get("include_claims_in_id_token"), + "signing_key": obj.get("signing_key"), + "encryption_key": obj.get("encryption_key"), + "redirect_uris": [RedirectURIRequest.from_dict(_item) for _item in obj["redirect_uris"]] if obj.get("redirect_uris") is not None else None, + "logout_uri": obj.get("logout_uri"), + "logout_method": obj.get("logout_method"), + "sub_mode": obj.get("sub_mode"), + "issuer_mode": obj.get("issuer_mode"), + "jwt_federation_sources": obj.get("jwt_federation_sources"), + "jwt_federation_providers": obj.get("jwt_federation_providers") + }) + return _obj + + diff --git a/authentik_client/models/patched_o_auth_source_property_mapping_request.py b/authentik_client/models/patched_o_auth_source_property_mapping_request.py new file mode 100644 index 000000000..01d2b4892 --- /dev/null +++ b/authentik_client/models/patched_o_auth_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedOAuthSourcePropertyMappingRequest(BaseModel): + """ + OAuthSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedOAuthSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedOAuthSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_o_auth_source_request.py b/authentik_client/models/patched_o_auth_source_request.py new file mode 100644 index 000000000..7c56c87f2 --- /dev/null +++ b/authentik_client/models/patched_o_auth_source_request.py @@ -0,0 +1,190 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.authorization_code_auth_method_enum import AuthorizationCodeAuthMethodEnum +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.pkce_method_enum import PKCEMethodEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.provider_type_enum import ProviderTypeEnum +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedOAuthSourceRequest(BaseModel): + """ + OAuth Source Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Source's display Name.") + slug: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + provider_type: Optional[ProviderTypeEnum] = None + request_token_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL used to request the initial token. This URL is only required for OAuth 1.") + authorization_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL the user is redirect to to conest the flow.") + access_token_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL used by authentik to retrieve tokens.") + profile_url: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(default=None, description="URL used by authentik to get user information.") + pkce: Optional[PKCEMethodEnum] = None + consumer_key: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + consumer_secret: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + additional_scopes: Optional[StrictStr] = None + oidc_well_known_url: Optional[StrictStr] = None + oidc_jwks_url: Optional[StrictStr] = None + oidc_jwks: Optional[Dict[str, Any]] = None + authorization_code_auth_method: Optional[AuthorizationCodeAuthMethodEnum] = Field(default=None, description="How to perform authentication during an authorization_code token request flow") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "group_matching_mode", "provider_type", "request_token_url", "authorization_url", "access_token_url", "profile_url", "pkce", "consumer_key", "consumer_secret", "additional_scopes", "oidc_well_known_url", "oidc_jwks_url", "oidc_jwks", "authorization_code_auth_method"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedOAuthSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if request_token_url (nullable) is None + # and model_fields_set contains the field + if self.request_token_url is None and "request_token_url" in self.model_fields_set: + _dict['request_token_url'] = None + + # set to None if authorization_url (nullable) is None + # and model_fields_set contains the field + if self.authorization_url is None and "authorization_url" in self.model_fields_set: + _dict['authorization_url'] = None + + # set to None if access_token_url (nullable) is None + # and model_fields_set contains the field + if self.access_token_url is None and "access_token_url" in self.model_fields_set: + _dict['access_token_url'] = None + + # set to None if profile_url (nullable) is None + # and model_fields_set contains the field + if self.profile_url is None and "profile_url" in self.model_fields_set: + _dict['profile_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedOAuthSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "group_matching_mode": obj.get("group_matching_mode"), + "provider_type": obj.get("provider_type"), + "request_token_url": obj.get("request_token_url"), + "authorization_url": obj.get("authorization_url"), + "access_token_url": obj.get("access_token_url"), + "profile_url": obj.get("profile_url"), + "pkce": obj.get("pkce"), + "consumer_key": obj.get("consumer_key"), + "consumer_secret": obj.get("consumer_secret"), + "additional_scopes": obj.get("additional_scopes"), + "oidc_well_known_url": obj.get("oidc_well_known_url"), + "oidc_jwks_url": obj.get("oidc_jwks_url"), + "oidc_jwks": obj.get("oidc_jwks"), + "authorization_code_auth_method": obj.get("authorization_code_auth_method") + }) + return _obj + + diff --git a/authentik_client/models/patched_outpost_request.py b/authentik_client/models/patched_outpost_request.py new file mode 100644 index 000000000..cd97f5207 --- /dev/null +++ b/authentik_client/models/patched_outpost_request.py @@ -0,0 +1,112 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.outpost_type_enum import OutpostTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedOutpostRequest(BaseModel): + """ + Outpost Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + type: Optional[OutpostTypeEnum] = None + providers: Optional[List[StrictInt]] = None + service_connection: Optional[UUID] = Field(default=None, description="Select Service-Connection authentik should use to manage this outpost. Leave empty if authentik should not handle the deployment.") + config: Optional[Dict[str, Any]] = None + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + __properties: ClassVar[List[str]] = ["name", "type", "providers", "service_connection", "config", "managed"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedOutpostRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if service_connection (nullable) is None + # and model_fields_set contains the field + if self.service_connection is None and "service_connection" in self.model_fields_set: + _dict['service_connection'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedOutpostRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "type": obj.get("type"), + "providers": obj.get("providers"), + "service_connection": obj.get("service_connection"), + "config": obj.get("config"), + "managed": obj.get("managed") + }) + return _obj + + diff --git a/authentik_client/models/patched_password_expiry_policy_request.py b/authentik_client/models/patched_password_expiry_policy_request.py new file mode 100644 index 000000000..4ed115ddc --- /dev/null +++ b/authentik_client/models/patched_password_expiry_policy_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedPasswordExpiryPolicyRequest(BaseModel): + """ + Password Expiry Policy Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + days: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + deny_only: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "days", "deny_only"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedPasswordExpiryPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedPasswordExpiryPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "days": obj.get("days"), + "deny_only": obj.get("deny_only") + }) + return _obj + + diff --git a/authentik_client/models/patched_password_policy_request.py b/authentik_client/models/patched_password_policy_request.py new file mode 100644 index 000000000..a131d763c --- /dev/null +++ b/authentik_client/models/patched_password_policy_request.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedPasswordPolicyRequest(BaseModel): + """ + Password Policy Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + password_field: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Field key to check, field keys defined in Prompt stages are available.") + amount_digits: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + amount_uppercase: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + amount_lowercase: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + amount_symbols: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + length_min: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = None + symbol_charset: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + error_message: Optional[StrictStr] = None + check_static_rules: Optional[StrictBool] = None + check_have_i_been_pwned: Optional[StrictBool] = None + check_zxcvbn: Optional[StrictBool] = None + hibp_allowed_count: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="How many times the password hash is allowed to be on haveibeenpwned") + zxcvbn_score_threshold: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="If the zxcvbn score is equal or less than this value, the policy will fail.") + __properties: ClassVar[List[str]] = ["name", "execution_logging", "password_field", "amount_digits", "amount_uppercase", "amount_lowercase", "amount_symbols", "length_min", "symbol_charset", "error_message", "check_static_rules", "check_have_i_been_pwned", "check_zxcvbn", "hibp_allowed_count", "zxcvbn_score_threshold"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedPasswordPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedPasswordPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "password_field": obj.get("password_field"), + "amount_digits": obj.get("amount_digits"), + "amount_uppercase": obj.get("amount_uppercase"), + "amount_lowercase": obj.get("amount_lowercase"), + "amount_symbols": obj.get("amount_symbols"), + "length_min": obj.get("length_min"), + "symbol_charset": obj.get("symbol_charset"), + "error_message": obj.get("error_message"), + "check_static_rules": obj.get("check_static_rules"), + "check_have_i_been_pwned": obj.get("check_have_i_been_pwned"), + "check_zxcvbn": obj.get("check_zxcvbn"), + "hibp_allowed_count": obj.get("hibp_allowed_count"), + "zxcvbn_score_threshold": obj.get("zxcvbn_score_threshold") + }) + return _obj + + diff --git a/authentik_client/models/patched_password_stage_request.py b/authentik_client/models/patched_password_stage_request.py new file mode 100644 index 000000000..64a57cd4b --- /dev/null +++ b/authentik_client/models/patched_password_stage_request.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.backends_enum import BackendsEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedPasswordStageRequest(BaseModel): + """ + PasswordStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + backends: Optional[List[BackendsEnum]] = Field(default=None, description="Selection of backends to test the password against.") + configure_flow: Optional[UUID] = Field(default=None, description="Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage.") + failed_attempts_before_cancel: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = Field(default=None, description="How many attempts a user has before the flow is canceled. To lock the user out, use a reputation policy and a user_write stage.") + allow_show_password: Optional[StrictBool] = Field(default=None, description="When enabled, provides a 'show password' button with the password input field.") + __properties: ClassVar[List[str]] = ["name", "backends", "configure_flow", "failed_attempts_before_cancel", "allow_show_password"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedPasswordStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if configure_flow (nullable) is None + # and model_fields_set contains the field + if self.configure_flow is None and "configure_flow" in self.model_fields_set: + _dict['configure_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedPasswordStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "backends": obj.get("backends"), + "configure_flow": obj.get("configure_flow"), + "failed_attempts_before_cancel": obj.get("failed_attempts_before_cancel"), + "allow_show_password": obj.get("allow_show_password") + }) + return _obj + + diff --git a/authentik_client/models/patched_permission_assign_request.py b/authentik_client/models/patched_permission_assign_request.py new file mode 100644 index 000000000..38b46bd73 --- /dev/null +++ b/authentik_client/models/patched_permission_assign_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.model_enum import ModelEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedPermissionAssignRequest(BaseModel): + """ + Request to assign a new permission + """ # noqa: E501 + permissions: Optional[List[Annotated[str, Field(min_length=1, strict=True)]]] = None + model: Optional[ModelEnum] = None + object_pk: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["permissions", "model", "object_pk"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedPermissionAssignRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedPermissionAssignRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "permissions": obj.get("permissions"), + "model": obj.get("model"), + "object_pk": obj.get("object_pk") + }) + return _obj + + diff --git a/authentik_client/models/patched_plex_source_property_mapping_request.py b/authentik_client/models/patched_plex_source_property_mapping_request.py new file mode 100644 index 000000000..d252a5d4e --- /dev/null +++ b/authentik_client/models/patched_plex_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedPlexSourcePropertyMappingRequest(BaseModel): + """ + PlexSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedPlexSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedPlexSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_plex_source_request.py b/authentik_client/models/patched_plex_source_request.py new file mode 100644 index 000000000..4e978da92 --- /dev/null +++ b/authentik_client/models/patched_plex_source_request.py @@ -0,0 +1,149 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedPlexSourceRequest(BaseModel): + """ + Plex Source Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Source's display Name.") + slug: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + client_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Client identifier used to talk to Plex.") + allowed_servers: Optional[List[Annotated[str, Field(min_length=1, strict=True)]]] = Field(default=None, description="Which servers a user has to be a member of to be granted access. Empty list allows every server.") + allow_friends: Optional[StrictBool] = Field(default=None, description="Allow friends to authenticate, even if you don't share a server.") + plex_token: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Plex token used to check friends") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "group_matching_mode", "client_id", "allowed_servers", "allow_friends", "plex_token"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedPlexSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedPlexSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "group_matching_mode": obj.get("group_matching_mode"), + "client_id": obj.get("client_id"), + "allowed_servers": obj.get("allowed_servers"), + "allow_friends": obj.get("allow_friends"), + "plex_token": obj.get("plex_token") + }) + return _obj + + diff --git a/authentik_client/models/patched_policy_binding_request.py b/authentik_client/models/patched_policy_binding_request.py new file mode 100644 index 000000000..52f53c6f9 --- /dev/null +++ b/authentik_client/models/patched_policy_binding_request.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedPolicyBindingRequest(BaseModel): + """ + PolicyBinding Serializer + """ # noqa: E501 + policy: Optional[UUID] = None + group: Optional[UUID] = None + user: Optional[StrictInt] = None + target: Optional[UUID] = None + negate: Optional[StrictBool] = Field(default=None, description="Negates the outcome of the policy. Messages are unaffected.") + enabled: Optional[StrictBool] = None + order: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Timeout after which Policy execution is terminated.") + failure_result: Optional[StrictBool] = Field(default=None, description="Result if the Policy execution fails.") + __properties: ClassVar[List[str]] = ["policy", "group", "user", "target", "negate", "enabled", "order", "timeout", "failure_result"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedPolicyBindingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if policy (nullable) is None + # and model_fields_set contains the field + if self.policy is None and "policy" in self.model_fields_set: + _dict['policy'] = None + + # set to None if group (nullable) is None + # and model_fields_set contains the field + if self.group is None and "group" in self.model_fields_set: + _dict['group'] = None + + # set to None if user (nullable) is None + # and model_fields_set contains the field + if self.user is None and "user" in self.model_fields_set: + _dict['user'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedPolicyBindingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "policy": obj.get("policy"), + "group": obj.get("group"), + "user": obj.get("user"), + "target": obj.get("target"), + "negate": obj.get("negate"), + "enabled": obj.get("enabled"), + "order": obj.get("order"), + "timeout": obj.get("timeout"), + "failure_result": obj.get("failure_result") + }) + return _obj + + diff --git a/authentik_client/models/patched_prompt_request.py b/authentik_client/models/patched_prompt_request.py new file mode 100644 index 000000000..afec879c9 --- /dev/null +++ b/authentik_client/models/patched_prompt_request.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.prompt_type_enum import PromptTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedPromptRequest(BaseModel): + """ + Prompt Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + field_key: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Name of the form field, also used to store the value") + label: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + type: Optional[PromptTypeEnum] = None + required: Optional[StrictBool] = None + placeholder: Optional[StrictStr] = Field(default=None, description="Optionally provide a short hint that describes the expected input value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple choices.") + initial_value: Optional[StrictStr] = Field(default=None, description="Optionally pre-fill the input with an initial value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple default choices.") + order: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + sub_text: Optional[StrictStr] = None + placeholder_expression: Optional[StrictBool] = None + initial_value_expression: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "field_key", "label", "type", "required", "placeholder", "initial_value", "order", "sub_text", "placeholder_expression", "initial_value_expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedPromptRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedPromptRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "field_key": obj.get("field_key"), + "label": obj.get("label"), + "type": obj.get("type"), + "required": obj.get("required"), + "placeholder": obj.get("placeholder"), + "initial_value": obj.get("initial_value"), + "order": obj.get("order"), + "sub_text": obj.get("sub_text"), + "placeholder_expression": obj.get("placeholder_expression"), + "initial_value_expression": obj.get("initial_value_expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_prompt_stage_request.py b/authentik_client/models/patched_prompt_stage_request.py new file mode 100644 index 000000000..5e95c12ff --- /dev/null +++ b/authentik_client/models/patched_prompt_stage_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedPromptStageRequest(BaseModel): + """ + PromptStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + fields: Optional[List[UUID]] = None + validation_policies: Optional[List[UUID]] = None + __properties: ClassVar[List[str]] = ["name", "fields", "validation_policies"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedPromptStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedPromptStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "fields": obj.get("fields"), + "validation_policies": obj.get("validation_policies") + }) + return _obj + + diff --git a/authentik_client/models/patched_proxy_provider_request.py b/authentik_client/models/patched_proxy_provider_request.py new file mode 100644 index 000000000..e9f7a24dc --- /dev/null +++ b/authentik_client/models/patched_proxy_provider_request.py @@ -0,0 +1,140 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.proxy_mode import ProxyMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedProxyProviderRequest(BaseModel): + """ + ProxyProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: Optional[UUID] = Field(default=None, description="Flow used when authorizing this provider.") + invalidation_flow: Optional[UUID] = Field(default=None, description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + internal_host: Optional[StrictStr] = None + external_host: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + internal_host_ssl_validation: Optional[StrictBool] = Field(default=None, description="Validate SSL Certificates of upstream servers") + certificate: Optional[UUID] = None + skip_path_regex: Optional[StrictStr] = Field(default=None, description="Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression.") + basic_auth_enabled: Optional[StrictBool] = Field(default=None, description="Set a custom HTTP-Basic Authentication header based on values from authentik.") + basic_auth_password_attribute: Optional[StrictStr] = Field(default=None, description="User/Group Attribute used for the password part of the HTTP-Basic Header.") + basic_auth_user_attribute: Optional[StrictStr] = Field(default=None, description="User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used.") + mode: Optional[ProxyMode] = Field(default=None, description="Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host.") + intercept_header_auth: Optional[StrictBool] = Field(default=None, description="When enabled, this provider will intercept the authorization header and authenticate requests based on its value.") + cookie_domain: Optional[StrictStr] = None + jwt_federation_sources: Optional[List[UUID]] = None + jwt_federation_providers: Optional[List[StrictInt]] = None + access_token_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + refresh_token_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "internal_host", "external_host", "internal_host_ssl_validation", "certificate", "skip_path_regex", "basic_auth_enabled", "basic_auth_password_attribute", "basic_auth_user_attribute", "mode", "intercept_header_auth", "cookie_domain", "jwt_federation_sources", "jwt_federation_providers", "access_token_validity", "refresh_token_validity"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedProxyProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedProxyProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "internal_host": obj.get("internal_host"), + "external_host": obj.get("external_host"), + "internal_host_ssl_validation": obj.get("internal_host_ssl_validation"), + "certificate": obj.get("certificate"), + "skip_path_regex": obj.get("skip_path_regex"), + "basic_auth_enabled": obj.get("basic_auth_enabled"), + "basic_auth_password_attribute": obj.get("basic_auth_password_attribute"), + "basic_auth_user_attribute": obj.get("basic_auth_user_attribute"), + "mode": obj.get("mode"), + "intercept_header_auth": obj.get("intercept_header_auth"), + "cookie_domain": obj.get("cookie_domain"), + "jwt_federation_sources": obj.get("jwt_federation_sources"), + "jwt_federation_providers": obj.get("jwt_federation_providers"), + "access_token_validity": obj.get("access_token_validity"), + "refresh_token_validity": obj.get("refresh_token_validity") + }) + return _obj + + diff --git a/authentik_client/models/patched_rac_property_mapping_request.py b/authentik_client/models/patched_rac_property_mapping_request.py new file mode 100644 index 000000000..c47b36d71 --- /dev/null +++ b/authentik_client/models/patched_rac_property_mapping_request.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedRACPropertyMappingRequest(BaseModel): + """ + RACPropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[StrictStr] = None + static_settings: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression", "static_settings"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedRACPropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedRACPropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "static_settings": obj.get("static_settings") + }) + return _obj + + diff --git a/authentik_client/models/patched_rac_provider_request.py b/authentik_client/models/patched_rac_provider_request.py new file mode 100644 index 000000000..c24a1ddda --- /dev/null +++ b/authentik_client/models/patched_rac_provider_request.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedRACProviderRequest(BaseModel): + """ + RACProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: Optional[UUID] = Field(default=None, description="Flow used when authorizing this provider.") + property_mappings: Optional[List[UUID]] = None + settings: Optional[Dict[str, Any]] = None + connection_expiry: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)") + delete_token_on_disconnect: Optional[StrictBool] = Field(default=None, description="When set to true, connection tokens will be deleted upon disconnect.") + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "property_mappings", "settings", "connection_expiry", "delete_token_on_disconnect"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedRACProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedRACProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "property_mappings": obj.get("property_mappings"), + "settings": obj.get("settings"), + "connection_expiry": obj.get("connection_expiry"), + "delete_token_on_disconnect": obj.get("delete_token_on_disconnect") + }) + return _obj + + diff --git a/authentik_client/models/patched_radius_provider_property_mapping_request.py b/authentik_client/models/patched_radius_provider_property_mapping_request.py new file mode 100644 index 000000000..4ed9d06ff --- /dev/null +++ b/authentik_client/models/patched_radius_provider_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedRadiusProviderPropertyMappingRequest(BaseModel): + """ + RadiusProviderPropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedRadiusProviderPropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedRadiusProviderPropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_radius_provider_request.py b/authentik_client/models/patched_radius_provider_request.py new file mode 100644 index 000000000..abcf08f2d --- /dev/null +++ b/authentik_client/models/patched_radius_provider_request.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedRadiusProviderRequest(BaseModel): + """ + RadiusProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: Optional[UUID] = Field(default=None, description="Flow used when authorizing this provider.") + invalidation_flow: Optional[UUID] = Field(default=None, description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + client_networks: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="List of CIDRs (comma-separated) that clients can connect from. A more specific CIDR will match before a looser one. Clients connecting from a non-specified CIDR will be dropped.") + shared_secret: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Shared secret between clients and server to hash packets.") + mfa_support: Optional[StrictBool] = Field(default=None, description="When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.") + certificate: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "client_networks", "shared_secret", "mfa_support", "certificate"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedRadiusProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedRadiusProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "client_networks": obj.get("client_networks"), + "shared_secret": obj.get("shared_secret"), + "mfa_support": obj.get("mfa_support"), + "certificate": obj.get("certificate") + }) + return _obj + + diff --git a/authentik_client/models/patched_redirect_stage_request.py b/authentik_client/models/patched_redirect_stage_request.py new file mode 100644 index 000000000..b382fcc54 --- /dev/null +++ b/authentik_client/models/patched_redirect_stage_request.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.redirect_stage_mode_enum import RedirectStageModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedRedirectStageRequest(BaseModel): + """ + RedirectStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + keep_context: Optional[StrictBool] = None + mode: Optional[RedirectStageModeEnum] = None + target_static: Optional[StrictStr] = None + target_flow: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["name", "keep_context", "mode", "target_static", "target_flow"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedRedirectStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if target_flow (nullable) is None + # and model_fields_set contains the field + if self.target_flow is None and "target_flow" in self.model_fields_set: + _dict['target_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedRedirectStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "keep_context": obj.get("keep_context"), + "mode": obj.get("mode"), + "target_static": obj.get("target_static"), + "target_flow": obj.get("target_flow") + }) + return _obj + + diff --git a/authentik_client/models/patched_reputation_policy_request.py b/authentik_client/models/patched_reputation_policy_request.py new file mode 100644 index 000000000..20c849d2b --- /dev/null +++ b/authentik_client/models/patched_reputation_policy_request.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedReputationPolicyRequest(BaseModel): + """ + Reputation Policy Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + check_ip: Optional[StrictBool] = None + check_username: Optional[StrictBool] = None + threshold: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "check_ip", "check_username", "threshold"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedReputationPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedReputationPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "check_ip": obj.get("check_ip"), + "check_username": obj.get("check_username"), + "threshold": obj.get("threshold") + }) + return _obj + + diff --git a/authentik_client/models/patched_role_request.py b/authentik_client/models/patched_role_request.py new file mode 100644 index 000000000..be770a65b --- /dev/null +++ b/authentik_client/models/patched_role_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedRoleRequest(BaseModel): + """ + Role serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedRoleRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedRoleRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_saml_property_mapping_request.py b/authentik_client/models/patched_saml_property_mapping_request.py new file mode 100644 index 000000000..859b93e12 --- /dev/null +++ b/authentik_client/models/patched_saml_property_mapping_request.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSAMLPropertyMappingRequest(BaseModel): + """ + SAMLPropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + saml_name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + friendly_name: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression", "saml_name", "friendly_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSAMLPropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if friendly_name (nullable) is None + # and model_fields_set contains the field + if self.friendly_name is None and "friendly_name" in self.model_fields_set: + _dict['friendly_name'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSAMLPropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "saml_name": obj.get("saml_name"), + "friendly_name": obj.get("friendly_name") + }) + return _obj + + diff --git a/authentik_client/models/patched_saml_provider_request.py b/authentik_client/models/patched_saml_provider_request.py new file mode 100644 index 000000000..a1fd7460b --- /dev/null +++ b/authentik_client/models/patched_saml_provider_request.py @@ -0,0 +1,180 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.saml_bindings_enum import SAMLBindingsEnum +from authentik_client.models.saml_logout_methods import SAMLLogoutMethods +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSAMLProviderRequest(BaseModel): + """ + SAMLProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: Optional[UUID] = Field(default=None, description="Flow used when authorizing this provider.") + invalidation_flow: Optional[UUID] = Field(default=None, description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + acs_url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + sls_url: Optional[StrictStr] = Field(default=None, description="Single Logout Service URL where the logout response should be sent.") + audience: Optional[StrictStr] = Field(default=None, description="Value of the audience restriction field of the assertion. When left empty, no audience restriction will be added.") + issuer_override: Optional[StrictStr] = Field(default=None, description="Also known as EntityID. Providing a value overrides the default issuer generated by authentik.") + assertion_valid_not_before: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3).") + assertion_valid_not_on_or_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + session_valid_not_on_or_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + name_id_mapping: Optional[UUID] = Field(default=None, description="Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered") + authn_context_class_ref_mapping: Optional[UUID] = Field(default=None, description="Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate.") + digest_algorithm: Optional[DigestAlgorithmEnum] = None + signature_algorithm: Optional[SignatureAlgorithmEnum] = None + signing_kp: Optional[UUID] = Field(default=None, description="Keypair used to sign outgoing Responses going to the Service Provider.") + verification_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default.") + encryption_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key.") + sign_assertion: Optional[StrictBool] = None + sign_response: Optional[StrictBool] = None + sign_logout_request: Optional[StrictBool] = None + sign_logout_response: Optional[StrictBool] = None + sp_binding: Optional[SAMLBindingsEnum] = Field(default=None, description="This determines how authentik sends the response back to the Service Provider.") + sls_binding: Optional[SAMLBindingsEnum] = Field(default=None, description="This determines how authentik sends the logout response back to the Service Provider.") + logout_method: Optional[SAMLLogoutMethods] = Field(default=None, description="Method to use for logout. Front-channel iframe loads all logout URLs simultaneously in hidden iframes. Front-channel native uses your active browser tab to send post requests and redirect to providers. Back-channel sends logout requests directly from the server without user interaction (requires POST SLS binding).") + default_relay_state: Optional[StrictStr] = Field(default=None, description="Default relay_state value for IDP-initiated logins") + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "acs_url", "sls_url", "audience", "issuer_override", "assertion_valid_not_before", "assertion_valid_not_on_or_after", "session_valid_not_on_or_after", "name_id_mapping", "authn_context_class_ref_mapping", "digest_algorithm", "signature_algorithm", "signing_kp", "verification_kp", "encryption_kp", "sign_assertion", "sign_response", "sign_logout_request", "sign_logout_response", "sp_binding", "sls_binding", "logout_method", "default_relay_state", "default_name_id_policy"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSAMLProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if name_id_mapping (nullable) is None + # and model_fields_set contains the field + if self.name_id_mapping is None and "name_id_mapping" in self.model_fields_set: + _dict['name_id_mapping'] = None + + # set to None if authn_context_class_ref_mapping (nullable) is None + # and model_fields_set contains the field + if self.authn_context_class_ref_mapping is None and "authn_context_class_ref_mapping" in self.model_fields_set: + _dict['authn_context_class_ref_mapping'] = None + + # set to None if signing_kp (nullable) is None + # and model_fields_set contains the field + if self.signing_kp is None and "signing_kp" in self.model_fields_set: + _dict['signing_kp'] = None + + # set to None if verification_kp (nullable) is None + # and model_fields_set contains the field + if self.verification_kp is None and "verification_kp" in self.model_fields_set: + _dict['verification_kp'] = None + + # set to None if encryption_kp (nullable) is None + # and model_fields_set contains the field + if self.encryption_kp is None and "encryption_kp" in self.model_fields_set: + _dict['encryption_kp'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSAMLProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "acs_url": obj.get("acs_url"), + "sls_url": obj.get("sls_url"), + "audience": obj.get("audience"), + "issuer_override": obj.get("issuer_override"), + "assertion_valid_not_before": obj.get("assertion_valid_not_before"), + "assertion_valid_not_on_or_after": obj.get("assertion_valid_not_on_or_after"), + "session_valid_not_on_or_after": obj.get("session_valid_not_on_or_after"), + "name_id_mapping": obj.get("name_id_mapping"), + "authn_context_class_ref_mapping": obj.get("authn_context_class_ref_mapping"), + "digest_algorithm": obj.get("digest_algorithm"), + "signature_algorithm": obj.get("signature_algorithm"), + "signing_kp": obj.get("signing_kp"), + "verification_kp": obj.get("verification_kp"), + "encryption_kp": obj.get("encryption_kp"), + "sign_assertion": obj.get("sign_assertion"), + "sign_response": obj.get("sign_response"), + "sign_logout_request": obj.get("sign_logout_request"), + "sign_logout_response": obj.get("sign_logout_response"), + "sp_binding": obj.get("sp_binding"), + "sls_binding": obj.get("sls_binding"), + "logout_method": obj.get("logout_method"), + "default_relay_state": obj.get("default_relay_state"), + "default_name_id_policy": obj.get("default_name_id_policy") + }) + return _obj + + diff --git a/authentik_client/models/patched_saml_source_property_mapping_request.py b/authentik_client/models/patched_saml_source_property_mapping_request.py new file mode 100644 index 000000000..5430df98b --- /dev/null +++ b/authentik_client/models/patched_saml_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSAMLSourcePropertyMappingRequest(BaseModel): + """ + SAMLSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSAMLSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSAMLSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_saml_source_request.py b/authentik_client/models/patched_saml_source_request.py new file mode 100644 index 000000000..33a2d1f97 --- /dev/null +++ b/authentik_client/models/patched_saml_source_request.py @@ -0,0 +1,197 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.binding_type_enum import BindingTypeEnum +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSAMLSourceRequest(BaseModel): + """ + SAMLSource Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Source's display Name.") + slug: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + pre_authentication_flow: Optional[UUID] = Field(default=None, description="Flow used before authentication.") + issuer: Optional[StrictStr] = Field(default=None, description="Also known as Entity ID. Defaults the Metadata URL.") + sso_url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="URL that the initial Login request is sent to.") + slo_url: Optional[StrictStr] = Field(default=None, description="Optional URL if your IDP supports Single-Logout.") + allow_idp_initiated: Optional[StrictBool] = Field(default=None, description="Allows authentication flows initiated by the IdP. This can be a security risk, as no validation of the request ID is done.") + force_authn: Optional[StrictBool] = Field(default=None, description="When enabled, the IdP will re-authenticate the user even if a session exists.") + name_id_policy: Optional[SAMLNameIDPolicyEnum] = Field(default=None, description="NameID Policy sent to the IdP. Can be unset, in which case no Policy is sent.") + binding_type: Optional[BindingTypeEnum] = None + verification_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default.") + signing_kp: Optional[UUID] = Field(default=None, description="Keypair used to sign outgoing Responses going to the Identity Provider.") + digest_algorithm: Optional[DigestAlgorithmEnum] = None + signature_algorithm: Optional[SignatureAlgorithmEnum] = None + temporary_user_delete_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Time offset when temporary users should be deleted. This only applies if your IDP uses the NameID Format 'transient', and the user doesn't log out manually. (Format: hours=1;minutes=2;seconds=3).") + encryption_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key.") + signed_assertion: Optional[StrictBool] = None + signed_response: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "group_matching_mode", "pre_authentication_flow", "issuer", "sso_url", "slo_url", "allow_idp_initiated", "force_authn", "name_id_policy", "binding_type", "verification_kp", "signing_kp", "digest_algorithm", "signature_algorithm", "temporary_user_delete_after", "encryption_kp", "signed_assertion", "signed_response"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSAMLSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if slo_url (nullable) is None + # and model_fields_set contains the field + if self.slo_url is None and "slo_url" in self.model_fields_set: + _dict['slo_url'] = None + + # set to None if verification_kp (nullable) is None + # and model_fields_set contains the field + if self.verification_kp is None and "verification_kp" in self.model_fields_set: + _dict['verification_kp'] = None + + # set to None if signing_kp (nullable) is None + # and model_fields_set contains the field + if self.signing_kp is None and "signing_kp" in self.model_fields_set: + _dict['signing_kp'] = None + + # set to None if encryption_kp (nullable) is None + # and model_fields_set contains the field + if self.encryption_kp is None and "encryption_kp" in self.model_fields_set: + _dict['encryption_kp'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSAMLSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "group_matching_mode": obj.get("group_matching_mode"), + "pre_authentication_flow": obj.get("pre_authentication_flow"), + "issuer": obj.get("issuer"), + "sso_url": obj.get("sso_url"), + "slo_url": obj.get("slo_url"), + "allow_idp_initiated": obj.get("allow_idp_initiated"), + "force_authn": obj.get("force_authn"), + "name_id_policy": obj.get("name_id_policy"), + "binding_type": obj.get("binding_type"), + "verification_kp": obj.get("verification_kp"), + "signing_kp": obj.get("signing_kp"), + "digest_algorithm": obj.get("digest_algorithm"), + "signature_algorithm": obj.get("signature_algorithm"), + "temporary_user_delete_after": obj.get("temporary_user_delete_after"), + "encryption_kp": obj.get("encryption_kp"), + "signed_assertion": obj.get("signed_assertion"), + "signed_response": obj.get("signed_response") + }) + return _obj + + diff --git a/authentik_client/models/patched_schedule_request.py b/authentik_client/models/patched_schedule_request.py new file mode 100644 index 000000000..ead053b4c --- /dev/null +++ b/authentik_client/models/patched_schedule_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedScheduleRequest(BaseModel): + """ + PatchedScheduleRequest + """ # noqa: E501 + rel_obj_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + crontab: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="When to schedule tasks") + paused: Optional[StrictBool] = Field(default=None, description="Pause this schedule") + __properties: ClassVar[List[str]] = ["rel_obj_id", "crontab", "paused"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedScheduleRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if rel_obj_id (nullable) is None + # and model_fields_set contains the field + if self.rel_obj_id is None and "rel_obj_id" in self.model_fields_set: + _dict['rel_obj_id'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedScheduleRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "rel_obj_id": obj.get("rel_obj_id"), + "crontab": obj.get("crontab"), + "paused": obj.get("paused") + }) + return _obj + + diff --git a/authentik_client/models/patched_scim_mapping_request.py b/authentik_client/models/patched_scim_mapping_request.py new file mode 100644 index 000000000..b4ba125c4 --- /dev/null +++ b/authentik_client/models/patched_scim_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSCIMMappingRequest(BaseModel): + """ + SCIMMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSCIMMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSCIMMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_scim_provider_request.py b/authentik_client/models/patched_scim_provider_request.py new file mode 100644 index 000000000..ff0d56009 --- /dev/null +++ b/authentik_client/models/patched_scim_provider_request.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.compatibility_mode_enum import CompatibilityModeEnum +from authentik_client.models.scim_authentication_mode_enum import SCIMAuthenticationModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSCIMProviderRequest(BaseModel): + """ + SCIMProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + property_mappings: Optional[List[UUID]] = None + property_mappings_group: Optional[List[UUID]] = Field(default=None, description="Property mappings used for group creation/updating.") + url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Base URL to SCIM requests, usually ends in /v2") + verify_certificates: Optional[StrictBool] = None + token: Optional[StrictStr] = Field(default=None, description="Authentication token") + auth_mode: Optional[SCIMAuthenticationModeEnum] = None + auth_oauth: Optional[UUID] = Field(default=None, description="OAuth Source used for authentication") + auth_oauth_params: Optional[Dict[str, Any]] = Field(default=None, description="Additional OAuth parameters, such as grant_type") + compatibility_mode: Optional[CompatibilityModeEnum] = Field(default=None, description="Alter authentik behavior for vendor-specific SCIM implementations.") + service_provider_config_cache_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Cache duration for ServiceProviderConfig responses. Set minutes=0 to disable.") + exclude_users_service_account: Optional[StrictBool] = None + sync_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Controls the number of objects synced in a single task") + sync_page_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Timeout for synchronization of a single page") + group_filters: Optional[List[UUID]] = Field(default=None, description="Group filters used to define sync-scope for groups.") + dry_run: Optional[StrictBool] = Field(default=None, description="When enabled, provider will not modify or create objects in the remote system.") + __properties: ClassVar[List[str]] = ["name", "property_mappings", "property_mappings_group", "url", "verify_certificates", "token", "auth_mode", "auth_oauth", "auth_oauth_params", "compatibility_mode", "service_provider_config_cache_timeout", "exclude_users_service_account", "sync_page_size", "sync_page_timeout", "group_filters", "dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSCIMProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if auth_oauth (nullable) is None + # and model_fields_set contains the field + if self.auth_oauth is None and "auth_oauth" in self.model_fields_set: + _dict['auth_oauth'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSCIMProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "property_mappings": obj.get("property_mappings"), + "property_mappings_group": obj.get("property_mappings_group"), + "url": obj.get("url"), + "verify_certificates": obj.get("verify_certificates"), + "token": obj.get("token"), + "auth_mode": obj.get("auth_mode"), + "auth_oauth": obj.get("auth_oauth"), + "auth_oauth_params": obj.get("auth_oauth_params"), + "compatibility_mode": obj.get("compatibility_mode"), + "service_provider_config_cache_timeout": obj.get("service_provider_config_cache_timeout"), + "exclude_users_service_account": obj.get("exclude_users_service_account"), + "sync_page_size": obj.get("sync_page_size"), + "sync_page_timeout": obj.get("sync_page_timeout"), + "group_filters": obj.get("group_filters"), + "dry_run": obj.get("dry_run") + }) + return _obj + + diff --git a/authentik_client/models/patched_scim_source_group_request.py b/authentik_client/models/patched_scim_source_group_request.py new file mode 100644 index 000000000..0b0b59fba --- /dev/null +++ b/authentik_client/models/patched_scim_source_group_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSCIMSourceGroupRequest(BaseModel): + """ + SCIMSourceGroup Serializer + """ # noqa: E501 + id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + external_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + group: Optional[UUID] = None + source: Optional[UUID] = None + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["id", "external_id", "group", "source", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSCIMSourceGroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSCIMSourceGroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "external_id": obj.get("external_id"), + "group": obj.get("group"), + "source": obj.get("source"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/patched_scim_source_property_mapping_request.py b/authentik_client/models/patched_scim_source_property_mapping_request.py new file mode 100644 index 000000000..2a7a87336 --- /dev/null +++ b/authentik_client/models/patched_scim_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSCIMSourcePropertyMappingRequest(BaseModel): + """ + SCIMSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSCIMSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSCIMSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_scim_source_request.py b/authentik_client/models/patched_scim_source_request.py new file mode 100644 index 000000000..79e139e47 --- /dev/null +++ b/authentik_client/models/patched_scim_source_request.py @@ -0,0 +1,114 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSCIMSourceRequest(BaseModel): + """ + SCIMSource Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Source's display Name.") + slug: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "user_property_mappings", "group_property_mappings", "user_path_template"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSCIMSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSCIMSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "user_path_template": obj.get("user_path_template") + }) + return _obj + + diff --git a/authentik_client/models/patched_scim_source_user_request.py b/authentik_client/models/patched_scim_source_user_request.py new file mode 100644 index 000000000..4b40a3424 --- /dev/null +++ b/authentik_client/models/patched_scim_source_user_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSCIMSourceUserRequest(BaseModel): + """ + SCIMSourceUser Serializer + """ # noqa: E501 + id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + external_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + user: Optional[StrictInt] = None + source: Optional[UUID] = None + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["id", "external_id", "user", "source", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSCIMSourceUserRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSCIMSourceUserRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "external_id": obj.get("external_id"), + "user": obj.get("user"), + "source": obj.get("source"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/patched_scope_mapping_request.py b/authentik_client/models/patched_scope_mapping_request.py new file mode 100644 index 000000000..b5b32798c --- /dev/null +++ b/authentik_client/models/patched_scope_mapping_request.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedScopeMappingRequest(BaseModel): + """ + ScopeMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + scope_name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Scope name requested by the client") + description: Optional[StrictStr] = Field(default=None, description="Description shown to the user when consenting. If left empty, the user won't be informed.") + __properties: ClassVar[List[str]] = ["managed", "name", "expression", "scope_name", "description"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedScopeMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedScopeMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "scope_name": obj.get("scope_name"), + "description": obj.get("description") + }) + return _obj + + diff --git a/authentik_client/models/patched_settings_request.py b/authentik_client/models/patched_settings_request.py new file mode 100644 index 000000000..d344c6c1f --- /dev/null +++ b/authentik_client/models/patched_settings_request.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.patched_settings_request_flags import PatchedSettingsRequestFlags +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSettingsRequest(BaseModel): + """ + Settings Serializer + """ # noqa: E501 + avatars: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Configure how authentik should show avatars for users.") + default_user_change_name: Optional[StrictBool] = Field(default=None, description="Enable the ability for users to change their name.") + default_user_change_email: Optional[StrictBool] = Field(default=None, description="Enable the ability for users to change their email address.") + default_user_change_username: Optional[StrictBool] = Field(default=None, description="Enable the ability for users to change their username.") + event_retention: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Events will be deleted after this duration.(Format: weeks=3;days=2;hours=3,seconds=2).") + reputation_lower_limit: Optional[Annotated[int, Field(le=0, strict=True, ge=-2147483648)]] = Field(default=None, description="Reputation cannot decrease lower than this value. Zero or negative.") + reputation_upper_limit: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Reputation cannot increase higher than this value. Zero or positive.") + footer_links: Optional[Any] = None + gdpr_compliance: Optional[StrictBool] = Field(default=None, description="When enabled, all the events caused by a user will be deleted upon the user's deletion.") + impersonation: Optional[StrictBool] = Field(default=None, description="Globally enable/disable impersonation.") + impersonation_require_reason: Optional[StrictBool] = Field(default=None, description="Require administrators to provide a reason for impersonating a user.") + default_token_duration: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Default token duration") + default_token_length: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Default token length") + pagination_default_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Default page size for API responses, if no size was requested.") + pagination_max_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Maximum page size") + flags: Optional[PatchedSettingsRequestFlags] = None + __properties: ClassVar[List[str]] = ["avatars", "default_user_change_name", "default_user_change_email", "default_user_change_username", "event_retention", "reputation_lower_limit", "reputation_upper_limit", "footer_links", "gdpr_compliance", "impersonation", "impersonation_require_reason", "default_token_duration", "default_token_length", "pagination_default_page_size", "pagination_max_page_size", "flags"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSettingsRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flags + if self.flags: + _dict['flags'] = self.flags.to_dict() + # set to None if footer_links (nullable) is None + # and model_fields_set contains the field + if self.footer_links is None and "footer_links" in self.model_fields_set: + _dict['footer_links'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSettingsRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "avatars": obj.get("avatars"), + "default_user_change_name": obj.get("default_user_change_name"), + "default_user_change_email": obj.get("default_user_change_email"), + "default_user_change_username": obj.get("default_user_change_username"), + "event_retention": obj.get("event_retention"), + "reputation_lower_limit": obj.get("reputation_lower_limit"), + "reputation_upper_limit": obj.get("reputation_upper_limit"), + "footer_links": obj.get("footer_links"), + "gdpr_compliance": obj.get("gdpr_compliance"), + "impersonation": obj.get("impersonation"), + "impersonation_require_reason": obj.get("impersonation_require_reason"), + "default_token_duration": obj.get("default_token_duration"), + "default_token_length": obj.get("default_token_length"), + "pagination_default_page_size": obj.get("pagination_default_page_size"), + "pagination_max_page_size": obj.get("pagination_max_page_size"), + "flags": PatchedSettingsRequestFlags.from_dict(obj["flags"]) if obj.get("flags") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/patched_settings_request_flags.py b/authentik_client/models/patched_settings_request_flags.py new file mode 100644 index 000000000..8313f0942 --- /dev/null +++ b/authentik_client/models/patched_settings_request_flags.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSettingsRequestFlags(BaseModel): + """ + PatchedSettingsRequestFlags + """ # noqa: E501 + core_default_app_access: StrictBool = Field(description="Configure if applications without any policy/group/user bindings should be accessible to any user.") + enterprise_audit_include_expanded_diff: StrictBool = Field(description="Include additional information in audit logs, may incur a performance penalty.") + flows_continuous_login: StrictBool = Field(description="Upon successful authentication, re-start authentication in other open tabs.") + flows_refresh_others: StrictBool = Field(description="Refresh other tabs after successful authentication.") + __properties: ClassVar[List[str]] = ["core_default_app_access", "enterprise_audit_include_expanded_diff", "flows_continuous_login", "flows_refresh_others"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSettingsRequestFlags from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSettingsRequestFlags from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "core_default_app_access": obj.get("core_default_app_access"), + "enterprise_audit_include_expanded_diff": obj.get("enterprise_audit_include_expanded_diff"), + "flows_continuous_login": obj.get("flows_continuous_login"), + "flows_refresh_others": obj.get("flows_refresh_others") + }) + return _obj + + diff --git a/authentik_client/models/patched_sms_device_request.py b/authentik_client/models/patched_sms_device_request.py new file mode 100644 index 000000000..418b40db9 --- /dev/null +++ b/authentik_client/models/patched_sms_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSMSDeviceRequest(BaseModel): + """ + Serializer for sms authenticator devices + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=64)]] = Field(default=None, description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSMSDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSMSDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_source_stage_request.py b/authentik_client/models/patched_source_stage_request.py new file mode 100644 index 000000000..a9eed9c73 --- /dev/null +++ b/authentik_client/models/patched_source_stage_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSourceStageRequest(BaseModel): + """ + SourceStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + source: Optional[UUID] = None + resume_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Amount of time a user can take to return from the source to continue the flow (Format: hours=-1;minutes=-2;seconds=-3)") + __properties: ClassVar[List[str]] = ["name", "source", "resume_timeout"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSourceStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSourceStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "source": obj.get("source"), + "resume_timeout": obj.get("resume_timeout") + }) + return _obj + + diff --git a/authentik_client/models/patched_ssf_provider_request.py b/authentik_client/models/patched_ssf_provider_request.py new file mode 100644 index 000000000..28b5c0a97 --- /dev/null +++ b/authentik_client/models/patched_ssf_provider_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedSSFProviderRequest(BaseModel): + """ + SSFProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + signing_key: Optional[UUID] = Field(default=None, description="Key used to sign the SSF Events.") + oidc_auth_providers: Optional[List[StrictInt]] = None + event_retention: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + push_verify_certificates: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "signing_key", "oidc_auth_providers", "event_retention", "push_verify_certificates"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedSSFProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedSSFProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "signing_key": obj.get("signing_key"), + "oidc_auth_providers": obj.get("oidc_auth_providers"), + "event_retention": obj.get("event_retention"), + "push_verify_certificates": obj.get("push_verify_certificates") + }) + return _obj + + diff --git a/authentik_client/models/patched_static_device_request.py b/authentik_client/models/patched_static_device_request.py new file mode 100644 index 000000000..e5a44d4e6 --- /dev/null +++ b/authentik_client/models/patched_static_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedStaticDeviceRequest(BaseModel): + """ + Serializer for static authenticator devices + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=64)]] = Field(default=None, description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedStaticDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedStaticDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_telegram_source_property_mapping_request.py b/authentik_client/models/patched_telegram_source_property_mapping_request.py new file mode 100644 index 000000000..13d6f6e75 --- /dev/null +++ b/authentik_client/models/patched_telegram_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedTelegramSourcePropertyMappingRequest(BaseModel): + """ + TelegramSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + expression: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedTelegramSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedTelegramSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/patched_telegram_source_request.py b/authentik_client/models/patched_telegram_source_request.py new file mode 100644 index 000000000..922d927e0 --- /dev/null +++ b/authentik_client/models/patched_telegram_source_request.py @@ -0,0 +1,146 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedTelegramSourceRequest(BaseModel): + """ + Source Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Source's display Name.") + slug: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + bot_username: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Telegram bot username") + bot_token: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Telegram bot token") + request_message_access: Optional[StrictBool] = Field(default=None, description="Request access to send messages from your bot.") + pre_authentication_flow: Optional[UUID] = Field(default=None, description="Flow used before authentication.") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "bot_username", "bot_token", "request_message_access", "pre_authentication_flow"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedTelegramSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedTelegramSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "bot_username": obj.get("bot_username"), + "bot_token": obj.get("bot_token"), + "request_message_access": obj.get("request_message_access"), + "pre_authentication_flow": obj.get("pre_authentication_flow") + }) + return _obj + + diff --git a/authentik_client/models/patched_tenant_request.py b/authentik_client/models/patched_tenant_request.py new file mode 100644 index 000000000..b329d0672 --- /dev/null +++ b/authentik_client/models/patched_tenant_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedTenantRequest(BaseModel): + """ + Tenant Serializer + """ # noqa: E501 + schema_name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=63)]] = None + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + ready: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["schema_name", "name", "ready"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedTenantRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedTenantRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "schema_name": obj.get("schema_name"), + "name": obj.get("name"), + "ready": obj.get("ready") + }) + return _obj + + diff --git a/authentik_client/models/patched_token_request.py b/authentik_client/models/patched_token_request.py new file mode 100644 index 000000000..3a1e34f16 --- /dev/null +++ b/authentik_client/models/patched_token_request.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.intent_enum import IntentEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedTokenRequest(BaseModel): + """ + Token Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + identifier: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=255)]] = None + intent: Optional[IntentEnum] = None + user: Optional[StrictInt] = None + description: Optional[StrictStr] = None + expires: Optional[datetime] = None + expiring: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["managed", "identifier", "intent", "user", "description", "expires", "expiring"] + + @field_validator('identifier') + def identifier_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedTokenRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedTokenRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "identifier": obj.get("identifier"), + "intent": obj.get("intent"), + "user": obj.get("user"), + "description": obj.get("description"), + "expires": obj.get("expires"), + "expiring": obj.get("expiring") + }) + return _obj + + diff --git a/authentik_client/models/patched_totp_device_request.py b/authentik_client/models/patched_totp_device_request.py new file mode 100644 index 000000000..5043201b6 --- /dev/null +++ b/authentik_client/models/patched_totp_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedTOTPDeviceRequest(BaseModel): + """ + Serializer for totp authenticator devices + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=64)]] = Field(default=None, description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedTOTPDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedTOTPDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_unique_password_policy_request.py b/authentik_client/models/patched_unique_password_policy_request.py new file mode 100644 index 000000000..956752aaf --- /dev/null +++ b/authentik_client/models/patched_unique_password_policy_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUniquePasswordPolicyRequest(BaseModel): + """ + Password Uniqueness Policy Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + password_field: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Field key to check, field keys defined in Prompt stages are available.") + num_historical_passwords: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Number of passwords to check against.") + __properties: ClassVar[List[str]] = ["name", "execution_logging", "password_field", "num_historical_passwords"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUniquePasswordPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUniquePasswordPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "password_field": obj.get("password_field"), + "num_historical_passwords": obj.get("num_historical_passwords") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_delete_stage_request.py b/authentik_client/models/patched_user_delete_stage_request.py new file mode 100644 index 000000000..f2e20a270 --- /dev/null +++ b/authentik_client/models/patched_user_delete_stage_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserDeleteStageRequest(BaseModel): + """ + UserDeleteStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserDeleteStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserDeleteStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_kerberos_source_connection_request.py b/authentik_client/models/patched_user_kerberos_source_connection_request.py new file mode 100644 index 000000000..6afbc1c01 --- /dev/null +++ b/authentik_client/models/patched_user_kerberos_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserKerberosSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserKerberosSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserKerberosSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_ldap_source_connection_request.py b/authentik_client/models/patched_user_ldap_source_connection_request.py new file mode 100644 index 000000000..7061dc01e --- /dev/null +++ b/authentik_client/models/patched_user_ldap_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserLDAPSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserLDAPSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserLDAPSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_login_stage_request.py b/authentik_client/models/patched_user_login_stage_request.py new file mode 100644 index 000000000..1a9374659 --- /dev/null +++ b/authentik_client/models/patched_user_login_stage_request.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.geoip_binding_enum import GeoipBindingEnum +from authentik_client.models.network_binding_enum import NetworkBindingEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserLoginStageRequest(BaseModel): + """ + UserLoginStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + session_duration: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)") + terminate_other_sessions: Optional[StrictBool] = Field(default=None, description="Terminate all other sessions of the user logging in.") + remember_me_offset: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Offset the session will be extended by when the user picks the remember me option. Default of 0 means that the remember me option will not be shown. (Format: hours=-1;minutes=-2;seconds=-3)") + network_binding: Optional[NetworkBindingEnum] = Field(default=None, description="Bind sessions created by this stage to the configured network") + geoip_binding: Optional[GeoipBindingEnum] = Field(default=None, description="Bind sessions created by this stage to the configured GeoIP location") + remember_device: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="When set to a non-zero value, authentik will save a cookie with a longer expiry,to remember the device the user is logging in from. (Format: hours=-1;minutes=-2;seconds=-3)") + __properties: ClassVar[List[str]] = ["name", "session_duration", "terminate_other_sessions", "remember_me_offset", "network_binding", "geoip_binding", "remember_device"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserLoginStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserLoginStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "session_duration": obj.get("session_duration"), + "terminate_other_sessions": obj.get("terminate_other_sessions"), + "remember_me_offset": obj.get("remember_me_offset"), + "network_binding": obj.get("network_binding"), + "geoip_binding": obj.get("geoip_binding"), + "remember_device": obj.get("remember_device") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_logout_stage_request.py b/authentik_client/models/patched_user_logout_stage_request.py new file mode 100644 index 000000000..5cbb225e0 --- /dev/null +++ b/authentik_client/models/patched_user_logout_stage_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserLogoutStageRequest(BaseModel): + """ + UserLogoutStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserLogoutStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserLogoutStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_o_auth_source_connection_request.py b/authentik_client/models/patched_user_o_auth_source_connection_request.py new file mode 100644 index 000000000..aebfa2f67 --- /dev/null +++ b/authentik_client/models/patched_user_o_auth_source_connection_request.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserOAuthSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + access_token: Optional[StrictStr] = None + expires: Optional[datetime] = None + __properties: ClassVar[List[str]] = ["source", "identifier", "access_token", "expires"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserOAuthSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if access_token (nullable) is None + # and model_fields_set contains the field + if self.access_token is None and "access_token" in self.model_fields_set: + _dict['access_token'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserOAuthSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier"), + "access_token": obj.get("access_token"), + "expires": obj.get("expires") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_plex_source_connection_request.py b/authentik_client/models/patched_user_plex_source_connection_request.py new file mode 100644 index 000000000..804bdb8bc --- /dev/null +++ b/authentik_client/models/patched_user_plex_source_connection_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserPlexSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + plex_token: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier", "plex_token"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserPlexSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserPlexSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier"), + "plex_token": obj.get("plex_token") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_request.py b/authentik_client/models/patched_user_request.py new file mode 100644 index 000000000..40471bfe7 --- /dev/null +++ b/authentik_client/models/patched_user_request.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.user_type_enum import UserTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserRequest(BaseModel): + """ + User Serializer + """ # noqa: E501 + username: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=150)]] = None + name: Optional[StrictStr] = Field(default=None, description="User's display name.") + is_active: Optional[StrictBool] = Field(default=None, description="Designates whether this user should be treated as active. Unselect this instead of deleting accounts.") + last_login: Optional[datetime] = None + groups: Optional[List[UUID]] = None + roles: Optional[List[UUID]] = None + email: Optional[Annotated[str, Field(strict=True, max_length=254)]] = None + attributes: Optional[Dict[str, Any]] = None + path: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + type: Optional[UserTypeEnum] = None + __properties: ClassVar[List[str]] = ["username", "name", "is_active", "last_login", "groups", "roles", "email", "attributes", "path", "type"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if last_login (nullable) is None + # and model_fields_set contains the field + if self.last_login is None and "last_login" in self.model_fields_set: + _dict['last_login'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "username": obj.get("username"), + "name": obj.get("name"), + "is_active": obj.get("is_active"), + "last_login": obj.get("last_login"), + "groups": obj.get("groups"), + "roles": obj.get("roles"), + "email": obj.get("email"), + "attributes": obj.get("attributes"), + "path": obj.get("path"), + "type": obj.get("type") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_saml_source_connection_request.py b/authentik_client/models/patched_user_saml_source_connection_request.py new file mode 100644 index 000000000..6b9112cc5 --- /dev/null +++ b/authentik_client/models/patched_user_saml_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserSAMLSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserSAMLSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserSAMLSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_source_connection_request.py b/authentik_client/models/patched_user_source_connection_request.py new file mode 100644 index 000000000..b442864fa --- /dev/null +++ b/authentik_client/models/patched_user_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_telegram_source_connection_request.py b/authentik_client/models/patched_user_telegram_source_connection_request.py new file mode 100644 index 000000000..d73721a33 --- /dev/null +++ b/authentik_client/models/patched_user_telegram_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserTelegramSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: Optional[UUID] = None + identifier: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserTelegramSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserTelegramSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/patched_user_write_stage_request.py b/authentik_client/models/patched_user_write_stage_request.py new file mode 100644 index 000000000..7713f5a38 --- /dev/null +++ b/authentik_client/models/patched_user_write_stage_request.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.user_creation_mode_enum import UserCreationModeEnum +from authentik_client.models.user_type_enum import UserTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedUserWriteStageRequest(BaseModel): + """ + UserWriteStage Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + user_creation_mode: Optional[UserCreationModeEnum] = None + create_users_as_inactive: Optional[StrictBool] = Field(default=None, description="When set, newly created users are inactive and cannot login.") + create_users_group: Optional[UUID] = Field(default=None, description="Optionally add newly created users to this group.") + user_type: Optional[UserTypeEnum] = None + user_path_template: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "user_creation_mode", "create_users_as_inactive", "create_users_group", "user_type", "user_path_template"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedUserWriteStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if create_users_group (nullable) is None + # and model_fields_set contains the field + if self.create_users_group is None and "create_users_group" in self.model_fields_set: + _dict['create_users_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedUserWriteStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "user_creation_mode": obj.get("user_creation_mode"), + "create_users_as_inactive": obj.get("create_users_as_inactive"), + "create_users_group": obj.get("create_users_group"), + "user_type": obj.get("user_type"), + "user_path_template": obj.get("user_path_template") + }) + return _obj + + diff --git a/authentik_client/models/patched_web_authn_device_request.py b/authentik_client/models/patched_web_authn_device_request.py new file mode 100644 index 000000000..1840c96a7 --- /dev/null +++ b/authentik_client/models/patched_web_authn_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedWebAuthnDeviceRequest(BaseModel): + """ + Serializer for WebAuthn authenticator devices + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=200)]] = None + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedWebAuthnDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedWebAuthnDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/patched_ws_federation_provider_request.py b/authentik_client/models/patched_ws_federation_provider_request.py new file mode 100644 index 000000000..3a890e49a --- /dev/null +++ b/authentik_client/models/patched_ws_federation_provider_request.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PatchedWSFederationProviderRequest(BaseModel): + """ + WSFederationProvider Serializer + """ # noqa: E501 + name: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: Optional[UUID] = Field(default=None, description="Flow used when authorizing this provider.") + invalidation_flow: Optional[UUID] = Field(default=None, description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + reply_url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + wtrealm: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + assertion_valid_not_before: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3).") + assertion_valid_not_on_or_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + session_valid_not_on_or_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + name_id_mapping: Optional[UUID] = Field(default=None, description="Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered") + authn_context_class_ref_mapping: Optional[UUID] = Field(default=None, description="Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate.") + digest_algorithm: Optional[DigestAlgorithmEnum] = None + signature_algorithm: Optional[SignatureAlgorithmEnum] = None + signing_kp: Optional[UUID] = Field(default=None, description="Keypair used to sign outgoing Responses going to the Service Provider.") + encryption_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key.") + sign_assertion: Optional[StrictBool] = None + sign_logout_request: Optional[StrictBool] = None + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "reply_url", "wtrealm", "assertion_valid_not_before", "assertion_valid_not_on_or_after", "session_valid_not_on_or_after", "name_id_mapping", "authn_context_class_ref_mapping", "digest_algorithm", "signature_algorithm", "signing_kp", "encryption_kp", "sign_assertion", "sign_logout_request", "default_name_id_policy"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PatchedWSFederationProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if name_id_mapping (nullable) is None + # and model_fields_set contains the field + if self.name_id_mapping is None and "name_id_mapping" in self.model_fields_set: + _dict['name_id_mapping'] = None + + # set to None if authn_context_class_ref_mapping (nullable) is None + # and model_fields_set contains the field + if self.authn_context_class_ref_mapping is None and "authn_context_class_ref_mapping" in self.model_fields_set: + _dict['authn_context_class_ref_mapping'] = None + + # set to None if signing_kp (nullable) is None + # and model_fields_set contains the field + if self.signing_kp is None and "signing_kp" in self.model_fields_set: + _dict['signing_kp'] = None + + # set to None if encryption_kp (nullable) is None + # and model_fields_set contains the field + if self.encryption_kp is None and "encryption_kp" in self.model_fields_set: + _dict['encryption_kp'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PatchedWSFederationProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "reply_url": obj.get("reply_url"), + "wtrealm": obj.get("wtrealm"), + "assertion_valid_not_before": obj.get("assertion_valid_not_before"), + "assertion_valid_not_on_or_after": obj.get("assertion_valid_not_on_or_after"), + "session_valid_not_on_or_after": obj.get("session_valid_not_on_or_after"), + "name_id_mapping": obj.get("name_id_mapping"), + "authn_context_class_ref_mapping": obj.get("authn_context_class_ref_mapping"), + "digest_algorithm": obj.get("digest_algorithm"), + "signature_algorithm": obj.get("signature_algorithm"), + "signing_kp": obj.get("signing_kp"), + "encryption_kp": obj.get("encryption_kp"), + "sign_assertion": obj.get("sign_assertion"), + "sign_logout_request": obj.get("sign_logout_request"), + "default_name_id_policy": obj.get("default_name_id_policy") + }) + return _obj + + diff --git a/authentik_client/models/permission.py b/authentik_client/models/permission.py new file mode 100644 index 000000000..83104fe36 --- /dev/null +++ b/authentik_client/models/permission.py @@ -0,0 +1,112 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Permission(BaseModel): + """ + Global permission + """ # noqa: E501 + id: StrictInt + name: Annotated[str, Field(strict=True, max_length=255)] + codename: Annotated[str, Field(strict=True, max_length=100)] + model: StrictStr + app_label: StrictStr + app_label_verbose: StrictStr = Field(description="Human-readable app label") + model_verbose: StrictStr = Field(description="Human-readable model name") + __properties: ClassVar[List[str]] = ["id", "name", "codename", "model", "app_label", "app_label_verbose", "model_verbose"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Permission from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "model", + "app_label", + "app_label_verbose", + "model_verbose", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Permission from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "name": obj.get("name"), + "codename": obj.get("codename"), + "model": obj.get("model"), + "app_label": obj.get("app_label"), + "app_label_verbose": obj.get("app_label_verbose"), + "model_verbose": obj.get("model_verbose") + }) + return _obj + + diff --git a/authentik_client/models/permission_assign_request.py b/authentik_client/models/permission_assign_request.py new file mode 100644 index 000000000..84d5aea78 --- /dev/null +++ b/authentik_client/models/permission_assign_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.model_enum import ModelEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PermissionAssignRequest(BaseModel): + """ + Request to assign a new permission + """ # noqa: E501 + permissions: List[Annotated[str, Field(min_length=1, strict=True)]] + model: Optional[ModelEnum] = None + object_pk: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["permissions", "model", "object_pk"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PermissionAssignRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PermissionAssignRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "permissions": obj.get("permissions"), + "model": obj.get("model"), + "object_pk": obj.get("object_pk") + }) + return _obj + + diff --git a/authentik_client/models/permission_assign_result.py b/authentik_client/models/permission_assign_result.py new file mode 100644 index 000000000..5f8b31bb9 --- /dev/null +++ b/authentik_client/models/permission_assign_result.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PermissionAssignResult(BaseModel): + """ + Result from assigning permissions to a user/role + """ # noqa: E501 + id: StrictStr + __properties: ClassVar[List[str]] = ["id"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PermissionAssignResult from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PermissionAssignResult from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id") + }) + return _obj + + diff --git a/authentik_client/models/pkce_method_enum.py b/authentik_client/models/pkce_method_enum.py new file mode 100644 index 000000000..fec5dca53 --- /dev/null +++ b/authentik_client/models/pkce_method_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class PKCEMethodEnum(str, Enum): + """ + PKCEMethodEnum + """ + + """ + allowed enum values + """ + NONE = 'none' + PLAIN = 'plain' + S256 = 'S256' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of PKCEMethodEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/plex_authentication_challenge.py b/authentik_client/models/plex_authentication_challenge.py new file mode 100644 index 000000000..adb99fb32 --- /dev/null +++ b/authentik_client/models/plex_authentication_challenge.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PlexAuthenticationChallenge(BaseModel): + """ + Challenge shown to the user in identification stage + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-source-plex' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + client_id: StrictStr + slug: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "client_id", "slug"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PlexAuthenticationChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PlexAuthenticationChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-source-plex', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "client_id": obj.get("client_id"), + "slug": obj.get("slug") + }) + return _obj + + diff --git a/authentik_client/models/plex_authentication_challenge_response_request.py b/authentik_client/models/plex_authentication_challenge_response_request.py new file mode 100644 index 000000000..9246ac946 --- /dev/null +++ b/authentik_client/models/plex_authentication_challenge_response_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PlexAuthenticationChallengeResponseRequest(BaseModel): + """ + Pseudo class for plex response + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-source-plex' + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PlexAuthenticationChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PlexAuthenticationChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-source-plex' + }) + return _obj + + diff --git a/authentik_client/models/plex_source.py b/authentik_client/models/plex_source.py new file mode 100644 index 000000000..aa5ee7b80 --- /dev/null +++ b/authentik_client/models/plex_source.py @@ -0,0 +1,192 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.themed_urls import ThemedUrls +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PlexSource(BaseModel): + """ + Plex Source Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr = Field(description="Source's display Name.") + slug: Annotated[str, Field(strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + managed: Optional[StrictStr] = Field(description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + user_path_template: Optional[StrictStr] = None + icon: Optional[StrictStr] = None + icon_url: StrictStr + icon_themed_urls: Optional[ThemedUrls] + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + client_id: Optional[StrictStr] = Field(default=None, description="Client identifier used to talk to Plex.") + allowed_servers: Optional[List[StrictStr]] = Field(default=None, description="Which servers a user has to be a member of to be granted access. Empty list allows every server.") + allow_friends: Optional[StrictBool] = Field(default=None, description="Allow friends to authenticate, even if you don't share a server.") + plex_token: StrictStr = Field(description="Plex token used to check friends") + __properties: ClassVar[List[str]] = ["pk", "name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "policy_engine_mode", "user_matching_mode", "managed", "user_path_template", "icon", "icon_url", "icon_themed_urls", "group_matching_mode", "client_id", "allowed_servers", "allow_friends", "plex_token"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PlexSource from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "managed", + "icon_url", + "icon_themed_urls", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of icon_themed_urls + if self.icon_themed_urls: + _dict['icon_themed_urls'] = self.icon_themed_urls.to_dict() + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if icon_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.icon_themed_urls is None and "icon_themed_urls" in self.model_fields_set: + _dict['icon_themed_urls'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PlexSource from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "managed": obj.get("managed"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "icon_url": obj.get("icon_url"), + "icon_themed_urls": ThemedUrls.from_dict(obj["icon_themed_urls"]) if obj.get("icon_themed_urls") is not None else None, + "group_matching_mode": obj.get("group_matching_mode"), + "client_id": obj.get("client_id"), + "allowed_servers": obj.get("allowed_servers"), + "allow_friends": obj.get("allow_friends"), + "plex_token": obj.get("plex_token") + }) + return _obj + + diff --git a/authentik_client/models/plex_source_property_mapping.py b/authentik_client/models/plex_source_property_mapping.py new file mode 100644 index 000000000..0ce1b2c76 --- /dev/null +++ b/authentik_client/models/plex_source_property_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PlexSourcePropertyMapping(BaseModel): + """ + PlexSourcePropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PlexSourcePropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PlexSourcePropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/plex_source_property_mapping_request.py b/authentik_client/models/plex_source_property_mapping_request.py new file mode 100644 index 000000000..a4a849eab --- /dev/null +++ b/authentik_client/models/plex_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PlexSourcePropertyMappingRequest(BaseModel): + """ + PlexSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PlexSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PlexSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/plex_source_request.py b/authentik_client/models/plex_source_request.py new file mode 100644 index 000000000..c076d2b44 --- /dev/null +++ b/authentik_client/models/plex_source_request.py @@ -0,0 +1,146 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PlexSourceRequest(BaseModel): + """ + Plex Source Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Source's display Name.") + slug: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + client_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Client identifier used to talk to Plex.") + allowed_servers: Optional[List[Annotated[str, Field(min_length=1, strict=True)]]] = Field(default=None, description="Which servers a user has to be a member of to be granted access. Empty list allows every server.") + allow_friends: Optional[StrictBool] = Field(default=None, description="Allow friends to authenticate, even if you don't share a server.") + plex_token: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Plex token used to check friends") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "group_matching_mode", "client_id", "allowed_servers", "allow_friends", "plex_token"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PlexSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PlexSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "group_matching_mode": obj.get("group_matching_mode"), + "client_id": obj.get("client_id"), + "allowed_servers": obj.get("allowed_servers"), + "allow_friends": obj.get("allow_friends"), + "plex_token": obj.get("plex_token") + }) + return _obj + + diff --git a/authentik_client/models/plex_token_redeem_request.py b/authentik_client/models/plex_token_redeem_request.py new file mode 100644 index 000000000..a9676580b --- /dev/null +++ b/authentik_client/models/plex_token_redeem_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PlexTokenRedeemRequest(BaseModel): + """ + Serializer to redeem a plex token + """ # noqa: E501 + plex_token: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["plex_token"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PlexTokenRedeemRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PlexTokenRedeemRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "plex_token": obj.get("plex_token") + }) + return _obj + + diff --git a/authentik_client/models/policy.py b/authentik_client/models/policy.py new file mode 100644 index 000000000..c5dbd813f --- /dev/null +++ b/authentik_client/models/policy.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Policy(BaseModel): + """ + Policy Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + bound_to: StrictInt = Field(description="Return objects policy is bound to") + __properties: ClassVar[List[str]] = ["pk", "name", "execution_logging", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "bound_to"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Policy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "bound_to", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Policy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "bound_to": obj.get("bound_to") + }) + return _obj + + diff --git a/authentik_client/models/policy_binding.py b/authentik_client/models/policy_binding.py new file mode 100644 index 000000000..7e5febbf6 --- /dev/null +++ b/authentik_client/models/policy_binding.py @@ -0,0 +1,165 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.partial_group import PartialGroup +from authentik_client.models.partial_user import PartialUser +from authentik_client.models.policy import Policy +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PolicyBinding(BaseModel): + """ + PolicyBinding Serializer + """ # noqa: E501 + pk: UUID + policy: Optional[UUID] = None + group: Optional[UUID] = None + user: Optional[StrictInt] = None + policy_obj: Optional[Policy] + group_obj: Optional[PartialGroup] + user_obj: Optional[PartialUser] + target: UUID + negate: Optional[StrictBool] = Field(default=None, description="Negates the outcome of the policy. Messages are unaffected.") + enabled: Optional[StrictBool] = None + order: Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)] + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Timeout after which Policy execution is terminated.") + failure_result: Optional[StrictBool] = Field(default=None, description="Result if the Policy execution fails.") + __properties: ClassVar[List[str]] = ["pk", "policy", "group", "user", "policy_obj", "group_obj", "user_obj", "target", "negate", "enabled", "order", "timeout", "failure_result"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PolicyBinding from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "policy_obj", + "group_obj", + "user_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of policy_obj + if self.policy_obj: + _dict['policy_obj'] = self.policy_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of group_obj + if self.group_obj: + _dict['group_obj'] = self.group_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of user_obj + if self.user_obj: + _dict['user_obj'] = self.user_obj.to_dict() + # set to None if policy (nullable) is None + # and model_fields_set contains the field + if self.policy is None and "policy" in self.model_fields_set: + _dict['policy'] = None + + # set to None if group (nullable) is None + # and model_fields_set contains the field + if self.group is None and "group" in self.model_fields_set: + _dict['group'] = None + + # set to None if user (nullable) is None + # and model_fields_set contains the field + if self.user is None and "user" in self.model_fields_set: + _dict['user'] = None + + # set to None if policy_obj (nullable) is None + # and model_fields_set contains the field + if self.policy_obj is None and "policy_obj" in self.model_fields_set: + _dict['policy_obj'] = None + + # set to None if group_obj (nullable) is None + # and model_fields_set contains the field + if self.group_obj is None and "group_obj" in self.model_fields_set: + _dict['group_obj'] = None + + # set to None if user_obj (nullable) is None + # and model_fields_set contains the field + if self.user_obj is None and "user_obj" in self.model_fields_set: + _dict['user_obj'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PolicyBinding from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "policy": obj.get("policy"), + "group": obj.get("group"), + "user": obj.get("user"), + "policy_obj": Policy.from_dict(obj["policy_obj"]) if obj.get("policy_obj") is not None else None, + "group_obj": PartialGroup.from_dict(obj["group_obj"]) if obj.get("group_obj") is not None else None, + "user_obj": PartialUser.from_dict(obj["user_obj"]) if obj.get("user_obj") is not None else None, + "target": obj.get("target"), + "negate": obj.get("negate"), + "enabled": obj.get("enabled"), + "order": obj.get("order"), + "timeout": obj.get("timeout"), + "failure_result": obj.get("failure_result") + }) + return _obj + + diff --git a/authentik_client/models/policy_binding_request.py b/authentik_client/models/policy_binding_request.py new file mode 100644 index 000000000..05a8f7c5a --- /dev/null +++ b/authentik_client/models/policy_binding_request.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PolicyBindingRequest(BaseModel): + """ + PolicyBinding Serializer + """ # noqa: E501 + policy: Optional[UUID] = None + group: Optional[UUID] = None + user: Optional[StrictInt] = None + target: UUID + negate: Optional[StrictBool] = Field(default=None, description="Negates the outcome of the policy. Messages are unaffected.") + enabled: Optional[StrictBool] = None + order: Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)] + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Timeout after which Policy execution is terminated.") + failure_result: Optional[StrictBool] = Field(default=None, description="Result if the Policy execution fails.") + __properties: ClassVar[List[str]] = ["policy", "group", "user", "target", "negate", "enabled", "order", "timeout", "failure_result"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PolicyBindingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if policy (nullable) is None + # and model_fields_set contains the field + if self.policy is None and "policy" in self.model_fields_set: + _dict['policy'] = None + + # set to None if group (nullable) is None + # and model_fields_set contains the field + if self.group is None and "group" in self.model_fields_set: + _dict['group'] = None + + # set to None if user (nullable) is None + # and model_fields_set contains the field + if self.user is None and "user" in self.model_fields_set: + _dict['user'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PolicyBindingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "policy": obj.get("policy"), + "group": obj.get("group"), + "user": obj.get("user"), + "target": obj.get("target"), + "negate": obj.get("negate"), + "enabled": obj.get("enabled"), + "order": obj.get("order"), + "timeout": obj.get("timeout"), + "failure_result": obj.get("failure_result") + }) + return _obj + + diff --git a/authentik_client/models/policy_engine_mode.py b/authentik_client/models/policy_engine_mode.py new file mode 100644 index 000000000..ca4a516a0 --- /dev/null +++ b/authentik_client/models/policy_engine_mode.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class PolicyEngineMode(str, Enum): + """ + PolicyEngineMode + """ + + """ + allowed enum values + """ + ALL = 'all' + ANY = 'any' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of PolicyEngineMode from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/policy_test_request.py b/authentik_client/models/policy_test_request.py new file mode 100644 index 000000000..8b6911ee7 --- /dev/null +++ b/authentik_client/models/policy_test_request.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PolicyTestRequest(BaseModel): + """ + Test policy execution for a user with context + """ # noqa: E501 + user: StrictInt + context: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["user", "context"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PolicyTestRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PolicyTestRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user": obj.get("user"), + "context": obj.get("context") + }) + return _obj + + diff --git a/authentik_client/models/policy_test_result.py b/authentik_client/models/policy_test_result.py new file mode 100644 index 000000000..2889dd530 --- /dev/null +++ b/authentik_client/models/policy_test_result.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List +from authentik_client.models.log_event import LogEvent +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PolicyTestResult(BaseModel): + """ + result of a policy test + """ # noqa: E501 + passing: StrictBool + messages: List[StrictStr] + log_messages: List[LogEvent] + __properties: ClassVar[List[str]] = ["passing", "messages", "log_messages"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PolicyTestResult from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "messages", + "log_messages", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in log_messages (list) + _items = [] + if self.log_messages: + for _item_log_messages in self.log_messages: + if _item_log_messages: + _items.append(_item_log_messages.to_dict()) + _dict['log_messages'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PolicyTestResult from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "passing": obj.get("passing"), + "messages": obj.get("messages"), + "log_messages": [LogEvent.from_dict(_item) for _item in obj["log_messages"]] if obj.get("log_messages") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/process.py b/authentik_client/models/process.py new file mode 100644 index 000000000..af880cd3b --- /dev/null +++ b/authentik_client/models/process.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Process(BaseModel): + """ + Process + """ # noqa: E501 + id: StrictInt + name: StrictStr + user: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["id", "name", "user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Process from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Process from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "name": obj.get("name"), + "user": obj.get("user") + }) + return _obj + + diff --git a/authentik_client/models/process_request.py b/authentik_client/models/process_request.py new file mode 100644 index 000000000..205268d8e --- /dev/null +++ b/authentik_client/models/process_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ProcessRequest(BaseModel): + """ + ProcessRequest + """ # noqa: E501 + id: StrictInt + name: Annotated[str, Field(min_length=1, strict=True)] + user: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["id", "name", "user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ProcessRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ProcessRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "name": obj.get("name"), + "user": obj.get("user") + }) + return _obj + + diff --git a/authentik_client/models/prompt.py b/authentik_client/models/prompt.py new file mode 100644 index 000000000..e958c92bd --- /dev/null +++ b/authentik_client/models/prompt.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.prompt_stage import PromptStage +from authentik_client.models.prompt_type_enum import PromptTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Prompt(BaseModel): + """ + Prompt Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + field_key: StrictStr = Field(description="Name of the form field, also used to store the value") + label: StrictStr + type: PromptTypeEnum + required: Optional[StrictBool] = None + placeholder: Optional[StrictStr] = Field(default=None, description="Optionally provide a short hint that describes the expected input value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple choices.") + initial_value: Optional[StrictStr] = Field(default=None, description="Optionally pre-fill the input with an initial value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple default choices.") + order: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + prompt_stages_obj: List[PromptStage] + sub_text: Optional[StrictStr] = None + placeholder_expression: Optional[StrictBool] = None + initial_value_expression: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["pk", "name", "field_key", "label", "type", "required", "placeholder", "initial_value", "order", "prompt_stages_obj", "sub_text", "placeholder_expression", "initial_value_expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Prompt from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "prompt_stages_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in prompt_stages_obj (list) + _items = [] + if self.prompt_stages_obj: + for _item_prompt_stages_obj in self.prompt_stages_obj: + if _item_prompt_stages_obj: + _items.append(_item_prompt_stages_obj.to_dict()) + _dict['prompt_stages_obj'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Prompt from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "field_key": obj.get("field_key"), + "label": obj.get("label"), + "type": obj.get("type"), + "required": obj.get("required"), + "placeholder": obj.get("placeholder"), + "initial_value": obj.get("initial_value"), + "order": obj.get("order"), + "prompt_stages_obj": [PromptStage.from_dict(_item) for _item in obj["prompt_stages_obj"]] if obj.get("prompt_stages_obj") is not None else None, + "sub_text": obj.get("sub_text"), + "placeholder_expression": obj.get("placeholder_expression"), + "initial_value_expression": obj.get("initial_value_expression") + }) + return _obj + + diff --git a/authentik_client/models/prompt_challenge.py b/authentik_client/models/prompt_challenge.py new file mode 100644 index 000000000..0fc8c47e9 --- /dev/null +++ b/authentik_client/models/prompt_challenge.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from authentik_client.models.stage_prompt import StagePrompt +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PromptChallenge(BaseModel): + """ + Initial challenge being sent, define fields + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-prompt' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + fields: List[StagePrompt] + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "fields"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PromptChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + # override the default output from pydantic by calling `to_dict()` of each item in fields (list) + _items = [] + if self.fields: + for _item_fields in self.fields: + if _item_fields: + _items.append(_item_fields.to_dict()) + _dict['fields'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PromptChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-prompt', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "fields": [StagePrompt.from_dict(_item) for _item in obj["fields"]] if obj.get("fields") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/prompt_challenge_response_request.py b/authentik_client/models/prompt_challenge_response_request.py new file mode 100644 index 000000000..57835cd6c --- /dev/null +++ b/authentik_client/models/prompt_challenge_response_request.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PromptChallengeResponseRequest(BaseModel): + """ + Validate response, fields are dynamically created based on the stage + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-prompt' + additional_properties: Dict[str, Any] = {} + __properties: ClassVar[List[str]] = ["component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PromptChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * Fields in `self.additional_properties` are added to the output dict. + """ + excluded_fields: Set[str] = set([ + "additional_properties", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # puts key-value pairs in additional_properties in the top level + if self.additional_properties is not None: + for _key, _value in self.additional_properties.items(): + _dict[_key] = _value + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PromptChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-prompt' + }) + # store additional fields in additional_properties + for _key in obj.keys(): + if _key not in cls.__properties: + _obj.additional_properties[_key] = obj.get(_key) + + return _obj + + diff --git a/authentik_client/models/prompt_choice.py b/authentik_client/models/prompt_choice.py new file mode 100644 index 000000000..f7025d333 --- /dev/null +++ b/authentik_client/models/prompt_choice.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PromptChoice(BaseModel): + """ + Serializer for a single Choice field + """ # noqa: E501 + value: StrictStr + label: StrictStr + __properties: ClassVar[List[str]] = ["value", "label"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PromptChoice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PromptChoice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "value": obj.get("value"), + "label": obj.get("label") + }) + return _obj + + diff --git a/authentik_client/models/prompt_request.py b/authentik_client/models/prompt_request.py new file mode 100644 index 000000000..2b0299d6a --- /dev/null +++ b/authentik_client/models/prompt_request.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.prompt_type_enum import PromptTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PromptRequest(BaseModel): + """ + Prompt Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + field_key: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Name of the form field, also used to store the value") + label: Annotated[str, Field(min_length=1, strict=True)] + type: PromptTypeEnum + required: Optional[StrictBool] = None + placeholder: Optional[StrictStr] = Field(default=None, description="Optionally provide a short hint that describes the expected input value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple choices.") + initial_value: Optional[StrictStr] = Field(default=None, description="Optionally pre-fill the input with an initial value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple default choices.") + order: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + sub_text: Optional[StrictStr] = None + placeholder_expression: Optional[StrictBool] = None + initial_value_expression: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "field_key", "label", "type", "required", "placeholder", "initial_value", "order", "sub_text", "placeholder_expression", "initial_value_expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PromptRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PromptRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "field_key": obj.get("field_key"), + "label": obj.get("label"), + "type": obj.get("type"), + "required": obj.get("required"), + "placeholder": obj.get("placeholder"), + "initial_value": obj.get("initial_value"), + "order": obj.get("order"), + "sub_text": obj.get("sub_text"), + "placeholder_expression": obj.get("placeholder_expression"), + "initial_value_expression": obj.get("initial_value_expression") + }) + return _obj + + diff --git a/authentik_client/models/prompt_stage.py b/authentik_client/models/prompt_stage.py new file mode 100644 index 000000000..802c32959 --- /dev/null +++ b/authentik_client/models/prompt_stage.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PromptStage(BaseModel): + """ + PromptStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + fields: List[UUID] + validation_policies: Optional[List[UUID]] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "fields", "validation_policies"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PromptStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PromptStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "fields": obj.get("fields"), + "validation_policies": obj.get("validation_policies") + }) + return _obj + + diff --git a/authentik_client/models/prompt_stage_request.py b/authentik_client/models/prompt_stage_request.py new file mode 100644 index 000000000..0a80aa5d5 --- /dev/null +++ b/authentik_client/models/prompt_stage_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PromptStageRequest(BaseModel): + """ + PromptStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + fields: List[UUID] + validation_policies: Optional[List[UUID]] = None + __properties: ClassVar[List[str]] = ["name", "fields", "validation_policies"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PromptStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PromptStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "fields": obj.get("fields"), + "validation_policies": obj.get("validation_policies") + }) + return _obj + + diff --git a/authentik_client/models/prompt_type_enum.py b/authentik_client/models/prompt_type_enum.py new file mode 100644 index 000000000..6f6e79913 --- /dev/null +++ b/authentik_client/models/prompt_type_enum.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class PromptTypeEnum(str, Enum): + """ + PromptTypeEnum + """ + + """ + allowed enum values + """ + TEXT = 'text' + TEXT_AREA = 'text_area' + TEXT_READ_ONLY = 'text_read_only' + TEXT_AREA_READ_ONLY = 'text_area_read_only' + USERNAME = 'username' + EMAIL = 'email' + PASSWORD = 'password' + NUMBER = 'number' + CHECKBOX = 'checkbox' + RADIO_MINUS_BUTTON_MINUS_GROUP = 'radio-button-group' + DROPDOWN = 'dropdown' + DATE = 'date' + DATE_MINUS_TIME = 'date-time' + FILE = 'file' + SEPARATOR = 'separator' + HIDDEN = 'hidden' + STATIC = 'static' + ALERT_INFO = 'alert_info' + ALERT_WARNING = 'alert_warning' + ALERT_DANGER = 'alert_danger' + AK_MINUS_LOCALE = 'ak-locale' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of PromptTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/property_mapping.py b/authentik_client/models/property_mapping.py new file mode 100644 index 000000000..4e979b91a --- /dev/null +++ b/authentik_client/models/property_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PropertyMapping(BaseModel): + """ + PropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/property_mapping_preview.py b/authentik_client/models/property_mapping_preview.py new file mode 100644 index 000000000..f692ebe2a --- /dev/null +++ b/authentik_client/models/property_mapping_preview.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PropertyMappingPreview(BaseModel): + """ + Preview how the current user is mapped via the property mappings selected in a provider + """ # noqa: E501 + preview: Dict[str, Any] + __properties: ClassVar[List[str]] = ["preview"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PropertyMappingPreview from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "preview", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PropertyMappingPreview from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "preview": obj.get("preview") + }) + return _obj + + diff --git a/authentik_client/models/property_mapping_test_request.py b/authentik_client/models/property_mapping_test_request.py new file mode 100644 index 000000000..b55647ae1 --- /dev/null +++ b/authentik_client/models/property_mapping_test_request.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PropertyMappingTestRequest(BaseModel): + """ + Test property mapping execution for a user/group with context + """ # noqa: E501 + user: Optional[StrictInt] = None + context: Optional[Dict[str, Any]] = None + group: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["user", "context", "group"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PropertyMappingTestRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if user (nullable) is None + # and model_fields_set contains the field + if self.user is None and "user" in self.model_fields_set: + _dict['user'] = None + + # set to None if group (nullable) is None + # and model_fields_set contains the field + if self.group is None and "group" in self.model_fields_set: + _dict['group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PropertyMappingTestRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user": obj.get("user"), + "context": obj.get("context"), + "group": obj.get("group") + }) + return _obj + + diff --git a/authentik_client/models/property_mapping_test_result.py b/authentik_client/models/property_mapping_test_result.py new file mode 100644 index 000000000..3aa456105 --- /dev/null +++ b/authentik_client/models/property_mapping_test_result.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class PropertyMappingTestResult(BaseModel): + """ + Result of a Property-mapping test + """ # noqa: E501 + result: StrictStr + successful: StrictBool + __properties: ClassVar[List[str]] = ["result", "successful"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of PropertyMappingTestResult from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "result", + "successful", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of PropertyMappingTestResult from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "result": obj.get("result"), + "successful": obj.get("successful") + }) + return _obj + + diff --git a/authentik_client/models/protocol_enum.py b/authentik_client/models/protocol_enum.py new file mode 100644 index 000000000..b7d68aad5 --- /dev/null +++ b/authentik_client/models/protocol_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ProtocolEnum(str, Enum): + """ + ProtocolEnum + """ + + """ + allowed enum values + """ + RDP = 'rdp' + VNC = 'vnc' + SSH = 'ssh' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ProtocolEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/provider.py b/authentik_client/models/provider.py new file mode 100644 index 000000000..306ce799e --- /dev/null +++ b/authentik_client/models/provider.py @@ -0,0 +1,159 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Provider(BaseModel): + """ + Provider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "component", "assigned_application_slug", "assigned_application_name", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Provider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_application_slug", + "assigned_application_name", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if assigned_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_slug is None and "assigned_application_slug" in self.model_fields_set: + _dict['assigned_application_slug'] = None + + # set to None if assigned_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_name is None and "assigned_application_name" in self.model_fields_set: + _dict['assigned_application_name'] = None + + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Provider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "component": obj.get("component"), + "assigned_application_slug": obj.get("assigned_application_slug"), + "assigned_application_name": obj.get("assigned_application_name"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/provider_enum.py b/authentik_client/models/provider_enum.py new file mode 100644 index 000000000..816a5ccba --- /dev/null +++ b/authentik_client/models/provider_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ProviderEnum(str, Enum): + """ + ProviderEnum + """ + + """ + allowed enum values + """ + TWILIO = 'twilio' + GENERIC = 'generic' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ProviderEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/provider_model_enum.py b/authentik_client/models/provider_model_enum.py new file mode 100644 index 000000000..ef96c51e4 --- /dev/null +++ b/authentik_client/models/provider_model_enum.py @@ -0,0 +1,47 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ProviderModelEnum(str, Enum): + """ + ProviderModelEnum + """ + + """ + allowed enum values + """ + AUTHENTIK_PROVIDERS_GOOGLE_WORKSPACE_DOT_GOOGLEWORKSPACEPROVIDER = 'authentik_providers_google_workspace.googleworkspaceprovider' + AUTHENTIK_PROVIDERS_LDAP_DOT_LDAPPROVIDER = 'authentik_providers_ldap.ldapprovider' + AUTHENTIK_PROVIDERS_MICROSOFT_ENTRA_DOT_MICROSOFTENTRAPROVIDER = 'authentik_providers_microsoft_entra.microsoftentraprovider' + AUTHENTIK_PROVIDERS_OAUTH2_DOT_OAUTH2PROVIDER = 'authentik_providers_oauth2.oauth2provider' + AUTHENTIK_PROVIDERS_PROXY_DOT_PROXYPROVIDER = 'authentik_providers_proxy.proxyprovider' + AUTHENTIK_PROVIDERS_RAC_DOT_RACPROVIDER = 'authentik_providers_rac.racprovider' + AUTHENTIK_PROVIDERS_RADIUS_DOT_RADIUSPROVIDER = 'authentik_providers_radius.radiusprovider' + AUTHENTIK_PROVIDERS_SAML_DOT_SAMLPROVIDER = 'authentik_providers_saml.samlprovider' + AUTHENTIK_PROVIDERS_SCIM_DOT_SCIMPROVIDER = 'authentik_providers_scim.scimprovider' + AUTHENTIK_PROVIDERS_SSF_DOT_SSFPROVIDER = 'authentik_providers_ssf.ssfprovider' + AUTHENTIK_PROVIDERS_WS_FEDERATION_DOT_WSFEDERATIONPROVIDER = 'authentik_providers_ws_federation.wsfederationprovider' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ProviderModelEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/provider_type_enum.py b/authentik_client/models/provider_type_enum.py new file mode 100644 index 000000000..ba9fc5a9f --- /dev/null +++ b/authentik_client/models/provider_type_enum.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ProviderTypeEnum(str, Enum): + """ + ProviderTypeEnum + """ + + """ + allowed enum values + """ + OPENIDCONNECT = 'openidconnect' + APPLE = 'apple' + ENTRAID = 'entraid' + AZUREAD = 'azuread' + DISCORD = 'discord' + FACEBOOK = 'facebook' + GITHUB = 'github' + GITLAB = 'gitlab' + GOOGLE = 'google' + MAILCOW = 'mailcow' + OKTA = 'okta' + PATREON = 'patreon' + REDDIT = 'reddit' + SLACK = 'slack' + TWITCH = 'twitch' + TWITTER = 'twitter' + WECHAT = 'wechat' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ProviderTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/proxy_mode.py b/authentik_client/models/proxy_mode.py new file mode 100644 index 000000000..3141689ea --- /dev/null +++ b/authentik_client/models/proxy_mode.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class ProxyMode(str, Enum): + """ + ProxyMode + """ + + """ + allowed enum values + """ + PROXY = 'proxy' + FORWARD_SINGLE = 'forward_single' + FORWARD_DOMAIN = 'forward_domain' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of ProxyMode from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/proxy_outpost_config.py b/authentik_client/models/proxy_outpost_config.py new file mode 100644 index 000000000..c8dbfeff0 --- /dev/null +++ b/authentik_client/models/proxy_outpost_config.py @@ -0,0 +1,158 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional, Union +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.open_id_connect_configuration import OpenIDConnectConfiguration +from authentik_client.models.proxy_mode import ProxyMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ProxyOutpostConfig(BaseModel): + """ + Proxy provider serializer for outposts + """ # noqa: E501 + pk: StrictInt + name: StrictStr + internal_host: Optional[StrictStr] = None + external_host: StrictStr + internal_host_ssl_validation: Optional[StrictBool] = Field(default=None, description="Validate SSL Certificates of upstream servers") + client_id: Optional[Annotated[str, Field(strict=True, max_length=255)]] = None + client_secret: Optional[Annotated[str, Field(strict=True, max_length=255)]] = None + oidc_configuration: OpenIDConnectConfiguration + cookie_secret: Optional[StrictStr] = None + certificate: Optional[UUID] = None + skip_path_regex: Optional[StrictStr] = Field(default=None, description="Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression.") + basic_auth_enabled: Optional[StrictBool] = Field(default=None, description="Set a custom HTTP-Basic Authentication header based on values from authentik.") + basic_auth_password_attribute: Optional[StrictStr] = Field(default=None, description="User/Group Attribute used for the password part of the HTTP-Basic Header.") + basic_auth_user_attribute: Optional[StrictStr] = Field(default=None, description="User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used.") + mode: Optional[ProxyMode] = Field(default=None, description="Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host.") + cookie_domain: Optional[StrictStr] = None + access_token_validity: Optional[Union[StrictFloat, StrictInt]] = Field(description="Get token validity as second count") + intercept_header_auth: Optional[StrictBool] = Field(default=None, description="When enabled, this provider will intercept the authorization header and authenticate requests based on its value.") + scopes_to_request: List[StrictStr] = Field(description="Get all the scope names the outpost should request, including custom-defined ones") + assigned_application_slug: StrictStr = Field(description="Internal application name, used in URLs.") + assigned_application_name: StrictStr = Field(description="Application's display Name.") + __properties: ClassVar[List[str]] = ["pk", "name", "internal_host", "external_host", "internal_host_ssl_validation", "client_id", "client_secret", "oidc_configuration", "cookie_secret", "certificate", "skip_path_regex", "basic_auth_enabled", "basic_auth_password_attribute", "basic_auth_user_attribute", "mode", "cookie_domain", "access_token_validity", "intercept_header_auth", "scopes_to_request", "assigned_application_slug", "assigned_application_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ProxyOutpostConfig from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "oidc_configuration", + "access_token_validity", + "scopes_to_request", + "assigned_application_slug", + "assigned_application_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of oidc_configuration + if self.oidc_configuration: + _dict['oidc_configuration'] = self.oidc_configuration.to_dict() + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + # set to None if access_token_validity (nullable) is None + # and model_fields_set contains the field + if self.access_token_validity is None and "access_token_validity" in self.model_fields_set: + _dict['access_token_validity'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ProxyOutpostConfig from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "internal_host": obj.get("internal_host"), + "external_host": obj.get("external_host"), + "internal_host_ssl_validation": obj.get("internal_host_ssl_validation"), + "client_id": obj.get("client_id"), + "client_secret": obj.get("client_secret"), + "oidc_configuration": OpenIDConnectConfiguration.from_dict(obj["oidc_configuration"]) if obj.get("oidc_configuration") is not None else None, + "cookie_secret": obj.get("cookie_secret"), + "certificate": obj.get("certificate"), + "skip_path_regex": obj.get("skip_path_regex"), + "basic_auth_enabled": obj.get("basic_auth_enabled"), + "basic_auth_password_attribute": obj.get("basic_auth_password_attribute"), + "basic_auth_user_attribute": obj.get("basic_auth_user_attribute"), + "mode": obj.get("mode"), + "cookie_domain": obj.get("cookie_domain"), + "access_token_validity": obj.get("access_token_validity"), + "intercept_header_auth": obj.get("intercept_header_auth"), + "scopes_to_request": obj.get("scopes_to_request"), + "assigned_application_slug": obj.get("assigned_application_slug"), + "assigned_application_name": obj.get("assigned_application_name") + }) + return _obj + + diff --git a/authentik_client/models/proxy_provider.py b/authentik_client/models/proxy_provider.py new file mode 100644 index 000000000..fe16ca1f3 --- /dev/null +++ b/authentik_client/models/proxy_provider.py @@ -0,0 +1,215 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.proxy_mode import ProxyMode +from authentik_client.models.redirect_uri import RedirectURI +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ProxyProvider(BaseModel): + """ + ProxyProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + client_id: StrictStr + internal_host: Optional[StrictStr] = None + external_host: StrictStr + internal_host_ssl_validation: Optional[StrictBool] = Field(default=None, description="Validate SSL Certificates of upstream servers") + certificate: Optional[UUID] = None + skip_path_regex: Optional[StrictStr] = Field(default=None, description="Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression.") + basic_auth_enabled: Optional[StrictBool] = Field(default=None, description="Set a custom HTTP-Basic Authentication header based on values from authentik.") + basic_auth_password_attribute: Optional[StrictStr] = Field(default=None, description="User/Group Attribute used for the password part of the HTTP-Basic Header.") + basic_auth_user_attribute: Optional[StrictStr] = Field(default=None, description="User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used.") + mode: Optional[ProxyMode] = Field(default=None, description="Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host.") + intercept_header_auth: Optional[StrictBool] = Field(default=None, description="When enabled, this provider will intercept the authorization header and authenticate requests based on its value.") + redirect_uris: List[RedirectURI] + cookie_domain: Optional[StrictStr] = None + jwt_federation_sources: Optional[List[UUID]] = None + jwt_federation_providers: Optional[List[StrictInt]] = None + access_token_validity: Optional[StrictStr] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + refresh_token_validity: Optional[StrictStr] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + outpost_set: List[StrictStr] + __properties: ClassVar[List[str]] = ["pk", "name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "component", "assigned_application_slug", "assigned_application_name", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "client_id", "internal_host", "external_host", "internal_host_ssl_validation", "certificate", "skip_path_regex", "basic_auth_enabled", "basic_auth_password_attribute", "basic_auth_user_attribute", "mode", "intercept_header_auth", "redirect_uris", "cookie_domain", "jwt_federation_sources", "jwt_federation_providers", "access_token_validity", "refresh_token_validity", "outpost_set"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ProxyProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_application_slug", + "assigned_application_name", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "client_id", + "redirect_uris", + "outpost_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in redirect_uris (list) + _items = [] + if self.redirect_uris: + for _item_redirect_uris in self.redirect_uris: + if _item_redirect_uris: + _items.append(_item_redirect_uris.to_dict()) + _dict['redirect_uris'] = _items + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if assigned_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_slug is None and "assigned_application_slug" in self.model_fields_set: + _dict['assigned_application_slug'] = None + + # set to None if assigned_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_name is None and "assigned_application_name" in self.model_fields_set: + _dict['assigned_application_name'] = None + + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ProxyProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "component": obj.get("component"), + "assigned_application_slug": obj.get("assigned_application_slug"), + "assigned_application_name": obj.get("assigned_application_name"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "client_id": obj.get("client_id"), + "internal_host": obj.get("internal_host"), + "external_host": obj.get("external_host"), + "internal_host_ssl_validation": obj.get("internal_host_ssl_validation"), + "certificate": obj.get("certificate"), + "skip_path_regex": obj.get("skip_path_regex"), + "basic_auth_enabled": obj.get("basic_auth_enabled"), + "basic_auth_password_attribute": obj.get("basic_auth_password_attribute"), + "basic_auth_user_attribute": obj.get("basic_auth_user_attribute"), + "mode": obj.get("mode"), + "intercept_header_auth": obj.get("intercept_header_auth"), + "redirect_uris": [RedirectURI.from_dict(_item) for _item in obj["redirect_uris"]] if obj.get("redirect_uris") is not None else None, + "cookie_domain": obj.get("cookie_domain"), + "jwt_federation_sources": obj.get("jwt_federation_sources"), + "jwt_federation_providers": obj.get("jwt_federation_providers"), + "access_token_validity": obj.get("access_token_validity"), + "refresh_token_validity": obj.get("refresh_token_validity"), + "outpost_set": obj.get("outpost_set") + }) + return _obj + + diff --git a/authentik_client/models/proxy_provider_request.py b/authentik_client/models/proxy_provider_request.py new file mode 100644 index 000000000..06df603be --- /dev/null +++ b/authentik_client/models/proxy_provider_request.py @@ -0,0 +1,140 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.proxy_mode import ProxyMode +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ProxyProviderRequest(BaseModel): + """ + ProxyProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + internal_host: Optional[StrictStr] = None + external_host: Annotated[str, Field(min_length=1, strict=True)] + internal_host_ssl_validation: Optional[StrictBool] = Field(default=None, description="Validate SSL Certificates of upstream servers") + certificate: Optional[UUID] = None + skip_path_regex: Optional[StrictStr] = Field(default=None, description="Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression.") + basic_auth_enabled: Optional[StrictBool] = Field(default=None, description="Set a custom HTTP-Basic Authentication header based on values from authentik.") + basic_auth_password_attribute: Optional[StrictStr] = Field(default=None, description="User/Group Attribute used for the password part of the HTTP-Basic Header.") + basic_auth_user_attribute: Optional[StrictStr] = Field(default=None, description="User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used.") + mode: Optional[ProxyMode] = Field(default=None, description="Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host.") + intercept_header_auth: Optional[StrictBool] = Field(default=None, description="When enabled, this provider will intercept the authorization header and authenticate requests based on its value.") + cookie_domain: Optional[StrictStr] = None + jwt_federation_sources: Optional[List[UUID]] = None + jwt_federation_providers: Optional[List[StrictInt]] = None + access_token_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + refresh_token_validity: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "internal_host", "external_host", "internal_host_ssl_validation", "certificate", "skip_path_regex", "basic_auth_enabled", "basic_auth_password_attribute", "basic_auth_user_attribute", "mode", "intercept_header_auth", "cookie_domain", "jwt_federation_sources", "jwt_federation_providers", "access_token_validity", "refresh_token_validity"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ProxyProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ProxyProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "internal_host": obj.get("internal_host"), + "external_host": obj.get("external_host"), + "internal_host_ssl_validation": obj.get("internal_host_ssl_validation"), + "certificate": obj.get("certificate"), + "skip_path_regex": obj.get("skip_path_regex"), + "basic_auth_enabled": obj.get("basic_auth_enabled"), + "basic_auth_password_attribute": obj.get("basic_auth_password_attribute"), + "basic_auth_user_attribute": obj.get("basic_auth_user_attribute"), + "mode": obj.get("mode"), + "intercept_header_auth": obj.get("intercept_header_auth"), + "cookie_domain": obj.get("cookie_domain"), + "jwt_federation_sources": obj.get("jwt_federation_sources"), + "jwt_federation_providers": obj.get("jwt_federation_providers"), + "access_token_validity": obj.get("access_token_validity"), + "refresh_token_validity": obj.get("refresh_token_validity") + }) + return _obj + + diff --git a/authentik_client/models/rac_property_mapping.py b/authentik_client/models/rac_property_mapping.py new file mode 100644 index 000000000..847853bf3 --- /dev/null +++ b/authentik_client/models/rac_property_mapping.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RACPropertyMapping(BaseModel): + """ + RACPropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: Optional[StrictStr] = None + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + static_settings: Dict[str, Any] + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "static_settings"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RACPropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RACPropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "static_settings": obj.get("static_settings") + }) + return _obj + + diff --git a/authentik_client/models/rac_property_mapping_request.py b/authentik_client/models/rac_property_mapping_request.py new file mode 100644 index 000000000..b9cc9bb52 --- /dev/null +++ b/authentik_client/models/rac_property_mapping_request.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RACPropertyMappingRequest(BaseModel): + """ + RACPropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Optional[StrictStr] = None + static_settings: Dict[str, Any] + __properties: ClassVar[List[str]] = ["managed", "name", "expression", "static_settings"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RACPropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RACPropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "static_settings": obj.get("static_settings") + }) + return _obj + + diff --git a/authentik_client/models/rac_provider.py b/authentik_client/models/rac_provider.py new file mode 100644 index 000000000..9cee87957 --- /dev/null +++ b/authentik_client/models/rac_provider.py @@ -0,0 +1,167 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RACProvider(BaseModel): + """ + RACProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + settings: Optional[Dict[str, Any]] = None + outpost_set: List[StrictStr] + connection_expiry: Optional[StrictStr] = Field(default=None, description="Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)") + delete_token_on_disconnect: Optional[StrictBool] = Field(default=None, description="When set to true, connection tokens will be deleted upon disconnect.") + __properties: ClassVar[List[str]] = ["pk", "name", "authentication_flow", "authorization_flow", "property_mappings", "component", "assigned_application_slug", "assigned_application_name", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "settings", "outpost_set", "connection_expiry", "delete_token_on_disconnect"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RACProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_application_slug", + "assigned_application_name", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "outpost_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if assigned_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_slug is None and "assigned_application_slug" in self.model_fields_set: + _dict['assigned_application_slug'] = None + + # set to None if assigned_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_name is None and "assigned_application_name" in self.model_fields_set: + _dict['assigned_application_name'] = None + + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RACProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "property_mappings": obj.get("property_mappings"), + "component": obj.get("component"), + "assigned_application_slug": obj.get("assigned_application_slug"), + "assigned_application_name": obj.get("assigned_application_name"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "settings": obj.get("settings"), + "outpost_set": obj.get("outpost_set"), + "connection_expiry": obj.get("connection_expiry"), + "delete_token_on_disconnect": obj.get("delete_token_on_disconnect") + }) + return _obj + + diff --git a/authentik_client/models/rac_provider_request.py b/authentik_client/models/rac_provider_request.py new file mode 100644 index 000000000..7cd63dd79 --- /dev/null +++ b/authentik_client/models/rac_provider_request.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RACProviderRequest(BaseModel): + """ + RACProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + property_mappings: Optional[List[UUID]] = None + settings: Optional[Dict[str, Any]] = None + connection_expiry: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)") + delete_token_on_disconnect: Optional[StrictBool] = Field(default=None, description="When set to true, connection tokens will be deleted upon disconnect.") + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "property_mappings", "settings", "connection_expiry", "delete_token_on_disconnect"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RACProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RACProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "property_mappings": obj.get("property_mappings"), + "settings": obj.get("settings"), + "connection_expiry": obj.get("connection_expiry"), + "delete_token_on_disconnect": obj.get("delete_token_on_disconnect") + }) + return _obj + + diff --git a/authentik_client/models/radius_check_access.py b/authentik_client/models/radius_check_access.py new file mode 100644 index 000000000..a338b8529 --- /dev/null +++ b/authentik_client/models/radius_check_access.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.policy_test_result import PolicyTestResult +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RadiusCheckAccess(BaseModel): + """ + Base serializer class which doesn't implement create/update methods + """ # noqa: E501 + attributes: Optional[StrictStr] = None + access: PolicyTestResult + __properties: ClassVar[List[str]] = ["attributes", "access"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RadiusCheckAccess from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of access + if self.access: + _dict['access'] = self.access.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RadiusCheckAccess from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "attributes": obj.get("attributes"), + "access": PolicyTestResult.from_dict(obj["access"]) if obj.get("access") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/radius_outpost_config.py b/authentik_client/models/radius_outpost_config.py new file mode 100644 index 000000000..7045f1cde --- /dev/null +++ b/authentik_client/models/radius_outpost_config.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RadiusOutpostConfig(BaseModel): + """ + RadiusProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + application_slug: StrictStr + auth_flow_slug: StrictStr + client_networks: Optional[StrictStr] = Field(default=None, description="List of CIDRs (comma-separated) that clients can connect from. A more specific CIDR will match before a looser one. Clients connecting from a non-specified CIDR will be dropped.") + shared_secret: Optional[StrictStr] = Field(default=None, description="Shared secret between clients and server to hash packets.") + mfa_support: Optional[StrictBool] = Field(default=None, description="When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.") + certificate: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["pk", "name", "application_slug", "auth_flow_slug", "client_networks", "shared_secret", "mfa_support", "certificate"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RadiusOutpostConfig from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RadiusOutpostConfig from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "application_slug": obj.get("application_slug"), + "auth_flow_slug": obj.get("auth_flow_slug"), + "client_networks": obj.get("client_networks"), + "shared_secret": obj.get("shared_secret"), + "mfa_support": obj.get("mfa_support"), + "certificate": obj.get("certificate") + }) + return _obj + + diff --git a/authentik_client/models/radius_provider.py b/authentik_client/models/radius_provider.py new file mode 100644 index 000000000..e2ba6c798 --- /dev/null +++ b/authentik_client/models/radius_provider.py @@ -0,0 +1,176 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RadiusProvider(BaseModel): + """ + RadiusProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + client_networks: Optional[StrictStr] = Field(default=None, description="List of CIDRs (comma-separated) that clients can connect from. A more specific CIDR will match before a looser one. Clients connecting from a non-specified CIDR will be dropped.") + shared_secret: Optional[StrictStr] = Field(default=None, description="Shared secret between clients and server to hash packets.") + outpost_set: List[StrictStr] + mfa_support: Optional[StrictBool] = Field(default=None, description="When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.") + certificate: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["pk", "name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "component", "assigned_application_slug", "assigned_application_name", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "client_networks", "shared_secret", "outpost_set", "mfa_support", "certificate"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RadiusProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_application_slug", + "assigned_application_name", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "outpost_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if assigned_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_slug is None and "assigned_application_slug" in self.model_fields_set: + _dict['assigned_application_slug'] = None + + # set to None if assigned_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_name is None and "assigned_application_name" in self.model_fields_set: + _dict['assigned_application_name'] = None + + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RadiusProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "component": obj.get("component"), + "assigned_application_slug": obj.get("assigned_application_slug"), + "assigned_application_name": obj.get("assigned_application_name"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "client_networks": obj.get("client_networks"), + "shared_secret": obj.get("shared_secret"), + "outpost_set": obj.get("outpost_set"), + "mfa_support": obj.get("mfa_support"), + "certificate": obj.get("certificate") + }) + return _obj + + diff --git a/authentik_client/models/radius_provider_property_mapping.py b/authentik_client/models/radius_provider_property_mapping.py new file mode 100644 index 000000000..48b1c1cfc --- /dev/null +++ b/authentik_client/models/radius_provider_property_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RadiusProviderPropertyMapping(BaseModel): + """ + RadiusProviderPropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RadiusProviderPropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RadiusProviderPropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/radius_provider_property_mapping_request.py b/authentik_client/models/radius_provider_property_mapping_request.py new file mode 100644 index 000000000..6c5002646 --- /dev/null +++ b/authentik_client/models/radius_provider_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RadiusProviderPropertyMappingRequest(BaseModel): + """ + RadiusProviderPropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RadiusProviderPropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RadiusProviderPropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/radius_provider_request.py b/authentik_client/models/radius_provider_request.py new file mode 100644 index 000000000..bf82ed1b4 --- /dev/null +++ b/authentik_client/models/radius_provider_request.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RadiusProviderRequest(BaseModel): + """ + RadiusProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + client_networks: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="List of CIDRs (comma-separated) that clients can connect from. A more specific CIDR will match before a looser one. Clients connecting from a non-specified CIDR will be dropped.") + shared_secret: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Shared secret between clients and server to hash packets.") + mfa_support: Optional[StrictBool] = Field(default=None, description="When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.") + certificate: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "client_networks", "shared_secret", "mfa_support", "certificate"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RadiusProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if certificate (nullable) is None + # and model_fields_set contains the field + if self.certificate is None and "certificate" in self.model_fields_set: + _dict['certificate'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RadiusProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "client_networks": obj.get("client_networks"), + "shared_secret": obj.get("shared_secret"), + "mfa_support": obj.get("mfa_support"), + "certificate": obj.get("certificate") + }) + return _obj + + diff --git a/authentik_client/models/redirect_challenge.py b/authentik_client/models/redirect_challenge.py new file mode 100644 index 000000000..8683bf976 --- /dev/null +++ b/authentik_client/models/redirect_challenge.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RedirectChallenge(BaseModel): + """ + Challenge type to redirect the client + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'xak-flow-redirect' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + to: StrictStr + final_redirect: Optional[StrictBool] = False + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "to", "final_redirect"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RedirectChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RedirectChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'xak-flow-redirect', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "to": obj.get("to"), + "final_redirect": obj.get("final_redirect") if obj.get("final_redirect") is not None else False + }) + return _obj + + diff --git a/authentik_client/models/redirect_challenge_response_request.py b/authentik_client/models/redirect_challenge_response_request.py new file mode 100644 index 000000000..d41725043 --- /dev/null +++ b/authentik_client/models/redirect_challenge_response_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RedirectChallengeResponseRequest(BaseModel): + """ + Redirect challenge response + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'xak-flow-redirect' + to: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["component", "to"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RedirectChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RedirectChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'xak-flow-redirect', + "to": obj.get("to") + }) + return _obj + + diff --git a/authentik_client/models/redirect_stage.py b/authentik_client/models/redirect_stage.py new file mode 100644 index 000000000..bcad529b7 --- /dev/null +++ b/authentik_client/models/redirect_stage.py @@ -0,0 +1,136 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.redirect_stage_mode_enum import RedirectStageModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RedirectStage(BaseModel): + """ + RedirectStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + keep_context: Optional[StrictBool] = None + mode: RedirectStageModeEnum + target_static: Optional[StrictStr] = None + target_flow: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "keep_context", "mode", "target_static", "target_flow"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RedirectStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if target_flow (nullable) is None + # and model_fields_set contains the field + if self.target_flow is None and "target_flow" in self.model_fields_set: + _dict['target_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RedirectStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "keep_context": obj.get("keep_context"), + "mode": obj.get("mode"), + "target_static": obj.get("target_static"), + "target_flow": obj.get("target_flow") + }) + return _obj + + diff --git a/authentik_client/models/redirect_stage_mode_enum.py b/authentik_client/models/redirect_stage_mode_enum.py new file mode 100644 index 000000000..da0d86437 --- /dev/null +++ b/authentik_client/models/redirect_stage_mode_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class RedirectStageModeEnum(str, Enum): + """ + RedirectStageModeEnum + """ + + """ + allowed enum values + """ + STATIC = 'static' + FLOW = 'flow' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of RedirectStageModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/redirect_stage_request.py b/authentik_client/models/redirect_stage_request.py new file mode 100644 index 000000000..4cb4d1198 --- /dev/null +++ b/authentik_client/models/redirect_stage_request.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.redirect_stage_mode_enum import RedirectStageModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RedirectStageRequest(BaseModel): + """ + RedirectStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + keep_context: Optional[StrictBool] = None + mode: RedirectStageModeEnum + target_static: Optional[StrictStr] = None + target_flow: Optional[UUID] = None + __properties: ClassVar[List[str]] = ["name", "keep_context", "mode", "target_static", "target_flow"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RedirectStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if target_flow (nullable) is None + # and model_fields_set contains the field + if self.target_flow is None and "target_flow" in self.model_fields_set: + _dict['target_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RedirectStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "keep_context": obj.get("keep_context"), + "mode": obj.get("mode"), + "target_static": obj.get("target_static"), + "target_flow": obj.get("target_flow") + }) + return _obj + + diff --git a/authentik_client/models/redirect_uri.py b/authentik_client/models/redirect_uri.py new file mode 100644 index 000000000..0c8e1cdf5 --- /dev/null +++ b/authentik_client/models/redirect_uri.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.matching_mode_enum import MatchingModeEnum +from authentik_client.models.redirect_uri_type_enum import RedirectURITypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RedirectURI(BaseModel): + """ + A single allowed redirect URI entry + """ # noqa: E501 + matching_mode: MatchingModeEnum + url: StrictStr + redirect_uri_type: Optional[RedirectURITypeEnum] = None + __properties: ClassVar[List[str]] = ["matching_mode", "url", "redirect_uri_type"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RedirectURI from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RedirectURI from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "matching_mode": obj.get("matching_mode"), + "url": obj.get("url"), + "redirect_uri_type": obj.get("redirect_uri_type") + }) + return _obj + + diff --git a/authentik_client/models/redirect_uri_request.py b/authentik_client/models/redirect_uri_request.py new file mode 100644 index 000000000..ecb843faf --- /dev/null +++ b/authentik_client/models/redirect_uri_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.matching_mode_enum import MatchingModeEnum +from authentik_client.models.redirect_uri_type_enum import RedirectURITypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RedirectURIRequest(BaseModel): + """ + A single allowed redirect URI entry + """ # noqa: E501 + matching_mode: MatchingModeEnum + url: Annotated[str, Field(min_length=1, strict=True)] + redirect_uri_type: Optional[RedirectURITypeEnum] = None + __properties: ClassVar[List[str]] = ["matching_mode", "url", "redirect_uri_type"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RedirectURIRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RedirectURIRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "matching_mode": obj.get("matching_mode"), + "url": obj.get("url"), + "redirect_uri_type": obj.get("redirect_uri_type") + }) + return _obj + + diff --git a/authentik_client/models/redirect_uri_type_enum.py b/authentik_client/models/redirect_uri_type_enum.py new file mode 100644 index 000000000..074a926bb --- /dev/null +++ b/authentik_client/models/redirect_uri_type_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class RedirectURITypeEnum(str, Enum): + """ + RedirectURITypeEnum + """ + + """ + allowed enum values + """ + AUTHORIZATION = 'authorization' + LOGOUT = 'logout' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of RedirectURITypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/related_group.py b/authentik_client/models/related_group.py new file mode 100644 index 000000000..aa3377110 --- /dev/null +++ b/authentik_client/models/related_group.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RelatedGroup(BaseModel): + """ + Stripped down group serializer to show relevant children/parents for groups + """ # noqa: E501 + pk: UUID + name: StrictStr + is_superuser: Optional[StrictBool] = Field(default=None, description="Users added to this group will be superusers.") + attributes: Optional[Dict[str, Any]] = None + group_uuid: UUID + __properties: ClassVar[List[str]] = ["pk", "name", "is_superuser", "attributes", "group_uuid"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RelatedGroup from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "group_uuid", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RelatedGroup from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "is_superuser": obj.get("is_superuser"), + "attributes": obj.get("attributes"), + "group_uuid": obj.get("group_uuid") + }) + return _obj + + diff --git a/authentik_client/models/related_rule.py b/authentik_client/models/related_rule.py new file mode 100644 index 000000000..0ac8d947f --- /dev/null +++ b/authentik_client/models/related_rule.py @@ -0,0 +1,120 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.reviewer_group import ReviewerGroup +from authentik_client.models.reviewer_user import ReviewerUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RelatedRule(BaseModel): + """ + Mixin to validate that a valid enterprise license exists before allowing to save the object + """ # noqa: E501 + id: Optional[UUID] = None + name: StrictStr + reviewer_groups: List[ReviewerGroup] + min_reviewers: StrictInt + reviewers: List[ReviewerUser] + __properties: ClassVar[List[str]] = ["id", "name", "reviewer_groups", "min_reviewers", "reviewers"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RelatedRule from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "reviewer_groups", + "min_reviewers", + "reviewers", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in reviewer_groups (list) + _items = [] + if self.reviewer_groups: + for _item_reviewer_groups in self.reviewer_groups: + if _item_reviewer_groups: + _items.append(_item_reviewer_groups.to_dict()) + _dict['reviewer_groups'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in reviewers (list) + _items = [] + if self.reviewers: + for _item_reviewers in self.reviewers: + if _item_reviewers: + _items.append(_item_reviewers.to_dict()) + _dict['reviewers'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RelatedRule from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "name": obj.get("name"), + "reviewer_groups": [ReviewerGroup.from_dict(_item) for _item in obj["reviewer_groups"]] if obj.get("reviewer_groups") is not None else None, + "min_reviewers": obj.get("min_reviewers"), + "reviewers": [ReviewerUser.from_dict(_item) for _item in obj["reviewers"]] if obj.get("reviewers") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/reputation.py b/authentik_client/models/reputation.py new file mode 100644 index 000000000..18dea78af --- /dev/null +++ b/authentik_client/models/reputation.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Reputation(BaseModel): + """ + Reputation Serializer + """ # noqa: E501 + pk: Optional[UUID] = None + identifier: StrictStr + ip: StrictStr + ip_geo_data: Optional[Dict[str, Any]] = None + ip_asn_data: Optional[Dict[str, Any]] = None + score: Optional[Annotated[int, Field(le=9223372036854775807, strict=True, ge=-9223372036854775808)]] = None + updated: datetime + __properties: ClassVar[List[str]] = ["pk", "identifier", "ip", "ip_geo_data", "ip_asn_data", "score", "updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Reputation from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Reputation from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "identifier": obj.get("identifier"), + "ip": obj.get("ip"), + "ip_geo_data": obj.get("ip_geo_data"), + "ip_asn_data": obj.get("ip_asn_data"), + "score": obj.get("score"), + "updated": obj.get("updated") + }) + return _obj + + diff --git a/authentik_client/models/reputation_policy.py b/authentik_client/models/reputation_policy.py new file mode 100644 index 000000000..8d9a3af13 --- /dev/null +++ b/authentik_client/models/reputation_policy.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ReputationPolicy(BaseModel): + """ + Reputation Policy Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + bound_to: StrictInt = Field(description="Return objects policy is bound to") + check_ip: Optional[StrictBool] = None + check_username: Optional[StrictBool] = None + threshold: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + __properties: ClassVar[List[str]] = ["pk", "name", "execution_logging", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "bound_to", "check_ip", "check_username", "threshold"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ReputationPolicy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "bound_to", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ReputationPolicy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "bound_to": obj.get("bound_to"), + "check_ip": obj.get("check_ip"), + "check_username": obj.get("check_username"), + "threshold": obj.get("threshold") + }) + return _obj + + diff --git a/authentik_client/models/reputation_policy_request.py b/authentik_client/models/reputation_policy_request.py new file mode 100644 index 000000000..e9e647729 --- /dev/null +++ b/authentik_client/models/reputation_policy_request.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ReputationPolicyRequest(BaseModel): + """ + Reputation Policy Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + check_ip: Optional[StrictBool] = None + check_username: Optional[StrictBool] = None + threshold: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)]] = None + __properties: ClassVar[List[str]] = ["name", "execution_logging", "check_ip", "check_username", "threshold"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ReputationPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ReputationPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "check_ip": obj.get("check_ip"), + "check_username": obj.get("check_username"), + "threshold": obj.get("threshold") + }) + return _obj + + diff --git a/authentik_client/models/review.py b/authentik_client/models/review.py new file mode 100644 index 000000000..2b72073a3 --- /dev/null +++ b/authentik_client/models/review.py @@ -0,0 +1,114 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.reviewer_user import ReviewerUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Review(BaseModel): + """ + Mixin to validate that a valid enterprise license exists before allowing to save the object + """ # noqa: E501 + id: UUID + iteration: UUID + reviewer: ReviewerUser + timestamp: datetime + note: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["id", "iteration", "reviewer", "timestamp", "note"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Review from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "reviewer", + "timestamp", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of reviewer + if self.reviewer: + _dict['reviewer'] = self.reviewer.to_dict() + # set to None if note (nullable) is None + # and model_fields_set contains the field + if self.note is None and "note" in self.model_fields_set: + _dict['note'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Review from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "iteration": obj.get("iteration"), + "reviewer": ReviewerUser.from_dict(obj["reviewer"]) if obj.get("reviewer") is not None else None, + "timestamp": obj.get("timestamp"), + "note": obj.get("note") + }) + return _obj + + diff --git a/authentik_client/models/review_request.py b/authentik_client/models/review_request.py new file mode 100644 index 000000000..991091f66 --- /dev/null +++ b/authentik_client/models/review_request.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ReviewRequest(BaseModel): + """ + Mixin to validate that a valid enterprise license exists before allowing to save the object + """ # noqa: E501 + iteration: UUID + note: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["iteration", "note"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ReviewRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if note (nullable) is None + # and model_fields_set contains the field + if self.note is None and "note" in self.model_fields_set: + _dict['note'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ReviewRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "iteration": obj.get("iteration"), + "note": obj.get("note") + }) + return _obj + + diff --git a/authentik_client/models/reviewer_group.py b/authentik_client/models/reviewer_group.py new file mode 100644 index 000000000..f47eb7c1f --- /dev/null +++ b/authentik_client/models/reviewer_group.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ReviewerGroup(BaseModel): + """ + ReviewerGroup + """ # noqa: E501 + pk: UUID + name: StrictStr + __properties: ClassVar[List[str]] = ["pk", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ReviewerGroup from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ReviewerGroup from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/reviewer_user.py b/authentik_client/models/reviewer_user.py new file mode 100644 index 000000000..07dea014a --- /dev/null +++ b/authentik_client/models/reviewer_user.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ReviewerUser(BaseModel): + """ + ReviewerUser + """ # noqa: E501 + pk: StrictInt + uuid: UUID + username: Annotated[str, Field(strict=True, max_length=150)] = Field(description="Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.") + name: StrictStr = Field(description="User's display name.") + __properties: ClassVar[List[str]] = ["pk", "uuid", "username", "name"] + + @field_validator('username') + def username_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[\w.@+-]+$", value): + raise ValueError(r"must validate the regular expression /^[\w.@+-]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ReviewerUser from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "uuid", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ReviewerUser from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "uuid": obj.get("uuid"), + "username": obj.get("username"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/role.py b/authentik_client/models/role.py new file mode 100644 index 000000000..f97404744 --- /dev/null +++ b/authentik_client/models/role.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Role(BaseModel): + """ + Role serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + __properties: ClassVar[List[str]] = ["pk", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Role from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Role from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/role_assigned_object_permission.py b/authentik_client/models/role_assigned_object_permission.py new file mode 100644 index 000000000..5e55a49ef --- /dev/null +++ b/authentik_client/models/role_assigned_object_permission.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from authentik_client.models.role_model_permission import RoleModelPermission +from authentik_client.models.role_object_permission import RoleObjectPermission +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RoleAssignedObjectPermission(BaseModel): + """ + Roles assigned object permission serializer + """ # noqa: E501 + role_pk: StrictStr + name: StrictStr + object_permissions: List[RoleObjectPermission] + model_permissions: List[RoleModelPermission] + __properties: ClassVar[List[str]] = ["role_pk", "name", "object_permissions", "model_permissions"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RoleAssignedObjectPermission from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "role_pk", + "name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in object_permissions (list) + _items = [] + if self.object_permissions: + for _item_object_permissions in self.object_permissions: + if _item_object_permissions: + _items.append(_item_object_permissions.to_dict()) + _dict['object_permissions'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in model_permissions (list) + _items = [] + if self.model_permissions: + for _item_model_permissions in self.model_permissions: + if _item_model_permissions: + _items.append(_item_model_permissions.to_dict()) + _dict['model_permissions'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RoleAssignedObjectPermission from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "role_pk": obj.get("role_pk"), + "name": obj.get("name"), + "object_permissions": [RoleObjectPermission.from_dict(_item) for _item in obj["object_permissions"]] if obj.get("object_permissions") is not None else None, + "model_permissions": [RoleModelPermission.from_dict(_item) for _item in obj["model_permissions"]] if obj.get("model_permissions") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/role_model_permission.py b/authentik_client/models/role_model_permission.py new file mode 100644 index 000000000..72d759b66 --- /dev/null +++ b/authentik_client/models/role_model_permission.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RoleModelPermission(BaseModel): + """ + Role-bound object level permission + """ # noqa: E501 + id: StrictInt + codename: StrictStr + model: StrictStr + app_label: StrictStr + name: StrictStr + __properties: ClassVar[List[str]] = ["id", "codename", "model", "app_label", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RoleModelPermission from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "codename", + "model", + "app_label", + "name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RoleModelPermission from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "codename": obj.get("codename"), + "model": obj.get("model"), + "app_label": obj.get("app_label"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/role_object_permission.py b/authentik_client/models/role_object_permission.py new file mode 100644 index 000000000..38a538275 --- /dev/null +++ b/authentik_client/models/role_object_permission.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RoleObjectPermission(BaseModel): + """ + Role-bound object level permission + """ # noqa: E501 + id: StrictInt + codename: StrictStr + model: StrictStr + app_label: StrictStr + object_pk: StrictStr + name: StrictStr + __properties: ClassVar[List[str]] = ["id", "codename", "model", "app_label", "object_pk", "name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RoleObjectPermission from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "codename", + "model", + "app_label", + "name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RoleObjectPermission from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "codename": obj.get("codename"), + "model": obj.get("model"), + "app_label": obj.get("app_label"), + "object_pk": obj.get("object_pk"), + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/role_request.py b/authentik_client/models/role_request.py new file mode 100644 index 000000000..341d172a5 --- /dev/null +++ b/authentik_client/models/role_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class RoleRequest(BaseModel): + """ + Role serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of RoleRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of RoleRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/saml_bindings_enum.py b/authentik_client/models/saml_bindings_enum.py new file mode 100644 index 000000000..f414f5ae4 --- /dev/null +++ b/authentik_client/models/saml_bindings_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SAMLBindingsEnum(str, Enum): + """ + SAMLBindingsEnum + """ + + """ + allowed enum values + """ + REDIRECT = 'redirect' + POST = 'post' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SAMLBindingsEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/saml_logout_methods.py b/authentik_client/models/saml_logout_methods.py new file mode 100644 index 000000000..664f4ac30 --- /dev/null +++ b/authentik_client/models/saml_logout_methods.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SAMLLogoutMethods(str, Enum): + """ + SAMLLogoutMethods + """ + + """ + allowed enum values + """ + FRONTCHANNEL_IFRAME = 'frontchannel_iframe' + FRONTCHANNEL_NATIVE = 'frontchannel_native' + BACKCHANNEL = 'backchannel' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SAMLLogoutMethods from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/saml_metadata.py b/authentik_client/models/saml_metadata.py new file mode 100644 index 000000000..bee340bc8 --- /dev/null +++ b/authentik_client/models/saml_metadata.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SAMLMetadata(BaseModel): + """ + SAML Provider Metadata serializer + """ # noqa: E501 + metadata: StrictStr + download_url: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["metadata", "download_url"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SAMLMetadata from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if download_url (nullable) is None + # and model_fields_set contains the field + if self.download_url is None and "download_url" in self.model_fields_set: + _dict['download_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SAMLMetadata from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "metadata": obj.get("metadata"), + "download_url": obj.get("download_url") + }) + return _obj + + diff --git a/authentik_client/models/saml_name_id_policy_enum.py b/authentik_client/models/saml_name_id_policy_enum.py new file mode 100644 index 000000000..913529fb1 --- /dev/null +++ b/authentik_client/models/saml_name_id_policy_enum.py @@ -0,0 +1,42 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SAMLNameIDPolicyEnum(str, Enum): + """ + SAMLNameIDPolicyEnum + """ + + """ + allowed enum values + """ + URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_1_DOT_1_COLON_NAMEID_MINUS_FORMAT_COLON_EMAIL_ADDRESS = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress' + URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_NAMEID_MINUS_FORMAT_COLON_PERSISTENT = 'urn:oasis:names:tc:SAML:2.0:nameid-format:persistent' + URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_1_DOT_1_COLON_NAMEID_MINUS_FORMAT_COLON_X509_SUBJECT_NAME = 'urn:oasis:names:tc:SAML:1.1:nameid-format:X509SubjectName' + URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_NAMEID_MINUS_FORMAT_COLON_WINDOWS_DOMAIN_QUALIFIED_NAME = 'urn:oasis:names:tc:SAML:2.0:nameid-format:WindowsDomainQualifiedName' + URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_NAMEID_MINUS_FORMAT_COLON_TRANSIENT = 'urn:oasis:names:tc:SAML:2.0:nameid-format:transient' + URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_1_DOT_1_COLON_NAMEID_MINUS_FORMAT_COLON_UNSPECIFIED = 'urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SAMLNameIDPolicyEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/saml_property_mapping.py b/authentik_client/models/saml_property_mapping.py new file mode 100644 index 000000000..99a8cbb15 --- /dev/null +++ b/authentik_client/models/saml_property_mapping.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SAMLPropertyMapping(BaseModel): + """ + SAMLPropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + saml_name: StrictStr + friendly_name: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "saml_name", "friendly_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SAMLPropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if friendly_name (nullable) is None + # and model_fields_set contains the field + if self.friendly_name is None and "friendly_name" in self.model_fields_set: + _dict['friendly_name'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SAMLPropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "saml_name": obj.get("saml_name"), + "friendly_name": obj.get("friendly_name") + }) + return _obj + + diff --git a/authentik_client/models/saml_property_mapping_request.py b/authentik_client/models/saml_property_mapping_request.py new file mode 100644 index 000000000..4498af4d4 --- /dev/null +++ b/authentik_client/models/saml_property_mapping_request.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SAMLPropertyMappingRequest(BaseModel): + """ + SAMLPropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + saml_name: Annotated[str, Field(min_length=1, strict=True)] + friendly_name: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["managed", "name", "expression", "saml_name", "friendly_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SAMLPropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if friendly_name (nullable) is None + # and model_fields_set contains the field + if self.friendly_name is None and "friendly_name" in self.model_fields_set: + _dict['friendly_name'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SAMLPropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "saml_name": obj.get("saml_name"), + "friendly_name": obj.get("friendly_name") + }) + return _obj + + diff --git a/authentik_client/models/saml_provider.py b/authentik_client/models/saml_provider.py new file mode 100644 index 000000000..9c251509f --- /dev/null +++ b/authentik_client/models/saml_provider.py @@ -0,0 +1,271 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.saml_bindings_enum import SAMLBindingsEnum +from authentik_client.models.saml_logout_methods import SAMLLogoutMethods +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SAMLProvider(BaseModel): + """ + SAMLProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + acs_url: StrictStr + sls_url: Optional[StrictStr] = Field(default=None, description="Single Logout Service URL where the logout response should be sent.") + audience: Optional[StrictStr] = Field(default=None, description="Value of the audience restriction field of the assertion. When left empty, no audience restriction will be added.") + issuer_override: Optional[StrictStr] = Field(default=None, description="Also known as EntityID. Providing a value overrides the default issuer generated by authentik.") + assertion_valid_not_before: Optional[StrictStr] = Field(default=None, description="Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3).") + assertion_valid_not_on_or_after: Optional[StrictStr] = Field(default=None, description="Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + session_valid_not_on_or_after: Optional[StrictStr] = Field(default=None, description="Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + name_id_mapping: Optional[UUID] = Field(default=None, description="Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered") + authn_context_class_ref_mapping: Optional[UUID] = Field(default=None, description="Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate.") + digest_algorithm: Optional[DigestAlgorithmEnum] = None + signature_algorithm: Optional[SignatureAlgorithmEnum] = None + signing_kp: Optional[UUID] = Field(default=None, description="Keypair used to sign outgoing Responses going to the Service Provider.") + verification_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default.") + encryption_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key.") + sign_assertion: Optional[StrictBool] = None + sign_response: Optional[StrictBool] = None + sign_logout_request: Optional[StrictBool] = None + sign_logout_response: Optional[StrictBool] = None + sp_binding: Optional[SAMLBindingsEnum] = Field(default=None, description="This determines how authentik sends the response back to the Service Provider.") + sls_binding: Optional[SAMLBindingsEnum] = Field(default=None, description="This determines how authentik sends the logout response back to the Service Provider.") + logout_method: Optional[SAMLLogoutMethods] = Field(default=None, description="Method to use for logout. Front-channel iframe loads all logout URLs simultaneously in hidden iframes. Front-channel native uses your active browser tab to send post requests and redirect to providers. Back-channel sends logout requests directly from the server without user interaction (requires POST SLS binding).") + default_relay_state: Optional[StrictStr] = Field(default=None, description="Default relay_state value for IDP-initiated logins") + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None + url_download_metadata: StrictStr = Field(description="Get metadata download URL") + url_issuer: StrictStr = Field(description="Get Issuer/EntityID URL") + url_unified: StrictStr = Field(description="Get unified SAML endpoint URL (handles SSO and SLO)") + url_unified_init: StrictStr = Field(description="Get IdP-initiated SAML URL") + url_sso_post: StrictStr = Field(description="Get SSO Post URL") + url_sso_redirect: StrictStr = Field(description="Get SSO Redirect URL") + url_sso_init: StrictStr = Field(description="Get SSO IDP-Initiated URL") + url_slo_post: StrictStr = Field(description="Get SLO POST URL") + url_slo_redirect: StrictStr = Field(description="Get SLO redirect URL") + __properties: ClassVar[List[str]] = ["pk", "name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "component", "assigned_application_slug", "assigned_application_name", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "acs_url", "sls_url", "audience", "issuer_override", "assertion_valid_not_before", "assertion_valid_not_on_or_after", "session_valid_not_on_or_after", "name_id_mapping", "authn_context_class_ref_mapping", "digest_algorithm", "signature_algorithm", "signing_kp", "verification_kp", "encryption_kp", "sign_assertion", "sign_response", "sign_logout_request", "sign_logout_response", "sp_binding", "sls_binding", "logout_method", "default_relay_state", "default_name_id_policy", "url_download_metadata", "url_issuer", "url_unified", "url_unified_init", "url_sso_post", "url_sso_redirect", "url_sso_init", "url_slo_post", "url_slo_redirect"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SAMLProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_application_slug", + "assigned_application_name", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "url_download_metadata", + "url_issuer", + "url_unified", + "url_unified_init", + "url_sso_post", + "url_sso_redirect", + "url_sso_init", + "url_slo_post", + "url_slo_redirect", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if assigned_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_slug is None and "assigned_application_slug" in self.model_fields_set: + _dict['assigned_application_slug'] = None + + # set to None if assigned_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_name is None and "assigned_application_name" in self.model_fields_set: + _dict['assigned_application_name'] = None + + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + # set to None if name_id_mapping (nullable) is None + # and model_fields_set contains the field + if self.name_id_mapping is None and "name_id_mapping" in self.model_fields_set: + _dict['name_id_mapping'] = None + + # set to None if authn_context_class_ref_mapping (nullable) is None + # and model_fields_set contains the field + if self.authn_context_class_ref_mapping is None and "authn_context_class_ref_mapping" in self.model_fields_set: + _dict['authn_context_class_ref_mapping'] = None + + # set to None if signing_kp (nullable) is None + # and model_fields_set contains the field + if self.signing_kp is None and "signing_kp" in self.model_fields_set: + _dict['signing_kp'] = None + + # set to None if verification_kp (nullable) is None + # and model_fields_set contains the field + if self.verification_kp is None and "verification_kp" in self.model_fields_set: + _dict['verification_kp'] = None + + # set to None if encryption_kp (nullable) is None + # and model_fields_set contains the field + if self.encryption_kp is None and "encryption_kp" in self.model_fields_set: + _dict['encryption_kp'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SAMLProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "component": obj.get("component"), + "assigned_application_slug": obj.get("assigned_application_slug"), + "assigned_application_name": obj.get("assigned_application_name"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "acs_url": obj.get("acs_url"), + "sls_url": obj.get("sls_url"), + "audience": obj.get("audience"), + "issuer_override": obj.get("issuer_override"), + "assertion_valid_not_before": obj.get("assertion_valid_not_before"), + "assertion_valid_not_on_or_after": obj.get("assertion_valid_not_on_or_after"), + "session_valid_not_on_or_after": obj.get("session_valid_not_on_or_after"), + "name_id_mapping": obj.get("name_id_mapping"), + "authn_context_class_ref_mapping": obj.get("authn_context_class_ref_mapping"), + "digest_algorithm": obj.get("digest_algorithm"), + "signature_algorithm": obj.get("signature_algorithm"), + "signing_kp": obj.get("signing_kp"), + "verification_kp": obj.get("verification_kp"), + "encryption_kp": obj.get("encryption_kp"), + "sign_assertion": obj.get("sign_assertion"), + "sign_response": obj.get("sign_response"), + "sign_logout_request": obj.get("sign_logout_request"), + "sign_logout_response": obj.get("sign_logout_response"), + "sp_binding": obj.get("sp_binding"), + "sls_binding": obj.get("sls_binding"), + "logout_method": obj.get("logout_method"), + "default_relay_state": obj.get("default_relay_state"), + "default_name_id_policy": obj.get("default_name_id_policy"), + "url_download_metadata": obj.get("url_download_metadata"), + "url_issuer": obj.get("url_issuer"), + "url_unified": obj.get("url_unified"), + "url_unified_init": obj.get("url_unified_init"), + "url_sso_post": obj.get("url_sso_post"), + "url_sso_redirect": obj.get("url_sso_redirect"), + "url_sso_init": obj.get("url_sso_init"), + "url_slo_post": obj.get("url_slo_post"), + "url_slo_redirect": obj.get("url_slo_redirect") + }) + return _obj + + diff --git a/authentik_client/models/saml_provider_request.py b/authentik_client/models/saml_provider_request.py new file mode 100644 index 000000000..c63f2dd78 --- /dev/null +++ b/authentik_client/models/saml_provider_request.py @@ -0,0 +1,180 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.saml_bindings_enum import SAMLBindingsEnum +from authentik_client.models.saml_logout_methods import SAMLLogoutMethods +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SAMLProviderRequest(BaseModel): + """ + SAMLProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + acs_url: Annotated[str, Field(min_length=1, strict=True)] + sls_url: Optional[StrictStr] = Field(default=None, description="Single Logout Service URL where the logout response should be sent.") + audience: Optional[StrictStr] = Field(default=None, description="Value of the audience restriction field of the assertion. When left empty, no audience restriction will be added.") + issuer_override: Optional[StrictStr] = Field(default=None, description="Also known as EntityID. Providing a value overrides the default issuer generated by authentik.") + assertion_valid_not_before: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3).") + assertion_valid_not_on_or_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + session_valid_not_on_or_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + name_id_mapping: Optional[UUID] = Field(default=None, description="Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered") + authn_context_class_ref_mapping: Optional[UUID] = Field(default=None, description="Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate.") + digest_algorithm: Optional[DigestAlgorithmEnum] = None + signature_algorithm: Optional[SignatureAlgorithmEnum] = None + signing_kp: Optional[UUID] = Field(default=None, description="Keypair used to sign outgoing Responses going to the Service Provider.") + verification_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default.") + encryption_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key.") + sign_assertion: Optional[StrictBool] = None + sign_response: Optional[StrictBool] = None + sign_logout_request: Optional[StrictBool] = None + sign_logout_response: Optional[StrictBool] = None + sp_binding: Optional[SAMLBindingsEnum] = Field(default=None, description="This determines how authentik sends the response back to the Service Provider.") + sls_binding: Optional[SAMLBindingsEnum] = Field(default=None, description="This determines how authentik sends the logout response back to the Service Provider.") + logout_method: Optional[SAMLLogoutMethods] = Field(default=None, description="Method to use for logout. Front-channel iframe loads all logout URLs simultaneously in hidden iframes. Front-channel native uses your active browser tab to send post requests and redirect to providers. Back-channel sends logout requests directly from the server without user interaction (requires POST SLS binding).") + default_relay_state: Optional[StrictStr] = Field(default=None, description="Default relay_state value for IDP-initiated logins") + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "acs_url", "sls_url", "audience", "issuer_override", "assertion_valid_not_before", "assertion_valid_not_on_or_after", "session_valid_not_on_or_after", "name_id_mapping", "authn_context_class_ref_mapping", "digest_algorithm", "signature_algorithm", "signing_kp", "verification_kp", "encryption_kp", "sign_assertion", "sign_response", "sign_logout_request", "sign_logout_response", "sp_binding", "sls_binding", "logout_method", "default_relay_state", "default_name_id_policy"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SAMLProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if name_id_mapping (nullable) is None + # and model_fields_set contains the field + if self.name_id_mapping is None and "name_id_mapping" in self.model_fields_set: + _dict['name_id_mapping'] = None + + # set to None if authn_context_class_ref_mapping (nullable) is None + # and model_fields_set contains the field + if self.authn_context_class_ref_mapping is None and "authn_context_class_ref_mapping" in self.model_fields_set: + _dict['authn_context_class_ref_mapping'] = None + + # set to None if signing_kp (nullable) is None + # and model_fields_set contains the field + if self.signing_kp is None and "signing_kp" in self.model_fields_set: + _dict['signing_kp'] = None + + # set to None if verification_kp (nullable) is None + # and model_fields_set contains the field + if self.verification_kp is None and "verification_kp" in self.model_fields_set: + _dict['verification_kp'] = None + + # set to None if encryption_kp (nullable) is None + # and model_fields_set contains the field + if self.encryption_kp is None and "encryption_kp" in self.model_fields_set: + _dict['encryption_kp'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SAMLProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "acs_url": obj.get("acs_url"), + "sls_url": obj.get("sls_url"), + "audience": obj.get("audience"), + "issuer_override": obj.get("issuer_override"), + "assertion_valid_not_before": obj.get("assertion_valid_not_before"), + "assertion_valid_not_on_or_after": obj.get("assertion_valid_not_on_or_after"), + "session_valid_not_on_or_after": obj.get("session_valid_not_on_or_after"), + "name_id_mapping": obj.get("name_id_mapping"), + "authn_context_class_ref_mapping": obj.get("authn_context_class_ref_mapping"), + "digest_algorithm": obj.get("digest_algorithm"), + "signature_algorithm": obj.get("signature_algorithm"), + "signing_kp": obj.get("signing_kp"), + "verification_kp": obj.get("verification_kp"), + "encryption_kp": obj.get("encryption_kp"), + "sign_assertion": obj.get("sign_assertion"), + "sign_response": obj.get("sign_response"), + "sign_logout_request": obj.get("sign_logout_request"), + "sign_logout_response": obj.get("sign_logout_response"), + "sp_binding": obj.get("sp_binding"), + "sls_binding": obj.get("sls_binding"), + "logout_method": obj.get("logout_method"), + "default_relay_state": obj.get("default_relay_state"), + "default_name_id_policy": obj.get("default_name_id_policy") + }) + return _obj + + diff --git a/authentik_client/models/saml_source.py b/authentik_client/models/saml_source.py new file mode 100644 index 000000000..c7fd5ad7e --- /dev/null +++ b/authentik_client/models/saml_source.py @@ -0,0 +1,240 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.binding_type_enum import BindingTypeEnum +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from authentik_client.models.themed_urls import ThemedUrls +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SAMLSource(BaseModel): + """ + SAMLSource Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr = Field(description="Source's display Name.") + slug: Annotated[str, Field(strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + managed: Optional[StrictStr] = Field(description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + user_path_template: Optional[StrictStr] = None + icon: Optional[StrictStr] = None + icon_url: StrictStr + icon_themed_urls: Optional[ThemedUrls] + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + pre_authentication_flow: UUID = Field(description="Flow used before authentication.") + issuer: Optional[StrictStr] = Field(default=None, description="Also known as Entity ID. Defaults the Metadata URL.") + sso_url: StrictStr = Field(description="URL that the initial Login request is sent to.") + slo_url: Optional[StrictStr] = Field(default=None, description="Optional URL if your IDP supports Single-Logout.") + allow_idp_initiated: Optional[StrictBool] = Field(default=None, description="Allows authentication flows initiated by the IdP. This can be a security risk, as no validation of the request ID is done.") + force_authn: Optional[StrictBool] = Field(default=None, description="When enabled, the IdP will re-authenticate the user even if a session exists.") + name_id_policy: Optional[SAMLNameIDPolicyEnum] = Field(default=None, description="NameID Policy sent to the IdP. Can be unset, in which case no Policy is sent.") + binding_type: Optional[BindingTypeEnum] = None + verification_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default.") + signing_kp: Optional[UUID] = Field(default=None, description="Keypair used to sign outgoing Responses going to the Identity Provider.") + digest_algorithm: Optional[DigestAlgorithmEnum] = None + signature_algorithm: Optional[SignatureAlgorithmEnum] = None + temporary_user_delete_after: Optional[StrictStr] = Field(default=None, description="Time offset when temporary users should be deleted. This only applies if your IDP uses the NameID Format 'transient', and the user doesn't log out manually. (Format: hours=1;minutes=2;seconds=3).") + encryption_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key.") + signed_assertion: Optional[StrictBool] = None + signed_response: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["pk", "name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "policy_engine_mode", "user_matching_mode", "managed", "user_path_template", "icon", "icon_url", "icon_themed_urls", "group_matching_mode", "pre_authentication_flow", "issuer", "sso_url", "slo_url", "allow_idp_initiated", "force_authn", "name_id_policy", "binding_type", "verification_kp", "signing_kp", "digest_algorithm", "signature_algorithm", "temporary_user_delete_after", "encryption_kp", "signed_assertion", "signed_response"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SAMLSource from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "managed", + "icon_url", + "icon_themed_urls", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of icon_themed_urls + if self.icon_themed_urls: + _dict['icon_themed_urls'] = self.icon_themed_urls.to_dict() + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if icon_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.icon_themed_urls is None and "icon_themed_urls" in self.model_fields_set: + _dict['icon_themed_urls'] = None + + # set to None if slo_url (nullable) is None + # and model_fields_set contains the field + if self.slo_url is None and "slo_url" in self.model_fields_set: + _dict['slo_url'] = None + + # set to None if verification_kp (nullable) is None + # and model_fields_set contains the field + if self.verification_kp is None and "verification_kp" in self.model_fields_set: + _dict['verification_kp'] = None + + # set to None if signing_kp (nullable) is None + # and model_fields_set contains the field + if self.signing_kp is None and "signing_kp" in self.model_fields_set: + _dict['signing_kp'] = None + + # set to None if encryption_kp (nullable) is None + # and model_fields_set contains the field + if self.encryption_kp is None and "encryption_kp" in self.model_fields_set: + _dict['encryption_kp'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SAMLSource from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "managed": obj.get("managed"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "icon_url": obj.get("icon_url"), + "icon_themed_urls": ThemedUrls.from_dict(obj["icon_themed_urls"]) if obj.get("icon_themed_urls") is not None else None, + "group_matching_mode": obj.get("group_matching_mode"), + "pre_authentication_flow": obj.get("pre_authentication_flow"), + "issuer": obj.get("issuer"), + "sso_url": obj.get("sso_url"), + "slo_url": obj.get("slo_url"), + "allow_idp_initiated": obj.get("allow_idp_initiated"), + "force_authn": obj.get("force_authn"), + "name_id_policy": obj.get("name_id_policy"), + "binding_type": obj.get("binding_type"), + "verification_kp": obj.get("verification_kp"), + "signing_kp": obj.get("signing_kp"), + "digest_algorithm": obj.get("digest_algorithm"), + "signature_algorithm": obj.get("signature_algorithm"), + "temporary_user_delete_after": obj.get("temporary_user_delete_after"), + "encryption_kp": obj.get("encryption_kp"), + "signed_assertion": obj.get("signed_assertion"), + "signed_response": obj.get("signed_response") + }) + return _obj + + diff --git a/authentik_client/models/saml_source_property_mapping.py b/authentik_client/models/saml_source_property_mapping.py new file mode 100644 index 000000000..747d8c600 --- /dev/null +++ b/authentik_client/models/saml_source_property_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SAMLSourcePropertyMapping(BaseModel): + """ + SAMLSourcePropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SAMLSourcePropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SAMLSourcePropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/saml_source_property_mapping_request.py b/authentik_client/models/saml_source_property_mapping_request.py new file mode 100644 index 000000000..0b9f79348 --- /dev/null +++ b/authentik_client/models/saml_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SAMLSourcePropertyMappingRequest(BaseModel): + """ + SAMLSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SAMLSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SAMLSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/saml_source_request.py b/authentik_client/models/saml_source_request.py new file mode 100644 index 000000000..527f2ad14 --- /dev/null +++ b/authentik_client/models/saml_source_request.py @@ -0,0 +1,194 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.binding_type_enum import BindingTypeEnum +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SAMLSourceRequest(BaseModel): + """ + SAMLSource Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Source's display Name.") + slug: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + group_matching_mode: Optional[GroupMatchingModeEnum] = Field(default=None, description="How the source determines if an existing group should be used or a new group created.") + pre_authentication_flow: UUID = Field(description="Flow used before authentication.") + issuer: Optional[StrictStr] = Field(default=None, description="Also known as Entity ID. Defaults the Metadata URL.") + sso_url: Annotated[str, Field(min_length=1, strict=True)] = Field(description="URL that the initial Login request is sent to.") + slo_url: Optional[StrictStr] = Field(default=None, description="Optional URL if your IDP supports Single-Logout.") + allow_idp_initiated: Optional[StrictBool] = Field(default=None, description="Allows authentication flows initiated by the IdP. This can be a security risk, as no validation of the request ID is done.") + force_authn: Optional[StrictBool] = Field(default=None, description="When enabled, the IdP will re-authenticate the user even if a session exists.") + name_id_policy: Optional[SAMLNameIDPolicyEnum] = Field(default=None, description="NameID Policy sent to the IdP. Can be unset, in which case no Policy is sent.") + binding_type: Optional[BindingTypeEnum] = None + verification_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default.") + signing_kp: Optional[UUID] = Field(default=None, description="Keypair used to sign outgoing Responses going to the Identity Provider.") + digest_algorithm: Optional[DigestAlgorithmEnum] = None + signature_algorithm: Optional[SignatureAlgorithmEnum] = None + temporary_user_delete_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Time offset when temporary users should be deleted. This only applies if your IDP uses the NameID Format 'transient', and the user doesn't log out manually. (Format: hours=1;minutes=2;seconds=3).") + encryption_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key.") + signed_assertion: Optional[StrictBool] = None + signed_response: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "group_matching_mode", "pre_authentication_flow", "issuer", "sso_url", "slo_url", "allow_idp_initiated", "force_authn", "name_id_policy", "binding_type", "verification_kp", "signing_kp", "digest_algorithm", "signature_algorithm", "temporary_user_delete_after", "encryption_kp", "signed_assertion", "signed_response"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SAMLSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if slo_url (nullable) is None + # and model_fields_set contains the field + if self.slo_url is None and "slo_url" in self.model_fields_set: + _dict['slo_url'] = None + + # set to None if verification_kp (nullable) is None + # and model_fields_set contains the field + if self.verification_kp is None and "verification_kp" in self.model_fields_set: + _dict['verification_kp'] = None + + # set to None if signing_kp (nullable) is None + # and model_fields_set contains the field + if self.signing_kp is None and "signing_kp" in self.model_fields_set: + _dict['signing_kp'] = None + + # set to None if encryption_kp (nullable) is None + # and model_fields_set contains the field + if self.encryption_kp is None and "encryption_kp" in self.model_fields_set: + _dict['encryption_kp'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SAMLSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "group_matching_mode": obj.get("group_matching_mode"), + "pre_authentication_flow": obj.get("pre_authentication_flow"), + "issuer": obj.get("issuer"), + "sso_url": obj.get("sso_url"), + "slo_url": obj.get("slo_url"), + "allow_idp_initiated": obj.get("allow_idp_initiated"), + "force_authn": obj.get("force_authn"), + "name_id_policy": obj.get("name_id_policy"), + "binding_type": obj.get("binding_type"), + "verification_kp": obj.get("verification_kp"), + "signing_kp": obj.get("signing_kp"), + "digest_algorithm": obj.get("digest_algorithm"), + "signature_algorithm": obj.get("signature_algorithm"), + "temporary_user_delete_after": obj.get("temporary_user_delete_after"), + "encryption_kp": obj.get("encryption_kp"), + "signed_assertion": obj.get("signed_assertion"), + "signed_response": obj.get("signed_response") + }) + return _obj + + diff --git a/authentik_client/models/schedule.py b/authentik_client/models/schedule.py new file mode 100644 index 000000000..a1a9b879d --- /dev/null +++ b/authentik_client/models/schedule.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.last_task_status_enum import LastTaskStatusEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Schedule(BaseModel): + """ + Schedule + """ # noqa: E501 + id: UUID + identifier: Optional[StrictStr] = Field(description="Unique schedule identifier") + uid: StrictStr + actor_name: StrictStr = Field(description="Dramatiq actor to call") + rel_obj_app_label: StrictStr + rel_obj_model: StrictStr + rel_obj_id: Optional[StrictStr] = None + crontab: StrictStr = Field(description="When to schedule tasks") + paused: Optional[StrictBool] = Field(default=None, description="Pause this schedule") + next_run: datetime + description: Optional[StrictStr] + last_task_status: Optional[LastTaskStatusEnum] + __properties: ClassVar[List[str]] = ["id", "identifier", "uid", "actor_name", "rel_obj_app_label", "rel_obj_model", "rel_obj_id", "crontab", "paused", "next_run", "description", "last_task_status"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Schedule from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "identifier", + "uid", + "actor_name", + "rel_obj_app_label", + "rel_obj_model", + "next_run", + "description", + "last_task_status", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if identifier (nullable) is None + # and model_fields_set contains the field + if self.identifier is None and "identifier" in self.model_fields_set: + _dict['identifier'] = None + + # set to None if rel_obj_id (nullable) is None + # and model_fields_set contains the field + if self.rel_obj_id is None and "rel_obj_id" in self.model_fields_set: + _dict['rel_obj_id'] = None + + # set to None if description (nullable) is None + # and model_fields_set contains the field + if self.description is None and "description" in self.model_fields_set: + _dict['description'] = None + + # set to None if last_task_status (nullable) is None + # and model_fields_set contains the field + if self.last_task_status is None and "last_task_status" in self.model_fields_set: + _dict['last_task_status'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Schedule from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "identifier": obj.get("identifier"), + "uid": obj.get("uid"), + "actor_name": obj.get("actor_name"), + "rel_obj_app_label": obj.get("rel_obj_app_label"), + "rel_obj_model": obj.get("rel_obj_model"), + "rel_obj_id": obj.get("rel_obj_id"), + "crontab": obj.get("crontab"), + "paused": obj.get("paused"), + "next_run": obj.get("next_run"), + "description": obj.get("description"), + "last_task_status": obj.get("last_task_status") + }) + return _obj + + diff --git a/authentik_client/models/schedule_request.py b/authentik_client/models/schedule_request.py new file mode 100644 index 000000000..0b886f918 --- /dev/null +++ b/authentik_client/models/schedule_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ScheduleRequest(BaseModel): + """ + ScheduleRequest + """ # noqa: E501 + rel_obj_id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + crontab: Annotated[str, Field(min_length=1, strict=True)] = Field(description="When to schedule tasks") + paused: Optional[StrictBool] = Field(default=None, description="Pause this schedule") + __properties: ClassVar[List[str]] = ["rel_obj_id", "crontab", "paused"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ScheduleRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if rel_obj_id (nullable) is None + # and model_fields_set contains the field + if self.rel_obj_id is None and "rel_obj_id" in self.model_fields_set: + _dict['rel_obj_id'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ScheduleRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "rel_obj_id": obj.get("rel_obj_id"), + "crontab": obj.get("crontab"), + "paused": obj.get("paused") + }) + return _obj + + diff --git a/authentik_client/models/scim_authentication_mode_enum.py b/authentik_client/models/scim_authentication_mode_enum.py new file mode 100644 index 000000000..d1abef587 --- /dev/null +++ b/authentik_client/models/scim_authentication_mode_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SCIMAuthenticationModeEnum(str, Enum): + """ + SCIMAuthenticationModeEnum + """ + + """ + allowed enum values + """ + TOKEN = 'token' + OAUTH = 'oauth' + OAUTH_INTERACTIVE = 'oauth_interactive' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SCIMAuthenticationModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/scim_mapping.py b/authentik_client/models/scim_mapping.py new file mode 100644 index 000000000..022b96cd9 --- /dev/null +++ b/authentik_client/models/scim_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMMapping(BaseModel): + """ + SCIMMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/scim_mapping_request.py b/authentik_client/models/scim_mapping_request.py new file mode 100644 index 000000000..c75fb8c64 --- /dev/null +++ b/authentik_client/models/scim_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMMappingRequest(BaseModel): + """ + SCIMMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/scim_provider.py b/authentik_client/models/scim_provider.py new file mode 100644 index 000000000..a29cd6f3f --- /dev/null +++ b/authentik_client/models/scim_provider.py @@ -0,0 +1,201 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.compatibility_mode_enum import CompatibilityModeEnum +from authentik_client.models.scim_authentication_mode_enum import SCIMAuthenticationModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMProvider(BaseModel): + """ + SCIMProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + property_mappings: Optional[List[UUID]] = None + property_mappings_group: Optional[List[UUID]] = Field(default=None, description="Property mappings used for group creation/updating.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + url: StrictStr = Field(description="Base URL to SCIM requests, usually ends in /v2") + verify_certificates: Optional[StrictBool] = None + auth_mode: Optional[SCIMAuthenticationModeEnum] = None + auth_oauth: Optional[UUID] = Field(default=None, description="OAuth Source used for authentication") + auth_oauth_params: Optional[Dict[str, Any]] = Field(default=None, description="Additional OAuth parameters, such as grant_type") + auth_oauth_token_last_updated: Optional[datetime] + auth_oauth_token_expires: Optional[datetime] + auth_oauth_url_callback: Optional[StrictStr] + auth_oauth_url_start: Optional[StrictStr] + compatibility_mode: Optional[CompatibilityModeEnum] = Field(default=None, description="Alter authentik behavior for vendor-specific SCIM implementations.") + service_provider_config_cache_timeout: Optional[StrictStr] = Field(default=None, description="Cache duration for ServiceProviderConfig responses. Set minutes=0 to disable.") + exclude_users_service_account: Optional[StrictBool] = None + sync_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Controls the number of objects synced in a single task") + sync_page_timeout: Optional[StrictStr] = Field(default=None, description="Timeout for synchronization of a single page") + group_filters: Optional[List[UUID]] = Field(default=None, description="Group filters used to define sync-scope for groups.") + dry_run: Optional[StrictBool] = Field(default=None, description="When enabled, provider will not modify or create objects in the remote system.") + __properties: ClassVar[List[str]] = ["pk", "name", "property_mappings", "property_mappings_group", "component", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "url", "verify_certificates", "auth_mode", "auth_oauth", "auth_oauth_params", "auth_oauth_token_last_updated", "auth_oauth_token_expires", "auth_oauth_url_callback", "auth_oauth_url_start", "compatibility_mode", "service_provider_config_cache_timeout", "exclude_users_service_account", "sync_page_size", "sync_page_timeout", "group_filters", "dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "auth_oauth_token_last_updated", + "auth_oauth_token_expires", + "auth_oauth_url_callback", + "auth_oauth_url_start", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + # set to None if auth_oauth (nullable) is None + # and model_fields_set contains the field + if self.auth_oauth is None and "auth_oauth" in self.model_fields_set: + _dict['auth_oauth'] = None + + # set to None if auth_oauth_token_last_updated (nullable) is None + # and model_fields_set contains the field + if self.auth_oauth_token_last_updated is None and "auth_oauth_token_last_updated" in self.model_fields_set: + _dict['auth_oauth_token_last_updated'] = None + + # set to None if auth_oauth_token_expires (nullable) is None + # and model_fields_set contains the field + if self.auth_oauth_token_expires is None and "auth_oauth_token_expires" in self.model_fields_set: + _dict['auth_oauth_token_expires'] = None + + # set to None if auth_oauth_url_callback (nullable) is None + # and model_fields_set contains the field + if self.auth_oauth_url_callback is None and "auth_oauth_url_callback" in self.model_fields_set: + _dict['auth_oauth_url_callback'] = None + + # set to None if auth_oauth_url_start (nullable) is None + # and model_fields_set contains the field + if self.auth_oauth_url_start is None and "auth_oauth_url_start" in self.model_fields_set: + _dict['auth_oauth_url_start'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "property_mappings": obj.get("property_mappings"), + "property_mappings_group": obj.get("property_mappings_group"), + "component": obj.get("component"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "url": obj.get("url"), + "verify_certificates": obj.get("verify_certificates"), + "auth_mode": obj.get("auth_mode"), + "auth_oauth": obj.get("auth_oauth"), + "auth_oauth_params": obj.get("auth_oauth_params"), + "auth_oauth_token_last_updated": obj.get("auth_oauth_token_last_updated"), + "auth_oauth_token_expires": obj.get("auth_oauth_token_expires"), + "auth_oauth_url_callback": obj.get("auth_oauth_url_callback"), + "auth_oauth_url_start": obj.get("auth_oauth_url_start"), + "compatibility_mode": obj.get("compatibility_mode"), + "service_provider_config_cache_timeout": obj.get("service_provider_config_cache_timeout"), + "exclude_users_service_account": obj.get("exclude_users_service_account"), + "sync_page_size": obj.get("sync_page_size"), + "sync_page_timeout": obj.get("sync_page_timeout"), + "group_filters": obj.get("group_filters"), + "dry_run": obj.get("dry_run") + }) + return _obj + + diff --git a/authentik_client/models/scim_provider_group.py b/authentik_client/models/scim_provider_group.py new file mode 100644 index 000000000..f7485768f --- /dev/null +++ b/authentik_client/models/scim_provider_group.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.partial_group import PartialGroup +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMProviderGroup(BaseModel): + """ + SCIMProviderGroup Serializer + """ # noqa: E501 + id: UUID + scim_id: StrictStr + group: UUID + group_obj: PartialGroup + provider: StrictInt + attributes: Dict[str, Any] + __properties: ClassVar[List[str]] = ["id", "scim_id", "group", "group_obj", "provider", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMProviderGroup from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "group_obj", + "attributes", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of group_obj + if self.group_obj: + _dict['group_obj'] = self.group_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMProviderGroup from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "scim_id": obj.get("scim_id"), + "group": obj.get("group"), + "group_obj": PartialGroup.from_dict(obj["group_obj"]) if obj.get("group_obj") is not None else None, + "provider": obj.get("provider"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/scim_provider_group_request.py b/authentik_client/models/scim_provider_group_request.py new file mode 100644 index 000000000..1430144a8 --- /dev/null +++ b/authentik_client/models/scim_provider_group_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMProviderGroupRequest(BaseModel): + """ + SCIMProviderGroup Serializer + """ # noqa: E501 + scim_id: Annotated[str, Field(min_length=1, strict=True)] + group: UUID + provider: StrictInt + __properties: ClassVar[List[str]] = ["scim_id", "group", "provider"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMProviderGroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMProviderGroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "scim_id": obj.get("scim_id"), + "group": obj.get("group"), + "provider": obj.get("provider") + }) + return _obj + + diff --git a/authentik_client/models/scim_provider_request.py b/authentik_client/models/scim_provider_request.py new file mode 100644 index 000000000..14acb47ba --- /dev/null +++ b/authentik_client/models/scim_provider_request.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.compatibility_mode_enum import CompatibilityModeEnum +from authentik_client.models.scim_authentication_mode_enum import SCIMAuthenticationModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMProviderRequest(BaseModel): + """ + SCIMProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + property_mappings: Optional[List[UUID]] = None + property_mappings_group: Optional[List[UUID]] = Field(default=None, description="Property mappings used for group creation/updating.") + url: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Base URL to SCIM requests, usually ends in /v2") + verify_certificates: Optional[StrictBool] = None + token: Optional[StrictStr] = Field(default=None, description="Authentication token") + auth_mode: Optional[SCIMAuthenticationModeEnum] = None + auth_oauth: Optional[UUID] = Field(default=None, description="OAuth Source used for authentication") + auth_oauth_params: Optional[Dict[str, Any]] = Field(default=None, description="Additional OAuth parameters, such as grant_type") + compatibility_mode: Optional[CompatibilityModeEnum] = Field(default=None, description="Alter authentik behavior for vendor-specific SCIM implementations.") + service_provider_config_cache_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Cache duration for ServiceProviderConfig responses. Set minutes=0 to disable.") + exclude_users_service_account: Optional[StrictBool] = None + sync_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Controls the number of objects synced in a single task") + sync_page_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Timeout for synchronization of a single page") + group_filters: Optional[List[UUID]] = Field(default=None, description="Group filters used to define sync-scope for groups.") + dry_run: Optional[StrictBool] = Field(default=None, description="When enabled, provider will not modify or create objects in the remote system.") + __properties: ClassVar[List[str]] = ["name", "property_mappings", "property_mappings_group", "url", "verify_certificates", "token", "auth_mode", "auth_oauth", "auth_oauth_params", "compatibility_mode", "service_provider_config_cache_timeout", "exclude_users_service_account", "sync_page_size", "sync_page_timeout", "group_filters", "dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if auth_oauth (nullable) is None + # and model_fields_set contains the field + if self.auth_oauth is None and "auth_oauth" in self.model_fields_set: + _dict['auth_oauth'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "property_mappings": obj.get("property_mappings"), + "property_mappings_group": obj.get("property_mappings_group"), + "url": obj.get("url"), + "verify_certificates": obj.get("verify_certificates"), + "token": obj.get("token"), + "auth_mode": obj.get("auth_mode"), + "auth_oauth": obj.get("auth_oauth"), + "auth_oauth_params": obj.get("auth_oauth_params"), + "compatibility_mode": obj.get("compatibility_mode"), + "service_provider_config_cache_timeout": obj.get("service_provider_config_cache_timeout"), + "exclude_users_service_account": obj.get("exclude_users_service_account"), + "sync_page_size": obj.get("sync_page_size"), + "sync_page_timeout": obj.get("sync_page_timeout"), + "group_filters": obj.get("group_filters"), + "dry_run": obj.get("dry_run") + }) + return _obj + + diff --git a/authentik_client/models/scim_provider_user.py b/authentik_client/models/scim_provider_user.py new file mode 100644 index 000000000..1b658389e --- /dev/null +++ b/authentik_client/models/scim_provider_user.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMProviderUser(BaseModel): + """ + SCIMProviderUser Serializer + """ # noqa: E501 + id: UUID + scim_id: StrictStr + user: StrictInt + user_obj: PartialUser + provider: StrictInt + attributes: Dict[str, Any] + __properties: ClassVar[List[str]] = ["id", "scim_id", "user", "user_obj", "provider", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMProviderUser from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + "user_obj", + "attributes", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user_obj + if self.user_obj: + _dict['user_obj'] = self.user_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMProviderUser from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "scim_id": obj.get("scim_id"), + "user": obj.get("user"), + "user_obj": PartialUser.from_dict(obj["user_obj"]) if obj.get("user_obj") is not None else None, + "provider": obj.get("provider"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/scim_provider_user_request.py b/authentik_client/models/scim_provider_user_request.py new file mode 100644 index 000000000..1bfef0d1d --- /dev/null +++ b/authentik_client/models/scim_provider_user_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMProviderUserRequest(BaseModel): + """ + SCIMProviderUser Serializer + """ # noqa: E501 + scim_id: Annotated[str, Field(min_length=1, strict=True)] + user: StrictInt + provider: StrictInt + __properties: ClassVar[List[str]] = ["scim_id", "user", "provider"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMProviderUserRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMProviderUserRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "scim_id": obj.get("scim_id"), + "user": obj.get("user"), + "provider": obj.get("provider") + }) + return _obj + + diff --git a/authentik_client/models/scim_source.py b/authentik_client/models/scim_source.py new file mode 100644 index 000000000..7d67ef686 --- /dev/null +++ b/authentik_client/models/scim_source.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.token import Token +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMSource(BaseModel): + """ + SCIMSource Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr = Field(description="Source's display Name.") + slug: Annotated[str, Field(strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + managed: Optional[StrictStr] = Field(description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + user_path_template: Optional[StrictStr] = None + root_url: StrictStr = Field(description="Get Root URL") + token_obj: Token + __properties: ClassVar[List[str]] = ["pk", "name", "slug", "enabled", "user_property_mappings", "group_property_mappings", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "managed", "user_path_template", "root_url", "token_obj"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMSource from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "managed", + "root_url", + "token_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of token_obj + if self.token_obj: + _dict['token_obj'] = self.token_obj.to_dict() + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMSource from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "managed": obj.get("managed"), + "user_path_template": obj.get("user_path_template"), + "root_url": obj.get("root_url"), + "token_obj": Token.from_dict(obj["token_obj"]) if obj.get("token_obj") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/scim_source_group.py b/authentik_client/models/scim_source_group.py new file mode 100644 index 000000000..e9ad5b450 --- /dev/null +++ b/authentik_client/models/scim_source_group.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.partial_group import PartialGroup +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMSourceGroup(BaseModel): + """ + SCIMSourceGroup Serializer + """ # noqa: E501 + id: Optional[StrictStr] = None + external_id: StrictStr + group: UUID + group_obj: PartialGroup + source: UUID + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["id", "external_id", "group", "group_obj", "source", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMSourceGroup from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "group_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of group_obj + if self.group_obj: + _dict['group_obj'] = self.group_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMSourceGroup from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "external_id": obj.get("external_id"), + "group": obj.get("group"), + "group_obj": PartialGroup.from_dict(obj["group_obj"]) if obj.get("group_obj") is not None else None, + "source": obj.get("source"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/scim_source_group_request.py b/authentik_client/models/scim_source_group_request.py new file mode 100644 index 000000000..d24995457 --- /dev/null +++ b/authentik_client/models/scim_source_group_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMSourceGroupRequest(BaseModel): + """ + SCIMSourceGroup Serializer + """ # noqa: E501 + id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + external_id: Annotated[str, Field(min_length=1, strict=True)] + group: UUID + source: UUID + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["id", "external_id", "group", "source", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMSourceGroupRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMSourceGroupRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "external_id": obj.get("external_id"), + "group": obj.get("group"), + "source": obj.get("source"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/scim_source_property_mapping.py b/authentik_client/models/scim_source_property_mapping.py new file mode 100644 index 000000000..a93fdb7c2 --- /dev/null +++ b/authentik_client/models/scim_source_property_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMSourcePropertyMapping(BaseModel): + """ + SCIMSourcePropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMSourcePropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMSourcePropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/scim_source_property_mapping_request.py b/authentik_client/models/scim_source_property_mapping_request.py new file mode 100644 index 000000000..c1dc68e0b --- /dev/null +++ b/authentik_client/models/scim_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMSourcePropertyMappingRequest(BaseModel): + """ + SCIMSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/scim_source_request.py b/authentik_client/models/scim_source_request.py new file mode 100644 index 000000000..cd2178fd5 --- /dev/null +++ b/authentik_client/models/scim_source_request.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMSourceRequest(BaseModel): + """ + SCIMSource Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Source's display Name.") + slug: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "user_property_mappings", "group_property_mappings", "user_path_template"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "user_path_template": obj.get("user_path_template") + }) + return _obj + + diff --git a/authentik_client/models/scim_source_user.py b/authentik_client/models/scim_source_user.py new file mode 100644 index 000000000..4c91fb833 --- /dev/null +++ b/authentik_client/models/scim_source_user.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMSourceUser(BaseModel): + """ + SCIMSourceUser Serializer + """ # noqa: E501 + id: Optional[StrictStr] = None + external_id: StrictStr + user: StrictInt + user_obj: PartialUser + source: UUID + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["id", "external_id", "user", "user_obj", "source", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMSourceUser from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "user_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user_obj + if self.user_obj: + _dict['user_obj'] = self.user_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMSourceUser from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "external_id": obj.get("external_id"), + "user": obj.get("user"), + "user_obj": PartialUser.from_dict(obj["user_obj"]) if obj.get("user_obj") is not None else None, + "source": obj.get("source"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/scim_source_user_request.py b/authentik_client/models/scim_source_user_request.py new file mode 100644 index 000000000..5b1ecda29 --- /dev/null +++ b/authentik_client/models/scim_source_user_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SCIMSourceUserRequest(BaseModel): + """ + SCIMSourceUser Serializer + """ # noqa: E501 + id: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + external_id: Annotated[str, Field(min_length=1, strict=True)] + user: StrictInt + source: UUID + attributes: Optional[Dict[str, Any]] = None + __properties: ClassVar[List[str]] = ["id", "external_id", "user", "source", "attributes"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SCIMSourceUserRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SCIMSourceUserRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "external_id": obj.get("external_id"), + "user": obj.get("user"), + "source": obj.get("source"), + "attributes": obj.get("attributes") + }) + return _obj + + diff --git a/authentik_client/models/scope_mapping.py b/authentik_client/models/scope_mapping.py new file mode 100644 index 000000000..9703c8ce6 --- /dev/null +++ b/authentik_client/models/scope_mapping.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ScopeMapping(BaseModel): + """ + ScopeMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + scope_name: StrictStr = Field(description="Scope name requested by the client") + description: Optional[StrictStr] = Field(default=None, description="Description shown to the user when consenting. If left empty, the user won't be informed.") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "scope_name", "description"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ScopeMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ScopeMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "scope_name": obj.get("scope_name"), + "description": obj.get("description") + }) + return _obj + + diff --git a/authentik_client/models/scope_mapping_request.py b/authentik_client/models/scope_mapping_request.py new file mode 100644 index 000000000..e868688a2 --- /dev/null +++ b/authentik_client/models/scope_mapping_request.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ScopeMappingRequest(BaseModel): + """ + ScopeMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + scope_name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Scope name requested by the client") + description: Optional[StrictStr] = Field(default=None, description="Description shown to the user when consenting. If left empty, the user won't be informed.") + __properties: ClassVar[List[str]] = ["managed", "name", "expression", "scope_name", "description"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ScopeMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ScopeMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "scope_name": obj.get("scope_name"), + "description": obj.get("description") + }) + return _obj + + diff --git a/authentik_client/models/selectable_stage.py b/authentik_client/models/selectable_stage.py new file mode 100644 index 000000000..44c3b87ce --- /dev/null +++ b/authentik_client/models/selectable_stage.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SelectableStage(BaseModel): + """ + Serializer for stages which can be selected by users + """ # noqa: E501 + pk: UUID + name: StrictStr + verbose_name: StrictStr + meta_model_name: StrictStr + __properties: ClassVar[List[str]] = ["pk", "name", "verbose_name", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SelectableStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SelectableStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "verbose_name": obj.get("verbose_name"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/service_connection.py b/authentik_client/models/service_connection.py new file mode 100644 index 000000000..b800cbc78 --- /dev/null +++ b/authentik_client/models/service_connection.py @@ -0,0 +1,112 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ServiceConnection(BaseModel): + """ + ServiceConnection Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + local: Optional[StrictBool] = Field(default=None, description="If enabled, use the local connection. Required Docker socket/Kubernetes Integration") + component: StrictStr = Field(description="Return component used to edit this object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "name", "local", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ServiceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ServiceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "local": obj.get("local"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/service_connection_state.py b/authentik_client/models/service_connection_state.py new file mode 100644 index 000000000..521bff8eb --- /dev/null +++ b/authentik_client/models/service_connection_state.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ServiceConnectionState(BaseModel): + """ + Serializer for Service connection state + """ # noqa: E501 + healthy: StrictBool + version: StrictStr + __properties: ClassVar[List[str]] = ["healthy", "version"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ServiceConnectionState from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "healthy", + "version", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ServiceConnectionState from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "healthy": obj.get("healthy"), + "version": obj.get("version") + }) + return _obj + + diff --git a/authentik_client/models/session_end_challenge.py b/authentik_client/models/session_end_challenge.py new file mode 100644 index 000000000..347f9bfcc --- /dev/null +++ b/authentik_client/models/session_end_challenge.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SessionEndChallenge(BaseModel): + """ + Challenge for ending a session + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-session-end' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + application_name: Optional[StrictStr] = None + application_launch_url: Optional[StrictStr] = None + invalidation_flow_url: Optional[StrictStr] = None + overview_url: Optional[StrictStr] = None + brand_name: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar", "application_name", "application_launch_url", "invalidation_flow_url", "overview_url", "brand_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SessionEndChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SessionEndChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-session-end', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar"), + "application_name": obj.get("application_name"), + "application_launch_url": obj.get("application_launch_url"), + "invalidation_flow_url": obj.get("invalidation_flow_url"), + "overview_url": obj.get("overview_url"), + "brand_name": obj.get("brand_name") + }) + return _obj + + diff --git a/authentik_client/models/session_user.py b/authentik_client/models/session_user.py new file mode 100644 index 000000000..7d1bf5372 --- /dev/null +++ b/authentik_client/models/session_user.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.user_self import UserSelf +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SessionUser(BaseModel): + """ + Response for the /user/me endpoint, returns the currently active user (as `user` property) and, if this user is being impersonated, the original user in the `original` property. + """ # noqa: E501 + user: UserSelf + original: Optional[UserSelf] = None + __properties: ClassVar[List[str]] = ["user", "original"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SessionUser from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + # override the default output from pydantic by calling `to_dict()` of original + if self.original: + _dict['original'] = self.original.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SessionUser from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user": UserSelf.from_dict(obj["user"]) if obj.get("user") is not None else None, + "original": UserSelf.from_dict(obj["original"]) if obj.get("original") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/settings.py b/authentik_client/models/settings.py new file mode 100644 index 000000000..678c16ad3 --- /dev/null +++ b/authentik_client/models/settings.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.patched_settings_request_flags import PatchedSettingsRequestFlags +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Settings(BaseModel): + """ + Settings Serializer + """ # noqa: E501 + avatars: Optional[StrictStr] = Field(default=None, description="Configure how authentik should show avatars for users.") + default_user_change_name: Optional[StrictBool] = Field(default=None, description="Enable the ability for users to change their name.") + default_user_change_email: Optional[StrictBool] = Field(default=None, description="Enable the ability for users to change their email address.") + default_user_change_username: Optional[StrictBool] = Field(default=None, description="Enable the ability for users to change their username.") + event_retention: Optional[StrictStr] = Field(default=None, description="Events will be deleted after this duration.(Format: weeks=3;days=2;hours=3,seconds=2).") + reputation_lower_limit: Optional[Annotated[int, Field(le=0, strict=True, ge=-2147483648)]] = Field(default=None, description="Reputation cannot decrease lower than this value. Zero or negative.") + reputation_upper_limit: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Reputation cannot increase higher than this value. Zero or positive.") + footer_links: Optional[Any] = None + gdpr_compliance: Optional[StrictBool] = Field(default=None, description="When enabled, all the events caused by a user will be deleted upon the user's deletion.") + impersonation: Optional[StrictBool] = Field(default=None, description="Globally enable/disable impersonation.") + impersonation_require_reason: Optional[StrictBool] = Field(default=None, description="Require administrators to provide a reason for impersonating a user.") + default_token_duration: Optional[StrictStr] = Field(default=None, description="Default token duration") + default_token_length: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Default token length") + pagination_default_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Default page size for API responses, if no size was requested.") + pagination_max_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Maximum page size") + flags: PatchedSettingsRequestFlags + __properties: ClassVar[List[str]] = ["avatars", "default_user_change_name", "default_user_change_email", "default_user_change_username", "event_retention", "reputation_lower_limit", "reputation_upper_limit", "footer_links", "gdpr_compliance", "impersonation", "impersonation_require_reason", "default_token_duration", "default_token_length", "pagination_default_page_size", "pagination_max_page_size", "flags"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Settings from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flags + if self.flags: + _dict['flags'] = self.flags.to_dict() + # set to None if footer_links (nullable) is None + # and model_fields_set contains the field + if self.footer_links is None and "footer_links" in self.model_fields_set: + _dict['footer_links'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Settings from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "avatars": obj.get("avatars"), + "default_user_change_name": obj.get("default_user_change_name"), + "default_user_change_email": obj.get("default_user_change_email"), + "default_user_change_username": obj.get("default_user_change_username"), + "event_retention": obj.get("event_retention"), + "reputation_lower_limit": obj.get("reputation_lower_limit"), + "reputation_upper_limit": obj.get("reputation_upper_limit"), + "footer_links": obj.get("footer_links"), + "gdpr_compliance": obj.get("gdpr_compliance"), + "impersonation": obj.get("impersonation"), + "impersonation_require_reason": obj.get("impersonation_require_reason"), + "default_token_duration": obj.get("default_token_duration"), + "default_token_length": obj.get("default_token_length"), + "pagination_default_page_size": obj.get("pagination_default_page_size"), + "pagination_max_page_size": obj.get("pagination_max_page_size"), + "flags": PatchedSettingsRequestFlags.from_dict(obj["flags"]) if obj.get("flags") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/settings_request.py b/authentik_client/models/settings_request.py new file mode 100644 index 000000000..0fb5dbd5e --- /dev/null +++ b/authentik_client/models/settings_request.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.patched_settings_request_flags import PatchedSettingsRequestFlags +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SettingsRequest(BaseModel): + """ + Settings Serializer + """ # noqa: E501 + avatars: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Configure how authentik should show avatars for users.") + default_user_change_name: Optional[StrictBool] = Field(default=None, description="Enable the ability for users to change their name.") + default_user_change_email: Optional[StrictBool] = Field(default=None, description="Enable the ability for users to change their email address.") + default_user_change_username: Optional[StrictBool] = Field(default=None, description="Enable the ability for users to change their username.") + event_retention: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Events will be deleted after this duration.(Format: weeks=3;days=2;hours=3,seconds=2).") + reputation_lower_limit: Optional[Annotated[int, Field(le=0, strict=True, ge=-2147483648)]] = Field(default=None, description="Reputation cannot decrease lower than this value. Zero or negative.") + reputation_upper_limit: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Reputation cannot increase higher than this value. Zero or positive.") + footer_links: Optional[Any] = None + gdpr_compliance: Optional[StrictBool] = Field(default=None, description="When enabled, all the events caused by a user will be deleted upon the user's deletion.") + impersonation: Optional[StrictBool] = Field(default=None, description="Globally enable/disable impersonation.") + impersonation_require_reason: Optional[StrictBool] = Field(default=None, description="Require administrators to provide a reason for impersonating a user.") + default_token_duration: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Default token duration") + default_token_length: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=1)]] = Field(default=None, description="Default token length") + pagination_default_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Default page size for API responses, if no size was requested.") + pagination_max_page_size: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Maximum page size") + flags: PatchedSettingsRequestFlags + __properties: ClassVar[List[str]] = ["avatars", "default_user_change_name", "default_user_change_email", "default_user_change_username", "event_retention", "reputation_lower_limit", "reputation_upper_limit", "footer_links", "gdpr_compliance", "impersonation", "impersonation_require_reason", "default_token_duration", "default_token_length", "pagination_default_page_size", "pagination_max_page_size", "flags"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SettingsRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flags + if self.flags: + _dict['flags'] = self.flags.to_dict() + # set to None if footer_links (nullable) is None + # and model_fields_set contains the field + if self.footer_links is None and "footer_links" in self.model_fields_set: + _dict['footer_links'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SettingsRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "avatars": obj.get("avatars"), + "default_user_change_name": obj.get("default_user_change_name"), + "default_user_change_email": obj.get("default_user_change_email"), + "default_user_change_username": obj.get("default_user_change_username"), + "event_retention": obj.get("event_retention"), + "reputation_lower_limit": obj.get("reputation_lower_limit"), + "reputation_upper_limit": obj.get("reputation_upper_limit"), + "footer_links": obj.get("footer_links"), + "gdpr_compliance": obj.get("gdpr_compliance"), + "impersonation": obj.get("impersonation"), + "impersonation_require_reason": obj.get("impersonation_require_reason"), + "default_token_duration": obj.get("default_token_duration"), + "default_token_length": obj.get("default_token_length"), + "pagination_default_page_size": obj.get("pagination_default_page_size"), + "pagination_max_page_size": obj.get("pagination_max_page_size"), + "flags": PatchedSettingsRequestFlags.from_dict(obj["flags"]) if obj.get("flags") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/severity_enum.py b/authentik_client/models/severity_enum.py new file mode 100644 index 000000000..ccc02f41e --- /dev/null +++ b/authentik_client/models/severity_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SeverityEnum(str, Enum): + """ + SeverityEnum + """ + + """ + allowed enum values + """ + NOTICE = 'notice' + WARNING = 'warning' + ALERT = 'alert' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SeverityEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/shell_challenge.py b/authentik_client/models/shell_challenge.py new file mode 100644 index 000000000..d2c61ee67 --- /dev/null +++ b/authentik_client/models/shell_challenge.py @@ -0,0 +1,114 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ShellChallenge(BaseModel): + """ + challenge type to render HTML as-is + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'xak-flow-shell' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + body: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "body"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ShellChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ShellChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'xak-flow-shell', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "body": obj.get("body") + }) + return _obj + + diff --git a/authentik_client/models/signature_algorithm_enum.py b/authentik_client/models/signature_algorithm_enum.py new file mode 100644 index 000000000..8840ca0b0 --- /dev/null +++ b/authentik_client/models/signature_algorithm_enum.py @@ -0,0 +1,45 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SignatureAlgorithmEnum(str, Enum): + """ + SignatureAlgorithmEnum + """ + + """ + allowed enum values + """ + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2000_SLASH_09_SLASH_XMLDSIG_HASH_RSA_MINUS_SHA1 = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_RSA_MINUS_SHA256 = 'http://www.w3.org/2001/04/xmldsig-more#rsa-sha256' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_RSA_MINUS_SHA384 = 'http://www.w3.org/2001/04/xmldsig-more#rsa-sha384' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_RSA_MINUS_SHA512 = 'http://www.w3.org/2001/04/xmldsig-more#rsa-sha512' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_ECDSA_MINUS_SHA1 = 'http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha1' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_ECDSA_MINUS_SHA256 = 'http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha256' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_ECDSA_MINUS_SHA384 = 'http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha384' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_ECDSA_MINUS_SHA512 = 'http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha512' + HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2000_SLASH_09_SLASH_XMLDSIG_HASH_DSA_MINUS_SHA1 = 'http://www.w3.org/2000/09/xmldsig#dsa-sha1' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SignatureAlgorithmEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/sms_device.py b/authentik_client/models/sms_device.py new file mode 100644 index 000000000..a6a61a3f5 --- /dev/null +++ b/authentik_client/models/sms_device.py @@ -0,0 +1,106 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SMSDevice(BaseModel): + """ + Serializer for sms authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + pk: StrictInt + phone_number: StrictStr + user: PartialUser + __properties: ClassVar[List[str]] = ["name", "pk", "phone_number", "user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SMSDevice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "phone_number", + "user", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SMSDevice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "pk": obj.get("pk"), + "phone_number": obj.get("phone_number"), + "user": PartialUser.from_dict(obj["user"]) if obj.get("user") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/sms_device_request.py b/authentik_client/models/sms_device_request.py new file mode 100644 index 000000000..25387d428 --- /dev/null +++ b/authentik_client/models/sms_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SMSDeviceRequest(BaseModel): + """ + Serializer for sms authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SMSDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SMSDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/software.py b/authentik_client/models/software.py new file mode 100644 index 000000000..953f22e45 --- /dev/null +++ b/authentik_client/models/software.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Software(BaseModel): + """ + Software + """ # noqa: E501 + name: StrictStr + version: Optional[StrictStr] = None + source: StrictStr + path: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "version", "source", "path"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Software from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Software from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "version": obj.get("version"), + "source": obj.get("source"), + "path": obj.get("path") + }) + return _obj + + diff --git a/authentik_client/models/software_request.py b/authentik_client/models/software_request.py new file mode 100644 index 000000000..8215f7a69 --- /dev/null +++ b/authentik_client/models/software_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SoftwareRequest(BaseModel): + """ + SoftwareRequest + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + version: Optional[StrictStr] = None + source: Annotated[str, Field(min_length=1, strict=True)] + path: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["name", "version", "source", "path"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SoftwareRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SoftwareRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "version": obj.get("version"), + "source": obj.get("source"), + "path": obj.get("path") + }) + return _obj + + diff --git a/authentik_client/models/source.py b/authentik_client/models/source.py new file mode 100644 index 000000000..be0e82d51 --- /dev/null +++ b/authentik_client/models/source.py @@ -0,0 +1,186 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.themed_urls import ThemedUrls +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Source(BaseModel): + """ + Source Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr = Field(description="Source's display Name.") + slug: Annotated[str, Field(strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + managed: Optional[StrictStr] = Field(description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + user_path_template: Optional[StrictStr] = None + icon: Optional[StrictStr] = None + icon_url: Optional[StrictStr] = Field(description="Get the URL to the source icon") + icon_themed_urls: Optional[ThemedUrls] + __properties: ClassVar[List[str]] = ["pk", "name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "policy_engine_mode", "user_matching_mode", "managed", "user_path_template", "icon", "icon_url", "icon_themed_urls"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Source from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "managed", + "icon_url", + "icon_themed_urls", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of icon_themed_urls + if self.icon_themed_urls: + _dict['icon_themed_urls'] = self.icon_themed_urls.to_dict() + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if icon_url (nullable) is None + # and model_fields_set contains the field + if self.icon_url is None and "icon_url" in self.model_fields_set: + _dict['icon_url'] = None + + # set to None if icon_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.icon_themed_urls is None and "icon_themed_urls" in self.model_fields_set: + _dict['icon_themed_urls'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Source from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "managed": obj.get("managed"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "icon_url": obj.get("icon_url"), + "icon_themed_urls": ThemedUrls.from_dict(obj["icon_themed_urls"]) if obj.get("icon_themed_urls") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/source_stage.py b/authentik_client/models/source_stage.py new file mode 100644 index 000000000..8c566f5a0 --- /dev/null +++ b/authentik_client/models/source_stage.py @@ -0,0 +1,126 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SourceStage(BaseModel): + """ + SourceStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + source: UUID + resume_timeout: Optional[StrictStr] = Field(default=None, description="Amount of time a user can take to return from the source to continue the flow (Format: hours=-1;minutes=-2;seconds=-3)") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "source", "resume_timeout"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SourceStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SourceStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "source": obj.get("source"), + "resume_timeout": obj.get("resume_timeout") + }) + return _obj + + diff --git a/authentik_client/models/source_stage_request.py b/authentik_client/models/source_stage_request.py new file mode 100644 index 000000000..146750dc5 --- /dev/null +++ b/authentik_client/models/source_stage_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SourceStageRequest(BaseModel): + """ + SourceStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + source: UUID + resume_timeout: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Amount of time a user can take to return from the source to continue the flow (Format: hours=-1;minutes=-2;seconds=-3)") + __properties: ClassVar[List[str]] = ["name", "source", "resume_timeout"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SourceStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SourceStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "source": obj.get("source"), + "resume_timeout": obj.get("resume_timeout") + }) + return _obj + + diff --git a/authentik_client/models/source_type.py b/authentik_client/models/source_type.py new file mode 100644 index 000000000..f2056ee5d --- /dev/null +++ b/authentik_client/models/source_type.py @@ -0,0 +1,147 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SourceType(BaseModel): + """ + Serializer for SourceType + """ # noqa: E501 + name: StrictStr + verbose_name: StrictStr + urls_customizable: StrictBool + request_token_url: Optional[StrictStr] + authorization_url: Optional[StrictStr] + access_token_url: Optional[StrictStr] + profile_url: Optional[StrictStr] + oidc_well_known_url: Optional[StrictStr] + oidc_jwks_url: Optional[StrictStr] + __properties: ClassVar[List[str]] = ["name", "verbose_name", "urls_customizable", "request_token_url", "authorization_url", "access_token_url", "profile_url", "oidc_well_known_url", "oidc_jwks_url"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SourceType from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "request_token_url", + "authorization_url", + "access_token_url", + "profile_url", + "oidc_well_known_url", + "oidc_jwks_url", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if request_token_url (nullable) is None + # and model_fields_set contains the field + if self.request_token_url is None and "request_token_url" in self.model_fields_set: + _dict['request_token_url'] = None + + # set to None if authorization_url (nullable) is None + # and model_fields_set contains the field + if self.authorization_url is None and "authorization_url" in self.model_fields_set: + _dict['authorization_url'] = None + + # set to None if access_token_url (nullable) is None + # and model_fields_set contains the field + if self.access_token_url is None and "access_token_url" in self.model_fields_set: + _dict['access_token_url'] = None + + # set to None if profile_url (nullable) is None + # and model_fields_set contains the field + if self.profile_url is None and "profile_url" in self.model_fields_set: + _dict['profile_url'] = None + + # set to None if oidc_well_known_url (nullable) is None + # and model_fields_set contains the field + if self.oidc_well_known_url is None and "oidc_well_known_url" in self.model_fields_set: + _dict['oidc_well_known_url'] = None + + # set to None if oidc_jwks_url (nullable) is None + # and model_fields_set contains the field + if self.oidc_jwks_url is None and "oidc_jwks_url" in self.model_fields_set: + _dict['oidc_jwks_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SourceType from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "verbose_name": obj.get("verbose_name"), + "urls_customizable": obj.get("urls_customizable"), + "request_token_url": obj.get("request_token_url"), + "authorization_url": obj.get("authorization_url"), + "access_token_url": obj.get("access_token_url"), + "profile_url": obj.get("profile_url"), + "oidc_well_known_url": obj.get("oidc_well_known_url"), + "oidc_jwks_url": obj.get("oidc_jwks_url") + }) + return _obj + + diff --git a/authentik_client/models/ssf_provider.py b/authentik_client/models/ssf_provider.py new file mode 100644 index 000000000..27a9a12cd --- /dev/null +++ b/authentik_client/models/ssf_provider.py @@ -0,0 +1,147 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.provider import Provider +from authentik_client.models.token import Token +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SSFProvider(BaseModel): + """ + SSFProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + signing_key: UUID = Field(description="Key used to sign the SSF Events.") + token_obj: Token + oidc_auth_providers: Optional[List[StrictInt]] = None + oidc_auth_providers_obj: List[Provider] + ssf_url: Optional[StrictStr] + event_retention: Optional[StrictStr] = None + push_verify_certificates: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "signing_key", "token_obj", "oidc_auth_providers", "oidc_auth_providers_obj", "ssf_url", "event_retention", "push_verify_certificates"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SSFProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "token_obj", + "oidc_auth_providers_obj", + "ssf_url", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of token_obj + if self.token_obj: + _dict['token_obj'] = self.token_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in oidc_auth_providers_obj (list) + _items = [] + if self.oidc_auth_providers_obj: + for _item_oidc_auth_providers_obj in self.oidc_auth_providers_obj: + if _item_oidc_auth_providers_obj: + _items.append(_item_oidc_auth_providers_obj.to_dict()) + _dict['oidc_auth_providers_obj'] = _items + # set to None if ssf_url (nullable) is None + # and model_fields_set contains the field + if self.ssf_url is None and "ssf_url" in self.model_fields_set: + _dict['ssf_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SSFProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "signing_key": obj.get("signing_key"), + "token_obj": Token.from_dict(obj["token_obj"]) if obj.get("token_obj") is not None else None, + "oidc_auth_providers": obj.get("oidc_auth_providers"), + "oidc_auth_providers_obj": [Provider.from_dict(_item) for _item in obj["oidc_auth_providers_obj"]] if obj.get("oidc_auth_providers_obj") is not None else None, + "ssf_url": obj.get("ssf_url"), + "event_retention": obj.get("event_retention"), + "push_verify_certificates": obj.get("push_verify_certificates") + }) + return _obj + + diff --git a/authentik_client/models/ssf_provider_request.py b/authentik_client/models/ssf_provider_request.py new file mode 100644 index 000000000..d393a4fac --- /dev/null +++ b/authentik_client/models/ssf_provider_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SSFProviderRequest(BaseModel): + """ + SSFProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + signing_key: UUID = Field(description="Key used to sign the SSF Events.") + oidc_auth_providers: Optional[List[StrictInt]] = None + event_retention: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + push_verify_certificates: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["name", "signing_key", "oidc_auth_providers", "event_retention", "push_verify_certificates"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SSFProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SSFProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "signing_key": obj.get("signing_key"), + "oidc_auth_providers": obj.get("oidc_auth_providers"), + "event_retention": obj.get("event_retention"), + "push_verify_certificates": obj.get("push_verify_certificates") + }) + return _obj + + diff --git a/authentik_client/models/ssf_stream.py b/authentik_client/models/ssf_stream.py new file mode 100644 index 000000000..78395f1e2 --- /dev/null +++ b/authentik_client/models/ssf_stream.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.delivery_method_enum import DeliveryMethodEnum +from authentik_client.models.events_requested_enum import EventsRequestedEnum +from authentik_client.models.ssf_provider import SSFProvider +from authentik_client.models.ssf_stream_status_enum import SSFStreamStatusEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SSFStream(BaseModel): + """ + SSFStream Serializer + """ # noqa: E501 + pk: UUID + status: Optional[SSFStreamStatusEnum] = None + provider: StrictInt + provider_obj: SSFProvider + delivery_method: DeliveryMethodEnum + endpoint_url: Optional[StrictStr] = None + events_requested: Optional[List[EventsRequestedEnum]] = None + format: StrictStr + aud: Optional[List[StrictStr]] = None + iss: StrictStr + __properties: ClassVar[List[str]] = ["pk", "status", "provider", "provider_obj", "delivery_method", "endpoint_url", "events_requested", "format", "aud", "iss"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SSFStream from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "provider_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of provider_obj + if self.provider_obj: + _dict['provider_obj'] = self.provider_obj.to_dict() + # set to None if endpoint_url (nullable) is None + # and model_fields_set contains the field + if self.endpoint_url is None and "endpoint_url" in self.model_fields_set: + _dict['endpoint_url'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SSFStream from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "status": obj.get("status"), + "provider": obj.get("provider"), + "provider_obj": SSFProvider.from_dict(obj["provider_obj"]) if obj.get("provider_obj") is not None else None, + "delivery_method": obj.get("delivery_method"), + "endpoint_url": obj.get("endpoint_url"), + "events_requested": obj.get("events_requested"), + "format": obj.get("format"), + "aud": obj.get("aud"), + "iss": obj.get("iss") + }) + return _obj + + diff --git a/authentik_client/models/ssf_stream_status_enum.py b/authentik_client/models/ssf_stream_status_enum.py new file mode 100644 index 000000000..bdad35003 --- /dev/null +++ b/authentik_client/models/ssf_stream_status_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SSFStreamStatusEnum(str, Enum): + """ + SSFStreamStatusEnum + """ + + """ + allowed enum values + """ + ENABLED = 'enabled' + PAUSED = 'paused' + DISABLED = 'disabled' + DISABLED_DELETED = 'disabled_deleted' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SSFStreamStatusEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/stage.py b/authentik_client/models/stage.py new file mode 100644 index 000000000..8e6e85959 --- /dev/null +++ b/authentik_client/models/stage.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Stage(BaseModel): + """ + Stage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Stage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Stage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/stage_mode_enum.py b/authentik_client/models/stage_mode_enum.py new file mode 100644 index 000000000..baae75bea --- /dev/null +++ b/authentik_client/models/stage_mode_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class StageModeEnum(str, Enum): + """ + StageModeEnum + """ + + """ + allowed enum values + """ + OPTIONAL = 'optional' + REQUIRED = 'required' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of StageModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/stage_prompt.py b/authentik_client/models/stage_prompt.py new file mode 100644 index 000000000..6fcd6738f --- /dev/null +++ b/authentik_client/models/stage_prompt.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.prompt_choice import PromptChoice +from authentik_client.models.prompt_type_enum import PromptTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class StagePrompt(BaseModel): + """ + Serializer for a single Prompt field + """ # noqa: E501 + field_key: StrictStr + label: StrictStr + type: PromptTypeEnum + required: StrictBool + placeholder: StrictStr + initial_value: StrictStr + order: StrictInt + sub_text: StrictStr + choices: Optional[List[PromptChoice]] + __properties: ClassVar[List[str]] = ["field_key", "label", "type", "required", "placeholder", "initial_value", "order", "sub_text", "choices"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of StagePrompt from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in choices (list) + _items = [] + if self.choices: + for _item_choices in self.choices: + if _item_choices: + _items.append(_item_choices.to_dict()) + _dict['choices'] = _items + # set to None if choices (nullable) is None + # and model_fields_set contains the field + if self.choices is None and "choices" in self.model_fields_set: + _dict['choices'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of StagePrompt from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "field_key": obj.get("field_key"), + "label": obj.get("label"), + "type": obj.get("type"), + "required": obj.get("required"), + "placeholder": obj.get("placeholder"), + "initial_value": obj.get("initial_value"), + "order": obj.get("order"), + "sub_text": obj.get("sub_text"), + "choices": [PromptChoice.from_dict(_item) for _item in obj["choices"]] if obj.get("choices") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/static_device.py b/authentik_client/models/static_device.py new file mode 100644 index 000000000..f00e9156e --- /dev/null +++ b/authentik_client/models/static_device.py @@ -0,0 +1,114 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from authentik_client.models.partial_user import PartialUser +from authentik_client.models.static_device_token import StaticDeviceToken +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class StaticDevice(BaseModel): + """ + Serializer for static authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + token_set: List[StaticDeviceToken] + pk: StrictInt + user: PartialUser + __properties: ClassVar[List[str]] = ["name", "token_set", "pk", "user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of StaticDevice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "token_set", + "pk", + "user", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in token_set (list) + _items = [] + if self.token_set: + for _item_token_set in self.token_set: + if _item_token_set: + _items.append(_item_token_set.to_dict()) + _dict['token_set'] = _items + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of StaticDevice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "token_set": [StaticDeviceToken.from_dict(_item) for _item in obj["token_set"]] if obj.get("token_set") is not None else None, + "pk": obj.get("pk"), + "user": PartialUser.from_dict(obj["user"]) if obj.get("user") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/static_device_request.py b/authentik_client/models/static_device_request.py new file mode 100644 index 000000000..5a4f83250 --- /dev/null +++ b/authentik_client/models/static_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class StaticDeviceRequest(BaseModel): + """ + Serializer for static authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of StaticDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of StaticDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/static_device_token.py b/authentik_client/models/static_device_token.py new file mode 100644 index 000000000..bf48832d1 --- /dev/null +++ b/authentik_client/models/static_device_token.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class StaticDeviceToken(BaseModel): + """ + Serializer for static device's tokens + """ # noqa: E501 + token: Annotated[str, Field(strict=True, max_length=100)] + __properties: ClassVar[List[str]] = ["token"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of StaticDeviceToken from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of StaticDeviceToken from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "token": obj.get("token") + }) + return _obj + + diff --git a/authentik_client/models/sub_mode_enum.py b/authentik_client/models/sub_mode_enum.py new file mode 100644 index 000000000..0059eb622 --- /dev/null +++ b/authentik_client/models/sub_mode_enum.py @@ -0,0 +1,42 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SubModeEnum(str, Enum): + """ + SubModeEnum + """ + + """ + allowed enum values + """ + HASHED_USER_ID = 'hashed_user_id' + USER_ID = 'user_id' + USER_UUID = 'user_uuid' + USER_USERNAME = 'user_username' + USER_EMAIL = 'user_email' + USER_UPN = 'user_upn' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SubModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/sync_object_model_enum.py b/authentik_client/models/sync_object_model_enum.py new file mode 100644 index 000000000..5591c1822 --- /dev/null +++ b/authentik_client/models/sync_object_model_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SyncObjectModelEnum(str, Enum): + """ + SyncObjectModelEnum + """ + + """ + allowed enum values + """ + AUTHENTIK_DOT_CORE_DOT_MODELS_DOT_USER = 'authentik.core.models.User' + AUTHENTIK_DOT_CORE_DOT_MODELS_DOT_GROUP = 'authentik.core.models.Group' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SyncObjectModelEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/sync_object_request.py b/authentik_client/models/sync_object_request.py new file mode 100644 index 000000000..f1e13ee1a --- /dev/null +++ b/authentik_client/models/sync_object_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.sync_object_model_enum import SyncObjectModelEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SyncObjectRequest(BaseModel): + """ + Sync object serializer + """ # noqa: E501 + sync_object_model: SyncObjectModelEnum + sync_object_id: Annotated[str, Field(min_length=1, strict=True)] + override_dry_run: Optional[StrictBool] = False + __properties: ClassVar[List[str]] = ["sync_object_model", "sync_object_id", "override_dry_run"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SyncObjectRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SyncObjectRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "sync_object_model": obj.get("sync_object_model"), + "sync_object_id": obj.get("sync_object_id"), + "override_dry_run": obj.get("override_dry_run") if obj.get("override_dry_run") is not None else False + }) + return _obj + + diff --git a/authentik_client/models/sync_object_result.py b/authentik_client/models/sync_object_result.py new file mode 100644 index 000000000..936bda492 --- /dev/null +++ b/authentik_client/models/sync_object_result.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from authentik_client.models.log_event import LogEvent +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SyncObjectResult(BaseModel): + """ + Result of a single object sync + """ # noqa: E501 + messages: List[LogEvent] + __properties: ClassVar[List[str]] = ["messages"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SyncObjectResult from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "messages", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in messages (list) + _items = [] + if self.messages: + for _item_messages in self.messages: + if _item_messages: + _items.append(_item_messages.to_dict()) + _dict['messages'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SyncObjectResult from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "messages": [LogEvent.from_dict(_item) for _item in obj["messages"]] if obj.get("messages") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/sync_outgoing_trigger_mode_enum.py b/authentik_client/models/sync_outgoing_trigger_mode_enum.py new file mode 100644 index 000000000..fe66df131 --- /dev/null +++ b/authentik_client/models/sync_outgoing_trigger_mode_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class SyncOutgoingTriggerModeEnum(str, Enum): + """ + SyncOutgoingTriggerModeEnum + """ + + """ + allowed enum values + """ + NONE = 'none' + IMMEDIATE = 'immediate' + DEFERRED_END = 'deferred_end' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of SyncOutgoingTriggerModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/sync_status.py b/authentik_client/models/sync_status.py new file mode 100644 index 000000000..def2eff4e --- /dev/null +++ b/authentik_client/models/sync_status.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.task_aggregated_status_enum import TaskAggregatedStatusEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SyncStatus(BaseModel): + """ + Provider/source sync status + """ # noqa: E501 + is_running: StrictBool + last_successful_sync: Optional[datetime] = None + last_sync_status: Optional[TaskAggregatedStatusEnum] = None + __properties: ClassVar[List[str]] = ["is_running", "last_successful_sync", "last_sync_status"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SyncStatus from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SyncStatus from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "is_running": obj.get("is_running"), + "last_successful_sync": obj.get("last_successful_sync"), + "last_sync_status": obj.get("last_sync_status") + }) + return _obj + + diff --git a/authentik_client/models/system_info.py b/authentik_client/models/system_info.py new file mode 100644 index 000000000..a60a90f09 --- /dev/null +++ b/authentik_client/models/system_info.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List +from authentik_client.models.system_info_runtime import SystemInfoRuntime +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SystemInfo(BaseModel): + """ + Get system information. + """ # noqa: E501 + http_headers: Dict[str, StrictStr] = Field(description="Get HTTP Request headers") + http_host: StrictStr = Field(description="Get HTTP host") + http_is_secure: StrictBool = Field(description="Get HTTP Secure flag") + runtime: SystemInfoRuntime + brand: StrictStr = Field(description="Currently active brand") + server_time: datetime = Field(description="Current server time") + embedded_outpost_disabled: StrictBool = Field(description="Whether the embedded outpost is disabled") + embedded_outpost_host: StrictStr = Field(description="Get the FQDN configured on the embedded outpost") + __properties: ClassVar[List[str]] = ["http_headers", "http_host", "http_is_secure", "runtime", "brand", "server_time", "embedded_outpost_disabled", "embedded_outpost_host"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SystemInfo from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "http_headers", + "http_host", + "http_is_secure", + "brand", + "server_time", + "embedded_outpost_disabled", + "embedded_outpost_host", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of runtime + if self.runtime: + _dict['runtime'] = self.runtime.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SystemInfo from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "http_headers": obj.get("http_headers"), + "http_host": obj.get("http_host"), + "http_is_secure": obj.get("http_is_secure"), + "runtime": SystemInfoRuntime.from_dict(obj["runtime"]) if obj.get("runtime") is not None else None, + "brand": obj.get("brand"), + "server_time": obj.get("server_time"), + "embedded_outpost_disabled": obj.get("embedded_outpost_disabled"), + "embedded_outpost_host": obj.get("embedded_outpost_host") + }) + return _obj + + diff --git a/authentik_client/models/system_info_runtime.py b/authentik_client/models/system_info_runtime.py new file mode 100644 index 000000000..c053d7089 --- /dev/null +++ b/authentik_client/models/system_info_runtime.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class SystemInfoRuntime(BaseModel): + """ + Get versions + """ # noqa: E501 + python_version: StrictStr + environment: StrictStr + architecture: StrictStr + platform: StrictStr + uname: StrictStr + openssl_version: StrictStr + openssl_fips_enabled: Optional[StrictBool] + authentik_version: StrictStr + __properties: ClassVar[List[str]] = ["python_version", "environment", "architecture", "platform", "uname", "openssl_version", "openssl_fips_enabled", "authentik_version"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of SystemInfoRuntime from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if openssl_fips_enabled (nullable) is None + # and model_fields_set contains the field + if self.openssl_fips_enabled is None and "openssl_fips_enabled" in self.model_fields_set: + _dict['openssl_fips_enabled'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of SystemInfoRuntime from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "python_version": obj.get("python_version"), + "environment": obj.get("environment"), + "architecture": obj.get("architecture"), + "platform": obj.get("platform"), + "uname": obj.get("uname"), + "openssl_version": obj.get("openssl_version"), + "openssl_fips_enabled": obj.get("openssl_fips_enabled"), + "authentik_version": obj.get("authentik_version") + }) + return _obj + + diff --git a/authentik_client/models/task.py b/authentik_client/models/task.py new file mode 100644 index 000000000..b2250e050 --- /dev/null +++ b/authentik_client/models/task.py @@ -0,0 +1,164 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.log_event import LogEvent +from authentik_client.models.task_aggregated_status_enum import TaskAggregatedStatusEnum +from authentik_client.models.task_status_enum import TaskStatusEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Task(BaseModel): + """ + Task + """ # noqa: E501 + message_id: Optional[UUID] = None + queue_name: Optional[StrictStr] = Field(default=None, description="Queue name") + actor_name: StrictStr = Field(description="Dramatiq actor name") + state: Optional[TaskStatusEnum] = Field(default=None, description="Task status") + mtime: Optional[datetime] = Field(default=None, description="Task last modified time") + retries: Optional[Annotated[int, Field(le=9223372036854775807, strict=True, ge=0)]] = Field(default=None, description="Number of retries") + eta: Optional[datetime] = Field(default=None, description="Planned execution time") + rel_obj_app_label: StrictStr + rel_obj_model: StrictStr + rel_obj_id: Optional[StrictStr] = None + uid: StrictStr + logs: List[LogEvent] + previous_logs: List[LogEvent] + aggregated_status: TaskAggregatedStatusEnum + description: Optional[StrictStr] + __properties: ClassVar[List[str]] = ["message_id", "queue_name", "actor_name", "state", "mtime", "retries", "eta", "rel_obj_app_label", "rel_obj_model", "rel_obj_id", "uid", "logs", "previous_logs", "aggregated_status", "description"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Task from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "rel_obj_app_label", + "rel_obj_model", + "uid", + "logs", + "previous_logs", + "description", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in logs (list) + _items = [] + if self.logs: + for _item_logs in self.logs: + if _item_logs: + _items.append(_item_logs.to_dict()) + _dict['logs'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in previous_logs (list) + _items = [] + if self.previous_logs: + for _item_previous_logs in self.previous_logs: + if _item_previous_logs: + _items.append(_item_previous_logs.to_dict()) + _dict['previous_logs'] = _items + # set to None if eta (nullable) is None + # and model_fields_set contains the field + if self.eta is None and "eta" in self.model_fields_set: + _dict['eta'] = None + + # set to None if rel_obj_id (nullable) is None + # and model_fields_set contains the field + if self.rel_obj_id is None and "rel_obj_id" in self.model_fields_set: + _dict['rel_obj_id'] = None + + # set to None if description (nullable) is None + # and model_fields_set contains the field + if self.description is None and "description" in self.model_fields_set: + _dict['description'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Task from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "message_id": obj.get("message_id"), + "queue_name": obj.get("queue_name"), + "actor_name": obj.get("actor_name"), + "state": obj.get("state"), + "mtime": obj.get("mtime"), + "retries": obj.get("retries"), + "eta": obj.get("eta"), + "rel_obj_app_label": obj.get("rel_obj_app_label"), + "rel_obj_model": obj.get("rel_obj_model"), + "rel_obj_id": obj.get("rel_obj_id"), + "uid": obj.get("uid"), + "logs": [LogEvent.from_dict(_item) for _item in obj["logs"]] if obj.get("logs") is not None else None, + "previous_logs": [LogEvent.from_dict(_item) for _item in obj["previous_logs"]] if obj.get("previous_logs") is not None else None, + "aggregated_status": obj.get("aggregated_status"), + "description": obj.get("description") + }) + return _obj + + diff --git a/authentik_client/models/task_aggregated_status_enum.py b/authentik_client/models/task_aggregated_status_enum.py new file mode 100644 index 000000000..daa695973 --- /dev/null +++ b/authentik_client/models/task_aggregated_status_enum.py @@ -0,0 +1,46 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class TaskAggregatedStatusEnum(str, Enum): + """ + TaskAggregatedStatusEnum + """ + + """ + allowed enum values + """ + QUEUED = 'queued' + CONSUMED = 'consumed' + PREPROCESS = 'preprocess' + RUNNING = 'running' + POSTPROCESS = 'postprocess' + REJECTED = 'rejected' + DONE = 'done' + INFO = 'info' + WARNING = 'warning' + ERROR = 'error' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of TaskAggregatedStatusEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/task_status_enum.py b/authentik_client/models/task_status_enum.py new file mode 100644 index 000000000..392003f44 --- /dev/null +++ b/authentik_client/models/task_status_enum.py @@ -0,0 +1,43 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class TaskStatusEnum(str, Enum): + """ + TaskStatusEnum + """ + + """ + allowed enum values + """ + QUEUED = 'queued' + CONSUMED = 'consumed' + PREPROCESS = 'preprocess' + RUNNING = 'running' + POSTPROCESS = 'postprocess' + REJECTED = 'rejected' + DONE = 'done' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of TaskStatusEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/telegram_auth_request.py b/authentik_client/models/telegram_auth_request.py new file mode 100644 index 000000000..870fd131b --- /dev/null +++ b/authentik_client/models/telegram_auth_request.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TelegramAuthRequest(BaseModel): + """ + TelegramAuthRequest + """ # noqa: E501 + id: StrictInt + first_name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=255)]] = None + last_name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=255)]] = None + username: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=255)]] = None + photo_url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + auth_date: StrictInt + hash: Annotated[str, Field(min_length=1, strict=True, max_length=64)] + __properties: ClassVar[List[str]] = ["id", "first_name", "last_name", "username", "photo_url", "auth_date", "hash"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TelegramAuthRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TelegramAuthRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "first_name": obj.get("first_name"), + "last_name": obj.get("last_name"), + "username": obj.get("username"), + "photo_url": obj.get("photo_url"), + "auth_date": obj.get("auth_date"), + "hash": obj.get("hash") + }) + return _obj + + diff --git a/authentik_client/models/telegram_challenge_response_request.py b/authentik_client/models/telegram_challenge_response_request.py new file mode 100644 index 000000000..294d00eda --- /dev/null +++ b/authentik_client/models/telegram_challenge_response_request.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TelegramChallengeResponseRequest(BaseModel): + """ + Base class for all challenge responses + """ # noqa: E501 + id: StrictInt + first_name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=255)]] = None + last_name: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=255)]] = None + username: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=255)]] = None + photo_url: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + auth_date: StrictInt + hash: Annotated[str, Field(min_length=1, strict=True, max_length=64)] + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-source-telegram' + __properties: ClassVar[List[str]] = ["id", "first_name", "last_name", "username", "photo_url", "auth_date", "hash", "component"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TelegramChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TelegramChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "first_name": obj.get("first_name"), + "last_name": obj.get("last_name"), + "username": obj.get("username"), + "photo_url": obj.get("photo_url"), + "auth_date": obj.get("auth_date"), + "hash": obj.get("hash"), + "component": obj.get("component") if obj.get("component") is not None else 'ak-source-telegram' + }) + return _obj + + diff --git a/authentik_client/models/telegram_login_challenge.py b/authentik_client/models/telegram_login_challenge.py new file mode 100644 index 000000000..df0328ed5 --- /dev/null +++ b/authentik_client/models/telegram_login_challenge.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TelegramLoginChallenge(BaseModel): + """ + Base login challenge for Identification stage + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-source-telegram' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + bot_username: StrictStr = Field(description="Telegram bot username") + request_message_access: StrictBool + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "bot_username", "request_message_access"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TelegramLoginChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TelegramLoginChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-source-telegram', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "bot_username": obj.get("bot_username"), + "request_message_access": obj.get("request_message_access") + }) + return _obj + + diff --git a/authentik_client/models/telegram_source.py b/authentik_client/models/telegram_source.py new file mode 100644 index 000000000..b5c32b4dc --- /dev/null +++ b/authentik_client/models/telegram_source.py @@ -0,0 +1,192 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.themed_urls import ThemedUrls +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TelegramSource(BaseModel): + """ + Source Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr = Field(description="Source's display Name.") + slug: Annotated[str, Field(strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + managed: Optional[StrictStr] = Field(description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + user_path_template: Optional[StrictStr] = None + icon: Optional[StrictStr] = None + icon_url: Optional[StrictStr] + icon_themed_urls: Optional[ThemedUrls] + bot_username: StrictStr = Field(description="Telegram bot username") + request_message_access: Optional[StrictBool] = Field(default=None, description="Request access to send messages from your bot.") + pre_authentication_flow: UUID = Field(description="Flow used before authentication.") + __properties: ClassVar[List[str]] = ["pk", "name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "policy_engine_mode", "user_matching_mode", "managed", "user_path_template", "icon", "icon_url", "icon_themed_urls", "bot_username", "request_message_access", "pre_authentication_flow"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TelegramSource from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "managed", + "icon_url", + "icon_themed_urls", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of icon_themed_urls + if self.icon_themed_urls: + _dict['icon_themed_urls'] = self.icon_themed_urls.to_dict() + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if icon_url (nullable) is None + # and model_fields_set contains the field + if self.icon_url is None and "icon_url" in self.model_fields_set: + _dict['icon_url'] = None + + # set to None if icon_themed_urls (nullable) is None + # and model_fields_set contains the field + if self.icon_themed_urls is None and "icon_themed_urls" in self.model_fields_set: + _dict['icon_themed_urls'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TelegramSource from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "managed": obj.get("managed"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "icon_url": obj.get("icon_url"), + "icon_themed_urls": ThemedUrls.from_dict(obj["icon_themed_urls"]) if obj.get("icon_themed_urls") is not None else None, + "bot_username": obj.get("bot_username"), + "request_message_access": obj.get("request_message_access"), + "pre_authentication_flow": obj.get("pre_authentication_flow") + }) + return _obj + + diff --git a/authentik_client/models/telegram_source_property_mapping.py b/authentik_client/models/telegram_source_property_mapping.py new file mode 100644 index 000000000..2a549429e --- /dev/null +++ b/authentik_client/models/telegram_source_property_mapping.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TelegramSourcePropertyMapping(BaseModel): + """ + TelegramSourcePropertyMapping Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: StrictStr + expression: StrictStr + component: StrictStr = Field(description="Get object's component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + __properties: ClassVar[List[str]] = ["pk", "managed", "name", "expression", "component", "verbose_name", "verbose_name_plural", "meta_model_name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TelegramSourcePropertyMapping from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TelegramSourcePropertyMapping from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name") + }) + return _obj + + diff --git a/authentik_client/models/telegram_source_property_mapping_request.py b/authentik_client/models/telegram_source_property_mapping_request.py new file mode 100644 index 000000000..51cb3a54a --- /dev/null +++ b/authentik_client/models/telegram_source_property_mapping_request.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TelegramSourcePropertyMappingRequest(BaseModel): + """ + TelegramSourcePropertyMapping Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + name: Annotated[str, Field(min_length=1, strict=True)] + expression: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["managed", "name", "expression"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TelegramSourcePropertyMappingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TelegramSourcePropertyMappingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "name": obj.get("name"), + "expression": obj.get("expression") + }) + return _obj + + diff --git a/authentik_client/models/telegram_source_request.py b/authentik_client/models/telegram_source_request.py new file mode 100644 index 000000000..26ffaa47a --- /dev/null +++ b/authentik_client/models/telegram_source_request.py @@ -0,0 +1,143 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TelegramSourceRequest(BaseModel): + """ + Source Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Source's display Name.") + slug: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Internal source name, used in URLs.") + enabled: Optional[StrictBool] = None + promoted: Optional[StrictBool] = Field(default=None, description="When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon.") + authentication_flow: Optional[UUID] = Field(default=None, description="Flow to use when authenticating existing users.") + enrollment_flow: Optional[UUID] = Field(default=None, description="Flow to use when enrolling new users.") + user_property_mappings: Optional[List[UUID]] = None + group_property_mappings: Optional[List[UUID]] = None + policy_engine_mode: Optional[PolicyEngineMode] = None + user_matching_mode: Optional[UserMatchingModeEnum] = Field(default=None, description="How the source determines if an existing user should be authenticated or a new user enrolled.") + user_path_template: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + icon: Optional[StrictStr] = None + bot_username: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Telegram bot username") + bot_token: Annotated[str, Field(min_length=1, strict=True)] = Field(description="Telegram bot token") + request_message_access: Optional[StrictBool] = Field(default=None, description="Request access to send messages from your bot.") + pre_authentication_flow: UUID = Field(description="Flow used before authentication.") + __properties: ClassVar[List[str]] = ["name", "slug", "enabled", "promoted", "authentication_flow", "enrollment_flow", "user_property_mappings", "group_property_mappings", "policy_engine_mode", "user_matching_mode", "user_path_template", "icon", "bot_username", "bot_token", "request_message_access", "pre_authentication_flow"] + + @field_validator('slug') + def slug_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TelegramSourceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if enrollment_flow (nullable) is None + # and model_fields_set contains the field + if self.enrollment_flow is None and "enrollment_flow" in self.model_fields_set: + _dict['enrollment_flow'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TelegramSourceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "slug": obj.get("slug"), + "enabled": obj.get("enabled"), + "promoted": obj.get("promoted"), + "authentication_flow": obj.get("authentication_flow"), + "enrollment_flow": obj.get("enrollment_flow"), + "user_property_mappings": obj.get("user_property_mappings"), + "group_property_mappings": obj.get("group_property_mappings"), + "policy_engine_mode": obj.get("policy_engine_mode"), + "user_matching_mode": obj.get("user_matching_mode"), + "user_path_template": obj.get("user_path_template"), + "icon": obj.get("icon"), + "bot_username": obj.get("bot_username"), + "bot_token": obj.get("bot_token"), + "request_message_access": obj.get("request_message_access"), + "pre_authentication_flow": obj.get("pre_authentication_flow") + }) + return _obj + + diff --git a/authentik_client/models/tenant.py b/authentik_client/models/tenant.py new file mode 100644 index 000000000..ed5ad8058 --- /dev/null +++ b/authentik_client/models/tenant.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Tenant(BaseModel): + """ + Tenant Serializer + """ # noqa: E501 + tenant_uuid: UUID + schema_name: Annotated[str, Field(strict=True, max_length=63)] + name: StrictStr + ready: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["tenant_uuid", "schema_name", "name", "ready"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Tenant from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "tenant_uuid", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Tenant from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "tenant_uuid": obj.get("tenant_uuid"), + "schema_name": obj.get("schema_name"), + "name": obj.get("name"), + "ready": obj.get("ready") + }) + return _obj + + diff --git a/authentik_client/models/tenant_admin_group_request_request.py b/authentik_client/models/tenant_admin_group_request_request.py new file mode 100644 index 000000000..d5b33d1b0 --- /dev/null +++ b/authentik_client/models/tenant_admin_group_request_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TenantAdminGroupRequestRequest(BaseModel): + """ + Tenant admin group creation request serializer + """ # noqa: E501 + user: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TenantAdminGroupRequestRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TenantAdminGroupRequestRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user": obj.get("user") + }) + return _obj + + diff --git a/authentik_client/models/tenant_recovery_key_request_request.py b/authentik_client/models/tenant_recovery_key_request_request.py new file mode 100644 index 000000000..ca8949ab1 --- /dev/null +++ b/authentik_client/models/tenant_recovery_key_request_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TenantRecoveryKeyRequestRequest(BaseModel): + """ + Tenant recovery key creation request serializer + """ # noqa: E501 + user: Annotated[str, Field(min_length=1, strict=True)] + duration_days: StrictInt + __properties: ClassVar[List[str]] = ["user", "duration_days"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TenantRecoveryKeyRequestRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TenantRecoveryKeyRequestRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user": obj.get("user"), + "duration_days": obj.get("duration_days") + }) + return _obj + + diff --git a/authentik_client/models/tenant_recovery_key_response.py b/authentik_client/models/tenant_recovery_key_response.py new file mode 100644 index 000000000..38346b2ca --- /dev/null +++ b/authentik_client/models/tenant_recovery_key_response.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TenantRecoveryKeyResponse(BaseModel): + """ + Tenant recovery key creation response serializer + """ # noqa: E501 + expiry: datetime + url: StrictStr + __properties: ClassVar[List[str]] = ["expiry", "url"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TenantRecoveryKeyResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TenantRecoveryKeyResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "expiry": obj.get("expiry"), + "url": obj.get("url") + }) + return _obj + + diff --git a/authentik_client/models/tenant_request.py b/authentik_client/models/tenant_request.py new file mode 100644 index 000000000..6db253764 --- /dev/null +++ b/authentik_client/models/tenant_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TenantRequest(BaseModel): + """ + Tenant Serializer + """ # noqa: E501 + schema_name: Annotated[str, Field(min_length=1, strict=True, max_length=63)] + name: Annotated[str, Field(min_length=1, strict=True)] + ready: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["schema_name", "name", "ready"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TenantRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TenantRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "schema_name": obj.get("schema_name"), + "name": obj.get("name"), + "ready": obj.get("ready") + }) + return _obj + + diff --git a/authentik_client/models/themed_urls.py b/authentik_client/models/themed_urls.py new file mode 100644 index 000000000..b674157fd --- /dev/null +++ b/authentik_client/models/themed_urls.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ThemedUrls(BaseModel): + """ + Themed URLs - maps theme names to URLs for light and dark themes + """ # noqa: E501 + light: Optional[StrictStr] = None + dark: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["light", "dark"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ThemedUrls from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if light (nullable) is None + # and model_fields_set contains the field + if self.light is None and "light" in self.model_fields_set: + _dict['light'] = None + + # set to None if dark (nullable) is None + # and model_fields_set contains the field + if self.dark is None and "dark" in self.model_fields_set: + _dict['dark'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ThemedUrls from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "light": obj.get("light"), + "dark": obj.get("dark") + }) + return _obj + + diff --git a/authentik_client/models/token.py b/authentik_client/models/token.py new file mode 100644 index 000000000..515427fa2 --- /dev/null +++ b/authentik_client/models/token.py @@ -0,0 +1,137 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.intent_enum import IntentEnum +from authentik_client.models.user import User +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Token(BaseModel): + """ + Token Serializer + """ # noqa: E501 + pk: UUID + managed: Optional[StrictStr] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + identifier: Annotated[str, Field(strict=True, max_length=255)] + intent: Optional[IntentEnum] = None + user: Optional[StrictInt] = None + user_obj: User + description: Optional[StrictStr] = None + expires: Optional[datetime] = None + expiring: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["pk", "managed", "identifier", "intent", "user", "user_obj", "description", "expires", "expiring"] + + @field_validator('identifier') + def identifier_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Token from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user_obj + if self.user_obj: + _dict['user_obj'] = self.user_obj.to_dict() + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Token from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "managed": obj.get("managed"), + "identifier": obj.get("identifier"), + "intent": obj.get("intent"), + "user": obj.get("user"), + "user_obj": User.from_dict(obj["user_obj"]) if obj.get("user_obj") is not None else None, + "description": obj.get("description"), + "expires": obj.get("expires"), + "expiring": obj.get("expiring") + }) + return _obj + + diff --git a/authentik_client/models/token_model.py b/authentik_client/models/token_model.py new file mode 100644 index 000000000..a341d2286 --- /dev/null +++ b/authentik_client/models/token_model.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.provider import Provider +from authentik_client.models.user import User +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TokenModel(BaseModel): + """ + Serializer for BaseGrantModel and RefreshToken + """ # noqa: E501 + pk: StrictInt + provider: Provider + user: User + is_expired: StrictBool = Field(description="Check if token is expired yet.") + expires: Optional[datetime] = None + scope: List[StrictStr] + id_token: StrictStr = Field(description="Get the token's id_token as JSON String") + revoked: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["pk", "provider", "user", "is_expired", "expires", "scope", "id_token", "revoked"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TokenModel from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "is_expired", + "id_token", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of provider + if self.provider: + _dict['provider'] = self.provider.to_dict() + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TokenModel from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "provider": Provider.from_dict(obj["provider"]) if obj.get("provider") is not None else None, + "user": User.from_dict(obj["user"]) if obj.get("user") is not None else None, + "is_expired": obj.get("is_expired"), + "expires": obj.get("expires"), + "scope": obj.get("scope"), + "id_token": obj.get("id_token"), + "revoked": obj.get("revoked") + }) + return _obj + + diff --git a/authentik_client/models/token_request.py b/authentik_client/models/token_request.py new file mode 100644 index 000000000..4a6e717c8 --- /dev/null +++ b/authentik_client/models/token_request.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.intent_enum import IntentEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TokenRequest(BaseModel): + """ + Token Serializer + """ # noqa: E501 + managed: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update.") + identifier: Annotated[str, Field(min_length=1, strict=True, max_length=255)] + intent: Optional[IntentEnum] = None + user: Optional[StrictInt] = None + description: Optional[StrictStr] = None + expires: Optional[datetime] = None + expiring: Optional[StrictBool] = None + __properties: ClassVar[List[str]] = ["managed", "identifier", "intent", "user", "description", "expires", "expiring"] + + @field_validator('identifier') + def identifier_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[-a-zA-Z0-9_]+$", value): + raise ValueError(r"must validate the regular expression /^[-a-zA-Z0-9_]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TokenRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if managed (nullable) is None + # and model_fields_set contains the field + if self.managed is None and "managed" in self.model_fields_set: + _dict['managed'] = None + + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TokenRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "managed": obj.get("managed"), + "identifier": obj.get("identifier"), + "intent": obj.get("intent"), + "user": obj.get("user"), + "description": obj.get("description"), + "expires": obj.get("expires"), + "expiring": obj.get("expiring") + }) + return _obj + + diff --git a/authentik_client/models/token_set_key_request.py b/authentik_client/models/token_set_key_request.py new file mode 100644 index 000000000..8c800ac40 --- /dev/null +++ b/authentik_client/models/token_set_key_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TokenSetKeyRequest(BaseModel): + """ + Set token's key + """ # noqa: E501 + key: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["key"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TokenSetKeyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TokenSetKeyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "key": obj.get("key") + }) + return _obj + + diff --git a/authentik_client/models/token_view.py b/authentik_client/models/token_view.py new file mode 100644 index 000000000..1366cc107 --- /dev/null +++ b/authentik_client/models/token_view.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TokenView(BaseModel): + """ + Show token's current key + """ # noqa: E501 + key: StrictStr + __properties: ClassVar[List[str]] = ["key"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TokenView from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "key", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TokenView from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "key": obj.get("key") + }) + return _obj + + diff --git a/authentik_client/models/totp_device.py b/authentik_client/models/totp_device.py new file mode 100644 index 000000000..62ca68fbf --- /dev/null +++ b/authentik_client/models/totp_device.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from authentik_client.models.partial_user import PartialUser +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TOTPDevice(BaseModel): + """ + Serializer for totp authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + pk: StrictInt + user: PartialUser + __properties: ClassVar[List[str]] = ["name", "pk", "user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TOTPDevice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TOTPDevice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "pk": obj.get("pk"), + "user": PartialUser.from_dict(obj["user"]) if obj.get("user") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/totp_device_request.py b/authentik_client/models/totp_device_request.py new file mode 100644 index 000000000..68ba6be3c --- /dev/null +++ b/authentik_client/models/totp_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TOTPDeviceRequest(BaseModel): + """ + Serializer for totp authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True, max_length=64)] = Field(description="The human-readable name of this device.") + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TOTPDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TOTPDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/transaction_application_request.py b/authentik_client/models/transaction_application_request.py new file mode 100644 index 000000000..48b2571a3 --- /dev/null +++ b/authentik_client/models/transaction_application_request.py @@ -0,0 +1,112 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.application_request import ApplicationRequest +from authentik_client.models.model_request import ModelRequest +from authentik_client.models.provider_model_enum import ProviderModelEnum +from authentik_client.models.transaction_policy_binding_request import TransactionPolicyBindingRequest +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TransactionApplicationRequest(BaseModel): + """ + Serializer for creating a provider and an application in one transaction + """ # noqa: E501 + app: ApplicationRequest + provider_model: ProviderModelEnum + provider: ModelRequest + policy_bindings: Optional[List[TransactionPolicyBindingRequest]] = None + __properties: ClassVar[List[str]] = ["app", "provider_model", "provider", "policy_bindings"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TransactionApplicationRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of app + if self.app: + _dict['app'] = self.app.to_dict() + # override the default output from pydantic by calling `to_dict()` of provider + if self.provider: + _dict['provider'] = self.provider.to_dict() + # override the default output from pydantic by calling `to_dict()` of each item in policy_bindings (list) + _items = [] + if self.policy_bindings: + for _item_policy_bindings in self.policy_bindings: + if _item_policy_bindings: + _items.append(_item_policy_bindings.to_dict()) + _dict['policy_bindings'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TransactionApplicationRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "app": ApplicationRequest.from_dict(obj["app"]) if obj.get("app") is not None else None, + "provider_model": obj.get("provider_model"), + "provider": ModelRequest.from_dict(obj["provider"]) if obj.get("provider") is not None else None, + "policy_bindings": [TransactionPolicyBindingRequest.from_dict(_item) for _item in obj["policy_bindings"]] if obj.get("policy_bindings") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/transaction_application_response.py b/authentik_client/models/transaction_application_response.py new file mode 100644 index 000000000..67389e82c --- /dev/null +++ b/authentik_client/models/transaction_application_response.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TransactionApplicationResponse(BaseModel): + """ + Transactional creation response + """ # noqa: E501 + applied: StrictBool + logs: List[StrictStr] + __properties: ClassVar[List[str]] = ["applied", "logs"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TransactionApplicationResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TransactionApplicationResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "applied": obj.get("applied"), + "logs": obj.get("logs") + }) + return _obj + + diff --git a/authentik_client/models/transaction_policy_binding_request.py b/authentik_client/models/transaction_policy_binding_request.py new file mode 100644 index 000000000..bacf64a40 --- /dev/null +++ b/authentik_client/models/transaction_policy_binding_request.py @@ -0,0 +1,120 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TransactionPolicyBindingRequest(BaseModel): + """ + PolicyBindingSerializer which does not require target as target is set implicitly + """ # noqa: E501 + policy: Optional[UUID] = None + group: Optional[UUID] = None + user: Optional[StrictInt] = None + negate: Optional[StrictBool] = Field(default=None, description="Negates the outcome of the policy. Messages are unaffected.") + enabled: Optional[StrictBool] = None + order: Annotated[int, Field(le=2147483647, strict=True, ge=-2147483648)] + timeout: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Timeout after which Policy execution is terminated.") + failure_result: Optional[StrictBool] = Field(default=None, description="Result if the Policy execution fails.") + __properties: ClassVar[List[str]] = ["policy", "group", "user", "negate", "enabled", "order", "timeout", "failure_result"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TransactionPolicyBindingRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if policy (nullable) is None + # and model_fields_set contains the field + if self.policy is None and "policy" in self.model_fields_set: + _dict['policy'] = None + + # set to None if group (nullable) is None + # and model_fields_set contains the field + if self.group is None and "group" in self.model_fields_set: + _dict['group'] = None + + # set to None if user (nullable) is None + # and model_fields_set contains the field + if self.user is None and "user" in self.model_fields_set: + _dict['user'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TransactionPolicyBindingRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "policy": obj.get("policy"), + "group": obj.get("group"), + "user": obj.get("user"), + "negate": obj.get("negate"), + "enabled": obj.get("enabled"), + "order": obj.get("order"), + "timeout": obj.get("timeout"), + "failure_result": obj.get("failure_result") + }) + return _obj + + diff --git a/authentik_client/models/transport_mode_enum.py b/authentik_client/models/transport_mode_enum.py new file mode 100644 index 000000000..4d12fb245 --- /dev/null +++ b/authentik_client/models/transport_mode_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class TransportModeEnum(str, Enum): + """ + TransportModeEnum + """ + + """ + allowed enum values + """ + LOCAL = 'local' + WEBHOOK = 'webhook' + WEBHOOK_SLACK = 'webhook_slack' + EMAIL = 'email' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of TransportModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/type_create.py b/authentik_client/models/type_create.py new file mode 100644 index 000000000..a621ca890 --- /dev/null +++ b/authentik_client/models/type_create.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class TypeCreate(BaseModel): + """ + Types of an object that can be created + """ # noqa: E501 + name: StrictStr + description: StrictStr + component: StrictStr + model_name: StrictStr + icon_url: Optional[StrictStr] = None + requires_enterprise: Optional[StrictBool] = False + deprecated: Optional[StrictBool] = False + __properties: ClassVar[List[str]] = ["name", "description", "component", "model_name", "icon_url", "requires_enterprise", "deprecated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of TypeCreate from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of TypeCreate from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "description": obj.get("description"), + "component": obj.get("component"), + "model_name": obj.get("model_name"), + "icon_url": obj.get("icon_url"), + "requires_enterprise": obj.get("requires_enterprise") if obj.get("requires_enterprise") is not None else False, + "deprecated": obj.get("deprecated") if obj.get("deprecated") is not None else False + }) + return _obj + + diff --git a/authentik_client/models/ui_theme_enum.py b/authentik_client/models/ui_theme_enum.py new file mode 100644 index 000000000..333388b00 --- /dev/null +++ b/authentik_client/models/ui_theme_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class UiThemeEnum(str, Enum): + """ + UiThemeEnum + """ + + """ + allowed enum values + """ + AUTOMATIC = 'automatic' + LIGHT = 'light' + DARK = 'dark' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of UiThemeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/unique_password_policy.py b/authentik_client/models/unique_password_policy.py new file mode 100644 index 000000000..0f9dc6276 --- /dev/null +++ b/authentik_client/models/unique_password_policy.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UniquePasswordPolicy(BaseModel): + """ + Password Uniqueness Policy Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + bound_to: StrictInt = Field(description="Return objects policy is bound to") + password_field: Optional[StrictStr] = Field(default=None, description="Field key to check, field keys defined in Prompt stages are available.") + num_historical_passwords: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Number of passwords to check against.") + __properties: ClassVar[List[str]] = ["pk", "name", "execution_logging", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "bound_to", "password_field", "num_historical_passwords"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UniquePasswordPolicy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "bound_to", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UniquePasswordPolicy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "bound_to": obj.get("bound_to"), + "password_field": obj.get("password_field"), + "num_historical_passwords": obj.get("num_historical_passwords") + }) + return _obj + + diff --git a/authentik_client/models/unique_password_policy_request.py b/authentik_client/models/unique_password_policy_request.py new file mode 100644 index 000000000..75db2c487 --- /dev/null +++ b/authentik_client/models/unique_password_policy_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UniquePasswordPolicyRequest(BaseModel): + """ + Password Uniqueness Policy Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + execution_logging: Optional[StrictBool] = Field(default=None, description="When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.") + password_field: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Field key to check, field keys defined in Prompt stages are available.") + num_historical_passwords: Optional[Annotated[int, Field(le=2147483647, strict=True, ge=0)]] = Field(default=None, description="Number of passwords to check against.") + __properties: ClassVar[List[str]] = ["name", "execution_logging", "password_field", "num_historical_passwords"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UniquePasswordPolicyRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UniquePasswordPolicyRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "execution_logging": obj.get("execution_logging"), + "password_field": obj.get("password_field"), + "num_historical_passwords": obj.get("num_historical_passwords") + }) + return _obj + + diff --git a/authentik_client/models/usage_enum.py b/authentik_client/models/usage_enum.py new file mode 100644 index 000000000..63e9506fd --- /dev/null +++ b/authentik_client/models/usage_enum.py @@ -0,0 +1,37 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class UsageEnum(str, Enum): + """ + UsageEnum + """ + + """ + allowed enum values + """ + MEDIA = 'media' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of UsageEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/used_by.py b/authentik_client/models/used_by.py new file mode 100644 index 000000000..6fa0a3f1c --- /dev/null +++ b/authentik_client/models/used_by.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from authentik_client.models.used_by_action_enum import UsedByActionEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UsedBy(BaseModel): + """ + A list of all objects referencing the queried object + """ # noqa: E501 + app: StrictStr + model_name: StrictStr + pk: StrictStr + name: StrictStr + action: UsedByActionEnum + __properties: ClassVar[List[str]] = ["app", "model_name", "pk", "name", "action"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UsedBy from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UsedBy from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "app": obj.get("app"), + "model_name": obj.get("model_name"), + "pk": obj.get("pk"), + "name": obj.get("name"), + "action": obj.get("action") + }) + return _obj + + diff --git a/authentik_client/models/used_by_action_enum.py b/authentik_client/models/used_by_action_enum.py new file mode 100644 index 000000000..480e41061 --- /dev/null +++ b/authentik_client/models/used_by_action_enum.py @@ -0,0 +1,41 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class UsedByActionEnum(str, Enum): + """ + UsedByActionEnum + """ + + """ + allowed enum values + """ + CASCADE = 'cascade' + CASCADE_MANY = 'cascade_many' + SET_NULL = 'set_null' + SET_DEFAULT = 'set_default' + LEFT_DANGLING = 'left_dangling' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of UsedByActionEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/user.py b/authentik_client/models/user.py new file mode 100644 index 000000000..d13696f9c --- /dev/null +++ b/authentik_client/models/user.py @@ -0,0 +1,182 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.partial_group import PartialGroup +from authentik_client.models.role import Role +from authentik_client.models.user_type_enum import UserTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class User(BaseModel): + """ + User Serializer + """ # noqa: E501 + pk: StrictInt + username: Annotated[str, Field(strict=True, max_length=150)] + name: StrictStr = Field(description="User's display name.") + is_active: Optional[StrictBool] = Field(default=None, description="Designates whether this user should be treated as active. Unselect this instead of deleting accounts.") + last_login: Optional[datetime] = None + date_joined: datetime + is_superuser: StrictBool + groups: Optional[List[UUID]] = None + groups_obj: Optional[List[PartialGroup]] + roles: Optional[List[UUID]] = None + roles_obj: Optional[List[Role]] + email: Optional[Annotated[str, Field(strict=True, max_length=254)]] = None + avatar: StrictStr = Field(description="User's avatar, either a http/https URL or a data URI") + attributes: Optional[Dict[str, Any]] = None + uid: StrictStr + path: Optional[StrictStr] = None + type: Optional[UserTypeEnum] = None + uuid: UUID + password_change_date: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "username", "name", "is_active", "last_login", "date_joined", "is_superuser", "groups", "groups_obj", "roles", "roles_obj", "email", "avatar", "attributes", "uid", "path", "type", "uuid", "password_change_date", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of User from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "date_joined", + "is_superuser", + "groups_obj", + "roles_obj", + "avatar", + "uid", + "uuid", + "password_change_date", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in groups_obj (list) + _items = [] + if self.groups_obj: + for _item_groups_obj in self.groups_obj: + if _item_groups_obj: + _items.append(_item_groups_obj.to_dict()) + _dict['groups_obj'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in roles_obj (list) + _items = [] + if self.roles_obj: + for _item_roles_obj in self.roles_obj: + if _item_roles_obj: + _items.append(_item_roles_obj.to_dict()) + _dict['roles_obj'] = _items + # set to None if last_login (nullable) is None + # and model_fields_set contains the field + if self.last_login is None and "last_login" in self.model_fields_set: + _dict['last_login'] = None + + # set to None if groups_obj (nullable) is None + # and model_fields_set contains the field + if self.groups_obj is None and "groups_obj" in self.model_fields_set: + _dict['groups_obj'] = None + + # set to None if roles_obj (nullable) is None + # and model_fields_set contains the field + if self.roles_obj is None and "roles_obj" in self.model_fields_set: + _dict['roles_obj'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of User from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "username": obj.get("username"), + "name": obj.get("name"), + "is_active": obj.get("is_active"), + "last_login": obj.get("last_login"), + "date_joined": obj.get("date_joined"), + "is_superuser": obj.get("is_superuser"), + "groups": obj.get("groups"), + "groups_obj": [PartialGroup.from_dict(_item) for _item in obj["groups_obj"]] if obj.get("groups_obj") is not None else None, + "roles": obj.get("roles"), + "roles_obj": [Role.from_dict(_item) for _item in obj["roles_obj"]] if obj.get("roles_obj") is not None else None, + "email": obj.get("email"), + "avatar": obj.get("avatar"), + "attributes": obj.get("attributes"), + "uid": obj.get("uid"), + "path": obj.get("path"), + "type": obj.get("type"), + "uuid": obj.get("uuid"), + "password_change_date": obj.get("password_change_date"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/user_account_lockdown_request.py b/authentik_client/models/user_account_lockdown_request.py new file mode 100644 index 000000000..73e5f3b71 --- /dev/null +++ b/authentik_client/models/user_account_lockdown_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserAccountLockdownRequest(BaseModel): + """ + Choose the target account before starting the lockdown flow. + """ # noqa: E501 + user: Optional[StrictInt] = Field(default=None, description="User to lock. If omitted, locks the current user (self-service).") + __properties: ClassVar[List[str]] = ["user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserAccountLockdownRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if user (nullable) is None + # and model_fields_set contains the field + if self.user is None and "user" in self.model_fields_set: + _dict['user'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserAccountLockdownRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "user": obj.get("user") + }) + return _obj + + diff --git a/authentik_client/models/user_account_request.py b/authentik_client/models/user_account_request.py new file mode 100644 index 000000000..9b78825cb --- /dev/null +++ b/authentik_client/models/user_account_request.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserAccountRequest(BaseModel): + """ + Account adding/removing operations + """ # noqa: E501 + pk: StrictInt + __properties: ClassVar[List[str]] = ["pk"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserAccountRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserAccountRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk") + }) + return _obj + + diff --git a/authentik_client/models/user_account_serializer_for_role_request.py b/authentik_client/models/user_account_serializer_for_role_request.py new file mode 100644 index 000000000..151cf3693 --- /dev/null +++ b/authentik_client/models/user_account_serializer_for_role_request.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserAccountSerializerForRoleRequest(BaseModel): + """ + Account adding/removing operations + """ # noqa: E501 + pk: StrictInt + __properties: ClassVar[List[str]] = ["pk"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserAccountSerializerForRoleRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserAccountSerializerForRoleRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk") + }) + return _obj + + diff --git a/authentik_client/models/user_attribute_enum.py b/authentik_client/models/user_attribute_enum.py new file mode 100644 index 000000000..0a06391f6 --- /dev/null +++ b/authentik_client/models/user_attribute_enum.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class UserAttributeEnum(str, Enum): + """ + UserAttributeEnum + """ + + """ + allowed enum values + """ + USERNAME = 'username' + EMAIL = 'email' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of UserAttributeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/user_consent.py b/authentik_client/models/user_consent.py new file mode 100644 index 000000000..bdb0fcdf4 --- /dev/null +++ b/authentik_client/models/user_consent.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.application import Application +from authentik_client.models.user import User +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserConsent(BaseModel): + """ + UserConsent Serializer + """ # noqa: E501 + pk: StrictInt + expires: Optional[datetime] = None + expiring: Optional[StrictBool] = None + user: User + application: Application + permissions: Optional[StrictStr] = '' + __properties: ClassVar[List[str]] = ["pk", "expires", "expiring", "user", "application", "permissions"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserConsent from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + # override the default output from pydantic by calling `to_dict()` of application + if self.application: + _dict['application'] = self.application.to_dict() + # set to None if expires (nullable) is None + # and model_fields_set contains the field + if self.expires is None and "expires" in self.model_fields_set: + _dict['expires'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserConsent from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "expires": obj.get("expires"), + "expiring": obj.get("expiring"), + "user": User.from_dict(obj["user"]) if obj.get("user") is not None else None, + "application": Application.from_dict(obj["application"]) if obj.get("application") is not None else None, + "permissions": obj.get("permissions") if obj.get("permissions") is not None else '' + }) + return _obj + + diff --git a/authentik_client/models/user_creation_mode_enum.py b/authentik_client/models/user_creation_mode_enum.py new file mode 100644 index 000000000..cf9df45ee --- /dev/null +++ b/authentik_client/models/user_creation_mode_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class UserCreationModeEnum(str, Enum): + """ + UserCreationModeEnum + """ + + """ + allowed enum values + """ + NEVER_CREATE = 'never_create' + CREATE_WHEN_REQUIRED = 'create_when_required' + ALWAYS_CREATE = 'always_create' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of UserCreationModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/user_delete_stage.py b/authentik_client/models/user_delete_stage.py new file mode 100644 index 000000000..e36dfceb1 --- /dev/null +++ b/authentik_client/models/user_delete_stage.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserDeleteStage(BaseModel): + """ + UserDeleteStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserDeleteStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserDeleteStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/user_delete_stage_request.py b/authentik_client/models/user_delete_stage_request.py new file mode 100644 index 000000000..e1a83e32d --- /dev/null +++ b/authentik_client/models/user_delete_stage_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserDeleteStageRequest(BaseModel): + """ + UserDeleteStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserDeleteStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserDeleteStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/user_fields_enum.py b/authentik_client/models/user_fields_enum.py new file mode 100644 index 000000000..6015fd54e --- /dev/null +++ b/authentik_client/models/user_fields_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class UserFieldsEnum(str, Enum): + """ + UserFieldsEnum + """ + + """ + allowed enum values + """ + EMAIL = 'email' + USERNAME = 'username' + UPN = 'upn' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of UserFieldsEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/user_kerberos_source_connection.py b/authentik_client/models/user_kerberos_source_connection.py new file mode 100644 index 000000000..0d28d4d95 --- /dev/null +++ b/authentik_client/models/user_kerberos_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserKerberosSourceConnection(BaseModel): + """ + User source connection + """ # noqa: E501 + pk: StrictInt + user: StrictInt + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "user", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserKerberosSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserKerberosSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "user": obj.get("user"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/user_kerberos_source_connection_request.py b/authentik_client/models/user_kerberos_source_connection_request.py new file mode 100644 index 000000000..00a986556 --- /dev/null +++ b/authentik_client/models/user_kerberos_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserKerberosSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserKerberosSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserKerberosSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/user_ldap_source_connection.py b/authentik_client/models/user_ldap_source_connection.py new file mode 100644 index 000000000..95d6d4bc9 --- /dev/null +++ b/authentik_client/models/user_ldap_source_connection.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.partial_user import PartialUser +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserLDAPSourceConnection(BaseModel): + """ + User source connection + """ # noqa: E501 + pk: StrictInt + user: StrictInt + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + user_obj: PartialUser + __properties: ClassVar[List[str]] = ["pk", "user", "source", "source_obj", "identifier", "created", "last_updated", "user_obj"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserLDAPSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user", + "source_obj", + "created", + "last_updated", + "user_obj", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + # override the default output from pydantic by calling `to_dict()` of user_obj + if self.user_obj: + _dict['user_obj'] = self.user_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserLDAPSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "user": obj.get("user"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated"), + "user_obj": PartialUser.from_dict(obj["user_obj"]) if obj.get("user_obj") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/user_ldap_source_connection_request.py b/authentik_client/models/user_ldap_source_connection_request.py new file mode 100644 index 000000000..57266215e --- /dev/null +++ b/authentik_client/models/user_ldap_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserLDAPSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserLDAPSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserLDAPSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/user_login_challenge.py b/authentik_client/models/user_login_challenge.py new file mode 100644 index 000000000..a96c9c04a --- /dev/null +++ b/authentik_client/models/user_login_challenge.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from authentik_client.models.contextual_flow_info import ContextualFlowInfo +from authentik_client.models.error_detail import ErrorDetail +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserLoginChallenge(BaseModel): + """ + Empty challenge + """ # noqa: E501 + flow_info: Optional[ContextualFlowInfo] = None + component: Optional[StrictStr] = 'ak-stage-user-login' + response_errors: Optional[Dict[str, List[ErrorDetail]]] = None + pending_user: StrictStr + pending_user_avatar: StrictStr + __properties: ClassVar[List[str]] = ["flow_info", "component", "response_errors", "pending_user", "pending_user_avatar"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserLoginChallenge from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of flow_info + if self.flow_info: + _dict['flow_info'] = self.flow_info.to_dict() + # override the default output from pydantic by calling `to_dict()` of each value in response_errors (dict of array) + _field_dict_of_array = {} + if self.response_errors: + for _key_response_errors in self.response_errors: + if self.response_errors[_key_response_errors] is not None: + _field_dict_of_array[_key_response_errors] = [ + _item.to_dict() for _item in self.response_errors[_key_response_errors] + ] + _dict['response_errors'] = _field_dict_of_array + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserLoginChallenge from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "flow_info": ContextualFlowInfo.from_dict(obj["flow_info"]) if obj.get("flow_info") is not None else None, + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-user-login', + "response_errors": { + _k: [ErrorDetail.from_dict(_item) for _item in _v] if _v is not None else None + for _k, _v in obj["response_errors"].items() + } + if obj.get("response_errors") is not None + else None, + "pending_user": obj.get("pending_user"), + "pending_user_avatar": obj.get("pending_user_avatar") + }) + return _obj + + diff --git a/authentik_client/models/user_login_challenge_response_request.py b/authentik_client/models/user_login_challenge_response_request.py new file mode 100644 index 000000000..ab3ae5689 --- /dev/null +++ b/authentik_client/models/user_login_challenge_response_request.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserLoginChallengeResponseRequest(BaseModel): + """ + User login challenge + """ # noqa: E501 + component: Optional[Annotated[str, Field(min_length=1, strict=True)]] = 'ak-stage-user-login' + remember_me: StrictBool + __properties: ClassVar[List[str]] = ["component", "remember_me"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserLoginChallengeResponseRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserLoginChallengeResponseRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "component": obj.get("component") if obj.get("component") is not None else 'ak-stage-user-login', + "remember_me": obj.get("remember_me") + }) + return _obj + + diff --git a/authentik_client/models/user_login_stage.py b/authentik_client/models/user_login_stage.py new file mode 100644 index 000000000..ae7218584 --- /dev/null +++ b/authentik_client/models/user_login_stage.py @@ -0,0 +1,136 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.geoip_binding_enum import GeoipBindingEnum +from authentik_client.models.network_binding_enum import NetworkBindingEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserLoginStage(BaseModel): + """ + UserLoginStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + session_duration: Optional[StrictStr] = Field(default=None, description="Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)") + terminate_other_sessions: Optional[StrictBool] = Field(default=None, description="Terminate all other sessions of the user logging in.") + remember_me_offset: Optional[StrictStr] = Field(default=None, description="Offset the session will be extended by when the user picks the remember me option. Default of 0 means that the remember me option will not be shown. (Format: hours=-1;minutes=-2;seconds=-3)") + network_binding: Optional[NetworkBindingEnum] = Field(default=None, description="Bind sessions created by this stage to the configured network") + geoip_binding: Optional[GeoipBindingEnum] = Field(default=None, description="Bind sessions created by this stage to the configured GeoIP location") + remember_device: Optional[StrictStr] = Field(default=None, description="When set to a non-zero value, authentik will save a cookie with a longer expiry,to remember the device the user is logging in from. (Format: hours=-1;minutes=-2;seconds=-3)") + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "session_duration", "terminate_other_sessions", "remember_me_offset", "network_binding", "geoip_binding", "remember_device"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserLoginStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserLoginStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "session_duration": obj.get("session_duration"), + "terminate_other_sessions": obj.get("terminate_other_sessions"), + "remember_me_offset": obj.get("remember_me_offset"), + "network_binding": obj.get("network_binding"), + "geoip_binding": obj.get("geoip_binding"), + "remember_device": obj.get("remember_device") + }) + return _obj + + diff --git a/authentik_client/models/user_login_stage_request.py b/authentik_client/models/user_login_stage_request.py new file mode 100644 index 000000000..7d4a1afd0 --- /dev/null +++ b/authentik_client/models/user_login_stage_request.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.geoip_binding_enum import GeoipBindingEnum +from authentik_client.models.network_binding_enum import NetworkBindingEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserLoginStageRequest(BaseModel): + """ + UserLoginStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + session_duration: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)") + terminate_other_sessions: Optional[StrictBool] = Field(default=None, description="Terminate all other sessions of the user logging in.") + remember_me_offset: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Offset the session will be extended by when the user picks the remember me option. Default of 0 means that the remember me option will not be shown. (Format: hours=-1;minutes=-2;seconds=-3)") + network_binding: Optional[NetworkBindingEnum] = Field(default=None, description="Bind sessions created by this stage to the configured network") + geoip_binding: Optional[GeoipBindingEnum] = Field(default=None, description="Bind sessions created by this stage to the configured GeoIP location") + remember_device: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="When set to a non-zero value, authentik will save a cookie with a longer expiry,to remember the device the user is logging in from. (Format: hours=-1;minutes=-2;seconds=-3)") + __properties: ClassVar[List[str]] = ["name", "session_duration", "terminate_other_sessions", "remember_me_offset", "network_binding", "geoip_binding", "remember_device"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserLoginStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserLoginStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "session_duration": obj.get("session_duration"), + "terminate_other_sessions": obj.get("terminate_other_sessions"), + "remember_me_offset": obj.get("remember_me_offset"), + "network_binding": obj.get("network_binding"), + "geoip_binding": obj.get("geoip_binding"), + "remember_device": obj.get("remember_device") + }) + return _obj + + diff --git a/authentik_client/models/user_logout_stage.py b/authentik_client/models/user_logout_stage.py new file mode 100644 index 000000000..98e9261d7 --- /dev/null +++ b/authentik_client/models/user_logout_stage.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserLogoutStage(BaseModel): + """ + UserLogoutStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserLogoutStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserLogoutStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/user_logout_stage_request.py b/authentik_client/models/user_logout_stage_request.py new file mode 100644 index 000000000..4c7a23625 --- /dev/null +++ b/authentik_client/models/user_logout_stage_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserLogoutStageRequest(BaseModel): + """ + UserLogoutStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserLogoutStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserLogoutStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/user_matching_mode_enum.py b/authentik_client/models/user_matching_mode_enum.py new file mode 100644 index 000000000..b085e7318 --- /dev/null +++ b/authentik_client/models/user_matching_mode_enum.py @@ -0,0 +1,41 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class UserMatchingModeEnum(str, Enum): + """ + UserMatchingModeEnum + """ + + """ + allowed enum values + """ + IDENTIFIER = 'identifier' + EMAIL_LINK = 'email_link' + EMAIL_DENY = 'email_deny' + USERNAME_LINK = 'username_link' + USERNAME_DENY = 'username_deny' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of UserMatchingModeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/user_o_auth_source_connection.py b/authentik_client/models/user_o_auth_source_connection.py new file mode 100644 index 000000000..81e4101af --- /dev/null +++ b/authentik_client/models/user_o_auth_source_connection.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserOAuthSourceConnection(BaseModel): + """ + User source connection + """ # noqa: E501 + pk: StrictInt + user: StrictInt + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + expires: Optional[datetime] = None + __properties: ClassVar[List[str]] = ["pk", "user", "source", "source_obj", "identifier", "created", "last_updated", "expires"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserOAuthSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserOAuthSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "user": obj.get("user"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated"), + "expires": obj.get("expires") + }) + return _obj + + diff --git a/authentik_client/models/user_o_auth_source_connection_request.py b/authentik_client/models/user_o_auth_source_connection_request.py new file mode 100644 index 000000000..997c3e400 --- /dev/null +++ b/authentik_client/models/user_o_auth_source_connection_request.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserOAuthSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + access_token: Optional[StrictStr] = None + expires: Optional[datetime] = None + __properties: ClassVar[List[str]] = ["source", "identifier", "access_token", "expires"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserOAuthSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if access_token (nullable) is None + # and model_fields_set contains the field + if self.access_token is None and "access_token" in self.model_fields_set: + _dict['access_token'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserOAuthSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier"), + "access_token": obj.get("access_token"), + "expires": obj.get("expires") + }) + return _obj + + diff --git a/authentik_client/models/user_password_hash_set_request.py b/authentik_client/models/user_password_hash_set_request.py new file mode 100644 index 000000000..57a56ad98 --- /dev/null +++ b/authentik_client/models/user_password_hash_set_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserPasswordHashSetRequest(BaseModel): + """ + Payload to set a users' password hash directly + """ # noqa: E501 + password: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["password"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserPasswordHashSetRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserPasswordHashSetRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "password": obj.get("password") + }) + return _obj + + diff --git a/authentik_client/models/user_password_set_request.py b/authentik_client/models/user_password_set_request.py new file mode 100644 index 000000000..c6d498e28 --- /dev/null +++ b/authentik_client/models/user_password_set_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserPasswordSetRequest(BaseModel): + """ + Payload to set a users' password directly + """ # noqa: E501 + password: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["password"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserPasswordSetRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserPasswordSetRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "password": obj.get("password") + }) + return _obj + + diff --git a/authentik_client/models/user_path.py b/authentik_client/models/user_path.py new file mode 100644 index 000000000..f0bf37525 --- /dev/null +++ b/authentik_client/models/user_path.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserPath(BaseModel): + """ + UserPath + """ # noqa: E501 + paths: List[StrictStr] + __properties: ClassVar[List[str]] = ["paths"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserPath from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "paths", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserPath from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "paths": obj.get("paths") + }) + return _obj + + diff --git a/authentik_client/models/user_plex_source_connection.py b/authentik_client/models/user_plex_source_connection.py new file mode 100644 index 000000000..d400dc4ed --- /dev/null +++ b/authentik_client/models/user_plex_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserPlexSourceConnection(BaseModel): + """ + User source connection + """ # noqa: E501 + pk: StrictInt + user: StrictInt + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "user", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserPlexSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserPlexSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "user": obj.get("user"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/user_plex_source_connection_request.py b/authentik_client/models/user_plex_source_connection_request.py new file mode 100644 index 000000000..dd1cac389 --- /dev/null +++ b/authentik_client/models/user_plex_source_connection_request.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserPlexSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + plex_token: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier", "plex_token"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserPlexSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserPlexSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier"), + "plex_token": obj.get("plex_token") + }) + return _obj + + diff --git a/authentik_client/models/user_recovery_email_request.py b/authentik_client/models/user_recovery_email_request.py new file mode 100644 index 000000000..a4fae3062 --- /dev/null +++ b/authentik_client/models/user_recovery_email_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserRecoveryEmailRequest(BaseModel): + """ + Payload to create and email a recovery link + """ # noqa: E501 + token_duration: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + email_stage: UUID + __properties: ClassVar[List[str]] = ["token_duration", "email_stage"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserRecoveryEmailRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserRecoveryEmailRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "token_duration": obj.get("token_duration"), + "email_stage": obj.get("email_stage") + }) + return _obj + + diff --git a/authentik_client/models/user_recovery_link_request.py b/authentik_client/models/user_recovery_link_request.py new file mode 100644 index 000000000..9a5d2b34c --- /dev/null +++ b/authentik_client/models/user_recovery_link_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserRecoveryLinkRequest(BaseModel): + """ + Payload to create a recovery link + """ # noqa: E501 + token_duration: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + __properties: ClassVar[List[str]] = ["token_duration"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserRecoveryLinkRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserRecoveryLinkRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "token_duration": obj.get("token_duration") + }) + return _obj + + diff --git a/authentik_client/models/user_request.py b/authentik_client/models/user_request.py new file mode 100644 index 000000000..864171341 --- /dev/null +++ b/authentik_client/models/user_request.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.user_type_enum import UserTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserRequest(BaseModel): + """ + User Serializer + """ # noqa: E501 + username: Annotated[str, Field(min_length=1, strict=True, max_length=150)] + name: StrictStr = Field(description="User's display name.") + is_active: Optional[StrictBool] = Field(default=None, description="Designates whether this user should be treated as active. Unselect this instead of deleting accounts.") + last_login: Optional[datetime] = None + groups: Optional[List[UUID]] = None + roles: Optional[List[UUID]] = None + email: Optional[Annotated[str, Field(strict=True, max_length=254)]] = None + attributes: Optional[Dict[str, Any]] = None + path: Optional[Annotated[str, Field(min_length=1, strict=True)]] = None + type: Optional[UserTypeEnum] = None + __properties: ClassVar[List[str]] = ["username", "name", "is_active", "last_login", "groups", "roles", "email", "attributes", "path", "type"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if last_login (nullable) is None + # and model_fields_set contains the field + if self.last_login is None and "last_login" in self.model_fields_set: + _dict['last_login'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "username": obj.get("username"), + "name": obj.get("name"), + "is_active": obj.get("is_active"), + "last_login": obj.get("last_login"), + "groups": obj.get("groups"), + "roles": obj.get("roles"), + "email": obj.get("email"), + "attributes": obj.get("attributes"), + "path": obj.get("path"), + "type": obj.get("type") + }) + return _obj + + diff --git a/authentik_client/models/user_saml_source_connection.py b/authentik_client/models/user_saml_source_connection.py new file mode 100644 index 000000000..5ad88ec1a --- /dev/null +++ b/authentik_client/models/user_saml_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserSAMLSourceConnection(BaseModel): + """ + User source connection + """ # noqa: E501 + pk: StrictInt + user: StrictInt + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "user", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserSAMLSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserSAMLSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "user": obj.get("user"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/user_saml_source_connection_request.py b/authentik_client/models/user_saml_source_connection_request.py new file mode 100644 index 000000000..9df052fc0 --- /dev/null +++ b/authentik_client/models/user_saml_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserSAMLSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserSAMLSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserSAMLSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/user_self.py b/authentik_client/models/user_self.py new file mode 100644 index 000000000..a46f71f7c --- /dev/null +++ b/authentik_client/models/user_self.py @@ -0,0 +1,159 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr, field_validator +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.user_self_groups import UserSelfGroups +from authentik_client.models.user_self_roles import UserSelfRoles +from authentik_client.models.user_type_enum import UserTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserSelf(BaseModel): + """ + User Serializer for information a user can retrieve about themselves + """ # noqa: E501 + pk: StrictInt + username: Annotated[str, Field(strict=True, max_length=150)] = Field(description="Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.") + name: StrictStr = Field(description="User's display name.") + is_active: StrictBool = Field(description="Designates whether this user should be treated as active. Unselect this instead of deleting accounts.") + is_superuser: StrictBool + groups: List[UserSelfGroups] + roles: List[UserSelfRoles] + email: Optional[Annotated[str, Field(strict=True, max_length=254)]] = None + avatar: StrictStr = Field(description="User's avatar, either a http/https URL or a data URI") + uid: StrictStr + settings: Dict[str, Any] = Field(description="Get user settings with brand and group settings applied") + type: Optional[UserTypeEnum] = None + system_permissions: List[StrictStr] = Field(description="Get all system permissions assigned to the user") + __properties: ClassVar[List[str]] = ["pk", "username", "name", "is_active", "is_superuser", "groups", "roles", "email", "avatar", "uid", "settings", "type", "system_permissions"] + + @field_validator('username') + def username_validate_regular_expression(cls, value): + """Validates the regular expression""" + if not isinstance(value, str): + value = str(value) + + if not re.match(r"^[\w.@+-]+$", value): + raise ValueError(r"must validate the regular expression /^[\w.@+-]+$/") + return value + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserSelf from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "is_active", + "is_superuser", + "groups", + "roles", + "avatar", + "uid", + "settings", + "system_permissions", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in groups (list) + _items = [] + if self.groups: + for _item_groups in self.groups: + if _item_groups: + _items.append(_item_groups.to_dict()) + _dict['groups'] = _items + # override the default output from pydantic by calling `to_dict()` of each item in roles (list) + _items = [] + if self.roles: + for _item_roles in self.roles: + if _item_roles: + _items.append(_item_roles.to_dict()) + _dict['roles'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserSelf from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "username": obj.get("username"), + "name": obj.get("name"), + "is_active": obj.get("is_active"), + "is_superuser": obj.get("is_superuser"), + "groups": [UserSelfGroups.from_dict(_item) for _item in obj["groups"]] if obj.get("groups") is not None else None, + "roles": [UserSelfRoles.from_dict(_item) for _item in obj["roles"]] if obj.get("roles") is not None else None, + "email": obj.get("email"), + "avatar": obj.get("avatar"), + "uid": obj.get("uid"), + "settings": obj.get("settings"), + "type": obj.get("type"), + "system_permissions": obj.get("system_permissions") + }) + return _obj + + diff --git a/authentik_client/models/user_self_groups.py b/authentik_client/models/user_self_groups.py new file mode 100644 index 000000000..fad4fe232 --- /dev/null +++ b/authentik_client/models/user_self_groups.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserSelfGroups(BaseModel): + """ + UserSelfGroups + """ # noqa: E501 + name: StrictStr + pk: StrictStr + __properties: ClassVar[List[str]] = ["name", "pk"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserSelfGroups from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "name", + "pk", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserSelfGroups from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "pk": obj.get("pk") + }) + return _obj + + diff --git a/authentik_client/models/user_self_roles.py b/authentik_client/models/user_self_roles.py new file mode 100644 index 000000000..e752a20fc --- /dev/null +++ b/authentik_client/models/user_self_roles.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserSelfRoles(BaseModel): + """ + UserSelfRoles + """ # noqa: E501 + name: StrictStr + pk: StrictStr + __properties: ClassVar[List[str]] = ["name", "pk"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserSelfRoles from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "name", + "pk", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserSelfRoles from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "pk": obj.get("pk") + }) + return _obj + + diff --git a/authentik_client/models/user_service_account_request.py b/authentik_client/models/user_service_account_request.py new file mode 100644 index 000000000..716549407 --- /dev/null +++ b/authentik_client/models/user_service_account_request.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserServiceAccountRequest(BaseModel): + """ + Payload to create a service account + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + create_group: Optional[StrictBool] = False + expiring: Optional[StrictBool] = True + expires: Optional[datetime] = Field(default=None, description="If not provided, valid for 360 days") + __properties: ClassVar[List[str]] = ["name", "create_group", "expiring", "expires"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserServiceAccountRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserServiceAccountRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "create_group": obj.get("create_group") if obj.get("create_group") is not None else False, + "expiring": obj.get("expiring") if obj.get("expiring") is not None else True, + "expires": obj.get("expires") + }) + return _obj + + diff --git a/authentik_client/models/user_service_account_response.py b/authentik_client/models/user_service_account_response.py new file mode 100644 index 000000000..a9bf6f264 --- /dev/null +++ b/authentik_client/models/user_service_account_response.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserServiceAccountResponse(BaseModel): + """ + UserServiceAccountResponse + """ # noqa: E501 + username: StrictStr + token: StrictStr + user_uid: StrictStr + user_pk: StrictInt + group_pk: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["username", "token", "user_uid", "user_pk", "group_pk"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserServiceAccountResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserServiceAccountResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "username": obj.get("username"), + "token": obj.get("token"), + "user_uid": obj.get("user_uid"), + "user_pk": obj.get("user_pk"), + "group_pk": obj.get("group_pk") + }) + return _obj + + diff --git a/authentik_client/models/user_setting.py b/authentik_client/models/user_setting.py new file mode 100644 index 000000000..4d337b362 --- /dev/null +++ b/authentik_client/models/user_setting.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserSetting(BaseModel): + """ + Serializer for User settings for stages and sources + """ # noqa: E501 + object_uid: StrictStr + component: StrictStr + title: StrictStr + configure_url: Optional[StrictStr] = None + icon_url: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["object_uid", "component", "title", "configure_url", "icon_url"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserSetting from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserSetting from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "object_uid": obj.get("object_uid"), + "component": obj.get("component"), + "title": obj.get("title"), + "configure_url": obj.get("configure_url"), + "icon_url": obj.get("icon_url") + }) + return _obj + + diff --git a/authentik_client/models/user_source_connection.py b/authentik_client/models/user_source_connection.py new file mode 100644 index 000000000..3b6b9b393 --- /dev/null +++ b/authentik_client/models/user_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserSourceConnection(BaseModel): + """ + User source connection + """ # noqa: E501 + pk: StrictInt + user: StrictInt + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "user", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "user": obj.get("user"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/user_source_connection_request.py b/authentik_client/models/user_source_connection_request.py new file mode 100644 index 000000000..416258639 --- /dev/null +++ b/authentik_client/models/user_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/user_telegram_source_connection.py b/authentik_client/models/user_telegram_source_connection.py new file mode 100644 index 000000000..e04b8a957 --- /dev/null +++ b/authentik_client/models/user_telegram_source_connection.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from authentik_client.models.source import Source +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserTelegramSourceConnection(BaseModel): + """ + User source connection + """ # noqa: E501 + pk: StrictInt + user: StrictInt + source: UUID + source_obj: Source + identifier: StrictStr + created: datetime + last_updated: datetime + __properties: ClassVar[List[str]] = ["pk", "user", "source", "source_obj", "identifier", "created", "last_updated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserTelegramSourceConnection from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "user", + "source_obj", + "created", + "last_updated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of source_obj + if self.source_obj: + _dict['source_obj'] = self.source_obj.to_dict() + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserTelegramSourceConnection from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "user": obj.get("user"), + "source": obj.get("source"), + "source_obj": Source.from_dict(obj["source_obj"]) if obj.get("source_obj") is not None else None, + "identifier": obj.get("identifier"), + "created": obj.get("created"), + "last_updated": obj.get("last_updated") + }) + return _obj + + diff --git a/authentik_client/models/user_telegram_source_connection_request.py b/authentik_client/models/user_telegram_source_connection_request.py new file mode 100644 index 000000000..2b204f43d --- /dev/null +++ b/authentik_client/models/user_telegram_source_connection_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserTelegramSourceConnectionRequest(BaseModel): + """ + User source connection + """ # noqa: E501 + source: UUID + identifier: Annotated[str, Field(min_length=1, strict=True)] + __properties: ClassVar[List[str]] = ["source", "identifier"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserTelegramSourceConnectionRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserTelegramSourceConnectionRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "source": obj.get("source"), + "identifier": obj.get("identifier") + }) + return _obj + + diff --git a/authentik_client/models/user_type_enum.py b/authentik_client/models/user_type_enum.py new file mode 100644 index 000000000..4a1f9eb1f --- /dev/null +++ b/authentik_client/models/user_type_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class UserTypeEnum(str, Enum): + """ + UserTypeEnum + """ + + """ + allowed enum values + """ + INTERNAL = 'internal' + EXTERNAL = 'external' + SERVICE_ACCOUNT = 'service_account' + INTERNAL_SERVICE_ACCOUNT = 'internal_service_account' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of UserTypeEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/user_verification_enum.py b/authentik_client/models/user_verification_enum.py new file mode 100644 index 000000000..94522be39 --- /dev/null +++ b/authentik_client/models/user_verification_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class UserVerificationEnum(str, Enum): + """ + UserVerificationEnum + """ + + """ + allowed enum values + """ + REQUIRED = 'required' + PREFERRED = 'preferred' + DISCOURAGED = 'discouraged' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of UserVerificationEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/user_write_stage.py b/authentik_client/models/user_write_stage.py new file mode 100644 index 000000000..d713d11f5 --- /dev/null +++ b/authentik_client/models/user_write_stage.py @@ -0,0 +1,139 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.flow_set import FlowSet +from authentik_client.models.user_creation_mode_enum import UserCreationModeEnum +from authentik_client.models.user_type_enum import UserTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserWriteStage(BaseModel): + """ + UserWriteStage Serializer + """ # noqa: E501 + pk: UUID + name: StrictStr + component: StrictStr = Field(description="Get object type so that we know how to edit the object") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + flow_set: List[FlowSet] + user_creation_mode: Optional[UserCreationModeEnum] = None + create_users_as_inactive: Optional[StrictBool] = Field(default=None, description="When set, newly created users are inactive and cannot login.") + create_users_group: Optional[UUID] = Field(default=None, description="Optionally add newly created users to this group.") + user_type: Optional[UserTypeEnum] = None + user_path_template: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["pk", "name", "component", "verbose_name", "verbose_name_plural", "meta_model_name", "flow_set", "user_creation_mode", "create_users_as_inactive", "create_users_group", "user_type", "user_path_template"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserWriteStage from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "flow_set", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in flow_set (list) + _items = [] + if self.flow_set: + for _item_flow_set in self.flow_set: + if _item_flow_set: + _items.append(_item_flow_set.to_dict()) + _dict['flow_set'] = _items + # set to None if create_users_group (nullable) is None + # and model_fields_set contains the field + if self.create_users_group is None and "create_users_group" in self.model_fields_set: + _dict['create_users_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserWriteStage from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "component": obj.get("component"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "flow_set": [FlowSet.from_dict(_item) for _item in obj["flow_set"]] if obj.get("flow_set") is not None else None, + "user_creation_mode": obj.get("user_creation_mode"), + "create_users_as_inactive": obj.get("create_users_as_inactive"), + "create_users_group": obj.get("create_users_group"), + "user_type": obj.get("user_type"), + "user_path_template": obj.get("user_path_template") + }) + return _obj + + diff --git a/authentik_client/models/user_write_stage_request.py b/authentik_client/models/user_write_stage_request.py new file mode 100644 index 000000000..5dc94974f --- /dev/null +++ b/authentik_client/models/user_write_stage_request.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.user_creation_mode_enum import UserCreationModeEnum +from authentik_client.models.user_type_enum import UserTypeEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class UserWriteStageRequest(BaseModel): + """ + UserWriteStage Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + user_creation_mode: Optional[UserCreationModeEnum] = None + create_users_as_inactive: Optional[StrictBool] = Field(default=None, description="When set, newly created users are inactive and cannot login.") + create_users_group: Optional[UUID] = Field(default=None, description="Optionally add newly created users to this group.") + user_type: Optional[UserTypeEnum] = None + user_path_template: Optional[StrictStr] = None + __properties: ClassVar[List[str]] = ["name", "user_creation_mode", "create_users_as_inactive", "create_users_group", "user_type", "user_path_template"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UserWriteStageRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if create_users_group (nullable) is None + # and model_fields_set contains the field + if self.create_users_group is None and "create_users_group" in self.model_fields_set: + _dict['create_users_group'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UserWriteStageRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "user_creation_mode": obj.get("user_creation_mode"), + "create_users_as_inactive": obj.get("create_users_as_inactive"), + "create_users_group": obj.get("create_users_group"), + "user_type": obj.get("user_type"), + "user_path_template": obj.get("user_path_template") + }) + return _obj + + diff --git a/authentik_client/models/validation_error.py b/authentik_client/models/validation_error.py new file mode 100644 index 000000000..c3fee3fd1 --- /dev/null +++ b/authentik_client/models/validation_error.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class ValidationError(BaseModel): + """ + Validation Error + """ # noqa: E501 + non_field_errors: Optional[List[StrictStr]] = None + code: Optional[StrictStr] = None + additional_properties: Dict[str, Any] = {} + __properties: ClassVar[List[str]] = ["non_field_errors", "code"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of ValidationError from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * Fields in `self.additional_properties` are added to the output dict. + """ + excluded_fields: Set[str] = set([ + "additional_properties", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # puts key-value pairs in additional_properties in the top level + if self.additional_properties is not None: + for _key, _value in self.additional_properties.items(): + _dict[_key] = _value + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of ValidationError from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "non_field_errors": obj.get("non_field_errors"), + "code": obj.get("code") + }) + # store additional fields in additional_properties + for _key in obj.keys(): + if _key not in cls.__properties: + _obj.additional_properties[_key] = obj.get(_key) + + return _obj + + diff --git a/authentik_client/models/vendor_enum.py b/authentik_client/models/vendor_enum.py new file mode 100644 index 000000000..87edaff27 --- /dev/null +++ b/authentik_client/models/vendor_enum.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class VendorEnum(str, Enum): + """ + VendorEnum + """ + + """ + allowed enum values + """ + GOAUTHENTIK_DOT_IO_SLASH_AT_MERGED = 'goauthentik.io/@merged' + GOAUTHENTIK_DOT_IO_SLASH_PLATFORM = 'goauthentik.io/platform' + FLEETDM_DOT_COM = 'fleetdm.com' + CHROME_DOT_GOOGLE_DOT_COM = 'chrome.google.com' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of VendorEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/version.py b/authentik_client/models/version.py new file mode 100644 index 000000000..6eb3f111f --- /dev/null +++ b/authentik_client/models/version.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Version(BaseModel): + """ + Get running and latest version. + """ # noqa: E501 + version_current: StrictStr = Field(description="Get current version") + version_latest: StrictStr = Field(description="Get latest version from cache") + version_latest_valid: StrictBool = Field(description="Check if latest version is valid") + build_hash: StrictStr = Field(description="Get build hash, if version is not latest or released") + outdated: StrictBool = Field(description="Check if we're running the latest version") + outpost_outdated: StrictBool = Field(description="Check if any outpost is outdated/has a version mismatch") + __properties: ClassVar[List[str]] = ["version_current", "version_latest", "version_latest_valid", "build_hash", "outdated", "outpost_outdated"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Version from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "version_current", + "version_latest", + "version_latest_valid", + "build_hash", + "outdated", + "outpost_outdated", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Version from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "version_current": obj.get("version_current"), + "version_latest": obj.get("version_latest"), + "version_latest_valid": obj.get("version_latest_valid"), + "build_hash": obj.get("build_hash"), + "outdated": obj.get("outdated"), + "outpost_outdated": obj.get("outpost_outdated") + }) + return _obj + + diff --git a/authentik_client/models/version_history.py b/authentik_client/models/version_history.py new file mode 100644 index 000000000..1653c9f21 --- /dev/null +++ b/authentik_client/models/version_history.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class VersionHistory(BaseModel): + """ + VersionHistory Serializer + """ # noqa: E501 + id: StrictInt + timestamp: datetime + version: StrictStr + build: StrictStr + __properties: ClassVar[List[str]] = ["id", "timestamp", "version", "build"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of VersionHistory from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "id", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of VersionHistory from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "timestamp": obj.get("timestamp"), + "version": obj.get("version"), + "build": obj.get("build") + }) + return _obj + + diff --git a/authentik_client/models/web_authn_device.py b/authentik_client/models/web_authn_device.py new file mode 100644 index 000000000..f92264bcf --- /dev/null +++ b/authentik_client/models/web_authn_device.py @@ -0,0 +1,124 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from datetime import datetime +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from authentik_client.models.partial_user import PartialUser +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class WebAuthnDevice(BaseModel): + """ + Serializer for WebAuthn authenticator devices + """ # noqa: E501 + pk: StrictInt + name: Annotated[str, Field(strict=True, max_length=200)] + created_on: datetime + device_type: Optional[WebAuthnDeviceType] + aaguid: StrictStr + user: PartialUser + __properties: ClassVar[List[str]] = ["pk", "name", "created_on", "device_type", "aaguid", "user"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of WebAuthnDevice from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "created_on", + "device_type", + "aaguid", + "user", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of device_type + if self.device_type: + _dict['device_type'] = self.device_type.to_dict() + # override the default output from pydantic by calling `to_dict()` of user + if self.user: + _dict['user'] = self.user.to_dict() + # set to None if device_type (nullable) is None + # and model_fields_set contains the field + if self.device_type is None and "device_type" in self.model_fields_set: + _dict['device_type'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of WebAuthnDevice from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "created_on": obj.get("created_on"), + "device_type": WebAuthnDeviceType.from_dict(obj["device_type"]) if obj.get("device_type") is not None else None, + "aaguid": obj.get("aaguid"), + "user": PartialUser.from_dict(obj["user"]) if obj.get("user") is not None else None + }) + return _obj + + diff --git a/authentik_client/models/web_authn_device_request.py b/authentik_client/models/web_authn_device_request.py new file mode 100644 index 000000000..60b7b0005 --- /dev/null +++ b/authentik_client/models/web_authn_device_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class WebAuthnDeviceRequest(BaseModel): + """ + Serializer for WebAuthn authenticator devices + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True, max_length=200)] + __properties: ClassVar[List[str]] = ["name"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of WebAuthnDeviceRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of WebAuthnDeviceRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name") + }) + return _obj + + diff --git a/authentik_client/models/web_authn_device_type.py b/authentik_client/models/web_authn_device_type.py new file mode 100644 index 000000000..2e80435b9 --- /dev/null +++ b/authentik_client/models/web_authn_device_type.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from uuid import UUID +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class WebAuthnDeviceType(BaseModel): + """ + WebAuthnDeviceType Serializer + """ # noqa: E501 + aaguid: UUID + description: StrictStr + __properties: ClassVar[List[str]] = ["aaguid", "description"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of WebAuthnDeviceType from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of WebAuthnDeviceType from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "aaguid": obj.get("aaguid"), + "description": obj.get("description") + }) + return _obj + + diff --git a/authentik_client/models/web_authn_hint_enum.py b/authentik_client/models/web_authn_hint_enum.py new file mode 100644 index 000000000..f7cd94776 --- /dev/null +++ b/authentik_client/models/web_authn_hint_enum.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class WebAuthnHintEnum(str, Enum): + """ + WebAuthnHintEnum + """ + + """ + allowed enum values + """ + SECURITY_MINUS_KEY = 'security-key' + CLIENT_MINUS_DEVICE = 'client-device' + HYBRID = 'hybrid' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of WebAuthnHintEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/authentik_client/models/worker.py b/authentik_client/models/worker.py new file mode 100644 index 000000000..8ac1b7e92 --- /dev/null +++ b/authentik_client/models/worker.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class Worker(BaseModel): + """ + Worker + """ # noqa: E501 + worker_id: StrictStr + version: StrictStr + version_matching: StrictBool + __properties: ClassVar[List[str]] = ["worker_id", "version", "version_matching"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of Worker from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of Worker from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "worker_id": obj.get("worker_id"), + "version": obj.get("version"), + "version_matching": obj.get("version_matching") + }) + return _obj + + diff --git a/authentik_client/models/ws_federation_provider.py b/authentik_client/models/ws_federation_provider.py new file mode 100644 index 000000000..8e812b2cd --- /dev/null +++ b/authentik_client/models/ws_federation_provider.py @@ -0,0 +1,218 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from uuid import UUID +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class WSFederationProvider(BaseModel): + """ + WSFederationProvider Serializer + """ # noqa: E501 + pk: StrictInt + name: StrictStr + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + component: StrictStr = Field(description="Get object component so that we know how to edit the object") + assigned_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + assigned_backchannel_application_slug: Optional[StrictStr] = Field(description="Internal application name, used in URLs.") + assigned_backchannel_application_name: Optional[StrictStr] = Field(description="Application's display Name.") + verbose_name: StrictStr = Field(description="Return object's verbose_name") + verbose_name_plural: StrictStr = Field(description="Return object's plural verbose_name") + meta_model_name: StrictStr = Field(description="Return internal model name") + reply_url: StrictStr + wtrealm: StrictStr + assertion_valid_not_before: Optional[StrictStr] = Field(default=None, description="Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3).") + assertion_valid_not_on_or_after: Optional[StrictStr] = Field(default=None, description="Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + session_valid_not_on_or_after: Optional[StrictStr] = Field(default=None, description="Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + name_id_mapping: Optional[UUID] = Field(default=None, description="Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered") + authn_context_class_ref_mapping: Optional[UUID] = Field(default=None, description="Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate.") + digest_algorithm: Optional[DigestAlgorithmEnum] = None + signature_algorithm: Optional[SignatureAlgorithmEnum] = None + signing_kp: Optional[UUID] = Field(default=None, description="Keypair used to sign outgoing Responses going to the Service Provider.") + encryption_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key.") + sign_assertion: Optional[StrictBool] = None + sign_logout_request: Optional[StrictBool] = None + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None + url_download_metadata: StrictStr = Field(description="Get metadata download URL") + url_wsfed: StrictStr = Field(description="Get WS-Fed url") + __properties: ClassVar[List[str]] = ["pk", "name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "component", "assigned_application_slug", "assigned_application_name", "assigned_backchannel_application_slug", "assigned_backchannel_application_name", "verbose_name", "verbose_name_plural", "meta_model_name", "reply_url", "wtrealm", "assertion_valid_not_before", "assertion_valid_not_on_or_after", "session_valid_not_on_or_after", "name_id_mapping", "authn_context_class_ref_mapping", "digest_algorithm", "signature_algorithm", "signing_kp", "encryption_kp", "sign_assertion", "sign_logout_request", "default_name_id_policy", "url_download_metadata", "url_wsfed"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of WSFederationProvider from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. + """ + excluded_fields: Set[str] = set([ + "pk", + "component", + "assigned_application_slug", + "assigned_application_name", + "assigned_backchannel_application_slug", + "assigned_backchannel_application_name", + "verbose_name", + "verbose_name_plural", + "meta_model_name", + "url_download_metadata", + "url_wsfed", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if assigned_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_slug is None and "assigned_application_slug" in self.model_fields_set: + _dict['assigned_application_slug'] = None + + # set to None if assigned_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_application_name is None and "assigned_application_name" in self.model_fields_set: + _dict['assigned_application_name'] = None + + # set to None if assigned_backchannel_application_slug (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_slug is None and "assigned_backchannel_application_slug" in self.model_fields_set: + _dict['assigned_backchannel_application_slug'] = None + + # set to None if assigned_backchannel_application_name (nullable) is None + # and model_fields_set contains the field + if self.assigned_backchannel_application_name is None and "assigned_backchannel_application_name" in self.model_fields_set: + _dict['assigned_backchannel_application_name'] = None + + # set to None if name_id_mapping (nullable) is None + # and model_fields_set contains the field + if self.name_id_mapping is None and "name_id_mapping" in self.model_fields_set: + _dict['name_id_mapping'] = None + + # set to None if authn_context_class_ref_mapping (nullable) is None + # and model_fields_set contains the field + if self.authn_context_class_ref_mapping is None and "authn_context_class_ref_mapping" in self.model_fields_set: + _dict['authn_context_class_ref_mapping'] = None + + # set to None if signing_kp (nullable) is None + # and model_fields_set contains the field + if self.signing_kp is None and "signing_kp" in self.model_fields_set: + _dict['signing_kp'] = None + + # set to None if encryption_kp (nullable) is None + # and model_fields_set contains the field + if self.encryption_kp is None and "encryption_kp" in self.model_fields_set: + _dict['encryption_kp'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of WSFederationProvider from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pk": obj.get("pk"), + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "component": obj.get("component"), + "assigned_application_slug": obj.get("assigned_application_slug"), + "assigned_application_name": obj.get("assigned_application_name"), + "assigned_backchannel_application_slug": obj.get("assigned_backchannel_application_slug"), + "assigned_backchannel_application_name": obj.get("assigned_backchannel_application_name"), + "verbose_name": obj.get("verbose_name"), + "verbose_name_plural": obj.get("verbose_name_plural"), + "meta_model_name": obj.get("meta_model_name"), + "reply_url": obj.get("reply_url"), + "wtrealm": obj.get("wtrealm"), + "assertion_valid_not_before": obj.get("assertion_valid_not_before"), + "assertion_valid_not_on_or_after": obj.get("assertion_valid_not_on_or_after"), + "session_valid_not_on_or_after": obj.get("session_valid_not_on_or_after"), + "name_id_mapping": obj.get("name_id_mapping"), + "authn_context_class_ref_mapping": obj.get("authn_context_class_ref_mapping"), + "digest_algorithm": obj.get("digest_algorithm"), + "signature_algorithm": obj.get("signature_algorithm"), + "signing_kp": obj.get("signing_kp"), + "encryption_kp": obj.get("encryption_kp"), + "sign_assertion": obj.get("sign_assertion"), + "sign_logout_request": obj.get("sign_logout_request"), + "default_name_id_policy": obj.get("default_name_id_policy"), + "url_download_metadata": obj.get("url_download_metadata"), + "url_wsfed": obj.get("url_wsfed") + }) + return _obj + + diff --git a/authentik_client/models/ws_federation_provider_request.py b/authentik_client/models/ws_federation_provider_request.py new file mode 100644 index 000000000..016785392 --- /dev/null +++ b/authentik_client/models/ws_federation_provider_request.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictBool +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from uuid import UUID +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from typing import Optional, Set +from typing_extensions import Self +from pydantic_core import to_jsonable_python + +class WSFederationProviderRequest(BaseModel): + """ + WSFederationProvider Serializer + """ # noqa: E501 + name: Annotated[str, Field(min_length=1, strict=True)] + authentication_flow: Optional[UUID] = Field(default=None, description="Flow used for authentication when the associated application is accessed by an un-authenticated user.") + authorization_flow: UUID = Field(description="Flow used when authorizing this provider.") + invalidation_flow: UUID = Field(description="Flow used ending the session from a provider.") + property_mappings: Optional[List[UUID]] = None + reply_url: Annotated[str, Field(min_length=1, strict=True)] + wtrealm: Annotated[str, Field(min_length=1, strict=True)] + assertion_valid_not_before: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3).") + assertion_valid_not_on_or_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + session_valid_not_on_or_after: Optional[Annotated[str, Field(min_length=1, strict=True)]] = Field(default=None, description="Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3).") + name_id_mapping: Optional[UUID] = Field(default=None, description="Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered") + authn_context_class_ref_mapping: Optional[UUID] = Field(default=None, description="Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate.") + digest_algorithm: Optional[DigestAlgorithmEnum] = None + signature_algorithm: Optional[SignatureAlgorithmEnum] = None + signing_kp: Optional[UUID] = Field(default=None, description="Keypair used to sign outgoing Responses going to the Service Provider.") + encryption_kp: Optional[UUID] = Field(default=None, description="When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key.") + sign_assertion: Optional[StrictBool] = None + sign_logout_request: Optional[StrictBool] = None + default_name_id_policy: Optional[SAMLNameIDPolicyEnum] = None + __properties: ClassVar[List[str]] = ["name", "authentication_flow", "authorization_flow", "invalidation_flow", "property_mappings", "reply_url", "wtrealm", "assertion_valid_not_before", "assertion_valid_not_on_or_after", "session_valid_not_on_or_after", "name_id_mapping", "authn_context_class_ref_mapping", "digest_algorithm", "signature_algorithm", "signing_kp", "encryption_kp", "sign_assertion", "sign_logout_request", "default_name_id_policy"] + + model_config = ConfigDict( + validate_by_name=True, + validate_by_alias=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + return json.dumps(to_jsonable_python(self.to_dict())) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of WSFederationProviderRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if authentication_flow (nullable) is None + # and model_fields_set contains the field + if self.authentication_flow is None and "authentication_flow" in self.model_fields_set: + _dict['authentication_flow'] = None + + # set to None if name_id_mapping (nullable) is None + # and model_fields_set contains the field + if self.name_id_mapping is None and "name_id_mapping" in self.model_fields_set: + _dict['name_id_mapping'] = None + + # set to None if authn_context_class_ref_mapping (nullable) is None + # and model_fields_set contains the field + if self.authn_context_class_ref_mapping is None and "authn_context_class_ref_mapping" in self.model_fields_set: + _dict['authn_context_class_ref_mapping'] = None + + # set to None if signing_kp (nullable) is None + # and model_fields_set contains the field + if self.signing_kp is None and "signing_kp" in self.model_fields_set: + _dict['signing_kp'] = None + + # set to None if encryption_kp (nullable) is None + # and model_fields_set contains the field + if self.encryption_kp is None and "encryption_kp" in self.model_fields_set: + _dict['encryption_kp'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of WSFederationProviderRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "name": obj.get("name"), + "authentication_flow": obj.get("authentication_flow"), + "authorization_flow": obj.get("authorization_flow"), + "invalidation_flow": obj.get("invalidation_flow"), + "property_mappings": obj.get("property_mappings"), + "reply_url": obj.get("reply_url"), + "wtrealm": obj.get("wtrealm"), + "assertion_valid_not_before": obj.get("assertion_valid_not_before"), + "assertion_valid_not_on_or_after": obj.get("assertion_valid_not_on_or_after"), + "session_valid_not_on_or_after": obj.get("session_valid_not_on_or_after"), + "name_id_mapping": obj.get("name_id_mapping"), + "authn_context_class_ref_mapping": obj.get("authn_context_class_ref_mapping"), + "digest_algorithm": obj.get("digest_algorithm"), + "signature_algorithm": obj.get("signature_algorithm"), + "signing_kp": obj.get("signing_kp"), + "encryption_kp": obj.get("encryption_kp"), + "sign_assertion": obj.get("sign_assertion"), + "sign_logout_request": obj.get("sign_logout_request"), + "default_name_id_policy": obj.get("default_name_id_policy") + }) + return _obj + + diff --git a/authentik_client/py.typed b/authentik_client/py.typed new file mode 100644 index 000000000..e69de29bb diff --git a/authentik_client/rest.py b/authentik_client/rest.py new file mode 100644 index 000000000..162fcab41 --- /dev/null +++ b/authentik_client/rest.py @@ -0,0 +1,264 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import io +import json +import re +import ssl + +import urllib3 + +from authentik_client.exceptions import ApiException, ApiValueError + +SUPPORTED_SOCKS_PROXIES = {"socks5", "socks5h", "socks4", "socks4a"} +RESTResponseType = urllib3.HTTPResponse + + +def is_socks_proxy_url(url): + if url is None: + return False + split_section = url.split("://") + if len(split_section) < 2: + return False + else: + return split_section[0].lower() in SUPPORTED_SOCKS_PROXIES + + +class RESTResponse(io.IOBase): + + def __init__(self, resp) -> None: + self.response = resp + self.status = resp.status + self.reason = resp.reason + self.data = None + + def read(self): + if self.data is None: + self.data = self.response.data + return self.data + + @property + def headers(self): + """Returns a dictionary of response headers.""" + return self.response.headers + + def getheaders(self): + """Returns a dictionary of the response headers; use ``headers`` instead.""" + return self.response.headers + + def getheader(self, name, default=None): + """Returns a given response header; use ``headers.get()`` instead.""" + return self.response.headers.get(name, default) + + +class RESTClientObject: + + def __init__(self, configuration) -> None: + # urllib3.PoolManager will pass all kw parameters to connectionpool + # https://github.com/shazow/urllib3/blob/f9409436f83aeb79fbaf090181cd81b784f1b8ce/urllib3/poolmanager.py#L75 # noqa: E501 + # https://github.com/shazow/urllib3/blob/f9409436f83aeb79fbaf090181cd81b784f1b8ce/urllib3/connectionpool.py#L680 # noqa: E501 + # Custom SSL certificates and client certificates: http://urllib3.readthedocs.io/en/latest/advanced-usage.html # noqa: E501 + + # cert_reqs + if configuration.verify_ssl: + cert_reqs = ssl.CERT_REQUIRED + else: + cert_reqs = ssl.CERT_NONE + + pool_args = { + "cert_reqs": cert_reqs, + "ca_certs": configuration.ssl_ca_cert, + "cert_file": configuration.cert_file, + "key_file": configuration.key_file, + "ca_cert_data": configuration.ca_cert_data, + } + if configuration.assert_hostname is not None: + pool_args['assert_hostname'] = ( + configuration.assert_hostname + ) + + if configuration.retries is not None: + pool_args['retries'] = configuration.retries + + if configuration.tls_server_name: + pool_args['server_hostname'] = configuration.tls_server_name + + + if configuration.socket_options is not None: + pool_args['socket_options'] = configuration.socket_options + + if configuration.connection_pool_maxsize is not None: + pool_args['maxsize'] = configuration.connection_pool_maxsize + + # https pool manager + self.pool_manager: urllib3.PoolManager + + if configuration.proxy: + if is_socks_proxy_url(configuration.proxy): + from urllib3.contrib.socks import SOCKSProxyManager + pool_args["proxy_url"] = configuration.proxy + pool_args["headers"] = configuration.proxy_headers + self.pool_manager = SOCKSProxyManager(**pool_args) + else: + pool_args["proxy_url"] = configuration.proxy + pool_args["proxy_headers"] = configuration.proxy_headers + self.pool_manager = urllib3.ProxyManager(**pool_args) + else: + self.pool_manager = urllib3.PoolManager(**pool_args) + + def request( + self, + method, + url, + headers=None, + body=None, + post_params=None, + _request_timeout=None + ): + """Perform requests. + + :param method: http request method + :param url: http request url + :param headers: http request headers + :param body: request json body, for `application/json` + :param post_params: request post parameters, + `application/x-www-form-urlencoded` + and `multipart/form-data` + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + """ + method = method.upper() + assert method in [ + 'GET', + 'HEAD', + 'DELETE', + 'POST', + 'PUT', + 'PATCH', + 'OPTIONS' + ] + + if post_params and body: + raise ApiValueError( + "body parameter cannot be used with post_params parameter." + ) + + post_params = post_params or {} + headers = headers or {} + + timeout = None + if _request_timeout: + if isinstance(_request_timeout, (int, float)): + timeout = urllib3.Timeout(total=_request_timeout) + elif ( + isinstance(_request_timeout, tuple) + and len(_request_timeout) == 2 + ): + timeout = urllib3.Timeout( + connect=_request_timeout[0], + read=_request_timeout[1] + ) + + try: + # For `POST`, `PUT`, `PATCH`, `OPTIONS`, `DELETE` + if method in ['POST', 'PUT', 'PATCH', 'OPTIONS', 'DELETE']: + + # no content type provided or payload is json + content_type = headers.get('Content-Type') + if ( + not content_type + or re.search('json', content_type, re.IGNORECASE) + ): + request_body = None + if body is not None: + request_body = json.dumps(body) + r = self.pool_manager.request( + method, + url, + body=request_body, + timeout=timeout, + headers=headers, + preload_content=False + ) + elif content_type == 'application/x-www-form-urlencoded': + r = self.pool_manager.request( + method, + url, + fields=post_params, + encode_multipart=False, + timeout=timeout, + headers=headers, + preload_content=False + ) + elif content_type == 'multipart/form-data': + # must del headers['Content-Type'], or the correct + # Content-Type which generated by urllib3 will be + # overwritten. + del headers['Content-Type'] + # Ensures that dict objects are serialized + post_params = [(a, json.dumps(b)) if isinstance(b, dict) else (a,b) for a, b in post_params] + r = self.pool_manager.request( + method, + url, + fields=post_params, + encode_multipart=True, + timeout=timeout, + headers=headers, + preload_content=False + ) + # Pass a `string` parameter directly in the body to support + # other content types than JSON when `body` argument is + # provided in serialized form. + elif isinstance(body, str) or isinstance(body, bytes): + r = self.pool_manager.request( + method, + url, + body=body, + timeout=timeout, + headers=headers, + preload_content=False + ) + elif headers['Content-Type'].startswith('text/') and isinstance(body, bool): + request_body = "true" if body else "false" + r = self.pool_manager.request( + method, + url, + body=request_body, + preload_content=False, + timeout=timeout, + headers=headers) + else: + # Cannot generate the request from given parameters + msg = """Cannot prepare a request message for provided + arguments. Please check that your arguments match + declared content type.""" + raise ApiException(status=0, reason=msg) + # For `GET`, `HEAD` + else: + r = self.pool_manager.request( + method, + url, + fields={}, + timeout=timeout, + headers=headers, + preload_content=False + ) + except urllib3.exceptions.SSLError as e: + msg = "\n".join([type(e).__name__, str(e)]) + raise ApiException(status=0, reason=msg) + + return RESTResponse(r) diff --git a/docs/AccessDeniedChallenge.md b/docs/AccessDeniedChallenge.md new file mode 100644 index 000000000..c12ab07f4 --- /dev/null +++ b/docs/AccessDeniedChallenge.md @@ -0,0 +1,35 @@ +# AccessDeniedChallenge + +Challenge when a flow's active stage calls `stage_invalid()`. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-access-denied'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**error_message** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.access_denied_challenge import AccessDeniedChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AccessDeniedChallenge from a JSON string +access_denied_challenge_instance = AccessDeniedChallenge.from_json(json) +# print the JSON string representation of the object +print(AccessDeniedChallenge.to_json()) + +# convert the object into a dict +access_denied_challenge_dict = access_denied_challenge_instance.to_dict() +# create an instance of AccessDeniedChallenge from a dict +access_denied_challenge_from_dict = AccessDeniedChallenge.from_dict(access_denied_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AccountLockdownStage.md b/docs/AccountLockdownStage.md new file mode 100644 index 000000000..ec0e8a65d --- /dev/null +++ b/docs/AccountLockdownStage.md @@ -0,0 +1,41 @@ +# AccountLockdownStage + +AccountLockdownStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**deactivate_user** | **bool** | Deactivate the user account (set is_active to False) | [optional] +**set_unusable_password** | **bool** | Set an unusable password for the user | [optional] +**delete_sessions** | **bool** | Delete all active sessions for the user | [optional] +**revoke_tokens** | **bool** | Revoke all tokens for the user (API, app password, recovery, verification, OAuth) | [optional] +**self_service_completion_flow** | **UUID** | Flow to redirect users to after self-service lockdown. This flow should not require authentication since the user's session is deleted. | [optional] + +## Example + +```python +from authentik_client.models.account_lockdown_stage import AccountLockdownStage + +# TODO update the JSON string below +json = "{}" +# create an instance of AccountLockdownStage from a JSON string +account_lockdown_stage_instance = AccountLockdownStage.from_json(json) +# print the JSON string representation of the object +print(AccountLockdownStage.to_json()) + +# convert the object into a dict +account_lockdown_stage_dict = account_lockdown_stage_instance.to_dict() +# create an instance of AccountLockdownStage from a dict +account_lockdown_stage_from_dict = AccountLockdownStage.from_dict(account_lockdown_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AccountLockdownStageRequest.md b/docs/AccountLockdownStageRequest.md new file mode 100644 index 000000000..56a258f2b --- /dev/null +++ b/docs/AccountLockdownStageRequest.md @@ -0,0 +1,35 @@ +# AccountLockdownStageRequest + +AccountLockdownStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**deactivate_user** | **bool** | Deactivate the user account (set is_active to False) | [optional] +**set_unusable_password** | **bool** | Set an unusable password for the user | [optional] +**delete_sessions** | **bool** | Delete all active sessions for the user | [optional] +**revoke_tokens** | **bool** | Revoke all tokens for the user (API, app password, recovery, verification, OAuth) | [optional] +**self_service_completion_flow** | **UUID** | Flow to redirect users to after self-service lockdown. This flow should not require authentication since the user's session is deleted. | [optional] + +## Example + +```python +from authentik_client.models.account_lockdown_stage_request import AccountLockdownStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AccountLockdownStageRequest from a JSON string +account_lockdown_stage_request_instance = AccountLockdownStageRequest.from_json(json) +# print the JSON string representation of the object +print(AccountLockdownStageRequest.to_json()) + +# convert the object into a dict +account_lockdown_stage_request_dict = account_lockdown_stage_request_instance.to_dict() +# create an instance of AccountLockdownStageRequest from a dict +account_lockdown_stage_request_from_dict = AccountLockdownStageRequest.from_dict(account_lockdown_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AdminApi.md b/docs/AdminApi.md new file mode 100644 index 000000000..748c55081 --- /dev/null +++ b/docs/AdminApi.md @@ -0,0 +1,1086 @@ +# authentik_client.AdminApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**admin_apps_list**](AdminApi.md#admin_apps_list) | **GET** /admin/apps/ | +[**admin_file_create**](AdminApi.md#admin_file_create) | **POST** /admin/file/ | +[**admin_file_destroy**](AdminApi.md#admin_file_destroy) | **DELETE** /admin/file/ | +[**admin_file_list**](AdminApi.md#admin_file_list) | **GET** /admin/file/ | +[**admin_file_used_by_list**](AdminApi.md#admin_file_used_by_list) | **GET** /admin/file/used_by/ | +[**admin_models_list**](AdminApi.md#admin_models_list) | **GET** /admin/models/ | +[**admin_settings_partial_update**](AdminApi.md#admin_settings_partial_update) | **PATCH** /admin/settings/ | +[**admin_settings_retrieve**](AdminApi.md#admin_settings_retrieve) | **GET** /admin/settings/ | +[**admin_settings_update**](AdminApi.md#admin_settings_update) | **PUT** /admin/settings/ | +[**admin_system_create**](AdminApi.md#admin_system_create) | **POST** /admin/system/ | +[**admin_system_retrieve**](AdminApi.md#admin_system_retrieve) | **GET** /admin/system/ | +[**admin_version_history_list**](AdminApi.md#admin_version_history_list) | **GET** /admin/version/history/ | +[**admin_version_history_retrieve**](AdminApi.md#admin_version_history_retrieve) | **GET** /admin/version/history/{id}/ | +[**admin_version_retrieve**](AdminApi.md#admin_version_retrieve) | **GET** /admin/version/ | + + +# **admin_apps_list** +> List[App] admin_apps_list() + +Read-only view list all installed apps + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.app import App +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + + try: + api_response = api_instance.admin_apps_list() + print("The response of AdminApi->admin_apps_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_apps_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[App]**](App.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_file_create** +> admin_file_create(file, name=name, usage=usage) + +Upload file to storage backend. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + file = None # bytes | + name = 'name_example' # str | (optional) + usage = 'media' # str | (optional) (default to 'media') + + try: + api_instance.admin_file_create(file, name=name, usage=usage) + except Exception as e: + print("Exception when calling AdminApi->admin_file_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **file** | **bytes**| | + **name** | **str**| | [optional] + **usage** | **str**| | [optional] [default to 'media'] + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: multipart/form-data + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_file_destroy** +> admin_file_destroy(name=name, usage=usage) + +Delete file from storage backend. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + name = 'name_example' # str | (optional) + usage = authentik_client.UsageEnum() # UsageEnum | (optional) + + try: + api_instance.admin_file_destroy(name=name, usage=usage) + except Exception as e: + print("Exception when calling AdminApi->admin_file_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **usage** | [**UsageEnum**](.md)| | [optional] + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_file_list** +> List[FileList] admin_file_list(manageable_only=manageable_only, search=search, usage=usage) + +List files from storage backend. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.file_list import FileList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + manageable_only = False # bool | (optional) (default to False) + search = 'search_example' # str | A search term. (optional) + usage = authentik_client.UsageEnum() # UsageEnum | (optional) + + try: + api_response = api_instance.admin_file_list(manageable_only=manageable_only, search=search, usage=usage) + print("The response of AdminApi->admin_file_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_file_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **manageable_only** | **bool**| | [optional] [default to False] + **search** | **str**| A search term. | [optional] + **usage** | [**UsageEnum**](.md)| | [optional] + +### Return type + +[**List[FileList]**](FileList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_file_used_by_list** +> List[UsedBy] admin_file_used_by_list(name=name) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + name = 'name_example' # str | (optional) + + try: + api_response = api_instance.admin_file_used_by_list(name=name) + print("The response of AdminApi->admin_file_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_file_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_models_list** +> List[App] admin_models_list() + +Read-only view list all installed models + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.app import App +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + + try: + api_response = api_instance.admin_models_list() + print("The response of AdminApi->admin_models_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_models_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[App]**](App.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_settings_partial_update** +> Settings admin_settings_partial_update(patched_settings_request=patched_settings_request) + +Settings view + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_settings_request import PatchedSettingsRequest +from authentik_client.models.settings import Settings +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + patched_settings_request = authentik_client.PatchedSettingsRequest() # PatchedSettingsRequest | (optional) + + try: + api_response = api_instance.admin_settings_partial_update(patched_settings_request=patched_settings_request) + print("The response of AdminApi->admin_settings_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_settings_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **patched_settings_request** | [**PatchedSettingsRequest**](PatchedSettingsRequest.md)| | [optional] + +### Return type + +[**Settings**](Settings.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_settings_retrieve** +> Settings admin_settings_retrieve() + +Settings view + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.settings import Settings +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + + try: + api_response = api_instance.admin_settings_retrieve() + print("The response of AdminApi->admin_settings_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_settings_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**Settings**](Settings.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_settings_update** +> Settings admin_settings_update(settings_request) + +Settings view + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.settings import Settings +from authentik_client.models.settings_request import SettingsRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + settings_request = authentik_client.SettingsRequest() # SettingsRequest | + + try: + api_response = api_instance.admin_settings_update(settings_request) + print("The response of AdminApi->admin_settings_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_settings_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **settings_request** | [**SettingsRequest**](SettingsRequest.md)| | + +### Return type + +[**Settings**](Settings.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_system_create** +> SystemInfo admin_system_create() + +Get system information. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.system_info import SystemInfo +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + + try: + api_response = api_instance.admin_system_create() + print("The response of AdminApi->admin_system_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_system_create: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**SystemInfo**](SystemInfo.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_system_retrieve** +> SystemInfo admin_system_retrieve() + +Get system information. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.system_info import SystemInfo +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + + try: + api_response = api_instance.admin_system_retrieve() + print("The response of AdminApi->admin_system_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_system_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**SystemInfo**](SystemInfo.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_version_history_list** +> List[VersionHistory] admin_version_history_list(build=build, ordering=ordering, search=search, version=version) + +VersionHistory Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.version_history import VersionHistory +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + build = 'build_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + search = 'search_example' # str | A search term. (optional) + version = 'version_example' # str | (optional) + + try: + api_response = api_instance.admin_version_history_list(build=build, ordering=ordering, search=search, version=version) + print("The response of AdminApi->admin_version_history_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_version_history_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **build** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **search** | **str**| A search term. | [optional] + **version** | **str**| | [optional] + +### Return type + +[**List[VersionHistory]**](VersionHistory.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_version_history_retrieve** +> VersionHistory admin_version_history_retrieve(id) + +VersionHistory Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.version_history import VersionHistory +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + id = 56 # int | A unique integer value identifying this Version history. + + try: + api_response = api_instance.admin_version_history_retrieve(id) + print("The response of AdminApi->admin_version_history_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_version_history_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Version history. | + +### Return type + +[**VersionHistory**](VersionHistory.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **admin_version_retrieve** +> Version admin_version_retrieve() + +Get running and latest version. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.version import Version +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AdminApi(api_client) + + try: + api_response = api_instance.admin_version_retrieve() + print("The response of AdminApi->admin_version_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AdminApi->admin_version_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**Version**](Version.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/AgentAuthenticationResponse.md b/docs/AgentAuthenticationResponse.md new file mode 100644 index 000000000..9492a3165 --- /dev/null +++ b/docs/AgentAuthenticationResponse.md @@ -0,0 +1,30 @@ +# AgentAuthenticationResponse + +Base serializer class which doesn't implement create/update methods + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**url** | **str** | | + +## Example + +```python +from authentik_client.models.agent_authentication_response import AgentAuthenticationResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of AgentAuthenticationResponse from a JSON string +agent_authentication_response_instance = AgentAuthenticationResponse.from_json(json) +# print the JSON string representation of the object +print(AgentAuthenticationResponse.to_json()) + +# convert the object into a dict +agent_authentication_response_dict = agent_authentication_response_instance.to_dict() +# create an instance of AgentAuthenticationResponse from a dict +agent_authentication_response_from_dict = AgentAuthenticationResponse.from_dict(agent_authentication_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AgentConfig.md b/docs/AgentConfig.md new file mode 100644 index 000000000..6a76d975a --- /dev/null +++ b/docs/AgentConfig.md @@ -0,0 +1,39 @@ +# AgentConfig + +Base serializer class which doesn't implement create/update methods + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_id** | **str** | | [readonly] +**refresh_interval** | **int** | | [readonly] +**authorization_flow** | **str** | | [readonly] +**jwks_auth** | **Dict[str, object]** | | [readonly] +**jwks_challenge** | **Dict[str, object]** | | [readonly] +**nss_uid_offset** | **int** | | +**nss_gid_offset** | **int** | | +**auth_terminate_session_on_expiry** | **bool** | | +**system_config** | [**Config**](Config.md) | | [readonly] +**license_status** | [**LicenseStatusEnum**](LicenseStatusEnum.md) | | [readonly] + +## Example + +```python +from authentik_client.models.agent_config import AgentConfig + +# TODO update the JSON string below +json = "{}" +# create an instance of AgentConfig from a JSON string +agent_config_instance = AgentConfig.from_json(json) +# print the JSON string representation of the object +print(AgentConfig.to_json()) + +# convert the object into a dict +agent_config_dict = agent_config_instance.to_dict() +# create an instance of AgentConfig from a dict +agent_config_from_dict = AgentConfig.from_dict(agent_config_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AgentConnector.md b/docs/AgentConnector.md new file mode 100644 index 000000000..4f392e710 --- /dev/null +++ b/docs/AgentConnector.md @@ -0,0 +1,46 @@ +# AgentConnector + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | +**enabled** | **bool** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**snapshot_expiry** | **str** | | [optional] +**auth_session_duration** | **str** | | [optional] +**auth_terminate_session_on_expiry** | **bool** | | [optional] +**refresh_interval** | **str** | | [optional] +**authorization_flow** | **UUID** | | [optional] +**nss_uid_offset** | **int** | | [optional] +**nss_gid_offset** | **int** | | [optional] +**challenge_key** | **UUID** | | [optional] +**challenge_idle_timeout** | **str** | | [optional] +**challenge_trigger_check_in** | **bool** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] + +## Example + +```python +from authentik_client.models.agent_connector import AgentConnector + +# TODO update the JSON string below +json = "{}" +# create an instance of AgentConnector from a JSON string +agent_connector_instance = AgentConnector.from_json(json) +# print the JSON string representation of the object +print(AgentConnector.to_json()) + +# convert the object into a dict +agent_connector_dict = agent_connector_instance.to_dict() +# create an instance of AgentConnector from a dict +agent_connector_from_dict = AgentConnector.from_dict(agent_connector_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AgentConnectorRequest.md b/docs/AgentConnectorRequest.md new file mode 100644 index 000000000..8c6ecfb08 --- /dev/null +++ b/docs/AgentConnectorRequest.md @@ -0,0 +1,42 @@ +# AgentConnectorRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | +**enabled** | **bool** | | [optional] +**snapshot_expiry** | **str** | | [optional] +**auth_session_duration** | **str** | | [optional] +**auth_terminate_session_on_expiry** | **bool** | | [optional] +**refresh_interval** | **str** | | [optional] +**authorization_flow** | **UUID** | | [optional] +**nss_uid_offset** | **int** | | [optional] +**nss_gid_offset** | **int** | | [optional] +**challenge_key** | **UUID** | | [optional] +**challenge_idle_timeout** | **str** | | [optional] +**challenge_trigger_check_in** | **bool** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] + +## Example + +```python +from authentik_client.models.agent_connector_request import AgentConnectorRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AgentConnectorRequest from a JSON string +agent_connector_request_instance = AgentConnectorRequest.from_json(json) +# print the JSON string representation of the object +print(AgentConnectorRequest.to_json()) + +# convert the object into a dict +agent_connector_request_dict = agent_connector_request_instance.to_dict() +# create an instance of AgentConnectorRequest from a dict +agent_connector_request_from_dict = AgentConnectorRequest.from_dict(agent_connector_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AgentPSSODeviceRegistrationRequest.md b/docs/AgentPSSODeviceRegistrationRequest.md new file mode 100644 index 000000000..c70b49c2b --- /dev/null +++ b/docs/AgentPSSODeviceRegistrationRequest.md @@ -0,0 +1,33 @@ +# AgentPSSODeviceRegistrationRequest + +Register Apple device via Platform SSO + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_signing_key** | **str** | | +**device_encryption_key** | **str** | | +**sign_key_id** | **str** | | +**enc_key_id** | **str** | | + +## Example + +```python +from authentik_client.models.agent_psso_device_registration_request import AgentPSSODeviceRegistrationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AgentPSSODeviceRegistrationRequest from a JSON string +agent_psso_device_registration_request_instance = AgentPSSODeviceRegistrationRequest.from_json(json) +# print the JSON string representation of the object +print(AgentPSSODeviceRegistrationRequest.to_json()) + +# convert the object into a dict +agent_psso_device_registration_request_dict = agent_psso_device_registration_request_instance.to_dict() +# create an instance of AgentPSSODeviceRegistrationRequest from a dict +agent_psso_device_registration_request_from_dict = AgentPSSODeviceRegistrationRequest.from_dict(agent_psso_device_registration_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AgentPSSODeviceRegistrationResponse.md b/docs/AgentPSSODeviceRegistrationResponse.md new file mode 100644 index 000000000..65fbb2707 --- /dev/null +++ b/docs/AgentPSSODeviceRegistrationResponse.md @@ -0,0 +1,35 @@ +# AgentPSSODeviceRegistrationResponse + +authentik settings for Platform SSO tokens + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**client_id** | **str** | | +**issuer** | **str** | | +**token_endpoint** | **str** | | +**jwks_endpoint** | **str** | | +**audience** | **str** | | +**nonce_endpoint** | **str** | | + +## Example + +```python +from authentik_client.models.agent_psso_device_registration_response import AgentPSSODeviceRegistrationResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of AgentPSSODeviceRegistrationResponse from a JSON string +agent_psso_device_registration_response_instance = AgentPSSODeviceRegistrationResponse.from_json(json) +# print the JSON string representation of the object +print(AgentPSSODeviceRegistrationResponse.to_json()) + +# convert the object into a dict +agent_psso_device_registration_response_dict = agent_psso_device_registration_response_instance.to_dict() +# create an instance of AgentPSSODeviceRegistrationResponse from a dict +agent_psso_device_registration_response_from_dict = AgentPSSODeviceRegistrationResponse.from_dict(agent_psso_device_registration_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AgentPSSOUserRegistrationRequest.md b/docs/AgentPSSOUserRegistrationRequest.md new file mode 100644 index 000000000..d2cc0d408 --- /dev/null +++ b/docs/AgentPSSOUserRegistrationRequest.md @@ -0,0 +1,32 @@ +# AgentPSSOUserRegistrationRequest + +Register Apple device user via Platform SSO + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user_auth** | **str** | | +**user_secure_enclave_key** | **str** | | +**enclave_key_id** | **str** | | + +## Example + +```python +from authentik_client.models.agent_psso_user_registration_request import AgentPSSOUserRegistrationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AgentPSSOUserRegistrationRequest from a JSON string +agent_psso_user_registration_request_instance = AgentPSSOUserRegistrationRequest.from_json(json) +# print the JSON string representation of the object +print(AgentPSSOUserRegistrationRequest.to_json()) + +# convert the object into a dict +agent_psso_user_registration_request_dict = agent_psso_user_registration_request_instance.to_dict() +# create an instance of AgentPSSOUserRegistrationRequest from a dict +agent_psso_user_registration_request_from_dict = AgentPSSOUserRegistrationRequest.from_dict(agent_psso_user_registration_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AgentTokenResponse.md b/docs/AgentTokenResponse.md new file mode 100644 index 000000000..f4c6555f9 --- /dev/null +++ b/docs/AgentTokenResponse.md @@ -0,0 +1,31 @@ +# AgentTokenResponse + +Base serializer class which doesn't implement create/update methods + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**token** | **str** | | +**expires_in** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.agent_token_response import AgentTokenResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of AgentTokenResponse from a JSON string +agent_token_response_instance = AgentTokenResponse.from_json(json) +# print the JSON string representation of the object +print(AgentTokenResponse.to_json()) + +# convert the object into a dict +agent_token_response_dict = agent_token_response_instance.to_dict() +# create an instance of AgentTokenResponse from a dict +agent_token_response_from_dict = AgentTokenResponse.from_dict(agent_token_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AlgEnum.md b/docs/AlgEnum.md new file mode 100644 index 000000000..909e99df1 --- /dev/null +++ b/docs/AlgEnum.md @@ -0,0 +1,16 @@ +# AlgEnum + + +## Enum + +* `RSA` (value: `'rsa'`) + +* `ECDSA` (value: `'ecdsa'`) + +* `ED25519` (value: `'ed25519'`) + +* `ED448` (value: `'ed448'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/App.md b/docs/App.md new file mode 100644 index 000000000..999550716 --- /dev/null +++ b/docs/App.md @@ -0,0 +1,31 @@ +# App + +Serialize Application info + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**label** | **str** | | + +## Example + +```python +from authentik_client.models.app import App + +# TODO update the JSON string below +json = "{}" +# create an instance of App from a JSON string +app_instance = App.from_json(json) +# print the JSON string representation of the object +print(App.to_json()) + +# convert the object into a dict +app_dict = app_instance.to_dict() +# create an instance of App from a dict +app_from_dict = App.from_dict(app_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AppEnum.md b/docs/AppEnum.md new file mode 100644 index 000000000..a95e2ffc0 --- /dev/null +++ b/docs/AppEnum.md @@ -0,0 +1,168 @@ +# AppEnum + + +## Enum + +* `AUTHENTIK_DOT_COMMANDS` (value: `'authentik.commands'`) + +* `AUTHENTIK_DOT_TENANTS` (value: `'authentik.tenants'`) + +* `AUTHENTIK_DOT_TASKS` (value: `'authentik.tasks'`) + +* `AUTHENTIK_DOT_ADMIN` (value: `'authentik.admin'`) + +* `AUTHENTIK_DOT_API` (value: `'authentik.api'`) + +* `AUTHENTIK_DOT_CORE` (value: `'authentik.core'`) + +* `AUTHENTIK_DOT_CRYPTO` (value: `'authentik.crypto'`) + +* `AUTHENTIK_DOT_ENDPOINTS` (value: `'authentik.endpoints'`) + +* `AUTHENTIK_DOT_ENDPOINTS_DOT_CONNECTORS_DOT_AGENT` (value: `'authentik.endpoints.connectors.agent'`) + +* `AUTHENTIK_DOT_ENTERPRISE` (value: `'authentik.enterprise'`) + +* `AUTHENTIK_DOT_EVENTS` (value: `'authentik.events'`) + +* `AUTHENTIK_DOT_ADMIN_DOT_FILES` (value: `'authentik.admin.files'`) + +* `AUTHENTIK_DOT_FLOWS` (value: `'authentik.flows'`) + +* `AUTHENTIK_DOT_OUTPOSTS` (value: `'authentik.outposts'`) + +* `AUTHENTIK_DOT_POLICIES_DOT_DUMMY` (value: `'authentik.policies.dummy'`) + +* `AUTHENTIK_DOT_POLICIES_DOT_EVENT_MATCHER` (value: `'authentik.policies.event_matcher'`) + +* `AUTHENTIK_DOT_POLICIES_DOT_EXPIRY` (value: `'authentik.policies.expiry'`) + +* `AUTHENTIK_DOT_POLICIES_DOT_EXPRESSION` (value: `'authentik.policies.expression'`) + +* `AUTHENTIK_DOT_POLICIES_DOT_GEOIP` (value: `'authentik.policies.geoip'`) + +* `AUTHENTIK_DOT_POLICIES_DOT_PASSWORD` (value: `'authentik.policies.password'`) + +* `AUTHENTIK_DOT_POLICIES_DOT_REPUTATION` (value: `'authentik.policies.reputation'`) + +* `AUTHENTIK_DOT_POLICIES` (value: `'authentik.policies'`) + +* `AUTHENTIK_DOT_PROVIDERS_DOT_LDAP` (value: `'authentik.providers.ldap'`) + +* `AUTHENTIK_DOT_PROVIDERS_DOT_OAUTH2` (value: `'authentik.providers.oauth2'`) + +* `AUTHENTIK_DOT_PROVIDERS_DOT_PROXY` (value: `'authentik.providers.proxy'`) + +* `AUTHENTIK_DOT_PROVIDERS_DOT_RAC` (value: `'authentik.providers.rac'`) + +* `AUTHENTIK_DOT_PROVIDERS_DOT_RADIUS` (value: `'authentik.providers.radius'`) + +* `AUTHENTIK_DOT_PROVIDERS_DOT_SAML` (value: `'authentik.providers.saml'`) + +* `AUTHENTIK_DOT_PROVIDERS_DOT_SCIM` (value: `'authentik.providers.scim'`) + +* `AUTHENTIK_DOT_RBAC` (value: `'authentik.rbac'`) + +* `AUTHENTIK_DOT_RECOVERY` (value: `'authentik.recovery'`) + +* `AUTHENTIK_DOT_SOURCES_DOT_KERBEROS` (value: `'authentik.sources.kerberos'`) + +* `AUTHENTIK_DOT_SOURCES_DOT_LDAP` (value: `'authentik.sources.ldap'`) + +* `AUTHENTIK_DOT_SOURCES_DOT_OAUTH` (value: `'authentik.sources.oauth'`) + +* `AUTHENTIK_DOT_SOURCES_DOT_PLEX` (value: `'authentik.sources.plex'`) + +* `AUTHENTIK_DOT_SOURCES_DOT_SAML` (value: `'authentik.sources.saml'`) + +* `AUTHENTIK_DOT_SOURCES_DOT_SCIM` (value: `'authentik.sources.scim'`) + +* `AUTHENTIK_DOT_SOURCES_DOT_TELEGRAM` (value: `'authentik.sources.telegram'`) + +* `AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR` (value: `'authentik.stages.authenticator'`) + +* `AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_DUO` (value: `'authentik.stages.authenticator_duo'`) + +* `AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_EMAIL` (value: `'authentik.stages.authenticator_email'`) + +* `AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_SMS` (value: `'authentik.stages.authenticator_sms'`) + +* `AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_STATIC` (value: `'authentik.stages.authenticator_static'`) + +* `AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_TOTP` (value: `'authentik.stages.authenticator_totp'`) + +* `AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_VALIDATE` (value: `'authentik.stages.authenticator_validate'`) + +* `AUTHENTIK_DOT_STAGES_DOT_AUTHENTICATOR_WEBAUTHN` (value: `'authentik.stages.authenticator_webauthn'`) + +* `AUTHENTIK_DOT_STAGES_DOT_CAPTCHA` (value: `'authentik.stages.captcha'`) + +* `AUTHENTIK_DOT_STAGES_DOT_CONSENT` (value: `'authentik.stages.consent'`) + +* `AUTHENTIK_DOT_STAGES_DOT_DENY` (value: `'authentik.stages.deny'`) + +* `AUTHENTIK_DOT_STAGES_DOT_DUMMY` (value: `'authentik.stages.dummy'`) + +* `AUTHENTIK_DOT_STAGES_DOT_EMAIL` (value: `'authentik.stages.email'`) + +* `AUTHENTIK_DOT_STAGES_DOT_IDENTIFICATION` (value: `'authentik.stages.identification'`) + +* `AUTHENTIK_DOT_STAGES_DOT_INVITATION` (value: `'authentik.stages.invitation'`) + +* `AUTHENTIK_DOT_STAGES_DOT_PASSWORD` (value: `'authentik.stages.password'`) + +* `AUTHENTIK_DOT_STAGES_DOT_PROMPT` (value: `'authentik.stages.prompt'`) + +* `AUTHENTIK_DOT_STAGES_DOT_REDIRECT` (value: `'authentik.stages.redirect'`) + +* `AUTHENTIK_DOT_STAGES_DOT_USER_DELETE` (value: `'authentik.stages.user_delete'`) + +* `AUTHENTIK_DOT_STAGES_DOT_USER_LOGIN` (value: `'authentik.stages.user_login'`) + +* `AUTHENTIK_DOT_STAGES_DOT_USER_LOGOUT` (value: `'authentik.stages.user_logout'`) + +* `AUTHENTIK_DOT_STAGES_DOT_USER_WRITE` (value: `'authentik.stages.user_write'`) + +* `AUTHENTIK_DOT_TASKS_DOT_SCHEDULES` (value: `'authentik.tasks.schedules'`) + +* `AUTHENTIK_DOT_BRANDS` (value: `'authentik.brands'`) + +* `AUTHENTIK_DOT_BLUEPRINTS` (value: `'authentik.blueprints'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_AUDIT` (value: `'authentik.enterprise.audit'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_ENDPOINTS_DOT_CONNECTORS_DOT_AGENT` (value: `'authentik.enterprise.endpoints.connectors.agent'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_ENDPOINTS_DOT_CONNECTORS_DOT_FLEET` (value: `'authentik.enterprise.endpoints.connectors.fleet'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_ENDPOINTS_DOT_CONNECTORS_DOT_GOOGLE_CHROME` (value: `'authentik.enterprise.endpoints.connectors.google_chrome'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_LIFECYCLE` (value: `'authentik.enterprise.lifecycle'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_POLICIES_DOT_UNIQUE_PASSWORD` (value: `'authentik.enterprise.policies.unique_password'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_GOOGLE_WORKSPACE` (value: `'authentik.enterprise.providers.google_workspace'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_MICROSOFT_ENTRA` (value: `'authentik.enterprise.providers.microsoft_entra'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_RADIUS` (value: `'authentik.enterprise.providers.radius'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_SCIM` (value: `'authentik.enterprise.providers.scim'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_SSF` (value: `'authentik.enterprise.providers.ssf'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_PROVIDERS_DOT_WS_FEDERATION` (value: `'authentik.enterprise.providers.ws_federation'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_REPORTS` (value: `'authentik.enterprise.reports'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_STAGES_DOT_ACCOUNT_LOCKDOWN` (value: `'authentik.enterprise.stages.account_lockdown'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_STAGES_DOT_AUTHENTICATOR_ENDPOINT_GDTC` (value: `'authentik.enterprise.stages.authenticator_endpoint_gdtc'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_STAGES_DOT_MTLS` (value: `'authentik.enterprise.stages.mtls'`) + +* `AUTHENTIK_DOT_ENTERPRISE_DOT_STAGES_DOT_SOURCE` (value: `'authentik.enterprise.stages.source'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AppleChallengeResponseRequest.md b/docs/AppleChallengeResponseRequest.md new file mode 100644 index 000000000..acc0a1fd7 --- /dev/null +++ b/docs/AppleChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# AppleChallengeResponseRequest + +Pseudo class for apple response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-source-oauth-apple'] + +## Example + +```python +from authentik_client.models.apple_challenge_response_request import AppleChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AppleChallengeResponseRequest from a JSON string +apple_challenge_response_request_instance = AppleChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(AppleChallengeResponseRequest.to_json()) + +# convert the object into a dict +apple_challenge_response_request_dict = apple_challenge_response_request_instance.to_dict() +# create an instance of AppleChallengeResponseRequest from a dict +apple_challenge_response_request_from_dict = AppleChallengeResponseRequest.from_dict(apple_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AppleIndependentSecureEnclave.md b/docs/AppleIndependentSecureEnclave.md new file mode 100644 index 000000000..08f9108cf --- /dev/null +++ b/docs/AppleIndependentSecureEnclave.md @@ -0,0 +1,33 @@ +# AppleIndependentSecureEnclave + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**uuid** | **UUID** | | [optional] +**user** | **int** | The user that this device belongs to. | +**apple_secure_enclave_key** | **str** | | +**apple_enclave_key_id** | **str** | | +**device_type** | **str** | | + +## Example + +```python +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave + +# TODO update the JSON string below +json = "{}" +# create an instance of AppleIndependentSecureEnclave from a JSON string +apple_independent_secure_enclave_instance = AppleIndependentSecureEnclave.from_json(json) +# print the JSON string representation of the object +print(AppleIndependentSecureEnclave.to_json()) + +# convert the object into a dict +apple_independent_secure_enclave_dict = apple_independent_secure_enclave_instance.to_dict() +# create an instance of AppleIndependentSecureEnclave from a dict +apple_independent_secure_enclave_from_dict = AppleIndependentSecureEnclave.from_dict(apple_independent_secure_enclave_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AppleIndependentSecureEnclaveRequest.md b/docs/AppleIndependentSecureEnclaveRequest.md new file mode 100644 index 000000000..07a3f5f22 --- /dev/null +++ b/docs/AppleIndependentSecureEnclaveRequest.md @@ -0,0 +1,33 @@ +# AppleIndependentSecureEnclaveRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**uuid** | **UUID** | | [optional] +**user** | **int** | The user that this device belongs to. | +**apple_secure_enclave_key** | **str** | | +**apple_enclave_key_id** | **str** | | +**device_type** | **str** | | + +## Example + +```python +from authentik_client.models.apple_independent_secure_enclave_request import AppleIndependentSecureEnclaveRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AppleIndependentSecureEnclaveRequest from a JSON string +apple_independent_secure_enclave_request_instance = AppleIndependentSecureEnclaveRequest.from_json(json) +# print the JSON string representation of the object +print(AppleIndependentSecureEnclaveRequest.to_json()) + +# convert the object into a dict +apple_independent_secure_enclave_request_dict = apple_independent_secure_enclave_request_instance.to_dict() +# create an instance of AppleIndependentSecureEnclaveRequest from a dict +apple_independent_secure_enclave_request_from_dict = AppleIndependentSecureEnclaveRequest.from_dict(apple_independent_secure_enclave_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AppleLoginChallenge.md b/docs/AppleLoginChallenge.md new file mode 100644 index 000000000..50155915f --- /dev/null +++ b/docs/AppleLoginChallenge.md @@ -0,0 +1,36 @@ +# AppleLoginChallenge + +Special challenge for apple-native authentication flow, which happens on the client. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-source-oauth-apple'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**client_id** | **str** | | +**scope** | **str** | | +**redirect_uri** | **str** | | +**state** | **str** | | + +## Example + +```python +from authentik_client.models.apple_login_challenge import AppleLoginChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AppleLoginChallenge from a JSON string +apple_login_challenge_instance = AppleLoginChallenge.from_json(json) +# print the JSON string representation of the object +print(AppleLoginChallenge.to_json()) + +# convert the object into a dict +apple_login_challenge_dict = apple_login_challenge_instance.to_dict() +# create an instance of AppleLoginChallenge from a dict +apple_login_challenge_from_dict = AppleLoginChallenge.from_dict(apple_login_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Application.md b/docs/Application.md new file mode 100644 index 000000000..d55a76655 --- /dev/null +++ b/docs/Application.md @@ -0,0 +1,47 @@ +# Application + +Application Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | Application's display Name. | +**slug** | **str** | Internal application name, used in URLs. | +**provider** | **int** | | [optional] +**provider_obj** | [**Provider**](Provider.md) | | [readonly] +**backchannel_providers** | **List[int]** | | [optional] +**backchannel_providers_obj** | [**List[Provider]**](Provider.md) | | [readonly] +**launch_url** | **str** | Allow formatting of launch URL | [readonly] +**open_in_new_tab** | **bool** | Open launch URL in a new browser tab or window. | [optional] +**meta_launch_url** | **str** | | [optional] +**meta_icon** | **str** | | [optional] +**meta_icon_url** | **str** | Get the URL to the App Icon image | [readonly] +**meta_icon_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**meta_description** | **str** | | [optional] +**meta_publisher** | **str** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**group** | **str** | | [optional] +**meta_hide** | **bool** | Hide this application from the user's My applications page. | [optional] + +## Example + +```python +from authentik_client.models.application import Application + +# TODO update the JSON string below +json = "{}" +# create an instance of Application from a JSON string +application_instance = Application.from_json(json) +# print the JSON string representation of the object +print(Application.to_json()) + +# convert the object into a dict +application_dict = application_instance.to_dict() +# create an instance of Application from a dict +application_from_dict = Application.from_dict(application_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ApplicationEntitlement.md b/docs/ApplicationEntitlement.md new file mode 100644 index 000000000..bfbdc5a3f --- /dev/null +++ b/docs/ApplicationEntitlement.md @@ -0,0 +1,33 @@ +# ApplicationEntitlement + +ApplicationEntitlement Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pbm_uuid** | **UUID** | | [readonly] +**name** | **str** | | +**app** | **UUID** | | +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.application_entitlement import ApplicationEntitlement + +# TODO update the JSON string below +json = "{}" +# create an instance of ApplicationEntitlement from a JSON string +application_entitlement_instance = ApplicationEntitlement.from_json(json) +# print the JSON string representation of the object +print(ApplicationEntitlement.to_json()) + +# convert the object into a dict +application_entitlement_dict = application_entitlement_instance.to_dict() +# create an instance of ApplicationEntitlement from a dict +application_entitlement_from_dict = ApplicationEntitlement.from_dict(application_entitlement_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ApplicationEntitlementRequest.md b/docs/ApplicationEntitlementRequest.md new file mode 100644 index 000000000..0e6504fea --- /dev/null +++ b/docs/ApplicationEntitlementRequest.md @@ -0,0 +1,32 @@ +# ApplicationEntitlementRequest + +ApplicationEntitlement Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**app** | **UUID** | | +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.application_entitlement_request import ApplicationEntitlementRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ApplicationEntitlementRequest from a JSON string +application_entitlement_request_instance = ApplicationEntitlementRequest.from_json(json) +# print the JSON string representation of the object +print(ApplicationEntitlementRequest.to_json()) + +# convert the object into a dict +application_entitlement_request_dict = application_entitlement_request_instance.to_dict() +# create an instance of ApplicationEntitlementRequest from a dict +application_entitlement_request_from_dict = ApplicationEntitlementRequest.from_dict(application_entitlement_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ApplicationRequest.md b/docs/ApplicationRequest.md new file mode 100644 index 000000000..0da18ea22 --- /dev/null +++ b/docs/ApplicationRequest.md @@ -0,0 +1,41 @@ +# ApplicationRequest + +Application Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Application's display Name. | +**slug** | **str** | Internal application name, used in URLs. | +**provider** | **int** | | [optional] +**backchannel_providers** | **List[int]** | | [optional] +**open_in_new_tab** | **bool** | Open launch URL in a new browser tab or window. | [optional] +**meta_launch_url** | **str** | | [optional] +**meta_icon** | **str** | | [optional] +**meta_description** | **str** | | [optional] +**meta_publisher** | **str** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**group** | **str** | | [optional] +**meta_hide** | **bool** | Hide this application from the user's My applications page. | [optional] + +## Example + +```python +from authentik_client.models.application_request import ApplicationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ApplicationRequest from a JSON string +application_request_instance = ApplicationRequest.from_json(json) +# print the JSON string representation of the object +print(ApplicationRequest.to_json()) + +# convert the object into a dict +application_request_dict = application_request_instance.to_dict() +# create an instance of ApplicationRequest from a dict +application_request_from_dict = ApplicationRequest.from_dict(application_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthTypeEnum.md b/docs/AuthTypeEnum.md new file mode 100644 index 000000000..819014681 --- /dev/null +++ b/docs/AuthTypeEnum.md @@ -0,0 +1,12 @@ +# AuthTypeEnum + + +## Enum + +* `BASIC` (value: `'basic'`) + +* `BEARER` (value: `'bearer'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatedSession.md b/docs/AuthenticatedSession.md new file mode 100644 index 000000000..fd1ece179 --- /dev/null +++ b/docs/AuthenticatedSession.md @@ -0,0 +1,39 @@ +# AuthenticatedSession + +AuthenticatedSession Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**uuid** | **UUID** | | [optional] +**current** | **bool** | Check if session is currently active session | [readonly] +**user_agent** | [**AuthenticatedSessionUserAgent**](AuthenticatedSessionUserAgent.md) | | +**geo_ip** | [**AuthenticatedSessionGeoIp**](AuthenticatedSessionGeoIp.md) | | +**asn** | [**AuthenticatedSessionAsn**](AuthenticatedSessionAsn.md) | | +**user** | **int** | | +**last_ip** | **str** | | [readonly] +**last_user_agent** | **str** | | [readonly] +**last_used** | **datetime** | | [readonly] +**expires** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.authenticated_session import AuthenticatedSession + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatedSession from a JSON string +authenticated_session_instance = AuthenticatedSession.from_json(json) +# print the JSON string representation of the object +print(AuthenticatedSession.to_json()) + +# convert the object into a dict +authenticated_session_dict = authenticated_session_instance.to_dict() +# create an instance of AuthenticatedSession from a dict +authenticated_session_from_dict = AuthenticatedSession.from_dict(authenticated_session_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatedSessionAsn.md b/docs/AuthenticatedSessionAsn.md new file mode 100644 index 000000000..13aa5da42 --- /dev/null +++ b/docs/AuthenticatedSessionAsn.md @@ -0,0 +1,32 @@ +# AuthenticatedSessionAsn + +Get ASN Data + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**asn** | **int** | | +**as_org** | **str** | | +**network** | **str** | | + +## Example + +```python +from authentik_client.models.authenticated_session_asn import AuthenticatedSessionAsn + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatedSessionAsn from a JSON string +authenticated_session_asn_instance = AuthenticatedSessionAsn.from_json(json) +# print the JSON string representation of the object +print(AuthenticatedSessionAsn.to_json()) + +# convert the object into a dict +authenticated_session_asn_dict = authenticated_session_asn_instance.to_dict() +# create an instance of AuthenticatedSessionAsn from a dict +authenticated_session_asn_from_dict = AuthenticatedSessionAsn.from_dict(authenticated_session_asn_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatedSessionGeoIp.md b/docs/AuthenticatedSessionGeoIp.md new file mode 100644 index 000000000..0ba364905 --- /dev/null +++ b/docs/AuthenticatedSessionGeoIp.md @@ -0,0 +1,34 @@ +# AuthenticatedSessionGeoIp + +Get GeoIP Data + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**continent** | **str** | | +**country** | **str** | | +**lat** | **float** | | +**long** | **float** | | +**city** | **str** | | + +## Example + +```python +from authentik_client.models.authenticated_session_geo_ip import AuthenticatedSessionGeoIp + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatedSessionGeoIp from a JSON string +authenticated_session_geo_ip_instance = AuthenticatedSessionGeoIp.from_json(json) +# print the JSON string representation of the object +print(AuthenticatedSessionGeoIp.to_json()) + +# convert the object into a dict +authenticated_session_geo_ip_dict = authenticated_session_geo_ip_instance.to_dict() +# create an instance of AuthenticatedSessionGeoIp from a dict +authenticated_session_geo_ip_from_dict = AuthenticatedSessionGeoIp.from_dict(authenticated_session_geo_ip_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatedSessionUserAgent.md b/docs/AuthenticatedSessionUserAgent.md new file mode 100644 index 000000000..210f38fac --- /dev/null +++ b/docs/AuthenticatedSessionUserAgent.md @@ -0,0 +1,33 @@ +# AuthenticatedSessionUserAgent + +Get parsed user agent + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device** | [**AuthenticatedSessionUserAgentDevice**](AuthenticatedSessionUserAgentDevice.md) | | +**os** | [**AuthenticatedSessionUserAgentOs**](AuthenticatedSessionUserAgentOs.md) | | +**user_agent** | [**AuthenticatedSessionUserAgentUserAgent**](AuthenticatedSessionUserAgentUserAgent.md) | | +**string** | **str** | | + +## Example + +```python +from authentik_client.models.authenticated_session_user_agent import AuthenticatedSessionUserAgent + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatedSessionUserAgent from a JSON string +authenticated_session_user_agent_instance = AuthenticatedSessionUserAgent.from_json(json) +# print the JSON string representation of the object +print(AuthenticatedSessionUserAgent.to_json()) + +# convert the object into a dict +authenticated_session_user_agent_dict = authenticated_session_user_agent_instance.to_dict() +# create an instance of AuthenticatedSessionUserAgent from a dict +authenticated_session_user_agent_from_dict = AuthenticatedSessionUserAgent.from_dict(authenticated_session_user_agent_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatedSessionUserAgentDevice.md b/docs/AuthenticatedSessionUserAgentDevice.md new file mode 100644 index 000000000..1f38e8c2c --- /dev/null +++ b/docs/AuthenticatedSessionUserAgentDevice.md @@ -0,0 +1,32 @@ +# AuthenticatedSessionUserAgentDevice + +User agent device + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**brand** | **str** | | +**family** | **str** | | +**model** | **str** | | + +## Example + +```python +from authentik_client.models.authenticated_session_user_agent_device import AuthenticatedSessionUserAgentDevice + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatedSessionUserAgentDevice from a JSON string +authenticated_session_user_agent_device_instance = AuthenticatedSessionUserAgentDevice.from_json(json) +# print the JSON string representation of the object +print(AuthenticatedSessionUserAgentDevice.to_json()) + +# convert the object into a dict +authenticated_session_user_agent_device_dict = authenticated_session_user_agent_device_instance.to_dict() +# create an instance of AuthenticatedSessionUserAgentDevice from a dict +authenticated_session_user_agent_device_from_dict = AuthenticatedSessionUserAgentDevice.from_dict(authenticated_session_user_agent_device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatedSessionUserAgentOs.md b/docs/AuthenticatedSessionUserAgentOs.md new file mode 100644 index 000000000..bb6bf05fb --- /dev/null +++ b/docs/AuthenticatedSessionUserAgentOs.md @@ -0,0 +1,34 @@ +# AuthenticatedSessionUserAgentOs + +User agent os + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**family** | **str** | | +**major** | **str** | | +**minor** | **str** | | +**patch** | **str** | | +**patch_minor** | **str** | | + +## Example + +```python +from authentik_client.models.authenticated_session_user_agent_os import AuthenticatedSessionUserAgentOs + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatedSessionUserAgentOs from a JSON string +authenticated_session_user_agent_os_instance = AuthenticatedSessionUserAgentOs.from_json(json) +# print the JSON string representation of the object +print(AuthenticatedSessionUserAgentOs.to_json()) + +# convert the object into a dict +authenticated_session_user_agent_os_dict = authenticated_session_user_agent_os_instance.to_dict() +# create an instance of AuthenticatedSessionUserAgentOs from a dict +authenticated_session_user_agent_os_from_dict = AuthenticatedSessionUserAgentOs.from_dict(authenticated_session_user_agent_os_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatedSessionUserAgentUserAgent.md b/docs/AuthenticatedSessionUserAgentUserAgent.md new file mode 100644 index 000000000..2eba4a3b7 --- /dev/null +++ b/docs/AuthenticatedSessionUserAgentUserAgent.md @@ -0,0 +1,33 @@ +# AuthenticatedSessionUserAgentUserAgent + +User agent browser + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**family** | **str** | | +**major** | **str** | | +**minor** | **str** | | +**patch** | **str** | | + +## Example + +```python +from authentik_client.models.authenticated_session_user_agent_user_agent import AuthenticatedSessionUserAgentUserAgent + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatedSessionUserAgentUserAgent from a JSON string +authenticated_session_user_agent_user_agent_instance = AuthenticatedSessionUserAgentUserAgent.from_json(json) +# print the JSON string representation of the object +print(AuthenticatedSessionUserAgentUserAgent.to_json()) + +# convert the object into a dict +authenticated_session_user_agent_user_agent_dict = authenticated_session_user_agent_user_agent_instance.to_dict() +# create an instance of AuthenticatedSessionUserAgentUserAgent from a dict +authenticated_session_user_agent_user_agent_from_dict = AuthenticatedSessionUserAgentUserAgent.from_dict(authenticated_session_user_agent_user_agent_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticationEnum.md b/docs/AuthenticationEnum.md new file mode 100644 index 000000000..4b2f6c559 --- /dev/null +++ b/docs/AuthenticationEnum.md @@ -0,0 +1,22 @@ +# AuthenticationEnum + + +## Enum + +* `NONE` (value: `'none'`) + +* `REQUIRE_AUTHENTICATED` (value: `'require_authenticated'`) + +* `REQUIRE_UNAUTHENTICATED` (value: `'require_unauthenticated'`) + +* `REQUIRE_SUPERUSER` (value: `'require_superuser'`) + +* `REQUIRE_REDIRECT` (value: `'require_redirect'`) + +* `REQUIRE_OUTPOST` (value: `'require_outpost'`) + +* `REQUIRE_TOKEN` (value: `'require_token'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorAttachmentEnum.md b/docs/AuthenticatorAttachmentEnum.md new file mode 100644 index 000000000..ae21ac40c --- /dev/null +++ b/docs/AuthenticatorAttachmentEnum.md @@ -0,0 +1,12 @@ +# AuthenticatorAttachmentEnum + + +## Enum + +* `PLATFORM` (value: `'platform'`) + +* `CROSS_MINUS_PLATFORM` (value: `'cross-platform'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorDuoChallenge.md b/docs/AuthenticatorDuoChallenge.md new file mode 100644 index 000000000..e58e54f9e --- /dev/null +++ b/docs/AuthenticatorDuoChallenge.md @@ -0,0 +1,37 @@ +# AuthenticatorDuoChallenge + +Duo Challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-duo'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**activation_barcode** | **str** | | +**activation_code** | **str** | | +**stage_uuid** | **str** | | + +## Example + +```python +from authentik_client.models.authenticator_duo_challenge import AuthenticatorDuoChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorDuoChallenge from a JSON string +authenticator_duo_challenge_instance = AuthenticatorDuoChallenge.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorDuoChallenge.to_json()) + +# convert the object into a dict +authenticator_duo_challenge_dict = authenticator_duo_challenge_instance.to_dict() +# create an instance of AuthenticatorDuoChallenge from a dict +authenticator_duo_challenge_from_dict = AuthenticatorDuoChallenge.from_dict(authenticator_duo_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorDuoChallengeResponseRequest.md b/docs/AuthenticatorDuoChallengeResponseRequest.md new file mode 100644 index 000000000..11b29ad18 --- /dev/null +++ b/docs/AuthenticatorDuoChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# AuthenticatorDuoChallengeResponseRequest + +Pseudo class for duo response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-duo'] + +## Example + +```python +from authentik_client.models.authenticator_duo_challenge_response_request import AuthenticatorDuoChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorDuoChallengeResponseRequest from a JSON string +authenticator_duo_challenge_response_request_instance = AuthenticatorDuoChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorDuoChallengeResponseRequest.to_json()) + +# convert the object into a dict +authenticator_duo_challenge_response_request_dict = authenticator_duo_challenge_response_request_instance.to_dict() +# create an instance of AuthenticatorDuoChallengeResponseRequest from a dict +authenticator_duo_challenge_response_request_from_dict = AuthenticatorDuoChallengeResponseRequest.from_dict(authenticator_duo_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorDuoStage.md b/docs/AuthenticatorDuoStage.md new file mode 100644 index 000000000..359f75590 --- /dev/null +++ b/docs/AuthenticatorDuoStage.md @@ -0,0 +1,41 @@ +# AuthenticatorDuoStage + +AuthenticatorDuoStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**client_id** | **str** | | +**api_hostname** | **str** | | +**admin_integration_key** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorDuoStage from a JSON string +authenticator_duo_stage_instance = AuthenticatorDuoStage.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorDuoStage.to_json()) + +# convert the object into a dict +authenticator_duo_stage_dict = authenticator_duo_stage_instance.to_dict() +# create an instance of AuthenticatorDuoStage from a dict +authenticator_duo_stage_from_dict = AuthenticatorDuoStage.from_dict(authenticator_duo_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorDuoStageDeviceImportResponse.md b/docs/AuthenticatorDuoStageDeviceImportResponse.md new file mode 100644 index 000000000..d9dda7daf --- /dev/null +++ b/docs/AuthenticatorDuoStageDeviceImportResponse.md @@ -0,0 +1,30 @@ +# AuthenticatorDuoStageDeviceImportResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**count** | **int** | | [readonly] +**error** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.authenticator_duo_stage_device_import_response import AuthenticatorDuoStageDeviceImportResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorDuoStageDeviceImportResponse from a JSON string +authenticator_duo_stage_device_import_response_instance = AuthenticatorDuoStageDeviceImportResponse.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorDuoStageDeviceImportResponse.to_json()) + +# convert the object into a dict +authenticator_duo_stage_device_import_response_dict = authenticator_duo_stage_device_import_response_instance.to_dict() +# create an instance of AuthenticatorDuoStageDeviceImportResponse from a dict +authenticator_duo_stage_device_import_response_from_dict = AuthenticatorDuoStageDeviceImportResponse.from_dict(authenticator_duo_stage_device_import_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorDuoStageManualDeviceImportRequest.md b/docs/AuthenticatorDuoStageManualDeviceImportRequest.md new file mode 100644 index 000000000..2026ab4b6 --- /dev/null +++ b/docs/AuthenticatorDuoStageManualDeviceImportRequest.md @@ -0,0 +1,30 @@ +# AuthenticatorDuoStageManualDeviceImportRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**duo_user_id** | **str** | | +**username** | **str** | | + +## Example + +```python +from authentik_client.models.authenticator_duo_stage_manual_device_import_request import AuthenticatorDuoStageManualDeviceImportRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorDuoStageManualDeviceImportRequest from a JSON string +authenticator_duo_stage_manual_device_import_request_instance = AuthenticatorDuoStageManualDeviceImportRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorDuoStageManualDeviceImportRequest.to_json()) + +# convert the object into a dict +authenticator_duo_stage_manual_device_import_request_dict = authenticator_duo_stage_manual_device_import_request_instance.to_dict() +# create an instance of AuthenticatorDuoStageManualDeviceImportRequest from a dict +authenticator_duo_stage_manual_device_import_request_from_dict = AuthenticatorDuoStageManualDeviceImportRequest.from_dict(authenticator_duo_stage_manual_device_import_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorDuoStageRequest.md b/docs/AuthenticatorDuoStageRequest.md new file mode 100644 index 000000000..0a6be1c66 --- /dev/null +++ b/docs/AuthenticatorDuoStageRequest.md @@ -0,0 +1,37 @@ +# AuthenticatorDuoStageRequest + +AuthenticatorDuoStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**client_id** | **str** | | +**client_secret** | **str** | | +**api_hostname** | **str** | | +**admin_integration_key** | **str** | | [optional] +**admin_secret_key** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_duo_stage_request import AuthenticatorDuoStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorDuoStageRequest from a JSON string +authenticator_duo_stage_request_instance = AuthenticatorDuoStageRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorDuoStageRequest.to_json()) + +# convert the object into a dict +authenticator_duo_stage_request_dict = authenticator_duo_stage_request_instance.to_dict() +# create an instance of AuthenticatorDuoStageRequest from a dict +authenticator_duo_stage_request_from_dict = AuthenticatorDuoStageRequest.from_dict(authenticator_duo_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorEmailChallenge.md b/docs/AuthenticatorEmailChallenge.md new file mode 100644 index 000000000..20b58238d --- /dev/null +++ b/docs/AuthenticatorEmailChallenge.md @@ -0,0 +1,36 @@ +# AuthenticatorEmailChallenge + +Authenticator Email Setup challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-email'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**email** | **str** | | [optional] +**email_required** | **bool** | | [optional] [default to True] + +## Example + +```python +from authentik_client.models.authenticator_email_challenge import AuthenticatorEmailChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorEmailChallenge from a JSON string +authenticator_email_challenge_instance = AuthenticatorEmailChallenge.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorEmailChallenge.to_json()) + +# convert the object into a dict +authenticator_email_challenge_dict = authenticator_email_challenge_instance.to_dict() +# create an instance of AuthenticatorEmailChallenge from a dict +authenticator_email_challenge_from_dict = AuthenticatorEmailChallenge.from_dict(authenticator_email_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorEmailChallengeResponseRequest.md b/docs/AuthenticatorEmailChallengeResponseRequest.md new file mode 100644 index 000000000..8769056b2 --- /dev/null +++ b/docs/AuthenticatorEmailChallengeResponseRequest.md @@ -0,0 +1,32 @@ +# AuthenticatorEmailChallengeResponseRequest + +Authenticator Email Challenge response, device is set by get_response_instance + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-email'] +**code** | **str** | | [optional] +**email** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_email_challenge_response_request import AuthenticatorEmailChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorEmailChallengeResponseRequest from a JSON string +authenticator_email_challenge_response_request_instance = AuthenticatorEmailChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorEmailChallengeResponseRequest.to_json()) + +# convert the object into a dict +authenticator_email_challenge_response_request_dict = authenticator_email_challenge_response_request_instance.to_dict() +# create an instance of AuthenticatorEmailChallengeResponseRequest from a dict +authenticator_email_challenge_response_request_from_dict = AuthenticatorEmailChallengeResponseRequest.from_dict(authenticator_email_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorEmailStage.md b/docs/AuthenticatorEmailStage.md new file mode 100644 index 000000000..e16b3e571 --- /dev/null +++ b/docs/AuthenticatorEmailStage.md @@ -0,0 +1,49 @@ +# AuthenticatorEmailStage + +AuthenticatorEmailStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**use_global_settings** | **bool** | When enabled, global Email connection settings will be used and connection settings below will be ignored. | [optional] +**host** | **str** | | [optional] +**port** | **int** | | [optional] +**username** | **str** | | [optional] +**use_tls** | **bool** | | [optional] +**use_ssl** | **bool** | | [optional] +**timeout** | **int** | | [optional] +**from_address** | **str** | | [optional] +**subject** | **str** | | [optional] +**token_expiry** | **str** | Time the token sent is valid (Format: hours=3,minutes=17,seconds=300). | [optional] +**template** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorEmailStage from a JSON string +authenticator_email_stage_instance = AuthenticatorEmailStage.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorEmailStage.to_json()) + +# convert the object into a dict +authenticator_email_stage_dict = authenticator_email_stage_instance.to_dict() +# create an instance of AuthenticatorEmailStage from a dict +authenticator_email_stage_from_dict = AuthenticatorEmailStage.from_dict(authenticator_email_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorEmailStageRequest.md b/docs/AuthenticatorEmailStageRequest.md new file mode 100644 index 000000000..72f0c1455 --- /dev/null +++ b/docs/AuthenticatorEmailStageRequest.md @@ -0,0 +1,44 @@ +# AuthenticatorEmailStageRequest + +AuthenticatorEmailStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**use_global_settings** | **bool** | When enabled, global Email connection settings will be used and connection settings below will be ignored. | [optional] +**host** | **str** | | [optional] +**port** | **int** | | [optional] +**username** | **str** | | [optional] +**password** | **str** | | [optional] +**use_tls** | **bool** | | [optional] +**use_ssl** | **bool** | | [optional] +**timeout** | **int** | | [optional] +**from_address** | **str** | | [optional] +**subject** | **str** | | [optional] +**token_expiry** | **str** | Time the token sent is valid (Format: hours=3,minutes=17,seconds=300). | [optional] +**template** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_email_stage_request import AuthenticatorEmailStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorEmailStageRequest from a JSON string +authenticator_email_stage_request_instance = AuthenticatorEmailStageRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorEmailStageRequest.to_json()) + +# convert the object into a dict +authenticator_email_stage_request_dict = authenticator_email_stage_request_instance.to_dict() +# create an instance of AuthenticatorEmailStageRequest from a dict +authenticator_email_stage_request_from_dict = AuthenticatorEmailStageRequest.from_dict(authenticator_email_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorEndpointGDTCStage.md b/docs/AuthenticatorEndpointGDTCStage.md new file mode 100644 index 000000000..076cd2c1f --- /dev/null +++ b/docs/AuthenticatorEndpointGDTCStage.md @@ -0,0 +1,39 @@ +# AuthenticatorEndpointGDTCStage + +AuthenticatorEndpointGDTCStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**credentials** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorEndpointGDTCStage from a JSON string +authenticator_endpoint_gdtc_stage_instance = AuthenticatorEndpointGDTCStage.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorEndpointGDTCStage.to_json()) + +# convert the object into a dict +authenticator_endpoint_gdtc_stage_dict = authenticator_endpoint_gdtc_stage_instance.to_dict() +# create an instance of AuthenticatorEndpointGDTCStage from a dict +authenticator_endpoint_gdtc_stage_from_dict = AuthenticatorEndpointGDTCStage.from_dict(authenticator_endpoint_gdtc_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorEndpointGDTCStageRequest.md b/docs/AuthenticatorEndpointGDTCStageRequest.md new file mode 100644 index 000000000..0bcbde02e --- /dev/null +++ b/docs/AuthenticatorEndpointGDTCStageRequest.md @@ -0,0 +1,33 @@ +# AuthenticatorEndpointGDTCStageRequest + +AuthenticatorEndpointGDTCStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**credentials** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.authenticator_endpoint_gdtc_stage_request import AuthenticatorEndpointGDTCStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorEndpointGDTCStageRequest from a JSON string +authenticator_endpoint_gdtc_stage_request_instance = AuthenticatorEndpointGDTCStageRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorEndpointGDTCStageRequest.to_json()) + +# convert the object into a dict +authenticator_endpoint_gdtc_stage_request_dict = authenticator_endpoint_gdtc_stage_request_instance.to_dict() +# create an instance of AuthenticatorEndpointGDTCStageRequest from a dict +authenticator_endpoint_gdtc_stage_request_from_dict = AuthenticatorEndpointGDTCStageRequest.from_dict(authenticator_endpoint_gdtc_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorSMSChallenge.md b/docs/AuthenticatorSMSChallenge.md new file mode 100644 index 000000000..d4c9648f3 --- /dev/null +++ b/docs/AuthenticatorSMSChallenge.md @@ -0,0 +1,35 @@ +# AuthenticatorSMSChallenge + +SMS Setup challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-sms'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**phone_number_required** | **bool** | | [optional] [default to True] + +## Example + +```python +from authentik_client.models.authenticator_sms_challenge import AuthenticatorSMSChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorSMSChallenge from a JSON string +authenticator_sms_challenge_instance = AuthenticatorSMSChallenge.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorSMSChallenge.to_json()) + +# convert the object into a dict +authenticator_sms_challenge_dict = authenticator_sms_challenge_instance.to_dict() +# create an instance of AuthenticatorSMSChallenge from a dict +authenticator_sms_challenge_from_dict = AuthenticatorSMSChallenge.from_dict(authenticator_sms_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorSMSChallengeResponseRequest.md b/docs/AuthenticatorSMSChallengeResponseRequest.md new file mode 100644 index 000000000..3c930a82b --- /dev/null +++ b/docs/AuthenticatorSMSChallengeResponseRequest.md @@ -0,0 +1,32 @@ +# AuthenticatorSMSChallengeResponseRequest + +SMS Challenge response, device is set by get_response_instance + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-sms'] +**code** | **str** | | [optional] +**phone_number** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_sms_challenge_response_request import AuthenticatorSMSChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorSMSChallengeResponseRequest from a JSON string +authenticator_sms_challenge_response_request_instance = AuthenticatorSMSChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorSMSChallengeResponseRequest.to_json()) + +# convert the object into a dict +authenticator_sms_challenge_response_request_dict = authenticator_sms_challenge_response_request_instance.to_dict() +# create an instance of AuthenticatorSMSChallengeResponseRequest from a dict +authenticator_sms_challenge_response_request_from_dict = AuthenticatorSMSChallengeResponseRequest.from_dict(authenticator_sms_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorSMSStage.md b/docs/AuthenticatorSMSStage.md new file mode 100644 index 000000000..834b9b0da --- /dev/null +++ b/docs/AuthenticatorSMSStage.md @@ -0,0 +1,44 @@ +# AuthenticatorSMSStage + +AuthenticatorSMSStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**provider** | [**ProviderEnum**](ProviderEnum.md) | | +**from_number** | **str** | | +**account_sid** | **str** | | +**auth_type** | [**AuthTypeEnum**](AuthTypeEnum.md) | | [optional] +**verify_only** | **bool** | When enabled, the Phone number is only used during enrollment to verify the users authenticity. Only a hash of the phone number is saved to ensure it is not reused in the future. | [optional] +**mapping** | **UUID** | Optionally modify the payload being sent to custom providers. | [optional] + +## Example + +```python +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorSMSStage from a JSON string +authenticator_sms_stage_instance = AuthenticatorSMSStage.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorSMSStage.to_json()) + +# convert the object into a dict +authenticator_sms_stage_dict = authenticator_sms_stage_instance.to_dict() +# create an instance of AuthenticatorSMSStage from a dict +authenticator_sms_stage_from_dict = AuthenticatorSMSStage.from_dict(authenticator_sms_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorSMSStageRequest.md b/docs/AuthenticatorSMSStageRequest.md new file mode 100644 index 000000000..fcd1dd044 --- /dev/null +++ b/docs/AuthenticatorSMSStageRequest.md @@ -0,0 +1,40 @@ +# AuthenticatorSMSStageRequest + +AuthenticatorSMSStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**provider** | [**ProviderEnum**](ProviderEnum.md) | | +**from_number** | **str** | | +**account_sid** | **str** | | +**auth** | **str** | | +**auth_password** | **str** | | [optional] +**auth_type** | [**AuthTypeEnum**](AuthTypeEnum.md) | | [optional] +**verify_only** | **bool** | When enabled, the Phone number is only used during enrollment to verify the users authenticity. Only a hash of the phone number is saved to ensure it is not reused in the future. | [optional] +**mapping** | **UUID** | Optionally modify the payload being sent to custom providers. | [optional] + +## Example + +```python +from authentik_client.models.authenticator_sms_stage_request import AuthenticatorSMSStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorSMSStageRequest from a JSON string +authenticator_sms_stage_request_instance = AuthenticatorSMSStageRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorSMSStageRequest.to_json()) + +# convert the object into a dict +authenticator_sms_stage_request_dict = authenticator_sms_stage_request_instance.to_dict() +# create an instance of AuthenticatorSMSStageRequest from a dict +authenticator_sms_stage_request_from_dict = AuthenticatorSMSStageRequest.from_dict(authenticator_sms_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorStaticChallenge.md b/docs/AuthenticatorStaticChallenge.md new file mode 100644 index 000000000..39d995253 --- /dev/null +++ b/docs/AuthenticatorStaticChallenge.md @@ -0,0 +1,35 @@ +# AuthenticatorStaticChallenge + +Static authenticator challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-static'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**codes** | **List[str]** | | + +## Example + +```python +from authentik_client.models.authenticator_static_challenge import AuthenticatorStaticChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorStaticChallenge from a JSON string +authenticator_static_challenge_instance = AuthenticatorStaticChallenge.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorStaticChallenge.to_json()) + +# convert the object into a dict +authenticator_static_challenge_dict = authenticator_static_challenge_instance.to_dict() +# create an instance of AuthenticatorStaticChallenge from a dict +authenticator_static_challenge_from_dict = AuthenticatorStaticChallenge.from_dict(authenticator_static_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorStaticChallengeResponseRequest.md b/docs/AuthenticatorStaticChallengeResponseRequest.md new file mode 100644 index 000000000..e36a206b4 --- /dev/null +++ b/docs/AuthenticatorStaticChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# AuthenticatorStaticChallengeResponseRequest + +Pseudo class for static response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-static'] + +## Example + +```python +from authentik_client.models.authenticator_static_challenge_response_request import AuthenticatorStaticChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorStaticChallengeResponseRequest from a JSON string +authenticator_static_challenge_response_request_instance = AuthenticatorStaticChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorStaticChallengeResponseRequest.to_json()) + +# convert the object into a dict +authenticator_static_challenge_response_request_dict = authenticator_static_challenge_response_request_instance.to_dict() +# create an instance of AuthenticatorStaticChallengeResponseRequest from a dict +authenticator_static_challenge_response_request_from_dict = AuthenticatorStaticChallengeResponseRequest.from_dict(authenticator_static_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorStaticStage.md b/docs/AuthenticatorStaticStage.md new file mode 100644 index 000000000..27f264b33 --- /dev/null +++ b/docs/AuthenticatorStaticStage.md @@ -0,0 +1,40 @@ +# AuthenticatorStaticStage + +AuthenticatorStaticStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**token_count** | **int** | | [optional] +**token_length** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorStaticStage from a JSON string +authenticator_static_stage_instance = AuthenticatorStaticStage.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorStaticStage.to_json()) + +# convert the object into a dict +authenticator_static_stage_dict = authenticator_static_stage_instance.to_dict() +# create an instance of AuthenticatorStaticStage from a dict +authenticator_static_stage_from_dict = AuthenticatorStaticStage.from_dict(authenticator_static_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorStaticStageRequest.md b/docs/AuthenticatorStaticStageRequest.md new file mode 100644 index 000000000..f5318dc7d --- /dev/null +++ b/docs/AuthenticatorStaticStageRequest.md @@ -0,0 +1,34 @@ +# AuthenticatorStaticStageRequest + +AuthenticatorStaticStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**token_count** | **int** | | [optional] +**token_length** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_static_stage_request import AuthenticatorStaticStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorStaticStageRequest from a JSON string +authenticator_static_stage_request_instance = AuthenticatorStaticStageRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorStaticStageRequest.to_json()) + +# convert the object into a dict +authenticator_static_stage_request_dict = authenticator_static_stage_request_instance.to_dict() +# create an instance of AuthenticatorStaticStageRequest from a dict +authenticator_static_stage_request_from_dict = AuthenticatorStaticStageRequest.from_dict(authenticator_static_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorTOTPChallenge.md b/docs/AuthenticatorTOTPChallenge.md new file mode 100644 index 000000000..e0c43224d --- /dev/null +++ b/docs/AuthenticatorTOTPChallenge.md @@ -0,0 +1,35 @@ +# AuthenticatorTOTPChallenge + +TOTP Setup challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-totp'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**config_url** | **str** | | + +## Example + +```python +from authentik_client.models.authenticator_totp_challenge import AuthenticatorTOTPChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorTOTPChallenge from a JSON string +authenticator_totp_challenge_instance = AuthenticatorTOTPChallenge.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorTOTPChallenge.to_json()) + +# convert the object into a dict +authenticator_totp_challenge_dict = authenticator_totp_challenge_instance.to_dict() +# create an instance of AuthenticatorTOTPChallenge from a dict +authenticator_totp_challenge_from_dict = AuthenticatorTOTPChallenge.from_dict(authenticator_totp_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorTOTPChallengeResponseRequest.md b/docs/AuthenticatorTOTPChallengeResponseRequest.md new file mode 100644 index 000000000..d2ede2328 --- /dev/null +++ b/docs/AuthenticatorTOTPChallengeResponseRequest.md @@ -0,0 +1,31 @@ +# AuthenticatorTOTPChallengeResponseRequest + +TOTP Challenge response, device is set by get_response_instance + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-totp'] +**code** | **str** | | + +## Example + +```python +from authentik_client.models.authenticator_totp_challenge_response_request import AuthenticatorTOTPChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorTOTPChallengeResponseRequest from a JSON string +authenticator_totp_challenge_response_request_instance = AuthenticatorTOTPChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorTOTPChallengeResponseRequest.to_json()) + +# convert the object into a dict +authenticator_totp_challenge_response_request_dict = authenticator_totp_challenge_response_request_instance.to_dict() +# create an instance of AuthenticatorTOTPChallengeResponseRequest from a dict +authenticator_totp_challenge_response_request_from_dict = AuthenticatorTOTPChallengeResponseRequest.from_dict(authenticator_totp_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorTOTPStage.md b/docs/AuthenticatorTOTPStage.md new file mode 100644 index 000000000..5a52ecbb1 --- /dev/null +++ b/docs/AuthenticatorTOTPStage.md @@ -0,0 +1,39 @@ +# AuthenticatorTOTPStage + +AuthenticatorTOTPStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**digits** | [**DigitsEnum**](DigitsEnum.md) | | + +## Example + +```python +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorTOTPStage from a JSON string +authenticator_totp_stage_instance = AuthenticatorTOTPStage.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorTOTPStage.to_json()) + +# convert the object into a dict +authenticator_totp_stage_dict = authenticator_totp_stage_instance.to_dict() +# create an instance of AuthenticatorTOTPStage from a dict +authenticator_totp_stage_from_dict = AuthenticatorTOTPStage.from_dict(authenticator_totp_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorTOTPStageRequest.md b/docs/AuthenticatorTOTPStageRequest.md new file mode 100644 index 000000000..f7c0aa7b8 --- /dev/null +++ b/docs/AuthenticatorTOTPStageRequest.md @@ -0,0 +1,33 @@ +# AuthenticatorTOTPStageRequest + +AuthenticatorTOTPStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**digits** | [**DigitsEnum**](DigitsEnum.md) | | + +## Example + +```python +from authentik_client.models.authenticator_totp_stage_request import AuthenticatorTOTPStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorTOTPStageRequest from a JSON string +authenticator_totp_stage_request_instance = AuthenticatorTOTPStageRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorTOTPStageRequest.to_json()) + +# convert the object into a dict +authenticator_totp_stage_request_dict = authenticator_totp_stage_request_instance.to_dict() +# create an instance of AuthenticatorTOTPStageRequest from a dict +authenticator_totp_stage_request_from_dict = AuthenticatorTOTPStageRequest.from_dict(authenticator_totp_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorValidateStage.md b/docs/AuthenticatorValidateStage.md new file mode 100644 index 000000000..5aaa95a8a --- /dev/null +++ b/docs/AuthenticatorValidateStage.md @@ -0,0 +1,48 @@ +# AuthenticatorValidateStage + +AuthenticatorValidateStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**not_configured_action** | [**NotConfiguredActionEnum**](NotConfiguredActionEnum.md) | | [optional] +**device_classes** | [**List[DeviceClassesEnum]**](DeviceClassesEnum.md) | Device classes which can be used to authenticate | [optional] +**configuration_stages** | **List[UUID]** | Stages used to configure Authenticator when user doesn't have any compatible devices. After this configuration Stage passes, the user is not prompted again. | [optional] +**last_auth_threshold** | **str** | If any of the user's device has been used within this threshold, this stage will be skipped | [optional] +**webauthn_user_verification** | [**UserVerificationEnum**](UserVerificationEnum.md) | Enforce user verification for WebAuthn devices. | [optional] +**webauthn_hints** | [**List[WebAuthnHintEnum]**](WebAuthnHintEnum.md) | | [optional] +**webauthn_allowed_device_types** | **List[UUID]** | | [optional] +**webauthn_allowed_device_types_obj** | [**List[WebAuthnDeviceType]**](WebAuthnDeviceType.md) | | [readonly] +**email_otp_throttling_factor** | **float** | | [optional] +**sms_otp_throttling_factor** | **float** | | [optional] +**totp_otp_throttling_factor** | **float** | | [optional] +**static_otp_throttling_factor** | **float** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorValidateStage from a JSON string +authenticator_validate_stage_instance = AuthenticatorValidateStage.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorValidateStage.to_json()) + +# convert the object into a dict +authenticator_validate_stage_dict = authenticator_validate_stage_instance.to_dict() +# create an instance of AuthenticatorValidateStage from a dict +authenticator_validate_stage_from_dict = AuthenticatorValidateStage.from_dict(authenticator_validate_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorValidateStageRequest.md b/docs/AuthenticatorValidateStageRequest.md new file mode 100644 index 000000000..b86f30a3a --- /dev/null +++ b/docs/AuthenticatorValidateStageRequest.md @@ -0,0 +1,41 @@ +# AuthenticatorValidateStageRequest + +AuthenticatorValidateStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**not_configured_action** | [**NotConfiguredActionEnum**](NotConfiguredActionEnum.md) | | [optional] +**device_classes** | [**List[DeviceClassesEnum]**](DeviceClassesEnum.md) | Device classes which can be used to authenticate | [optional] +**configuration_stages** | **List[UUID]** | Stages used to configure Authenticator when user doesn't have any compatible devices. After this configuration Stage passes, the user is not prompted again. | [optional] +**last_auth_threshold** | **str** | If any of the user's device has been used within this threshold, this stage will be skipped | [optional] +**webauthn_user_verification** | [**UserVerificationEnum**](UserVerificationEnum.md) | Enforce user verification for WebAuthn devices. | [optional] +**webauthn_hints** | [**List[WebAuthnHintEnum]**](WebAuthnHintEnum.md) | | [optional] +**webauthn_allowed_device_types** | **List[UUID]** | | [optional] +**email_otp_throttling_factor** | **float** | | [optional] +**sms_otp_throttling_factor** | **float** | | [optional] +**totp_otp_throttling_factor** | **float** | | [optional] +**static_otp_throttling_factor** | **float** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_validate_stage_request import AuthenticatorValidateStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorValidateStageRequest from a JSON string +authenticator_validate_stage_request_instance = AuthenticatorValidateStageRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorValidateStageRequest.to_json()) + +# convert the object into a dict +authenticator_validate_stage_request_dict = authenticator_validate_stage_request_instance.to_dict() +# create an instance of AuthenticatorValidateStageRequest from a dict +authenticator_validate_stage_request_from_dict = AuthenticatorValidateStageRequest.from_dict(authenticator_validate_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorValidationChallenge.md b/docs/AuthenticatorValidationChallenge.md new file mode 100644 index 000000000..885b2ac0a --- /dev/null +++ b/docs/AuthenticatorValidationChallenge.md @@ -0,0 +1,36 @@ +# AuthenticatorValidationChallenge + +Authenticator challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-validate'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**device_challenges** | [**List[DeviceChallenge]**](DeviceChallenge.md) | | +**configuration_stages** | [**List[SelectableStage]**](SelectableStage.md) | | + +## Example + +```python +from authentik_client.models.authenticator_validation_challenge import AuthenticatorValidationChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorValidationChallenge from a JSON string +authenticator_validation_challenge_instance = AuthenticatorValidationChallenge.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorValidationChallenge.to_json()) + +# convert the object into a dict +authenticator_validation_challenge_dict = authenticator_validation_challenge_instance.to_dict() +# create an instance of AuthenticatorValidationChallenge from a dict +authenticator_validation_challenge_from_dict = AuthenticatorValidationChallenge.from_dict(authenticator_validation_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorValidationChallengeResponseRequest.md b/docs/AuthenticatorValidationChallengeResponseRequest.md new file mode 100644 index 000000000..6cb4c5bcf --- /dev/null +++ b/docs/AuthenticatorValidationChallengeResponseRequest.md @@ -0,0 +1,35 @@ +# AuthenticatorValidationChallengeResponseRequest + +Challenge used for Code-based and WebAuthn authenticators + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-validate'] +**selected_challenge** | [**DeviceChallengeRequest**](DeviceChallengeRequest.md) | | [optional] +**selected_stage** | **str** | | [optional] +**code** | **str** | | [optional] +**webauthn** | **Dict[str, object]** | | [optional] +**duo** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_validation_challenge_response_request import AuthenticatorValidationChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorValidationChallengeResponseRequest from a JSON string +authenticator_validation_challenge_response_request_instance = AuthenticatorValidationChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorValidationChallengeResponseRequest.to_json()) + +# convert the object into a dict +authenticator_validation_challenge_response_request_dict = authenticator_validation_challenge_response_request_instance.to_dict() +# create an instance of AuthenticatorValidationChallengeResponseRequest from a dict +authenticator_validation_challenge_response_request_from_dict = AuthenticatorValidationChallengeResponseRequest.from_dict(authenticator_validation_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorWebAuthnChallenge.md b/docs/AuthenticatorWebAuthnChallenge.md new file mode 100644 index 000000000..51c723c9a --- /dev/null +++ b/docs/AuthenticatorWebAuthnChallenge.md @@ -0,0 +1,35 @@ +# AuthenticatorWebAuthnChallenge + +WebAuthn Challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-webauthn'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**registration** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.authenticator_web_authn_challenge import AuthenticatorWebAuthnChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorWebAuthnChallenge from a JSON string +authenticator_web_authn_challenge_instance = AuthenticatorWebAuthnChallenge.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorWebAuthnChallenge.to_json()) + +# convert the object into a dict +authenticator_web_authn_challenge_dict = authenticator_web_authn_challenge_instance.to_dict() +# create an instance of AuthenticatorWebAuthnChallenge from a dict +authenticator_web_authn_challenge_from_dict = AuthenticatorWebAuthnChallenge.from_dict(authenticator_web_authn_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorWebAuthnChallengeResponseRequest.md b/docs/AuthenticatorWebAuthnChallengeResponseRequest.md new file mode 100644 index 000000000..392db88f6 --- /dev/null +++ b/docs/AuthenticatorWebAuthnChallengeResponseRequest.md @@ -0,0 +1,31 @@ +# AuthenticatorWebAuthnChallengeResponseRequest + +WebAuthn Challenge response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-authenticator-webauthn'] +**response** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.authenticator_web_authn_challenge_response_request import AuthenticatorWebAuthnChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorWebAuthnChallengeResponseRequest from a JSON string +authenticator_web_authn_challenge_response_request_instance = AuthenticatorWebAuthnChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorWebAuthnChallengeResponseRequest.to_json()) + +# convert the object into a dict +authenticator_web_authn_challenge_response_request_dict = authenticator_web_authn_challenge_response_request_instance.to_dict() +# create an instance of AuthenticatorWebAuthnChallengeResponseRequest from a dict +authenticator_web_authn_challenge_response_request_from_dict = AuthenticatorWebAuthnChallengeResponseRequest.from_dict(authenticator_web_authn_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorWebAuthnStage.md b/docs/AuthenticatorWebAuthnStage.md new file mode 100644 index 000000000..71ada6a4b --- /dev/null +++ b/docs/AuthenticatorWebAuthnStage.md @@ -0,0 +1,46 @@ +# AuthenticatorWebAuthnStage + +AuthenticatorWebAuthnStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**user_verification** | [**UserVerificationEnum**](UserVerificationEnum.md) | | [optional] +**authenticator_attachment** | [**AuthenticatorAttachmentEnum**](AuthenticatorAttachmentEnum.md) | | [optional] +**resident_key_requirement** | [**UserVerificationEnum**](UserVerificationEnum.md) | | [optional] +**hints** | [**List[WebAuthnHintEnum]**](WebAuthnHintEnum.md) | | [optional] +**device_type_restrictions** | **List[UUID]** | | [optional] +**device_type_restrictions_obj** | [**List[WebAuthnDeviceType]**](WebAuthnDeviceType.md) | | [readonly] +**prevent_duplicate_devices** | **bool** | When enabled, a given device can only be registered once. | [optional] +**max_attempts** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorWebAuthnStage from a JSON string +authenticator_web_authn_stage_instance = AuthenticatorWebAuthnStage.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorWebAuthnStage.to_json()) + +# convert the object into a dict +authenticator_web_authn_stage_dict = authenticator_web_authn_stage_instance.to_dict() +# create an instance of AuthenticatorWebAuthnStage from a dict +authenticator_web_authn_stage_from_dict = AuthenticatorWebAuthnStage.from_dict(authenticator_web_authn_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorWebAuthnStageRequest.md b/docs/AuthenticatorWebAuthnStageRequest.md new file mode 100644 index 000000000..d8e42e9e1 --- /dev/null +++ b/docs/AuthenticatorWebAuthnStageRequest.md @@ -0,0 +1,39 @@ +# AuthenticatorWebAuthnStageRequest + +AuthenticatorWebAuthnStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**user_verification** | [**UserVerificationEnum**](UserVerificationEnum.md) | | [optional] +**authenticator_attachment** | [**AuthenticatorAttachmentEnum**](AuthenticatorAttachmentEnum.md) | | [optional] +**resident_key_requirement** | [**UserVerificationEnum**](UserVerificationEnum.md) | | [optional] +**hints** | [**List[WebAuthnHintEnum]**](WebAuthnHintEnum.md) | | [optional] +**device_type_restrictions** | **List[UUID]** | | [optional] +**prevent_duplicate_devices** | **bool** | When enabled, a given device can only be registered once. | [optional] +**max_attempts** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.authenticator_web_authn_stage_request import AuthenticatorWebAuthnStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AuthenticatorWebAuthnStageRequest from a JSON string +authenticator_web_authn_stage_request_instance = AuthenticatorWebAuthnStageRequest.from_json(json) +# print the JSON string representation of the object +print(AuthenticatorWebAuthnStageRequest.to_json()) + +# convert the object into a dict +authenticator_web_authn_stage_request_dict = authenticator_web_authn_stage_request_instance.to_dict() +# create an instance of AuthenticatorWebAuthnStageRequest from a dict +authenticator_web_authn_stage_request_from_dict = AuthenticatorWebAuthnStageRequest.from_dict(authenticator_web_authn_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AuthenticatorsApi.md b/docs/AuthenticatorsApi.md new file mode 100644 index 000000000..a09298e90 --- /dev/null +++ b/docs/AuthenticatorsApi.md @@ -0,0 +1,6636 @@ +# authentik_client.AuthenticatorsApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**authenticators_admin_all_list**](AuthenticatorsApi.md#authenticators_admin_all_list) | **GET** /authenticators/admin/all/ | +[**authenticators_admin_duo_create**](AuthenticatorsApi.md#authenticators_admin_duo_create) | **POST** /authenticators/admin/duo/ | +[**authenticators_admin_duo_destroy**](AuthenticatorsApi.md#authenticators_admin_duo_destroy) | **DELETE** /authenticators/admin/duo/{id}/ | +[**authenticators_admin_duo_list**](AuthenticatorsApi.md#authenticators_admin_duo_list) | **GET** /authenticators/admin/duo/ | +[**authenticators_admin_duo_partial_update**](AuthenticatorsApi.md#authenticators_admin_duo_partial_update) | **PATCH** /authenticators/admin/duo/{id}/ | +[**authenticators_admin_duo_retrieve**](AuthenticatorsApi.md#authenticators_admin_duo_retrieve) | **GET** /authenticators/admin/duo/{id}/ | +[**authenticators_admin_duo_update**](AuthenticatorsApi.md#authenticators_admin_duo_update) | **PUT** /authenticators/admin/duo/{id}/ | +[**authenticators_admin_email_create**](AuthenticatorsApi.md#authenticators_admin_email_create) | **POST** /authenticators/admin/email/ | +[**authenticators_admin_email_destroy**](AuthenticatorsApi.md#authenticators_admin_email_destroy) | **DELETE** /authenticators/admin/email/{id}/ | +[**authenticators_admin_email_list**](AuthenticatorsApi.md#authenticators_admin_email_list) | **GET** /authenticators/admin/email/ | +[**authenticators_admin_email_partial_update**](AuthenticatorsApi.md#authenticators_admin_email_partial_update) | **PATCH** /authenticators/admin/email/{id}/ | +[**authenticators_admin_email_retrieve**](AuthenticatorsApi.md#authenticators_admin_email_retrieve) | **GET** /authenticators/admin/email/{id}/ | +[**authenticators_admin_email_update**](AuthenticatorsApi.md#authenticators_admin_email_update) | **PUT** /authenticators/admin/email/{id}/ | +[**authenticators_admin_endpoint_create**](AuthenticatorsApi.md#authenticators_admin_endpoint_create) | **POST** /authenticators/admin/endpoint/ | +[**authenticators_admin_endpoint_destroy**](AuthenticatorsApi.md#authenticators_admin_endpoint_destroy) | **DELETE** /authenticators/admin/endpoint/{uuid}/ | +[**authenticators_admin_endpoint_list**](AuthenticatorsApi.md#authenticators_admin_endpoint_list) | **GET** /authenticators/admin/endpoint/ | +[**authenticators_admin_endpoint_partial_update**](AuthenticatorsApi.md#authenticators_admin_endpoint_partial_update) | **PATCH** /authenticators/admin/endpoint/{uuid}/ | +[**authenticators_admin_endpoint_retrieve**](AuthenticatorsApi.md#authenticators_admin_endpoint_retrieve) | **GET** /authenticators/admin/endpoint/{uuid}/ | +[**authenticators_admin_endpoint_update**](AuthenticatorsApi.md#authenticators_admin_endpoint_update) | **PUT** /authenticators/admin/endpoint/{uuid}/ | +[**authenticators_admin_sms_create**](AuthenticatorsApi.md#authenticators_admin_sms_create) | **POST** /authenticators/admin/sms/ | +[**authenticators_admin_sms_destroy**](AuthenticatorsApi.md#authenticators_admin_sms_destroy) | **DELETE** /authenticators/admin/sms/{id}/ | +[**authenticators_admin_sms_list**](AuthenticatorsApi.md#authenticators_admin_sms_list) | **GET** /authenticators/admin/sms/ | +[**authenticators_admin_sms_partial_update**](AuthenticatorsApi.md#authenticators_admin_sms_partial_update) | **PATCH** /authenticators/admin/sms/{id}/ | +[**authenticators_admin_sms_retrieve**](AuthenticatorsApi.md#authenticators_admin_sms_retrieve) | **GET** /authenticators/admin/sms/{id}/ | +[**authenticators_admin_sms_update**](AuthenticatorsApi.md#authenticators_admin_sms_update) | **PUT** /authenticators/admin/sms/{id}/ | +[**authenticators_admin_static_create**](AuthenticatorsApi.md#authenticators_admin_static_create) | **POST** /authenticators/admin/static/ | +[**authenticators_admin_static_destroy**](AuthenticatorsApi.md#authenticators_admin_static_destroy) | **DELETE** /authenticators/admin/static/{id}/ | +[**authenticators_admin_static_list**](AuthenticatorsApi.md#authenticators_admin_static_list) | **GET** /authenticators/admin/static/ | +[**authenticators_admin_static_partial_update**](AuthenticatorsApi.md#authenticators_admin_static_partial_update) | **PATCH** /authenticators/admin/static/{id}/ | +[**authenticators_admin_static_retrieve**](AuthenticatorsApi.md#authenticators_admin_static_retrieve) | **GET** /authenticators/admin/static/{id}/ | +[**authenticators_admin_static_update**](AuthenticatorsApi.md#authenticators_admin_static_update) | **PUT** /authenticators/admin/static/{id}/ | +[**authenticators_admin_totp_create**](AuthenticatorsApi.md#authenticators_admin_totp_create) | **POST** /authenticators/admin/totp/ | +[**authenticators_admin_totp_destroy**](AuthenticatorsApi.md#authenticators_admin_totp_destroy) | **DELETE** /authenticators/admin/totp/{id}/ | +[**authenticators_admin_totp_list**](AuthenticatorsApi.md#authenticators_admin_totp_list) | **GET** /authenticators/admin/totp/ | +[**authenticators_admin_totp_partial_update**](AuthenticatorsApi.md#authenticators_admin_totp_partial_update) | **PATCH** /authenticators/admin/totp/{id}/ | +[**authenticators_admin_totp_retrieve**](AuthenticatorsApi.md#authenticators_admin_totp_retrieve) | **GET** /authenticators/admin/totp/{id}/ | +[**authenticators_admin_totp_update**](AuthenticatorsApi.md#authenticators_admin_totp_update) | **PUT** /authenticators/admin/totp/{id}/ | +[**authenticators_admin_webauthn_create**](AuthenticatorsApi.md#authenticators_admin_webauthn_create) | **POST** /authenticators/admin/webauthn/ | +[**authenticators_admin_webauthn_destroy**](AuthenticatorsApi.md#authenticators_admin_webauthn_destroy) | **DELETE** /authenticators/admin/webauthn/{id}/ | +[**authenticators_admin_webauthn_list**](AuthenticatorsApi.md#authenticators_admin_webauthn_list) | **GET** /authenticators/admin/webauthn/ | +[**authenticators_admin_webauthn_partial_update**](AuthenticatorsApi.md#authenticators_admin_webauthn_partial_update) | **PATCH** /authenticators/admin/webauthn/{id}/ | +[**authenticators_admin_webauthn_retrieve**](AuthenticatorsApi.md#authenticators_admin_webauthn_retrieve) | **GET** /authenticators/admin/webauthn/{id}/ | +[**authenticators_admin_webauthn_update**](AuthenticatorsApi.md#authenticators_admin_webauthn_update) | **PUT** /authenticators/admin/webauthn/{id}/ | +[**authenticators_all_list**](AuthenticatorsApi.md#authenticators_all_list) | **GET** /authenticators/all/ | +[**authenticators_duo_destroy**](AuthenticatorsApi.md#authenticators_duo_destroy) | **DELETE** /authenticators/duo/{id}/ | +[**authenticators_duo_list**](AuthenticatorsApi.md#authenticators_duo_list) | **GET** /authenticators/duo/ | +[**authenticators_duo_partial_update**](AuthenticatorsApi.md#authenticators_duo_partial_update) | **PATCH** /authenticators/duo/{id}/ | +[**authenticators_duo_retrieve**](AuthenticatorsApi.md#authenticators_duo_retrieve) | **GET** /authenticators/duo/{id}/ | +[**authenticators_duo_update**](AuthenticatorsApi.md#authenticators_duo_update) | **PUT** /authenticators/duo/{id}/ | +[**authenticators_duo_used_by_list**](AuthenticatorsApi.md#authenticators_duo_used_by_list) | **GET** /authenticators/duo/{id}/used_by/ | +[**authenticators_email_destroy**](AuthenticatorsApi.md#authenticators_email_destroy) | **DELETE** /authenticators/email/{id}/ | +[**authenticators_email_list**](AuthenticatorsApi.md#authenticators_email_list) | **GET** /authenticators/email/ | +[**authenticators_email_partial_update**](AuthenticatorsApi.md#authenticators_email_partial_update) | **PATCH** /authenticators/email/{id}/ | +[**authenticators_email_retrieve**](AuthenticatorsApi.md#authenticators_email_retrieve) | **GET** /authenticators/email/{id}/ | +[**authenticators_email_update**](AuthenticatorsApi.md#authenticators_email_update) | **PUT** /authenticators/email/{id}/ | +[**authenticators_email_used_by_list**](AuthenticatorsApi.md#authenticators_email_used_by_list) | **GET** /authenticators/email/{id}/used_by/ | +[**authenticators_endpoint_list**](AuthenticatorsApi.md#authenticators_endpoint_list) | **GET** /authenticators/endpoint/ | +[**authenticators_endpoint_retrieve**](AuthenticatorsApi.md#authenticators_endpoint_retrieve) | **GET** /authenticators/endpoint/{uuid}/ | +[**authenticators_endpoint_used_by_list**](AuthenticatorsApi.md#authenticators_endpoint_used_by_list) | **GET** /authenticators/endpoint/{uuid}/used_by/ | +[**authenticators_sms_destroy**](AuthenticatorsApi.md#authenticators_sms_destroy) | **DELETE** /authenticators/sms/{id}/ | +[**authenticators_sms_list**](AuthenticatorsApi.md#authenticators_sms_list) | **GET** /authenticators/sms/ | +[**authenticators_sms_partial_update**](AuthenticatorsApi.md#authenticators_sms_partial_update) | **PATCH** /authenticators/sms/{id}/ | +[**authenticators_sms_retrieve**](AuthenticatorsApi.md#authenticators_sms_retrieve) | **GET** /authenticators/sms/{id}/ | +[**authenticators_sms_update**](AuthenticatorsApi.md#authenticators_sms_update) | **PUT** /authenticators/sms/{id}/ | +[**authenticators_sms_used_by_list**](AuthenticatorsApi.md#authenticators_sms_used_by_list) | **GET** /authenticators/sms/{id}/used_by/ | +[**authenticators_static_destroy**](AuthenticatorsApi.md#authenticators_static_destroy) | **DELETE** /authenticators/static/{id}/ | +[**authenticators_static_list**](AuthenticatorsApi.md#authenticators_static_list) | **GET** /authenticators/static/ | +[**authenticators_static_partial_update**](AuthenticatorsApi.md#authenticators_static_partial_update) | **PATCH** /authenticators/static/{id}/ | +[**authenticators_static_retrieve**](AuthenticatorsApi.md#authenticators_static_retrieve) | **GET** /authenticators/static/{id}/ | +[**authenticators_static_update**](AuthenticatorsApi.md#authenticators_static_update) | **PUT** /authenticators/static/{id}/ | +[**authenticators_static_used_by_list**](AuthenticatorsApi.md#authenticators_static_used_by_list) | **GET** /authenticators/static/{id}/used_by/ | +[**authenticators_totp_destroy**](AuthenticatorsApi.md#authenticators_totp_destroy) | **DELETE** /authenticators/totp/{id}/ | +[**authenticators_totp_list**](AuthenticatorsApi.md#authenticators_totp_list) | **GET** /authenticators/totp/ | +[**authenticators_totp_partial_update**](AuthenticatorsApi.md#authenticators_totp_partial_update) | **PATCH** /authenticators/totp/{id}/ | +[**authenticators_totp_retrieve**](AuthenticatorsApi.md#authenticators_totp_retrieve) | **GET** /authenticators/totp/{id}/ | +[**authenticators_totp_update**](AuthenticatorsApi.md#authenticators_totp_update) | **PUT** /authenticators/totp/{id}/ | +[**authenticators_totp_used_by_list**](AuthenticatorsApi.md#authenticators_totp_used_by_list) | **GET** /authenticators/totp/{id}/used_by/ | +[**authenticators_webauthn_destroy**](AuthenticatorsApi.md#authenticators_webauthn_destroy) | **DELETE** /authenticators/webauthn/{id}/ | +[**authenticators_webauthn_list**](AuthenticatorsApi.md#authenticators_webauthn_list) | **GET** /authenticators/webauthn/ | +[**authenticators_webauthn_partial_update**](AuthenticatorsApi.md#authenticators_webauthn_partial_update) | **PATCH** /authenticators/webauthn/{id}/ | +[**authenticators_webauthn_retrieve**](AuthenticatorsApi.md#authenticators_webauthn_retrieve) | **GET** /authenticators/webauthn/{id}/ | +[**authenticators_webauthn_update**](AuthenticatorsApi.md#authenticators_webauthn_update) | **PUT** /authenticators/webauthn/{id}/ | +[**authenticators_webauthn_used_by_list**](AuthenticatorsApi.md#authenticators_webauthn_used_by_list) | **GET** /authenticators/webauthn/{id}/used_by/ | + + +# **authenticators_admin_all_list** +> List[Device] authenticators_admin_all_list(user=user) + +Get all devices for current user + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device import Device +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + user = 56 # int | (optional) + + try: + api_response = api_instance.authenticators_admin_all_list(user=user) + print("The response of AuthenticatorsApi->authenticators_admin_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_all_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user** | **int**| | [optional] + +### Return type + +[**List[Device]**](Device.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_duo_create** +> DuoDevice authenticators_admin_duo_create(duo_device_request) + +Viewset for Duo authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.duo_device import DuoDevice +from authentik_client.models.duo_device_request import DuoDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + duo_device_request = authentik_client.DuoDeviceRequest() # DuoDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_duo_create(duo_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_duo_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_duo_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **duo_device_request** | [**DuoDeviceRequest**](DuoDeviceRequest.md)| | + +### Return type + +[**DuoDevice**](DuoDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_duo_destroy** +> authenticators_admin_duo_destroy(id) + +Viewset for Duo authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Duo Device. + + try: + api_instance.authenticators_admin_duo_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_duo_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Duo Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_duo_list** +> PaginatedDuoDeviceList authenticators_admin_duo_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for Duo authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_duo_device_list import PaginatedDuoDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_admin_duo_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_admin_duo_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_duo_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedDuoDeviceList**](PaginatedDuoDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_duo_partial_update** +> DuoDevice authenticators_admin_duo_partial_update(id, patched_duo_device_request=patched_duo_device_request) + +Viewset for Duo authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.duo_device import DuoDevice +from authentik_client.models.patched_duo_device_request import PatchedDuoDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Duo Device. + patched_duo_device_request = authentik_client.PatchedDuoDeviceRequest() # PatchedDuoDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_admin_duo_partial_update(id, patched_duo_device_request=patched_duo_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_duo_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_duo_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Duo Device. | + **patched_duo_device_request** | [**PatchedDuoDeviceRequest**](PatchedDuoDeviceRequest.md)| | [optional] + +### Return type + +[**DuoDevice**](DuoDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_duo_retrieve** +> DuoDevice authenticators_admin_duo_retrieve(id) + +Viewset for Duo authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.duo_device import DuoDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Duo Device. + + try: + api_response = api_instance.authenticators_admin_duo_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_admin_duo_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_duo_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Duo Device. | + +### Return type + +[**DuoDevice**](DuoDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_duo_update** +> DuoDevice authenticators_admin_duo_update(id, duo_device_request) + +Viewset for Duo authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.duo_device import DuoDevice +from authentik_client.models.duo_device_request import DuoDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Duo Device. + duo_device_request = authentik_client.DuoDeviceRequest() # DuoDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_duo_update(id, duo_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_duo_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_duo_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Duo Device. | + **duo_device_request** | [**DuoDeviceRequest**](DuoDeviceRequest.md)| | + +### Return type + +[**DuoDevice**](DuoDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_email_create** +> EmailDevice authenticators_admin_email_create(email_device_request) + +Viewset for email authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_device import EmailDevice +from authentik_client.models.email_device_request import EmailDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + email_device_request = authentik_client.EmailDeviceRequest() # EmailDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_email_create(email_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_email_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_email_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **email_device_request** | [**EmailDeviceRequest**](EmailDeviceRequest.md)| | + +### Return type + +[**EmailDevice**](EmailDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_email_destroy** +> authenticators_admin_email_destroy(id) + +Viewset for email authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Email Device. + + try: + api_instance.authenticators_admin_email_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_email_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Email Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_email_list** +> PaginatedEmailDeviceList authenticators_admin_email_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for email authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_email_device_list import PaginatedEmailDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_admin_email_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_admin_email_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_email_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedEmailDeviceList**](PaginatedEmailDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_email_partial_update** +> EmailDevice authenticators_admin_email_partial_update(id, patched_email_device_request=patched_email_device_request) + +Viewset for email authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_device import EmailDevice +from authentik_client.models.patched_email_device_request import PatchedEmailDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Email Device. + patched_email_device_request = authentik_client.PatchedEmailDeviceRequest() # PatchedEmailDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_admin_email_partial_update(id, patched_email_device_request=patched_email_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_email_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_email_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Email Device. | + **patched_email_device_request** | [**PatchedEmailDeviceRequest**](PatchedEmailDeviceRequest.md)| | [optional] + +### Return type + +[**EmailDevice**](EmailDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_email_retrieve** +> EmailDevice authenticators_admin_email_retrieve(id) + +Viewset for email authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_device import EmailDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Email Device. + + try: + api_response = api_instance.authenticators_admin_email_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_admin_email_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_email_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Email Device. | + +### Return type + +[**EmailDevice**](EmailDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_email_update** +> EmailDevice authenticators_admin_email_update(id, email_device_request) + +Viewset for email authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_device import EmailDevice +from authentik_client.models.email_device_request import EmailDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Email Device. + email_device_request = authentik_client.EmailDeviceRequest() # EmailDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_email_update(id, email_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_email_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_email_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Email Device. | + **email_device_request** | [**EmailDeviceRequest**](EmailDeviceRequest.md)| | + +### Return type + +[**EmailDevice**](EmailDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_endpoint_create** +> GoogleEndpointDevice authenticators_admin_endpoint_create(google_endpoint_device_request) + +Viewset for Endpoint authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice +from authentik_client.models.google_endpoint_device_request import GoogleEndpointDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + google_endpoint_device_request = authentik_client.GoogleEndpointDeviceRequest() # GoogleEndpointDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_endpoint_create(google_endpoint_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_endpoint_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_endpoint_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **google_endpoint_device_request** | [**GoogleEndpointDeviceRequest**](GoogleEndpointDeviceRequest.md)| | + +### Return type + +[**GoogleEndpointDevice**](GoogleEndpointDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_endpoint_destroy** +> authenticators_admin_endpoint_destroy(uuid) + +Viewset for Endpoint authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Device. + + try: + api_instance.authenticators_admin_endpoint_destroy(uuid) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_endpoint_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Endpoint Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_endpoint_list** +> PaginatedGoogleEndpointDeviceList authenticators_admin_endpoint_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for Endpoint authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_google_endpoint_device_list import PaginatedGoogleEndpointDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_admin_endpoint_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_admin_endpoint_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_endpoint_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedGoogleEndpointDeviceList**](PaginatedGoogleEndpointDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_endpoint_partial_update** +> GoogleEndpointDevice authenticators_admin_endpoint_partial_update(uuid, patched_google_endpoint_device_request=patched_google_endpoint_device_request) + +Viewset for Endpoint authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice +from authentik_client.models.patched_google_endpoint_device_request import PatchedGoogleEndpointDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Device. + patched_google_endpoint_device_request = authentik_client.PatchedGoogleEndpointDeviceRequest() # PatchedGoogleEndpointDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_admin_endpoint_partial_update(uuid, patched_google_endpoint_device_request=patched_google_endpoint_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_endpoint_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_endpoint_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Endpoint Device. | + **patched_google_endpoint_device_request** | [**PatchedGoogleEndpointDeviceRequest**](PatchedGoogleEndpointDeviceRequest.md)| | [optional] + +### Return type + +[**GoogleEndpointDevice**](GoogleEndpointDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_endpoint_retrieve** +> GoogleEndpointDevice authenticators_admin_endpoint_retrieve(uuid) + +Viewset for Endpoint authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Device. + + try: + api_response = api_instance.authenticators_admin_endpoint_retrieve(uuid) + print("The response of AuthenticatorsApi->authenticators_admin_endpoint_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_endpoint_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Endpoint Device. | + +### Return type + +[**GoogleEndpointDevice**](GoogleEndpointDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_endpoint_update** +> GoogleEndpointDevice authenticators_admin_endpoint_update(uuid, google_endpoint_device_request) + +Viewset for Endpoint authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice +from authentik_client.models.google_endpoint_device_request import GoogleEndpointDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Device. + google_endpoint_device_request = authentik_client.GoogleEndpointDeviceRequest() # GoogleEndpointDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_endpoint_update(uuid, google_endpoint_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_endpoint_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_endpoint_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Endpoint Device. | + **google_endpoint_device_request** | [**GoogleEndpointDeviceRequest**](GoogleEndpointDeviceRequest.md)| | + +### Return type + +[**GoogleEndpointDevice**](GoogleEndpointDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_sms_create** +> SMSDevice authenticators_admin_sms_create(sms_device_request) + +Viewset for sms authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sms_device import SMSDevice +from authentik_client.models.sms_device_request import SMSDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + sms_device_request = authentik_client.SMSDeviceRequest() # SMSDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_sms_create(sms_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_sms_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_sms_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **sms_device_request** | [**SMSDeviceRequest**](SMSDeviceRequest.md)| | + +### Return type + +[**SMSDevice**](SMSDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_sms_destroy** +> authenticators_admin_sms_destroy(id) + +Viewset for sms authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this SMS Device. + + try: + api_instance.authenticators_admin_sms_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_sms_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SMS Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_sms_list** +> PaginatedSMSDeviceList authenticators_admin_sms_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for sms authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_sms_device_list import PaginatedSMSDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_admin_sms_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_admin_sms_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_sms_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedSMSDeviceList**](PaginatedSMSDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_sms_partial_update** +> SMSDevice authenticators_admin_sms_partial_update(id, patched_sms_device_request=patched_sms_device_request) + +Viewset for sms authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_sms_device_request import PatchedSMSDeviceRequest +from authentik_client.models.sms_device import SMSDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this SMS Device. + patched_sms_device_request = authentik_client.PatchedSMSDeviceRequest() # PatchedSMSDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_admin_sms_partial_update(id, patched_sms_device_request=patched_sms_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_sms_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_sms_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SMS Device. | + **patched_sms_device_request** | [**PatchedSMSDeviceRequest**](PatchedSMSDeviceRequest.md)| | [optional] + +### Return type + +[**SMSDevice**](SMSDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_sms_retrieve** +> SMSDevice authenticators_admin_sms_retrieve(id) + +Viewset for sms authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sms_device import SMSDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this SMS Device. + + try: + api_response = api_instance.authenticators_admin_sms_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_admin_sms_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_sms_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SMS Device. | + +### Return type + +[**SMSDevice**](SMSDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_sms_update** +> SMSDevice authenticators_admin_sms_update(id, sms_device_request) + +Viewset for sms authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sms_device import SMSDevice +from authentik_client.models.sms_device_request import SMSDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this SMS Device. + sms_device_request = authentik_client.SMSDeviceRequest() # SMSDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_sms_update(id, sms_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_sms_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_sms_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SMS Device. | + **sms_device_request** | [**SMSDeviceRequest**](SMSDeviceRequest.md)| | + +### Return type + +[**SMSDevice**](SMSDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_static_create** +> StaticDevice authenticators_admin_static_create(static_device_request) + +Viewset for static authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.static_device import StaticDevice +from authentik_client.models.static_device_request import StaticDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + static_device_request = authentik_client.StaticDeviceRequest() # StaticDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_static_create(static_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_static_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_static_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **static_device_request** | [**StaticDeviceRequest**](StaticDeviceRequest.md)| | + +### Return type + +[**StaticDevice**](StaticDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_static_destroy** +> authenticators_admin_static_destroy(id) + +Viewset for static authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Static Device. + + try: + api_instance.authenticators_admin_static_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_static_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Static Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_static_list** +> PaginatedStaticDeviceList authenticators_admin_static_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for static authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_static_device_list import PaginatedStaticDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_admin_static_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_admin_static_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_static_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedStaticDeviceList**](PaginatedStaticDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_static_partial_update** +> StaticDevice authenticators_admin_static_partial_update(id, patched_static_device_request=patched_static_device_request) + +Viewset for static authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_static_device_request import PatchedStaticDeviceRequest +from authentik_client.models.static_device import StaticDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Static Device. + patched_static_device_request = authentik_client.PatchedStaticDeviceRequest() # PatchedStaticDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_admin_static_partial_update(id, patched_static_device_request=patched_static_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_static_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_static_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Static Device. | + **patched_static_device_request** | [**PatchedStaticDeviceRequest**](PatchedStaticDeviceRequest.md)| | [optional] + +### Return type + +[**StaticDevice**](StaticDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_static_retrieve** +> StaticDevice authenticators_admin_static_retrieve(id) + +Viewset for static authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.static_device import StaticDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Static Device. + + try: + api_response = api_instance.authenticators_admin_static_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_admin_static_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_static_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Static Device. | + +### Return type + +[**StaticDevice**](StaticDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_static_update** +> StaticDevice authenticators_admin_static_update(id, static_device_request) + +Viewset for static authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.static_device import StaticDevice +from authentik_client.models.static_device_request import StaticDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Static Device. + static_device_request = authentik_client.StaticDeviceRequest() # StaticDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_static_update(id, static_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_static_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_static_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Static Device. | + **static_device_request** | [**StaticDeviceRequest**](StaticDeviceRequest.md)| | + +### Return type + +[**StaticDevice**](StaticDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_totp_create** +> TOTPDevice authenticators_admin_totp_create(totp_device_request) + +Viewset for totp authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.totp_device import TOTPDevice +from authentik_client.models.totp_device_request import TOTPDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + totp_device_request = authentik_client.TOTPDeviceRequest() # TOTPDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_totp_create(totp_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_totp_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_totp_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **totp_device_request** | [**TOTPDeviceRequest**](TOTPDeviceRequest.md)| | + +### Return type + +[**TOTPDevice**](TOTPDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_totp_destroy** +> authenticators_admin_totp_destroy(id) + +Viewset for totp authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this TOTP Device. + + try: + api_instance.authenticators_admin_totp_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_totp_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this TOTP Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_totp_list** +> PaginatedTOTPDeviceList authenticators_admin_totp_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for totp authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_totp_device_list import PaginatedTOTPDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_admin_totp_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_admin_totp_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_totp_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedTOTPDeviceList**](PaginatedTOTPDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_totp_partial_update** +> TOTPDevice authenticators_admin_totp_partial_update(id, patched_totp_device_request=patched_totp_device_request) + +Viewset for totp authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_totp_device_request import PatchedTOTPDeviceRequest +from authentik_client.models.totp_device import TOTPDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this TOTP Device. + patched_totp_device_request = authentik_client.PatchedTOTPDeviceRequest() # PatchedTOTPDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_admin_totp_partial_update(id, patched_totp_device_request=patched_totp_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_totp_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_totp_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this TOTP Device. | + **patched_totp_device_request** | [**PatchedTOTPDeviceRequest**](PatchedTOTPDeviceRequest.md)| | [optional] + +### Return type + +[**TOTPDevice**](TOTPDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_totp_retrieve** +> TOTPDevice authenticators_admin_totp_retrieve(id) + +Viewset for totp authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.totp_device import TOTPDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this TOTP Device. + + try: + api_response = api_instance.authenticators_admin_totp_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_admin_totp_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_totp_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this TOTP Device. | + +### Return type + +[**TOTPDevice**](TOTPDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_totp_update** +> TOTPDevice authenticators_admin_totp_update(id, totp_device_request) + +Viewset for totp authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.totp_device import TOTPDevice +from authentik_client.models.totp_device_request import TOTPDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this TOTP Device. + totp_device_request = authentik_client.TOTPDeviceRequest() # TOTPDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_totp_update(id, totp_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_totp_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_totp_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this TOTP Device. | + **totp_device_request** | [**TOTPDeviceRequest**](TOTPDeviceRequest.md)| | + +### Return type + +[**TOTPDevice**](TOTPDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_webauthn_create** +> WebAuthnDevice authenticators_admin_webauthn_create(web_authn_device_request) + +Viewset for WebAuthn authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.web_authn_device import WebAuthnDevice +from authentik_client.models.web_authn_device_request import WebAuthnDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + web_authn_device_request = authentik_client.WebAuthnDeviceRequest() # WebAuthnDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_webauthn_create(web_authn_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_webauthn_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_webauthn_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **web_authn_device_request** | [**WebAuthnDeviceRequest**](WebAuthnDeviceRequest.md)| | + +### Return type + +[**WebAuthnDevice**](WebAuthnDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_webauthn_destroy** +> authenticators_admin_webauthn_destroy(id) + +Viewset for WebAuthn authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this WebAuthn Device. + + try: + api_instance.authenticators_admin_webauthn_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_webauthn_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WebAuthn Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_webauthn_list** +> PaginatedWebAuthnDeviceList authenticators_admin_webauthn_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for WebAuthn authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_web_authn_device_list import PaginatedWebAuthnDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_admin_webauthn_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_admin_webauthn_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_webauthn_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedWebAuthnDeviceList**](PaginatedWebAuthnDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_webauthn_partial_update** +> WebAuthnDevice authenticators_admin_webauthn_partial_update(id, patched_web_authn_device_request=patched_web_authn_device_request) + +Viewset for WebAuthn authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_web_authn_device_request import PatchedWebAuthnDeviceRequest +from authentik_client.models.web_authn_device import WebAuthnDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this WebAuthn Device. + patched_web_authn_device_request = authentik_client.PatchedWebAuthnDeviceRequest() # PatchedWebAuthnDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_admin_webauthn_partial_update(id, patched_web_authn_device_request=patched_web_authn_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_webauthn_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_webauthn_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WebAuthn Device. | + **patched_web_authn_device_request** | [**PatchedWebAuthnDeviceRequest**](PatchedWebAuthnDeviceRequest.md)| | [optional] + +### Return type + +[**WebAuthnDevice**](WebAuthnDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_webauthn_retrieve** +> WebAuthnDevice authenticators_admin_webauthn_retrieve(id) + +Viewset for WebAuthn authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.web_authn_device import WebAuthnDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this WebAuthn Device. + + try: + api_response = api_instance.authenticators_admin_webauthn_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_admin_webauthn_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_webauthn_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WebAuthn Device. | + +### Return type + +[**WebAuthnDevice**](WebAuthnDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_admin_webauthn_update** +> WebAuthnDevice authenticators_admin_webauthn_update(id, web_authn_device_request) + +Viewset for WebAuthn authenticator devices (for admins) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.web_authn_device import WebAuthnDevice +from authentik_client.models.web_authn_device_request import WebAuthnDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this WebAuthn Device. + web_authn_device_request = authentik_client.WebAuthnDeviceRequest() # WebAuthnDeviceRequest | + + try: + api_response = api_instance.authenticators_admin_webauthn_update(id, web_authn_device_request) + print("The response of AuthenticatorsApi->authenticators_admin_webauthn_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_admin_webauthn_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WebAuthn Device. | + **web_authn_device_request** | [**WebAuthnDeviceRequest**](WebAuthnDeviceRequest.md)| | + +### Return type + +[**WebAuthnDevice**](WebAuthnDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_all_list** +> List[Device] authenticators_all_list() + +Get all devices for current user + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device import Device +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + + try: + api_response = api_instance.authenticators_all_list() + print("The response of AuthenticatorsApi->authenticators_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_all_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[Device]**](Device.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_duo_destroy** +> authenticators_duo_destroy(id) + +Viewset for Duo authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Duo Device. + + try: + api_instance.authenticators_duo_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_duo_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Duo Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_duo_list** +> PaginatedDuoDeviceList authenticators_duo_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for Duo authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_duo_device_list import PaginatedDuoDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_duo_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_duo_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_duo_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedDuoDeviceList**](PaginatedDuoDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_duo_partial_update** +> DuoDevice authenticators_duo_partial_update(id, patched_duo_device_request=patched_duo_device_request) + +Viewset for Duo authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.duo_device import DuoDevice +from authentik_client.models.patched_duo_device_request import PatchedDuoDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Duo Device. + patched_duo_device_request = authentik_client.PatchedDuoDeviceRequest() # PatchedDuoDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_duo_partial_update(id, patched_duo_device_request=patched_duo_device_request) + print("The response of AuthenticatorsApi->authenticators_duo_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_duo_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Duo Device. | + **patched_duo_device_request** | [**PatchedDuoDeviceRequest**](PatchedDuoDeviceRequest.md)| | [optional] + +### Return type + +[**DuoDevice**](DuoDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_duo_retrieve** +> DuoDevice authenticators_duo_retrieve(id) + +Viewset for Duo authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.duo_device import DuoDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Duo Device. + + try: + api_response = api_instance.authenticators_duo_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_duo_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_duo_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Duo Device. | + +### Return type + +[**DuoDevice**](DuoDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_duo_update** +> DuoDevice authenticators_duo_update(id, duo_device_request) + +Viewset for Duo authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.duo_device import DuoDevice +from authentik_client.models.duo_device_request import DuoDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Duo Device. + duo_device_request = authentik_client.DuoDeviceRequest() # DuoDeviceRequest | + + try: + api_response = api_instance.authenticators_duo_update(id, duo_device_request) + print("The response of AuthenticatorsApi->authenticators_duo_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_duo_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Duo Device. | + **duo_device_request** | [**DuoDeviceRequest**](DuoDeviceRequest.md)| | + +### Return type + +[**DuoDevice**](DuoDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_duo_used_by_list** +> List[UsedBy] authenticators_duo_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Duo Device. + + try: + api_response = api_instance.authenticators_duo_used_by_list(id) + print("The response of AuthenticatorsApi->authenticators_duo_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_duo_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Duo Device. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_email_destroy** +> authenticators_email_destroy(id) + +Viewset for email authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Email Device. + + try: + api_instance.authenticators_email_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_email_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Email Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_email_list** +> PaginatedEmailDeviceList authenticators_email_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for email authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_email_device_list import PaginatedEmailDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_email_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_email_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_email_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedEmailDeviceList**](PaginatedEmailDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_email_partial_update** +> EmailDevice authenticators_email_partial_update(id, patched_email_device_request=patched_email_device_request) + +Viewset for email authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_device import EmailDevice +from authentik_client.models.patched_email_device_request import PatchedEmailDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Email Device. + patched_email_device_request = authentik_client.PatchedEmailDeviceRequest() # PatchedEmailDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_email_partial_update(id, patched_email_device_request=patched_email_device_request) + print("The response of AuthenticatorsApi->authenticators_email_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_email_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Email Device. | + **patched_email_device_request** | [**PatchedEmailDeviceRequest**](PatchedEmailDeviceRequest.md)| | [optional] + +### Return type + +[**EmailDevice**](EmailDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_email_retrieve** +> EmailDevice authenticators_email_retrieve(id) + +Viewset for email authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_device import EmailDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Email Device. + + try: + api_response = api_instance.authenticators_email_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_email_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_email_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Email Device. | + +### Return type + +[**EmailDevice**](EmailDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_email_update** +> EmailDevice authenticators_email_update(id, email_device_request) + +Viewset for email authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_device import EmailDevice +from authentik_client.models.email_device_request import EmailDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Email Device. + email_device_request = authentik_client.EmailDeviceRequest() # EmailDeviceRequest | + + try: + api_response = api_instance.authenticators_email_update(id, email_device_request) + print("The response of AuthenticatorsApi->authenticators_email_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_email_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Email Device. | + **email_device_request** | [**EmailDeviceRequest**](EmailDeviceRequest.md)| | + +### Return type + +[**EmailDevice**](EmailDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_email_used_by_list** +> List[UsedBy] authenticators_email_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Email Device. + + try: + api_response = api_instance.authenticators_email_used_by_list(id) + print("The response of AuthenticatorsApi->authenticators_email_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_email_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Email Device. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_endpoint_list** +> PaginatedGoogleEndpointDeviceList authenticators_endpoint_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for Endpoint authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_google_endpoint_device_list import PaginatedGoogleEndpointDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_endpoint_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_endpoint_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_endpoint_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedGoogleEndpointDeviceList**](PaginatedGoogleEndpointDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_endpoint_retrieve** +> GoogleEndpointDevice authenticators_endpoint_retrieve(uuid) + +Viewset for Endpoint authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Device. + + try: + api_response = api_instance.authenticators_endpoint_retrieve(uuid) + print("The response of AuthenticatorsApi->authenticators_endpoint_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_endpoint_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Endpoint Device. | + +### Return type + +[**GoogleEndpointDevice**](GoogleEndpointDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_endpoint_used_by_list** +> List[UsedBy] authenticators_endpoint_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Device. + + try: + api_response = api_instance.authenticators_endpoint_used_by_list(uuid) + print("The response of AuthenticatorsApi->authenticators_endpoint_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_endpoint_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Endpoint Device. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_sms_destroy** +> authenticators_sms_destroy(id) + +Viewset for sms authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this SMS Device. + + try: + api_instance.authenticators_sms_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_sms_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SMS Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_sms_list** +> PaginatedSMSDeviceList authenticators_sms_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for sms authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_sms_device_list import PaginatedSMSDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_sms_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_sms_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_sms_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedSMSDeviceList**](PaginatedSMSDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_sms_partial_update** +> SMSDevice authenticators_sms_partial_update(id, patched_sms_device_request=patched_sms_device_request) + +Viewset for sms authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_sms_device_request import PatchedSMSDeviceRequest +from authentik_client.models.sms_device import SMSDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this SMS Device. + patched_sms_device_request = authentik_client.PatchedSMSDeviceRequest() # PatchedSMSDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_sms_partial_update(id, patched_sms_device_request=patched_sms_device_request) + print("The response of AuthenticatorsApi->authenticators_sms_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_sms_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SMS Device. | + **patched_sms_device_request** | [**PatchedSMSDeviceRequest**](PatchedSMSDeviceRequest.md)| | [optional] + +### Return type + +[**SMSDevice**](SMSDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_sms_retrieve** +> SMSDevice authenticators_sms_retrieve(id) + +Viewset for sms authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sms_device import SMSDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this SMS Device. + + try: + api_response = api_instance.authenticators_sms_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_sms_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_sms_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SMS Device. | + +### Return type + +[**SMSDevice**](SMSDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_sms_update** +> SMSDevice authenticators_sms_update(id, sms_device_request) + +Viewset for sms authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sms_device import SMSDevice +from authentik_client.models.sms_device_request import SMSDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this SMS Device. + sms_device_request = authentik_client.SMSDeviceRequest() # SMSDeviceRequest | + + try: + api_response = api_instance.authenticators_sms_update(id, sms_device_request) + print("The response of AuthenticatorsApi->authenticators_sms_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_sms_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SMS Device. | + **sms_device_request** | [**SMSDeviceRequest**](SMSDeviceRequest.md)| | + +### Return type + +[**SMSDevice**](SMSDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_sms_used_by_list** +> List[UsedBy] authenticators_sms_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this SMS Device. + + try: + api_response = api_instance.authenticators_sms_used_by_list(id) + print("The response of AuthenticatorsApi->authenticators_sms_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_sms_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SMS Device. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_static_destroy** +> authenticators_static_destroy(id) + +Viewset for static authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Static Device. + + try: + api_instance.authenticators_static_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_static_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Static Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_static_list** +> PaginatedStaticDeviceList authenticators_static_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for static authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_static_device_list import PaginatedStaticDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_static_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_static_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_static_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedStaticDeviceList**](PaginatedStaticDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_static_partial_update** +> StaticDevice authenticators_static_partial_update(id, patched_static_device_request=patched_static_device_request) + +Viewset for static authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_static_device_request import PatchedStaticDeviceRequest +from authentik_client.models.static_device import StaticDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Static Device. + patched_static_device_request = authentik_client.PatchedStaticDeviceRequest() # PatchedStaticDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_static_partial_update(id, patched_static_device_request=patched_static_device_request) + print("The response of AuthenticatorsApi->authenticators_static_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_static_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Static Device. | + **patched_static_device_request** | [**PatchedStaticDeviceRequest**](PatchedStaticDeviceRequest.md)| | [optional] + +### Return type + +[**StaticDevice**](StaticDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_static_retrieve** +> StaticDevice authenticators_static_retrieve(id) + +Viewset for static authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.static_device import StaticDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Static Device. + + try: + api_response = api_instance.authenticators_static_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_static_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_static_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Static Device. | + +### Return type + +[**StaticDevice**](StaticDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_static_update** +> StaticDevice authenticators_static_update(id, static_device_request) + +Viewset for static authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.static_device import StaticDevice +from authentik_client.models.static_device_request import StaticDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Static Device. + static_device_request = authentik_client.StaticDeviceRequest() # StaticDeviceRequest | + + try: + api_response = api_instance.authenticators_static_update(id, static_device_request) + print("The response of AuthenticatorsApi->authenticators_static_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_static_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Static Device. | + **static_device_request** | [**StaticDeviceRequest**](StaticDeviceRequest.md)| | + +### Return type + +[**StaticDevice**](StaticDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_static_used_by_list** +> List[UsedBy] authenticators_static_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this Static Device. + + try: + api_response = api_instance.authenticators_static_used_by_list(id) + print("The response of AuthenticatorsApi->authenticators_static_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_static_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Static Device. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_totp_destroy** +> authenticators_totp_destroy(id) + +Viewset for totp authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this TOTP Device. + + try: + api_instance.authenticators_totp_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_totp_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this TOTP Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_totp_list** +> PaginatedTOTPDeviceList authenticators_totp_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for totp authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_totp_device_list import PaginatedTOTPDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_totp_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_totp_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_totp_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedTOTPDeviceList**](PaginatedTOTPDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_totp_partial_update** +> TOTPDevice authenticators_totp_partial_update(id, patched_totp_device_request=patched_totp_device_request) + +Viewset for totp authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_totp_device_request import PatchedTOTPDeviceRequest +from authentik_client.models.totp_device import TOTPDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this TOTP Device. + patched_totp_device_request = authentik_client.PatchedTOTPDeviceRequest() # PatchedTOTPDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_totp_partial_update(id, patched_totp_device_request=patched_totp_device_request) + print("The response of AuthenticatorsApi->authenticators_totp_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_totp_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this TOTP Device. | + **patched_totp_device_request** | [**PatchedTOTPDeviceRequest**](PatchedTOTPDeviceRequest.md)| | [optional] + +### Return type + +[**TOTPDevice**](TOTPDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_totp_retrieve** +> TOTPDevice authenticators_totp_retrieve(id) + +Viewset for totp authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.totp_device import TOTPDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this TOTP Device. + + try: + api_response = api_instance.authenticators_totp_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_totp_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_totp_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this TOTP Device. | + +### Return type + +[**TOTPDevice**](TOTPDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_totp_update** +> TOTPDevice authenticators_totp_update(id, totp_device_request) + +Viewset for totp authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.totp_device import TOTPDevice +from authentik_client.models.totp_device_request import TOTPDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this TOTP Device. + totp_device_request = authentik_client.TOTPDeviceRequest() # TOTPDeviceRequest | + + try: + api_response = api_instance.authenticators_totp_update(id, totp_device_request) + print("The response of AuthenticatorsApi->authenticators_totp_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_totp_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this TOTP Device. | + **totp_device_request** | [**TOTPDeviceRequest**](TOTPDeviceRequest.md)| | + +### Return type + +[**TOTPDevice**](TOTPDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_totp_used_by_list** +> List[UsedBy] authenticators_totp_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this TOTP Device. + + try: + api_response = api_instance.authenticators_totp_used_by_list(id) + print("The response of AuthenticatorsApi->authenticators_totp_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_totp_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this TOTP Device. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_webauthn_destroy** +> authenticators_webauthn_destroy(id) + +Viewset for WebAuthn authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this WebAuthn Device. + + try: + api_instance.authenticators_webauthn_destroy(id) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_webauthn_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WebAuthn Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_webauthn_list** +> PaginatedWebAuthnDeviceList authenticators_webauthn_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Viewset for WebAuthn authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_web_authn_device_list import PaginatedWebAuthnDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.authenticators_webauthn_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of AuthenticatorsApi->authenticators_webauthn_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_webauthn_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedWebAuthnDeviceList**](PaginatedWebAuthnDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_webauthn_partial_update** +> WebAuthnDevice authenticators_webauthn_partial_update(id, patched_web_authn_device_request=patched_web_authn_device_request) + +Viewset for WebAuthn authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_web_authn_device_request import PatchedWebAuthnDeviceRequest +from authentik_client.models.web_authn_device import WebAuthnDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this WebAuthn Device. + patched_web_authn_device_request = authentik_client.PatchedWebAuthnDeviceRequest() # PatchedWebAuthnDeviceRequest | (optional) + + try: + api_response = api_instance.authenticators_webauthn_partial_update(id, patched_web_authn_device_request=patched_web_authn_device_request) + print("The response of AuthenticatorsApi->authenticators_webauthn_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_webauthn_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WebAuthn Device. | + **patched_web_authn_device_request** | [**PatchedWebAuthnDeviceRequest**](PatchedWebAuthnDeviceRequest.md)| | [optional] + +### Return type + +[**WebAuthnDevice**](WebAuthnDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_webauthn_retrieve** +> WebAuthnDevice authenticators_webauthn_retrieve(id) + +Viewset for WebAuthn authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.web_authn_device import WebAuthnDevice +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this WebAuthn Device. + + try: + api_response = api_instance.authenticators_webauthn_retrieve(id) + print("The response of AuthenticatorsApi->authenticators_webauthn_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_webauthn_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WebAuthn Device. | + +### Return type + +[**WebAuthnDevice**](WebAuthnDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_webauthn_update** +> WebAuthnDevice authenticators_webauthn_update(id, web_authn_device_request) + +Viewset for WebAuthn authenticator devices + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.web_authn_device import WebAuthnDevice +from authentik_client.models.web_authn_device_request import WebAuthnDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this WebAuthn Device. + web_authn_device_request = authentik_client.WebAuthnDeviceRequest() # WebAuthnDeviceRequest | + + try: + api_response = api_instance.authenticators_webauthn_update(id, web_authn_device_request) + print("The response of AuthenticatorsApi->authenticators_webauthn_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_webauthn_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WebAuthn Device. | + **web_authn_device_request** | [**WebAuthnDeviceRequest**](WebAuthnDeviceRequest.md)| | + +### Return type + +[**WebAuthnDevice**](WebAuthnDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **authenticators_webauthn_used_by_list** +> List[UsedBy] authenticators_webauthn_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.AuthenticatorsApi(api_client) + id = 56 # int | A unique integer value identifying this WebAuthn Device. + + try: + api_response = api_instance.authenticators_webauthn_used_by_list(id) + print("The response of AuthenticatorsApi->authenticators_webauthn_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling AuthenticatorsApi->authenticators_webauthn_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WebAuthn Device. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/AuthorizationCodeAuthMethodEnum.md b/docs/AuthorizationCodeAuthMethodEnum.md new file mode 100644 index 000000000..7a1d275f3 --- /dev/null +++ b/docs/AuthorizationCodeAuthMethodEnum.md @@ -0,0 +1,12 @@ +# AuthorizationCodeAuthMethodEnum + + +## Enum + +* `BASIC_AUTH` (value: `'basic_auth'`) + +* `POST_BODY` (value: `'post_body'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AutoSubmitChallengeResponseRequest.md b/docs/AutoSubmitChallengeResponseRequest.md new file mode 100644 index 000000000..a9e83c87b --- /dev/null +++ b/docs/AutoSubmitChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# AutoSubmitChallengeResponseRequest + +Pseudo class for autosubmit response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-autosubmit'] + +## Example + +```python +from authentik_client.models.auto_submit_challenge_response_request import AutoSubmitChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of AutoSubmitChallengeResponseRequest from a JSON string +auto_submit_challenge_response_request_instance = AutoSubmitChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(AutoSubmitChallengeResponseRequest.to_json()) + +# convert the object into a dict +auto_submit_challenge_response_request_dict = auto_submit_challenge_response_request_instance.to_dict() +# create an instance of AutoSubmitChallengeResponseRequest from a dict +auto_submit_challenge_response_request_from_dict = AutoSubmitChallengeResponseRequest.from_dict(auto_submit_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AutosubmitChallenge.md b/docs/AutosubmitChallenge.md new file mode 100644 index 000000000..ef0a5993e --- /dev/null +++ b/docs/AutosubmitChallenge.md @@ -0,0 +1,35 @@ +# AutosubmitChallenge + +Autosubmit challenge used to send and navigate a POST request + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-autosubmit'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**url** | **str** | | +**attrs** | **Dict[str, str]** | | +**title** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.autosubmit_challenge import AutosubmitChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of AutosubmitChallenge from a JSON string +autosubmit_challenge_instance = AutosubmitChallenge.from_json(json) +# print the JSON string representation of the object +print(AutosubmitChallenge.to_json()) + +# convert the object into a dict +autosubmit_challenge_dict = autosubmit_challenge_instance.to_dict() +# create an instance of AutosubmitChallenge from a dict +autosubmit_challenge_from_dict = AutosubmitChallenge.from_dict(autosubmit_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/BackendsEnum.md b/docs/BackendsEnum.md new file mode 100644 index 000000000..40a178e7a --- /dev/null +++ b/docs/BackendsEnum.md @@ -0,0 +1,16 @@ +# BackendsEnum + + +## Enum + +* `AUTHENTIK_DOT_CORE_DOT_AUTH_DOT_INBUILT_BACKEND` (value: `'authentik.core.auth.InbuiltBackend'`) + +* `AUTHENTIK_DOT_CORE_DOT_AUTH_DOT_TOKEN_BACKEND` (value: `'authentik.core.auth.TokenBackend'`) + +* `AUTHENTIK_DOT_SOURCES_DOT_LDAP_DOT_AUTH_DOT_LDAP_BACKEND` (value: `'authentik.sources.ldap.auth.LDAPBackend'`) + +* `AUTHENTIK_DOT_SOURCES_DOT_KERBEROS_DOT_AUTH_DOT_KERBEROS_BACKEND` (value: `'authentik.sources.kerberos.auth.KerberosBackend'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/BindingTypeEnum.md b/docs/BindingTypeEnum.md new file mode 100644 index 000000000..821e597f1 --- /dev/null +++ b/docs/BindingTypeEnum.md @@ -0,0 +1,14 @@ +# BindingTypeEnum + + +## Enum + +* `REDIRECT` (value: `'REDIRECT'`) + +* `POST` (value: `'POST'`) + +* `POST_AUTO` (value: `'POST_AUTO'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/BlueprintFile.md b/docs/BlueprintFile.md new file mode 100644 index 000000000..45cca57dd --- /dev/null +++ b/docs/BlueprintFile.md @@ -0,0 +1,32 @@ +# BlueprintFile + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**path** | **str** | | +**last_m** | **datetime** | | +**hash** | **str** | | +**meta** | [**Metadata**](Metadata.md) | | [readonly] + +## Example + +```python +from authentik_client.models.blueprint_file import BlueprintFile + +# TODO update the JSON string below +json = "{}" +# create an instance of BlueprintFile from a JSON string +blueprint_file_instance = BlueprintFile.from_json(json) +# print the JSON string representation of the object +print(BlueprintFile.to_json()) + +# convert the object into a dict +blueprint_file_dict = blueprint_file_instance.to_dict() +# create an instance of BlueprintFile from a dict +blueprint_file_from_dict = BlueprintFile.from_dict(blueprint_file_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/BlueprintImportResult.md b/docs/BlueprintImportResult.md new file mode 100644 index 000000000..415e1958f --- /dev/null +++ b/docs/BlueprintImportResult.md @@ -0,0 +1,31 @@ +# BlueprintImportResult + +Logs of an attempted blueprint import + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**logs** | [**List[LogEvent]**](LogEvent.md) | | [readonly] +**success** | **bool** | | [readonly] + +## Example + +```python +from authentik_client.models.blueprint_import_result import BlueprintImportResult + +# TODO update the JSON string below +json = "{}" +# create an instance of BlueprintImportResult from a JSON string +blueprint_import_result_instance = BlueprintImportResult.from_json(json) +# print the JSON string representation of the object +print(BlueprintImportResult.to_json()) + +# convert the object into a dict +blueprint_import_result_dict = blueprint_import_result_instance.to_dict() +# create an instance of BlueprintImportResult from a dict +blueprint_import_result_from_dict = BlueprintImportResult.from_dict(blueprint_import_result_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/BlueprintInstance.md b/docs/BlueprintInstance.md new file mode 100644 index 000000000..c3c230e6c --- /dev/null +++ b/docs/BlueprintInstance.md @@ -0,0 +1,40 @@ +# BlueprintInstance + +Info about a single blueprint instance file + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**path** | **str** | | [optional] [default to ''] +**context** | **Dict[str, object]** | | [optional] +**last_applied** | **datetime** | | [readonly] +**last_applied_hash** | **str** | | [readonly] +**status** | [**BlueprintInstanceStatusEnum**](BlueprintInstanceStatusEnum.md) | | [readonly] +**enabled** | **bool** | | [optional] +**managed_models** | **List[str]** | | [readonly] +**metadata** | **Dict[str, object]** | | [readonly] +**content** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.blueprint_instance import BlueprintInstance + +# TODO update the JSON string below +json = "{}" +# create an instance of BlueprintInstance from a JSON string +blueprint_instance_instance = BlueprintInstance.from_json(json) +# print the JSON string representation of the object +print(BlueprintInstance.to_json()) + +# convert the object into a dict +blueprint_instance_dict = blueprint_instance_instance.to_dict() +# create an instance of BlueprintInstance from a dict +blueprint_instance_from_dict = BlueprintInstance.from_dict(blueprint_instance_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/BlueprintInstanceRequest.md b/docs/BlueprintInstanceRequest.md new file mode 100644 index 000000000..105799b3d --- /dev/null +++ b/docs/BlueprintInstanceRequest.md @@ -0,0 +1,34 @@ +# BlueprintInstanceRequest + +Info about a single blueprint instance file + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**path** | **str** | | [optional] [default to ''] +**context** | **Dict[str, object]** | | [optional] +**enabled** | **bool** | | [optional] +**content** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.blueprint_instance_request import BlueprintInstanceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of BlueprintInstanceRequest from a JSON string +blueprint_instance_request_instance = BlueprintInstanceRequest.from_json(json) +# print the JSON string representation of the object +print(BlueprintInstanceRequest.to_json()) + +# convert the object into a dict +blueprint_instance_request_dict = blueprint_instance_request_instance.to_dict() +# create an instance of BlueprintInstanceRequest from a dict +blueprint_instance_request_from_dict = BlueprintInstanceRequest.from_dict(blueprint_instance_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/BlueprintInstanceStatusEnum.md b/docs/BlueprintInstanceStatusEnum.md new file mode 100644 index 000000000..a579303bd --- /dev/null +++ b/docs/BlueprintInstanceStatusEnum.md @@ -0,0 +1,18 @@ +# BlueprintInstanceStatusEnum + + +## Enum + +* `SUCCESSFUL` (value: `'successful'`) + +* `WARNING` (value: `'warning'`) + +* `ERROR` (value: `'error'`) + +* `ORPHANED` (value: `'orphaned'`) + +* `UNKNOWN` (value: `'unknown'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Brand.md b/docs/Brand.md new file mode 100644 index 000000000..a61c6ed5e --- /dev/null +++ b/docs/Brand.md @@ -0,0 +1,48 @@ +# Brand + +Brand Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**brand_uuid** | **UUID** | | [readonly] +**domain** | **str** | Domain that activates this brand. Can be a superset, i.e. `a.b` for `aa.b` and `ba.b` | +**default** | **bool** | | [optional] +**branding_title** | **str** | | [optional] +**branding_logo** | **str** | | [optional] +**branding_favicon** | **str** | | [optional] +**branding_custom_css** | **str** | | [optional] +**branding_default_flow_background** | **str** | | [optional] +**flow_authentication** | **UUID** | | [optional] +**flow_invalidation** | **UUID** | | [optional] +**flow_recovery** | **UUID** | | [optional] +**flow_unenrollment** | **UUID** | | [optional] +**flow_user_settings** | **UUID** | | [optional] +**flow_device_code** | **UUID** | | [optional] +**flow_lockdown** | **UUID** | | [optional] +**default_application** | **UUID** | When set, external users will be redirected to this application after authenticating. | [optional] +**web_certificate** | **UUID** | Web Certificate used by the authentik Core webserver. | [optional] +**client_certificates** | **List[UUID]** | Certificates used for client authentication. | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.brand import Brand + +# TODO update the JSON string below +json = "{}" +# create an instance of Brand from a JSON string +brand_instance = Brand.from_json(json) +# print the JSON string representation of the object +print(Brand.to_json()) + +# convert the object into a dict +brand_dict = brand_instance.to_dict() +# create an instance of Brand from a dict +brand_from_dict = Brand.from_dict(brand_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/BrandRequest.md b/docs/BrandRequest.md new file mode 100644 index 000000000..47cdf5dc3 --- /dev/null +++ b/docs/BrandRequest.md @@ -0,0 +1,47 @@ +# BrandRequest + +Brand Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**domain** | **str** | Domain that activates this brand. Can be a superset, i.e. `a.b` for `aa.b` and `ba.b` | +**default** | **bool** | | [optional] +**branding_title** | **str** | | [optional] +**branding_logo** | **str** | | [optional] +**branding_favicon** | **str** | | [optional] +**branding_custom_css** | **str** | | [optional] +**branding_default_flow_background** | **str** | | [optional] +**flow_authentication** | **UUID** | | [optional] +**flow_invalidation** | **UUID** | | [optional] +**flow_recovery** | **UUID** | | [optional] +**flow_unenrollment** | **UUID** | | [optional] +**flow_user_settings** | **UUID** | | [optional] +**flow_device_code** | **UUID** | | [optional] +**flow_lockdown** | **UUID** | | [optional] +**default_application** | **UUID** | When set, external users will be redirected to this application after authenticating. | [optional] +**web_certificate** | **UUID** | Web Certificate used by the authentik Core webserver. | [optional] +**client_certificates** | **List[UUID]** | Certificates used for client authentication. | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.brand_request import BrandRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of BrandRequest from a JSON string +brand_request_instance = BrandRequest.from_json(json) +# print the JSON string representation of the object +print(BrandRequest.to_json()) + +# convert the object into a dict +brand_request_dict = brand_request_instance.to_dict() +# create an instance of BrandRequest from a dict +brand_request_from_dict = BrandRequest.from_dict(brand_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/BulkDeleteSessionResponse.md b/docs/BulkDeleteSessionResponse.md new file mode 100644 index 000000000..cb9c7f0a7 --- /dev/null +++ b/docs/BulkDeleteSessionResponse.md @@ -0,0 +1,29 @@ +# BulkDeleteSessionResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**deleted** | **int** | | + +## Example + +```python +from authentik_client.models.bulk_delete_session_response import BulkDeleteSessionResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of BulkDeleteSessionResponse from a JSON string +bulk_delete_session_response_instance = BulkDeleteSessionResponse.from_json(json) +# print the JSON string representation of the object +print(BulkDeleteSessionResponse.to_json()) + +# convert the object into a dict +bulk_delete_session_response_dict = bulk_delete_session_response_instance.to_dict() +# create an instance of BulkDeleteSessionResponse from a dict +bulk_delete_session_response_from_dict = BulkDeleteSessionResponse.from_dict(bulk_delete_session_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Cache.md b/docs/Cache.md new file mode 100644 index 000000000..0586ced4b --- /dev/null +++ b/docs/Cache.md @@ -0,0 +1,30 @@ +# Cache + +Generic cache stats for an object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**count** | **int** | | [readonly] + +## Example + +```python +from authentik_client.models.cache import Cache + +# TODO update the JSON string below +json = "{}" +# create an instance of Cache from a JSON string +cache_instance = Cache.from_json(json) +# print the JSON string representation of the object +print(Cache.to_json()) + +# convert the object into a dict +cache_dict = cache_instance.to_dict() +# create an instance of Cache from a dict +cache_from_dict = Cache.from_dict(cache_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CapabilitiesEnum.md b/docs/CapabilitiesEnum.md new file mode 100644 index 000000000..610581a6a --- /dev/null +++ b/docs/CapabilitiesEnum.md @@ -0,0 +1,22 @@ +# CapabilitiesEnum + + +## Enum + +* `CAN_SAVE_MEDIA` (value: `'can_save_media'`) + +* `CAN_SAVE_REPORTS` (value: `'can_save_reports'`) + +* `CAN_GEO_IP` (value: `'can_geo_ip'`) + +* `CAN_ASN` (value: `'can_asn'`) + +* `CAN_IMPERSONATE` (value: `'can_impersonate'`) + +* `CAN_DEBUG` (value: `'can_debug'`) + +* `IS_ENTERPRISE` (value: `'is_enterprise'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CaptchaChallenge.md b/docs/CaptchaChallenge.md new file mode 100644 index 000000000..21a965cce --- /dev/null +++ b/docs/CaptchaChallenge.md @@ -0,0 +1,37 @@ +# CaptchaChallenge + +Site public key + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-captcha'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**site_key** | **str** | | +**js_url** | **str** | | +**interactive** | **bool** | | + +## Example + +```python +from authentik_client.models.captcha_challenge import CaptchaChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of CaptchaChallenge from a JSON string +captcha_challenge_instance = CaptchaChallenge.from_json(json) +# print the JSON string representation of the object +print(CaptchaChallenge.to_json()) + +# convert the object into a dict +captcha_challenge_dict = captcha_challenge_instance.to_dict() +# create an instance of CaptchaChallenge from a dict +captcha_challenge_from_dict = CaptchaChallenge.from_dict(captcha_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CaptchaChallengeResponseRequest.md b/docs/CaptchaChallengeResponseRequest.md new file mode 100644 index 000000000..87be18bfc --- /dev/null +++ b/docs/CaptchaChallengeResponseRequest.md @@ -0,0 +1,31 @@ +# CaptchaChallengeResponseRequest + +Validate captcha token + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-captcha'] +**token** | **str** | | + +## Example + +```python +from authentik_client.models.captcha_challenge_response_request import CaptchaChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CaptchaChallengeResponseRequest from a JSON string +captcha_challenge_response_request_instance = CaptchaChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(CaptchaChallengeResponseRequest.to_json()) + +# convert the object into a dict +captcha_challenge_response_request_dict = captcha_challenge_response_request_instance.to_dict() +# create an instance of CaptchaChallengeResponseRequest from a dict +captcha_challenge_response_request_from_dict = CaptchaChallengeResponseRequest.from_dict(captcha_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CaptchaStage.md b/docs/CaptchaStage.md new file mode 100644 index 000000000..df5f325e6 --- /dev/null +++ b/docs/CaptchaStage.md @@ -0,0 +1,43 @@ +# CaptchaStage + +CaptchaStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**public_key** | **str** | Public key, acquired your captcha Provider. | +**js_url** | **str** | | [optional] +**api_url** | **str** | | [optional] +**interactive** | **bool** | | [optional] +**score_min_threshold** | **float** | | [optional] +**score_max_threshold** | **float** | | [optional] +**error_on_invalid_score** | **bool** | When enabled and the received captcha score is outside of the given threshold, the stage will show an error message. When not enabled, the flow will continue, but the data from the captcha will be available in the context for policy decisions | [optional] + +## Example + +```python +from authentik_client.models.captcha_stage import CaptchaStage + +# TODO update the JSON string below +json = "{}" +# create an instance of CaptchaStage from a JSON string +captcha_stage_instance = CaptchaStage.from_json(json) +# print the JSON string representation of the object +print(CaptchaStage.to_json()) + +# convert the object into a dict +captcha_stage_dict = captcha_stage_instance.to_dict() +# create an instance of CaptchaStage from a dict +captcha_stage_from_dict = CaptchaStage.from_dict(captcha_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CaptchaStageRequest.md b/docs/CaptchaStageRequest.md new file mode 100644 index 000000000..6063079ed --- /dev/null +++ b/docs/CaptchaStageRequest.md @@ -0,0 +1,38 @@ +# CaptchaStageRequest + +CaptchaStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**public_key** | **str** | Public key, acquired your captcha Provider. | +**private_key** | **str** | Private key, acquired your captcha Provider. | +**js_url** | **str** | | [optional] +**api_url** | **str** | | [optional] +**interactive** | **bool** | | [optional] +**score_min_threshold** | **float** | | [optional] +**score_max_threshold** | **float** | | [optional] +**error_on_invalid_score** | **bool** | When enabled and the received captcha score is outside of the given threshold, the stage will show an error message. When not enabled, the flow will continue, but the data from the captcha will be available in the context for policy decisions | [optional] + +## Example + +```python +from authentik_client.models.captcha_stage_request import CaptchaStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CaptchaStageRequest from a JSON string +captcha_stage_request_instance = CaptchaStageRequest.from_json(json) +# print the JSON string representation of the object +print(CaptchaStageRequest.to_json()) + +# convert the object into a dict +captcha_stage_request_dict = captcha_stage_request_instance.to_dict() +# create an instance of CaptchaStageRequest from a dict +captcha_stage_request_from_dict = CaptchaStageRequest.from_dict(captcha_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CertAttributeEnum.md b/docs/CertAttributeEnum.md new file mode 100644 index 000000000..958837298 --- /dev/null +++ b/docs/CertAttributeEnum.md @@ -0,0 +1,14 @@ +# CertAttributeEnum + + +## Enum + +* `SUBJECT` (value: `'subject'`) + +* `COMMON_NAME` (value: `'common_name'`) + +* `EMAIL` (value: `'email'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CertificateData.md b/docs/CertificateData.md new file mode 100644 index 000000000..78acf2013 --- /dev/null +++ b/docs/CertificateData.md @@ -0,0 +1,30 @@ +# CertificateData + +Get CertificateKeyPair's data + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.certificate_data import CertificateData + +# TODO update the JSON string below +json = "{}" +# create an instance of CertificateData from a JSON string +certificate_data_instance = CertificateData.from_json(json) +# print the JSON string representation of the object +print(CertificateData.to_json()) + +# convert the object into a dict +certificate_data_dict = certificate_data_instance.to_dict() +# create an instance of CertificateData from a dict +certificate_data_from_dict = CertificateData.from_dict(certificate_data_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CertificateGenerationRequest.md b/docs/CertificateGenerationRequest.md new file mode 100644 index 000000000..455820deb --- /dev/null +++ b/docs/CertificateGenerationRequest.md @@ -0,0 +1,33 @@ +# CertificateGenerationRequest + +Certificate generation parameters + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**common_name** | **str** | | +**subject_alt_name** | **str** | | [optional] +**validity_days** | **int** | | +**alg** | [**AlgEnum**](AlgEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.certificate_generation_request import CertificateGenerationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CertificateGenerationRequest from a JSON string +certificate_generation_request_instance = CertificateGenerationRequest.from_json(json) +# print the JSON string representation of the object +print(CertificateGenerationRequest.to_json()) + +# convert the object into a dict +certificate_generation_request_dict = certificate_generation_request_instance.to_dict() +# create an instance of CertificateGenerationRequest from a dict +certificate_generation_request_from_dict = CertificateGenerationRequest.from_dict(certificate_generation_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CertificateKeyPair.md b/docs/CertificateKeyPair.md new file mode 100644 index 000000000..650367634 --- /dev/null +++ b/docs/CertificateKeyPair.md @@ -0,0 +1,40 @@ +# CertificateKeyPair + +CertificateKeyPair Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**fingerprint_sha256** | **str** | SHA256 fingerprint of the certificate | [readonly] +**fingerprint_sha1** | **str** | SHA1 fingerprint of the certificate | [readonly] +**cert_expiry** | **datetime** | Certificate expiry date | [readonly] +**cert_subject** | **str** | Certificate subject as RFC4514 string | [readonly] +**private_key_available** | **bool** | Show if this keypair has a private key configured or not | [readonly] +**key_type** | [**CertificateKeyPairKeyTypeEnum**](CertificateKeyPairKeyTypeEnum.md) | Key algorithm type detected from the certificate's public key | [readonly] +**certificate_download_url** | **str** | Get URL to download certificate | [readonly] +**private_key_download_url** | **str** | Get URL to download private key | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [readonly] + +## Example + +```python +from authentik_client.models.certificate_key_pair import CertificateKeyPair + +# TODO update the JSON string below +json = "{}" +# create an instance of CertificateKeyPair from a JSON string +certificate_key_pair_instance = CertificateKeyPair.from_json(json) +# print the JSON string representation of the object +print(CertificateKeyPair.to_json()) + +# convert the object into a dict +certificate_key_pair_dict = certificate_key_pair_instance.to_dict() +# create an instance of CertificateKeyPair from a dict +certificate_key_pair_from_dict = CertificateKeyPair.from_dict(certificate_key_pair_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CertificateKeyPairKeyTypeEnum.md b/docs/CertificateKeyPairKeyTypeEnum.md new file mode 100644 index 000000000..0d03f78f0 --- /dev/null +++ b/docs/CertificateKeyPairKeyTypeEnum.md @@ -0,0 +1,18 @@ +# CertificateKeyPairKeyTypeEnum + + +## Enum + +* `RSA` (value: `'rsa'`) + +* `EC` (value: `'ec'`) + +* `DSA` (value: `'dsa'`) + +* `ED25519` (value: `'ed25519'`) + +* `ED448` (value: `'ed448'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CertificateKeyPairRequest.md b/docs/CertificateKeyPairRequest.md new file mode 100644 index 000000000..3853108ec --- /dev/null +++ b/docs/CertificateKeyPairRequest.md @@ -0,0 +1,32 @@ +# CertificateKeyPairRequest + +CertificateKeyPair Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**certificate_data** | **str** | PEM-encoded Certificate data | +**key_data** | **str** | Optional Private Key. If this is set, you can use this keypair for encryption. | [optional] + +## Example + +```python +from authentik_client.models.certificate_key_pair_request import CertificateKeyPairRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CertificateKeyPairRequest from a JSON string +certificate_key_pair_request_instance = CertificateKeyPairRequest.from_json(json) +# print the JSON string representation of the object +print(CertificateKeyPairRequest.to_json()) + +# convert the object into a dict +certificate_key_pair_request_dict = certificate_key_pair_request_instance.to_dict() +# create an instance of CertificateKeyPairRequest from a dict +certificate_key_pair_request_from_dict = CertificateKeyPairRequest.from_dict(certificate_key_pair_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ChallengeTypes.md b/docs/ChallengeTypes.md new file mode 100644 index 000000000..a814d61e8 --- /dev/null +++ b/docs/ChallengeTypes.md @@ -0,0 +1,104 @@ +# ChallengeTypes + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-user-login'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**error_message** | **str** | | [optional] +**client_id** | **str** | | +**scope** | **str** | | +**redirect_uri** | **str** | | +**state** | **str** | | +**activation_barcode** | **str** | | +**activation_code** | **str** | | +**stage_uuid** | **str** | | +**email** | **str** | | [optional] +**email_required** | **bool** | | [optional] [default to True] +**phone_number_required** | **bool** | | [optional] [default to True] +**codes** | **List[str]** | | +**config_url** | **str** | | +**device_challenges** | [**List[DeviceChallenge]**](DeviceChallenge.md) | | +**configuration_stages** | [**List[SelectableStage]**](SelectableStage.md) | | +**registration** | **Dict[str, object]** | | +**url** | **str** | | +**attrs** | **Dict[str, str]** | | +**title** | **str** | | [optional] +**site_key** | **str** | | +**js_url** | **str** | | +**interactive** | **bool** | | +**header_text** | **str** | | [optional] +**permissions** | [**List[ConsentPermission]**](ConsentPermission.md) | | +**additional_permissions** | [**List[ConsentPermission]**](ConsentPermission.md) | | +**token** | **str** | | +**name** | **str** | | +**challenge** | **str** | | +**challenge_idle_timeout** | **int** | | +**request_id** | **str** | | +**error** | **str** | | [optional] +**traceback** | **str** | | [optional] +**loading_overlay** | **bool** | | [optional] [default to False] +**loading_text** | **str** | | +**user_fields** | **List[str]** | | +**pending_user_identifier** | **str** | | [optional] +**password_fields** | **bool** | | +**allow_show_password** | **bool** | | [optional] [default to False] +**application_pre** | **str** | | [optional] +**application_pre_launch** | **str** | | [optional] +**flow_designation** | [**FlowDesignationEnum**](FlowDesignationEnum.md) | | +**captcha_stage** | [**CaptchaChallenge**](CaptchaChallenge.md) | | [optional] +**enroll_url** | **str** | | [optional] +**recovery_url** | **str** | | [optional] +**passwordless_url** | **str** | | [optional] +**primary_action** | **str** | | +**sources** | [**List[LoginSource]**](LoginSource.md) | | [optional] +**show_source_labels** | **bool** | | +**enable_remember_me** | **bool** | | [optional] [default to True] +**passkey_challenge** | **Dict[str, object]** | | [optional] +**logout_urls** | [**List[LogoutURL]**](LogoutURL.md) | | [optional] +**provider_name** | **str** | | [optional] +**is_complete** | **bool** | | [optional] [default to False] +**post_url** | **str** | | [optional] +**redirect_url** | **str** | | [optional] +**saml_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | | [optional] +**saml_request** | **str** | | [optional] +**saml_response** | **str** | | [optional] +**saml_relay_state** | **str** | | [optional] +**slug** | **str** | | +**fields** | [**List[StagePrompt]**](StagePrompt.md) | | +**to** | **str** | | +**final_redirect** | **bool** | | [optional] [default to False] +**application_name** | **str** | | [optional] +**application_launch_url** | **str** | | [optional] +**invalidation_flow_url** | **str** | | [optional] +**overview_url** | **str** | | [optional] +**brand_name** | **str** | | +**body** | **str** | | +**bot_username** | **str** | Telegram bot username | +**request_message_access** | **bool** | | + +## Example + +```python +from authentik_client.models.challenge_types import ChallengeTypes + +# TODO update the JSON string below +json = "{}" +# create an instance of ChallengeTypes from a JSON string +challenge_types_instance = ChallengeTypes.from_json(json) +# print the JSON string representation of the object +print(ChallengeTypes.to_json()) + +# convert the object into a dict +challenge_types_dict = challenge_types_instance.to_dict() +# create an instance of ChallengeTypes from a dict +challenge_types_from_dict = ChallengeTypes.from_dict(challenge_types_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ClientTypeEnum.md b/docs/ClientTypeEnum.md new file mode 100644 index 000000000..3c2a97264 --- /dev/null +++ b/docs/ClientTypeEnum.md @@ -0,0 +1,12 @@ +# ClientTypeEnum + + +## Enum + +* `CONFIDENTIAL` (value: `'confidential'`) + +* `PUBLIC` (value: `'public'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CompatibilityModeEnum.md b/docs/CompatibilityModeEnum.md new file mode 100644 index 000000000..09eb96909 --- /dev/null +++ b/docs/CompatibilityModeEnum.md @@ -0,0 +1,20 @@ +# CompatibilityModeEnum + + +## Enum + +* `DEFAULT` (value: `'default'`) + +* `AWS` (value: `'aws'`) + +* `SLACK` (value: `'slack'`) + +* `SFDC` (value: `'sfdc'`) + +* `WEBEX` (value: `'webex'`) + +* `VCENTER` (value: `'vcenter'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Config.md b/docs/Config.md new file mode 100644 index 000000000..deed73aeb --- /dev/null +++ b/docs/Config.md @@ -0,0 +1,34 @@ +# Config + +Serialize authentik Config into DRF Object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**error_reporting** | [**ErrorReportingConfig**](ErrorReportingConfig.md) | | +**capabilities** | [**List[CapabilitiesEnum]**](CapabilitiesEnum.md) | | +**cache_timeout** | **int** | | +**cache_timeout_flows** | **int** | | +**cache_timeout_policies** | **int** | | + +## Example + +```python +from authentik_client.models.config import Config + +# TODO update the JSON string below +json = "{}" +# create an instance of Config from a JSON string +config_instance = Config.from_json(json) +# print the JSON string representation of the object +print(Config.to_json()) + +# convert the object into a dict +config_dict = config_instance.to_dict() +# create an instance of Config from a dict +config_from_dict = Config.from_dict(config_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ConnectionToken.md b/docs/ConnectionToken.md new file mode 100644 index 000000000..3d55e4afe --- /dev/null +++ b/docs/ConnectionToken.md @@ -0,0 +1,35 @@ +# ConnectionToken + +ConnectionToken Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [optional] +**provider** | **int** | | +**provider_obj** | [**RACProvider**](RACProvider.md) | | [readonly] +**endpoint** | **UUID** | | +**endpoint_obj** | [**Endpoint**](Endpoint.md) | | [readonly] +**user** | [**PartialUser**](PartialUser.md) | | [readonly] + +## Example + +```python +from authentik_client.models.connection_token import ConnectionToken + +# TODO update the JSON string below +json = "{}" +# create an instance of ConnectionToken from a JSON string +connection_token_instance = ConnectionToken.from_json(json) +# print the JSON string representation of the object +print(ConnectionToken.to_json()) + +# convert the object into a dict +connection_token_dict = connection_token_instance.to_dict() +# create an instance of ConnectionToken from a dict +connection_token_from_dict = ConnectionToken.from_dict(connection_token_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ConnectionTokenRequest.md b/docs/ConnectionTokenRequest.md new file mode 100644 index 000000000..f37838db6 --- /dev/null +++ b/docs/ConnectionTokenRequest.md @@ -0,0 +1,32 @@ +# ConnectionTokenRequest + +ConnectionToken Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [optional] +**provider** | **int** | | +**endpoint** | **UUID** | | + +## Example + +```python +from authentik_client.models.connection_token_request import ConnectionTokenRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ConnectionTokenRequest from a JSON string +connection_token_request_instance = ConnectionTokenRequest.from_json(json) +# print the JSON string representation of the object +print(ConnectionTokenRequest.to_json()) + +# convert the object into a dict +connection_token_request_dict = connection_token_request_instance.to_dict() +# create an instance of ConnectionTokenRequest from a dict +connection_token_request_from_dict = ConnectionTokenRequest.from_dict(connection_token_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Connector.md b/docs/Connector.md new file mode 100644 index 000000000..36359e5ca --- /dev/null +++ b/docs/Connector.md @@ -0,0 +1,35 @@ +# Connector + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | +**enabled** | **bool** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.connector import Connector + +# TODO update the JSON string below +json = "{}" +# create an instance of Connector from a JSON string +connector_instance = Connector.from_json(json) +# print the JSON string representation of the object +print(Connector.to_json()) + +# convert the object into a dict +connector_dict = connector_instance.to_dict() +# create an instance of Connector from a dict +connector_from_dict = Connector.from_dict(connector_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ConsentChallenge.md b/docs/ConsentChallenge.md new file mode 100644 index 000000000..8eed9ec98 --- /dev/null +++ b/docs/ConsentChallenge.md @@ -0,0 +1,38 @@ +# ConsentChallenge + +Challenge info for consent screens + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-consent'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**header_text** | **str** | | [optional] +**permissions** | [**List[ConsentPermission]**](ConsentPermission.md) | | +**additional_permissions** | [**List[ConsentPermission]**](ConsentPermission.md) | | +**token** | **str** | | + +## Example + +```python +from authentik_client.models.consent_challenge import ConsentChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of ConsentChallenge from a JSON string +consent_challenge_instance = ConsentChallenge.from_json(json) +# print the JSON string representation of the object +print(ConsentChallenge.to_json()) + +# convert the object into a dict +consent_challenge_dict = consent_challenge_instance.to_dict() +# create an instance of ConsentChallenge from a dict +consent_challenge_from_dict = ConsentChallenge.from_dict(consent_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ConsentChallengeResponseRequest.md b/docs/ConsentChallengeResponseRequest.md new file mode 100644 index 000000000..8b77fa850 --- /dev/null +++ b/docs/ConsentChallengeResponseRequest.md @@ -0,0 +1,31 @@ +# ConsentChallengeResponseRequest + +Consent challenge response, any valid response request is valid + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-consent'] +**token** | **str** | | + +## Example + +```python +from authentik_client.models.consent_challenge_response_request import ConsentChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ConsentChallengeResponseRequest from a JSON string +consent_challenge_response_request_instance = ConsentChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(ConsentChallengeResponseRequest.to_json()) + +# convert the object into a dict +consent_challenge_response_request_dict = consent_challenge_response_request_instance.to_dict() +# create an instance of ConsentChallengeResponseRequest from a dict +consent_challenge_response_request_from_dict = ConsentChallengeResponseRequest.from_dict(consent_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ConsentModeEnum.md b/docs/ConsentModeEnum.md new file mode 100644 index 000000000..da439cfda --- /dev/null +++ b/docs/ConsentModeEnum.md @@ -0,0 +1,14 @@ +# ConsentModeEnum + + +## Enum + +* `ALWAYS_REQUIRE` (value: `'always_require'`) + +* `PERMANENT` (value: `'permanent'`) + +* `EXPIRING` (value: `'expiring'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ConsentPermission.md b/docs/ConsentPermission.md new file mode 100644 index 000000000..842f4337a --- /dev/null +++ b/docs/ConsentPermission.md @@ -0,0 +1,31 @@ +# ConsentPermission + +Permission used for consent + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**id** | **str** | | + +## Example + +```python +from authentik_client.models.consent_permission import ConsentPermission + +# TODO update the JSON string below +json = "{}" +# create an instance of ConsentPermission from a JSON string +consent_permission_instance = ConsentPermission.from_json(json) +# print the JSON string representation of the object +print(ConsentPermission.to_json()) + +# convert the object into a dict +consent_permission_dict = consent_permission_instance.to_dict() +# create an instance of ConsentPermission from a dict +consent_permission_from_dict = ConsentPermission.from_dict(consent_permission_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ConsentStage.md b/docs/ConsentStage.md new file mode 100644 index 000000000..ca0abe9e2 --- /dev/null +++ b/docs/ConsentStage.md @@ -0,0 +1,38 @@ +# ConsentStage + +ConsentStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**mode** | [**ConsentModeEnum**](ConsentModeEnum.md) | | [optional] +**consent_expire_in** | **str** | Offset after which consent expires. (Format: hours=1;minutes=2;seconds=3). | [optional] + +## Example + +```python +from authentik_client.models.consent_stage import ConsentStage + +# TODO update the JSON string below +json = "{}" +# create an instance of ConsentStage from a JSON string +consent_stage_instance = ConsentStage.from_json(json) +# print the JSON string representation of the object +print(ConsentStage.to_json()) + +# convert the object into a dict +consent_stage_dict = consent_stage_instance.to_dict() +# create an instance of ConsentStage from a dict +consent_stage_from_dict = ConsentStage.from_dict(consent_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ConsentStageRequest.md b/docs/ConsentStageRequest.md new file mode 100644 index 000000000..2961a5f04 --- /dev/null +++ b/docs/ConsentStageRequest.md @@ -0,0 +1,32 @@ +# ConsentStageRequest + +ConsentStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**mode** | [**ConsentModeEnum**](ConsentModeEnum.md) | | [optional] +**consent_expire_in** | **str** | Offset after which consent expires. (Format: hours=1;minutes=2;seconds=3). | [optional] + +## Example + +```python +from authentik_client.models.consent_stage_request import ConsentStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ConsentStageRequest from a JSON string +consent_stage_request_instance = ConsentStageRequest.from_json(json) +# print the JSON string representation of the object +print(ConsentStageRequest.to_json()) + +# convert the object into a dict +consent_stage_request_dict = consent_stage_request_instance.to_dict() +# create an instance of ConsentStageRequest from a dict +consent_stage_request_from_dict = ConsentStageRequest.from_dict(consent_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ContentType.md b/docs/ContentType.md new file mode 100644 index 000000000..610d88f67 --- /dev/null +++ b/docs/ContentType.md @@ -0,0 +1,32 @@ +# ContentType + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | [readonly] +**app_label** | **str** | | [readonly] +**model** | **str** | | [readonly] +**verbose_name_plural** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.content_type import ContentType + +# TODO update the JSON string below +json = "{}" +# create an instance of ContentType from a JSON string +content_type_instance = ContentType.from_json(json) +# print the JSON string representation of the object +print(ContentType.to_json()) + +# convert the object into a dict +content_type_dict = content_type_instance.to_dict() +# create an instance of ContentType from a dict +content_type_from_dict = ContentType.from_dict(content_type_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ContentTypeEnum.md b/docs/ContentTypeEnum.md new file mode 100644 index 000000000..cb77df928 --- /dev/null +++ b/docs/ContentTypeEnum.md @@ -0,0 +1,14 @@ +# ContentTypeEnum + + +## Enum + +* `AUTHENTIK_CORE_DOT_APPLICATION` (value: `'authentik_core.application'`) + +* `AUTHENTIK_CORE_DOT_GROUP` (value: `'authentik_core.group'`) + +* `AUTHENTIK_RBAC_DOT_ROLE` (value: `'authentik_rbac.role'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ContextualFlowInfo.md b/docs/ContextualFlowInfo.md new file mode 100644 index 000000000..18f4ab0cf --- /dev/null +++ b/docs/ContextualFlowInfo.md @@ -0,0 +1,34 @@ +# ContextualFlowInfo + +Contextual flow information for a challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**title** | **str** | | [optional] +**background** | **str** | | [optional] +**background_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [optional] +**cancel_url** | **str** | | +**layout** | [**ContextualFlowInfoLayoutEnum**](ContextualFlowInfoLayoutEnum.md) | | + +## Example + +```python +from authentik_client.models.contextual_flow_info import ContextualFlowInfo + +# TODO update the JSON string below +json = "{}" +# create an instance of ContextualFlowInfo from a JSON string +contextual_flow_info_instance = ContextualFlowInfo.from_json(json) +# print the JSON string representation of the object +print(ContextualFlowInfo.to_json()) + +# convert the object into a dict +contextual_flow_info_dict = contextual_flow_info_instance.to_dict() +# create an instance of ContextualFlowInfo from a dict +contextual_flow_info_from_dict = ContextualFlowInfo.from_dict(contextual_flow_info_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ContextualFlowInfoLayoutEnum.md b/docs/ContextualFlowInfoLayoutEnum.md new file mode 100644 index 000000000..b99864b30 --- /dev/null +++ b/docs/ContextualFlowInfoLayoutEnum.md @@ -0,0 +1,22 @@ +# ContextualFlowInfoLayoutEnum + + +## Enum + +* `STACKED` (value: `'stacked'`) + +* `CONTENT_LEFT` (value: `'content_left'`) + +* `CONTENT_RIGHT` (value: `'content_right'`) + +* `SIDEBAR_LEFT` (value: `'sidebar_left'`) + +* `SIDEBAR_RIGHT` (value: `'sidebar_right'`) + +* `SIDEBAR_LEFT_FRAME_BACKGROUND` (value: `'sidebar_left_frame_background'`) + +* `SIDEBAR_RIGHT_FRAME_BACKGROUND` (value: `'sidebar_right_frame_background'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CoreApi.md b/docs/CoreApi.md new file mode 100644 index 000000000..fc647f2f1 --- /dev/null +++ b/docs/CoreApi.md @@ -0,0 +1,5675 @@ +# authentik_client.CoreApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**core_application_entitlements_create**](CoreApi.md#core_application_entitlements_create) | **POST** /core/application_entitlements/ | +[**core_application_entitlements_destroy**](CoreApi.md#core_application_entitlements_destroy) | **DELETE** /core/application_entitlements/{pbm_uuid}/ | +[**core_application_entitlements_list**](CoreApi.md#core_application_entitlements_list) | **GET** /core/application_entitlements/ | +[**core_application_entitlements_partial_update**](CoreApi.md#core_application_entitlements_partial_update) | **PATCH** /core/application_entitlements/{pbm_uuid}/ | +[**core_application_entitlements_retrieve**](CoreApi.md#core_application_entitlements_retrieve) | **GET** /core/application_entitlements/{pbm_uuid}/ | +[**core_application_entitlements_update**](CoreApi.md#core_application_entitlements_update) | **PUT** /core/application_entitlements/{pbm_uuid}/ | +[**core_application_entitlements_used_by_list**](CoreApi.md#core_application_entitlements_used_by_list) | **GET** /core/application_entitlements/{pbm_uuid}/used_by/ | +[**core_applications_check_access_retrieve**](CoreApi.md#core_applications_check_access_retrieve) | **GET** /core/applications/{slug}/check_access/ | +[**core_applications_create**](CoreApi.md#core_applications_create) | **POST** /core/applications/ | +[**core_applications_destroy**](CoreApi.md#core_applications_destroy) | **DELETE** /core/applications/{slug}/ | +[**core_applications_list**](CoreApi.md#core_applications_list) | **GET** /core/applications/ | +[**core_applications_partial_update**](CoreApi.md#core_applications_partial_update) | **PATCH** /core/applications/{slug}/ | +[**core_applications_retrieve**](CoreApi.md#core_applications_retrieve) | **GET** /core/applications/{slug}/ | +[**core_applications_update**](CoreApi.md#core_applications_update) | **PUT** /core/applications/{slug}/ | +[**core_applications_used_by_list**](CoreApi.md#core_applications_used_by_list) | **GET** /core/applications/{slug}/used_by/ | +[**core_authenticated_sessions_bulk_delete_destroy**](CoreApi.md#core_authenticated_sessions_bulk_delete_destroy) | **DELETE** /core/authenticated_sessions/bulk_delete/ | +[**core_authenticated_sessions_destroy**](CoreApi.md#core_authenticated_sessions_destroy) | **DELETE** /core/authenticated_sessions/{uuid}/ | +[**core_authenticated_sessions_list**](CoreApi.md#core_authenticated_sessions_list) | **GET** /core/authenticated_sessions/ | +[**core_authenticated_sessions_retrieve**](CoreApi.md#core_authenticated_sessions_retrieve) | **GET** /core/authenticated_sessions/{uuid}/ | +[**core_authenticated_sessions_used_by_list**](CoreApi.md#core_authenticated_sessions_used_by_list) | **GET** /core/authenticated_sessions/{uuid}/used_by/ | +[**core_brands_create**](CoreApi.md#core_brands_create) | **POST** /core/brands/ | +[**core_brands_current_retrieve**](CoreApi.md#core_brands_current_retrieve) | **GET** /core/brands/current/ | +[**core_brands_destroy**](CoreApi.md#core_brands_destroy) | **DELETE** /core/brands/{brand_uuid}/ | +[**core_brands_list**](CoreApi.md#core_brands_list) | **GET** /core/brands/ | +[**core_brands_partial_update**](CoreApi.md#core_brands_partial_update) | **PATCH** /core/brands/{brand_uuid}/ | +[**core_brands_retrieve**](CoreApi.md#core_brands_retrieve) | **GET** /core/brands/{brand_uuid}/ | +[**core_brands_update**](CoreApi.md#core_brands_update) | **PUT** /core/brands/{brand_uuid}/ | +[**core_brands_used_by_list**](CoreApi.md#core_brands_used_by_list) | **GET** /core/brands/{brand_uuid}/used_by/ | +[**core_groups_add_user_create**](CoreApi.md#core_groups_add_user_create) | **POST** /core/groups/{group_uuid}/add_user/ | +[**core_groups_create**](CoreApi.md#core_groups_create) | **POST** /core/groups/ | +[**core_groups_destroy**](CoreApi.md#core_groups_destroy) | **DELETE** /core/groups/{group_uuid}/ | +[**core_groups_list**](CoreApi.md#core_groups_list) | **GET** /core/groups/ | +[**core_groups_partial_update**](CoreApi.md#core_groups_partial_update) | **PATCH** /core/groups/{group_uuid}/ | +[**core_groups_remove_user_create**](CoreApi.md#core_groups_remove_user_create) | **POST** /core/groups/{group_uuid}/remove_user/ | +[**core_groups_retrieve**](CoreApi.md#core_groups_retrieve) | **GET** /core/groups/{group_uuid}/ | +[**core_groups_update**](CoreApi.md#core_groups_update) | **PUT** /core/groups/{group_uuid}/ | +[**core_groups_used_by_list**](CoreApi.md#core_groups_used_by_list) | **GET** /core/groups/{group_uuid}/used_by/ | +[**core_tokens_create**](CoreApi.md#core_tokens_create) | **POST** /core/tokens/ | +[**core_tokens_destroy**](CoreApi.md#core_tokens_destroy) | **DELETE** /core/tokens/{identifier}/ | +[**core_tokens_list**](CoreApi.md#core_tokens_list) | **GET** /core/tokens/ | +[**core_tokens_partial_update**](CoreApi.md#core_tokens_partial_update) | **PATCH** /core/tokens/{identifier}/ | +[**core_tokens_retrieve**](CoreApi.md#core_tokens_retrieve) | **GET** /core/tokens/{identifier}/ | +[**core_tokens_set_key_create**](CoreApi.md#core_tokens_set_key_create) | **POST** /core/tokens/{identifier}/set_key/ | +[**core_tokens_update**](CoreApi.md#core_tokens_update) | **PUT** /core/tokens/{identifier}/ | +[**core_tokens_used_by_list**](CoreApi.md#core_tokens_used_by_list) | **GET** /core/tokens/{identifier}/used_by/ | +[**core_tokens_view_key_retrieve**](CoreApi.md#core_tokens_view_key_retrieve) | **GET** /core/tokens/{identifier}/view_key/ | +[**core_transactional_applications_update**](CoreApi.md#core_transactional_applications_update) | **PUT** /core/transactional/applications/ | +[**core_user_consent_destroy**](CoreApi.md#core_user_consent_destroy) | **DELETE** /core/user_consent/{id}/ | +[**core_user_consent_list**](CoreApi.md#core_user_consent_list) | **GET** /core/user_consent/ | +[**core_user_consent_retrieve**](CoreApi.md#core_user_consent_retrieve) | **GET** /core/user_consent/{id}/ | +[**core_user_consent_used_by_list**](CoreApi.md#core_user_consent_used_by_list) | **GET** /core/user_consent/{id}/used_by/ | +[**core_users_account_lockdown_create**](CoreApi.md#core_users_account_lockdown_create) | **POST** /core/users/account_lockdown/ | +[**core_users_create**](CoreApi.md#core_users_create) | **POST** /core/users/ | +[**core_users_destroy**](CoreApi.md#core_users_destroy) | **DELETE** /core/users/{id}/ | +[**core_users_export_create**](CoreApi.md#core_users_export_create) | **POST** /core/users/export/ | +[**core_users_impersonate_create**](CoreApi.md#core_users_impersonate_create) | **POST** /core/users/{id}/impersonate/ | +[**core_users_impersonate_end_retrieve**](CoreApi.md#core_users_impersonate_end_retrieve) | **GET** /core/users/impersonate_end/ | +[**core_users_list**](CoreApi.md#core_users_list) | **GET** /core/users/ | +[**core_users_me_retrieve**](CoreApi.md#core_users_me_retrieve) | **GET** /core/users/me/ | +[**core_users_partial_update**](CoreApi.md#core_users_partial_update) | **PATCH** /core/users/{id}/ | +[**core_users_paths_retrieve**](CoreApi.md#core_users_paths_retrieve) | **GET** /core/users/paths/ | +[**core_users_recovery_create**](CoreApi.md#core_users_recovery_create) | **POST** /core/users/{id}/recovery/ | +[**core_users_recovery_email_create**](CoreApi.md#core_users_recovery_email_create) | **POST** /core/users/{id}/recovery_email/ | +[**core_users_retrieve**](CoreApi.md#core_users_retrieve) | **GET** /core/users/{id}/ | +[**core_users_service_account_create**](CoreApi.md#core_users_service_account_create) | **POST** /core/users/service_account/ | +[**core_users_set_password_create**](CoreApi.md#core_users_set_password_create) | **POST** /core/users/{id}/set_password/ | +[**core_users_set_password_hash_create**](CoreApi.md#core_users_set_password_hash_create) | **POST** /core/users/{id}/set_password_hash/ | +[**core_users_update**](CoreApi.md#core_users_update) | **PUT** /core/users/{id}/ | +[**core_users_used_by_list**](CoreApi.md#core_users_used_by_list) | **GET** /core/users/{id}/used_by/ | + + +# **core_application_entitlements_create** +> ApplicationEntitlement core_application_entitlements_create(application_entitlement_request) + +ApplicationEntitlement Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.application_entitlement import ApplicationEntitlement +from authentik_client.models.application_entitlement_request import ApplicationEntitlementRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + application_entitlement_request = authentik_client.ApplicationEntitlementRequest() # ApplicationEntitlementRequest | + + try: + api_response = api_instance.core_application_entitlements_create(application_entitlement_request) + print("The response of CoreApi->core_application_entitlements_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_application_entitlements_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **application_entitlement_request** | [**ApplicationEntitlementRequest**](ApplicationEntitlementRequest.md)| | + +### Return type + +[**ApplicationEntitlement**](ApplicationEntitlement.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_application_entitlements_destroy** +> core_application_entitlements_destroy(pbm_uuid) + +ApplicationEntitlement Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Application Entitlement. + + try: + api_instance.core_application_entitlements_destroy(pbm_uuid) + except Exception as e: + print("Exception when calling CoreApi->core_application_entitlements_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Application Entitlement. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_application_entitlements_list** +> PaginatedApplicationEntitlementList core_application_entitlements_list(app=app, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, search=search) + +ApplicationEntitlement Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_application_entitlement_list import PaginatedApplicationEntitlementList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + app = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.core_application_entitlements_list(app=app, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, search=search) + print("The response of CoreApi->core_application_entitlements_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_application_entitlements_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **app** | **UUID**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pbm_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedApplicationEntitlementList**](PaginatedApplicationEntitlementList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_application_entitlements_partial_update** +> ApplicationEntitlement core_application_entitlements_partial_update(pbm_uuid, patched_application_entitlement_request=patched_application_entitlement_request) + +ApplicationEntitlement Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.application_entitlement import ApplicationEntitlement +from authentik_client.models.patched_application_entitlement_request import PatchedApplicationEntitlementRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Application Entitlement. + patched_application_entitlement_request = authentik_client.PatchedApplicationEntitlementRequest() # PatchedApplicationEntitlementRequest | (optional) + + try: + api_response = api_instance.core_application_entitlements_partial_update(pbm_uuid, patched_application_entitlement_request=patched_application_entitlement_request) + print("The response of CoreApi->core_application_entitlements_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_application_entitlements_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Application Entitlement. | + **patched_application_entitlement_request** | [**PatchedApplicationEntitlementRequest**](PatchedApplicationEntitlementRequest.md)| | [optional] + +### Return type + +[**ApplicationEntitlement**](ApplicationEntitlement.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_application_entitlements_retrieve** +> ApplicationEntitlement core_application_entitlements_retrieve(pbm_uuid) + +ApplicationEntitlement Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.application_entitlement import ApplicationEntitlement +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Application Entitlement. + + try: + api_response = api_instance.core_application_entitlements_retrieve(pbm_uuid) + print("The response of CoreApi->core_application_entitlements_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_application_entitlements_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Application Entitlement. | + +### Return type + +[**ApplicationEntitlement**](ApplicationEntitlement.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_application_entitlements_update** +> ApplicationEntitlement core_application_entitlements_update(pbm_uuid, application_entitlement_request) + +ApplicationEntitlement Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.application_entitlement import ApplicationEntitlement +from authentik_client.models.application_entitlement_request import ApplicationEntitlementRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Application Entitlement. + application_entitlement_request = authentik_client.ApplicationEntitlementRequest() # ApplicationEntitlementRequest | + + try: + api_response = api_instance.core_application_entitlements_update(pbm_uuid, application_entitlement_request) + print("The response of CoreApi->core_application_entitlements_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_application_entitlements_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Application Entitlement. | + **application_entitlement_request** | [**ApplicationEntitlementRequest**](ApplicationEntitlementRequest.md)| | + +### Return type + +[**ApplicationEntitlement**](ApplicationEntitlement.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_application_entitlements_used_by_list** +> List[UsedBy] core_application_entitlements_used_by_list(pbm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Application Entitlement. + + try: + api_response = api_instance.core_application_entitlements_used_by_list(pbm_uuid) + print("The response of CoreApi->core_application_entitlements_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_application_entitlements_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Application Entitlement. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_applications_check_access_retrieve** +> PolicyTestResult core_applications_check_access_retrieve(slug, for_user=for_user) + +Check access to a single application by slug + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.policy_test_result import PolicyTestResult +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + slug = 'slug_example' # str | + for_user = 56 # int | (optional) + + try: + api_response = api_instance.core_applications_check_access_retrieve(slug, for_user=for_user) + print("The response of CoreApi->core_applications_check_access_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_applications_check_access_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **for_user** | **int**| | [optional] + +### Return type + +[**PolicyTestResult**](PolicyTestResult.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_applications_create** +> Application core_applications_create(application_request) + +Application Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.application import Application +from authentik_client.models.application_request import ApplicationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + application_request = authentik_client.ApplicationRequest() # ApplicationRequest | + + try: + api_response = api_instance.core_applications_create(application_request) + print("The response of CoreApi->core_applications_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_applications_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **application_request** | [**ApplicationRequest**](ApplicationRequest.md)| | + +### Return type + +[**Application**](Application.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_applications_destroy** +> core_applications_destroy(slug) + +Application Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.core_applications_destroy(slug) + except Exception as e: + print("Exception when calling CoreApi->core_applications_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_applications_list** +> PaginatedApplicationList core_applications_list(for_user=for_user, group=group, meta_description=meta_description, meta_launch_url=meta_launch_url, meta_publisher=meta_publisher, name=name, only_with_launch_url=only_with_launch_url, ordering=ordering, page=page, page_size=page_size, search=search, slug=slug, superuser_full_list=superuser_full_list) + +Custom list method that checks Policy based access instead of guardian + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_application_list import PaginatedApplicationList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + for_user = 56 # int | (optional) + group = 'group_example' # str | (optional) + meta_description = 'meta_description_example' # str | (optional) + meta_launch_url = 'meta_launch_url_example' # str | (optional) + meta_publisher = 'meta_publisher_example' # str | (optional) + name = 'name_example' # str | (optional) + only_with_launch_url = True # bool | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + slug = 'slug_example' # str | (optional) + superuser_full_list = True # bool | (optional) + + try: + api_response = api_instance.core_applications_list(for_user=for_user, group=group, meta_description=meta_description, meta_launch_url=meta_launch_url, meta_publisher=meta_publisher, name=name, only_with_launch_url=only_with_launch_url, ordering=ordering, page=page, page_size=page_size, search=search, slug=slug, superuser_full_list=superuser_full_list) + print("The response of CoreApi->core_applications_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_applications_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **for_user** | **int**| | [optional] + **group** | **str**| | [optional] + **meta_description** | **str**| | [optional] + **meta_launch_url** | **str**| | [optional] + **meta_publisher** | **str**| | [optional] + **name** | **str**| | [optional] + **only_with_launch_url** | **bool**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **slug** | **str**| | [optional] + **superuser_full_list** | **bool**| | [optional] + +### Return type + +[**PaginatedApplicationList**](PaginatedApplicationList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_applications_partial_update** +> Application core_applications_partial_update(slug, patched_application_request=patched_application_request) + +Application Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.application import Application +from authentik_client.models.patched_application_request import PatchedApplicationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + slug = 'slug_example' # str | + patched_application_request = authentik_client.PatchedApplicationRequest() # PatchedApplicationRequest | (optional) + + try: + api_response = api_instance.core_applications_partial_update(slug, patched_application_request=patched_application_request) + print("The response of CoreApi->core_applications_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_applications_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **patched_application_request** | [**PatchedApplicationRequest**](PatchedApplicationRequest.md)| | [optional] + +### Return type + +[**Application**](Application.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_applications_retrieve** +> Application core_applications_retrieve(slug) + +Application Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.application import Application +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.core_applications_retrieve(slug) + print("The response of CoreApi->core_applications_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_applications_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**Application**](Application.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_applications_update** +> Application core_applications_update(slug, application_request) + +Application Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.application import Application +from authentik_client.models.application_request import ApplicationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + slug = 'slug_example' # str | + application_request = authentik_client.ApplicationRequest() # ApplicationRequest | + + try: + api_response = api_instance.core_applications_update(slug, application_request) + print("The response of CoreApi->core_applications_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_applications_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **application_request** | [**ApplicationRequest**](ApplicationRequest.md)| | + +### Return type + +[**Application**](Application.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_applications_used_by_list** +> List[UsedBy] core_applications_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.core_applications_used_by_list(slug) + print("The response of CoreApi->core_applications_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_applications_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_authenticated_sessions_bulk_delete_destroy** +> BulkDeleteSessionResponse core_authenticated_sessions_bulk_delete_destroy(user_pks) + +Bulk revoke all sessions for multiple users + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.bulk_delete_session_response import BulkDeleteSessionResponse +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + user_pks = [56] # List[int] | List of user IDs to revoke all sessions for + + try: + api_response = api_instance.core_authenticated_sessions_bulk_delete_destroy(user_pks) + print("The response of CoreApi->core_authenticated_sessions_bulk_delete_destroy:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_authenticated_sessions_bulk_delete_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_pks** | [**List[int]**](int.md)| List of user IDs to revoke all sessions for | + +### Return type + +[**BulkDeleteSessionResponse**](BulkDeleteSessionResponse.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_authenticated_sessions_destroy** +> core_authenticated_sessions_destroy(uuid) + +AuthenticatedSession Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | + + try: + api_instance.core_authenticated_sessions_destroy(uuid) + except Exception as e: + print("Exception when calling CoreApi->core_authenticated_sessions_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_authenticated_sessions_list** +> PaginatedAuthenticatedSessionList core_authenticated_sessions_list(ordering=ordering, page=page, page_size=page_size, search=search, session__last_ip=session__last_ip, session__last_user_agent=session__last_user_agent, user__username=user__username) + +AuthenticatedSession Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_authenticated_session_list import PaginatedAuthenticatedSessionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + session__last_ip = 'session__last_ip_example' # str | (optional) + session__last_user_agent = 'session__last_user_agent_example' # str | (optional) + user__username = 'user__username_example' # str | (optional) + + try: + api_response = api_instance.core_authenticated_sessions_list(ordering=ordering, page=page, page_size=page_size, search=search, session__last_ip=session__last_ip, session__last_user_agent=session__last_user_agent, user__username=user__username) + print("The response of CoreApi->core_authenticated_sessions_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_authenticated_sessions_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **session__last_ip** | **str**| | [optional] + **session__last_user_agent** | **str**| | [optional] + **user__username** | **str**| | [optional] + +### Return type + +[**PaginatedAuthenticatedSessionList**](PaginatedAuthenticatedSessionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_authenticated_sessions_retrieve** +> AuthenticatedSession core_authenticated_sessions_retrieve(uuid) + +AuthenticatedSession Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticated_session import AuthenticatedSession +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | + + try: + api_response = api_instance.core_authenticated_sessions_retrieve(uuid) + print("The response of CoreApi->core_authenticated_sessions_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_authenticated_sessions_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| | + +### Return type + +[**AuthenticatedSession**](AuthenticatedSession.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_authenticated_sessions_used_by_list** +> List[UsedBy] core_authenticated_sessions_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | + + try: + api_response = api_instance.core_authenticated_sessions_used_by_list(uuid) + print("The response of CoreApi->core_authenticated_sessions_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_authenticated_sessions_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_brands_create** +> Brand core_brands_create(brand_request) + +Brand Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.brand import Brand +from authentik_client.models.brand_request import BrandRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + brand_request = authentik_client.BrandRequest() # BrandRequest | + + try: + api_response = api_instance.core_brands_create(brand_request) + print("The response of CoreApi->core_brands_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_brands_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **brand_request** | [**BrandRequest**](BrandRequest.md)| | + +### Return type + +[**Brand**](Brand.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_brands_current_retrieve** +> CurrentBrand core_brands_current_retrieve() + +Get current brand + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.current_brand import CurrentBrand +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + + try: + api_response = api_instance.core_brands_current_retrieve() + print("The response of CoreApi->core_brands_current_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_brands_current_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**CurrentBrand**](CurrentBrand.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_brands_destroy** +> core_brands_destroy(brand_uuid) + +Brand Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + brand_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Brand. + + try: + api_instance.core_brands_destroy(brand_uuid) + except Exception as e: + print("Exception when calling CoreApi->core_brands_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **brand_uuid** | **UUID**| A UUID string identifying this Brand. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_brands_list** +> PaginatedBrandList core_brands_list(brand_uuid=brand_uuid, branding_default_flow_background=branding_default_flow_background, branding_favicon=branding_favicon, branding_logo=branding_logo, branding_title=branding_title, client_certificates=client_certificates, default=default, domain=domain, flow_authentication=flow_authentication, flow_device_code=flow_device_code, flow_invalidation=flow_invalidation, flow_lockdown=flow_lockdown, flow_recovery=flow_recovery, flow_unenrollment=flow_unenrollment, flow_user_settings=flow_user_settings, ordering=ordering, page=page, page_size=page_size, search=search, web_certificate=web_certificate) + +Brand Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_brand_list import PaginatedBrandList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + brand_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + branding_default_flow_background = 'branding_default_flow_background_example' # str | (optional) + branding_favicon = 'branding_favicon_example' # str | (optional) + branding_logo = 'branding_logo_example' # str | (optional) + branding_title = 'branding_title_example' # str | (optional) + client_certificates = None # List[UUID] | (optional) + default = True # bool | (optional) + domain = 'domain_example' # str | (optional) + flow_authentication = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + flow_device_code = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + flow_invalidation = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + flow_lockdown = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + flow_recovery = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + flow_unenrollment = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + flow_user_settings = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + web_certificate = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.core_brands_list(brand_uuid=brand_uuid, branding_default_flow_background=branding_default_flow_background, branding_favicon=branding_favicon, branding_logo=branding_logo, branding_title=branding_title, client_certificates=client_certificates, default=default, domain=domain, flow_authentication=flow_authentication, flow_device_code=flow_device_code, flow_invalidation=flow_invalidation, flow_lockdown=flow_lockdown, flow_recovery=flow_recovery, flow_unenrollment=flow_unenrollment, flow_user_settings=flow_user_settings, ordering=ordering, page=page, page_size=page_size, search=search, web_certificate=web_certificate) + print("The response of CoreApi->core_brands_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_brands_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **brand_uuid** | **UUID**| | [optional] + **branding_default_flow_background** | **str**| | [optional] + **branding_favicon** | **str**| | [optional] + **branding_logo** | **str**| | [optional] + **branding_title** | **str**| | [optional] + **client_certificates** | [**List[UUID]**](UUID.md)| | [optional] + **default** | **bool**| | [optional] + **domain** | **str**| | [optional] + **flow_authentication** | **UUID**| | [optional] + **flow_device_code** | **UUID**| | [optional] + **flow_invalidation** | **UUID**| | [optional] + **flow_lockdown** | **UUID**| | [optional] + **flow_recovery** | **UUID**| | [optional] + **flow_unenrollment** | **UUID**| | [optional] + **flow_user_settings** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **web_certificate** | **UUID**| | [optional] + +### Return type + +[**PaginatedBrandList**](PaginatedBrandList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_brands_partial_update** +> Brand core_brands_partial_update(brand_uuid, patched_brand_request=patched_brand_request) + +Brand Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.brand import Brand +from authentik_client.models.patched_brand_request import PatchedBrandRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + brand_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Brand. + patched_brand_request = authentik_client.PatchedBrandRequest() # PatchedBrandRequest | (optional) + + try: + api_response = api_instance.core_brands_partial_update(brand_uuid, patched_brand_request=patched_brand_request) + print("The response of CoreApi->core_brands_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_brands_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **brand_uuid** | **UUID**| A UUID string identifying this Brand. | + **patched_brand_request** | [**PatchedBrandRequest**](PatchedBrandRequest.md)| | [optional] + +### Return type + +[**Brand**](Brand.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_brands_retrieve** +> Brand core_brands_retrieve(brand_uuid) + +Brand Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.brand import Brand +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + brand_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Brand. + + try: + api_response = api_instance.core_brands_retrieve(brand_uuid) + print("The response of CoreApi->core_brands_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_brands_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **brand_uuid** | **UUID**| A UUID string identifying this Brand. | + +### Return type + +[**Brand**](Brand.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_brands_update** +> Brand core_brands_update(brand_uuid, brand_request) + +Brand Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.brand import Brand +from authentik_client.models.brand_request import BrandRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + brand_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Brand. + brand_request = authentik_client.BrandRequest() # BrandRequest | + + try: + api_response = api_instance.core_brands_update(brand_uuid, brand_request) + print("The response of CoreApi->core_brands_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_brands_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **brand_uuid** | **UUID**| A UUID string identifying this Brand. | + **brand_request** | [**BrandRequest**](BrandRequest.md)| | + +### Return type + +[**Brand**](Brand.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_brands_used_by_list** +> List[UsedBy] core_brands_used_by_list(brand_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + brand_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Brand. + + try: + api_response = api_instance.core_brands_used_by_list(brand_uuid) + print("The response of CoreApi->core_brands_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_brands_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **brand_uuid** | **UUID**| A UUID string identifying this Brand. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_groups_add_user_create** +> core_groups_add_user_create(group_uuid, user_account_request) + +Add user to group + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_account_request import UserAccountRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Group. + user_account_request = authentik_client.UserAccountRequest() # UserAccountRequest | + + try: + api_instance.core_groups_add_user_create(group_uuid, user_account_request) + except Exception as e: + print("Exception when calling CoreApi->core_groups_add_user_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_uuid** | **UUID**| A UUID string identifying this Group. | + **user_account_request** | [**UserAccountRequest**](UserAccountRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | User added | - | +**404** | User not found | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_groups_create** +> Group core_groups_create(group_request) + +Group Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group import Group +from authentik_client.models.group_request import GroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + group_request = authentik_client.GroupRequest() # GroupRequest | + + try: + api_response = api_instance.core_groups_create(group_request) + print("The response of CoreApi->core_groups_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_groups_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_request** | [**GroupRequest**](GroupRequest.md)| | + +### Return type + +[**Group**](Group.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_groups_destroy** +> core_groups_destroy(group_uuid) + +Group Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Group. + + try: + api_instance.core_groups_destroy(group_uuid) + except Exception as e: + print("Exception when calling CoreApi->core_groups_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_uuid** | **UUID**| A UUID string identifying this Group. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_groups_list** +> PaginatedGroupList core_groups_list(attributes=attributes, include_children=include_children, include_inherited_roles=include_inherited_roles, include_parents=include_parents, include_users=include_users, is_superuser=is_superuser, members_by_pk=members_by_pk, members_by_username=members_by_username, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Group Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_group_list import PaginatedGroupList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + attributes = 'attributes_example' # str | Attributes (optional) + include_children = False # bool | (optional) (default to False) + include_inherited_roles = False # bool | (optional) (default to False) + include_parents = False # bool | (optional) (default to False) + include_users = True # bool | (optional) (default to True) + is_superuser = True # bool | (optional) + members_by_pk = [56] # List[int] | (optional) + members_by_username = ['members_by_username_example'] # List[str] | Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only. (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.core_groups_list(attributes=attributes, include_children=include_children, include_inherited_roles=include_inherited_roles, include_parents=include_parents, include_users=include_users, is_superuser=is_superuser, members_by_pk=members_by_pk, members_by_username=members_by_username, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of CoreApi->core_groups_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_groups_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **attributes** | **str**| Attributes | [optional] + **include_children** | **bool**| | [optional] [default to False] + **include_inherited_roles** | **bool**| | [optional] [default to False] + **include_parents** | **bool**| | [optional] [default to False] + **include_users** | **bool**| | [optional] [default to True] + **is_superuser** | **bool**| | [optional] + **members_by_pk** | [**List[int]**](int.md)| | [optional] + **members_by_username** | [**List[str]**](str.md)| Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only. | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedGroupList**](PaginatedGroupList.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_groups_partial_update** +> Group core_groups_partial_update(group_uuid, patched_group_request=patched_group_request) + +Group Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group import Group +from authentik_client.models.patched_group_request import PatchedGroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Group. + patched_group_request = authentik_client.PatchedGroupRequest() # PatchedGroupRequest | (optional) + + try: + api_response = api_instance.core_groups_partial_update(group_uuid, patched_group_request=patched_group_request) + print("The response of CoreApi->core_groups_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_groups_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_uuid** | **UUID**| A UUID string identifying this Group. | + **patched_group_request** | [**PatchedGroupRequest**](PatchedGroupRequest.md)| | [optional] + +### Return type + +[**Group**](Group.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_groups_remove_user_create** +> core_groups_remove_user_create(group_uuid, user_account_request) + +Remove user from group + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_account_request import UserAccountRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Group. + user_account_request = authentik_client.UserAccountRequest() # UserAccountRequest | + + try: + api_instance.core_groups_remove_user_create(group_uuid, user_account_request) + except Exception as e: + print("Exception when calling CoreApi->core_groups_remove_user_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_uuid** | **UUID**| A UUID string identifying this Group. | + **user_account_request** | [**UserAccountRequest**](UserAccountRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | User removed | - | +**404** | User not found | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_groups_retrieve** +> Group core_groups_retrieve(group_uuid, include_children=include_children, include_inherited_roles=include_inherited_roles, include_parents=include_parents, include_users=include_users) + +Group Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group import Group +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Group. + include_children = False # bool | (optional) (default to False) + include_inherited_roles = False # bool | (optional) (default to False) + include_parents = False # bool | (optional) (default to False) + include_users = True # bool | (optional) (default to True) + + try: + api_response = api_instance.core_groups_retrieve(group_uuid, include_children=include_children, include_inherited_roles=include_inherited_roles, include_parents=include_parents, include_users=include_users) + print("The response of CoreApi->core_groups_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_groups_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_uuid** | **UUID**| A UUID string identifying this Group. | + **include_children** | **bool**| | [optional] [default to False] + **include_inherited_roles** | **bool**| | [optional] [default to False] + **include_parents** | **bool**| | [optional] [default to False] + **include_users** | **bool**| | [optional] [default to True] + +### Return type + +[**Group**](Group.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_groups_update** +> Group core_groups_update(group_uuid, group_request) + +Group Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group import Group +from authentik_client.models.group_request import GroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Group. + group_request = authentik_client.GroupRequest() # GroupRequest | + + try: + api_response = api_instance.core_groups_update(group_uuid, group_request) + print("The response of CoreApi->core_groups_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_groups_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_uuid** | **UUID**| A UUID string identifying this Group. | + **group_request** | [**GroupRequest**](GroupRequest.md)| | + +### Return type + +[**Group**](Group.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_groups_used_by_list** +> List[UsedBy] core_groups_used_by_list(group_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Group. + + try: + api_response = api_instance.core_groups_used_by_list(group_uuid) + print("The response of CoreApi->core_groups_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_groups_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_uuid** | **UUID**| A UUID string identifying this Group. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_tokens_create** +> Token core_tokens_create(token_request) + +Token Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.token import Token +from authentik_client.models.token_request import TokenRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + token_request = authentik_client.TokenRequest() # TokenRequest | + + try: + api_response = api_instance.core_tokens_create(token_request) + print("The response of CoreApi->core_tokens_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_tokens_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **token_request** | [**TokenRequest**](TokenRequest.md)| | + +### Return type + +[**Token**](Token.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_tokens_destroy** +> core_tokens_destroy(identifier) + +Token Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + identifier = 'identifier_example' # str | + + try: + api_instance.core_tokens_destroy(identifier) + except Exception as e: + print("Exception when calling CoreApi->core_tokens_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identifier** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_tokens_list** +> PaginatedTokenList core_tokens_list(description=description, expires=expires, expiring=expiring, identifier=identifier, intent=intent, managed=managed, ordering=ordering, page=page, page_size=page_size, search=search, user__username=user__username) + +Token Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.intent_enum import IntentEnum +from authentik_client.models.paginated_token_list import PaginatedTokenList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + description = 'description_example' # str | (optional) + expires = '2013-10-20T19:20:30+01:00' # datetime | (optional) + expiring = True # bool | (optional) + identifier = 'identifier_example' # str | (optional) + intent = authentik_client.IntentEnum() # IntentEnum | (optional) + managed = 'managed_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + user__username = 'user__username_example' # str | (optional) + + try: + api_response = api_instance.core_tokens_list(description=description, expires=expires, expiring=expiring, identifier=identifier, intent=intent, managed=managed, ordering=ordering, page=page, page_size=page_size, search=search, user__username=user__username) + print("The response of CoreApi->core_tokens_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_tokens_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **description** | **str**| | [optional] + **expires** | **datetime**| | [optional] + **expiring** | **bool**| | [optional] + **identifier** | **str**| | [optional] + **intent** | [**IntentEnum**](.md)| | [optional] + **managed** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **user__username** | **str**| | [optional] + +### Return type + +[**PaginatedTokenList**](PaginatedTokenList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_tokens_partial_update** +> Token core_tokens_partial_update(identifier, patched_token_request=patched_token_request) + +Token Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_token_request import PatchedTokenRequest +from authentik_client.models.token import Token +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + identifier = 'identifier_example' # str | + patched_token_request = authentik_client.PatchedTokenRequest() # PatchedTokenRequest | (optional) + + try: + api_response = api_instance.core_tokens_partial_update(identifier, patched_token_request=patched_token_request) + print("The response of CoreApi->core_tokens_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_tokens_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identifier** | **str**| | + **patched_token_request** | [**PatchedTokenRequest**](PatchedTokenRequest.md)| | [optional] + +### Return type + +[**Token**](Token.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_tokens_retrieve** +> Token core_tokens_retrieve(identifier) + +Token Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.token import Token +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + identifier = 'identifier_example' # str | + + try: + api_response = api_instance.core_tokens_retrieve(identifier) + print("The response of CoreApi->core_tokens_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_tokens_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identifier** | **str**| | + +### Return type + +[**Token**](Token.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_tokens_set_key_create** +> core_tokens_set_key_create(identifier, token_set_key_request) + +Set token key. Action is logged as event. `authentik_core.set_token_key` permission +is required. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.token_set_key_request import TokenSetKeyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + identifier = 'identifier_example' # str | + token_set_key_request = authentik_client.TokenSetKeyRequest() # TokenSetKeyRequest | + + try: + api_instance.core_tokens_set_key_create(identifier, token_set_key_request) + except Exception as e: + print("Exception when calling CoreApi->core_tokens_set_key_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identifier** | **str**| | + **token_set_key_request** | [**TokenSetKeyRequest**](TokenSetKeyRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully changed key | - | +**400** | Missing key | - | +**404** | Token not found or expired | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_tokens_update** +> Token core_tokens_update(identifier, token_request) + +Token Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.token import Token +from authentik_client.models.token_request import TokenRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + identifier = 'identifier_example' # str | + token_request = authentik_client.TokenRequest() # TokenRequest | + + try: + api_response = api_instance.core_tokens_update(identifier, token_request) + print("The response of CoreApi->core_tokens_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_tokens_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identifier** | **str**| | + **token_request** | [**TokenRequest**](TokenRequest.md)| | + +### Return type + +[**Token**](Token.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_tokens_used_by_list** +> List[UsedBy] core_tokens_used_by_list(identifier) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + identifier = 'identifier_example' # str | + + try: + api_response = api_instance.core_tokens_used_by_list(identifier) + print("The response of CoreApi->core_tokens_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_tokens_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identifier** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_tokens_view_key_retrieve** +> TokenView core_tokens_view_key_retrieve(identifier) + +Return token key and log access + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.token_view import TokenView +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + identifier = 'identifier_example' # str | + + try: + api_response = api_instance.core_tokens_view_key_retrieve(identifier) + print("The response of CoreApi->core_tokens_view_key_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_tokens_view_key_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identifier** | **str**| | + +### Return type + +[**TokenView**](TokenView.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**404** | Token not found or expired | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_transactional_applications_update** +> TransactionApplicationResponse core_transactional_applications_update(transaction_application_request) + +Convert data into a blueprint, validate it and apply it + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.transaction_application_request import TransactionApplicationRequest +from authentik_client.models.transaction_application_response import TransactionApplicationResponse +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + transaction_application_request = authentik_client.TransactionApplicationRequest() # TransactionApplicationRequest | + + try: + api_response = api_instance.core_transactional_applications_update(transaction_application_request) + print("The response of CoreApi->core_transactional_applications_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_transactional_applications_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **transaction_application_request** | [**TransactionApplicationRequest**](TransactionApplicationRequest.md)| | + +### Return type + +[**TransactionApplicationResponse**](TransactionApplicationResponse.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_user_consent_destroy** +> core_user_consent_destroy(id) + +UserConsent Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User Consent. + + try: + api_instance.core_user_consent_destroy(id) + except Exception as e: + print("Exception when calling CoreApi->core_user_consent_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Consent. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_user_consent_list** +> PaginatedUserConsentList core_user_consent_list(application=application, ordering=ordering, page=page, page_size=page_size, search=search, user=user) + +UserConsent Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_consent_list import PaginatedUserConsentList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + application = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.core_user_consent_list(application=application, ordering=ordering, page=page, page_size=page_size, search=search, user=user) + print("The response of CoreApi->core_user_consent_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_user_consent_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **application** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedUserConsentList**](PaginatedUserConsentList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_user_consent_retrieve** +> UserConsent core_user_consent_retrieve(id) + +UserConsent Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_consent import UserConsent +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User Consent. + + try: + api_response = api_instance.core_user_consent_retrieve(id) + print("The response of CoreApi->core_user_consent_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_user_consent_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Consent. | + +### Return type + +[**UserConsent**](UserConsent.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_user_consent_used_by_list** +> List[UsedBy] core_user_consent_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User Consent. + + try: + api_response = api_instance.core_user_consent_used_by_list(id) + print("The response of CoreApi->core_user_consent_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_user_consent_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Consent. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_account_lockdown_create** +> Link core_users_account_lockdown_create(user_account_lockdown_request=user_account_lockdown_request) + +Choose the target account, then return a flow link. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.link import Link +from authentik_client.models.user_account_lockdown_request import UserAccountLockdownRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + user_account_lockdown_request = authentik_client.UserAccountLockdownRequest() # UserAccountLockdownRequest | (optional) + + try: + api_response = api_instance.core_users_account_lockdown_create(user_account_lockdown_request=user_account_lockdown_request) + print("The response of CoreApi->core_users_account_lockdown_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_account_lockdown_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_account_lockdown_request** | [**UserAccountLockdownRequest**](UserAccountLockdownRequest.md)| | [optional] + +### Return type + +[**Link**](Link.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | No lockdown flow configured or the flow is not applicable | - | +**403** | Permission denied (when targeting another user) | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_create** +> User core_users_create(user_request) + +User Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user import User +from authentik_client.models.user_request import UserRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + user_request = authentik_client.UserRequest() # UserRequest | + + try: + api_response = api_instance.core_users_create(user_request) + print("The response of CoreApi->core_users_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_request** | [**UserRequest**](UserRequest.md)| | + +### Return type + +[**User**](User.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_destroy** +> core_users_destroy(id) + +User Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + + try: + api_instance.core_users_destroy(id) + except Exception as e: + print("Exception when calling CoreApi->core_users_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_export_create** +> DataExport core_users_export_create(attributes=attributes, date_joined=date_joined, date_joined__gt=date_joined__gt, date_joined__lt=date_joined__lt, email=email, groups_by_name=groups_by_name, groups_by_pk=groups_by_pk, is_active=is_active, is_superuser=is_superuser, last_login=last_login, last_login__gt=last_login__gt, last_login__isnull=last_login__isnull, last_login__lt=last_login__lt, last_updated=last_updated, last_updated__gt=last_updated__gt, last_updated__lt=last_updated__lt, name=name, ordering=ordering, path=path, path_startswith=path_startswith, roles_by_name=roles_by_name, roles_by_pk=roles_by_pk, search=search, type=type, username=username, uuid=uuid) + +Create a data export for this data type. Note that the export is generated asynchronously: +this method returns a `DataExport` object that will initially have `completed=false` as well +as the permanent URL to that object in the `Location` header. +You can poll that URL until `completed=true`, at which point the `file_url` property will +contain a URL to download + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.data_export import DataExport +from authentik_client.models.user_type_enum import UserTypeEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + attributes = 'attributes_example' # str | Attributes (optional) + date_joined = '2013-10-20T19:20:30+01:00' # datetime | (optional) + date_joined__gt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + date_joined__lt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + email = 'email_example' # str | (optional) + groups_by_name = ['groups_by_name_example'] # List[str] | (optional) + groups_by_pk = None # List[UUID] | (optional) + is_active = True # bool | (optional) + is_superuser = True # bool | (optional) + last_login = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_login__gt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_login__isnull = True # bool | (optional) + last_login__lt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_updated = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_updated__gt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_updated__lt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + path = 'path_example' # str | (optional) + path_startswith = 'path_startswith_example' # str | (optional) + roles_by_name = ['roles_by_name_example'] # List[str] | (optional) + roles_by_pk = None # List[UUID] | (optional) + search = 'search_example' # str | A search term. (optional) + type = [authentik_client.UserTypeEnum()] # List[UserTypeEnum] | (optional) + username = 'username_example' # str | (optional) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.core_users_export_create(attributes=attributes, date_joined=date_joined, date_joined__gt=date_joined__gt, date_joined__lt=date_joined__lt, email=email, groups_by_name=groups_by_name, groups_by_pk=groups_by_pk, is_active=is_active, is_superuser=is_superuser, last_login=last_login, last_login__gt=last_login__gt, last_login__isnull=last_login__isnull, last_login__lt=last_login__lt, last_updated=last_updated, last_updated__gt=last_updated__gt, last_updated__lt=last_updated__lt, name=name, ordering=ordering, path=path, path_startswith=path_startswith, roles_by_name=roles_by_name, roles_by_pk=roles_by_pk, search=search, type=type, username=username, uuid=uuid) + print("The response of CoreApi->core_users_export_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_export_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **attributes** | **str**| Attributes | [optional] + **date_joined** | **datetime**| | [optional] + **date_joined__gt** | **datetime**| | [optional] + **date_joined__lt** | **datetime**| | [optional] + **email** | **str**| | [optional] + **groups_by_name** | [**List[str]**](str.md)| | [optional] + **groups_by_pk** | [**List[UUID]**](UUID.md)| | [optional] + **is_active** | **bool**| | [optional] + **is_superuser** | **bool**| | [optional] + **last_login** | **datetime**| | [optional] + **last_login__gt** | **datetime**| | [optional] + **last_login__isnull** | **bool**| | [optional] + **last_login__lt** | **datetime**| | [optional] + **last_updated** | **datetime**| | [optional] + **last_updated__gt** | **datetime**| | [optional] + **last_updated__lt** | **datetime**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **path** | **str**| | [optional] + **path_startswith** | **str**| | [optional] + **roles_by_name** | [**List[str]**](str.md)| | [optional] + **roles_by_pk** | [**List[UUID]**](UUID.md)| | [optional] + **search** | **str**| A search term. | [optional] + **type** | [**List[UserTypeEnum]**](UserTypeEnum.md)| | [optional] + **username** | **str**| | [optional] + **uuid** | **UUID**| | [optional] + +### Return type + +[**DataExport**](DataExport.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_impersonate_create** +> core_users_impersonate_create(id, impersonation_request) + +Impersonate a user + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.impersonation_request import ImpersonationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + impersonation_request = authentik_client.ImpersonationRequest() # ImpersonationRequest | + + try: + api_instance.core_users_impersonate_create(id, impersonation_request) + except Exception as e: + print("Exception when calling CoreApi->core_users_impersonate_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + **impersonation_request** | [**ImpersonationRequest**](ImpersonationRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully started impersonation | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_impersonate_end_retrieve** +> core_users_impersonate_end_retrieve() + +End Impersonation a user + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + + try: + api_instance.core_users_impersonate_end_retrieve() + except Exception as e: + print("Exception when calling CoreApi->core_users_impersonate_end_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully ended impersonation | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_list** +> PaginatedUserList core_users_list(attributes=attributes, date_joined=date_joined, date_joined__gt=date_joined__gt, date_joined__lt=date_joined__lt, email=email, groups_by_name=groups_by_name, groups_by_pk=groups_by_pk, include_groups=include_groups, include_roles=include_roles, is_active=is_active, is_superuser=is_superuser, last_login=last_login, last_login__gt=last_login__gt, last_login__isnull=last_login__isnull, last_login__lt=last_login__lt, last_updated=last_updated, last_updated__gt=last_updated__gt, last_updated__lt=last_updated__lt, name=name, ordering=ordering, page=page, page_size=page_size, path=path, path_startswith=path_startswith, roles_by_name=roles_by_name, roles_by_pk=roles_by_pk, search=search, type=type, username=username, uuid=uuid) + +User Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_list import PaginatedUserList +from authentik_client.models.user_type_enum import UserTypeEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + attributes = 'attributes_example' # str | Attributes (optional) + date_joined = '2013-10-20T19:20:30+01:00' # datetime | (optional) + date_joined__gt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + date_joined__lt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + email = 'email_example' # str | (optional) + groups_by_name = ['groups_by_name_example'] # List[str] | (optional) + groups_by_pk = None # List[UUID] | (optional) + include_groups = True # bool | (optional) (default to True) + include_roles = True # bool | (optional) (default to True) + is_active = True # bool | (optional) + is_superuser = True # bool | (optional) + last_login = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_login__gt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_login__isnull = True # bool | (optional) + last_login__lt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_updated = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_updated__gt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + last_updated__lt = '2013-10-20T19:20:30+01:00' # datetime | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + path = 'path_example' # str | (optional) + path_startswith = 'path_startswith_example' # str | (optional) + roles_by_name = ['roles_by_name_example'] # List[str] | (optional) + roles_by_pk = None # List[UUID] | (optional) + search = 'search_example' # str | A search term. (optional) + type = [authentik_client.UserTypeEnum()] # List[UserTypeEnum] | (optional) + username = 'username_example' # str | (optional) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.core_users_list(attributes=attributes, date_joined=date_joined, date_joined__gt=date_joined__gt, date_joined__lt=date_joined__lt, email=email, groups_by_name=groups_by_name, groups_by_pk=groups_by_pk, include_groups=include_groups, include_roles=include_roles, is_active=is_active, is_superuser=is_superuser, last_login=last_login, last_login__gt=last_login__gt, last_login__isnull=last_login__isnull, last_login__lt=last_login__lt, last_updated=last_updated, last_updated__gt=last_updated__gt, last_updated__lt=last_updated__lt, name=name, ordering=ordering, page=page, page_size=page_size, path=path, path_startswith=path_startswith, roles_by_name=roles_by_name, roles_by_pk=roles_by_pk, search=search, type=type, username=username, uuid=uuid) + print("The response of CoreApi->core_users_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **attributes** | **str**| Attributes | [optional] + **date_joined** | **datetime**| | [optional] + **date_joined__gt** | **datetime**| | [optional] + **date_joined__lt** | **datetime**| | [optional] + **email** | **str**| | [optional] + **groups_by_name** | [**List[str]**](str.md)| | [optional] + **groups_by_pk** | [**List[UUID]**](UUID.md)| | [optional] + **include_groups** | **bool**| | [optional] [default to True] + **include_roles** | **bool**| | [optional] [default to True] + **is_active** | **bool**| | [optional] + **is_superuser** | **bool**| | [optional] + **last_login** | **datetime**| | [optional] + **last_login__gt** | **datetime**| | [optional] + **last_login__isnull** | **bool**| | [optional] + **last_login__lt** | **datetime**| | [optional] + **last_updated** | **datetime**| | [optional] + **last_updated__gt** | **datetime**| | [optional] + **last_updated__lt** | **datetime**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **path** | **str**| | [optional] + **path_startswith** | **str**| | [optional] + **roles_by_name** | [**List[str]**](str.md)| | [optional] + **roles_by_pk** | [**List[UUID]**](UUID.md)| | [optional] + **search** | **str**| A search term. | [optional] + **type** | [**List[UserTypeEnum]**](UserTypeEnum.md)| | [optional] + **username** | **str**| | [optional] + **uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedUserList**](PaginatedUserList.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_me_retrieve** +> SessionUser core_users_me_retrieve() + +Get information about current user + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.session_user import SessionUser +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + + try: + api_response = api_instance.core_users_me_retrieve() + print("The response of CoreApi->core_users_me_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_me_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**SessionUser**](SessionUser.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_partial_update** +> User core_users_partial_update(id, patched_user_request=patched_user_request) + +User Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_request import PatchedUserRequest +from authentik_client.models.user import User +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + patched_user_request = authentik_client.PatchedUserRequest() # PatchedUserRequest | (optional) + + try: + api_response = api_instance.core_users_partial_update(id, patched_user_request=patched_user_request) + print("The response of CoreApi->core_users_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + **patched_user_request** | [**PatchedUserRequest**](PatchedUserRequest.md)| | [optional] + +### Return type + +[**User**](User.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_paths_retrieve** +> UserPath core_users_paths_retrieve(search=search) + +Get all user paths + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_path import UserPath +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.core_users_paths_retrieve(search=search) + print("The response of CoreApi->core_users_paths_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_paths_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **search** | **str**| A search term. | [optional] + +### Return type + +[**UserPath**](UserPath.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_recovery_create** +> Link core_users_recovery_create(id, user_recovery_link_request=user_recovery_link_request) + +Create a temporary link that a user can use to recover their account + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.link import Link +from authentik_client.models.user_recovery_link_request import UserRecoveryLinkRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + user_recovery_link_request = authentik_client.UserRecoveryLinkRequest() # UserRecoveryLinkRequest | (optional) + + try: + api_response = api_instance.core_users_recovery_create(id, user_recovery_link_request=user_recovery_link_request) + print("The response of CoreApi->core_users_recovery_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_recovery_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + **user_recovery_link_request** | [**UserRecoveryLinkRequest**](UserRecoveryLinkRequest.md)| | [optional] + +### Return type + +[**Link**](Link.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_recovery_email_create** +> core_users_recovery_email_create(id, user_recovery_email_request) + +Send an email with a temporary link that a user can use to recover their account + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_recovery_email_request import UserRecoveryEmailRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + user_recovery_email_request = authentik_client.UserRecoveryEmailRequest() # UserRecoveryEmailRequest | + + try: + api_instance.core_users_recovery_email_create(id, user_recovery_email_request) + except Exception as e: + print("Exception when calling CoreApi->core_users_recovery_email_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + **user_recovery_email_request** | [**UserRecoveryEmailRequest**](UserRecoveryEmailRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully sent recover email | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_retrieve** +> User core_users_retrieve(id) + +User Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user import User +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + + try: + api_response = api_instance.core_users_retrieve(id) + print("The response of CoreApi->core_users_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + +### Return type + +[**User**](User.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_service_account_create** +> UserServiceAccountResponse core_users_service_account_create(user_service_account_request) + +Create a new user account that is marked as a service account + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_service_account_request import UserServiceAccountRequest +from authentik_client.models.user_service_account_response import UserServiceAccountResponse +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + user_service_account_request = authentik_client.UserServiceAccountRequest() # UserServiceAccountRequest | + + try: + api_response = api_instance.core_users_service_account_create(user_service_account_request) + print("The response of CoreApi->core_users_service_account_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_service_account_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_service_account_request** | [**UserServiceAccountRequest**](UserServiceAccountRequest.md)| | + +### Return type + +[**UserServiceAccountResponse**](UserServiceAccountResponse.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_set_password_create** +> core_users_set_password_create(id, user_password_set_request) + +Set password for user + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_password_set_request import UserPasswordSetRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + user_password_set_request = authentik_client.UserPasswordSetRequest() # UserPasswordSetRequest | + + try: + api_instance.core_users_set_password_create(id, user_password_set_request) + except Exception as e: + print("Exception when calling CoreApi->core_users_set_password_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + **user_password_set_request** | [**UserPasswordSetRequest**](UserPasswordSetRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully changed password | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_set_password_hash_create** +> core_users_set_password_hash_create(id, user_password_hash_set_request) + +Set a user's password from a pre-hashed Django password value. + +Submit the Django password hash in the shared ``password`` request field. + +This updates authentik's local password verifier only. It does not attempt +to propagate the password change to LDAP or Kerberos because no raw password +is available from the request payload. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_password_hash_set_request import UserPasswordHashSetRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + user_password_hash_set_request = authentik_client.UserPasswordHashSetRequest() # UserPasswordHashSetRequest | + + try: + api_instance.core_users_set_password_hash_create(id, user_password_hash_set_request) + except Exception as e: + print("Exception when calling CoreApi->core_users_set_password_hash_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + **user_password_hash_set_request** | [**UserPasswordHashSetRequest**](UserPasswordHashSetRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully changed password | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_update** +> User core_users_update(id, user_request) + +User Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user import User +from authentik_client.models.user_request import UserRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + user_request = authentik_client.UserRequest() # UserRequest | + + try: + api_response = api_instance.core_users_update(id, user_request) + print("The response of CoreApi->core_users_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + **user_request** | [**UserRequest**](UserRequest.md)| | + +### Return type + +[**User**](User.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **core_users_used_by_list** +> List[UsedBy] core_users_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CoreApi(api_client) + id = 56 # int | A unique integer value identifying this User. + + try: + api_response = api_instance.core_users_used_by_list(id) + print("The response of CoreApi->core_users_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CoreApi->core_users_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik), [authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/CountryCodeEnum.md b/docs/CountryCodeEnum.md new file mode 100644 index 000000000..417cd19fe --- /dev/null +++ b/docs/CountryCodeEnum.md @@ -0,0 +1,506 @@ +# CountryCodeEnum + + +## Enum + +* `AF` (value: `'AF'`) + +* `AX` (value: `'AX'`) + +* `AL` (value: `'AL'`) + +* `DZ` (value: `'DZ'`) + +* `AS` (value: `'AS'`) + +* `AD` (value: `'AD'`) + +* `AO` (value: `'AO'`) + +* `AI` (value: `'AI'`) + +* `AQ` (value: `'AQ'`) + +* `AG` (value: `'AG'`) + +* `AR` (value: `'AR'`) + +* `AM` (value: `'AM'`) + +* `AW` (value: `'AW'`) + +* `AU` (value: `'AU'`) + +* `AT` (value: `'AT'`) + +* `AZ` (value: `'AZ'`) + +* `BS` (value: `'BS'`) + +* `BH` (value: `'BH'`) + +* `BD` (value: `'BD'`) + +* `BB` (value: `'BB'`) + +* `BY` (value: `'BY'`) + +* `BE` (value: `'BE'`) + +* `BZ` (value: `'BZ'`) + +* `BJ` (value: `'BJ'`) + +* `BM` (value: `'BM'`) + +* `BT` (value: `'BT'`) + +* `BO` (value: `'BO'`) + +* `BQ` (value: `'BQ'`) + +* `BA` (value: `'BA'`) + +* `BW` (value: `'BW'`) + +* `BV` (value: `'BV'`) + +* `BR` (value: `'BR'`) + +* `IO` (value: `'IO'`) + +* `BN` (value: `'BN'`) + +* `BG` (value: `'BG'`) + +* `BF` (value: `'BF'`) + +* `BI` (value: `'BI'`) + +* `CV` (value: `'CV'`) + +* `KH` (value: `'KH'`) + +* `CM` (value: `'CM'`) + +* `CA` (value: `'CA'`) + +* `KY` (value: `'KY'`) + +* `CF` (value: `'CF'`) + +* `TD` (value: `'TD'`) + +* `CL` (value: `'CL'`) + +* `CN` (value: `'CN'`) + +* `CX` (value: `'CX'`) + +* `CC` (value: `'CC'`) + +* `CO` (value: `'CO'`) + +* `KM` (value: `'KM'`) + +* `CG` (value: `'CG'`) + +* `CK` (value: `'CK'`) + +* `CR` (value: `'CR'`) + +* `CI` (value: `'CI'`) + +* `HR` (value: `'HR'`) + +* `CU` (value: `'CU'`) + +* `CW` (value: `'CW'`) + +* `CY` (value: `'CY'`) + +* `CZ` (value: `'CZ'`) + +* `CD` (value: `'CD'`) + +* `DK` (value: `'DK'`) + +* `DJ` (value: `'DJ'`) + +* `DM` (value: `'DM'`) + +* `DO` (value: `'DO'`) + +* `EC` (value: `'EC'`) + +* `EG` (value: `'EG'`) + +* `SV` (value: `'SV'`) + +* `GQ` (value: `'GQ'`) + +* `ER` (value: `'ER'`) + +* `EE` (value: `'EE'`) + +* `SZ` (value: `'SZ'`) + +* `ET` (value: `'ET'`) + +* `FK` (value: `'FK'`) + +* `FO` (value: `'FO'`) + +* `FJ` (value: `'FJ'`) + +* `FI` (value: `'FI'`) + +* `FR` (value: `'FR'`) + +* `GF` (value: `'GF'`) + +* `PF` (value: `'PF'`) + +* `TF` (value: `'TF'`) + +* `GA` (value: `'GA'`) + +* `GM` (value: `'GM'`) + +* `GE` (value: `'GE'`) + +* `DE` (value: `'DE'`) + +* `GH` (value: `'GH'`) + +* `GI` (value: `'GI'`) + +* `GR` (value: `'GR'`) + +* `GL` (value: `'GL'`) + +* `GD` (value: `'GD'`) + +* `GP` (value: `'GP'`) + +* `GU` (value: `'GU'`) + +* `GT` (value: `'GT'`) + +* `GG` (value: `'GG'`) + +* `GN` (value: `'GN'`) + +* `GW` (value: `'GW'`) + +* `GY` (value: `'GY'`) + +* `HT` (value: `'HT'`) + +* `HM` (value: `'HM'`) + +* `HN` (value: `'HN'`) + +* `HK` (value: `'HK'`) + +* `HU` (value: `'HU'`) + +* `IS` (value: `'IS'`) + +* `IN` (value: `'IN'`) + +* `ID` (value: `'ID'`) + +* `IR` (value: `'IR'`) + +* `IQ` (value: `'IQ'`) + +* `IE` (value: `'IE'`) + +* `IM` (value: `'IM'`) + +* `IL` (value: `'IL'`) + +* `IT` (value: `'IT'`) + +* `JM` (value: `'JM'`) + +* `JP` (value: `'JP'`) + +* `JE` (value: `'JE'`) + +* `JO` (value: `'JO'`) + +* `KZ` (value: `'KZ'`) + +* `KE` (value: `'KE'`) + +* `KI` (value: `'KI'`) + +* `KW` (value: `'KW'`) + +* `KG` (value: `'KG'`) + +* `LA` (value: `'LA'`) + +* `LV` (value: `'LV'`) + +* `LB` (value: `'LB'`) + +* `LS` (value: `'LS'`) + +* `LR` (value: `'LR'`) + +* `LY` (value: `'LY'`) + +* `LI` (value: `'LI'`) + +* `LT` (value: `'LT'`) + +* `LU` (value: `'LU'`) + +* `MO` (value: `'MO'`) + +* `MG` (value: `'MG'`) + +* `MW` (value: `'MW'`) + +* `MY` (value: `'MY'`) + +* `MV` (value: `'MV'`) + +* `ML` (value: `'ML'`) + +* `MT` (value: `'MT'`) + +* `MH` (value: `'MH'`) + +* `MQ` (value: `'MQ'`) + +* `MR` (value: `'MR'`) + +* `MU` (value: `'MU'`) + +* `YT` (value: `'YT'`) + +* `MX` (value: `'MX'`) + +* `FM` (value: `'FM'`) + +* `MD` (value: `'MD'`) + +* `MC` (value: `'MC'`) + +* `MN` (value: `'MN'`) + +* `ME` (value: `'ME'`) + +* `MS` (value: `'MS'`) + +* `MA` (value: `'MA'`) + +* `MZ` (value: `'MZ'`) + +* `MM` (value: `'MM'`) + +* `NA` (value: `'NA'`) + +* `NR` (value: `'NR'`) + +* `NP` (value: `'NP'`) + +* `NL` (value: `'NL'`) + +* `NC` (value: `'NC'`) + +* `NZ` (value: `'NZ'`) + +* `NI` (value: `'NI'`) + +* `NE` (value: `'NE'`) + +* `NG` (value: `'NG'`) + +* `NU` (value: `'NU'`) + +* `NF` (value: `'NF'`) + +* `KP` (value: `'KP'`) + +* `MK` (value: `'MK'`) + +* `MP` (value: `'MP'`) + +* `NO` (value: `'NO'`) + +* `OM` (value: `'OM'`) + +* `PK` (value: `'PK'`) + +* `PW` (value: `'PW'`) + +* `PS` (value: `'PS'`) + +* `PA` (value: `'PA'`) + +* `PG` (value: `'PG'`) + +* `PY` (value: `'PY'`) + +* `PE` (value: `'PE'`) + +* `PH` (value: `'PH'`) + +* `PN` (value: `'PN'`) + +* `PL` (value: `'PL'`) + +* `PT` (value: `'PT'`) + +* `PR` (value: `'PR'`) + +* `QA` (value: `'QA'`) + +* `RE` (value: `'RE'`) + +* `RO` (value: `'RO'`) + +* `RU` (value: `'RU'`) + +* `RW` (value: `'RW'`) + +* `BL` (value: `'BL'`) + +* `SH` (value: `'SH'`) + +* `KN` (value: `'KN'`) + +* `LC` (value: `'LC'`) + +* `MF` (value: `'MF'`) + +* `PM` (value: `'PM'`) + +* `VC` (value: `'VC'`) + +* `WS` (value: `'WS'`) + +* `SM` (value: `'SM'`) + +* `ST` (value: `'ST'`) + +* `SA` (value: `'SA'`) + +* `SN` (value: `'SN'`) + +* `RS` (value: `'RS'`) + +* `SC` (value: `'SC'`) + +* `SL` (value: `'SL'`) + +* `SG` (value: `'SG'`) + +* `SX` (value: `'SX'`) + +* `SK` (value: `'SK'`) + +* `SI` (value: `'SI'`) + +* `SB` (value: `'SB'`) + +* `SO` (value: `'SO'`) + +* `ZA` (value: `'ZA'`) + +* `GS` (value: `'GS'`) + +* `KR` (value: `'KR'`) + +* `SS` (value: `'SS'`) + +* `ES` (value: `'ES'`) + +* `LK` (value: `'LK'`) + +* `SD` (value: `'SD'`) + +* `SR` (value: `'SR'`) + +* `SJ` (value: `'SJ'`) + +* `SE` (value: `'SE'`) + +* `CH` (value: `'CH'`) + +* `SY` (value: `'SY'`) + +* `TW` (value: `'TW'`) + +* `TJ` (value: `'TJ'`) + +* `TZ` (value: `'TZ'`) + +* `TH` (value: `'TH'`) + +* `TL` (value: `'TL'`) + +* `TG` (value: `'TG'`) + +* `TK` (value: `'TK'`) + +* `TO` (value: `'TO'`) + +* `TT` (value: `'TT'`) + +* `TN` (value: `'TN'`) + +* `TR` (value: `'TR'`) + +* `TM` (value: `'TM'`) + +* `TC` (value: `'TC'`) + +* `TV` (value: `'TV'`) + +* `UG` (value: `'UG'`) + +* `UA` (value: `'UA'`) + +* `AE` (value: `'AE'`) + +* `GB` (value: `'GB'`) + +* `UM` (value: `'UM'`) + +* `US` (value: `'US'`) + +* `UY` (value: `'UY'`) + +* `UZ` (value: `'UZ'`) + +* `VU` (value: `'VU'`) + +* `VA` (value: `'VA'`) + +* `VE` (value: `'VE'`) + +* `VN` (value: `'VN'`) + +* `VG` (value: `'VG'`) + +* `VI` (value: `'VI'`) + +* `WF` (value: `'WF'`) + +* `EH` (value: `'EH'`) + +* `YE` (value: `'YE'`) + +* `ZM` (value: `'ZM'`) + +* `ZW` (value: `'ZW'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CryptoApi.md b/docs/CryptoApi.md new file mode 100644 index 000000000..d49bbee82 --- /dev/null +++ b/docs/CryptoApi.md @@ -0,0 +1,812 @@ +# authentik_client.CryptoApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**crypto_certificatekeypairs_create**](CryptoApi.md#crypto_certificatekeypairs_create) | **POST** /crypto/certificatekeypairs/ | +[**crypto_certificatekeypairs_destroy**](CryptoApi.md#crypto_certificatekeypairs_destroy) | **DELETE** /crypto/certificatekeypairs/{kp_uuid}/ | +[**crypto_certificatekeypairs_generate_create**](CryptoApi.md#crypto_certificatekeypairs_generate_create) | **POST** /crypto/certificatekeypairs/generate/ | +[**crypto_certificatekeypairs_list**](CryptoApi.md#crypto_certificatekeypairs_list) | **GET** /crypto/certificatekeypairs/ | +[**crypto_certificatekeypairs_partial_update**](CryptoApi.md#crypto_certificatekeypairs_partial_update) | **PATCH** /crypto/certificatekeypairs/{kp_uuid}/ | +[**crypto_certificatekeypairs_retrieve**](CryptoApi.md#crypto_certificatekeypairs_retrieve) | **GET** /crypto/certificatekeypairs/{kp_uuid}/ | +[**crypto_certificatekeypairs_update**](CryptoApi.md#crypto_certificatekeypairs_update) | **PUT** /crypto/certificatekeypairs/{kp_uuid}/ | +[**crypto_certificatekeypairs_used_by_list**](CryptoApi.md#crypto_certificatekeypairs_used_by_list) | **GET** /crypto/certificatekeypairs/{kp_uuid}/used_by/ | +[**crypto_certificatekeypairs_view_certificate_retrieve**](CryptoApi.md#crypto_certificatekeypairs_view_certificate_retrieve) | **GET** /crypto/certificatekeypairs/{kp_uuid}/view_certificate/ | +[**crypto_certificatekeypairs_view_private_key_retrieve**](CryptoApi.md#crypto_certificatekeypairs_view_private_key_retrieve) | **GET** /crypto/certificatekeypairs/{kp_uuid}/view_private_key/ | + + +# **crypto_certificatekeypairs_create** +> CertificateKeyPair crypto_certificatekeypairs_create(certificate_key_pair_request) + +CertificateKeyPair Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.certificate_key_pair import CertificateKeyPair +from authentik_client.models.certificate_key_pair_request import CertificateKeyPairRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + certificate_key_pair_request = authentik_client.CertificateKeyPairRequest() # CertificateKeyPairRequest | + + try: + api_response = api_instance.crypto_certificatekeypairs_create(certificate_key_pair_request) + print("The response of CryptoApi->crypto_certificatekeypairs_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **certificate_key_pair_request** | [**CertificateKeyPairRequest**](CertificateKeyPairRequest.md)| | + +### Return type + +[**CertificateKeyPair**](CertificateKeyPair.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **crypto_certificatekeypairs_destroy** +> crypto_certificatekeypairs_destroy(kp_uuid) + +CertificateKeyPair Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + kp_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Certificate-Key Pair. + + try: + api_instance.crypto_certificatekeypairs_destroy(kp_uuid) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kp_uuid** | **UUID**| A UUID string identifying this Certificate-Key Pair. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **crypto_certificatekeypairs_generate_create** +> CertificateKeyPair crypto_certificatekeypairs_generate_create(certificate_generation_request) + +Generate a new, self-signed certificate-key pair + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.certificate_generation_request import CertificateGenerationRequest +from authentik_client.models.certificate_key_pair import CertificateKeyPair +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + certificate_generation_request = authentik_client.CertificateGenerationRequest() # CertificateGenerationRequest | + + try: + api_response = api_instance.crypto_certificatekeypairs_generate_create(certificate_generation_request) + print("The response of CryptoApi->crypto_certificatekeypairs_generate_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_generate_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **certificate_generation_request** | [**CertificateGenerationRequest**](CertificateGenerationRequest.md)| | + +### Return type + +[**CertificateKeyPair**](CertificateKeyPair.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **crypto_certificatekeypairs_list** +> PaginatedCertificateKeyPairList crypto_certificatekeypairs_list(has_key=has_key, key_type=key_type, managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +CertificateKeyPair Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.key_type_enum import KeyTypeEnum +from authentik_client.models.paginated_certificate_key_pair_list import PaginatedCertificateKeyPairList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + has_key = True # bool | Only return certificate-key pairs with keys (optional) + key_type = [authentik_client.KeyTypeEnum()] # List[KeyTypeEnum] | (optional) + managed = 'managed_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.crypto_certificatekeypairs_list(has_key=has_key, key_type=key_type, managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of CryptoApi->crypto_certificatekeypairs_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **has_key** | **bool**| Only return certificate-key pairs with keys | [optional] + **key_type** | [**List[KeyTypeEnum]**](KeyTypeEnum.md)| | [optional] + **managed** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedCertificateKeyPairList**](PaginatedCertificateKeyPairList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **crypto_certificatekeypairs_partial_update** +> CertificateKeyPair crypto_certificatekeypairs_partial_update(kp_uuid, patched_certificate_key_pair_request=patched_certificate_key_pair_request) + +CertificateKeyPair Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.certificate_key_pair import CertificateKeyPair +from authentik_client.models.patched_certificate_key_pair_request import PatchedCertificateKeyPairRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + kp_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Certificate-Key Pair. + patched_certificate_key_pair_request = authentik_client.PatchedCertificateKeyPairRequest() # PatchedCertificateKeyPairRequest | (optional) + + try: + api_response = api_instance.crypto_certificatekeypairs_partial_update(kp_uuid, patched_certificate_key_pair_request=patched_certificate_key_pair_request) + print("The response of CryptoApi->crypto_certificatekeypairs_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kp_uuid** | **UUID**| A UUID string identifying this Certificate-Key Pair. | + **patched_certificate_key_pair_request** | [**PatchedCertificateKeyPairRequest**](PatchedCertificateKeyPairRequest.md)| | [optional] + +### Return type + +[**CertificateKeyPair**](CertificateKeyPair.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **crypto_certificatekeypairs_retrieve** +> CertificateKeyPair crypto_certificatekeypairs_retrieve(kp_uuid) + +CertificateKeyPair Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.certificate_key_pair import CertificateKeyPair +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + kp_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Certificate-Key Pair. + + try: + api_response = api_instance.crypto_certificatekeypairs_retrieve(kp_uuid) + print("The response of CryptoApi->crypto_certificatekeypairs_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kp_uuid** | **UUID**| A UUID string identifying this Certificate-Key Pair. | + +### Return type + +[**CertificateKeyPair**](CertificateKeyPair.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **crypto_certificatekeypairs_update** +> CertificateKeyPair crypto_certificatekeypairs_update(kp_uuid, certificate_key_pair_request) + +CertificateKeyPair Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.certificate_key_pair import CertificateKeyPair +from authentik_client.models.certificate_key_pair_request import CertificateKeyPairRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + kp_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Certificate-Key Pair. + certificate_key_pair_request = authentik_client.CertificateKeyPairRequest() # CertificateKeyPairRequest | + + try: + api_response = api_instance.crypto_certificatekeypairs_update(kp_uuid, certificate_key_pair_request) + print("The response of CryptoApi->crypto_certificatekeypairs_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kp_uuid** | **UUID**| A UUID string identifying this Certificate-Key Pair. | + **certificate_key_pair_request** | [**CertificateKeyPairRequest**](CertificateKeyPairRequest.md)| | + +### Return type + +[**CertificateKeyPair**](CertificateKeyPair.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **crypto_certificatekeypairs_used_by_list** +> List[UsedBy] crypto_certificatekeypairs_used_by_list(kp_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + kp_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Certificate-Key Pair. + + try: + api_response = api_instance.crypto_certificatekeypairs_used_by_list(kp_uuid) + print("The response of CryptoApi->crypto_certificatekeypairs_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kp_uuid** | **UUID**| A UUID string identifying this Certificate-Key Pair. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **crypto_certificatekeypairs_view_certificate_retrieve** +> CertificateData crypto_certificatekeypairs_view_certificate_retrieve(kp_uuid, download=download) + +Return certificate-key pairs certificate and log access + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.certificate_data import CertificateData +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + kp_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Certificate-Key Pair. + download = True # bool | (optional) + + try: + api_response = api_instance.crypto_certificatekeypairs_view_certificate_retrieve(kp_uuid, download=download) + print("The response of CryptoApi->crypto_certificatekeypairs_view_certificate_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_view_certificate_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kp_uuid** | **UUID**| A UUID string identifying this Certificate-Key Pair. | + **download** | **bool**| | [optional] + +### Return type + +[**CertificateData**](CertificateData.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **crypto_certificatekeypairs_view_private_key_retrieve** +> CertificateData crypto_certificatekeypairs_view_private_key_retrieve(kp_uuid, download=download) + +Return certificate-key pairs private key and log access + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.certificate_data import CertificateData +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.CryptoApi(api_client) + kp_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Certificate-Key Pair. + download = True # bool | (optional) + + try: + api_response = api_instance.crypto_certificatekeypairs_view_private_key_retrieve(kp_uuid, download=download) + print("The response of CryptoApi->crypto_certificatekeypairs_view_private_key_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling CryptoApi->crypto_certificatekeypairs_view_private_key_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kp_uuid** | **UUID**| A UUID string identifying this Certificate-Key Pair. | + **download** | **bool**| | [optional] + +### Return type + +[**CertificateData**](CertificateData.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/CurrentBrand.md b/docs/CurrentBrand.md new file mode 100644 index 000000000..c2fabfe2e --- /dev/null +++ b/docs/CurrentBrand.md @@ -0,0 +1,47 @@ +# CurrentBrand + +Partial brand information for styling + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**matched_domain** | **str** | | +**branding_title** | **str** | | +**branding_logo** | **str** | | +**branding_logo_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**branding_favicon** | **str** | | +**branding_favicon_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**branding_custom_css** | **str** | | +**ui_footer_links** | [**List[FooterLink]**](FooterLink.md) | | [readonly] +**ui_theme** | [**UiThemeEnum**](UiThemeEnum.md) | | [readonly] +**flow_authentication** | **str** | | [optional] +**flow_invalidation** | **str** | | [optional] +**flow_recovery** | **str** | | [optional] +**flow_unenrollment** | **str** | | [optional] +**flow_user_settings** | **str** | | [optional] +**flow_device_code** | **str** | | [optional] +**flow_lockdown** | **str** | | [optional] +**default_locale** | **str** | | [readonly] +**flags** | [**CurrentBrandFlags**](CurrentBrandFlags.md) | | + +## Example + +```python +from authentik_client.models.current_brand import CurrentBrand + +# TODO update the JSON string below +json = "{}" +# create an instance of CurrentBrand from a JSON string +current_brand_instance = CurrentBrand.from_json(json) +# print the JSON string representation of the object +print(CurrentBrand.to_json()) + +# convert the object into a dict +current_brand_dict = current_brand_instance.to_dict() +# create an instance of CurrentBrand from a dict +current_brand_from_dict = CurrentBrand.from_dict(current_brand_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/CurrentBrandFlags.md b/docs/CurrentBrandFlags.md new file mode 100644 index 000000000..dd8e6d931 --- /dev/null +++ b/docs/CurrentBrandFlags.md @@ -0,0 +1,30 @@ +# CurrentBrandFlags + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flows_continuous_login** | **bool** | Upon successful authentication, re-start authentication in other open tabs. | +**flows_refresh_others** | **bool** | Refresh other tabs after successful authentication. | + +## Example + +```python +from authentik_client.models.current_brand_flags import CurrentBrandFlags + +# TODO update the JSON string below +json = "{}" +# create an instance of CurrentBrandFlags from a JSON string +current_brand_flags_instance = CurrentBrandFlags.from_json(json) +# print the JSON string representation of the object +print(CurrentBrandFlags.to_json()) + +# convert the object into a dict +current_brand_flags_dict = current_brand_flags_instance.to_dict() +# create an instance of CurrentBrandFlags from a dict +current_brand_flags_from_dict = CurrentBrandFlags.from_dict(current_brand_flags_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DataExport.md b/docs/DataExport.md new file mode 100644 index 000000000..30c3adc6d --- /dev/null +++ b/docs/DataExport.md @@ -0,0 +1,36 @@ +# DataExport + +Mixin to validate that a valid enterprise license exists before allowing to save the object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**requested_by** | [**PartialUser**](PartialUser.md) | | [readonly] +**requested_on** | **datetime** | | [readonly] +**content_type** | [**ContentType**](ContentType.md) | | [readonly] +**var_query_params** | **Dict[str, object]** | | +**file_url** | **str** | | [readonly] +**completed** | **bool** | | [readonly] + +## Example + +```python +from authentik_client.models.data_export import DataExport + +# TODO update the JSON string below +json = "{}" +# create an instance of DataExport from a JSON string +data_export_instance = DataExport.from_json(json) +# print the JSON string representation of the object +print(DataExport.to_json()) + +# convert the object into a dict +data_export_dict = data_export_instance.to_dict() +# create an instance of DataExport from a dict +data_export_from_dict = DataExport.from_dict(data_export_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeliveryMethodEnum.md b/docs/DeliveryMethodEnum.md new file mode 100644 index 000000000..18cdfffd4 --- /dev/null +++ b/docs/DeliveryMethodEnum.md @@ -0,0 +1,16 @@ +# DeliveryMethodEnum + + +## Enum + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_RISC_SLASH_DELIVERY_MINUS_METHOD_SLASH_PUSH` (value: `'https://schemas.openid.net/secevent/risc/delivery-method/push'`) + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_RISC_SLASH_DELIVERY_MINUS_METHOD_SLASH_POLL` (value: `'https://schemas.openid.net/secevent/risc/delivery-method/poll'`) + +* `URN_COLON_IETF_COLON_RFC_COLON_8935` (value: `'urn:ietf:rfc:8935'`) + +* `URN_COLON_IETF_COLON_RFC_COLON_8936` (value: `'urn:ietf:rfc:8936'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeniedActionEnum.md b/docs/DeniedActionEnum.md new file mode 100644 index 000000000..79b1df9f4 --- /dev/null +++ b/docs/DeniedActionEnum.md @@ -0,0 +1,14 @@ +# DeniedActionEnum + + +## Enum + +* `MESSAGE_CONTINUE` (value: `'message_continue'`) + +* `MESSAGE` (value: `'message'`) + +* `CONTINUE` (value: `'continue'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DenyStage.md b/docs/DenyStage.md new file mode 100644 index 000000000..b89a38695 --- /dev/null +++ b/docs/DenyStage.md @@ -0,0 +1,37 @@ +# DenyStage + +DenyStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**deny_message** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.deny_stage import DenyStage + +# TODO update the JSON string below +json = "{}" +# create an instance of DenyStage from a JSON string +deny_stage_instance = DenyStage.from_json(json) +# print the JSON string representation of the object +print(DenyStage.to_json()) + +# convert the object into a dict +deny_stage_dict = deny_stage_instance.to_dict() +# create an instance of DenyStage from a dict +deny_stage_from_dict = DenyStage.from_dict(deny_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DenyStageRequest.md b/docs/DenyStageRequest.md new file mode 100644 index 000000000..5f50883c6 --- /dev/null +++ b/docs/DenyStageRequest.md @@ -0,0 +1,31 @@ +# DenyStageRequest + +DenyStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**deny_message** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.deny_stage_request import DenyStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DenyStageRequest from a JSON string +deny_stage_request_instance = DenyStageRequest.from_json(json) +# print the JSON string representation of the object +print(DenyStageRequest.to_json()) + +# convert the object into a dict +deny_stage_request_dict = deny_stage_request_instance.to_dict() +# create an instance of DenyStageRequest from a dict +deny_stage_request_from_dict = DenyStageRequest.from_dict(deny_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DetailedCountry.md b/docs/DetailedCountry.md new file mode 100644 index 000000000..ac7bdb745 --- /dev/null +++ b/docs/DetailedCountry.md @@ -0,0 +1,30 @@ +# DetailedCountry + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**code** | [**CountryCodeEnum**](CountryCodeEnum.md) | | +**name** | **str** | | + +## Example + +```python +from authentik_client.models.detailed_country import DetailedCountry + +# TODO update the JSON string below +json = "{}" +# create an instance of DetailedCountry from a JSON string +detailed_country_instance = DetailedCountry.from_json(json) +# print the JSON string representation of the object +print(DetailedCountry.to_json()) + +# convert the object into a dict +detailed_country_dict = detailed_country_instance.to_dict() +# create an instance of DetailedCountry from a dict +detailed_country_from_dict = DetailedCountry.from_dict(detailed_country_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Device.md b/docs/Device.md new file mode 100644 index 000000000..ef57ff046 --- /dev/null +++ b/docs/Device.md @@ -0,0 +1,41 @@ +# Device + +Serializer for authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**pk** | **str** | | +**name** | **str** | | +**type** | **str** | Get type of device | [readonly] +**confirmed** | **bool** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] +**last_used** | **datetime** | | [readonly] +**extra_description** | **str** | Get extra description | [readonly] +**external_id** | **str** | Get external Device ID | [readonly] + +## Example + +```python +from authentik_client.models.device import Device + +# TODO update the JSON string below +json = "{}" +# create an instance of Device from a JSON string +device_instance = Device.from_json(json) +# print the JSON string representation of the object +print(Device.to_json()) + +# convert the object into a dict +device_dict = device_instance.to_dict() +# create an instance of Device from a dict +device_from_dict = Device.from_dict(device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceAccessGroup.md b/docs/DeviceAccessGroup.md new file mode 100644 index 000000000..282406219 --- /dev/null +++ b/docs/DeviceAccessGroup.md @@ -0,0 +1,31 @@ +# DeviceAccessGroup + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pbm_uuid** | **UUID** | | [readonly] +**name** | **str** | | +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.device_access_group import DeviceAccessGroup + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceAccessGroup from a JSON string +device_access_group_instance = DeviceAccessGroup.from_json(json) +# print the JSON string representation of the object +print(DeviceAccessGroup.to_json()) + +# convert the object into a dict +device_access_group_dict = device_access_group_instance.to_dict() +# create an instance of DeviceAccessGroup from a dict +device_access_group_from_dict = DeviceAccessGroup.from_dict(device_access_group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceAccessGroupRequest.md b/docs/DeviceAccessGroupRequest.md new file mode 100644 index 000000000..cca274a1b --- /dev/null +++ b/docs/DeviceAccessGroupRequest.md @@ -0,0 +1,30 @@ +# DeviceAccessGroupRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.device_access_group_request import DeviceAccessGroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceAccessGroupRequest from a JSON string +device_access_group_request_instance = DeviceAccessGroupRequest.from_json(json) +# print the JSON string representation of the object +print(DeviceAccessGroupRequest.to_json()) + +# convert the object into a dict +device_access_group_request_dict = device_access_group_request_instance.to_dict() +# create an instance of DeviceAccessGroupRequest from a dict +device_access_group_request_from_dict = DeviceAccessGroupRequest.from_dict(device_access_group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceChallenge.md b/docs/DeviceChallenge.md new file mode 100644 index 000000000..db95e5c37 --- /dev/null +++ b/docs/DeviceChallenge.md @@ -0,0 +1,33 @@ +# DeviceChallenge + +Single device challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_class** | [**DeviceClassesEnum**](DeviceClassesEnum.md) | | +**device_uid** | **str** | | +**challenge** | **Dict[str, object]** | | +**last_used** | **datetime** | | + +## Example + +```python +from authentik_client.models.device_challenge import DeviceChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceChallenge from a JSON string +device_challenge_instance = DeviceChallenge.from_json(json) +# print the JSON string representation of the object +print(DeviceChallenge.to_json()) + +# convert the object into a dict +device_challenge_dict = device_challenge_instance.to_dict() +# create an instance of DeviceChallenge from a dict +device_challenge_from_dict = DeviceChallenge.from_dict(device_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceChallengeRequest.md b/docs/DeviceChallengeRequest.md new file mode 100644 index 000000000..5a99a05fa --- /dev/null +++ b/docs/DeviceChallengeRequest.md @@ -0,0 +1,33 @@ +# DeviceChallengeRequest + +Single device challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_class** | [**DeviceClassesEnum**](DeviceClassesEnum.md) | | +**device_uid** | **str** | | +**challenge** | **Dict[str, object]** | | +**last_used** | **datetime** | | + +## Example + +```python +from authentik_client.models.device_challenge_request import DeviceChallengeRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceChallengeRequest from a JSON string +device_challenge_request_instance = DeviceChallengeRequest.from_json(json) +# print the JSON string representation of the object +print(DeviceChallengeRequest.to_json()) + +# convert the object into a dict +device_challenge_request_dict = device_challenge_request_instance.to_dict() +# create an instance of DeviceChallengeRequest from a dict +device_challenge_request_from_dict = DeviceChallengeRequest.from_dict(device_challenge_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceClassesEnum.md b/docs/DeviceClassesEnum.md new file mode 100644 index 000000000..bc66e7c2f --- /dev/null +++ b/docs/DeviceClassesEnum.md @@ -0,0 +1,20 @@ +# DeviceClassesEnum + + +## Enum + +* `STATIC` (value: `'static'`) + +* `TOTP` (value: `'totp'`) + +* `WEBAUTHN` (value: `'webauthn'`) + +* `DUO` (value: `'duo'`) + +* `SMS` (value: `'sms'`) + +* `EMAIL` (value: `'email'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceConnection.md b/docs/DeviceConnection.md new file mode 100644 index 000000000..71a5e211f --- /dev/null +++ b/docs/DeviceConnection.md @@ -0,0 +1,32 @@ +# DeviceConnection + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device** | **UUID** | | +**connector** | **UUID** | | +**connector_obj** | [**Connector**](Connector.md) | | [readonly] +**latest_snapshot** | [**DeviceFactSnapshot**](DeviceFactSnapshot.md) | | [readonly] + +## Example + +```python +from authentik_client.models.device_connection import DeviceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceConnection from a JSON string +device_connection_instance = DeviceConnection.from_json(json) +# print the JSON string representation of the object +print(DeviceConnection.to_json()) + +# convert the object into a dict +device_connection_dict = device_connection_instance.to_dict() +# create an instance of DeviceConnection from a dict +device_connection_from_dict = DeviceConnection.from_dict(device_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceFactSnapshot.md b/docs/DeviceFactSnapshot.md new file mode 100644 index 000000000..e8d38faac --- /dev/null +++ b/docs/DeviceFactSnapshot.md @@ -0,0 +1,33 @@ +# DeviceFactSnapshot + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**DeviceFacts**](DeviceFacts.md) | | +**connection** | **UUID** | | +**created** | **datetime** | | [readonly] +**expires** | **datetime** | | [readonly] +**vendor** | [**VendorEnum**](VendorEnum.md) | | [readonly] + +## Example + +```python +from authentik_client.models.device_fact_snapshot import DeviceFactSnapshot + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceFactSnapshot from a JSON string +device_fact_snapshot_instance = DeviceFactSnapshot.from_json(json) +# print the JSON string representation of the object +print(DeviceFactSnapshot.to_json()) + +# convert the object into a dict +device_fact_snapshot_dict = device_fact_snapshot_instance.to_dict() +# create an instance of DeviceFactSnapshot from a dict +device_fact_snapshot_from_dict = DeviceFactSnapshot.from_dict(device_fact_snapshot_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceFacts.md b/docs/DeviceFacts.md new file mode 100644 index 000000000..f0c9163ae --- /dev/null +++ b/docs/DeviceFacts.md @@ -0,0 +1,37 @@ +# DeviceFacts + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**os** | [**OperatingSystem**](OperatingSystem.md) | | [optional] +**disks** | [**List[Disk]**](Disk.md) | | [optional] +**network** | [**Network**](Network.md) | | [optional] +**hardware** | [**Hardware**](Hardware.md) | | [optional] +**software** | [**List[Software]**](Software.md) | | [optional] +**processes** | [**List[Process]**](Process.md) | | [optional] +**users** | [**List[DeviceUser]**](DeviceUser.md) | | [optional] +**groups** | [**List[DeviceGroup]**](DeviceGroup.md) | | [optional] +**vendor** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.device_facts import DeviceFacts + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceFacts from a JSON string +device_facts_instance = DeviceFacts.from_json(json) +# print the JSON string representation of the object +print(DeviceFacts.to_json()) + +# convert the object into a dict +device_facts_dict = device_facts_instance.to_dict() +# create an instance of DeviceFacts from a dict +device_facts_from_dict = DeviceFacts.from_dict(device_facts_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceFactsOSFamily.md b/docs/DeviceFactsOSFamily.md new file mode 100644 index 000000000..fe452cb73 --- /dev/null +++ b/docs/DeviceFactsOSFamily.md @@ -0,0 +1,24 @@ +# DeviceFactsOSFamily + + +## Enum + +* `LINUX` (value: `'linux'`) + +* `UNIX` (value: `'unix'`) + +* `BSD` (value: `'bsd'`) + +* `WINDOWS` (value: `'windows'`) + +* `MAC_OS` (value: `'mac_os'`) + +* `ANDROID` (value: `'android'`) + +* `I_OS` (value: `'i_os'`) + +* `OTHER` (value: `'other'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceFactsRequest.md b/docs/DeviceFactsRequest.md new file mode 100644 index 000000000..c152869d3 --- /dev/null +++ b/docs/DeviceFactsRequest.md @@ -0,0 +1,37 @@ +# DeviceFactsRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**os** | [**OperatingSystemRequest**](OperatingSystemRequest.md) | | [optional] +**disks** | [**List[DiskRequest]**](DiskRequest.md) | | [optional] +**network** | [**NetworkRequest**](NetworkRequest.md) | | [optional] +**hardware** | [**HardwareRequest**](HardwareRequest.md) | | [optional] +**software** | [**List[SoftwareRequest]**](SoftwareRequest.md) | | [optional] +**processes** | [**List[ProcessRequest]**](ProcessRequest.md) | | [optional] +**users** | [**List[DeviceUserRequest]**](DeviceUserRequest.md) | | [optional] +**groups** | [**List[DeviceGroupRequest]**](DeviceGroupRequest.md) | | [optional] +**vendor** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.device_facts_request import DeviceFactsRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceFactsRequest from a JSON string +device_facts_request_instance = DeviceFactsRequest.from_json(json) +# print the JSON string representation of the object +print(DeviceFactsRequest.to_json()) + +# convert the object into a dict +device_facts_request_dict = device_facts_request_instance.to_dict() +# create an instance of DeviceFactsRequest from a dict +device_facts_request_from_dict = DeviceFactsRequest.from_dict(device_facts_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceGroup.md b/docs/DeviceGroup.md new file mode 100644 index 000000000..27f0200e2 --- /dev/null +++ b/docs/DeviceGroup.md @@ -0,0 +1,30 @@ +# DeviceGroup + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | +**name** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.device_group import DeviceGroup + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceGroup from a JSON string +device_group_instance = DeviceGroup.from_json(json) +# print the JSON string representation of the object +print(DeviceGroup.to_json()) + +# convert the object into a dict +device_group_dict = device_group_instance.to_dict() +# create an instance of DeviceGroup from a dict +device_group_from_dict = DeviceGroup.from_dict(device_group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceGroupRequest.md b/docs/DeviceGroupRequest.md new file mode 100644 index 000000000..add8e0592 --- /dev/null +++ b/docs/DeviceGroupRequest.md @@ -0,0 +1,30 @@ +# DeviceGroupRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | +**name** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.device_group_request import DeviceGroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceGroupRequest from a JSON string +device_group_request_instance = DeviceGroupRequest.from_json(json) +# print the JSON string representation of the object +print(DeviceGroupRequest.to_json()) + +# convert the object into a dict +device_group_request_dict = device_group_request_instance.to_dict() +# create an instance of DeviceGroupRequest from a dict +device_group_request_from_dict = DeviceGroupRequest.from_dict(device_group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceSummary.md b/docs/DeviceSummary.md new file mode 100644 index 000000000..c52193f40 --- /dev/null +++ b/docs/DeviceSummary.md @@ -0,0 +1,32 @@ +# DeviceSummary + +Summary of registered devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**total_count** | **int** | | +**unreachable_count** | **int** | | +**outdated_agent_count** | **int** | | + +## Example + +```python +from authentik_client.models.device_summary import DeviceSummary + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceSummary from a JSON string +device_summary_instance = DeviceSummary.from_json(json) +# print the JSON string representation of the object +print(DeviceSummary.to_json()) + +# convert the object into a dict +device_summary_dict = device_summary_instance.to_dict() +# create an instance of DeviceSummary from a dict +device_summary_from_dict = DeviceSummary.from_dict(device_summary_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceUser.md b/docs/DeviceUser.md new file mode 100644 index 000000000..857e01ef9 --- /dev/null +++ b/docs/DeviceUser.md @@ -0,0 +1,32 @@ +# DeviceUser + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | +**username** | **str** | | [optional] +**name** | **str** | | [optional] +**home** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.device_user import DeviceUser + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceUser from a JSON string +device_user_instance = DeviceUser.from_json(json) +# print the JSON string representation of the object +print(DeviceUser.to_json()) + +# convert the object into a dict +device_user_dict = device_user_instance.to_dict() +# create an instance of DeviceUser from a dict +device_user_from_dict = DeviceUser.from_dict(device_user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceUserBinding.md b/docs/DeviceUserBinding.md new file mode 100644 index 000000000..00d61aed5 --- /dev/null +++ b/docs/DeviceUserBinding.md @@ -0,0 +1,45 @@ +# DeviceUserBinding + +PolicyBinding Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**policy** | **UUID** | | [optional] +**group** | **UUID** | | [optional] +**user** | **int** | | [optional] +**policy_obj** | [**Policy**](Policy.md) | | [readonly] +**group_obj** | [**PartialGroup**](PartialGroup.md) | | [readonly] +**user_obj** | [**PartialUser**](PartialUser.md) | | [readonly] +**target** | **UUID** | | +**negate** | **bool** | Negates the outcome of the policy. Messages are unaffected. | [optional] +**enabled** | **bool** | | [optional] +**order** | **int** | | +**timeout** | **int** | Timeout after which Policy execution is terminated. | [optional] +**failure_result** | **bool** | Result if the Policy execution fails. | [optional] +**is_primary** | **bool** | | [optional] +**connector** | **UUID** | | [readonly] +**connector_obj** | [**Connector**](Connector.md) | | [readonly] + +## Example + +```python +from authentik_client.models.device_user_binding import DeviceUserBinding + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceUserBinding from a JSON string +device_user_binding_instance = DeviceUserBinding.from_json(json) +# print the JSON string representation of the object +print(DeviceUserBinding.to_json()) + +# convert the object into a dict +device_user_binding_dict = device_user_binding_instance.to_dict() +# create an instance of DeviceUserBinding from a dict +device_user_binding_from_dict = DeviceUserBinding.from_dict(device_user_binding_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceUserBindingRequest.md b/docs/DeviceUserBindingRequest.md new file mode 100644 index 000000000..c40596b29 --- /dev/null +++ b/docs/DeviceUserBindingRequest.md @@ -0,0 +1,39 @@ +# DeviceUserBindingRequest + +PolicyBinding Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**policy** | **UUID** | | [optional] +**group** | **UUID** | | [optional] +**user** | **int** | | [optional] +**target** | **UUID** | | +**negate** | **bool** | Negates the outcome of the policy. Messages are unaffected. | [optional] +**enabled** | **bool** | | [optional] +**order** | **int** | | +**timeout** | **int** | Timeout after which Policy execution is terminated. | [optional] +**failure_result** | **bool** | Result if the Policy execution fails. | [optional] +**is_primary** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.device_user_binding_request import DeviceUserBindingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceUserBindingRequest from a JSON string +device_user_binding_request_instance = DeviceUserBindingRequest.from_json(json) +# print the JSON string representation of the object +print(DeviceUserBindingRequest.to_json()) + +# convert the object into a dict +device_user_binding_request_dict = device_user_binding_request_instance.to_dict() +# create an instance of DeviceUserBindingRequest from a dict +device_user_binding_request_from_dict = DeviceUserBindingRequest.from_dict(device_user_binding_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeviceUserRequest.md b/docs/DeviceUserRequest.md new file mode 100644 index 000000000..ecd1c844d --- /dev/null +++ b/docs/DeviceUserRequest.md @@ -0,0 +1,32 @@ +# DeviceUserRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | +**username** | **str** | | [optional] +**name** | **str** | | [optional] +**home** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.device_user_request import DeviceUserRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DeviceUserRequest from a JSON string +device_user_request_instance = DeviceUserRequest.from_json(json) +# print the JSON string representation of the object +print(DeviceUserRequest.to_json()) + +# convert the object into a dict +device_user_request_dict = device_user_request_instance.to_dict() +# create an instance of DeviceUserRequest from a dict +device_user_request_from_dict = DeviceUserRequest.from_dict(device_user_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DigestAlgorithmEnum.md b/docs/DigestAlgorithmEnum.md new file mode 100644 index 000000000..adc9db7c7 --- /dev/null +++ b/docs/DigestAlgorithmEnum.md @@ -0,0 +1,16 @@ +# DigestAlgorithmEnum + + +## Enum + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2000_SLASH_09_SLASH_XMLDSIG_HASH_SHA1` (value: `'http://www.w3.org/2000/09/xmldsig#sha1'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLENC_HASH_SHA256` (value: `'http://www.w3.org/2001/04/xmlenc#sha256'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_SHA384` (value: `'http://www.w3.org/2001/04/xmldsig-more#sha384'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLENC_HASH_SHA512` (value: `'http://www.w3.org/2001/04/xmlenc#sha512'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DigitsEnum.md b/docs/DigitsEnum.md new file mode 100644 index 000000000..944299804 --- /dev/null +++ b/docs/DigitsEnum.md @@ -0,0 +1,12 @@ +# DigitsEnum + + +## Enum + +* `ENUM_6` (value: `'6'`) + +* `ENUM_8` (value: `'8'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Disk.md b/docs/Disk.md new file mode 100644 index 000000000..3972603f3 --- /dev/null +++ b/docs/Disk.md @@ -0,0 +1,34 @@ +# Disk + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**mountpoint** | **str** | | +**label** | **str** | | [optional] +**capacity_total_bytes** | **int** | | [optional] +**capacity_used_bytes** | **int** | | [optional] +**encryption_enabled** | **bool** | | [optional] [default to False] + +## Example + +```python +from authentik_client.models.disk import Disk + +# TODO update the JSON string below +json = "{}" +# create an instance of Disk from a JSON string +disk_instance = Disk.from_json(json) +# print the JSON string representation of the object +print(Disk.to_json()) + +# convert the object into a dict +disk_dict = disk_instance.to_dict() +# create an instance of Disk from a dict +disk_from_dict = Disk.from_dict(disk_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DiskRequest.md b/docs/DiskRequest.md new file mode 100644 index 000000000..40c46b20a --- /dev/null +++ b/docs/DiskRequest.md @@ -0,0 +1,34 @@ +# DiskRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**mountpoint** | **str** | | +**label** | **str** | | [optional] +**capacity_total_bytes** | **int** | | [optional] +**capacity_used_bytes** | **int** | | [optional] +**encryption_enabled** | **bool** | | [optional] [default to False] + +## Example + +```python +from authentik_client.models.disk_request import DiskRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DiskRequest from a JSON string +disk_request_instance = DiskRequest.from_json(json) +# print the JSON string representation of the object +print(DiskRequest.to_json()) + +# convert the object into a dict +disk_request_dict = disk_request_instance.to_dict() +# create an instance of DiskRequest from a dict +disk_request_from_dict = DiskRequest.from_dict(disk_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DockerServiceConnection.md b/docs/DockerServiceConnection.md new file mode 100644 index 000000000..d9404d4e8 --- /dev/null +++ b/docs/DockerServiceConnection.md @@ -0,0 +1,39 @@ +# DockerServiceConnection + +DockerServiceConnection Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**local** | **bool** | If enabled, use the local connection. Required Docker socket/Kubernetes Integration | [optional] +**component** | **str** | | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**url** | **str** | Can be in the format of 'unix://<path>' when connecting to a local docker daemon, or 'https://<hostname>:2376' when connecting to a remote system. | +**tls_verification** | **UUID** | CA which the endpoint's Certificate is verified against. Can be left empty for no validation. | [optional] +**tls_authentication** | **UUID** | Certificate/Key used for authentication. Can be left empty for no authentication. | [optional] + +## Example + +```python +from authentik_client.models.docker_service_connection import DockerServiceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of DockerServiceConnection from a JSON string +docker_service_connection_instance = DockerServiceConnection.from_json(json) +# print the JSON string representation of the object +print(DockerServiceConnection.to_json()) + +# convert the object into a dict +docker_service_connection_dict = docker_service_connection_instance.to_dict() +# create an instance of DockerServiceConnection from a dict +docker_service_connection_from_dict = DockerServiceConnection.from_dict(docker_service_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DockerServiceConnectionRequest.md b/docs/DockerServiceConnectionRequest.md new file mode 100644 index 000000000..b212d5e74 --- /dev/null +++ b/docs/DockerServiceConnectionRequest.md @@ -0,0 +1,34 @@ +# DockerServiceConnectionRequest + +DockerServiceConnection Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**local** | **bool** | If enabled, use the local connection. Required Docker socket/Kubernetes Integration | [optional] +**url** | **str** | Can be in the format of 'unix://<path>' when connecting to a local docker daemon, or 'https://<hostname>:2376' when connecting to a remote system. | +**tls_verification** | **UUID** | CA which the endpoint's Certificate is verified against. Can be left empty for no validation. | [optional] +**tls_authentication** | **UUID** | Certificate/Key used for authentication. Can be left empty for no authentication. | [optional] + +## Example + +```python +from authentik_client.models.docker_service_connection_request import DockerServiceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DockerServiceConnectionRequest from a JSON string +docker_service_connection_request_instance = DockerServiceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(DockerServiceConnectionRequest.to_json()) + +# convert the object into a dict +docker_service_connection_request_dict = docker_service_connection_request_instance.to_dict() +# create an instance of DockerServiceConnectionRequest from a dict +docker_service_connection_request_from_dict = DockerServiceConnectionRequest.from_dict(docker_service_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Domain.md b/docs/Domain.md new file mode 100644 index 000000000..d1c654f8c --- /dev/null +++ b/docs/Domain.md @@ -0,0 +1,33 @@ +# Domain + +Domain Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | [readonly] +**domain** | **str** | | +**is_primary** | **bool** | | [optional] +**tenant** | **UUID** | | + +## Example + +```python +from authentik_client.models.domain import Domain + +# TODO update the JSON string below +json = "{}" +# create an instance of Domain from a JSON string +domain_instance = Domain.from_json(json) +# print the JSON string representation of the object +print(Domain.to_json()) + +# convert the object into a dict +domain_dict = domain_instance.to_dict() +# create an instance of Domain from a dict +domain_from_dict = Domain.from_dict(domain_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DomainRequest.md b/docs/DomainRequest.md new file mode 100644 index 000000000..dbadfa41a --- /dev/null +++ b/docs/DomainRequest.md @@ -0,0 +1,32 @@ +# DomainRequest + +Domain Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**domain** | **str** | | +**is_primary** | **bool** | | [optional] +**tenant** | **UUID** | | + +## Example + +```python +from authentik_client.models.domain_request import DomainRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DomainRequest from a JSON string +domain_request_instance = DomainRequest.from_json(json) +# print the JSON string representation of the object +print(DomainRequest.to_json()) + +# convert the object into a dict +domain_request_dict = domain_request_instance.to_dict() +# create an instance of DomainRequest from a dict +domain_request_from_dict = DomainRequest.from_dict(domain_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DummyChallenge.md b/docs/DummyChallenge.md new file mode 100644 index 000000000..fad5b4ef6 --- /dev/null +++ b/docs/DummyChallenge.md @@ -0,0 +1,33 @@ +# DummyChallenge + +Dummy challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-dummy'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**name** | **str** | | + +## Example + +```python +from authentik_client.models.dummy_challenge import DummyChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of DummyChallenge from a JSON string +dummy_challenge_instance = DummyChallenge.from_json(json) +# print the JSON string representation of the object +print(DummyChallenge.to_json()) + +# convert the object into a dict +dummy_challenge_dict = dummy_challenge_instance.to_dict() +# create an instance of DummyChallenge from a dict +dummy_challenge_from_dict = DummyChallenge.from_dict(dummy_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DummyChallengeResponseRequest.md b/docs/DummyChallengeResponseRequest.md new file mode 100644 index 000000000..c19e56b2a --- /dev/null +++ b/docs/DummyChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# DummyChallengeResponseRequest + +Dummy challenge response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-dummy'] + +## Example + +```python +from authentik_client.models.dummy_challenge_response_request import DummyChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DummyChallengeResponseRequest from a JSON string +dummy_challenge_response_request_instance = DummyChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(DummyChallengeResponseRequest.to_json()) + +# convert the object into a dict +dummy_challenge_response_request_dict = dummy_challenge_response_request_instance.to_dict() +# create an instance of DummyChallengeResponseRequest from a dict +dummy_challenge_response_request_from_dict = DummyChallengeResponseRequest.from_dict(dummy_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DummyPolicy.md b/docs/DummyPolicy.md new file mode 100644 index 000000000..18e29726e --- /dev/null +++ b/docs/DummyPolicy.md @@ -0,0 +1,40 @@ +# DummyPolicy + +Dummy Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**bound_to** | **int** | Return objects policy is bound to | [readonly] +**result** | **bool** | | [optional] +**wait_min** | **int** | | [optional] +**wait_max** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.dummy_policy import DummyPolicy + +# TODO update the JSON string below +json = "{}" +# create an instance of DummyPolicy from a JSON string +dummy_policy_instance = DummyPolicy.from_json(json) +# print the JSON string representation of the object +print(DummyPolicy.to_json()) + +# convert the object into a dict +dummy_policy_dict = dummy_policy_instance.to_dict() +# create an instance of DummyPolicy from a dict +dummy_policy_from_dict = DummyPolicy.from_dict(dummy_policy_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DummyPolicyRequest.md b/docs/DummyPolicyRequest.md new file mode 100644 index 000000000..3267c5b43 --- /dev/null +++ b/docs/DummyPolicyRequest.md @@ -0,0 +1,34 @@ +# DummyPolicyRequest + +Dummy Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**result** | **bool** | | [optional] +**wait_min** | **int** | | [optional] +**wait_max** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.dummy_policy_request import DummyPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DummyPolicyRequest from a JSON string +dummy_policy_request_instance = DummyPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(DummyPolicyRequest.to_json()) + +# convert the object into a dict +dummy_policy_request_dict = dummy_policy_request_instance.to_dict() +# create an instance of DummyPolicyRequest from a dict +dummy_policy_request_from_dict = DummyPolicyRequest.from_dict(dummy_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DummyStage.md b/docs/DummyStage.md new file mode 100644 index 000000000..59b437839 --- /dev/null +++ b/docs/DummyStage.md @@ -0,0 +1,37 @@ +# DummyStage + +DummyStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**throw_error** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.dummy_stage import DummyStage + +# TODO update the JSON string below +json = "{}" +# create an instance of DummyStage from a JSON string +dummy_stage_instance = DummyStage.from_json(json) +# print the JSON string representation of the object +print(DummyStage.to_json()) + +# convert the object into a dict +dummy_stage_dict = dummy_stage_instance.to_dict() +# create an instance of DummyStage from a dict +dummy_stage_from_dict = DummyStage.from_dict(dummy_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DummyStageRequest.md b/docs/DummyStageRequest.md new file mode 100644 index 000000000..7396c4c6f --- /dev/null +++ b/docs/DummyStageRequest.md @@ -0,0 +1,31 @@ +# DummyStageRequest + +DummyStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**throw_error** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.dummy_stage_request import DummyStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DummyStageRequest from a JSON string +dummy_stage_request_instance = DummyStageRequest.from_json(json) +# print the JSON string representation of the object +print(DummyStageRequest.to_json()) + +# convert the object into a dict +dummy_stage_request_dict = dummy_stage_request_instance.to_dict() +# create an instance of DummyStageRequest from a dict +dummy_stage_request_from_dict = DummyStageRequest.from_dict(dummy_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DuoDevice.md b/docs/DuoDevice.md new file mode 100644 index 000000000..a10c17e85 --- /dev/null +++ b/docs/DuoDevice.md @@ -0,0 +1,32 @@ +# DuoDevice + +Serializer for Duo authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | The human-readable name of this device. | +**user** | [**PartialUser**](PartialUser.md) | | [readonly] + +## Example + +```python +from authentik_client.models.duo_device import DuoDevice + +# TODO update the JSON string below +json = "{}" +# create an instance of DuoDevice from a JSON string +duo_device_instance = DuoDevice.from_json(json) +# print the JSON string representation of the object +print(DuoDevice.to_json()) + +# convert the object into a dict +duo_device_dict = duo_device_instance.to_dict() +# create an instance of DuoDevice from a dict +duo_device_from_dict = DuoDevice.from_dict(duo_device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DuoDeviceEnrollmentStatus.md b/docs/DuoDeviceEnrollmentStatus.md new file mode 100644 index 000000000..38e22e45f --- /dev/null +++ b/docs/DuoDeviceEnrollmentStatus.md @@ -0,0 +1,29 @@ +# DuoDeviceEnrollmentStatus + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**duo_response** | [**DuoResponseEnum**](DuoResponseEnum.md) | | + +## Example + +```python +from authentik_client.models.duo_device_enrollment_status import DuoDeviceEnrollmentStatus + +# TODO update the JSON string below +json = "{}" +# create an instance of DuoDeviceEnrollmentStatus from a JSON string +duo_device_enrollment_status_instance = DuoDeviceEnrollmentStatus.from_json(json) +# print the JSON string representation of the object +print(DuoDeviceEnrollmentStatus.to_json()) + +# convert the object into a dict +duo_device_enrollment_status_dict = duo_device_enrollment_status_instance.to_dict() +# create an instance of DuoDeviceEnrollmentStatus from a dict +duo_device_enrollment_status_from_dict = DuoDeviceEnrollmentStatus.from_dict(duo_device_enrollment_status_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DuoDeviceRequest.md b/docs/DuoDeviceRequest.md new file mode 100644 index 000000000..50663bcf2 --- /dev/null +++ b/docs/DuoDeviceRequest.md @@ -0,0 +1,30 @@ +# DuoDeviceRequest + +Serializer for Duo authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | + +## Example + +```python +from authentik_client.models.duo_device_request import DuoDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DuoDeviceRequest from a JSON string +duo_device_request_instance = DuoDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(DuoDeviceRequest.to_json()) + +# convert the object into a dict +duo_device_request_dict = duo_device_request_instance.to_dict() +# create an instance of DuoDeviceRequest from a dict +duo_device_request_from_dict = DuoDeviceRequest.from_dict(duo_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DuoResponseEnum.md b/docs/DuoResponseEnum.md new file mode 100644 index 000000000..667b1cb5f --- /dev/null +++ b/docs/DuoResponseEnum.md @@ -0,0 +1,14 @@ +# DuoResponseEnum + + +## Enum + +* `SUCCESS` (value: `'success'`) + +* `WAITING` (value: `'waiting'`) + +* `INVALID` (value: `'invalid'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EmailChallenge.md b/docs/EmailChallenge.md new file mode 100644 index 000000000..9172ba601 --- /dev/null +++ b/docs/EmailChallenge.md @@ -0,0 +1,32 @@ +# EmailChallenge + +Email challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-email'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] + +## Example + +```python +from authentik_client.models.email_challenge import EmailChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of EmailChallenge from a JSON string +email_challenge_instance = EmailChallenge.from_json(json) +# print the JSON string representation of the object +print(EmailChallenge.to_json()) + +# convert the object into a dict +email_challenge_dict = email_challenge_instance.to_dict() +# create an instance of EmailChallenge from a dict +email_challenge_from_dict = EmailChallenge.from_dict(email_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EmailChallengeResponseRequest.md b/docs/EmailChallengeResponseRequest.md new file mode 100644 index 000000000..eac989d53 --- /dev/null +++ b/docs/EmailChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# EmailChallengeResponseRequest + +Email challenge resposen. No fields. This challenge is always declared invalid to give the user a chance to retry + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-email'] + +## Example + +```python +from authentik_client.models.email_challenge_response_request import EmailChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EmailChallengeResponseRequest from a JSON string +email_challenge_response_request_instance = EmailChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(EmailChallengeResponseRequest.to_json()) + +# convert the object into a dict +email_challenge_response_request_dict = email_challenge_response_request_instance.to_dict() +# create an instance of EmailChallengeResponseRequest from a dict +email_challenge_response_request_from_dict = EmailChallengeResponseRequest.from_dict(email_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EmailDevice.md b/docs/EmailDevice.md new file mode 100644 index 000000000..5dcf6368b --- /dev/null +++ b/docs/EmailDevice.md @@ -0,0 +1,33 @@ +# EmailDevice + +Serializer for email authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | +**pk** | **int** | | [readonly] +**email** | **str** | | [readonly] +**user** | [**PartialUser**](PartialUser.md) | | [readonly] + +## Example + +```python +from authentik_client.models.email_device import EmailDevice + +# TODO update the JSON string below +json = "{}" +# create an instance of EmailDevice from a JSON string +email_device_instance = EmailDevice.from_json(json) +# print the JSON string representation of the object +print(EmailDevice.to_json()) + +# convert the object into a dict +email_device_dict = email_device_instance.to_dict() +# create an instance of EmailDevice from a dict +email_device_from_dict = EmailDevice.from_dict(email_device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EmailDeviceRequest.md b/docs/EmailDeviceRequest.md new file mode 100644 index 000000000..7f624dacc --- /dev/null +++ b/docs/EmailDeviceRequest.md @@ -0,0 +1,30 @@ +# EmailDeviceRequest + +Serializer for email authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | + +## Example + +```python +from authentik_client.models.email_device_request import EmailDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EmailDeviceRequest from a JSON string +email_device_request_instance = EmailDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(EmailDeviceRequest.to_json()) + +# convert the object into a dict +email_device_request_dict = email_device_request_instance.to_dict() +# create an instance of EmailDeviceRequest from a dict +email_device_request_from_dict = EmailDeviceRequest.from_dict(email_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EmailStage.md b/docs/EmailStage.md new file mode 100644 index 000000000..6ecf18ff6 --- /dev/null +++ b/docs/EmailStage.md @@ -0,0 +1,50 @@ +# EmailStage + +EmailStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**use_global_settings** | **bool** | When enabled, global Email connection settings will be used and connection settings below will be ignored. | [optional] +**host** | **str** | | [optional] +**port** | **int** | | [optional] +**username** | **str** | | [optional] +**use_tls** | **bool** | | [optional] +**use_ssl** | **bool** | | [optional] +**timeout** | **int** | | [optional] +**from_address** | **str** | | [optional] +**token_expiry** | **str** | Time the token sent is valid (Format: hours=3,minutes=17,seconds=300). | [optional] +**subject** | **str** | | [optional] +**template** | **str** | | [optional] +**activate_user_on_success** | **bool** | Activate users upon completion of stage. | [optional] +**recovery_max_attempts** | **int** | | [optional] +**recovery_cache_timeout** | **str** | The time window used to count recent account recovery attempts. If the number of attempts exceed recovery_max_attempts within this period, further attempts will be rate-limited. (Format: hours=1;minutes=2;seconds=3). | [optional] + +## Example + +```python +from authentik_client.models.email_stage import EmailStage + +# TODO update the JSON string below +json = "{}" +# create an instance of EmailStage from a JSON string +email_stage_instance = EmailStage.from_json(json) +# print the JSON string representation of the object +print(EmailStage.to_json()) + +# convert the object into a dict +email_stage_dict = email_stage_instance.to_dict() +# create an instance of EmailStage from a dict +email_stage_from_dict = EmailStage.from_dict(email_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EmailStageRequest.md b/docs/EmailStageRequest.md new file mode 100644 index 000000000..6281614be --- /dev/null +++ b/docs/EmailStageRequest.md @@ -0,0 +1,45 @@ +# EmailStageRequest + +EmailStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**use_global_settings** | **bool** | When enabled, global Email connection settings will be used and connection settings below will be ignored. | [optional] +**host** | **str** | | [optional] +**port** | **int** | | [optional] +**username** | **str** | | [optional] +**password** | **str** | | [optional] +**use_tls** | **bool** | | [optional] +**use_ssl** | **bool** | | [optional] +**timeout** | **int** | | [optional] +**from_address** | **str** | | [optional] +**token_expiry** | **str** | Time the token sent is valid (Format: hours=3,minutes=17,seconds=300). | [optional] +**subject** | **str** | | [optional] +**template** | **str** | | [optional] +**activate_user_on_success** | **bool** | Activate users upon completion of stage. | [optional] +**recovery_max_attempts** | **int** | | [optional] +**recovery_cache_timeout** | **str** | The time window used to count recent account recovery attempts. If the number of attempts exceed recovery_max_attempts within this period, further attempts will be rate-limited. (Format: hours=1;minutes=2;seconds=3). | [optional] + +## Example + +```python +from authentik_client.models.email_stage_request import EmailStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EmailStageRequest from a JSON string +email_stage_request_instance = EmailStageRequest.from_json(json) +# print the JSON string representation of the object +print(EmailStageRequest.to_json()) + +# convert the object into a dict +email_stage_request_dict = email_stage_request_instance.to_dict() +# create an instance of EmailStageRequest from a dict +email_stage_request_from_dict = EmailStageRequest.from_dict(email_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Endpoint.md b/docs/Endpoint.md new file mode 100644 index 000000000..bdea89724 --- /dev/null +++ b/docs/Endpoint.md @@ -0,0 +1,40 @@ +# Endpoint + +Endpoint Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**provider** | **int** | | +**provider_obj** | [**RACProvider**](RACProvider.md) | | [readonly] +**protocol** | [**ProtocolEnum**](ProtocolEnum.md) | | +**host** | **str** | | +**settings** | **Dict[str, object]** | | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**auth_mode** | [**EndpointAuthModeEnum**](EndpointAuthModeEnum.md) | | +**launch_url** | **str** | Build actual launch URL (the provider itself does not have one, just individual endpoints) | [readonly] +**maximum_connections** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.endpoint import Endpoint + +# TODO update the JSON string below +json = "{}" +# create an instance of Endpoint from a JSON string +endpoint_instance = Endpoint.from_json(json) +# print the JSON string representation of the object +print(Endpoint.to_json()) + +# convert the object into a dict +endpoint_dict = endpoint_instance.to_dict() +# create an instance of Endpoint from a dict +endpoint_from_dict = Endpoint.from_dict(endpoint_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointAgentChallenge.md b/docs/EndpointAgentChallenge.md new file mode 100644 index 000000000..f29672d3c --- /dev/null +++ b/docs/EndpointAgentChallenge.md @@ -0,0 +1,34 @@ +# EndpointAgentChallenge + +Signed challenge for authentik agent to respond to + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-endpoint-agent'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**challenge** | **str** | | +**challenge_idle_timeout** | **int** | | + +## Example + +```python +from authentik_client.models.endpoint_agent_challenge import EndpointAgentChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of EndpointAgentChallenge from a JSON string +endpoint_agent_challenge_instance = EndpointAgentChallenge.from_json(json) +# print the JSON string representation of the object +print(EndpointAgentChallenge.to_json()) + +# convert the object into a dict +endpoint_agent_challenge_dict = endpoint_agent_challenge_instance.to_dict() +# create an instance of EndpointAgentChallenge from a dict +endpoint_agent_challenge_from_dict = EndpointAgentChallenge.from_dict(endpoint_agent_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointAgentChallengeResponseRequest.md b/docs/EndpointAgentChallengeResponseRequest.md new file mode 100644 index 000000000..49c95b345 --- /dev/null +++ b/docs/EndpointAgentChallengeResponseRequest.md @@ -0,0 +1,31 @@ +# EndpointAgentChallengeResponseRequest + +Response to signed challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-endpoint-agent'] +**response** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.endpoint_agent_challenge_response_request import EndpointAgentChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EndpointAgentChallengeResponseRequest from a JSON string +endpoint_agent_challenge_response_request_instance = EndpointAgentChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(EndpointAgentChallengeResponseRequest.to_json()) + +# convert the object into a dict +endpoint_agent_challenge_response_request_dict = endpoint_agent_challenge_response_request_instance.to_dict() +# create an instance of EndpointAgentChallengeResponseRequest from a dict +endpoint_agent_challenge_response_request_from_dict = EndpointAgentChallengeResponseRequest.from_dict(endpoint_agent_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointAuthModeEnum.md b/docs/EndpointAuthModeEnum.md new file mode 100644 index 000000000..10b3effbf --- /dev/null +++ b/docs/EndpointAuthModeEnum.md @@ -0,0 +1,12 @@ +# EndpointAuthModeEnum + + +## Enum + +* `STATIC` (value: `'static'`) + +* `PROMPT` (value: `'prompt'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointDevice.md b/docs/EndpointDevice.md new file mode 100644 index 000000000..345fae52d --- /dev/null +++ b/docs/EndpointDevice.md @@ -0,0 +1,37 @@ +# EndpointDevice + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_uuid** | **UUID** | | [optional] +**pbm_uuid** | **UUID** | | [readonly] +**name** | **str** | | +**access_group** | **UUID** | | [optional] +**access_group_obj** | [**DeviceAccessGroup**](DeviceAccessGroup.md) | | [optional] +**expiring** | **bool** | | [optional] +**expires** | **datetime** | | [optional] +**facts** | [**DeviceFactSnapshot**](DeviceFactSnapshot.md) | | [readonly] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.endpoint_device import EndpointDevice + +# TODO update the JSON string below +json = "{}" +# create an instance of EndpointDevice from a JSON string +endpoint_device_instance = EndpointDevice.from_json(json) +# print the JSON string representation of the object +print(EndpointDevice.to_json()) + +# convert the object into a dict +endpoint_device_dict = endpoint_device_instance.to_dict() +# create an instance of EndpointDevice from a dict +endpoint_device_from_dict = EndpointDevice.from_dict(endpoint_device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointDeviceDetails.md b/docs/EndpointDeviceDetails.md new file mode 100644 index 000000000..846de8448 --- /dev/null +++ b/docs/EndpointDeviceDetails.md @@ -0,0 +1,40 @@ +# EndpointDeviceDetails + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_uuid** | **UUID** | | [optional] +**pbm_uuid** | **UUID** | | [readonly] +**name** | **str** | | +**access_group** | **UUID** | | [optional] +**access_group_obj** | [**DeviceAccessGroup**](DeviceAccessGroup.md) | | [optional] +**expiring** | **bool** | | [optional] +**expires** | **datetime** | | [optional] +**facts** | [**DeviceFactSnapshot**](DeviceFactSnapshot.md) | | [readonly] +**attributes** | **Dict[str, object]** | | [optional] +**connections_obj** | [**List[DeviceConnection]**](DeviceConnection.md) | | +**policies** | **List[UUID]** | | [readonly] +**connections** | **List[UUID]** | | [readonly] + +## Example + +```python +from authentik_client.models.endpoint_device_details import EndpointDeviceDetails + +# TODO update the JSON string below +json = "{}" +# create an instance of EndpointDeviceDetails from a JSON string +endpoint_device_details_instance = EndpointDeviceDetails.from_json(json) +# print the JSON string representation of the object +print(EndpointDeviceDetails.to_json()) + +# convert the object into a dict +endpoint_device_details_dict = endpoint_device_details_instance.to_dict() +# create an instance of EndpointDeviceDetails from a dict +endpoint_device_details_from_dict = EndpointDeviceDetails.from_dict(endpoint_device_details_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointDeviceRequest.md b/docs/EndpointDeviceRequest.md new file mode 100644 index 000000000..9be9a2fc0 --- /dev/null +++ b/docs/EndpointDeviceRequest.md @@ -0,0 +1,35 @@ +# EndpointDeviceRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_uuid** | **UUID** | | [optional] +**name** | **str** | | +**access_group** | **UUID** | | [optional] +**access_group_obj** | [**DeviceAccessGroupRequest**](DeviceAccessGroupRequest.md) | | [optional] +**expiring** | **bool** | | [optional] +**expires** | **datetime** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.endpoint_device_request import EndpointDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EndpointDeviceRequest from a JSON string +endpoint_device_request_instance = EndpointDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(EndpointDeviceRequest.to_json()) + +# convert the object into a dict +endpoint_device_request_dict = endpoint_device_request_instance.to_dict() +# create an instance of EndpointDeviceRequest from a dict +endpoint_device_request_from_dict = EndpointDeviceRequest.from_dict(endpoint_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointRequest.md b/docs/EndpointRequest.md new file mode 100644 index 000000000..6f6d08bb9 --- /dev/null +++ b/docs/EndpointRequest.md @@ -0,0 +1,37 @@ +# EndpointRequest + +Endpoint Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**provider** | **int** | | +**protocol** | [**ProtocolEnum**](ProtocolEnum.md) | | +**host** | **str** | | +**settings** | **Dict[str, object]** | | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**auth_mode** | [**EndpointAuthModeEnum**](EndpointAuthModeEnum.md) | | +**maximum_connections** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.endpoint_request import EndpointRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EndpointRequest from a JSON string +endpoint_request_instance = EndpointRequest.from_json(json) +# print the JSON string representation of the object +print(EndpointRequest.to_json()) + +# convert the object into a dict +endpoint_request_dict = endpoint_request_instance.to_dict() +# create an instance of EndpointRequest from a dict +endpoint_request_from_dict = EndpointRequest.from_dict(endpoint_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointStage.md b/docs/EndpointStage.md new file mode 100644 index 000000000..7cbed8c8a --- /dev/null +++ b/docs/EndpointStage.md @@ -0,0 +1,39 @@ +# EndpointStage + +EndpointStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**connector** | **UUID** | | +**connector_obj** | [**Connector**](Connector.md) | | [readonly] +**mode** | [**StageModeEnum**](StageModeEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.endpoint_stage import EndpointStage + +# TODO update the JSON string below +json = "{}" +# create an instance of EndpointStage from a JSON string +endpoint_stage_instance = EndpointStage.from_json(json) +# print the JSON string representation of the object +print(EndpointStage.to_json()) + +# convert the object into a dict +endpoint_stage_dict = endpoint_stage_instance.to_dict() +# create an instance of EndpointStage from a dict +endpoint_stage_from_dict = EndpointStage.from_dict(endpoint_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointStageRequest.md b/docs/EndpointStageRequest.md new file mode 100644 index 000000000..60448c139 --- /dev/null +++ b/docs/EndpointStageRequest.md @@ -0,0 +1,32 @@ +# EndpointStageRequest + +EndpointStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**connector** | **UUID** | | +**mode** | [**StageModeEnum**](StageModeEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.endpoint_stage_request import EndpointStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EndpointStageRequest from a JSON string +endpoint_stage_request_instance = EndpointStageRequest.from_json(json) +# print the JSON string representation of the object +print(EndpointStageRequest.to_json()) + +# convert the object into a dict +endpoint_stage_request_dict = endpoint_stage_request_instance.to_dict() +# create an instance of EndpointStageRequest from a dict +endpoint_stage_request_from_dict = EndpointStageRequest.from_dict(endpoint_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EndpointsApi.md b/docs/EndpointsApi.md new file mode 100644 index 000000000..b98135fba --- /dev/null +++ b/docs/EndpointsApi.md @@ -0,0 +1,5544 @@ +# authentik_client.EndpointsApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**endpoints_agents_connectors_agent_config_retrieve**](EndpointsApi.md#endpoints_agents_connectors_agent_config_retrieve) | **GET** /endpoints/agents/connectors/agent_config/ | +[**endpoints_agents_connectors_auth_fed_create**](EndpointsApi.md#endpoints_agents_connectors_auth_fed_create) | **POST** /endpoints/agents/connectors/auth_fed/ | +[**endpoints_agents_connectors_auth_ia_create**](EndpointsApi.md#endpoints_agents_connectors_auth_ia_create) | **POST** /endpoints/agents/connectors/auth_ia/ | +[**endpoints_agents_connectors_check_in_create**](EndpointsApi.md#endpoints_agents_connectors_check_in_create) | **POST** /endpoints/agents/connectors/check_in/ | +[**endpoints_agents_connectors_create**](EndpointsApi.md#endpoints_agents_connectors_create) | **POST** /endpoints/agents/connectors/ | +[**endpoints_agents_connectors_destroy**](EndpointsApi.md#endpoints_agents_connectors_destroy) | **DELETE** /endpoints/agents/connectors/{connector_uuid}/ | +[**endpoints_agents_connectors_enroll_create**](EndpointsApi.md#endpoints_agents_connectors_enroll_create) | **POST** /endpoints/agents/connectors/enroll/ | +[**endpoints_agents_connectors_list**](EndpointsApi.md#endpoints_agents_connectors_list) | **GET** /endpoints/agents/connectors/ | +[**endpoints_agents_connectors_mdm_config_create**](EndpointsApi.md#endpoints_agents_connectors_mdm_config_create) | **POST** /endpoints/agents/connectors/{connector_uuid}/mdm_config/ | +[**endpoints_agents_connectors_partial_update**](EndpointsApi.md#endpoints_agents_connectors_partial_update) | **PATCH** /endpoints/agents/connectors/{connector_uuid}/ | +[**endpoints_agents_connectors_retrieve**](EndpointsApi.md#endpoints_agents_connectors_retrieve) | **GET** /endpoints/agents/connectors/{connector_uuid}/ | +[**endpoints_agents_connectors_update**](EndpointsApi.md#endpoints_agents_connectors_update) | **PUT** /endpoints/agents/connectors/{connector_uuid}/ | +[**endpoints_agents_connectors_used_by_list**](EndpointsApi.md#endpoints_agents_connectors_used_by_list) | **GET** /endpoints/agents/connectors/{connector_uuid}/used_by/ | +[**endpoints_agents_enrollment_tokens_create**](EndpointsApi.md#endpoints_agents_enrollment_tokens_create) | **POST** /endpoints/agents/enrollment_tokens/ | +[**endpoints_agents_enrollment_tokens_destroy**](EndpointsApi.md#endpoints_agents_enrollment_tokens_destroy) | **DELETE** /endpoints/agents/enrollment_tokens/{token_uuid}/ | +[**endpoints_agents_enrollment_tokens_list**](EndpointsApi.md#endpoints_agents_enrollment_tokens_list) | **GET** /endpoints/agents/enrollment_tokens/ | +[**endpoints_agents_enrollment_tokens_partial_update**](EndpointsApi.md#endpoints_agents_enrollment_tokens_partial_update) | **PATCH** /endpoints/agents/enrollment_tokens/{token_uuid}/ | +[**endpoints_agents_enrollment_tokens_retrieve**](EndpointsApi.md#endpoints_agents_enrollment_tokens_retrieve) | **GET** /endpoints/agents/enrollment_tokens/{token_uuid}/ | +[**endpoints_agents_enrollment_tokens_update**](EndpointsApi.md#endpoints_agents_enrollment_tokens_update) | **PUT** /endpoints/agents/enrollment_tokens/{token_uuid}/ | +[**endpoints_agents_enrollment_tokens_used_by_list**](EndpointsApi.md#endpoints_agents_enrollment_tokens_used_by_list) | **GET** /endpoints/agents/enrollment_tokens/{token_uuid}/used_by/ | +[**endpoints_agents_enrollment_tokens_view_key_retrieve**](EndpointsApi.md#endpoints_agents_enrollment_tokens_view_key_retrieve) | **GET** /endpoints/agents/enrollment_tokens/{token_uuid}/view_key/ | +[**endpoints_agents_psso_ise_create**](EndpointsApi.md#endpoints_agents_psso_ise_create) | **POST** /endpoints/agents/psso/ise/ | +[**endpoints_agents_psso_ise_destroy**](EndpointsApi.md#endpoints_agents_psso_ise_destroy) | **DELETE** /endpoints/agents/psso/ise/{uuid}/ | +[**endpoints_agents_psso_ise_list**](EndpointsApi.md#endpoints_agents_psso_ise_list) | **GET** /endpoints/agents/psso/ise/ | +[**endpoints_agents_psso_ise_partial_update**](EndpointsApi.md#endpoints_agents_psso_ise_partial_update) | **PATCH** /endpoints/agents/psso/ise/{uuid}/ | +[**endpoints_agents_psso_ise_retrieve**](EndpointsApi.md#endpoints_agents_psso_ise_retrieve) | **GET** /endpoints/agents/psso/ise/{uuid}/ | +[**endpoints_agents_psso_ise_update**](EndpointsApi.md#endpoints_agents_psso_ise_update) | **PUT** /endpoints/agents/psso/ise/{uuid}/ | +[**endpoints_agents_psso_ise_used_by_list**](EndpointsApi.md#endpoints_agents_psso_ise_used_by_list) | **GET** /endpoints/agents/psso/ise/{uuid}/used_by/ | +[**endpoints_agents_psso_register_device_create**](EndpointsApi.md#endpoints_agents_psso_register_device_create) | **POST** /endpoints/agents/psso/register/device/ | +[**endpoints_agents_psso_register_user_create**](EndpointsApi.md#endpoints_agents_psso_register_user_create) | **POST** /endpoints/agents/psso/register/user/ | +[**endpoints_connectors_destroy**](EndpointsApi.md#endpoints_connectors_destroy) | **DELETE** /endpoints/connectors/{connector_uuid}/ | +[**endpoints_connectors_list**](EndpointsApi.md#endpoints_connectors_list) | **GET** /endpoints/connectors/ | +[**endpoints_connectors_retrieve**](EndpointsApi.md#endpoints_connectors_retrieve) | **GET** /endpoints/connectors/{connector_uuid}/ | +[**endpoints_connectors_types_list**](EndpointsApi.md#endpoints_connectors_types_list) | **GET** /endpoints/connectors/types/ | +[**endpoints_connectors_used_by_list**](EndpointsApi.md#endpoints_connectors_used_by_list) | **GET** /endpoints/connectors/{connector_uuid}/used_by/ | +[**endpoints_device_access_groups_create**](EndpointsApi.md#endpoints_device_access_groups_create) | **POST** /endpoints/device_access_groups/ | +[**endpoints_device_access_groups_destroy**](EndpointsApi.md#endpoints_device_access_groups_destroy) | **DELETE** /endpoints/device_access_groups/{pbm_uuid}/ | +[**endpoints_device_access_groups_list**](EndpointsApi.md#endpoints_device_access_groups_list) | **GET** /endpoints/device_access_groups/ | +[**endpoints_device_access_groups_partial_update**](EndpointsApi.md#endpoints_device_access_groups_partial_update) | **PATCH** /endpoints/device_access_groups/{pbm_uuid}/ | +[**endpoints_device_access_groups_retrieve**](EndpointsApi.md#endpoints_device_access_groups_retrieve) | **GET** /endpoints/device_access_groups/{pbm_uuid}/ | +[**endpoints_device_access_groups_update**](EndpointsApi.md#endpoints_device_access_groups_update) | **PUT** /endpoints/device_access_groups/{pbm_uuid}/ | +[**endpoints_device_access_groups_used_by_list**](EndpointsApi.md#endpoints_device_access_groups_used_by_list) | **GET** /endpoints/device_access_groups/{pbm_uuid}/used_by/ | +[**endpoints_device_bindings_create**](EndpointsApi.md#endpoints_device_bindings_create) | **POST** /endpoints/device_bindings/ | +[**endpoints_device_bindings_destroy**](EndpointsApi.md#endpoints_device_bindings_destroy) | **DELETE** /endpoints/device_bindings/{policy_binding_uuid}/ | +[**endpoints_device_bindings_list**](EndpointsApi.md#endpoints_device_bindings_list) | **GET** /endpoints/device_bindings/ | +[**endpoints_device_bindings_partial_update**](EndpointsApi.md#endpoints_device_bindings_partial_update) | **PATCH** /endpoints/device_bindings/{policy_binding_uuid}/ | +[**endpoints_device_bindings_retrieve**](EndpointsApi.md#endpoints_device_bindings_retrieve) | **GET** /endpoints/device_bindings/{policy_binding_uuid}/ | +[**endpoints_device_bindings_update**](EndpointsApi.md#endpoints_device_bindings_update) | **PUT** /endpoints/device_bindings/{policy_binding_uuid}/ | +[**endpoints_device_bindings_used_by_list**](EndpointsApi.md#endpoints_device_bindings_used_by_list) | **GET** /endpoints/device_bindings/{policy_binding_uuid}/used_by/ | +[**endpoints_devices_destroy**](EndpointsApi.md#endpoints_devices_destroy) | **DELETE** /endpoints/devices/{device_uuid}/ | +[**endpoints_devices_list**](EndpointsApi.md#endpoints_devices_list) | **GET** /endpoints/devices/ | +[**endpoints_devices_partial_update**](EndpointsApi.md#endpoints_devices_partial_update) | **PATCH** /endpoints/devices/{device_uuid}/ | +[**endpoints_devices_retrieve**](EndpointsApi.md#endpoints_devices_retrieve) | **GET** /endpoints/devices/{device_uuid}/ | +[**endpoints_devices_summary_retrieve**](EndpointsApi.md#endpoints_devices_summary_retrieve) | **GET** /endpoints/devices/summary/ | +[**endpoints_devices_update**](EndpointsApi.md#endpoints_devices_update) | **PUT** /endpoints/devices/{device_uuid}/ | +[**endpoints_devices_used_by_list**](EndpointsApi.md#endpoints_devices_used_by_list) | **GET** /endpoints/devices/{device_uuid}/used_by/ | +[**endpoints_fleet_connectors_create**](EndpointsApi.md#endpoints_fleet_connectors_create) | **POST** /endpoints/fleet/connectors/ | +[**endpoints_fleet_connectors_destroy**](EndpointsApi.md#endpoints_fleet_connectors_destroy) | **DELETE** /endpoints/fleet/connectors/{connector_uuid}/ | +[**endpoints_fleet_connectors_list**](EndpointsApi.md#endpoints_fleet_connectors_list) | **GET** /endpoints/fleet/connectors/ | +[**endpoints_fleet_connectors_partial_update**](EndpointsApi.md#endpoints_fleet_connectors_partial_update) | **PATCH** /endpoints/fleet/connectors/{connector_uuid}/ | +[**endpoints_fleet_connectors_retrieve**](EndpointsApi.md#endpoints_fleet_connectors_retrieve) | **GET** /endpoints/fleet/connectors/{connector_uuid}/ | +[**endpoints_fleet_connectors_update**](EndpointsApi.md#endpoints_fleet_connectors_update) | **PUT** /endpoints/fleet/connectors/{connector_uuid}/ | +[**endpoints_fleet_connectors_used_by_list**](EndpointsApi.md#endpoints_fleet_connectors_used_by_list) | **GET** /endpoints/fleet/connectors/{connector_uuid}/used_by/ | +[**endpoints_google_chrome_connectors_create**](EndpointsApi.md#endpoints_google_chrome_connectors_create) | **POST** /endpoints/google_chrome/connectors/ | +[**endpoints_google_chrome_connectors_destroy**](EndpointsApi.md#endpoints_google_chrome_connectors_destroy) | **DELETE** /endpoints/google_chrome/connectors/{connector_uuid}/ | +[**endpoints_google_chrome_connectors_list**](EndpointsApi.md#endpoints_google_chrome_connectors_list) | **GET** /endpoints/google_chrome/connectors/ | +[**endpoints_google_chrome_connectors_partial_update**](EndpointsApi.md#endpoints_google_chrome_connectors_partial_update) | **PATCH** /endpoints/google_chrome/connectors/{connector_uuid}/ | +[**endpoints_google_chrome_connectors_retrieve**](EndpointsApi.md#endpoints_google_chrome_connectors_retrieve) | **GET** /endpoints/google_chrome/connectors/{connector_uuid}/ | +[**endpoints_google_chrome_connectors_update**](EndpointsApi.md#endpoints_google_chrome_connectors_update) | **PUT** /endpoints/google_chrome/connectors/{connector_uuid}/ | +[**endpoints_google_chrome_connectors_used_by_list**](EndpointsApi.md#endpoints_google_chrome_connectors_used_by_list) | **GET** /endpoints/google_chrome/connectors/{connector_uuid}/used_by/ | + + +# **endpoints_agents_connectors_agent_config_retrieve** +> AgentConfig endpoints_agents_connectors_agent_config_retrieve() + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + + +```python +import authentik_client +from authentik_client.models.agent_config import AgentConfig +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + + try: + api_response = api_instance.endpoints_agents_connectors_agent_config_retrieve() + print("The response of EndpointsApi->endpoints_agents_connectors_agent_config_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_agent_config_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**AgentConfig**](AgentConfig.md) + +### Authorization + +[authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_auth_fed_create** +> AgentTokenResponse endpoints_agents_connectors_auth_fed_create(device) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik_device_federation): + +```python +import authentik_client +from authentik_client.models.agent_token_response import AgentTokenResponse +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik_device_federation +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + device = 'device_example' # str | + + try: + api_response = api_instance.endpoints_agents_connectors_auth_fed_create(device) + print("The response of EndpointsApi->endpoints_agents_connectors_auth_fed_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_auth_fed_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **device** | **str**| | + +### Return type + +[**AgentTokenResponse**](AgentTokenResponse.md) + +### Authorization + +[authentik_device_federation](../README.md#authentik_device_federation) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**404** | Device not found | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_auth_ia_create** +> AgentAuthenticationResponse endpoints_agents_connectors_auth_ia_create() + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + + +```python +import authentik_client +from authentik_client.models.agent_authentication_response import AgentAuthenticationResponse +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + + try: + api_response = api_instance.endpoints_agents_connectors_auth_ia_create() + print("The response of EndpointsApi->endpoints_agents_connectors_auth_ia_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_auth_ia_create: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**AgentAuthenticationResponse**](AgentAuthenticationResponse.md) + +### Authorization + +[authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_check_in_create** +> endpoints_agents_connectors_check_in_create(device_facts_request=device_facts_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + + +```python +import authentik_client +from authentik_client.models.device_facts_request import DeviceFactsRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + device_facts_request = authentik_client.DeviceFactsRequest() # DeviceFactsRequest | (optional) + + try: + api_instance.endpoints_agents_connectors_check_in_create(device_facts_request=device_facts_request) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_check_in_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **device_facts_request** | [**DeviceFactsRequest**](DeviceFactsRequest.md)| | [optional] + +### Return type + +void (empty response body) + +### Authorization + +[authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully checked in | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_create** +> AgentConnector endpoints_agents_connectors_create(agent_connector_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.agent_connector import AgentConnector +from authentik_client.models.agent_connector_request import AgentConnectorRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + agent_connector_request = authentik_client.AgentConnectorRequest() # AgentConnectorRequest | + + try: + api_response = api_instance.endpoints_agents_connectors_create(agent_connector_request) + print("The response of EndpointsApi->endpoints_agents_connectors_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **agent_connector_request** | [**AgentConnectorRequest**](AgentConnectorRequest.md)| | + +### Return type + +[**AgentConnector**](AgentConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_destroy** +> endpoints_agents_connectors_destroy(connector_uuid) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Agent Connector. + + try: + api_instance.endpoints_agents_connectors_destroy(connector_uuid) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Agent Connector. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_enroll_create** +> AgentTokenResponse endpoints_agents_connectors_enroll_create(enroll_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik_device_enroll): + +```python +import authentik_client +from authentik_client.models.agent_token_response import AgentTokenResponse +from authentik_client.models.enroll_request import EnrollRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik_device_enroll +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + enroll_request = authentik_client.EnrollRequest() # EnrollRequest | + + try: + api_response = api_instance.endpoints_agents_connectors_enroll_create(enroll_request) + print("The response of EndpointsApi->endpoints_agents_connectors_enroll_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_enroll_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **enroll_request** | [**EnrollRequest**](EnrollRequest.md)| | + +### Return type + +[**AgentTokenResponse**](AgentTokenResponse.md) + +### Authorization + +[authentik_device_enroll](../README.md#authentik_device_enroll) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_list** +> PaginatedAgentConnectorList endpoints_agents_connectors_list(enabled=enabled, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_agent_connector_list import PaginatedAgentConnectorList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + enabled = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.endpoints_agents_connectors_list(enabled=enabled, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of EndpointsApi->endpoints_agents_connectors_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **enabled** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedAgentConnectorList**](PaginatedAgentConnectorList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_mdm_config_create** +> MDMConfigResponse endpoints_agents_connectors_mdm_config_create(connector_uuid, mdm_config_request) + +Generate configuration for MDM systems to deploy authentik Agent + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.mdm_config_request import MDMConfigRequest +from authentik_client.models.mdm_config_response import MDMConfigResponse +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Agent Connector. + mdm_config_request = authentik_client.MDMConfigRequest() # MDMConfigRequest | + + try: + api_response = api_instance.endpoints_agents_connectors_mdm_config_create(connector_uuid, mdm_config_request) + print("The response of EndpointsApi->endpoints_agents_connectors_mdm_config_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_mdm_config_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Agent Connector. | + **mdm_config_request** | [**MDMConfigRequest**](MDMConfigRequest.md)| | + +### Return type + +[**MDMConfigResponse**](MDMConfigResponse.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_partial_update** +> AgentConnector endpoints_agents_connectors_partial_update(connector_uuid, patched_agent_connector_request=patched_agent_connector_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.agent_connector import AgentConnector +from authentik_client.models.patched_agent_connector_request import PatchedAgentConnectorRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Agent Connector. + patched_agent_connector_request = authentik_client.PatchedAgentConnectorRequest() # PatchedAgentConnectorRequest | (optional) + + try: + api_response = api_instance.endpoints_agents_connectors_partial_update(connector_uuid, patched_agent_connector_request=patched_agent_connector_request) + print("The response of EndpointsApi->endpoints_agents_connectors_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Agent Connector. | + **patched_agent_connector_request** | [**PatchedAgentConnectorRequest**](PatchedAgentConnectorRequest.md)| | [optional] + +### Return type + +[**AgentConnector**](AgentConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_retrieve** +> AgentConnector endpoints_agents_connectors_retrieve(connector_uuid) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.agent_connector import AgentConnector +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Agent Connector. + + try: + api_response = api_instance.endpoints_agents_connectors_retrieve(connector_uuid) + print("The response of EndpointsApi->endpoints_agents_connectors_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Agent Connector. | + +### Return type + +[**AgentConnector**](AgentConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_update** +> AgentConnector endpoints_agents_connectors_update(connector_uuid, agent_connector_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.agent_connector import AgentConnector +from authentik_client.models.agent_connector_request import AgentConnectorRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Agent Connector. + agent_connector_request = authentik_client.AgentConnectorRequest() # AgentConnectorRequest | + + try: + api_response = api_instance.endpoints_agents_connectors_update(connector_uuid, agent_connector_request) + print("The response of EndpointsApi->endpoints_agents_connectors_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Agent Connector. | + **agent_connector_request** | [**AgentConnectorRequest**](AgentConnectorRequest.md)| | + +### Return type + +[**AgentConnector**](AgentConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_connectors_used_by_list** +> List[UsedBy] endpoints_agents_connectors_used_by_list(connector_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Agent Connector. + + try: + api_response = api_instance.endpoints_agents_connectors_used_by_list(connector_uuid) + print("The response of EndpointsApi->endpoints_agents_connectors_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_connectors_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Agent Connector. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_enrollment_tokens_create** +> EnrollmentToken endpoints_agents_enrollment_tokens_create(enrollment_token_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.enrollment_token import EnrollmentToken +from authentik_client.models.enrollment_token_request import EnrollmentTokenRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + enrollment_token_request = authentik_client.EnrollmentTokenRequest() # EnrollmentTokenRequest | + + try: + api_response = api_instance.endpoints_agents_enrollment_tokens_create(enrollment_token_request) + print("The response of EndpointsApi->endpoints_agents_enrollment_tokens_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_enrollment_tokens_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **enrollment_token_request** | [**EnrollmentTokenRequest**](EnrollmentTokenRequest.md)| | + +### Return type + +[**EnrollmentToken**](EnrollmentToken.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_enrollment_tokens_destroy** +> endpoints_agents_enrollment_tokens_destroy(token_uuid) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Enrollment Token. + + try: + api_instance.endpoints_agents_enrollment_tokens_destroy(token_uuid) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_enrollment_tokens_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **token_uuid** | **UUID**| A UUID string identifying this Enrollment Token. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_enrollment_tokens_list** +> PaginatedEnrollmentTokenList endpoints_agents_enrollment_tokens_list(connector=connector, ordering=ordering, page=page, page_size=page_size, search=search, token_uuid=token_uuid) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_enrollment_token_list import PaginatedEnrollmentTokenList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.endpoints_agents_enrollment_tokens_list(connector=connector, ordering=ordering, page=page, page_size=page_size, search=search, token_uuid=token_uuid) + print("The response of EndpointsApi->endpoints_agents_enrollment_tokens_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_enrollment_tokens_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **token_uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedEnrollmentTokenList**](PaginatedEnrollmentTokenList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_enrollment_tokens_partial_update** +> EnrollmentToken endpoints_agents_enrollment_tokens_partial_update(token_uuid, patched_enrollment_token_request=patched_enrollment_token_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.enrollment_token import EnrollmentToken +from authentik_client.models.patched_enrollment_token_request import PatchedEnrollmentTokenRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Enrollment Token. + patched_enrollment_token_request = authentik_client.PatchedEnrollmentTokenRequest() # PatchedEnrollmentTokenRequest | (optional) + + try: + api_response = api_instance.endpoints_agents_enrollment_tokens_partial_update(token_uuid, patched_enrollment_token_request=patched_enrollment_token_request) + print("The response of EndpointsApi->endpoints_agents_enrollment_tokens_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_enrollment_tokens_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **token_uuid** | **UUID**| A UUID string identifying this Enrollment Token. | + **patched_enrollment_token_request** | [**PatchedEnrollmentTokenRequest**](PatchedEnrollmentTokenRequest.md)| | [optional] + +### Return type + +[**EnrollmentToken**](EnrollmentToken.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_enrollment_tokens_retrieve** +> EnrollmentToken endpoints_agents_enrollment_tokens_retrieve(token_uuid) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.enrollment_token import EnrollmentToken +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Enrollment Token. + + try: + api_response = api_instance.endpoints_agents_enrollment_tokens_retrieve(token_uuid) + print("The response of EndpointsApi->endpoints_agents_enrollment_tokens_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_enrollment_tokens_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **token_uuid** | **UUID**| A UUID string identifying this Enrollment Token. | + +### Return type + +[**EnrollmentToken**](EnrollmentToken.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_enrollment_tokens_update** +> EnrollmentToken endpoints_agents_enrollment_tokens_update(token_uuid, enrollment_token_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.enrollment_token import EnrollmentToken +from authentik_client.models.enrollment_token_request import EnrollmentTokenRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Enrollment Token. + enrollment_token_request = authentik_client.EnrollmentTokenRequest() # EnrollmentTokenRequest | + + try: + api_response = api_instance.endpoints_agents_enrollment_tokens_update(token_uuid, enrollment_token_request) + print("The response of EndpointsApi->endpoints_agents_enrollment_tokens_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_enrollment_tokens_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **token_uuid** | **UUID**| A UUID string identifying this Enrollment Token. | + **enrollment_token_request** | [**EnrollmentTokenRequest**](EnrollmentTokenRequest.md)| | + +### Return type + +[**EnrollmentToken**](EnrollmentToken.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_enrollment_tokens_used_by_list** +> List[UsedBy] endpoints_agents_enrollment_tokens_used_by_list(token_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Enrollment Token. + + try: + api_response = api_instance.endpoints_agents_enrollment_tokens_used_by_list(token_uuid) + print("The response of EndpointsApi->endpoints_agents_enrollment_tokens_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_enrollment_tokens_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **token_uuid** | **UUID**| A UUID string identifying this Enrollment Token. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_enrollment_tokens_view_key_retrieve** +> TokenView endpoints_agents_enrollment_tokens_view_key_retrieve(token_uuid) + +Return token key and log access + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.token_view import TokenView +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Enrollment Token. + + try: + api_response = api_instance.endpoints_agents_enrollment_tokens_view_key_retrieve(token_uuid) + print("The response of EndpointsApi->endpoints_agents_enrollment_tokens_view_key_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_enrollment_tokens_view_key_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **token_uuid** | **UUID**| A UUID string identifying this Enrollment Token. | + +### Return type + +[**TokenView**](TokenView.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**404** | Token not found or expired | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_psso_ise_create** +> AppleIndependentSecureEnclave endpoints_agents_psso_ise_create(apple_independent_secure_enclave_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave +from authentik_client.models.apple_independent_secure_enclave_request import AppleIndependentSecureEnclaveRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + apple_independent_secure_enclave_request = authentik_client.AppleIndependentSecureEnclaveRequest() # AppleIndependentSecureEnclaveRequest | + + try: + api_response = api_instance.endpoints_agents_psso_ise_create(apple_independent_secure_enclave_request) + print("The response of EndpointsApi->endpoints_agents_psso_ise_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_psso_ise_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **apple_independent_secure_enclave_request** | [**AppleIndependentSecureEnclaveRequest**](AppleIndependentSecureEnclaveRequest.md)| | + +### Return type + +[**AppleIndependentSecureEnclave**](AppleIndependentSecureEnclave.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_psso_ise_destroy** +> endpoints_agents_psso_ise_destroy(uuid) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Apple Independent Secure Enclave. + + try: + api_instance.endpoints_agents_psso_ise_destroy(uuid) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_psso_ise_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Apple Independent Secure Enclave. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_psso_ise_list** +> PaginatedAppleIndependentSecureEnclaveList endpoints_agents_psso_ise_list(apple_enclave_key_id=apple_enclave_key_id, ordering=ordering, page=page, page_size=page_size, search=search, user=user) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_apple_independent_secure_enclave_list import PaginatedAppleIndependentSecureEnclaveList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + apple_enclave_key_id = 'apple_enclave_key_id_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.endpoints_agents_psso_ise_list(apple_enclave_key_id=apple_enclave_key_id, ordering=ordering, page=page, page_size=page_size, search=search, user=user) + print("The response of EndpointsApi->endpoints_agents_psso_ise_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_psso_ise_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **apple_enclave_key_id** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedAppleIndependentSecureEnclaveList**](PaginatedAppleIndependentSecureEnclaveList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_psso_ise_partial_update** +> AppleIndependentSecureEnclave endpoints_agents_psso_ise_partial_update(uuid, patched_apple_independent_secure_enclave_request=patched_apple_independent_secure_enclave_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave +from authentik_client.models.patched_apple_independent_secure_enclave_request import PatchedAppleIndependentSecureEnclaveRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Apple Independent Secure Enclave. + patched_apple_independent_secure_enclave_request = authentik_client.PatchedAppleIndependentSecureEnclaveRequest() # PatchedAppleIndependentSecureEnclaveRequest | (optional) + + try: + api_response = api_instance.endpoints_agents_psso_ise_partial_update(uuid, patched_apple_independent_secure_enclave_request=patched_apple_independent_secure_enclave_request) + print("The response of EndpointsApi->endpoints_agents_psso_ise_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_psso_ise_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Apple Independent Secure Enclave. | + **patched_apple_independent_secure_enclave_request** | [**PatchedAppleIndependentSecureEnclaveRequest**](PatchedAppleIndependentSecureEnclaveRequest.md)| | [optional] + +### Return type + +[**AppleIndependentSecureEnclave**](AppleIndependentSecureEnclave.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_psso_ise_retrieve** +> AppleIndependentSecureEnclave endpoints_agents_psso_ise_retrieve(uuid) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Apple Independent Secure Enclave. + + try: + api_response = api_instance.endpoints_agents_psso_ise_retrieve(uuid) + print("The response of EndpointsApi->endpoints_agents_psso_ise_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_psso_ise_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Apple Independent Secure Enclave. | + +### Return type + +[**AppleIndependentSecureEnclave**](AppleIndependentSecureEnclave.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_psso_ise_update** +> AppleIndependentSecureEnclave endpoints_agents_psso_ise_update(uuid, apple_independent_secure_enclave_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave +from authentik_client.models.apple_independent_secure_enclave_request import AppleIndependentSecureEnclaveRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Apple Independent Secure Enclave. + apple_independent_secure_enclave_request = authentik_client.AppleIndependentSecureEnclaveRequest() # AppleIndependentSecureEnclaveRequest | + + try: + api_response = api_instance.endpoints_agents_psso_ise_update(uuid, apple_independent_secure_enclave_request) + print("The response of EndpointsApi->endpoints_agents_psso_ise_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_psso_ise_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Apple Independent Secure Enclave. | + **apple_independent_secure_enclave_request** | [**AppleIndependentSecureEnclaveRequest**](AppleIndependentSecureEnclaveRequest.md)| | + +### Return type + +[**AppleIndependentSecureEnclave**](AppleIndependentSecureEnclave.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_psso_ise_used_by_list** +> List[UsedBy] endpoints_agents_psso_ise_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Apple Independent Secure Enclave. + + try: + api_response = api_instance.endpoints_agents_psso_ise_used_by_list(uuid) + print("The response of EndpointsApi->endpoints_agents_psso_ise_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_psso_ise_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Apple Independent Secure Enclave. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_psso_register_device_create** +> AgentPSSODeviceRegistrationResponse endpoints_agents_psso_register_device_create(agent_psso_device_registration_request) + +### Example + + +```python +import authentik_client +from authentik_client.models.agent_psso_device_registration_request import AgentPSSODeviceRegistrationRequest +from authentik_client.models.agent_psso_device_registration_response import AgentPSSODeviceRegistrationResponse +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + agent_psso_device_registration_request = authentik_client.AgentPSSODeviceRegistrationRequest() # AgentPSSODeviceRegistrationRequest | + + try: + api_response = api_instance.endpoints_agents_psso_register_device_create(agent_psso_device_registration_request) + print("The response of EndpointsApi->endpoints_agents_psso_register_device_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_psso_register_device_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **agent_psso_device_registration_request** | [**AgentPSSODeviceRegistrationRequest**](AgentPSSODeviceRegistrationRequest.md)| | + +### Return type + +[**AgentPSSODeviceRegistrationResponse**](AgentPSSODeviceRegistrationResponse.md) + +### Authorization + +[authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_agents_psso_register_user_create** +> UserSelf endpoints_agents_psso_register_user_create(agent_psso_user_registration_request) + +### Example + + +```python +import authentik_client +from authentik_client.models.agent_psso_user_registration_request import AgentPSSOUserRegistrationRequest +from authentik_client.models.user_self import UserSelf +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + agent_psso_user_registration_request = authentik_client.AgentPSSOUserRegistrationRequest() # AgentPSSOUserRegistrationRequest | + + try: + api_response = api_instance.endpoints_agents_psso_register_user_create(agent_psso_user_registration_request) + print("The response of EndpointsApi->endpoints_agents_psso_register_user_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_agents_psso_register_user_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **agent_psso_user_registration_request** | [**AgentPSSOUserRegistrationRequest**](AgentPSSOUserRegistrationRequest.md)| | + +### Return type + +[**UserSelf**](UserSelf.md) + +### Authorization + +[authentik_device_auth](../README.md#authentik_device_auth) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_connectors_destroy** +> endpoints_connectors_destroy(connector_uuid) + +Connector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this connector. + + try: + api_instance.endpoints_connectors_destroy(connector_uuid) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_connectors_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this connector. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_connectors_list** +> PaginatedConnectorList endpoints_connectors_list(ordering=ordering, page=page, page_size=page_size, search=search) + +Connector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_connector_list import PaginatedConnectorList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.endpoints_connectors_list(ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of EndpointsApi->endpoints_connectors_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_connectors_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedConnectorList**](PaginatedConnectorList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_connectors_retrieve** +> Connector endpoints_connectors_retrieve(connector_uuid) + +Connector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.connector import Connector +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this connector. + + try: + api_response = api_instance.endpoints_connectors_retrieve(connector_uuid) + print("The response of EndpointsApi->endpoints_connectors_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_connectors_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this connector. | + +### Return type + +[**Connector**](Connector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_connectors_types_list** +> List[TypeCreate] endpoints_connectors_types_list() + +Get all creatable types + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.type_create import TypeCreate +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + + try: + api_response = api_instance.endpoints_connectors_types_list() + print("The response of EndpointsApi->endpoints_connectors_types_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_connectors_types_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[TypeCreate]**](TypeCreate.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_connectors_used_by_list** +> List[UsedBy] endpoints_connectors_used_by_list(connector_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this connector. + + try: + api_response = api_instance.endpoints_connectors_used_by_list(connector_uuid) + print("The response of EndpointsApi->endpoints_connectors_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_connectors_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this connector. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_access_groups_create** +> DeviceAccessGroup endpoints_device_access_groups_create(device_access_group_request) + +DeviceAccessGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device_access_group import DeviceAccessGroup +from authentik_client.models.device_access_group_request import DeviceAccessGroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + device_access_group_request = authentik_client.DeviceAccessGroupRequest() # DeviceAccessGroupRequest | + + try: + api_response = api_instance.endpoints_device_access_groups_create(device_access_group_request) + print("The response of EndpointsApi->endpoints_device_access_groups_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_access_groups_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **device_access_group_request** | [**DeviceAccessGroupRequest**](DeviceAccessGroupRequest.md)| | + +### Return type + +[**DeviceAccessGroup**](DeviceAccessGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_access_groups_destroy** +> endpoints_device_access_groups_destroy(pbm_uuid) + +DeviceAccessGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device access group. + + try: + api_instance.endpoints_device_access_groups_destroy(pbm_uuid) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_access_groups_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Device access group. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_access_groups_list** +> PaginatedDeviceAccessGroupList endpoints_device_access_groups_list(name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, search=search) + +DeviceAccessGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_device_access_group_list import PaginatedDeviceAccessGroupList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.endpoints_device_access_groups_list(name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, search=search) + print("The response of EndpointsApi->endpoints_device_access_groups_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_access_groups_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pbm_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedDeviceAccessGroupList**](PaginatedDeviceAccessGroupList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_access_groups_partial_update** +> DeviceAccessGroup endpoints_device_access_groups_partial_update(pbm_uuid, patched_device_access_group_request=patched_device_access_group_request) + +DeviceAccessGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device_access_group import DeviceAccessGroup +from authentik_client.models.patched_device_access_group_request import PatchedDeviceAccessGroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device access group. + patched_device_access_group_request = authentik_client.PatchedDeviceAccessGroupRequest() # PatchedDeviceAccessGroupRequest | (optional) + + try: + api_response = api_instance.endpoints_device_access_groups_partial_update(pbm_uuid, patched_device_access_group_request=patched_device_access_group_request) + print("The response of EndpointsApi->endpoints_device_access_groups_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_access_groups_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Device access group. | + **patched_device_access_group_request** | [**PatchedDeviceAccessGroupRequest**](PatchedDeviceAccessGroupRequest.md)| | [optional] + +### Return type + +[**DeviceAccessGroup**](DeviceAccessGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_access_groups_retrieve** +> DeviceAccessGroup endpoints_device_access_groups_retrieve(pbm_uuid) + +DeviceAccessGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device_access_group import DeviceAccessGroup +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device access group. + + try: + api_response = api_instance.endpoints_device_access_groups_retrieve(pbm_uuid) + print("The response of EndpointsApi->endpoints_device_access_groups_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_access_groups_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Device access group. | + +### Return type + +[**DeviceAccessGroup**](DeviceAccessGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_access_groups_update** +> DeviceAccessGroup endpoints_device_access_groups_update(pbm_uuid, device_access_group_request) + +DeviceAccessGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device_access_group import DeviceAccessGroup +from authentik_client.models.device_access_group_request import DeviceAccessGroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device access group. + device_access_group_request = authentik_client.DeviceAccessGroupRequest() # DeviceAccessGroupRequest | + + try: + api_response = api_instance.endpoints_device_access_groups_update(pbm_uuid, device_access_group_request) + print("The response of EndpointsApi->endpoints_device_access_groups_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_access_groups_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Device access group. | + **device_access_group_request** | [**DeviceAccessGroupRequest**](DeviceAccessGroupRequest.md)| | + +### Return type + +[**DeviceAccessGroup**](DeviceAccessGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_access_groups_used_by_list** +> List[UsedBy] endpoints_device_access_groups_used_by_list(pbm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device access group. + + try: + api_response = api_instance.endpoints_device_access_groups_used_by_list(pbm_uuid) + print("The response of EndpointsApi->endpoints_device_access_groups_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_access_groups_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Device access group. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_bindings_create** +> DeviceUserBinding endpoints_device_bindings_create(device_user_binding_request) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device_user_binding import DeviceUserBinding +from authentik_client.models.device_user_binding_request import DeviceUserBindingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + device_user_binding_request = authentik_client.DeviceUserBindingRequest() # DeviceUserBindingRequest | + + try: + api_response = api_instance.endpoints_device_bindings_create(device_user_binding_request) + print("The response of EndpointsApi->endpoints_device_bindings_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_bindings_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **device_user_binding_request** | [**DeviceUserBindingRequest**](DeviceUserBindingRequest.md)| | + +### Return type + +[**DeviceUserBinding**](DeviceUserBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_bindings_destroy** +> endpoints_device_bindings_destroy(policy_binding_uuid) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device User binding. + + try: + api_instance.endpoints_device_bindings_destroy(policy_binding_uuid) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_bindings_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Device User binding. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_bindings_list** +> PaginatedDeviceUserBindingList endpoints_device_bindings_list(enabled=enabled, order=order, ordering=ordering, page=page, page_size=page_size, policy=policy, policy__isnull=policy__isnull, search=search, target=target, target_in=target_in, timeout=timeout) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_device_user_binding_list import PaginatedDeviceUserBindingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + enabled = True # bool | (optional) + order = 56 # int | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + policy = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + policy__isnull = True # bool | (optional) + search = 'search_example' # str | A search term. (optional) + target = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + target_in = None # List[UUID] | (optional) + timeout = 56 # int | (optional) + + try: + api_response = api_instance.endpoints_device_bindings_list(enabled=enabled, order=order, ordering=ordering, page=page, page_size=page_size, policy=policy, policy__isnull=policy__isnull, search=search, target=target, target_in=target_in, timeout=timeout) + print("The response of EndpointsApi->endpoints_device_bindings_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_bindings_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **enabled** | **bool**| | [optional] + **order** | **int**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **policy** | **UUID**| | [optional] + **policy__isnull** | **bool**| | [optional] + **search** | **str**| A search term. | [optional] + **target** | **UUID**| | [optional] + **target_in** | [**List[UUID]**](UUID.md)| | [optional] + **timeout** | **int**| | [optional] + +### Return type + +[**PaginatedDeviceUserBindingList**](PaginatedDeviceUserBindingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_bindings_partial_update** +> DeviceUserBinding endpoints_device_bindings_partial_update(policy_binding_uuid, patched_device_user_binding_request=patched_device_user_binding_request) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device_user_binding import DeviceUserBinding +from authentik_client.models.patched_device_user_binding_request import PatchedDeviceUserBindingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device User binding. + patched_device_user_binding_request = authentik_client.PatchedDeviceUserBindingRequest() # PatchedDeviceUserBindingRequest | (optional) + + try: + api_response = api_instance.endpoints_device_bindings_partial_update(policy_binding_uuid, patched_device_user_binding_request=patched_device_user_binding_request) + print("The response of EndpointsApi->endpoints_device_bindings_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_bindings_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Device User binding. | + **patched_device_user_binding_request** | [**PatchedDeviceUserBindingRequest**](PatchedDeviceUserBindingRequest.md)| | [optional] + +### Return type + +[**DeviceUserBinding**](DeviceUserBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_bindings_retrieve** +> DeviceUserBinding endpoints_device_bindings_retrieve(policy_binding_uuid) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device_user_binding import DeviceUserBinding +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device User binding. + + try: + api_response = api_instance.endpoints_device_bindings_retrieve(policy_binding_uuid) + print("The response of EndpointsApi->endpoints_device_bindings_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_bindings_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Device User binding. | + +### Return type + +[**DeviceUserBinding**](DeviceUserBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_bindings_update** +> DeviceUserBinding endpoints_device_bindings_update(policy_binding_uuid, device_user_binding_request) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device_user_binding import DeviceUserBinding +from authentik_client.models.device_user_binding_request import DeviceUserBindingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device User binding. + device_user_binding_request = authentik_client.DeviceUserBindingRequest() # DeviceUserBindingRequest | + + try: + api_response = api_instance.endpoints_device_bindings_update(policy_binding_uuid, device_user_binding_request) + print("The response of EndpointsApi->endpoints_device_bindings_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_bindings_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Device User binding. | + **device_user_binding_request** | [**DeviceUserBindingRequest**](DeviceUserBindingRequest.md)| | + +### Return type + +[**DeviceUserBinding**](DeviceUserBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_device_bindings_used_by_list** +> List[UsedBy] endpoints_device_bindings_used_by_list(policy_binding_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device User binding. + + try: + api_response = api_instance.endpoints_device_bindings_used_by_list(policy_binding_uuid) + print("The response of EndpointsApi->endpoints_device_bindings_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_device_bindings_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Device User binding. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_devices_destroy** +> endpoints_devices_destroy(device_uuid) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + device_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device. + + try: + api_instance.endpoints_devices_destroy(device_uuid) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_devices_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **device_uuid** | **UUID**| A UUID string identifying this Device. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_devices_list** +> PaginatedEndpointDeviceList endpoints_devices_list(identifier=identifier, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_endpoint_device_list import PaginatedEndpointDeviceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + identifier = 'identifier_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.endpoints_devices_list(identifier=identifier, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of EndpointsApi->endpoints_devices_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_devices_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identifier** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedEndpointDeviceList**](PaginatedEndpointDeviceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_devices_partial_update** +> EndpointDevice endpoints_devices_partial_update(device_uuid, patched_endpoint_device_request=patched_endpoint_device_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint_device import EndpointDevice +from authentik_client.models.patched_endpoint_device_request import PatchedEndpointDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + device_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device. + patched_endpoint_device_request = authentik_client.PatchedEndpointDeviceRequest() # PatchedEndpointDeviceRequest | (optional) + + try: + api_response = api_instance.endpoints_devices_partial_update(device_uuid, patched_endpoint_device_request=patched_endpoint_device_request) + print("The response of EndpointsApi->endpoints_devices_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_devices_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **device_uuid** | **UUID**| A UUID string identifying this Device. | + **patched_endpoint_device_request** | [**PatchedEndpointDeviceRequest**](PatchedEndpointDeviceRequest.md)| | [optional] + +### Return type + +[**EndpointDevice**](EndpointDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_devices_retrieve** +> EndpointDeviceDetails endpoints_devices_retrieve(device_uuid) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint_device_details import EndpointDeviceDetails +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + device_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device. + + try: + api_response = api_instance.endpoints_devices_retrieve(device_uuid) + print("The response of EndpointsApi->endpoints_devices_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_devices_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **device_uuid** | **UUID**| A UUID string identifying this Device. | + +### Return type + +[**EndpointDeviceDetails**](EndpointDeviceDetails.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_devices_summary_retrieve** +> DeviceSummary endpoints_devices_summary_retrieve() + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.device_summary import DeviceSummary +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + + try: + api_response = api_instance.endpoints_devices_summary_retrieve() + print("The response of EndpointsApi->endpoints_devices_summary_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_devices_summary_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**DeviceSummary**](DeviceSummary.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_devices_update** +> EndpointDevice endpoints_devices_update(device_uuid, endpoint_device_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint_device import EndpointDevice +from authentik_client.models.endpoint_device_request import EndpointDeviceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + device_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device. + endpoint_device_request = authentik_client.EndpointDeviceRequest() # EndpointDeviceRequest | + + try: + api_response = api_instance.endpoints_devices_update(device_uuid, endpoint_device_request) + print("The response of EndpointsApi->endpoints_devices_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_devices_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **device_uuid** | **UUID**| A UUID string identifying this Device. | + **endpoint_device_request** | [**EndpointDeviceRequest**](EndpointDeviceRequest.md)| | + +### Return type + +[**EndpointDevice**](EndpointDevice.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_devices_used_by_list** +> List[UsedBy] endpoints_devices_used_by_list(device_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + device_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Device. + + try: + api_response = api_instance.endpoints_devices_used_by_list(device_uuid) + print("The response of EndpointsApi->endpoints_devices_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_devices_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **device_uuid** | **UUID**| A UUID string identifying this Device. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_fleet_connectors_create** +> FleetConnector endpoints_fleet_connectors_create(fleet_connector_request) + +FleetConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.fleet_connector import FleetConnector +from authentik_client.models.fleet_connector_request import FleetConnectorRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + fleet_connector_request = authentik_client.FleetConnectorRequest() # FleetConnectorRequest | + + try: + api_response = api_instance.endpoints_fleet_connectors_create(fleet_connector_request) + print("The response of EndpointsApi->endpoints_fleet_connectors_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_fleet_connectors_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **fleet_connector_request** | [**FleetConnectorRequest**](FleetConnectorRequest.md)| | + +### Return type + +[**FleetConnector**](FleetConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_fleet_connectors_destroy** +> endpoints_fleet_connectors_destroy(connector_uuid) + +FleetConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Fleet Connector. + + try: + api_instance.endpoints_fleet_connectors_destroy(connector_uuid) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_fleet_connectors_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Fleet Connector. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_fleet_connectors_list** +> PaginatedFleetConnectorList endpoints_fleet_connectors_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +FleetConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_fleet_connector_list import PaginatedFleetConnectorList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.endpoints_fleet_connectors_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of EndpointsApi->endpoints_fleet_connectors_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_fleet_connectors_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedFleetConnectorList**](PaginatedFleetConnectorList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_fleet_connectors_partial_update** +> FleetConnector endpoints_fleet_connectors_partial_update(connector_uuid, patched_fleet_connector_request=patched_fleet_connector_request) + +FleetConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.fleet_connector import FleetConnector +from authentik_client.models.patched_fleet_connector_request import PatchedFleetConnectorRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Fleet Connector. + patched_fleet_connector_request = authentik_client.PatchedFleetConnectorRequest() # PatchedFleetConnectorRequest | (optional) + + try: + api_response = api_instance.endpoints_fleet_connectors_partial_update(connector_uuid, patched_fleet_connector_request=patched_fleet_connector_request) + print("The response of EndpointsApi->endpoints_fleet_connectors_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_fleet_connectors_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Fleet Connector. | + **patched_fleet_connector_request** | [**PatchedFleetConnectorRequest**](PatchedFleetConnectorRequest.md)| | [optional] + +### Return type + +[**FleetConnector**](FleetConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_fleet_connectors_retrieve** +> FleetConnector endpoints_fleet_connectors_retrieve(connector_uuid) + +FleetConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.fleet_connector import FleetConnector +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Fleet Connector. + + try: + api_response = api_instance.endpoints_fleet_connectors_retrieve(connector_uuid) + print("The response of EndpointsApi->endpoints_fleet_connectors_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_fleet_connectors_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Fleet Connector. | + +### Return type + +[**FleetConnector**](FleetConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_fleet_connectors_update** +> FleetConnector endpoints_fleet_connectors_update(connector_uuid, fleet_connector_request) + +FleetConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.fleet_connector import FleetConnector +from authentik_client.models.fleet_connector_request import FleetConnectorRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Fleet Connector. + fleet_connector_request = authentik_client.FleetConnectorRequest() # FleetConnectorRequest | + + try: + api_response = api_instance.endpoints_fleet_connectors_update(connector_uuid, fleet_connector_request) + print("The response of EndpointsApi->endpoints_fleet_connectors_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_fleet_connectors_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Fleet Connector. | + **fleet_connector_request** | [**FleetConnectorRequest**](FleetConnectorRequest.md)| | + +### Return type + +[**FleetConnector**](FleetConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_fleet_connectors_used_by_list** +> List[UsedBy] endpoints_fleet_connectors_used_by_list(connector_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Fleet Connector. + + try: + api_response = api_instance.endpoints_fleet_connectors_used_by_list(connector_uuid) + print("The response of EndpointsApi->endpoints_fleet_connectors_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_fleet_connectors_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Fleet Connector. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_google_chrome_connectors_create** +> GoogleChromeConnector endpoints_google_chrome_connectors_create(google_chrome_connector_request) + +GoogleChromeConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_chrome_connector import GoogleChromeConnector +from authentik_client.models.google_chrome_connector_request import GoogleChromeConnectorRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + google_chrome_connector_request = authentik_client.GoogleChromeConnectorRequest() # GoogleChromeConnectorRequest | + + try: + api_response = api_instance.endpoints_google_chrome_connectors_create(google_chrome_connector_request) + print("The response of EndpointsApi->endpoints_google_chrome_connectors_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_google_chrome_connectors_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **google_chrome_connector_request** | [**GoogleChromeConnectorRequest**](GoogleChromeConnectorRequest.md)| | + +### Return type + +[**GoogleChromeConnector**](GoogleChromeConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_google_chrome_connectors_destroy** +> endpoints_google_chrome_connectors_destroy(connector_uuid) + +GoogleChromeConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Device Trust Connector. + + try: + api_instance.endpoints_google_chrome_connectors_destroy(connector_uuid) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_google_chrome_connectors_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Google Device Trust Connector. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_google_chrome_connectors_list** +> PaginatedGoogleChromeConnectorList endpoints_google_chrome_connectors_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +GoogleChromeConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_google_chrome_connector_list import PaginatedGoogleChromeConnectorList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.endpoints_google_chrome_connectors_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of EndpointsApi->endpoints_google_chrome_connectors_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_google_chrome_connectors_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedGoogleChromeConnectorList**](PaginatedGoogleChromeConnectorList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_google_chrome_connectors_partial_update** +> GoogleChromeConnector endpoints_google_chrome_connectors_partial_update(connector_uuid, patched_google_chrome_connector_request=patched_google_chrome_connector_request) + +GoogleChromeConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_chrome_connector import GoogleChromeConnector +from authentik_client.models.patched_google_chrome_connector_request import PatchedGoogleChromeConnectorRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Device Trust Connector. + patched_google_chrome_connector_request = authentik_client.PatchedGoogleChromeConnectorRequest() # PatchedGoogleChromeConnectorRequest | (optional) + + try: + api_response = api_instance.endpoints_google_chrome_connectors_partial_update(connector_uuid, patched_google_chrome_connector_request=patched_google_chrome_connector_request) + print("The response of EndpointsApi->endpoints_google_chrome_connectors_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_google_chrome_connectors_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Google Device Trust Connector. | + **patched_google_chrome_connector_request** | [**PatchedGoogleChromeConnectorRequest**](PatchedGoogleChromeConnectorRequest.md)| | [optional] + +### Return type + +[**GoogleChromeConnector**](GoogleChromeConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_google_chrome_connectors_retrieve** +> GoogleChromeConnector endpoints_google_chrome_connectors_retrieve(connector_uuid) + +GoogleChromeConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_chrome_connector import GoogleChromeConnector +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Device Trust Connector. + + try: + api_response = api_instance.endpoints_google_chrome_connectors_retrieve(connector_uuid) + print("The response of EndpointsApi->endpoints_google_chrome_connectors_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_google_chrome_connectors_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Google Device Trust Connector. | + +### Return type + +[**GoogleChromeConnector**](GoogleChromeConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_google_chrome_connectors_update** +> GoogleChromeConnector endpoints_google_chrome_connectors_update(connector_uuid, google_chrome_connector_request) + +GoogleChromeConnector Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_chrome_connector import GoogleChromeConnector +from authentik_client.models.google_chrome_connector_request import GoogleChromeConnectorRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Device Trust Connector. + google_chrome_connector_request = authentik_client.GoogleChromeConnectorRequest() # GoogleChromeConnectorRequest | + + try: + api_response = api_instance.endpoints_google_chrome_connectors_update(connector_uuid, google_chrome_connector_request) + print("The response of EndpointsApi->endpoints_google_chrome_connectors_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_google_chrome_connectors_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Google Device Trust Connector. | + **google_chrome_connector_request** | [**GoogleChromeConnectorRequest**](GoogleChromeConnectorRequest.md)| | + +### Return type + +[**GoogleChromeConnector**](GoogleChromeConnector.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **endpoints_google_chrome_connectors_used_by_list** +> List[UsedBy] endpoints_google_chrome_connectors_used_by_list(connector_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EndpointsApi(api_client) + connector_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Device Trust Connector. + + try: + api_response = api_instance.endpoints_google_chrome_connectors_used_by_list(connector_uuid) + print("The response of EndpointsApi->endpoints_google_chrome_connectors_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EndpointsApi->endpoints_google_chrome_connectors_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connector_uuid** | **UUID**| A UUID string identifying this Google Device Trust Connector. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/EnrollRequest.md b/docs/EnrollRequest.md new file mode 100644 index 000000000..379dbfe67 --- /dev/null +++ b/docs/EnrollRequest.md @@ -0,0 +1,31 @@ +# EnrollRequest + +Base serializer class which doesn't implement create/update methods + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_serial** | **str** | | +**device_name** | **str** | | + +## Example + +```python +from authentik_client.models.enroll_request import EnrollRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EnrollRequest from a JSON string +enroll_request_instance = EnrollRequest.from_json(json) +# print the JSON string representation of the object +print(EnrollRequest.to_json()) + +# convert the object into a dict +enroll_request_dict = enroll_request_instance.to_dict() +# create an instance of EnrollRequest from a dict +enroll_request_from_dict = EnrollRequest.from_dict(enroll_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EnrollmentToken.md b/docs/EnrollmentToken.md new file mode 100644 index 000000000..cfab81ab8 --- /dev/null +++ b/docs/EnrollmentToken.md @@ -0,0 +1,35 @@ +# EnrollmentToken + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**token_uuid** | **UUID** | | [readonly] +**device_group** | **UUID** | | [optional] +**device_group_obj** | [**DeviceAccessGroup**](DeviceAccessGroup.md) | | [readonly] +**connector** | **UUID** | | +**name** | **str** | | +**expiring** | **bool** | | [optional] +**expires** | **datetime** | | [optional] + +## Example + +```python +from authentik_client.models.enrollment_token import EnrollmentToken + +# TODO update the JSON string below +json = "{}" +# create an instance of EnrollmentToken from a JSON string +enrollment_token_instance = EnrollmentToken.from_json(json) +# print the JSON string representation of the object +print(EnrollmentToken.to_json()) + +# convert the object into a dict +enrollment_token_dict = enrollment_token_instance.to_dict() +# create an instance of EnrollmentToken from a dict +enrollment_token_from_dict = EnrollmentToken.from_dict(enrollment_token_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EnrollmentTokenRequest.md b/docs/EnrollmentTokenRequest.md new file mode 100644 index 000000000..ce2172d2b --- /dev/null +++ b/docs/EnrollmentTokenRequest.md @@ -0,0 +1,33 @@ +# EnrollmentTokenRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_group** | **UUID** | | [optional] +**connector** | **UUID** | | +**name** | **str** | | +**expiring** | **bool** | | [optional] +**expires** | **datetime** | | [optional] + +## Example + +```python +from authentik_client.models.enrollment_token_request import EnrollmentTokenRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EnrollmentTokenRequest from a JSON string +enrollment_token_request_instance = EnrollmentTokenRequest.from_json(json) +# print the JSON string representation of the object +print(EnrollmentTokenRequest.to_json()) + +# convert the object into a dict +enrollment_token_request_dict = enrollment_token_request_instance.to_dict() +# create an instance of EnrollmentTokenRequest from a dict +enrollment_token_request_from_dict = EnrollmentTokenRequest.from_dict(enrollment_token_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EnterpriseApi.md b/docs/EnterpriseApi.md new file mode 100644 index 000000000..152528583 --- /dev/null +++ b/docs/EnterpriseApi.md @@ -0,0 +1,792 @@ +# authentik_client.EnterpriseApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**enterprise_license_create**](EnterpriseApi.md#enterprise_license_create) | **POST** /enterprise/license/ | +[**enterprise_license_destroy**](EnterpriseApi.md#enterprise_license_destroy) | **DELETE** /enterprise/license/{license_uuid}/ | +[**enterprise_license_forecast_retrieve**](EnterpriseApi.md#enterprise_license_forecast_retrieve) | **GET** /enterprise/license/forecast/ | +[**enterprise_license_install_id_retrieve**](EnterpriseApi.md#enterprise_license_install_id_retrieve) | **GET** /enterprise/license/install_id/ | +[**enterprise_license_list**](EnterpriseApi.md#enterprise_license_list) | **GET** /enterprise/license/ | +[**enterprise_license_partial_update**](EnterpriseApi.md#enterprise_license_partial_update) | **PATCH** /enterprise/license/{license_uuid}/ | +[**enterprise_license_retrieve**](EnterpriseApi.md#enterprise_license_retrieve) | **GET** /enterprise/license/{license_uuid}/ | +[**enterprise_license_summary_retrieve**](EnterpriseApi.md#enterprise_license_summary_retrieve) | **GET** /enterprise/license/summary/ | +[**enterprise_license_update**](EnterpriseApi.md#enterprise_license_update) | **PUT** /enterprise/license/{license_uuid}/ | +[**enterprise_license_used_by_list**](EnterpriseApi.md#enterprise_license_used_by_list) | **GET** /enterprise/license/{license_uuid}/used_by/ | + + +# **enterprise_license_create** +> License enterprise_license_create(license_request) + +License Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.license import License +from authentik_client.models.license_request import LicenseRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + license_request = authentik_client.LicenseRequest() # LicenseRequest | + + try: + api_response = api_instance.enterprise_license_create(license_request) + print("The response of EnterpriseApi->enterprise_license_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **license_request** | [**LicenseRequest**](LicenseRequest.md)| | + +### Return type + +[**License**](License.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enterprise_license_destroy** +> enterprise_license_destroy(license_uuid) + +License Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + license_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this License. + + try: + api_instance.enterprise_license_destroy(license_uuid) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **license_uuid** | **UUID**| A UUID string identifying this License. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enterprise_license_forecast_retrieve** +> LicenseForecast enterprise_license_forecast_retrieve() + +Forecast how many users will be required in a year + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.license_forecast import LicenseForecast +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + + try: + api_response = api_instance.enterprise_license_forecast_retrieve() + print("The response of EnterpriseApi->enterprise_license_forecast_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_forecast_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**LicenseForecast**](LicenseForecast.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enterprise_license_install_id_retrieve** +> InstallID enterprise_license_install_id_retrieve() + +Get install_id + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.install_id import InstallID +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + + try: + api_response = api_instance.enterprise_license_install_id_retrieve() + print("The response of EnterpriseApi->enterprise_license_install_id_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_install_id_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**InstallID**](InstallID.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enterprise_license_list** +> PaginatedLicenseList enterprise_license_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +License Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_license_list import PaginatedLicenseList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.enterprise_license_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of EnterpriseApi->enterprise_license_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedLicenseList**](PaginatedLicenseList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enterprise_license_partial_update** +> License enterprise_license_partial_update(license_uuid, patched_license_request=patched_license_request) + +License Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.license import License +from authentik_client.models.patched_license_request import PatchedLicenseRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + license_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this License. + patched_license_request = authentik_client.PatchedLicenseRequest() # PatchedLicenseRequest | (optional) + + try: + api_response = api_instance.enterprise_license_partial_update(license_uuid, patched_license_request=patched_license_request) + print("The response of EnterpriseApi->enterprise_license_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **license_uuid** | **UUID**| A UUID string identifying this License. | + **patched_license_request** | [**PatchedLicenseRequest**](PatchedLicenseRequest.md)| | [optional] + +### Return type + +[**License**](License.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enterprise_license_retrieve** +> License enterprise_license_retrieve(license_uuid) + +License Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.license import License +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + license_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this License. + + try: + api_response = api_instance.enterprise_license_retrieve(license_uuid) + print("The response of EnterpriseApi->enterprise_license_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **license_uuid** | **UUID**| A UUID string identifying this License. | + +### Return type + +[**License**](License.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enterprise_license_summary_retrieve** +> LicenseSummary enterprise_license_summary_retrieve(cached=cached) + +Get the total license status + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.license_summary import LicenseSummary +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + cached = True # bool | (optional) (default to True) + + try: + api_response = api_instance.enterprise_license_summary_retrieve(cached=cached) + print("The response of EnterpriseApi->enterprise_license_summary_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_summary_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **cached** | **bool**| | [optional] [default to True] + +### Return type + +[**LicenseSummary**](LicenseSummary.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enterprise_license_update** +> License enterprise_license_update(license_uuid, license_request) + +License Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.license import License +from authentik_client.models.license_request import LicenseRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + license_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this License. + license_request = authentik_client.LicenseRequest() # LicenseRequest | + + try: + api_response = api_instance.enterprise_license_update(license_uuid, license_request) + print("The response of EnterpriseApi->enterprise_license_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **license_uuid** | **UUID**| A UUID string identifying this License. | + **license_request** | [**LicenseRequest**](LicenseRequest.md)| | + +### Return type + +[**License**](License.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **enterprise_license_used_by_list** +> List[UsedBy] enterprise_license_used_by_list(license_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EnterpriseApi(api_client) + license_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this License. + + try: + api_response = api_instance.enterprise_license_used_by_list(license_uuid) + print("The response of EnterpriseApi->enterprise_license_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EnterpriseApi->enterprise_license_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **license_uuid** | **UUID**| A UUID string identifying this License. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/ErrorDetail.md b/docs/ErrorDetail.md new file mode 100644 index 000000000..84dee9fe8 --- /dev/null +++ b/docs/ErrorDetail.md @@ -0,0 +1,31 @@ +# ErrorDetail + +Serializer for rest_framework's error messages + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**string** | **str** | | +**code** | **str** | | + +## Example + +```python +from authentik_client.models.error_detail import ErrorDetail + +# TODO update the JSON string below +json = "{}" +# create an instance of ErrorDetail from a JSON string +error_detail_instance = ErrorDetail.from_json(json) +# print the JSON string representation of the object +print(ErrorDetail.to_json()) + +# convert the object into a dict +error_detail_dict = error_detail_instance.to_dict() +# create an instance of ErrorDetail from a dict +error_detail_from_dict = ErrorDetail.from_dict(error_detail_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ErrorReportingConfig.md b/docs/ErrorReportingConfig.md new file mode 100644 index 000000000..bdcf92242 --- /dev/null +++ b/docs/ErrorReportingConfig.md @@ -0,0 +1,34 @@ +# ErrorReportingConfig + +Config for error reporting + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**enabled** | **bool** | | [readonly] +**sentry_dsn** | **str** | | [readonly] +**environment** | **str** | | [readonly] +**send_pii** | **bool** | | [readonly] +**traces_sample_rate** | **float** | | [readonly] + +## Example + +```python +from authentik_client.models.error_reporting_config import ErrorReportingConfig + +# TODO update the JSON string below +json = "{}" +# create an instance of ErrorReportingConfig from a JSON string +error_reporting_config_instance = ErrorReportingConfig.from_json(json) +# print the JSON string representation of the object +print(ErrorReportingConfig.to_json()) + +# convert the object into a dict +error_reporting_config_dict = error_reporting_config_instance.to_dict() +# create an instance of ErrorReportingConfig from a dict +error_reporting_config_from_dict = ErrorReportingConfig.from_dict(error_reporting_config_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Event.md b/docs/Event.md new file mode 100644 index 000000000..4dc08c76f --- /dev/null +++ b/docs/Event.md @@ -0,0 +1,38 @@ +# Event + +Event Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**user** | **Dict[str, object]** | | [optional] +**action** | [**EventActions**](EventActions.md) | | +**app** | **str** | | +**context** | **Dict[str, object]** | | [optional] +**client_ip** | **str** | | [optional] +**created** | **datetime** | | [readonly] +**expires** | **datetime** | | [optional] +**brand** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.event import Event + +# TODO update the JSON string below +json = "{}" +# create an instance of Event from a JSON string +event_instance = Event.from_json(json) +# print the JSON string representation of the object +print(Event.to_json()) + +# convert the object into a dict +event_dict = event_instance.to_dict() +# create an instance of Event from a dict +event_from_dict = Event.from_dict(event_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EventActions.md b/docs/EventActions.md new file mode 100644 index 000000000..438907f02 --- /dev/null +++ b/docs/EventActions.md @@ -0,0 +1,74 @@ +# EventActions + + +## Enum + +* `LOGIN` (value: `'login'`) + +* `LOGIN_FAILED` (value: `'login_failed'`) + +* `LOGOUT` (value: `'logout'`) + +* `USER_WRITE` (value: `'user_write'`) + +* `SUSPICIOUS_REQUEST` (value: `'suspicious_request'`) + +* `PASSWORD_SET` (value: `'password_set'`) + +* `SECRET_VIEW` (value: `'secret_view'`) + +* `SECRET_ROTATE` (value: `'secret_rotate'`) + +* `INVITATION_USED` (value: `'invitation_used'`) + +* `AUTHORIZE_APPLICATION` (value: `'authorize_application'`) + +* `SOURCE_LINKED` (value: `'source_linked'`) + +* `IMPERSONATION_STARTED` (value: `'impersonation_started'`) + +* `IMPERSONATION_ENDED` (value: `'impersonation_ended'`) + +* `FLOW_EXECUTION` (value: `'flow_execution'`) + +* `POLICY_EXECUTION` (value: `'policy_execution'`) + +* `POLICY_EXCEPTION` (value: `'policy_exception'`) + +* `PROPERTY_MAPPING_EXCEPTION` (value: `'property_mapping_exception'`) + +* `SYSTEM_TASK_EXECUTION` (value: `'system_task_execution'`) + +* `SYSTEM_TASK_EXCEPTION` (value: `'system_task_exception'`) + +* `SYSTEM_EXCEPTION` (value: `'system_exception'`) + +* `CONFIGURATION_ERROR` (value: `'configuration_error'`) + +* `CONFIGURATION_WARNING` (value: `'configuration_warning'`) + +* `MODEL_CREATED` (value: `'model_created'`) + +* `MODEL_UPDATED` (value: `'model_updated'`) + +* `MODEL_DELETED` (value: `'model_deleted'`) + +* `EMAIL_SENT` (value: `'email_sent'`) + +* `UPDATE_AVAILABLE` (value: `'update_available'`) + +* `EXPORT_READY` (value: `'export_ready'`) + +* `REVIEW_INITIATED` (value: `'review_initiated'`) + +* `REVIEW_OVERDUE` (value: `'review_overdue'`) + +* `REVIEW_ATTESTED` (value: `'review_attested'`) + +* `REVIEW_COMPLETED` (value: `'review_completed'`) + +* `CUSTOM` (value: `'custom_'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EventMatcherPolicy.md b/docs/EventMatcherPolicy.md new file mode 100644 index 000000000..cf2352146 --- /dev/null +++ b/docs/EventMatcherPolicy.md @@ -0,0 +1,42 @@ +# EventMatcherPolicy + +Event Matcher Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**bound_to** | **int** | Return objects policy is bound to | [readonly] +**action** | [**EventActions**](EventActions.md) | Match created events with this action type. When left empty, all action types will be matched. | [optional] +**client_ip** | **str** | Matches Event's Client IP (strict matching, for network matching use an Expression Policy) | [optional] +**app** | [**AppEnum**](AppEnum.md) | Match events created by selected application. When left empty, all applications are matched. | [optional] +**model** | [**ModelEnum**](ModelEnum.md) | Match events created by selected model. When left empty, all models are matched. When an app is selected, all the application's models are matched. | [optional] +**query** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.event_matcher_policy import EventMatcherPolicy + +# TODO update the JSON string below +json = "{}" +# create an instance of EventMatcherPolicy from a JSON string +event_matcher_policy_instance = EventMatcherPolicy.from_json(json) +# print the JSON string representation of the object +print(EventMatcherPolicy.to_json()) + +# convert the object into a dict +event_matcher_policy_dict = event_matcher_policy_instance.to_dict() +# create an instance of EventMatcherPolicy from a dict +event_matcher_policy_from_dict = EventMatcherPolicy.from_dict(event_matcher_policy_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EventMatcherPolicyRequest.md b/docs/EventMatcherPolicyRequest.md new file mode 100644 index 000000000..310154635 --- /dev/null +++ b/docs/EventMatcherPolicyRequest.md @@ -0,0 +1,36 @@ +# EventMatcherPolicyRequest + +Event Matcher Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**action** | [**EventActions**](EventActions.md) | Match created events with this action type. When left empty, all action types will be matched. | [optional] +**client_ip** | **str** | Matches Event's Client IP (strict matching, for network matching use an Expression Policy) | [optional] +**app** | [**AppEnum**](AppEnum.md) | Match events created by selected application. When left empty, all applications are matched. | [optional] +**model** | [**ModelEnum**](ModelEnum.md) | Match events created by selected model. When left empty, all models are matched. When an app is selected, all the application's models are matched. | [optional] +**query** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.event_matcher_policy_request import EventMatcherPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EventMatcherPolicyRequest from a JSON string +event_matcher_policy_request_instance = EventMatcherPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(EventMatcherPolicyRequest.to_json()) + +# convert the object into a dict +event_matcher_policy_request_dict = event_matcher_policy_request_instance.to_dict() +# create an instance of EventMatcherPolicyRequest from a dict +event_matcher_policy_request_from_dict = EventMatcherPolicyRequest.from_dict(event_matcher_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EventRequest.md b/docs/EventRequest.md new file mode 100644 index 000000000..2c06db44d --- /dev/null +++ b/docs/EventRequest.md @@ -0,0 +1,36 @@ +# EventRequest + +Event Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user** | **Dict[str, object]** | | [optional] +**action** | [**EventActions**](EventActions.md) | | +**app** | **str** | | +**context** | **Dict[str, object]** | | [optional] +**client_ip** | **str** | | [optional] +**expires** | **datetime** | | [optional] +**brand** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.event_request import EventRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of EventRequest from a JSON string +event_request_instance = EventRequest.from_json(json) +# print the JSON string representation of the object +print(EventRequest.to_json()) + +# convert the object into a dict +event_request_dict = event_request_instance.to_dict() +# create an instance of EventRequest from a dict +event_request_from_dict = EventRequest.from_dict(event_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EventStats.md b/docs/EventStats.md new file mode 100644 index 000000000..93519957f --- /dev/null +++ b/docs/EventStats.md @@ -0,0 +1,31 @@ +# EventStats + +Count of unique users in events and aggregated counts per specified deltas + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**unique_users** | **int** | | +**count_step** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.event_stats import EventStats + +# TODO update the JSON string below +json = "{}" +# create an instance of EventStats from a JSON string +event_stats_instance = EventStats.from_json(json) +# print the JSON string representation of the object +print(EventStats.to_json()) + +# convert the object into a dict +event_stats_dict = event_stats_instance.to_dict() +# create an instance of EventStats from a dict +event_stats_from_dict = EventStats.from_dict(event_stats_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EventTopPerUser.md b/docs/EventTopPerUser.md new file mode 100644 index 000000000..37ceea649 --- /dev/null +++ b/docs/EventTopPerUser.md @@ -0,0 +1,32 @@ +# EventTopPerUser + +Response object of Event's top_per_user + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**application** | **Dict[str, object]** | | +**counted_events** | **int** | | +**unique_users** | **int** | | + +## Example + +```python +from authentik_client.models.event_top_per_user import EventTopPerUser + +# TODO update the JSON string below +json = "{}" +# create an instance of EventTopPerUser from a JSON string +event_top_per_user_instance = EventTopPerUser.from_json(json) +# print the JSON string representation of the object +print(EventTopPerUser.to_json()) + +# convert the object into a dict +event_top_per_user_dict = event_top_per_user_instance.to_dict() +# create an instance of EventTopPerUser from a dict +event_top_per_user_from_dict = EventTopPerUser.from_dict(event_top_per_user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EventVolume.md b/docs/EventVolume.md new file mode 100644 index 000000000..4dc96ff7c --- /dev/null +++ b/docs/EventVolume.md @@ -0,0 +1,32 @@ +# EventVolume + +Count of events of action created on day for a single event action + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**action** | [**EventActions**](EventActions.md) | | +**time** | **datetime** | | +**count** | **int** | | + +## Example + +```python +from authentik_client.models.event_volume import EventVolume + +# TODO update the JSON string below +json = "{}" +# create an instance of EventVolume from a JSON string +event_volume_instance = EventVolume.from_json(json) +# print the JSON string representation of the object +print(EventVolume.to_json()) + +# convert the object into a dict +event_volume_dict = event_volume_instance.to_dict() +# create an instance of EventVolume from a dict +event_volume_from_dict = EventVolume.from_dict(event_volume_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EventsApi.md b/docs/EventsApi.md new file mode 100644 index 000000000..75ffc5a6e --- /dev/null +++ b/docs/EventsApi.md @@ -0,0 +1,2740 @@ +# authentik_client.EventsApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**events_events_actions_list**](EventsApi.md#events_events_actions_list) | **GET** /events/events/actions/ | +[**events_events_create**](EventsApi.md#events_events_create) | **POST** /events/events/ | +[**events_events_destroy**](EventsApi.md#events_events_destroy) | **DELETE** /events/events/{event_uuid}/ | +[**events_events_export_create**](EventsApi.md#events_events_export_create) | **POST** /events/events/export/ | +[**events_events_list**](EventsApi.md#events_events_list) | **GET** /events/events/ | +[**events_events_partial_update**](EventsApi.md#events_events_partial_update) | **PATCH** /events/events/{event_uuid}/ | +[**events_events_retrieve**](EventsApi.md#events_events_retrieve) | **GET** /events/events/{event_uuid}/ | +[**events_events_stats_retrieve**](EventsApi.md#events_events_stats_retrieve) | **GET** /events/events/stats/ | +[**events_events_top_per_user_list**](EventsApi.md#events_events_top_per_user_list) | **GET** /events/events/top_per_user/ | +[**events_events_update**](EventsApi.md#events_events_update) | **PUT** /events/events/{event_uuid}/ | +[**events_events_volume_list**](EventsApi.md#events_events_volume_list) | **GET** /events/events/volume/ | +[**events_notifications_destroy**](EventsApi.md#events_notifications_destroy) | **DELETE** /events/notifications/{uuid}/ | +[**events_notifications_list**](EventsApi.md#events_notifications_list) | **GET** /events/notifications/ | +[**events_notifications_mark_all_seen_create**](EventsApi.md#events_notifications_mark_all_seen_create) | **POST** /events/notifications/mark_all_seen/ | +[**events_notifications_partial_update**](EventsApi.md#events_notifications_partial_update) | **PATCH** /events/notifications/{uuid}/ | +[**events_notifications_retrieve**](EventsApi.md#events_notifications_retrieve) | **GET** /events/notifications/{uuid}/ | +[**events_notifications_update**](EventsApi.md#events_notifications_update) | **PUT** /events/notifications/{uuid}/ | +[**events_notifications_used_by_list**](EventsApi.md#events_notifications_used_by_list) | **GET** /events/notifications/{uuid}/used_by/ | +[**events_rules_create**](EventsApi.md#events_rules_create) | **POST** /events/rules/ | +[**events_rules_destroy**](EventsApi.md#events_rules_destroy) | **DELETE** /events/rules/{pbm_uuid}/ | +[**events_rules_list**](EventsApi.md#events_rules_list) | **GET** /events/rules/ | +[**events_rules_partial_update**](EventsApi.md#events_rules_partial_update) | **PATCH** /events/rules/{pbm_uuid}/ | +[**events_rules_retrieve**](EventsApi.md#events_rules_retrieve) | **GET** /events/rules/{pbm_uuid}/ | +[**events_rules_update**](EventsApi.md#events_rules_update) | **PUT** /events/rules/{pbm_uuid}/ | +[**events_rules_used_by_list**](EventsApi.md#events_rules_used_by_list) | **GET** /events/rules/{pbm_uuid}/used_by/ | +[**events_transports_create**](EventsApi.md#events_transports_create) | **POST** /events/transports/ | +[**events_transports_destroy**](EventsApi.md#events_transports_destroy) | **DELETE** /events/transports/{uuid}/ | +[**events_transports_list**](EventsApi.md#events_transports_list) | **GET** /events/transports/ | +[**events_transports_partial_update**](EventsApi.md#events_transports_partial_update) | **PATCH** /events/transports/{uuid}/ | +[**events_transports_retrieve**](EventsApi.md#events_transports_retrieve) | **GET** /events/transports/{uuid}/ | +[**events_transports_test_create**](EventsApi.md#events_transports_test_create) | **POST** /events/transports/{uuid}/test/ | +[**events_transports_update**](EventsApi.md#events_transports_update) | **PUT** /events/transports/{uuid}/ | +[**events_transports_used_by_list**](EventsApi.md#events_transports_used_by_list) | **GET** /events/transports/{uuid}/used_by/ | + + +# **events_events_actions_list** +> List[TypeCreate] events_events_actions_list() + +Get all actions + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.type_create import TypeCreate +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + + try: + api_response = api_instance.events_events_actions_list() + print("The response of EventsApi->events_events_actions_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_actions_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[TypeCreate]**](TypeCreate.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_create** +> Event events_events_create(event_request) + +Event Read-Only Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event import Event +from authentik_client.models.event_request import EventRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + event_request = authentik_client.EventRequest() # EventRequest | + + try: + api_response = api_instance.events_events_create(event_request) + print("The response of EventsApi->events_events_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **event_request** | [**EventRequest**](EventRequest.md)| | + +### Return type + +[**Event**](Event.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_destroy** +> events_events_destroy(event_uuid) + +Event Read-Only Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + event_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Event. + + try: + api_instance.events_events_destroy(event_uuid) + except Exception as e: + print("Exception when calling EventsApi->events_events_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **event_uuid** | **UUID**| A UUID string identifying this Event. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_export_create** +> DataExport events_events_export_create(action=action, actions=actions, brand_name=brand_name, client_ip=client_ip, context_authorized_app=context_authorized_app, context_device=context_device, context_model_app=context_model_app, context_model_name=context_model_name, context_model_pk=context_model_pk, ordering=ordering, search=search, username=username) + +Create a data export for this data type. Note that the export is generated asynchronously: +this method returns a `DataExport` object that will initially have `completed=false` as well +as the permanent URL to that object in the `Location` header. +You can poll that URL until `completed=true`, at which point the `file_url` property will +contain a URL to download + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.data_export import DataExport +from authentik_client.models.event_actions import EventActions +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + action = 'action_example' # str | (optional) + actions = [authentik_client.EventActions()] # List[EventActions] | (optional) + brand_name = 'brand_name_example' # str | Brand name (optional) + client_ip = 'client_ip_example' # str | (optional) + context_authorized_app = 'context_authorized_app_example' # str | Context Authorized application (optional) + context_device = 'context_device_example' # str | Context Device Primary Key (optional) + context_model_app = 'context_model_app_example' # str | Context Model App (optional) + context_model_name = 'context_model_name_example' # str | Context Model Name (optional) + context_model_pk = 'context_model_pk_example' # str | Context Model Primary Key (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + search = 'search_example' # str | A search term. (optional) + username = 'username_example' # str | Username (optional) + + try: + api_response = api_instance.events_events_export_create(action=action, actions=actions, brand_name=brand_name, client_ip=client_ip, context_authorized_app=context_authorized_app, context_device=context_device, context_model_app=context_model_app, context_model_name=context_model_name, context_model_pk=context_model_pk, ordering=ordering, search=search, username=username) + print("The response of EventsApi->events_events_export_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_export_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **action** | **str**| | [optional] + **actions** | [**List[EventActions]**](EventActions.md)| | [optional] + **brand_name** | **str**| Brand name | [optional] + **client_ip** | **str**| | [optional] + **context_authorized_app** | **str**| Context Authorized application | [optional] + **context_device** | **str**| Context Device Primary Key | [optional] + **context_model_app** | **str**| Context Model App | [optional] + **context_model_name** | **str**| Context Model Name | [optional] + **context_model_pk** | **str**| Context Model Primary Key | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **search** | **str**| A search term. | [optional] + **username** | **str**| Username | [optional] + +### Return type + +[**DataExport**](DataExport.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_list** +> PaginatedEventList events_events_list(action=action, actions=actions, brand_name=brand_name, client_ip=client_ip, context_authorized_app=context_authorized_app, context_device=context_device, context_model_app=context_model_app, context_model_name=context_model_name, context_model_pk=context_model_pk, ordering=ordering, page=page, page_size=page_size, search=search, username=username) + +Event Read-Only Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event_actions import EventActions +from authentik_client.models.paginated_event_list import PaginatedEventList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + action = 'action_example' # str | (optional) + actions = [authentik_client.EventActions()] # List[EventActions] | (optional) + brand_name = 'brand_name_example' # str | Brand name (optional) + client_ip = 'client_ip_example' # str | (optional) + context_authorized_app = 'context_authorized_app_example' # str | Context Authorized application (optional) + context_device = 'context_device_example' # str | Context Device Primary Key (optional) + context_model_app = 'context_model_app_example' # str | Context Model App (optional) + context_model_name = 'context_model_name_example' # str | Context Model Name (optional) + context_model_pk = 'context_model_pk_example' # str | Context Model Primary Key (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + username = 'username_example' # str | Username (optional) + + try: + api_response = api_instance.events_events_list(action=action, actions=actions, brand_name=brand_name, client_ip=client_ip, context_authorized_app=context_authorized_app, context_device=context_device, context_model_app=context_model_app, context_model_name=context_model_name, context_model_pk=context_model_pk, ordering=ordering, page=page, page_size=page_size, search=search, username=username) + print("The response of EventsApi->events_events_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **action** | **str**| | [optional] + **actions** | [**List[EventActions]**](EventActions.md)| | [optional] + **brand_name** | **str**| Brand name | [optional] + **client_ip** | **str**| | [optional] + **context_authorized_app** | **str**| Context Authorized application | [optional] + **context_device** | **str**| Context Device Primary Key | [optional] + **context_model_app** | **str**| Context Model App | [optional] + **context_model_name** | **str**| Context Model Name | [optional] + **context_model_pk** | **str**| Context Model Primary Key | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **username** | **str**| Username | [optional] + +### Return type + +[**PaginatedEventList**](PaginatedEventList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_partial_update** +> Event events_events_partial_update(event_uuid, patched_event_request=patched_event_request) + +Event Read-Only Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event import Event +from authentik_client.models.patched_event_request import PatchedEventRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + event_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Event. + patched_event_request = authentik_client.PatchedEventRequest() # PatchedEventRequest | (optional) + + try: + api_response = api_instance.events_events_partial_update(event_uuid, patched_event_request=patched_event_request) + print("The response of EventsApi->events_events_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **event_uuid** | **UUID**| A UUID string identifying this Event. | + **patched_event_request** | [**PatchedEventRequest**](PatchedEventRequest.md)| | [optional] + +### Return type + +[**Event**](Event.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_retrieve** +> Event events_events_retrieve(event_uuid) + +Event Read-Only Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event import Event +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + event_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Event. + + try: + api_response = api_instance.events_events_retrieve(event_uuid) + print("The response of EventsApi->events_events_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **event_uuid** | **UUID**| A UUID string identifying this Event. | + +### Return type + +[**Event**](Event.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_stats_retrieve** +> EventStats events_events_stats_retrieve(count_steps, action=action, actions=actions, brand_name=brand_name, client_ip=client_ip, context_authorized_app=context_authorized_app, context_device=context_device, context_model_app=context_model_app, context_model_name=context_model_name, context_model_pk=context_model_pk, ordering=ordering, search=search, username=username) + +Get event stats for specified filters and count steps + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event_actions import EventActions +from authentik_client.models.event_stats import EventStats +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + count_steps = ['count_steps_example'] # List[str] | Timedelta, format of 'weeks=3;days=2;hours=3,seconds=2' + action = 'action_example' # str | (optional) + actions = [authentik_client.EventActions()] # List[EventActions] | (optional) + brand_name = 'brand_name_example' # str | Brand name (optional) + client_ip = 'client_ip_example' # str | (optional) + context_authorized_app = 'context_authorized_app_example' # str | Context Authorized application (optional) + context_device = 'context_device_example' # str | Context Device Primary Key (optional) + context_model_app = 'context_model_app_example' # str | Context Model App (optional) + context_model_name = 'context_model_name_example' # str | Context Model Name (optional) + context_model_pk = 'context_model_pk_example' # str | Context Model Primary Key (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + search = 'search_example' # str | A search term. (optional) + username = 'username_example' # str | Username (optional) + + try: + api_response = api_instance.events_events_stats_retrieve(count_steps, action=action, actions=actions, brand_name=brand_name, client_ip=client_ip, context_authorized_app=context_authorized_app, context_device=context_device, context_model_app=context_model_app, context_model_name=context_model_name, context_model_pk=context_model_pk, ordering=ordering, search=search, username=username) + print("The response of EventsApi->events_events_stats_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_stats_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **count_steps** | [**List[str]**](str.md)| Timedelta, format of 'weeks=3;days=2;hours=3,seconds=2' | + **action** | **str**| | [optional] + **actions** | [**List[EventActions]**](EventActions.md)| | [optional] + **brand_name** | **str**| Brand name | [optional] + **client_ip** | **str**| | [optional] + **context_authorized_app** | **str**| Context Authorized application | [optional] + **context_device** | **str**| Context Device Primary Key | [optional] + **context_model_app** | **str**| Context Model App | [optional] + **context_model_name** | **str**| Context Model Name | [optional] + **context_model_pk** | **str**| Context Model Primary Key | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **search** | **str**| A search term. | [optional] + **username** | **str**| Username | [optional] + +### Return type + +[**EventStats**](EventStats.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_top_per_user_list** +> List[EventTopPerUser] events_events_top_per_user_list(action=action, top_n=top_n) + +Get the top_n events grouped by user count + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event_top_per_user import EventTopPerUser +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + action = 'action_example' # str | (optional) + top_n = 56 # int | (optional) + + try: + api_response = api_instance.events_events_top_per_user_list(action=action, top_n=top_n) + print("The response of EventsApi->events_events_top_per_user_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_top_per_user_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **action** | **str**| | [optional] + **top_n** | **int**| | [optional] + +### Return type + +[**List[EventTopPerUser]**](EventTopPerUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_update** +> Event events_events_update(event_uuid, event_request) + +Event Read-Only Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event import Event +from authentik_client.models.event_request import EventRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + event_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Event. + event_request = authentik_client.EventRequest() # EventRequest | + + try: + api_response = api_instance.events_events_update(event_uuid, event_request) + print("The response of EventsApi->events_events_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **event_uuid** | **UUID**| A UUID string identifying this Event. | + **event_request** | [**EventRequest**](EventRequest.md)| | + +### Return type + +[**Event**](Event.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_events_volume_list** +> List[EventVolume] events_events_volume_list(action=action, actions=actions, brand_name=brand_name, client_ip=client_ip, context_authorized_app=context_authorized_app, context_device=context_device, context_model_app=context_model_app, context_model_name=context_model_name, context_model_pk=context_model_pk, history_days=history_days, ordering=ordering, search=search, username=username) + +Get event volume for specified filters and timeframe + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event_actions import EventActions +from authentik_client.models.event_volume import EventVolume +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + action = 'action_example' # str | (optional) + actions = [authentik_client.EventActions()] # List[EventActions] | (optional) + brand_name = 'brand_name_example' # str | Brand name (optional) + client_ip = 'client_ip_example' # str | (optional) + context_authorized_app = 'context_authorized_app_example' # str | Context Authorized application (optional) + context_device = 'context_device_example' # str | Context Device Primary Key (optional) + context_model_app = 'context_model_app_example' # str | Context Model App (optional) + context_model_name = 'context_model_name_example' # str | Context Model Name (optional) + context_model_pk = 'context_model_pk_example' # str | Context Model Primary Key (optional) + history_days = 7 # int | (optional) (default to 7) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + search = 'search_example' # str | A search term. (optional) + username = 'username_example' # str | Username (optional) + + try: + api_response = api_instance.events_events_volume_list(action=action, actions=actions, brand_name=brand_name, client_ip=client_ip, context_authorized_app=context_authorized_app, context_device=context_device, context_model_app=context_model_app, context_model_name=context_model_name, context_model_pk=context_model_pk, history_days=history_days, ordering=ordering, search=search, username=username) + print("The response of EventsApi->events_events_volume_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_events_volume_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **action** | **str**| | [optional] + **actions** | [**List[EventActions]**](EventActions.md)| | [optional] + **brand_name** | **str**| Brand name | [optional] + **client_ip** | **str**| | [optional] + **context_authorized_app** | **str**| Context Authorized application | [optional] + **context_device** | **str**| Context Device Primary Key | [optional] + **context_model_app** | **str**| Context Model App | [optional] + **context_model_name** | **str**| Context Model Name | [optional] + **context_model_pk** | **str**| Context Model Primary Key | [optional] + **history_days** | **int**| | [optional] [default to 7] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **search** | **str**| A search term. | [optional] + **username** | **str**| Username | [optional] + +### Return type + +[**List[EventVolume]**](EventVolume.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_notifications_destroy** +> events_notifications_destroy(uuid) + +Notification Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification. + + try: + api_instance.events_notifications_destroy(uuid) + except Exception as e: + print("Exception when calling EventsApi->events_notifications_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_notifications_list** +> PaginatedNotificationList events_notifications_list(body=body, created=created, event=event, ordering=ordering, page=page, page_size=page_size, search=search, seen=seen, severity=severity, user=user) + +Notification Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_notification_list import PaginatedNotificationList +from authentik_client.models.severity_enum import SeverityEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + body = 'body_example' # str | (optional) + created = '2013-10-20T19:20:30+01:00' # datetime | (optional) + event = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + seen = True # bool | (optional) + severity = authentik_client.SeverityEnum() # SeverityEnum | (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.events_notifications_list(body=body, created=created, event=event, ordering=ordering, page=page, page_size=page_size, search=search, seen=seen, severity=severity, user=user) + print("The response of EventsApi->events_notifications_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_notifications_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **body** | **str**| | [optional] + **created** | **datetime**| | [optional] + **event** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **seen** | **bool**| | [optional] + **severity** | [**SeverityEnum**](.md)| | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedNotificationList**](PaginatedNotificationList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_notifications_mark_all_seen_create** +> events_notifications_mark_all_seen_create() + +Mark all the user's notifications as seen + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + + try: + api_instance.events_notifications_mark_all_seen_create() + except Exception as e: + print("Exception when calling EventsApi->events_notifications_mark_all_seen_create: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Marked tasks as read successfully. | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_notifications_partial_update** +> Notification events_notifications_partial_update(uuid, patched_notification_request=patched_notification_request) + +Notification Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification import Notification +from authentik_client.models.patched_notification_request import PatchedNotificationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification. + patched_notification_request = authentik_client.PatchedNotificationRequest() # PatchedNotificationRequest | (optional) + + try: + api_response = api_instance.events_notifications_partial_update(uuid, patched_notification_request=patched_notification_request) + print("The response of EventsApi->events_notifications_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_notifications_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification. | + **patched_notification_request** | [**PatchedNotificationRequest**](PatchedNotificationRequest.md)| | [optional] + +### Return type + +[**Notification**](Notification.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_notifications_retrieve** +> Notification events_notifications_retrieve(uuid) + +Notification Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification import Notification +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification. + + try: + api_response = api_instance.events_notifications_retrieve(uuid) + print("The response of EventsApi->events_notifications_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_notifications_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification. | + +### Return type + +[**Notification**](Notification.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_notifications_update** +> Notification events_notifications_update(uuid, notification_request=notification_request) + +Notification Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification import Notification +from authentik_client.models.notification_request import NotificationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification. + notification_request = authentik_client.NotificationRequest() # NotificationRequest | (optional) + + try: + api_response = api_instance.events_notifications_update(uuid, notification_request=notification_request) + print("The response of EventsApi->events_notifications_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_notifications_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification. | + **notification_request** | [**NotificationRequest**](NotificationRequest.md)| | [optional] + +### Return type + +[**Notification**](Notification.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_notifications_used_by_list** +> List[UsedBy] events_notifications_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification. + + try: + api_response = api_instance.events_notifications_used_by_list(uuid) + print("The response of EventsApi->events_notifications_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_notifications_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_rules_create** +> NotificationRule events_rules_create(notification_rule_request) + +NotificationRule Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_rule import NotificationRule +from authentik_client.models.notification_rule_request import NotificationRuleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + notification_rule_request = authentik_client.NotificationRuleRequest() # NotificationRuleRequest | + + try: + api_response = api_instance.events_rules_create(notification_rule_request) + print("The response of EventsApi->events_rules_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_rules_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **notification_rule_request** | [**NotificationRuleRequest**](NotificationRuleRequest.md)| | + +### Return type + +[**NotificationRule**](NotificationRule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_rules_destroy** +> events_rules_destroy(pbm_uuid) + +NotificationRule Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Rule. + + try: + api_instance.events_rules_destroy(pbm_uuid) + except Exception as e: + print("Exception when calling EventsApi->events_rules_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Notification Rule. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_rules_list** +> PaginatedNotificationRuleList events_rules_list(destination_group__name=destination_group__name, name=name, ordering=ordering, page=page, page_size=page_size, search=search, severity=severity) + +NotificationRule Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_notification_rule_list import PaginatedNotificationRuleList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + destination_group__name = 'destination_group__name_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + severity = authentik_client.SeverityEnum() # SeverityEnum | (optional) + + try: + api_response = api_instance.events_rules_list(destination_group__name=destination_group__name, name=name, ordering=ordering, page=page, page_size=page_size, search=search, severity=severity) + print("The response of EventsApi->events_rules_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_rules_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **destination_group__name** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **severity** | [**SeverityEnum**](.md)| | [optional] + +### Return type + +[**PaginatedNotificationRuleList**](PaginatedNotificationRuleList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_rules_partial_update** +> NotificationRule events_rules_partial_update(pbm_uuid, patched_notification_rule_request=patched_notification_rule_request) + +NotificationRule Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_rule import NotificationRule +from authentik_client.models.patched_notification_rule_request import PatchedNotificationRuleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Rule. + patched_notification_rule_request = authentik_client.PatchedNotificationRuleRequest() # PatchedNotificationRuleRequest | (optional) + + try: + api_response = api_instance.events_rules_partial_update(pbm_uuid, patched_notification_rule_request=patched_notification_rule_request) + print("The response of EventsApi->events_rules_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_rules_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Notification Rule. | + **patched_notification_rule_request** | [**PatchedNotificationRuleRequest**](PatchedNotificationRuleRequest.md)| | [optional] + +### Return type + +[**NotificationRule**](NotificationRule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_rules_retrieve** +> NotificationRule events_rules_retrieve(pbm_uuid) + +NotificationRule Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_rule import NotificationRule +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Rule. + + try: + api_response = api_instance.events_rules_retrieve(pbm_uuid) + print("The response of EventsApi->events_rules_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_rules_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Notification Rule. | + +### Return type + +[**NotificationRule**](NotificationRule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_rules_update** +> NotificationRule events_rules_update(pbm_uuid, notification_rule_request) + +NotificationRule Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_rule import NotificationRule +from authentik_client.models.notification_rule_request import NotificationRuleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Rule. + notification_rule_request = authentik_client.NotificationRuleRequest() # NotificationRuleRequest | + + try: + api_response = api_instance.events_rules_update(pbm_uuid, notification_rule_request) + print("The response of EventsApi->events_rules_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_rules_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Notification Rule. | + **notification_rule_request** | [**NotificationRuleRequest**](NotificationRuleRequest.md)| | + +### Return type + +[**NotificationRule**](NotificationRule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_rules_used_by_list** +> List[UsedBy] events_rules_used_by_list(pbm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Rule. + + try: + api_response = api_instance.events_rules_used_by_list(pbm_uuid) + print("The response of EventsApi->events_rules_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_rules_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this Notification Rule. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_transports_create** +> NotificationTransport events_transports_create(notification_transport_request) + +NotificationTransport Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_transport import NotificationTransport +from authentik_client.models.notification_transport_request import NotificationTransportRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + notification_transport_request = authentik_client.NotificationTransportRequest() # NotificationTransportRequest | + + try: + api_response = api_instance.events_transports_create(notification_transport_request) + print("The response of EventsApi->events_transports_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_transports_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **notification_transport_request** | [**NotificationTransportRequest**](NotificationTransportRequest.md)| | + +### Return type + +[**NotificationTransport**](NotificationTransport.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_transports_destroy** +> events_transports_destroy(uuid) + +NotificationTransport Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Transport. + + try: + api_instance.events_transports_destroy(uuid) + except Exception as e: + print("Exception when calling EventsApi->events_transports_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification Transport. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_transports_list** +> PaginatedNotificationTransportList events_transports_list(mode=mode, name=name, ordering=ordering, page=page, page_size=page_size, search=search, send_once=send_once, webhook_url=webhook_url) + +NotificationTransport Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_notification_transport_list import PaginatedNotificationTransportList +from authentik_client.models.transport_mode_enum import TransportModeEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + mode = authentik_client.TransportModeEnum() # TransportModeEnum | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + send_once = True # bool | (optional) + webhook_url = 'webhook_url_example' # str | (optional) + + try: + api_response = api_instance.events_transports_list(mode=mode, name=name, ordering=ordering, page=page, page_size=page_size, search=search, send_once=send_once, webhook_url=webhook_url) + print("The response of EventsApi->events_transports_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_transports_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **mode** | [**TransportModeEnum**](.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **send_once** | **bool**| | [optional] + **webhook_url** | **str**| | [optional] + +### Return type + +[**PaginatedNotificationTransportList**](PaginatedNotificationTransportList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_transports_partial_update** +> NotificationTransport events_transports_partial_update(uuid, patched_notification_transport_request=patched_notification_transport_request) + +NotificationTransport Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_transport import NotificationTransport +from authentik_client.models.patched_notification_transport_request import PatchedNotificationTransportRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Transport. + patched_notification_transport_request = authentik_client.PatchedNotificationTransportRequest() # PatchedNotificationTransportRequest | (optional) + + try: + api_response = api_instance.events_transports_partial_update(uuid, patched_notification_transport_request=patched_notification_transport_request) + print("The response of EventsApi->events_transports_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_transports_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification Transport. | + **patched_notification_transport_request** | [**PatchedNotificationTransportRequest**](PatchedNotificationTransportRequest.md)| | [optional] + +### Return type + +[**NotificationTransport**](NotificationTransport.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_transports_retrieve** +> NotificationTransport events_transports_retrieve(uuid) + +NotificationTransport Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_transport import NotificationTransport +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Transport. + + try: + api_response = api_instance.events_transports_retrieve(uuid) + print("The response of EventsApi->events_transports_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_transports_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification Transport. | + +### Return type + +[**NotificationTransport**](NotificationTransport.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_transports_test_create** +> NotificationTransportTest events_transports_test_create(uuid) + +Send example notification using selected transport. Requires +Modify permissions. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_transport_test import NotificationTransportTest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Transport. + + try: + api_response = api_instance.events_transports_test_create(uuid) + print("The response of EventsApi->events_transports_test_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_transports_test_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification Transport. | + +### Return type + +[**NotificationTransportTest**](NotificationTransportTest.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**500** | Failed to test transport | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_transports_update** +> NotificationTransport events_transports_update(uuid, notification_transport_request) + +NotificationTransport Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_transport import NotificationTransport +from authentik_client.models.notification_transport_request import NotificationTransportRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Transport. + notification_transport_request = authentik_client.NotificationTransportRequest() # NotificationTransportRequest | + + try: + api_response = api_instance.events_transports_update(uuid, notification_transport_request) + print("The response of EventsApi->events_transports_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_transports_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification Transport. | + **notification_transport_request** | [**NotificationTransportRequest**](NotificationTransportRequest.md)| | + +### Return type + +[**NotificationTransport**](NotificationTransport.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **events_transports_used_by_list** +> List[UsedBy] events_transports_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.EventsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Notification Transport. + + try: + api_response = api_instance.events_transports_used_by_list(uuid) + print("The response of EventsApi->events_transports_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EventsApi->events_transports_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Notification Transport. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/EventsRequestedEnum.md b/docs/EventsRequestedEnum.md new file mode 100644 index 000000000..5cac7cbce --- /dev/null +++ b/docs/EventsRequestedEnum.md @@ -0,0 +1,26 @@ +# EventsRequestedEnum + + +## Enum + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_SESSION_MINUS_REVOKED` (value: `'https://schemas.openid.net/secevent/caep/event-type/session-revoked'`) + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_TOKEN_MINUS_CLAIMS_MINUS_CHANGE` (value: `'https://schemas.openid.net/secevent/caep/event-type/token-claims-change'`) + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_CREDENTIAL_MINUS_CHANGE` (value: `'https://schemas.openid.net/secevent/caep/event-type/credential-change'`) + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_ASSURANCE_MINUS_LEVEL_MINUS_CHANGE` (value: `'https://schemas.openid.net/secevent/caep/event-type/assurance-level-change'`) + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_DEVICE_MINUS_COMPLIANCE_MINUS_CHANGE` (value: `'https://schemas.openid.net/secevent/caep/event-type/device-compliance-change'`) + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_SESSION_MINUS_ESTABLISHED` (value: `'https://schemas.openid.net/secevent/caep/event-type/session-established'`) + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_SESSION_MINUS_PRESENTED` (value: `'https://schemas.openid.net/secevent/caep/event-type/session-presented'`) + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_CAEP_SLASH_EVENT_MINUS_TYPE_SLASH_RISK_MINUS_LEVEL_MINUS_CHANGE` (value: `'https://schemas.openid.net/secevent/caep/event-type/risk-level-change'`) + +* `HTTPS_COLON_SLASH_SLASH_SCHEMAS_DOT_OPENID_DOT_NET_SLASH_SECEVENT_SLASH_SSF_SLASH_EVENT_MINUS_TYPE_SLASH_VERIFICATION` (value: `'https://schemas.openid.net/secevent/ssf/event-type/verification'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ExpiringBaseGrantModel.md b/docs/ExpiringBaseGrantModel.md new file mode 100644 index 000000000..abbaee1fc --- /dev/null +++ b/docs/ExpiringBaseGrantModel.md @@ -0,0 +1,35 @@ +# ExpiringBaseGrantModel + +Serializer for BaseGrantModel and ExpiringBaseGrant + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**provider** | [**Provider**](Provider.md) | | +**user** | [**User**](User.md) | | +**is_expired** | **bool** | Check if token is expired yet. | [readonly] +**expires** | **datetime** | | [optional] +**scope** | **List[str]** | | + +## Example + +```python +from authentik_client.models.expiring_base_grant_model import ExpiringBaseGrantModel + +# TODO update the JSON string below +json = "{}" +# create an instance of ExpiringBaseGrantModel from a JSON string +expiring_base_grant_model_instance = ExpiringBaseGrantModel.from_json(json) +# print the JSON string representation of the object +print(ExpiringBaseGrantModel.to_json()) + +# convert the object into a dict +expiring_base_grant_model_dict = expiring_base_grant_model_instance.to_dict() +# create an instance of ExpiringBaseGrantModel from a dict +expiring_base_grant_model_from_dict = ExpiringBaseGrantModel.from_dict(expiring_base_grant_model_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ExpressionPolicy.md b/docs/ExpressionPolicy.md new file mode 100644 index 000000000..e37832dfc --- /dev/null +++ b/docs/ExpressionPolicy.md @@ -0,0 +1,38 @@ +# ExpressionPolicy + +Group Membership Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**bound_to** | **int** | Return objects policy is bound to | [readonly] +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.expression_policy import ExpressionPolicy + +# TODO update the JSON string below +json = "{}" +# create an instance of ExpressionPolicy from a JSON string +expression_policy_instance = ExpressionPolicy.from_json(json) +# print the JSON string representation of the object +print(ExpressionPolicy.to_json()) + +# convert the object into a dict +expression_policy_dict = expression_policy_instance.to_dict() +# create an instance of ExpressionPolicy from a dict +expression_policy_from_dict = ExpressionPolicy.from_dict(expression_policy_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ExpressionPolicyRequest.md b/docs/ExpressionPolicyRequest.md new file mode 100644 index 000000000..107ee925e --- /dev/null +++ b/docs/ExpressionPolicyRequest.md @@ -0,0 +1,32 @@ +# ExpressionPolicyRequest + +Group Membership Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.expression_policy_request import ExpressionPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ExpressionPolicyRequest from a JSON string +expression_policy_request_instance = ExpressionPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(ExpressionPolicyRequest.to_json()) + +# convert the object into a dict +expression_policy_request_dict = expression_policy_request_instance.to_dict() +# create an instance of ExpressionPolicyRequest from a dict +expression_policy_request_from_dict = ExpressionPolicyRequest.from_dict(expression_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ExtraRoleObjectPermission.md b/docs/ExtraRoleObjectPermission.md new file mode 100644 index 000000000..9cfe73221 --- /dev/null +++ b/docs/ExtraRoleObjectPermission.md @@ -0,0 +1,38 @@ +# ExtraRoleObjectPermission + +Role permission with additional object-related data + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | [readonly] +**codename** | **str** | | [readonly] +**model** | **str** | | [readonly] +**app_label** | **str** | | [readonly] +**object_pk** | **str** | | +**name** | **str** | | [readonly] +**app_label_verbose** | **str** | Get app label from permission's model | [readonly] +**model_verbose** | **str** | Get model label from permission's model | [readonly] +**object_description** | **str** | Get model description from attached model. This operation takes at least one additional query, and the description is only shown if the role has the view_ permission on the object | [readonly] + +## Example + +```python +from authentik_client.models.extra_role_object_permission import ExtraRoleObjectPermission + +# TODO update the JSON string below +json = "{}" +# create an instance of ExtraRoleObjectPermission from a JSON string +extra_role_object_permission_instance = ExtraRoleObjectPermission.from_json(json) +# print the JSON string representation of the object +print(ExtraRoleObjectPermission.to_json()) + +# convert the object into a dict +extra_role_object_permission_dict = extra_role_object_permission_instance.to_dict() +# create an instance of ExtraRoleObjectPermission from a dict +extra_role_object_permission_from_dict = ExtraRoleObjectPermission.from_dict(extra_role_object_permission_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FileList.md b/docs/FileList.md new file mode 100644 index 000000000..67c3f41e1 --- /dev/null +++ b/docs/FileList.md @@ -0,0 +1,33 @@ +# FileList + +Base serializer class which doesn't implement create/update methods + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**mime_type** | **str** | | +**url** | **str** | | +**themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [optional] + +## Example + +```python +from authentik_client.models.file_list import FileList + +# TODO update the JSON string below +json = "{}" +# create an instance of FileList from a JSON string +file_list_instance = FileList.from_json(json) +# print the JSON string representation of the object +print(FileList.to_json()) + +# convert the object into a dict +file_list_dict = file_list_instance.to_dict() +# create an instance of FileList from a dict +file_list_from_dict = FileList.from_dict(file_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FleetConnector.md b/docs/FleetConnector.md new file mode 100644 index 000000000..c7985658f --- /dev/null +++ b/docs/FleetConnector.md @@ -0,0 +1,40 @@ +# FleetConnector + +FleetConnector Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | +**enabled** | **bool** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**url** | **str** | | +**headers_mapping** | **UUID** | Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs | [optional] +**map_users** | **bool** | | [optional] +**map_teams_access_group** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.fleet_connector import FleetConnector + +# TODO update the JSON string below +json = "{}" +# create an instance of FleetConnector from a JSON string +fleet_connector_instance = FleetConnector.from_json(json) +# print the JSON string representation of the object +print(FleetConnector.to_json()) + +# convert the object into a dict +fleet_connector_dict = fleet_connector_instance.to_dict() +# create an instance of FleetConnector from a dict +fleet_connector_from_dict = FleetConnector.from_dict(fleet_connector_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FleetConnectorRequest.md b/docs/FleetConnectorRequest.md new file mode 100644 index 000000000..b00e89bf5 --- /dev/null +++ b/docs/FleetConnectorRequest.md @@ -0,0 +1,37 @@ +# FleetConnectorRequest + +FleetConnector Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | +**enabled** | **bool** | | [optional] +**url** | **str** | | +**token** | **str** | | +**headers_mapping** | **UUID** | Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs | [optional] +**map_users** | **bool** | | [optional] +**map_teams_access_group** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.fleet_connector_request import FleetConnectorRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of FleetConnectorRequest from a JSON string +fleet_connector_request_instance = FleetConnectorRequest.from_json(json) +# print the JSON string representation of the object +print(FleetConnectorRequest.to_json()) + +# convert the object into a dict +fleet_connector_request_dict = fleet_connector_request_instance.to_dict() +# create an instance of FleetConnectorRequest from a dict +fleet_connector_request_from_dict = FleetConnectorRequest.from_dict(fleet_connector_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Flow.md b/docs/Flow.md new file mode 100644 index 000000000..10703254a --- /dev/null +++ b/docs/Flow.md @@ -0,0 +1,47 @@ +# Flow + +Flow Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**policybindingmodel_ptr_id** | **UUID** | | [readonly] +**name** | **str** | | +**slug** | **str** | Visible in the URL. | +**title** | **str** | Shown as the Title in Flow pages. | +**designation** | [**FlowDesignationEnum**](FlowDesignationEnum.md) | Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik. | +**background** | **str** | Background shown during execution | [optional] +**background_url** | **str** | Get the URL to the background image | [readonly] +**background_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**stages** | **List[UUID]** | | [readonly] +**policies** | **List[UUID]** | | [readonly] +**cache_count** | **int** | Get count of cached flows | [readonly] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**compatibility_mode** | **bool** | Enable compatibility mode, increases compatibility with password managers on mobile devices. | [optional] +**export_url** | **str** | Get export URL for flow | [readonly] +**layout** | [**FlowLayoutEnum**](FlowLayoutEnum.md) | | [optional] +**denied_action** | [**DeniedActionEnum**](DeniedActionEnum.md) | Configure what should happen when a flow denies access to a user. | [optional] +**authentication** | [**AuthenticationEnum**](AuthenticationEnum.md) | Required level of authentication and authorization to access a flow. | [optional] + +## Example + +```python +from authentik_client.models.flow import Flow + +# TODO update the JSON string below +json = "{}" +# create an instance of Flow from a JSON string +flow_instance = Flow.from_json(json) +# print the JSON string representation of the object +print(Flow.to_json()) + +# convert the object into a dict +flow_dict = flow_instance.to_dict() +# create an instance of Flow from a dict +flow_from_dict = Flow.from_dict(flow_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowChallengeResponseRequest.md b/docs/FlowChallengeResponseRequest.md new file mode 100644 index 000000000..0c87e84f5 --- /dev/null +++ b/docs/FlowChallengeResponseRequest.md @@ -0,0 +1,51 @@ +# FlowChallengeResponseRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-user-login'] +**code** | **str** | | +**email** | **str** | | [optional] +**phone_number** | **str** | | [optional] +**selected_challenge** | [**DeviceChallengeRequest**](DeviceChallengeRequest.md) | | [optional] +**selected_stage** | **str** | | [optional] +**webauthn** | **Dict[str, object]** | | [optional] +**duo** | **int** | | [optional] +**response** | **str** | | +**token** | **str** | | +**uid_field** | **str** | | [optional] +**password** | **str** | | +**captcha_token** | **str** | | [optional] +**passkey** | **Dict[str, object]** | | [optional] +**to** | **str** | | +**id** | **int** | | +**first_name** | **str** | | [optional] +**last_name** | **str** | | [optional] +**username** | **str** | | [optional] +**photo_url** | **str** | | [optional] +**auth_date** | **int** | | +**hash** | **str** | | +**remember_me** | **bool** | | + +## Example + +```python +from authentik_client.models.flow_challenge_response_request import FlowChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of FlowChallengeResponseRequest from a JSON string +flow_challenge_response_request_instance = FlowChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(FlowChallengeResponseRequest.to_json()) + +# convert the object into a dict +flow_challenge_response_request_dict = flow_challenge_response_request_instance.to_dict() +# create an instance of FlowChallengeResponseRequest from a dict +flow_challenge_response_request_from_dict = FlowChallengeResponseRequest.from_dict(flow_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowDesignationEnum.md b/docs/FlowDesignationEnum.md new file mode 100644 index 000000000..43f820152 --- /dev/null +++ b/docs/FlowDesignationEnum.md @@ -0,0 +1,22 @@ +# FlowDesignationEnum + + +## Enum + +* `AUTHENTICATION` (value: `'authentication'`) + +* `AUTHORIZATION` (value: `'authorization'`) + +* `INVALIDATION` (value: `'invalidation'`) + +* `ENROLLMENT` (value: `'enrollment'`) + +* `UNENROLLMENT` (value: `'unenrollment'`) + +* `RECOVERY` (value: `'recovery'`) + +* `STAGE_CONFIGURATION` (value: `'stage_configuration'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowDiagram.md b/docs/FlowDiagram.md new file mode 100644 index 000000000..daa7da7a5 --- /dev/null +++ b/docs/FlowDiagram.md @@ -0,0 +1,30 @@ +# FlowDiagram + +response of the flow's diagram action + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**diagram** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.flow_diagram import FlowDiagram + +# TODO update the JSON string below +json = "{}" +# create an instance of FlowDiagram from a JSON string +flow_diagram_instance = FlowDiagram.from_json(json) +# print the JSON string representation of the object +print(FlowDiagram.to_json()) + +# convert the object into a dict +flow_diagram_dict = flow_diagram_instance.to_dict() +# create an instance of FlowDiagram from a dict +flow_diagram_from_dict = FlowDiagram.from_dict(flow_diagram_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowErrorChallenge.md b/docs/FlowErrorChallenge.md new file mode 100644 index 000000000..59253c9e9 --- /dev/null +++ b/docs/FlowErrorChallenge.md @@ -0,0 +1,35 @@ +# FlowErrorChallenge + +Challenge class when an unhandled error occurs during a stage. Normal users are shown an error message, superusers are shown a full stacktrace. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-flow-error'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**request_id** | **str** | | +**error** | **str** | | [optional] +**traceback** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.flow_error_challenge import FlowErrorChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of FlowErrorChallenge from a JSON string +flow_error_challenge_instance = FlowErrorChallenge.from_json(json) +# print the JSON string representation of the object +print(FlowErrorChallenge.to_json()) + +# convert the object into a dict +flow_error_challenge_dict = flow_error_challenge_instance.to_dict() +# create an instance of FlowErrorChallenge from a dict +flow_error_challenge_from_dict = FlowErrorChallenge.from_dict(flow_error_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowInspection.md b/docs/FlowInspection.md new file mode 100644 index 000000000..d7b5756d2 --- /dev/null +++ b/docs/FlowInspection.md @@ -0,0 +1,32 @@ +# FlowInspection + +Serializer for inspect endpoint + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**plans** | [**List[FlowInspectorPlan]**](FlowInspectorPlan.md) | | +**current_plan** | [**FlowInspectorPlan**](FlowInspectorPlan.md) | | [optional] +**is_completed** | **bool** | | + +## Example + +```python +from authentik_client.models.flow_inspection import FlowInspection + +# TODO update the JSON string below +json = "{}" +# create an instance of FlowInspection from a JSON string +flow_inspection_instance = FlowInspection.from_json(json) +# print the JSON string representation of the object +print(FlowInspection.to_json()) + +# convert the object into a dict +flow_inspection_dict = flow_inspection_instance.to_dict() +# create an instance of FlowInspection from a dict +flow_inspection_from_dict = FlowInspection.from_dict(flow_inspection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowInspectorPlan.md b/docs/FlowInspectorPlan.md new file mode 100644 index 000000000..c97d6b5f6 --- /dev/null +++ b/docs/FlowInspectorPlan.md @@ -0,0 +1,33 @@ +# FlowInspectorPlan + +Serializer for an active FlowPlan + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**current_stage** | [**FlowStageBinding**](FlowStageBinding.md) | | [readonly] +**next_planned_stage** | [**FlowStageBinding**](FlowStageBinding.md) | | [readonly] +**plan_context** | **Dict[str, object]** | Get the plan's context, sanitized | [readonly] +**session_id** | **str** | Get a unique session ID | [readonly] + +## Example + +```python +from authentik_client.models.flow_inspector_plan import FlowInspectorPlan + +# TODO update the JSON string below +json = "{}" +# create an instance of FlowInspectorPlan from a JSON string +flow_inspector_plan_instance = FlowInspectorPlan.from_json(json) +# print the JSON string representation of the object +print(FlowInspectorPlan.to_json()) + +# convert the object into a dict +flow_inspector_plan_dict = flow_inspector_plan_instance.to_dict() +# create an instance of FlowInspectorPlan from a dict +flow_inspector_plan_from_dict = FlowInspectorPlan.from_dict(flow_inspector_plan_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowLayoutEnum.md b/docs/FlowLayoutEnum.md new file mode 100644 index 000000000..9eacb8e55 --- /dev/null +++ b/docs/FlowLayoutEnum.md @@ -0,0 +1,22 @@ +# FlowLayoutEnum + + +## Enum + +* `STACKED` (value: `'stacked'`) + +* `CONTENT_LEFT` (value: `'content_left'`) + +* `CONTENT_RIGHT` (value: `'content_right'`) + +* `SIDEBAR_LEFT` (value: `'sidebar_left'`) + +* `SIDEBAR_RIGHT` (value: `'sidebar_right'`) + +* `SIDEBAR_LEFT_FRAME_BACKGROUND` (value: `'sidebar_left_frame_background'`) + +* `SIDEBAR_RIGHT_FRAME_BACKGROUND` (value: `'sidebar_right_frame_background'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowRequest.md b/docs/FlowRequest.md new file mode 100644 index 000000000..5f3e49194 --- /dev/null +++ b/docs/FlowRequest.md @@ -0,0 +1,39 @@ +# FlowRequest + +Flow Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**slug** | **str** | Visible in the URL. | +**title** | **str** | Shown as the Title in Flow pages. | +**designation** | [**FlowDesignationEnum**](FlowDesignationEnum.md) | Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik. | +**background** | **str** | Background shown during execution | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**compatibility_mode** | **bool** | Enable compatibility mode, increases compatibility with password managers on mobile devices. | [optional] +**layout** | [**FlowLayoutEnum**](FlowLayoutEnum.md) | | [optional] +**denied_action** | [**DeniedActionEnum**](DeniedActionEnum.md) | Configure what should happen when a flow denies access to a user. | [optional] +**authentication** | [**AuthenticationEnum**](AuthenticationEnum.md) | Required level of authentication and authorization to access a flow. | [optional] + +## Example + +```python +from authentik_client.models.flow_request import FlowRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of FlowRequest from a JSON string +flow_request_instance = FlowRequest.from_json(json) +# print the JSON string representation of the object +print(FlowRequest.to_json()) + +# convert the object into a dict +flow_request_dict = flow_request_instance.to_dict() +# create an instance of FlowRequest from a dict +flow_request_from_dict = FlowRequest.from_dict(flow_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowSet.md b/docs/FlowSet.md new file mode 100644 index 000000000..e1bd68a17 --- /dev/null +++ b/docs/FlowSet.md @@ -0,0 +1,41 @@ +# FlowSet + +Stripped down flow serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**policybindingmodel_ptr_id** | **UUID** | | [readonly] +**name** | **str** | | +**slug** | **str** | Visible in the URL. | +**title** | **str** | Shown as the Title in Flow pages. | +**designation** | [**FlowDesignationEnum**](FlowDesignationEnum.md) | Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik. | +**background_url** | **str** | Get the URL to the background image | [readonly] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**compatibility_mode** | **bool** | Enable compatibility mode, increases compatibility with password managers on mobile devices. | [optional] +**export_url** | **str** | Get export URL for flow | [readonly] +**layout** | [**FlowLayoutEnum**](FlowLayoutEnum.md) | | [optional] +**denied_action** | [**DeniedActionEnum**](DeniedActionEnum.md) | Configure what should happen when a flow denies access to a user. | [optional] + +## Example + +```python +from authentik_client.models.flow_set import FlowSet + +# TODO update the JSON string below +json = "{}" +# create an instance of FlowSet from a JSON string +flow_set_instance = FlowSet.from_json(json) +# print the JSON string representation of the object +print(FlowSet.to_json()) + +# convert the object into a dict +flow_set_dict = flow_set_instance.to_dict() +# create an instance of FlowSet from a dict +flow_set_from_dict = FlowSet.from_dict(flow_set_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowStageBinding.md b/docs/FlowStageBinding.md new file mode 100644 index 000000000..ad315a29b --- /dev/null +++ b/docs/FlowStageBinding.md @@ -0,0 +1,39 @@ +# FlowStageBinding + +FlowStageBinding Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**policybindingmodel_ptr_id** | **UUID** | | [readonly] +**target** | **UUID** | | +**stage** | **UUID** | | +**stage_obj** | [**Stage**](Stage.md) | | [readonly] +**evaluate_on_plan** | **bool** | Evaluate policies during the Flow planning process. | [optional] +**re_evaluate_policies** | **bool** | Evaluate policies when the Stage is presented to the user. | [optional] +**order** | **int** | | +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**invalid_response_action** | [**InvalidResponseActionEnum**](InvalidResponseActionEnum.md) | Configure how the flow executor should handle an invalid response to a challenge. RETRY returns the error message and a similar challenge to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT restarts the flow while keeping the current context. | [optional] + +## Example + +```python +from authentik_client.models.flow_stage_binding import FlowStageBinding + +# TODO update the JSON string below +json = "{}" +# create an instance of FlowStageBinding from a JSON string +flow_stage_binding_instance = FlowStageBinding.from_json(json) +# print the JSON string representation of the object +print(FlowStageBinding.to_json()) + +# convert the object into a dict +flow_stage_binding_dict = flow_stage_binding_instance.to_dict() +# create an instance of FlowStageBinding from a dict +flow_stage_binding_from_dict = FlowStageBinding.from_dict(flow_stage_binding_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowStageBindingRequest.md b/docs/FlowStageBindingRequest.md new file mode 100644 index 000000000..dc5c3d8f1 --- /dev/null +++ b/docs/FlowStageBindingRequest.md @@ -0,0 +1,36 @@ +# FlowStageBindingRequest + +FlowStageBinding Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**target** | **UUID** | | +**stage** | **UUID** | | +**evaluate_on_plan** | **bool** | Evaluate policies during the Flow planning process. | [optional] +**re_evaluate_policies** | **bool** | Evaluate policies when the Stage is presented to the user. | [optional] +**order** | **int** | | +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**invalid_response_action** | [**InvalidResponseActionEnum**](InvalidResponseActionEnum.md) | Configure how the flow executor should handle an invalid response to a challenge. RETRY returns the error message and a similar challenge to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT restarts the flow while keeping the current context. | [optional] + +## Example + +```python +from authentik_client.models.flow_stage_binding_request import FlowStageBindingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of FlowStageBindingRequest from a JSON string +flow_stage_binding_request_instance = FlowStageBindingRequest.from_json(json) +# print the JSON string representation of the object +print(FlowStageBindingRequest.to_json()) + +# convert the object into a dict +flow_stage_binding_request_dict = flow_stage_binding_request_instance.to_dict() +# create an instance of FlowStageBindingRequest from a dict +flow_stage_binding_request_from_dict = FlowStageBindingRequest.from_dict(flow_stage_binding_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FlowsApi.md b/docs/FlowsApi.md new file mode 100644 index 000000000..c586a6cdc --- /dev/null +++ b/docs/FlowsApi.md @@ -0,0 +1,1770 @@ +# authentik_client.FlowsApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**flows_bindings_create**](FlowsApi.md#flows_bindings_create) | **POST** /flows/bindings/ | +[**flows_bindings_destroy**](FlowsApi.md#flows_bindings_destroy) | **DELETE** /flows/bindings/{fsb_uuid}/ | +[**flows_bindings_list**](FlowsApi.md#flows_bindings_list) | **GET** /flows/bindings/ | +[**flows_bindings_partial_update**](FlowsApi.md#flows_bindings_partial_update) | **PATCH** /flows/bindings/{fsb_uuid}/ | +[**flows_bindings_retrieve**](FlowsApi.md#flows_bindings_retrieve) | **GET** /flows/bindings/{fsb_uuid}/ | +[**flows_bindings_update**](FlowsApi.md#flows_bindings_update) | **PUT** /flows/bindings/{fsb_uuid}/ | +[**flows_bindings_used_by_list**](FlowsApi.md#flows_bindings_used_by_list) | **GET** /flows/bindings/{fsb_uuid}/used_by/ | +[**flows_executor_get**](FlowsApi.md#flows_executor_get) | **GET** /flows/executor/{flow_slug}/ | +[**flows_executor_solve**](FlowsApi.md#flows_executor_solve) | **POST** /flows/executor/{flow_slug}/ | +[**flows_inspector_get**](FlowsApi.md#flows_inspector_get) | **GET** /flows/inspector/{flow_slug}/ | +[**flows_instances_cache_clear_create**](FlowsApi.md#flows_instances_cache_clear_create) | **POST** /flows/instances/cache_clear/ | +[**flows_instances_cache_info_retrieve**](FlowsApi.md#flows_instances_cache_info_retrieve) | **GET** /flows/instances/cache_info/ | +[**flows_instances_create**](FlowsApi.md#flows_instances_create) | **POST** /flows/instances/ | +[**flows_instances_destroy**](FlowsApi.md#flows_instances_destroy) | **DELETE** /flows/instances/{slug}/ | +[**flows_instances_diagram_retrieve**](FlowsApi.md#flows_instances_diagram_retrieve) | **GET** /flows/instances/{slug}/diagram/ | +[**flows_instances_execute_retrieve**](FlowsApi.md#flows_instances_execute_retrieve) | **GET** /flows/instances/{slug}/execute/ | +[**flows_instances_export_retrieve**](FlowsApi.md#flows_instances_export_retrieve) | **GET** /flows/instances/{slug}/export/ | +[**flows_instances_list**](FlowsApi.md#flows_instances_list) | **GET** /flows/instances/ | +[**flows_instances_partial_update**](FlowsApi.md#flows_instances_partial_update) | **PATCH** /flows/instances/{slug}/ | +[**flows_instances_retrieve**](FlowsApi.md#flows_instances_retrieve) | **GET** /flows/instances/{slug}/ | +[**flows_instances_update**](FlowsApi.md#flows_instances_update) | **PUT** /flows/instances/{slug}/ | +[**flows_instances_used_by_list**](FlowsApi.md#flows_instances_used_by_list) | **GET** /flows/instances/{slug}/used_by/ | + + +# **flows_bindings_create** +> FlowStageBinding flows_bindings_create(flow_stage_binding_request) + +FlowStageBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow_stage_binding import FlowStageBinding +from authentik_client.models.flow_stage_binding_request import FlowStageBindingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + flow_stage_binding_request = authentik_client.FlowStageBindingRequest() # FlowStageBindingRequest | + + try: + api_response = api_instance.flows_bindings_create(flow_stage_binding_request) + print("The response of FlowsApi->flows_bindings_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_bindings_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **flow_stage_binding_request** | [**FlowStageBindingRequest**](FlowStageBindingRequest.md)| | + +### Return type + +[**FlowStageBinding**](FlowStageBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_bindings_destroy** +> flows_bindings_destroy(fsb_uuid) + +FlowStageBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + fsb_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Flow Stage Binding. + + try: + api_instance.flows_bindings_destroy(fsb_uuid) + except Exception as e: + print("Exception when calling FlowsApi->flows_bindings_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **fsb_uuid** | **UUID**| A UUID string identifying this Flow Stage Binding. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_bindings_list** +> PaginatedFlowStageBindingList flows_bindings_list(evaluate_on_plan=evaluate_on_plan, fsb_uuid=fsb_uuid, invalid_response_action=invalid_response_action, order=order, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policies=policies, policy_engine_mode=policy_engine_mode, re_evaluate_policies=re_evaluate_policies, search=search, stage=stage, target=target) + +FlowStageBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_flow_stage_binding_list import PaginatedFlowStageBindingList +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + evaluate_on_plan = True # bool | (optional) + fsb_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + invalid_response_action = authentik_client.InvalidResponseActionEnum() # InvalidResponseActionEnum | (optional) + order = 56 # int | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + policies = None # List[UUID] | (optional) + policy_engine_mode = authentik_client.PolicyEngineMode() # PolicyEngineMode | (optional) + re_evaluate_policies = True # bool | (optional) + search = 'search_example' # str | A search term. (optional) + stage = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + target = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.flows_bindings_list(evaluate_on_plan=evaluate_on_plan, fsb_uuid=fsb_uuid, invalid_response_action=invalid_response_action, order=order, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policies=policies, policy_engine_mode=policy_engine_mode, re_evaluate_policies=re_evaluate_policies, search=search, stage=stage, target=target) + print("The response of FlowsApi->flows_bindings_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_bindings_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **evaluate_on_plan** | **bool**| | [optional] + **fsb_uuid** | **UUID**| | [optional] + **invalid_response_action** | [**InvalidResponseActionEnum**](.md)| | [optional] + **order** | **int**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pbm_uuid** | **UUID**| | [optional] + **policies** | [**List[UUID]**](UUID.md)| | [optional] + **policy_engine_mode** | [**PolicyEngineMode**](.md)| | [optional] + **re_evaluate_policies** | **bool**| | [optional] + **search** | **str**| A search term. | [optional] + **stage** | **UUID**| | [optional] + **target** | **UUID**| | [optional] + +### Return type + +[**PaginatedFlowStageBindingList**](PaginatedFlowStageBindingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_bindings_partial_update** +> FlowStageBinding flows_bindings_partial_update(fsb_uuid, patched_flow_stage_binding_request=patched_flow_stage_binding_request) + +FlowStageBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow_stage_binding import FlowStageBinding +from authentik_client.models.patched_flow_stage_binding_request import PatchedFlowStageBindingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + fsb_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Flow Stage Binding. + patched_flow_stage_binding_request = authentik_client.PatchedFlowStageBindingRequest() # PatchedFlowStageBindingRequest | (optional) + + try: + api_response = api_instance.flows_bindings_partial_update(fsb_uuid, patched_flow_stage_binding_request=patched_flow_stage_binding_request) + print("The response of FlowsApi->flows_bindings_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_bindings_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **fsb_uuid** | **UUID**| A UUID string identifying this Flow Stage Binding. | + **patched_flow_stage_binding_request** | [**PatchedFlowStageBindingRequest**](PatchedFlowStageBindingRequest.md)| | [optional] + +### Return type + +[**FlowStageBinding**](FlowStageBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_bindings_retrieve** +> FlowStageBinding flows_bindings_retrieve(fsb_uuid) + +FlowStageBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow_stage_binding import FlowStageBinding +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + fsb_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Flow Stage Binding. + + try: + api_response = api_instance.flows_bindings_retrieve(fsb_uuid) + print("The response of FlowsApi->flows_bindings_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_bindings_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **fsb_uuid** | **UUID**| A UUID string identifying this Flow Stage Binding. | + +### Return type + +[**FlowStageBinding**](FlowStageBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_bindings_update** +> FlowStageBinding flows_bindings_update(fsb_uuid, flow_stage_binding_request) + +FlowStageBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow_stage_binding import FlowStageBinding +from authentik_client.models.flow_stage_binding_request import FlowStageBindingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + fsb_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Flow Stage Binding. + flow_stage_binding_request = authentik_client.FlowStageBindingRequest() # FlowStageBindingRequest | + + try: + api_response = api_instance.flows_bindings_update(fsb_uuid, flow_stage_binding_request) + print("The response of FlowsApi->flows_bindings_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_bindings_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **fsb_uuid** | **UUID**| A UUID string identifying this Flow Stage Binding. | + **flow_stage_binding_request** | [**FlowStageBindingRequest**](FlowStageBindingRequest.md)| | + +### Return type + +[**FlowStageBinding**](FlowStageBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_bindings_used_by_list** +> List[UsedBy] flows_bindings_used_by_list(fsb_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + fsb_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Flow Stage Binding. + + try: + api_response = api_instance.flows_bindings_used_by_list(fsb_uuid) + print("The response of FlowsApi->flows_bindings_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_bindings_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **fsb_uuid** | **UUID**| A UUID string identifying this Flow Stage Binding. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_executor_get** +> ChallengeTypes flows_executor_get(flow_slug, query) + +Get the next pending challenge from the currently active flow. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.challenge_types import ChallengeTypes +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + flow_slug = 'flow_slug_example' # str | + query = 'query_example' # str | Querystring as received + + try: + api_response = api_instance.flows_executor_get(flow_slug, query) + print("The response of FlowsApi->flows_executor_get:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_executor_get: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **flow_slug** | **str**| | + **query** | **str**| Querystring as received | + +### Return type + +[**ChallengeTypes**](ChallengeTypes.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_executor_solve** +> ChallengeTypes flows_executor_solve(flow_slug, query, flow_challenge_response_request=flow_challenge_response_request) + +Solve the previously retrieved challenge and advanced to the next stage. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.challenge_types import ChallengeTypes +from authentik_client.models.flow_challenge_response_request import FlowChallengeResponseRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + flow_slug = 'flow_slug_example' # str | + query = 'query_example' # str | Querystring as received + flow_challenge_response_request = authentik_client.FlowChallengeResponseRequest() # FlowChallengeResponseRequest | (optional) + + try: + api_response = api_instance.flows_executor_solve(flow_slug, query, flow_challenge_response_request=flow_challenge_response_request) + print("The response of FlowsApi->flows_executor_solve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_executor_solve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **flow_slug** | **str**| | + **query** | **str**| Querystring as received | + **flow_challenge_response_request** | [**FlowChallengeResponseRequest**](FlowChallengeResponseRequest.md)| | [optional] + +### Return type + +[**ChallengeTypes**](ChallengeTypes.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_inspector_get** +> FlowInspection flows_inspector_get(flow_slug) + +Get current flow state and record it + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow_inspection import FlowInspection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + flow_slug = 'flow_slug_example' # str | + + try: + api_response = api_instance.flows_inspector_get(flow_slug) + print("The response of FlowsApi->flows_inspector_get:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_inspector_get: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **flow_slug** | **str**| | + +### Return type + +[**FlowInspection**](FlowInspection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | No flow plan in session. | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_cache_clear_create** +> flows_instances_cache_clear_create() + +Clear flow cache + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + + try: + api_instance.flows_instances_cache_clear_create() + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_cache_clear_create: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully cleared cache | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_cache_info_retrieve** +> Cache flows_instances_cache_info_retrieve() + +Info about cached flows + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.cache import Cache +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + + try: + api_response = api_instance.flows_instances_cache_info_retrieve() + print("The response of FlowsApi->flows_instances_cache_info_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_cache_info_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**Cache**](Cache.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_create** +> Flow flows_instances_create(flow_request) + +Flow Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow import Flow +from authentik_client.models.flow_request import FlowRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + flow_request = authentik_client.FlowRequest() # FlowRequest | + + try: + api_response = api_instance.flows_instances_create(flow_request) + print("The response of FlowsApi->flows_instances_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **flow_request** | [**FlowRequest**](FlowRequest.md)| | + +### Return type + +[**Flow**](Flow.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_destroy** +> flows_instances_destroy(slug) + +Flow Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.flows_instances_destroy(slug) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_diagram_retrieve** +> FlowDiagram flows_instances_diagram_retrieve(slug) + +Return diagram for flow with slug `slug`, in the format used by flowchart.js + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow_diagram import FlowDiagram +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.flows_instances_diagram_retrieve(slug) + print("The response of FlowsApi->flows_instances_diagram_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_diagram_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**FlowDiagram**](FlowDiagram.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_execute_retrieve** +> Link flows_instances_execute_retrieve(slug) + +Execute flow for current user + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.link import Link +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.flows_instances_execute_retrieve(slug) + print("The response of FlowsApi->flows_instances_execute_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_execute_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**Link**](Link.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Flow not applicable | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_export_retrieve** +> bytes flows_instances_export_retrieve(slug) + +Export flow to .yaml file + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.flows_instances_export_retrieve(slug) + print("The response of FlowsApi->flows_instances_export_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_export_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +**bytes** + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_list** +> PaginatedFlowList flows_instances_list(denied_action=denied_action, designation=designation, flow_uuid=flow_uuid, name=name, ordering=ordering, page=page, page_size=page_size, search=search, slug=slug) + +Flow Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_flow_list import PaginatedFlowList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + denied_action = authentik_client.DeniedActionEnum() # DeniedActionEnum | (optional) + designation = authentik_client.FlowDesignationEnum() # FlowDesignationEnum | (optional) + flow_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + slug = 'slug_example' # str | (optional) + + try: + api_response = api_instance.flows_instances_list(denied_action=denied_action, designation=designation, flow_uuid=flow_uuid, name=name, ordering=ordering, page=page, page_size=page_size, search=search, slug=slug) + print("The response of FlowsApi->flows_instances_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **denied_action** | [**DeniedActionEnum**](.md)| | [optional] + **designation** | [**FlowDesignationEnum**](.md)| | [optional] + **flow_uuid** | **UUID**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **slug** | **str**| | [optional] + +### Return type + +[**PaginatedFlowList**](PaginatedFlowList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_partial_update** +> Flow flows_instances_partial_update(slug, patched_flow_request=patched_flow_request) + +Flow Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow import Flow +from authentik_client.models.patched_flow_request import PatchedFlowRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + slug = 'slug_example' # str | + patched_flow_request = authentik_client.PatchedFlowRequest() # PatchedFlowRequest | (optional) + + try: + api_response = api_instance.flows_instances_partial_update(slug, patched_flow_request=patched_flow_request) + print("The response of FlowsApi->flows_instances_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **patched_flow_request** | [**PatchedFlowRequest**](PatchedFlowRequest.md)| | [optional] + +### Return type + +[**Flow**](Flow.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_retrieve** +> Flow flows_instances_retrieve(slug) + +Flow Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow import Flow +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.flows_instances_retrieve(slug) + print("The response of FlowsApi->flows_instances_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**Flow**](Flow.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_update** +> Flow flows_instances_update(slug, flow_request) + +Flow Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.flow import Flow +from authentik_client.models.flow_request import FlowRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + slug = 'slug_example' # str | + flow_request = authentik_client.FlowRequest() # FlowRequest | + + try: + api_response = api_instance.flows_instances_update(slug, flow_request) + print("The response of FlowsApi->flows_instances_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **flow_request** | [**FlowRequest**](FlowRequest.md)| | + +### Return type + +[**Flow**](Flow.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **flows_instances_used_by_list** +> List[UsedBy] flows_instances_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.FlowsApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.flows_instances_used_by_list(slug) + print("The response of FlowsApi->flows_instances_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling FlowsApi->flows_instances_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/FooterLink.md b/docs/FooterLink.md new file mode 100644 index 000000000..5de1c2a03 --- /dev/null +++ b/docs/FooterLink.md @@ -0,0 +1,31 @@ +# FooterLink + +Links returned in Config API + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**href** | **str** | | [readonly] +**name** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.footer_link import FooterLink + +# TODO update the JSON string below +json = "{}" +# create an instance of FooterLink from a JSON string +footer_link_instance = FooterLink.from_json(json) +# print the JSON string representation of the object +print(FooterLink.to_json()) + +# convert the object into a dict +footer_link_dict = footer_link_instance.to_dict() +# create an instance of FooterLink from a dict +footer_link_from_dict = FooterLink.from_dict(footer_link_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ForceBindingEnum.md b/docs/ForceBindingEnum.md new file mode 100644 index 000000000..f524bb392 --- /dev/null +++ b/docs/ForceBindingEnum.md @@ -0,0 +1,12 @@ +# ForceBindingEnum + + +## Enum + +* `URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_BINDINGS_COLON_HTTP_MINUS_POST` (value: `'urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST'`) + +* `URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_BINDINGS_COLON_HTTP_MINUS_REDIRECT` (value: `'urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FormatEnum.md b/docs/FormatEnum.md new file mode 100644 index 000000000..782088dfe --- /dev/null +++ b/docs/FormatEnum.md @@ -0,0 +1,12 @@ +# FormatEnum + + +## Enum + +* `JSON` (value: `'json'`) + +* `YAML` (value: `'yaml'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FrameChallenge.md b/docs/FrameChallenge.md new file mode 100644 index 000000000..9103544be --- /dev/null +++ b/docs/FrameChallenge.md @@ -0,0 +1,35 @@ +# FrameChallenge + +Challenge type to render a frame + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'xak-flow-frame'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**url** | **str** | | +**loading_overlay** | **bool** | | [optional] [default to False] +**loading_text** | **str** | | + +## Example + +```python +from authentik_client.models.frame_challenge import FrameChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of FrameChallenge from a JSON string +frame_challenge_instance = FrameChallenge.from_json(json) +# print the JSON string representation of the object +print(FrameChallenge.to_json()) + +# convert the object into a dict +frame_challenge_dict = frame_challenge_instance.to_dict() +# create an instance of FrameChallenge from a dict +frame_challenge_from_dict = FrameChallenge.from_dict(frame_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FrameChallengeResponseRequest.md b/docs/FrameChallengeResponseRequest.md new file mode 100644 index 000000000..6e46aa491 --- /dev/null +++ b/docs/FrameChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# FrameChallengeResponseRequest + +Base class for all challenge responses + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'xak-flow-frame'] + +## Example + +```python +from authentik_client.models.frame_challenge_response_request import FrameChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of FrameChallengeResponseRequest from a JSON string +frame_challenge_response_request_instance = FrameChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(FrameChallengeResponseRequest.to_json()) + +# convert the object into a dict +frame_challenge_response_request_dict = frame_challenge_response_request_instance.to_dict() +# create an instance of FrameChallengeResponseRequest from a dict +frame_challenge_response_request_from_dict = FrameChallengeResponseRequest.from_dict(frame_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GenericError.md b/docs/GenericError.md new file mode 100644 index 000000000..fb8c99a49 --- /dev/null +++ b/docs/GenericError.md @@ -0,0 +1,31 @@ +# GenericError + +Generic API Error + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**detail** | **str** | | +**code** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.generic_error import GenericError + +# TODO update the JSON string below +json = "{}" +# create an instance of GenericError from a JSON string +generic_error_instance = GenericError.from_json(json) +# print the JSON string representation of the object +print(GenericError.to_json()) + +# convert the object into a dict +generic_error_dict = generic_error_instance.to_dict() +# create an instance of GenericError from a dict +generic_error_from_dict = GenericError.from_dict(generic_error_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GeoIPPolicy.md b/docs/GeoIPPolicy.md new file mode 100644 index 000000000..6037a28bb --- /dev/null +++ b/docs/GeoIPPolicy.md @@ -0,0 +1,46 @@ +# GeoIPPolicy + +GeoIP Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**bound_to** | **int** | Return objects policy is bound to | [readonly] +**asns** | **List[int]** | | [optional] +**countries** | [**List[CountryCodeEnum]**](CountryCodeEnum.md) | | +**countries_obj** | [**List[GeoIPPolicyCountriesObjInner]**](GeoIPPolicyCountriesObjInner.md) | | [readonly] +**check_history_distance** | **bool** | | [optional] +**history_max_distance_km** | **int** | | [optional] +**distance_tolerance_km** | **int** | | [optional] +**history_login_count** | **int** | | [optional] +**check_impossible_travel** | **bool** | | [optional] +**impossible_tolerance_km** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.geo_ip_policy import GeoIPPolicy + +# TODO update the JSON string below +json = "{}" +# create an instance of GeoIPPolicy from a JSON string +geo_ip_policy_instance = GeoIPPolicy.from_json(json) +# print the JSON string representation of the object +print(GeoIPPolicy.to_json()) + +# convert the object into a dict +geo_ip_policy_dict = geo_ip_policy_instance.to_dict() +# create an instance of GeoIPPolicy from a dict +geo_ip_policy_from_dict = GeoIPPolicy.from_dict(geo_ip_policy_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GeoIPPolicyCountriesObjInner.md b/docs/GeoIPPolicyCountriesObjInner.md new file mode 100644 index 000000000..6ce6089ed --- /dev/null +++ b/docs/GeoIPPolicyCountriesObjInner.md @@ -0,0 +1,30 @@ +# GeoIPPolicyCountriesObjInner + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**code** | **str** | | +**name** | **str** | | + +## Example + +```python +from authentik_client.models.geo_ip_policy_countries_obj_inner import GeoIPPolicyCountriesObjInner + +# TODO update the JSON string below +json = "{}" +# create an instance of GeoIPPolicyCountriesObjInner from a JSON string +geo_ip_policy_countries_obj_inner_instance = GeoIPPolicyCountriesObjInner.from_json(json) +# print the JSON string representation of the object +print(GeoIPPolicyCountriesObjInner.to_json()) + +# convert the object into a dict +geo_ip_policy_countries_obj_inner_dict = geo_ip_policy_countries_obj_inner_instance.to_dict() +# create an instance of GeoIPPolicyCountriesObjInner from a dict +geo_ip_policy_countries_obj_inner_from_dict = GeoIPPolicyCountriesObjInner.from_dict(geo_ip_policy_countries_obj_inner_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GeoIPPolicyRequest.md b/docs/GeoIPPolicyRequest.md new file mode 100644 index 000000000..aeff1aa68 --- /dev/null +++ b/docs/GeoIPPolicyRequest.md @@ -0,0 +1,39 @@ +# GeoIPPolicyRequest + +GeoIP Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**asns** | **List[int]** | | [optional] +**countries** | [**List[CountryCodeEnum]**](CountryCodeEnum.md) | | +**check_history_distance** | **bool** | | [optional] +**history_max_distance_km** | **int** | | [optional] +**distance_tolerance_km** | **int** | | [optional] +**history_login_count** | **int** | | [optional] +**check_impossible_travel** | **bool** | | [optional] +**impossible_tolerance_km** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.geo_ip_policy_request import GeoIPPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GeoIPPolicyRequest from a JSON string +geo_ip_policy_request_instance = GeoIPPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(GeoIPPolicyRequest.to_json()) + +# convert the object into a dict +geo_ip_policy_request_dict = geo_ip_policy_request_instance.to_dict() +# create an instance of GeoIPPolicyRequest from a dict +geo_ip_policy_request_from_dict = GeoIPPolicyRequest.from_dict(geo_ip_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GeoipBindingEnum.md b/docs/GeoipBindingEnum.md new file mode 100644 index 000000000..7dbc9361b --- /dev/null +++ b/docs/GeoipBindingEnum.md @@ -0,0 +1,16 @@ +# GeoipBindingEnum + + +## Enum + +* `NO_BINDING` (value: `'no_binding'`) + +* `BIND_CONTINENT` (value: `'bind_continent'`) + +* `BIND_CONTINENT_COUNTRY` (value: `'bind_continent_country'`) + +* `BIND_CONTINENT_COUNTRY_CITY` (value: `'bind_continent_country_city'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GlobalTaskStatus.md b/docs/GlobalTaskStatus.md new file mode 100644 index 000000000..bb8206194 --- /dev/null +++ b/docs/GlobalTaskStatus.md @@ -0,0 +1,38 @@ +# GlobalTaskStatus + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**queued** | **int** | | [readonly] +**consumed** | **int** | | [readonly] +**preprocess** | **int** | | [readonly] +**running** | **int** | | [readonly] +**postprocess** | **int** | | [readonly] +**rejected** | **int** | | [readonly] +**done** | **int** | | [readonly] +**info** | **int** | | [readonly] +**warning** | **int** | | [readonly] +**error** | **int** | | [readonly] + +## Example + +```python +from authentik_client.models.global_task_status import GlobalTaskStatus + +# TODO update the JSON string below +json = "{}" +# create an instance of GlobalTaskStatus from a JSON string +global_task_status_instance = GlobalTaskStatus.from_json(json) +# print the JSON string representation of the object +print(GlobalTaskStatus.to_json()) + +# convert the object into a dict +global_task_status_dict = global_task_status_instance.to_dict() +# create an instance of GlobalTaskStatus from a dict +global_task_status_from_dict = GlobalTaskStatus.from_dict(global_task_status_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleChromeConnector.md b/docs/GoogleChromeConnector.md new file mode 100644 index 000000000..a9280022e --- /dev/null +++ b/docs/GoogleChromeConnector.md @@ -0,0 +1,38 @@ +# GoogleChromeConnector + +GoogleChromeConnector Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | +**enabled** | **bool** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**credentials** | **Dict[str, object]** | | +**chrome_url** | **str** | Full URL to be used in Google Workspace configuration | [readonly] + +## Example + +```python +from authentik_client.models.google_chrome_connector import GoogleChromeConnector + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleChromeConnector from a JSON string +google_chrome_connector_instance = GoogleChromeConnector.from_json(json) +# print the JSON string representation of the object +print(GoogleChromeConnector.to_json()) + +# convert the object into a dict +google_chrome_connector_dict = google_chrome_connector_instance.to_dict() +# create an instance of GoogleChromeConnector from a dict +google_chrome_connector_from_dict = GoogleChromeConnector.from_dict(google_chrome_connector_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleChromeConnectorRequest.md b/docs/GoogleChromeConnectorRequest.md new file mode 100644 index 000000000..de285bdfd --- /dev/null +++ b/docs/GoogleChromeConnectorRequest.md @@ -0,0 +1,33 @@ +# GoogleChromeConnectorRequest + +GoogleChromeConnector Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | +**enabled** | **bool** | | [optional] +**credentials** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.google_chrome_connector_request import GoogleChromeConnectorRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleChromeConnectorRequest from a JSON string +google_chrome_connector_request_instance = GoogleChromeConnectorRequest.from_json(json) +# print the JSON string representation of the object +print(GoogleChromeConnectorRequest.to_json()) + +# convert the object into a dict +google_chrome_connector_request_dict = google_chrome_connector_request_instance.to_dict() +# create an instance of GoogleChromeConnectorRequest from a dict +google_chrome_connector_request_from_dict = GoogleChromeConnectorRequest.from_dict(google_chrome_connector_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleEndpointDevice.md b/docs/GoogleEndpointDevice.md new file mode 100644 index 000000000..295da2dcd --- /dev/null +++ b/docs/GoogleEndpointDevice.md @@ -0,0 +1,31 @@ +# GoogleEndpointDevice + +Serializer for Endpoint authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [optional] +**name** | **str** | The human-readable name of this device. | + +## Example + +```python +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleEndpointDevice from a JSON string +google_endpoint_device_instance = GoogleEndpointDevice.from_json(json) +# print the JSON string representation of the object +print(GoogleEndpointDevice.to_json()) + +# convert the object into a dict +google_endpoint_device_dict = google_endpoint_device_instance.to_dict() +# create an instance of GoogleEndpointDevice from a dict +google_endpoint_device_from_dict = GoogleEndpointDevice.from_dict(google_endpoint_device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleEndpointDeviceRequest.md b/docs/GoogleEndpointDeviceRequest.md new file mode 100644 index 000000000..61d8f5d5b --- /dev/null +++ b/docs/GoogleEndpointDeviceRequest.md @@ -0,0 +1,31 @@ +# GoogleEndpointDeviceRequest + +Serializer for Endpoint authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [optional] +**name** | **str** | The human-readable name of this device. | + +## Example + +```python +from authentik_client.models.google_endpoint_device_request import GoogleEndpointDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleEndpointDeviceRequest from a JSON string +google_endpoint_device_request_instance = GoogleEndpointDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(GoogleEndpointDeviceRequest.to_json()) + +# convert the object into a dict +google_endpoint_device_request_dict = google_endpoint_device_request_instance.to_dict() +# create an instance of GoogleEndpointDeviceRequest from a dict +google_endpoint_device_request_from_dict = GoogleEndpointDeviceRequest.from_dict(google_endpoint_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleWorkspaceProvider.md b/docs/GoogleWorkspaceProvider.md new file mode 100644 index 000000000..e49af2819 --- /dev/null +++ b/docs/GoogleWorkspaceProvider.md @@ -0,0 +1,50 @@ +# GoogleWorkspaceProvider + +GoogleWorkspaceProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**delegated_subject** | **str** | | +**credentials** | **Dict[str, object]** | | +**scopes** | **str** | | [optional] +**exclude_users_service_account** | **bool** | | [optional] +**filter_group** | **UUID** | | [optional] +**user_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**group_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**default_group_email_domain** | **str** | | +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] + +## Example + +```python +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleWorkspaceProvider from a JSON string +google_workspace_provider_instance = GoogleWorkspaceProvider.from_json(json) +# print the JSON string representation of the object +print(GoogleWorkspaceProvider.to_json()) + +# convert the object into a dict +google_workspace_provider_dict = google_workspace_provider_instance.to_dict() +# create an instance of GoogleWorkspaceProvider from a dict +google_workspace_provider_from_dict = GoogleWorkspaceProvider.from_dict(google_workspace_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleWorkspaceProviderGroup.md b/docs/GoogleWorkspaceProviderGroup.md new file mode 100644 index 000000000..34af3182b --- /dev/null +++ b/docs/GoogleWorkspaceProviderGroup.md @@ -0,0 +1,35 @@ +# GoogleWorkspaceProviderGroup + +GoogleWorkspaceProviderGroup Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**google_id** | **str** | | +**group** | **UUID** | | +**group_obj** | [**PartialGroup**](PartialGroup.md) | | [readonly] +**provider** | **int** | | +**attributes** | **Dict[str, object]** | | [readonly] + +## Example + +```python +from authentik_client.models.google_workspace_provider_group import GoogleWorkspaceProviderGroup + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleWorkspaceProviderGroup from a JSON string +google_workspace_provider_group_instance = GoogleWorkspaceProviderGroup.from_json(json) +# print the JSON string representation of the object +print(GoogleWorkspaceProviderGroup.to_json()) + +# convert the object into a dict +google_workspace_provider_group_dict = google_workspace_provider_group_instance.to_dict() +# create an instance of GoogleWorkspaceProviderGroup from a dict +google_workspace_provider_group_from_dict = GoogleWorkspaceProviderGroup.from_dict(google_workspace_provider_group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleWorkspaceProviderGroupRequest.md b/docs/GoogleWorkspaceProviderGroupRequest.md new file mode 100644 index 000000000..dbdde350b --- /dev/null +++ b/docs/GoogleWorkspaceProviderGroupRequest.md @@ -0,0 +1,32 @@ +# GoogleWorkspaceProviderGroupRequest + +GoogleWorkspaceProviderGroup Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**google_id** | **str** | | +**group** | **UUID** | | +**provider** | **int** | | + +## Example + +```python +from authentik_client.models.google_workspace_provider_group_request import GoogleWorkspaceProviderGroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleWorkspaceProviderGroupRequest from a JSON string +google_workspace_provider_group_request_instance = GoogleWorkspaceProviderGroupRequest.from_json(json) +# print the JSON string representation of the object +print(GoogleWorkspaceProviderGroupRequest.to_json()) + +# convert the object into a dict +google_workspace_provider_group_request_dict = google_workspace_provider_group_request_instance.to_dict() +# create an instance of GoogleWorkspaceProviderGroupRequest from a dict +google_workspace_provider_group_request_from_dict = GoogleWorkspaceProviderGroupRequest.from_dict(google_workspace_provider_group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleWorkspaceProviderMapping.md b/docs/GoogleWorkspaceProviderMapping.md new file mode 100644 index 000000000..4b0115954 --- /dev/null +++ b/docs/GoogleWorkspaceProviderMapping.md @@ -0,0 +1,37 @@ +# GoogleWorkspaceProviderMapping + +GoogleWorkspaceProviderMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleWorkspaceProviderMapping from a JSON string +google_workspace_provider_mapping_instance = GoogleWorkspaceProviderMapping.from_json(json) +# print the JSON string representation of the object +print(GoogleWorkspaceProviderMapping.to_json()) + +# convert the object into a dict +google_workspace_provider_mapping_dict = google_workspace_provider_mapping_instance.to_dict() +# create an instance of GoogleWorkspaceProviderMapping from a dict +google_workspace_provider_mapping_from_dict = GoogleWorkspaceProviderMapping.from_dict(google_workspace_provider_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleWorkspaceProviderMappingRequest.md b/docs/GoogleWorkspaceProviderMappingRequest.md new file mode 100644 index 000000000..22c95e33c --- /dev/null +++ b/docs/GoogleWorkspaceProviderMappingRequest.md @@ -0,0 +1,32 @@ +# GoogleWorkspaceProviderMappingRequest + +GoogleWorkspaceProviderMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.google_workspace_provider_mapping_request import GoogleWorkspaceProviderMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleWorkspaceProviderMappingRequest from a JSON string +google_workspace_provider_mapping_request_instance = GoogleWorkspaceProviderMappingRequest.from_json(json) +# print the JSON string representation of the object +print(GoogleWorkspaceProviderMappingRequest.to_json()) + +# convert the object into a dict +google_workspace_provider_mapping_request_dict = google_workspace_provider_mapping_request_instance.to_dict() +# create an instance of GoogleWorkspaceProviderMappingRequest from a dict +google_workspace_provider_mapping_request_from_dict = GoogleWorkspaceProviderMappingRequest.from_dict(google_workspace_provider_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleWorkspaceProviderRequest.md b/docs/GoogleWorkspaceProviderRequest.md new file mode 100644 index 000000000..e0c2e9130 --- /dev/null +++ b/docs/GoogleWorkspaceProviderRequest.md @@ -0,0 +1,43 @@ +# GoogleWorkspaceProviderRequest + +GoogleWorkspaceProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**delegated_subject** | **str** | | +**credentials** | **Dict[str, object]** | | +**scopes** | **str** | | [optional] +**exclude_users_service_account** | **bool** | | [optional] +**filter_group** | **UUID** | | [optional] +**user_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**group_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**default_group_email_domain** | **str** | | +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] + +## Example + +```python +from authentik_client.models.google_workspace_provider_request import GoogleWorkspaceProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleWorkspaceProviderRequest from a JSON string +google_workspace_provider_request_instance = GoogleWorkspaceProviderRequest.from_json(json) +# print the JSON string representation of the object +print(GoogleWorkspaceProviderRequest.to_json()) + +# convert the object into a dict +google_workspace_provider_request_dict = google_workspace_provider_request_instance.to_dict() +# create an instance of GoogleWorkspaceProviderRequest from a dict +google_workspace_provider_request_from_dict = GoogleWorkspaceProviderRequest.from_dict(google_workspace_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleWorkspaceProviderUser.md b/docs/GoogleWorkspaceProviderUser.md new file mode 100644 index 000000000..7ad1f8a45 --- /dev/null +++ b/docs/GoogleWorkspaceProviderUser.md @@ -0,0 +1,35 @@ +# GoogleWorkspaceProviderUser + +GoogleWorkspaceProviderUser Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**google_id** | **str** | | +**user** | **int** | | +**user_obj** | [**PartialUser**](PartialUser.md) | | [readonly] +**provider** | **int** | | +**attributes** | **Dict[str, object]** | | [readonly] + +## Example + +```python +from authentik_client.models.google_workspace_provider_user import GoogleWorkspaceProviderUser + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleWorkspaceProviderUser from a JSON string +google_workspace_provider_user_instance = GoogleWorkspaceProviderUser.from_json(json) +# print the JSON string representation of the object +print(GoogleWorkspaceProviderUser.to_json()) + +# convert the object into a dict +google_workspace_provider_user_dict = google_workspace_provider_user_instance.to_dict() +# create an instance of GoogleWorkspaceProviderUser from a dict +google_workspace_provider_user_from_dict = GoogleWorkspaceProviderUser.from_dict(google_workspace_provider_user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GoogleWorkspaceProviderUserRequest.md b/docs/GoogleWorkspaceProviderUserRequest.md new file mode 100644 index 000000000..8cf660d85 --- /dev/null +++ b/docs/GoogleWorkspaceProviderUserRequest.md @@ -0,0 +1,32 @@ +# GoogleWorkspaceProviderUserRequest + +GoogleWorkspaceProviderUser Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**google_id** | **str** | | +**user** | **int** | | +**provider** | **int** | | + +## Example + +```python +from authentik_client.models.google_workspace_provider_user_request import GoogleWorkspaceProviderUserRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GoogleWorkspaceProviderUserRequest from a JSON string +google_workspace_provider_user_request_instance = GoogleWorkspaceProviderUserRequest.from_json(json) +# print the JSON string representation of the object +print(GoogleWorkspaceProviderUserRequest.to_json()) + +# convert the object into a dict +google_workspace_provider_user_request_dict = google_workspace_provider_user_request_instance.to_dict() +# create an instance of GoogleWorkspaceProviderUserRequest from a dict +google_workspace_provider_user_request_from_dict = GoogleWorkspaceProviderUserRequest.from_dict(google_workspace_provider_user_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GrantTypesEnum.md b/docs/GrantTypesEnum.md new file mode 100644 index 000000000..6e5df8d10 --- /dev/null +++ b/docs/GrantTypesEnum.md @@ -0,0 +1,22 @@ +# GrantTypesEnum + + +## Enum + +* `AUTHORIZATION_CODE` (value: `'authorization_code'`) + +* `IMPLICIT` (value: `'implicit'`) + +* `HYBRID` (value: `'hybrid'`) + +* `REFRESH_TOKEN` (value: `'refresh_token'`) + +* `CLIENT_CREDENTIALS` (value: `'client_credentials'`) + +* `PASSWORD` (value: `'password'`) + +* `URN_COLON_IETF_COLON_PARAMS_COLON_OAUTH_COLON_GRANT_MINUS_TYPE_COLON_DEVICE_CODE` (value: `'urn:ietf:params:oauth:grant-type:device_code'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Group.md b/docs/Group.md new file mode 100644 index 000000000..15aacf2ca --- /dev/null +++ b/docs/Group.md @@ -0,0 +1,43 @@ +# Group + +Group Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**num_pk** | **int** | | [readonly] +**name** | **str** | | +**is_superuser** | **bool** | Users added to this group will be superusers. | [optional] +**parents** | **List[UUID]** | | [optional] +**parents_obj** | [**List[RelatedGroup]**](RelatedGroup.md) | | [readonly] +**users** | **List[int]** | | [optional] +**users_obj** | [**List[PartialUser]**](PartialUser.md) | | [readonly] +**attributes** | **Dict[str, object]** | | [optional] +**roles** | **List[UUID]** | | [optional] +**roles_obj** | [**List[Role]**](Role.md) | | [readonly] +**inherited_roles_obj** | [**List[Role]**](Role.md) | | [readonly] +**children** | **List[UUID]** | | [readonly] +**children_obj** | [**List[RelatedGroup]**](RelatedGroup.md) | | [readonly] + +## Example + +```python +from authentik_client.models.group import Group + +# TODO update the JSON string below +json = "{}" +# create an instance of Group from a JSON string +group_instance = Group.from_json(json) +# print the JSON string representation of the object +print(Group.to_json()) + +# convert the object into a dict +group_dict = group_instance.to_dict() +# create an instance of Group from a dict +group_from_dict = Group.from_dict(group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupKerberosSourceConnection.md b/docs/GroupKerberosSourceConnection.md new file mode 100644 index 000000000..d5ff2611d --- /dev/null +++ b/docs/GroupKerberosSourceConnection.md @@ -0,0 +1,36 @@ +# GroupKerberosSourceConnection + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**group** | **UUID** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupKerberosSourceConnection from a JSON string +group_kerberos_source_connection_instance = GroupKerberosSourceConnection.from_json(json) +# print the JSON string representation of the object +print(GroupKerberosSourceConnection.to_json()) + +# convert the object into a dict +group_kerberos_source_connection_dict = group_kerberos_source_connection_instance.to_dict() +# create an instance of GroupKerberosSourceConnection from a dict +group_kerberos_source_connection_from_dict = GroupKerberosSourceConnection.from_dict(group_kerberos_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupKerberosSourceConnectionRequest.md b/docs/GroupKerberosSourceConnectionRequest.md new file mode 100644 index 000000000..ea955098d --- /dev/null +++ b/docs/GroupKerberosSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# GroupKerberosSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.group_kerberos_source_connection_request import GroupKerberosSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupKerberosSourceConnectionRequest from a JSON string +group_kerberos_source_connection_request_instance = GroupKerberosSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(GroupKerberosSourceConnectionRequest.to_json()) + +# convert the object into a dict +group_kerberos_source_connection_request_dict = group_kerberos_source_connection_request_instance.to_dict() +# create an instance of GroupKerberosSourceConnectionRequest from a dict +group_kerberos_source_connection_request_from_dict = GroupKerberosSourceConnectionRequest.from_dict(group_kerberos_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupLDAPSourceConnection.md b/docs/GroupLDAPSourceConnection.md new file mode 100644 index 000000000..c57a47092 --- /dev/null +++ b/docs/GroupLDAPSourceConnection.md @@ -0,0 +1,37 @@ +# GroupLDAPSourceConnection + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**group** | **UUID** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] +**group_obj** | [**PartialGroup**](PartialGroup.md) | | [readonly] + +## Example + +```python +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupLDAPSourceConnection from a JSON string +group_ldap_source_connection_instance = GroupLDAPSourceConnection.from_json(json) +# print the JSON string representation of the object +print(GroupLDAPSourceConnection.to_json()) + +# convert the object into a dict +group_ldap_source_connection_dict = group_ldap_source_connection_instance.to_dict() +# create an instance of GroupLDAPSourceConnection from a dict +group_ldap_source_connection_from_dict = GroupLDAPSourceConnection.from_dict(group_ldap_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupLDAPSourceConnectionRequest.md b/docs/GroupLDAPSourceConnectionRequest.md new file mode 100644 index 000000000..2c670d584 --- /dev/null +++ b/docs/GroupLDAPSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# GroupLDAPSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.group_ldap_source_connection_request import GroupLDAPSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupLDAPSourceConnectionRequest from a JSON string +group_ldap_source_connection_request_instance = GroupLDAPSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(GroupLDAPSourceConnectionRequest.to_json()) + +# convert the object into a dict +group_ldap_source_connection_request_dict = group_ldap_source_connection_request_instance.to_dict() +# create an instance of GroupLDAPSourceConnectionRequest from a dict +group_ldap_source_connection_request_from_dict = GroupLDAPSourceConnectionRequest.from_dict(group_ldap_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupMatchingModeEnum.md b/docs/GroupMatchingModeEnum.md new file mode 100644 index 000000000..8e377c449 --- /dev/null +++ b/docs/GroupMatchingModeEnum.md @@ -0,0 +1,14 @@ +# GroupMatchingModeEnum + + +## Enum + +* `IDENTIFIER` (value: `'identifier'`) + +* `NAME_LINK` (value: `'name_link'`) + +* `NAME_DENY` (value: `'name_deny'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupOAuthSourceConnection.md b/docs/GroupOAuthSourceConnection.md new file mode 100644 index 000000000..ae3508b91 --- /dev/null +++ b/docs/GroupOAuthSourceConnection.md @@ -0,0 +1,36 @@ +# GroupOAuthSourceConnection + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**group** | **UUID** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupOAuthSourceConnection from a JSON string +group_o_auth_source_connection_instance = GroupOAuthSourceConnection.from_json(json) +# print the JSON string representation of the object +print(GroupOAuthSourceConnection.to_json()) + +# convert the object into a dict +group_o_auth_source_connection_dict = group_o_auth_source_connection_instance.to_dict() +# create an instance of GroupOAuthSourceConnection from a dict +group_o_auth_source_connection_from_dict = GroupOAuthSourceConnection.from_dict(group_o_auth_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupOAuthSourceConnectionRequest.md b/docs/GroupOAuthSourceConnectionRequest.md new file mode 100644 index 000000000..b89411c0f --- /dev/null +++ b/docs/GroupOAuthSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# GroupOAuthSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.group_o_auth_source_connection_request import GroupOAuthSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupOAuthSourceConnectionRequest from a JSON string +group_o_auth_source_connection_request_instance = GroupOAuthSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(GroupOAuthSourceConnectionRequest.to_json()) + +# convert the object into a dict +group_o_auth_source_connection_request_dict = group_o_auth_source_connection_request_instance.to_dict() +# create an instance of GroupOAuthSourceConnectionRequest from a dict +group_o_auth_source_connection_request_from_dict = GroupOAuthSourceConnectionRequest.from_dict(group_o_auth_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupPlexSourceConnection.md b/docs/GroupPlexSourceConnection.md new file mode 100644 index 000000000..72efb8229 --- /dev/null +++ b/docs/GroupPlexSourceConnection.md @@ -0,0 +1,36 @@ +# GroupPlexSourceConnection + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**group** | **UUID** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupPlexSourceConnection from a JSON string +group_plex_source_connection_instance = GroupPlexSourceConnection.from_json(json) +# print the JSON string representation of the object +print(GroupPlexSourceConnection.to_json()) + +# convert the object into a dict +group_plex_source_connection_dict = group_plex_source_connection_instance.to_dict() +# create an instance of GroupPlexSourceConnection from a dict +group_plex_source_connection_from_dict = GroupPlexSourceConnection.from_dict(group_plex_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupPlexSourceConnectionRequest.md b/docs/GroupPlexSourceConnectionRequest.md new file mode 100644 index 000000000..a50e69ef4 --- /dev/null +++ b/docs/GroupPlexSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# GroupPlexSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.group_plex_source_connection_request import GroupPlexSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupPlexSourceConnectionRequest from a JSON string +group_plex_source_connection_request_instance = GroupPlexSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(GroupPlexSourceConnectionRequest.to_json()) + +# convert the object into a dict +group_plex_source_connection_request_dict = group_plex_source_connection_request_instance.to_dict() +# create an instance of GroupPlexSourceConnectionRequest from a dict +group_plex_source_connection_request_from_dict = GroupPlexSourceConnectionRequest.from_dict(group_plex_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupRequest.md b/docs/GroupRequest.md new file mode 100644 index 000000000..e717d194f --- /dev/null +++ b/docs/GroupRequest.md @@ -0,0 +1,35 @@ +# GroupRequest + +Group Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**is_superuser** | **bool** | Users added to this group will be superusers. | [optional] +**parents** | **List[UUID]** | | [optional] +**users** | **List[int]** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] +**roles** | **List[UUID]** | | [optional] + +## Example + +```python +from authentik_client.models.group_request import GroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupRequest from a JSON string +group_request_instance = GroupRequest.from_json(json) +# print the JSON string representation of the object +print(GroupRequest.to_json()) + +# convert the object into a dict +group_request_dict = group_request_instance.to_dict() +# create an instance of GroupRequest from a dict +group_request_from_dict = GroupRequest.from_dict(group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupSAMLSourceConnection.md b/docs/GroupSAMLSourceConnection.md new file mode 100644 index 000000000..1b6132341 --- /dev/null +++ b/docs/GroupSAMLSourceConnection.md @@ -0,0 +1,36 @@ +# GroupSAMLSourceConnection + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**group** | **UUID** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupSAMLSourceConnection from a JSON string +group_saml_source_connection_instance = GroupSAMLSourceConnection.from_json(json) +# print the JSON string representation of the object +print(GroupSAMLSourceConnection.to_json()) + +# convert the object into a dict +group_saml_source_connection_dict = group_saml_source_connection_instance.to_dict() +# create an instance of GroupSAMLSourceConnection from a dict +group_saml_source_connection_from_dict = GroupSAMLSourceConnection.from_dict(group_saml_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupSAMLSourceConnectionRequest.md b/docs/GroupSAMLSourceConnectionRequest.md new file mode 100644 index 000000000..b09541cd0 --- /dev/null +++ b/docs/GroupSAMLSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# GroupSAMLSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.group_saml_source_connection_request import GroupSAMLSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupSAMLSourceConnectionRequest from a JSON string +group_saml_source_connection_request_instance = GroupSAMLSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(GroupSAMLSourceConnectionRequest.to_json()) + +# convert the object into a dict +group_saml_source_connection_request_dict = group_saml_source_connection_request_instance.to_dict() +# create an instance of GroupSAMLSourceConnectionRequest from a dict +group_saml_source_connection_request_from_dict = GroupSAMLSourceConnectionRequest.from_dict(group_saml_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupSourceConnection.md b/docs/GroupSourceConnection.md new file mode 100644 index 000000000..ffe96e856 --- /dev/null +++ b/docs/GroupSourceConnection.md @@ -0,0 +1,36 @@ +# GroupSourceConnection + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**group** | **UUID** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.group_source_connection import GroupSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupSourceConnection from a JSON string +group_source_connection_instance = GroupSourceConnection.from_json(json) +# print the JSON string representation of the object +print(GroupSourceConnection.to_json()) + +# convert the object into a dict +group_source_connection_dict = group_source_connection_instance.to_dict() +# create an instance of GroupSourceConnection from a dict +group_source_connection_from_dict = GroupSourceConnection.from_dict(group_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupSourceConnectionRequest.md b/docs/GroupSourceConnectionRequest.md new file mode 100644 index 000000000..13dc957e1 --- /dev/null +++ b/docs/GroupSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# GroupSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.group_source_connection_request import GroupSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupSourceConnectionRequest from a JSON string +group_source_connection_request_instance = GroupSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(GroupSourceConnectionRequest.to_json()) + +# convert the object into a dict +group_source_connection_request_dict = group_source_connection_request_instance.to_dict() +# create an instance of GroupSourceConnectionRequest from a dict +group_source_connection_request_from_dict = GroupSourceConnectionRequest.from_dict(group_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupTelegramSourceConnection.md b/docs/GroupTelegramSourceConnection.md new file mode 100644 index 000000000..e66a97e2c --- /dev/null +++ b/docs/GroupTelegramSourceConnection.md @@ -0,0 +1,36 @@ +# GroupTelegramSourceConnection + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**group** | **UUID** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupTelegramSourceConnection from a JSON string +group_telegram_source_connection_instance = GroupTelegramSourceConnection.from_json(json) +# print the JSON string representation of the object +print(GroupTelegramSourceConnection.to_json()) + +# convert the object into a dict +group_telegram_source_connection_dict = group_telegram_source_connection_instance.to_dict() +# create an instance of GroupTelegramSourceConnection from a dict +group_telegram_source_connection_from_dict = GroupTelegramSourceConnection.from_dict(group_telegram_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GroupTelegramSourceConnectionRequest.md b/docs/GroupTelegramSourceConnectionRequest.md new file mode 100644 index 000000000..118972941 --- /dev/null +++ b/docs/GroupTelegramSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# GroupTelegramSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.group_telegram_source_connection_request import GroupTelegramSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of GroupTelegramSourceConnectionRequest from a JSON string +group_telegram_source_connection_request_instance = GroupTelegramSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(GroupTelegramSourceConnectionRequest.to_json()) + +# convert the object into a dict +group_telegram_source_connection_request_dict = group_telegram_source_connection_request_instance.to_dict() +# create an instance of GroupTelegramSourceConnectionRequest from a dict +group_telegram_source_connection_request_from_dict = GroupTelegramSourceConnectionRequest.from_dict(group_telegram_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Hardware.md b/docs/Hardware.md new file mode 100644 index 000000000..49e0c5ea2 --- /dev/null +++ b/docs/Hardware.md @@ -0,0 +1,34 @@ +# Hardware + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**model** | **str** | | [optional] +**manufacturer** | **str** | | [optional] +**serial** | **str** | | +**cpu_name** | **str** | | [optional] +**cpu_count** | **int** | | [optional] +**memory_bytes** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.hardware import Hardware + +# TODO update the JSON string below +json = "{}" +# create an instance of Hardware from a JSON string +hardware_instance = Hardware.from_json(json) +# print the JSON string representation of the object +print(Hardware.to_json()) + +# convert the object into a dict +hardware_dict = hardware_instance.to_dict() +# create an instance of Hardware from a dict +hardware_from_dict = Hardware.from_dict(hardware_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/HardwareRequest.md b/docs/HardwareRequest.md new file mode 100644 index 000000000..714d6cffe --- /dev/null +++ b/docs/HardwareRequest.md @@ -0,0 +1,34 @@ +# HardwareRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**model** | **str** | | [optional] +**manufacturer** | **str** | | [optional] +**serial** | **str** | | +**cpu_name** | **str** | | [optional] +**cpu_count** | **int** | | [optional] +**memory_bytes** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.hardware_request import HardwareRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of HardwareRequest from a JSON string +hardware_request_instance = HardwareRequest.from_json(json) +# print the JSON string representation of the object +print(HardwareRequest.to_json()) + +# convert the object into a dict +hardware_request_dict = hardware_request_instance.to_dict() +# create an instance of HardwareRequest from a dict +hardware_request_from_dict = HardwareRequest.from_dict(hardware_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/IdentificationChallenge.md b/docs/IdentificationChallenge.md new file mode 100644 index 000000000..523c03144 --- /dev/null +++ b/docs/IdentificationChallenge.md @@ -0,0 +1,48 @@ +# IdentificationChallenge + +Identification challenges with all UI elements + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-identification'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**user_fields** | **List[str]** | | +**pending_user_identifier** | **str** | | [optional] +**password_fields** | **bool** | | +**allow_show_password** | **bool** | | [optional] [default to False] +**application_pre** | **str** | | [optional] +**application_pre_launch** | **str** | | [optional] +**flow_designation** | [**FlowDesignationEnum**](FlowDesignationEnum.md) | | +**captcha_stage** | [**CaptchaChallenge**](CaptchaChallenge.md) | | [optional] +**enroll_url** | **str** | | [optional] +**recovery_url** | **str** | | [optional] +**passwordless_url** | **str** | | [optional] +**primary_action** | **str** | | +**sources** | [**List[LoginSource]**](LoginSource.md) | | [optional] +**show_source_labels** | **bool** | | +**enable_remember_me** | **bool** | | [optional] [default to True] +**passkey_challenge** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.identification_challenge import IdentificationChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of IdentificationChallenge from a JSON string +identification_challenge_instance = IdentificationChallenge.from_json(json) +# print the JSON string representation of the object +print(IdentificationChallenge.to_json()) + +# convert the object into a dict +identification_challenge_dict = identification_challenge_instance.to_dict() +# create an instance of IdentificationChallenge from a dict +identification_challenge_from_dict = IdentificationChallenge.from_dict(identification_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/IdentificationChallengeResponseRequest.md b/docs/IdentificationChallengeResponseRequest.md new file mode 100644 index 000000000..707da1ff9 --- /dev/null +++ b/docs/IdentificationChallengeResponseRequest.md @@ -0,0 +1,34 @@ +# IdentificationChallengeResponseRequest + +Identification challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-identification'] +**uid_field** | **str** | | [optional] +**password** | **str** | | [optional] +**captcha_token** | **str** | | [optional] +**passkey** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.identification_challenge_response_request import IdentificationChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of IdentificationChallengeResponseRequest from a JSON string +identification_challenge_response_request_instance = IdentificationChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(IdentificationChallengeResponseRequest.to_json()) + +# convert the object into a dict +identification_challenge_response_request_dict = identification_challenge_response_request_instance.to_dict() +# create an instance of IdentificationChallengeResponseRequest from a dict +identification_challenge_response_request_from_dict = IdentificationChallengeResponseRequest.from_dict(identification_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/IdentificationStage.md b/docs/IdentificationStage.md new file mode 100644 index 000000000..c39360205 --- /dev/null +++ b/docs/IdentificationStage.md @@ -0,0 +1,49 @@ +# IdentificationStage + +IdentificationStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**user_fields** | [**List[UserFieldsEnum]**](UserFieldsEnum.md) | Fields of the user object to match against. (Hold shift to select multiple options) | [optional] +**password_stage** | **UUID** | When set, shows a password field, instead of showing the password field as separate step. | [optional] +**captcha_stage** | **UUID** | When set, adds functionality exactly like a Captcha stage, but baked into the Identification stage. | [optional] +**case_insensitive_matching** | **bool** | When enabled, user fields are matched regardless of their casing. | [optional] +**show_matched_user** | **bool** | When a valid username/email has been entered, and this option is enabled, the user's username and avatar will be shown. Otherwise, the text that the user entered will be shown | [optional] +**enrollment_flow** | **UUID** | Optional enrollment flow, which is linked at the bottom of the page. | [optional] +**recovery_flow** | **UUID** | Optional recovery flow, which is linked at the bottom of the page. | [optional] +**passwordless_flow** | **UUID** | Optional passwordless flow, which is linked at the bottom of the page. | [optional] +**sources** | **List[UUID]** | Specify which sources should be shown. | [optional] +**show_source_labels** | **bool** | | [optional] +**pretend_user_exists** | **bool** | When enabled, the stage will succeed and continue even when incorrect user info is entered. | [optional] +**enable_remember_me** | **bool** | Show the user the 'Remember me on this device' toggle, allowing repeat users to skip straight to entering their password. | [optional] +**webauthn_stage** | **UUID** | When set, and conditional WebAuthn is available, allow the user to use their passkey as a first factor. | [optional] + +## Example + +```python +from authentik_client.models.identification_stage import IdentificationStage + +# TODO update the JSON string below +json = "{}" +# create an instance of IdentificationStage from a JSON string +identification_stage_instance = IdentificationStage.from_json(json) +# print the JSON string representation of the object +print(IdentificationStage.to_json()) + +# convert the object into a dict +identification_stage_dict = identification_stage_instance.to_dict() +# create an instance of IdentificationStage from a dict +identification_stage_from_dict = IdentificationStage.from_dict(identification_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/IdentificationStageRequest.md b/docs/IdentificationStageRequest.md new file mode 100644 index 000000000..eb360bab7 --- /dev/null +++ b/docs/IdentificationStageRequest.md @@ -0,0 +1,43 @@ +# IdentificationStageRequest + +IdentificationStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**user_fields** | [**List[UserFieldsEnum]**](UserFieldsEnum.md) | Fields of the user object to match against. (Hold shift to select multiple options) | [optional] +**password_stage** | **UUID** | When set, shows a password field, instead of showing the password field as separate step. | [optional] +**captcha_stage** | **UUID** | When set, adds functionality exactly like a Captcha stage, but baked into the Identification stage. | [optional] +**case_insensitive_matching** | **bool** | When enabled, user fields are matched regardless of their casing. | [optional] +**show_matched_user** | **bool** | When a valid username/email has been entered, and this option is enabled, the user's username and avatar will be shown. Otherwise, the text that the user entered will be shown | [optional] +**enrollment_flow** | **UUID** | Optional enrollment flow, which is linked at the bottom of the page. | [optional] +**recovery_flow** | **UUID** | Optional recovery flow, which is linked at the bottom of the page. | [optional] +**passwordless_flow** | **UUID** | Optional passwordless flow, which is linked at the bottom of the page. | [optional] +**sources** | **List[UUID]** | Specify which sources should be shown. | [optional] +**show_source_labels** | **bool** | | [optional] +**pretend_user_exists** | **bool** | When enabled, the stage will succeed and continue even when incorrect user info is entered. | [optional] +**enable_remember_me** | **bool** | Show the user the 'Remember me on this device' toggle, allowing repeat users to skip straight to entering their password. | [optional] +**webauthn_stage** | **UUID** | When set, and conditional WebAuthn is available, allow the user to use their passkey as a first factor. | [optional] + +## Example + +```python +from authentik_client.models.identification_stage_request import IdentificationStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of IdentificationStageRequest from a JSON string +identification_stage_request_instance = IdentificationStageRequest.from_json(json) +# print the JSON string representation of the object +print(IdentificationStageRequest.to_json()) + +# convert the object into a dict +identification_stage_request_dict = identification_stage_request_instance.to_dict() +# create an instance of IdentificationStageRequest from a dict +identification_stage_request_from_dict = IdentificationStageRequest.from_dict(identification_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/IframeLogoutChallenge.md b/docs/IframeLogoutChallenge.md new file mode 100644 index 000000000..3a298d884 --- /dev/null +++ b/docs/IframeLogoutChallenge.md @@ -0,0 +1,33 @@ +# IframeLogoutChallenge + +Challenge for iframe logout + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-provider-iframe-logout'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**logout_urls** | [**List[LogoutURL]**](LogoutURL.md) | | [optional] + +## Example + +```python +from authentik_client.models.iframe_logout_challenge import IframeLogoutChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of IframeLogoutChallenge from a JSON string +iframe_logout_challenge_instance = IframeLogoutChallenge.from_json(json) +# print the JSON string representation of the object +print(IframeLogoutChallenge.to_json()) + +# convert the object into a dict +iframe_logout_challenge_dict = iframe_logout_challenge_instance.to_dict() +# create an instance of IframeLogoutChallenge from a dict +iframe_logout_challenge_from_dict = IframeLogoutChallenge.from_dict(iframe_logout_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/IframeLogoutChallengeResponseRequest.md b/docs/IframeLogoutChallengeResponseRequest.md new file mode 100644 index 000000000..010434795 --- /dev/null +++ b/docs/IframeLogoutChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# IframeLogoutChallengeResponseRequest + +Response for iframe logout + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-provider-iframe-logout'] + +## Example + +```python +from authentik_client.models.iframe_logout_challenge_response_request import IframeLogoutChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of IframeLogoutChallengeResponseRequest from a JSON string +iframe_logout_challenge_response_request_instance = IframeLogoutChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(IframeLogoutChallengeResponseRequest.to_json()) + +# convert the object into a dict +iframe_logout_challenge_response_request_dict = iframe_logout_challenge_response_request_instance.to_dict() +# create an instance of IframeLogoutChallengeResponseRequest from a dict +iframe_logout_challenge_response_request_from_dict = IframeLogoutChallengeResponseRequest.from_dict(iframe_logout_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ImpersonationRequest.md b/docs/ImpersonationRequest.md new file mode 100644 index 000000000..4773a0e1c --- /dev/null +++ b/docs/ImpersonationRequest.md @@ -0,0 +1,29 @@ +# ImpersonationRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**reason** | **str** | | + +## Example + +```python +from authentik_client.models.impersonation_request import ImpersonationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ImpersonationRequest from a JSON string +impersonation_request_instance = ImpersonationRequest.from_json(json) +# print the JSON string representation of the object +print(ImpersonationRequest.to_json()) + +# convert the object into a dict +impersonation_request_dict = impersonation_request_instance.to_dict() +# create an instance of ImpersonationRequest from a dict +impersonation_request_from_dict = ImpersonationRequest.from_dict(impersonation_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/InitialPermissions.md b/docs/InitialPermissions.md new file mode 100644 index 000000000..bb28ced3d --- /dev/null +++ b/docs/InitialPermissions.md @@ -0,0 +1,34 @@ +# InitialPermissions + +InitialPermissions serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**role** | **UUID** | | +**permissions** | **List[int]** | | [optional] +**permissions_obj** | [**List[Permission]**](Permission.md) | | [readonly] + +## Example + +```python +from authentik_client.models.initial_permissions import InitialPermissions + +# TODO update the JSON string below +json = "{}" +# create an instance of InitialPermissions from a JSON string +initial_permissions_instance = InitialPermissions.from_json(json) +# print the JSON string representation of the object +print(InitialPermissions.to_json()) + +# convert the object into a dict +initial_permissions_dict = initial_permissions_instance.to_dict() +# create an instance of InitialPermissions from a dict +initial_permissions_from_dict = InitialPermissions.from_dict(initial_permissions_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/InitialPermissionsRequest.md b/docs/InitialPermissionsRequest.md new file mode 100644 index 000000000..aef777cbe --- /dev/null +++ b/docs/InitialPermissionsRequest.md @@ -0,0 +1,32 @@ +# InitialPermissionsRequest + +InitialPermissions serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**role** | **UUID** | | +**permissions** | **List[int]** | | [optional] + +## Example + +```python +from authentik_client.models.initial_permissions_request import InitialPermissionsRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of InitialPermissionsRequest from a JSON string +initial_permissions_request_instance = InitialPermissionsRequest.from_json(json) +# print the JSON string representation of the object +print(InitialPermissionsRequest.to_json()) + +# convert the object into a dict +initial_permissions_request_dict = initial_permissions_request_instance.to_dict() +# create an instance of InitialPermissionsRequest from a dict +initial_permissions_request_from_dict = InitialPermissionsRequest.from_dict(initial_permissions_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/InstallID.md b/docs/InstallID.md new file mode 100644 index 000000000..c94178ed2 --- /dev/null +++ b/docs/InstallID.md @@ -0,0 +1,29 @@ +# InstallID + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**install_id** | **str** | | + +## Example + +```python +from authentik_client.models.install_id import InstallID + +# TODO update the JSON string below +json = "{}" +# create an instance of InstallID from a JSON string +install_id_instance = InstallID.from_json(json) +# print the JSON string representation of the object +print(InstallID.to_json()) + +# convert the object into a dict +install_id_dict = install_id_instance.to_dict() +# create an instance of InstallID from a dict +install_id_from_dict = InstallID.from_dict(install_id_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/IntentEnum.md b/docs/IntentEnum.md new file mode 100644 index 000000000..13fce95c6 --- /dev/null +++ b/docs/IntentEnum.md @@ -0,0 +1,16 @@ +# IntentEnum + + +## Enum + +* `VERIFICATION` (value: `'verification'`) + +* `API` (value: `'api'`) + +* `RECOVERY` (value: `'recovery'`) + +* `APP_PASSWORD` (value: `'app_password'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/InvalidResponseActionEnum.md b/docs/InvalidResponseActionEnum.md new file mode 100644 index 000000000..d7838ca23 --- /dev/null +++ b/docs/InvalidResponseActionEnum.md @@ -0,0 +1,14 @@ +# InvalidResponseActionEnum + + +## Enum + +* `RETRY` (value: `'retry'`) + +* `RESTART` (value: `'restart'`) + +* `RESTART_WITH_CONTEXT` (value: `'restart_with_context'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Invitation.md b/docs/Invitation.md new file mode 100644 index 000000000..df0c6b23e --- /dev/null +++ b/docs/Invitation.md @@ -0,0 +1,37 @@ +# Invitation + +Invitation Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**expires** | **datetime** | | [optional] +**fixed_data** | **Dict[str, object]** | | [optional] +**created_by** | [**PartialUser**](PartialUser.md) | | [readonly] +**single_use** | **bool** | When enabled, the invitation will be deleted after usage. | [optional] +**flow** | **UUID** | When set, only the configured flow can use this invitation. | [optional] +**flow_obj** | [**Flow**](Flow.md) | | [readonly] + +## Example + +```python +from authentik_client.models.invitation import Invitation + +# TODO update the JSON string below +json = "{}" +# create an instance of Invitation from a JSON string +invitation_instance = Invitation.from_json(json) +# print the JSON string representation of the object +print(Invitation.to_json()) + +# convert the object into a dict +invitation_dict = invitation_instance.to_dict() +# create an instance of Invitation from a dict +invitation_from_dict = Invitation.from_dict(invitation_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/InvitationRequest.md b/docs/InvitationRequest.md new file mode 100644 index 000000000..456e0283e --- /dev/null +++ b/docs/InvitationRequest.md @@ -0,0 +1,34 @@ +# InvitationRequest + +Invitation Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**expires** | **datetime** | | [optional] +**fixed_data** | **Dict[str, object]** | | [optional] +**single_use** | **bool** | When enabled, the invitation will be deleted after usage. | [optional] +**flow** | **UUID** | When set, only the configured flow can use this invitation. | [optional] + +## Example + +```python +from authentik_client.models.invitation_request import InvitationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of InvitationRequest from a JSON string +invitation_request_instance = InvitationRequest.from_json(json) +# print the JSON string representation of the object +print(InvitationRequest.to_json()) + +# convert the object into a dict +invitation_request_dict = invitation_request_instance.to_dict() +# create an instance of InvitationRequest from a dict +invitation_request_from_dict = InvitationRequest.from_dict(invitation_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/InvitationSendEmailRequest.md b/docs/InvitationSendEmailRequest.md new file mode 100644 index 000000000..8e1e9723a --- /dev/null +++ b/docs/InvitationSendEmailRequest.md @@ -0,0 +1,33 @@ +# InvitationSendEmailRequest + +Serializer for sending invitation emails + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**email_addresses** | **List[object]** | | +**cc_addresses** | **List[object]** | | [optional] +**bcc_addresses** | **List[object]** | | [optional] +**template** | **str** | | [optional] [default to 'invitation'] + +## Example + +```python +from authentik_client.models.invitation_send_email_request import InvitationSendEmailRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of InvitationSendEmailRequest from a JSON string +invitation_send_email_request_instance = InvitationSendEmailRequest.from_json(json) +# print the JSON string representation of the object +print(InvitationSendEmailRequest.to_json()) + +# convert the object into a dict +invitation_send_email_request_dict = invitation_send_email_request_instance.to_dict() +# create an instance of InvitationSendEmailRequest from a dict +invitation_send_email_request_from_dict = InvitationSendEmailRequest.from_dict(invitation_send_email_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/InvitationStage.md b/docs/InvitationStage.md new file mode 100644 index 000000000..c2e695678 --- /dev/null +++ b/docs/InvitationStage.md @@ -0,0 +1,37 @@ +# InvitationStage + +InvitationStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**continue_flow_without_invitation** | **bool** | If this flag is set, this Stage will jump to the next Stage when no Invitation is given. By default this Stage will cancel the Flow when no invitation is given. | [optional] + +## Example + +```python +from authentik_client.models.invitation_stage import InvitationStage + +# TODO update the JSON string below +json = "{}" +# create an instance of InvitationStage from a JSON string +invitation_stage_instance = InvitationStage.from_json(json) +# print the JSON string representation of the object +print(InvitationStage.to_json()) + +# convert the object into a dict +invitation_stage_dict = invitation_stage_instance.to_dict() +# create an instance of InvitationStage from a dict +invitation_stage_from_dict = InvitationStage.from_dict(invitation_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/InvitationStageRequest.md b/docs/InvitationStageRequest.md new file mode 100644 index 000000000..f7421cd76 --- /dev/null +++ b/docs/InvitationStageRequest.md @@ -0,0 +1,31 @@ +# InvitationStageRequest + +InvitationStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**continue_flow_without_invitation** | **bool** | If this flag is set, this Stage will jump to the next Stage when no Invitation is given. By default this Stage will cancel the Flow when no invitation is given. | [optional] + +## Example + +```python +from authentik_client.models.invitation_stage_request import InvitationStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of InvitationStageRequest from a JSON string +invitation_stage_request_instance = InvitationStageRequest.from_json(json) +# print the JSON string representation of the object +print(InvitationStageRequest.to_json()) + +# convert the object into a dict +invitation_stage_request_dict = invitation_stage_request_instance.to_dict() +# create an instance of InvitationStageRequest from a dict +invitation_stage_request_from_dict = InvitationStageRequest.from_dict(invitation_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/IssuerModeEnum.md b/docs/IssuerModeEnum.md new file mode 100644 index 000000000..09d4eb4ea --- /dev/null +++ b/docs/IssuerModeEnum.md @@ -0,0 +1,12 @@ +# IssuerModeEnum + + +## Enum + +* `GLOBAL` (value: `'global'`) + +* `PER_PROVIDER` (value: `'per_provider'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/KadminTypeEnum.md b/docs/KadminTypeEnum.md new file mode 100644 index 000000000..e92cd2919 --- /dev/null +++ b/docs/KadminTypeEnum.md @@ -0,0 +1,12 @@ +# KadminTypeEnum + + +## Enum + +* `MIT` (value: `'MIT'`) + +* `HEIMDAL` (value: `'Heimdal'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/KerberosSource.md b/docs/KerberosSource.md new file mode 100644 index 000000000..49814bfee --- /dev/null +++ b/docs/KerberosSource.md @@ -0,0 +1,60 @@ +# KerberosSource + +Kerberos Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [readonly] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**icon_url** | **str** | | [readonly] +**icon_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**realm** | **str** | Kerberos realm | +**krb5_conf** | **str** | Custom krb5.conf to use. Uses the system one by default | [optional] +**kadmin_type** | [**KadminTypeEnum**](KadminTypeEnum.md) | KAdmin server type | [optional] +**sync_users** | **bool** | Sync users from Kerberos into authentik | [optional] +**sync_users_password** | **bool** | When a user changes their password, sync it back to Kerberos | [optional] +**sync_principal** | **str** | Principal to authenticate to kadmin for sync. | [optional] +**connectivity** | **Dict[str, str]** | Get cached source connectivity | [readonly] +**spnego_server_name** | **str** | Force the use of a specific server name for SPNEGO. Must be in the form HTTP@hostname | [optional] +**password_login_update_internal_password** | **bool** | If enabled, the authentik-stored password will be updated upon login with the Kerberos password backend | [optional] +**sync_outgoing_trigger_mode** | [**SyncOutgoingTriggerModeEnum**](SyncOutgoingTriggerModeEnum.md) | When to trigger sync for outgoing providers | [optional] + +## Example + +```python +from authentik_client.models.kerberos_source import KerberosSource + +# TODO update the JSON string below +json = "{}" +# create an instance of KerberosSource from a JSON string +kerberos_source_instance = KerberosSource.from_json(json) +# print the JSON string representation of the object +print(KerberosSource.to_json()) + +# convert the object into a dict +kerberos_source_dict = kerberos_source_instance.to_dict() +# create an instance of KerberosSource from a dict +kerberos_source_from_dict = KerberosSource.from_dict(kerberos_source_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/KerberosSourcePropertyMapping.md b/docs/KerberosSourcePropertyMapping.md new file mode 100644 index 000000000..01449885f --- /dev/null +++ b/docs/KerberosSourcePropertyMapping.md @@ -0,0 +1,37 @@ +# KerberosSourcePropertyMapping + +Kerberos PropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of KerberosSourcePropertyMapping from a JSON string +kerberos_source_property_mapping_instance = KerberosSourcePropertyMapping.from_json(json) +# print the JSON string representation of the object +print(KerberosSourcePropertyMapping.to_json()) + +# convert the object into a dict +kerberos_source_property_mapping_dict = kerberos_source_property_mapping_instance.to_dict() +# create an instance of KerberosSourcePropertyMapping from a dict +kerberos_source_property_mapping_from_dict = KerberosSourcePropertyMapping.from_dict(kerberos_source_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/KerberosSourcePropertyMappingRequest.md b/docs/KerberosSourcePropertyMappingRequest.md new file mode 100644 index 000000000..43c7f6b07 --- /dev/null +++ b/docs/KerberosSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# KerberosSourcePropertyMappingRequest + +Kerberos PropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.kerberos_source_property_mapping_request import KerberosSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of KerberosSourcePropertyMappingRequest from a JSON string +kerberos_source_property_mapping_request_instance = KerberosSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(KerberosSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +kerberos_source_property_mapping_request_dict = kerberos_source_property_mapping_request_instance.to_dict() +# create an instance of KerberosSourcePropertyMappingRequest from a dict +kerberos_source_property_mapping_request_from_dict = KerberosSourcePropertyMappingRequest.from_dict(kerberos_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/KerberosSourceRequest.md b/docs/KerberosSourceRequest.md new file mode 100644 index 000000000..45bf3f571 --- /dev/null +++ b/docs/KerberosSourceRequest.md @@ -0,0 +1,56 @@ +# KerberosSourceRequest + +Kerberos Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**realm** | **str** | Kerberos realm | +**krb5_conf** | **str** | Custom krb5.conf to use. Uses the system one by default | [optional] +**kadmin_type** | [**KadminTypeEnum**](KadminTypeEnum.md) | KAdmin server type | [optional] +**sync_users** | **bool** | Sync users from Kerberos into authentik | [optional] +**sync_users_password** | **bool** | When a user changes their password, sync it back to Kerberos | [optional] +**sync_principal** | **str** | Principal to authenticate to kadmin for sync. | [optional] +**sync_password** | **str** | Password to authenticate to kadmin for sync | [optional] +**sync_keytab** | **str** | Keytab to authenticate to kadmin for sync. Must be base64-encoded or in the form TYPE:residual | [optional] +**sync_ccache** | **str** | Credentials cache to authenticate to kadmin for sync. Must be in the form TYPE:residual | [optional] +**spnego_server_name** | **str** | Force the use of a specific server name for SPNEGO. Must be in the form HTTP@hostname | [optional] +**spnego_keytab** | **str** | SPNEGO keytab base64-encoded or path to keytab in the form FILE:path | [optional] +**spnego_ccache** | **str** | Credential cache to use for SPNEGO in form type:residual | [optional] +**password_login_update_internal_password** | **bool** | If enabled, the authentik-stored password will be updated upon login with the Kerberos password backend | [optional] +**sync_outgoing_trigger_mode** | [**SyncOutgoingTriggerModeEnum**](SyncOutgoingTriggerModeEnum.md) | When to trigger sync for outgoing providers | [optional] + +## Example + +```python +from authentik_client.models.kerberos_source_request import KerberosSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of KerberosSourceRequest from a JSON string +kerberos_source_request_instance = KerberosSourceRequest.from_json(json) +# print the JSON string representation of the object +print(KerberosSourceRequest.to_json()) + +# convert the object into a dict +kerberos_source_request_dict = kerberos_source_request_instance.to_dict() +# create an instance of KerberosSourceRequest from a dict +kerberos_source_request_from_dict = KerberosSourceRequest.from_dict(kerberos_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/KeyTypeEnum.md b/docs/KeyTypeEnum.md new file mode 100644 index 000000000..3b44814d8 --- /dev/null +++ b/docs/KeyTypeEnum.md @@ -0,0 +1,18 @@ +# KeyTypeEnum + + +## Enum + +* `DSA` (value: `'dsa'`) + +* `EC` (value: `'ec'`) + +* `ED25519` (value: `'ed25519'`) + +* `ED448` (value: `'ed448'`) + +* `RSA` (value: `'rsa'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/KubernetesServiceConnection.md b/docs/KubernetesServiceConnection.md new file mode 100644 index 000000000..14f6460d1 --- /dev/null +++ b/docs/KubernetesServiceConnection.md @@ -0,0 +1,38 @@ +# KubernetesServiceConnection + +KubernetesServiceConnection Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**local** | **bool** | If enabled, use the local connection. Required Docker socket/Kubernetes Integration | [optional] +**component** | **str** | | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**kubeconfig** | **Dict[str, object]** | Paste your kubeconfig here. authentik will automatically use the currently selected context. | [optional] +**verify_ssl** | **bool** | Verify SSL Certificates of the Kubernetes API endpoint | [optional] + +## Example + +```python +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of KubernetesServiceConnection from a JSON string +kubernetes_service_connection_instance = KubernetesServiceConnection.from_json(json) +# print the JSON string representation of the object +print(KubernetesServiceConnection.to_json()) + +# convert the object into a dict +kubernetes_service_connection_dict = kubernetes_service_connection_instance.to_dict() +# create an instance of KubernetesServiceConnection from a dict +kubernetes_service_connection_from_dict = KubernetesServiceConnection.from_dict(kubernetes_service_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/KubernetesServiceConnectionRequest.md b/docs/KubernetesServiceConnectionRequest.md new file mode 100644 index 000000000..fcaadad55 --- /dev/null +++ b/docs/KubernetesServiceConnectionRequest.md @@ -0,0 +1,33 @@ +# KubernetesServiceConnectionRequest + +KubernetesServiceConnection Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**local** | **bool** | If enabled, use the local connection. Required Docker socket/Kubernetes Integration | [optional] +**kubeconfig** | **Dict[str, object]** | Paste your kubeconfig here. authentik will automatically use the currently selected context. | [optional] +**verify_ssl** | **bool** | Verify SSL Certificates of the Kubernetes API endpoint | [optional] + +## Example + +```python +from authentik_client.models.kubernetes_service_connection_request import KubernetesServiceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of KubernetesServiceConnectionRequest from a JSON string +kubernetes_service_connection_request_instance = KubernetesServiceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(KubernetesServiceConnectionRequest.to_json()) + +# convert the object into a dict +kubernetes_service_connection_request_dict = kubernetes_service_connection_request_instance.to_dict() +# create an instance of KubernetesServiceConnectionRequest from a dict +kubernetes_service_connection_request_from_dict = KubernetesServiceConnectionRequest.from_dict(kubernetes_service_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPAPIAccessMode.md b/docs/LDAPAPIAccessMode.md new file mode 100644 index 000000000..993211e09 --- /dev/null +++ b/docs/LDAPAPIAccessMode.md @@ -0,0 +1,12 @@ +# LDAPAPIAccessMode + + +## Enum + +* `DIRECT` (value: `'direct'`) + +* `CACHED` (value: `'cached'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPCheckAccess.md b/docs/LDAPCheckAccess.md new file mode 100644 index 000000000..402ecf4cf --- /dev/null +++ b/docs/LDAPCheckAccess.md @@ -0,0 +1,31 @@ +# LDAPCheckAccess + +Base serializer class which doesn't implement create/update methods + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**has_search_permission** | **bool** | | [optional] +**access** | [**PolicyTestResult**](PolicyTestResult.md) | | + +## Example + +```python +from authentik_client.models.ldap_check_access import LDAPCheckAccess + +# TODO update the JSON string below +json = "{}" +# create an instance of LDAPCheckAccess from a JSON string +ldap_check_access_instance = LDAPCheckAccess.from_json(json) +# print the JSON string representation of the object +print(LDAPCheckAccess.to_json()) + +# convert the object into a dict +ldap_check_access_dict = ldap_check_access_instance.to_dict() +# create an instance of LDAPCheckAccess from a dict +ldap_check_access_from_dict = LDAPCheckAccess.from_dict(ldap_check_access_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPDebug.md b/docs/LDAPDebug.md new file mode 100644 index 000000000..80c1b4d12 --- /dev/null +++ b/docs/LDAPDebug.md @@ -0,0 +1,31 @@ +# LDAPDebug + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user** | **List[Dict[str, object]]** | | [readonly] +**group** | **List[Dict[str, object]]** | | [readonly] +**membership** | **List[Dict[str, object]]** | | [readonly] + +## Example + +```python +from authentik_client.models.ldap_debug import LDAPDebug + +# TODO update the JSON string below +json = "{}" +# create an instance of LDAPDebug from a JSON string +ldap_debug_instance = LDAPDebug.from_json(json) +# print the JSON string representation of the object +print(LDAPDebug.to_json()) + +# convert the object into a dict +ldap_debug_dict = ldap_debug_instance.to_dict() +# create an instance of LDAPDebug from a dict +ldap_debug_from_dict = LDAPDebug.from_dict(ldap_debug_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPOutpostConfig.md b/docs/LDAPOutpostConfig.md new file mode 100644 index 000000000..6fb17014b --- /dev/null +++ b/docs/LDAPOutpostConfig.md @@ -0,0 +1,42 @@ +# LDAPOutpostConfig + +LDAPProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**base_dn** | **str** | DN under which objects are accessible. | [optional] +**bind_flow_slug** | **str** | | +**unbind_flow_slug** | **str** | Get slug for unbind flow, defaulting to brand's default flow. | [readonly] +**application_slug** | **str** | Prioritise backchannel slug over direct application slug | [readonly] +**certificate** | **UUID** | | [optional] +**tls_server_name** | **str** | | [optional] +**uid_start_number** | **int** | The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber | [optional] +**gid_start_number** | **int** | The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber | [optional] +**search_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**bind_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**mfa_support** | **bool** | When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon. | [optional] + +## Example + +```python +from authentik_client.models.ldap_outpost_config import LDAPOutpostConfig + +# TODO update the JSON string below +json = "{}" +# create an instance of LDAPOutpostConfig from a JSON string +ldap_outpost_config_instance = LDAPOutpostConfig.from_json(json) +# print the JSON string representation of the object +print(LDAPOutpostConfig.to_json()) + +# convert the object into a dict +ldap_outpost_config_dict = ldap_outpost_config_instance.to_dict() +# create an instance of LDAPOutpostConfig from a dict +ldap_outpost_config_from_dict = LDAPOutpostConfig.from_dict(ldap_outpost_config_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPProvider.md b/docs/LDAPProvider.md new file mode 100644 index 000000000..d5810c4e4 --- /dev/null +++ b/docs/LDAPProvider.md @@ -0,0 +1,52 @@ +# LDAPProvider + +LDAPProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_application_name** | **str** | Application's display Name. | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**base_dn** | **str** | DN under which objects are accessible. | [optional] +**certificate** | **UUID** | | [optional] +**tls_server_name** | **str** | | [optional] +**uid_start_number** | **int** | The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber | [optional] +**gid_start_number** | **int** | The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber | [optional] +**outpost_set** | **List[str]** | | [readonly] +**search_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**bind_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**mfa_support** | **bool** | When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon. | [optional] + +## Example + +```python +from authentik_client.models.ldap_provider import LDAPProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of LDAPProvider from a JSON string +ldap_provider_instance = LDAPProvider.from_json(json) +# print the JSON string representation of the object +print(LDAPProvider.to_json()) + +# convert the object into a dict +ldap_provider_dict = ldap_provider_instance.to_dict() +# create an instance of LDAPProvider from a dict +ldap_provider_from_dict = LDAPProvider.from_dict(ldap_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPProviderRequest.md b/docs/LDAPProviderRequest.md new file mode 100644 index 000000000..0f2d4ee9a --- /dev/null +++ b/docs/LDAPProviderRequest.md @@ -0,0 +1,42 @@ +# LDAPProviderRequest + +LDAPProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**base_dn** | **str** | DN under which objects are accessible. | [optional] +**certificate** | **UUID** | | [optional] +**tls_server_name** | **str** | | [optional] +**uid_start_number** | **int** | The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber | [optional] +**gid_start_number** | **int** | The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber | [optional] +**search_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**bind_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**mfa_support** | **bool** | When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon. | [optional] + +## Example + +```python +from authentik_client.models.ldap_provider_request import LDAPProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of LDAPProviderRequest from a JSON string +ldap_provider_request_instance = LDAPProviderRequest.from_json(json) +# print the JSON string representation of the object +print(LDAPProviderRequest.to_json()) + +# convert the object into a dict +ldap_provider_request_dict = ldap_provider_request_instance.to_dict() +# create an instance of LDAPProviderRequest from a dict +ldap_provider_request_from_dict = LDAPProviderRequest.from_dict(ldap_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPSource.md b/docs/LDAPSource.md new file mode 100644 index 000000000..56ad181e5 --- /dev/null +++ b/docs/LDAPSource.md @@ -0,0 +1,72 @@ +# LDAPSource + +LDAP Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [readonly] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**icon_url** | **str** | | [readonly] +**icon_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**server_uri** | **str** | | +**peer_certificate** | **UUID** | Optionally verify the LDAP Server's Certificate against the CA Chain in this keypair. | [optional] +**client_certificate** | **UUID** | Client certificate to authenticate against the LDAP Server's Certificate. | [optional] +**bind_cn** | **str** | | [optional] +**start_tls** | **bool** | | [optional] +**sni** | **bool** | | [optional] +**base_dn** | **str** | | +**additional_user_dn** | **str** | Prepended to Base DN for User-queries. | [optional] +**additional_group_dn** | **str** | Prepended to Base DN for Group-queries. | [optional] +**user_object_filter** | **str** | Consider Objects matching this filter to be Users. | [optional] +**group_object_filter** | **str** | Consider Objects matching this filter to be Groups. | [optional] +**group_membership_field** | **str** | Field which contains members of a group. | [optional] +**user_membership_attribute** | **str** | Attribute which matches the value of `group_membership_field`. | [optional] +**object_uniqueness_field** | **str** | Field which contains a unique Identifier. | [optional] +**password_login_update_internal_password** | **bool** | Update internal authentik password when login succeeds with LDAP | [optional] +**sync_users** | **bool** | | [optional] +**sync_users_password** | **bool** | When a user changes their password, sync it back to LDAP. This can only be enabled on a single LDAP source. | [optional] +**sync_groups** | **bool** | | [optional] +**sync_parent_group** | **UUID** | | [optional] +**connectivity** | **Dict[str, Dict[str, str]]** | Get cached source connectivity | [readonly] +**lookup_groups_from_user** | **bool** | Lookup group membership based on a user attribute instead of a group attribute. This allows nested group resolution on systems like FreeIPA and Active Directory | [optional] +**delete_not_found_objects** | **bool** | Delete authentik users and groups which were previously supplied by this source, but are now missing from it. | [optional] +**sync_outgoing_trigger_mode** | [**SyncOutgoingTriggerModeEnum**](SyncOutgoingTriggerModeEnum.md) | When to trigger sync for outgoing providers | [optional] + +## Example + +```python +from authentik_client.models.ldap_source import LDAPSource + +# TODO update the JSON string below +json = "{}" +# create an instance of LDAPSource from a JSON string +ldap_source_instance = LDAPSource.from_json(json) +# print the JSON string representation of the object +print(LDAPSource.to_json()) + +# convert the object into a dict +ldap_source_dict = ldap_source_instance.to_dict() +# create an instance of LDAPSource from a dict +ldap_source_from_dict = LDAPSource.from_dict(ldap_source_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPSourcePropertyMapping.md b/docs/LDAPSourcePropertyMapping.md new file mode 100644 index 000000000..51363cacf --- /dev/null +++ b/docs/LDAPSourcePropertyMapping.md @@ -0,0 +1,37 @@ +# LDAPSourcePropertyMapping + +LDAP PropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of LDAPSourcePropertyMapping from a JSON string +ldap_source_property_mapping_instance = LDAPSourcePropertyMapping.from_json(json) +# print the JSON string representation of the object +print(LDAPSourcePropertyMapping.to_json()) + +# convert the object into a dict +ldap_source_property_mapping_dict = ldap_source_property_mapping_instance.to_dict() +# create an instance of LDAPSourcePropertyMapping from a dict +ldap_source_property_mapping_from_dict = LDAPSourcePropertyMapping.from_dict(ldap_source_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPSourcePropertyMappingRequest.md b/docs/LDAPSourcePropertyMappingRequest.md new file mode 100644 index 000000000..8d5848242 --- /dev/null +++ b/docs/LDAPSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# LDAPSourcePropertyMappingRequest + +LDAP PropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.ldap_source_property_mapping_request import LDAPSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of LDAPSourcePropertyMappingRequest from a JSON string +ldap_source_property_mapping_request_instance = LDAPSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(LDAPSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +ldap_source_property_mapping_request_dict = ldap_source_property_mapping_request_instance.to_dict() +# create an instance of LDAPSourcePropertyMappingRequest from a dict +ldap_source_property_mapping_request_from_dict = LDAPSourcePropertyMappingRequest.from_dict(ldap_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LDAPSourceRequest.md b/docs/LDAPSourceRequest.md new file mode 100644 index 000000000..e142c6b94 --- /dev/null +++ b/docs/LDAPSourceRequest.md @@ -0,0 +1,64 @@ +# LDAPSourceRequest + +LDAP Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**server_uri** | **str** | | +**peer_certificate** | **UUID** | Optionally verify the LDAP Server's Certificate against the CA Chain in this keypair. | [optional] +**client_certificate** | **UUID** | Client certificate to authenticate against the LDAP Server's Certificate. | [optional] +**bind_cn** | **str** | | [optional] +**bind_password** | **str** | | [optional] +**start_tls** | **bool** | | [optional] +**sni** | **bool** | | [optional] +**base_dn** | **str** | | +**additional_user_dn** | **str** | Prepended to Base DN for User-queries. | [optional] +**additional_group_dn** | **str** | Prepended to Base DN for Group-queries. | [optional] +**user_object_filter** | **str** | Consider Objects matching this filter to be Users. | [optional] +**group_object_filter** | **str** | Consider Objects matching this filter to be Groups. | [optional] +**group_membership_field** | **str** | Field which contains members of a group. | [optional] +**user_membership_attribute** | **str** | Attribute which matches the value of `group_membership_field`. | [optional] +**object_uniqueness_field** | **str** | Field which contains a unique Identifier. | [optional] +**password_login_update_internal_password** | **bool** | Update internal authentik password when login succeeds with LDAP | [optional] +**sync_users** | **bool** | | [optional] +**sync_users_password** | **bool** | When a user changes their password, sync it back to LDAP. This can only be enabled on a single LDAP source. | [optional] +**sync_groups** | **bool** | | [optional] +**sync_parent_group** | **UUID** | | [optional] +**lookup_groups_from_user** | **bool** | Lookup group membership based on a user attribute instead of a group attribute. This allows nested group resolution on systems like FreeIPA and Active Directory | [optional] +**delete_not_found_objects** | **bool** | Delete authentik users and groups which were previously supplied by this source, but are now missing from it. | [optional] +**sync_outgoing_trigger_mode** | [**SyncOutgoingTriggerModeEnum**](SyncOutgoingTriggerModeEnum.md) | When to trigger sync for outgoing providers | [optional] + +## Example + +```python +from authentik_client.models.ldap_source_request import LDAPSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of LDAPSourceRequest from a JSON string +ldap_source_request_instance = LDAPSourceRequest.from_json(json) +# print the JSON string representation of the object +print(LDAPSourceRequest.to_json()) + +# convert the object into a dict +ldap_source_request_dict = ldap_source_request_instance.to_dict() +# create an instance of LDAPSourceRequest from a dict +ldap_source_request_from_dict = LDAPSourceRequest.from_dict(ldap_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LangEnum.md b/docs/LangEnum.md new file mode 100644 index 000000000..ceca51ddb --- /dev/null +++ b/docs/LangEnum.md @@ -0,0 +1,206 @@ +# LangEnum + + +## Enum + +* `AF` (value: `'af'`) + +* `AR` (value: `'ar'`) + +* `AR_MINUS_DZ` (value: `'ar-dz'`) + +* `AST` (value: `'ast'`) + +* `AZ` (value: `'az'`) + +* `BE` (value: `'be'`) + +* `BG` (value: `'bg'`) + +* `BN` (value: `'bn'`) + +* `BR` (value: `'br'`) + +* `BS` (value: `'bs'`) + +* `CA` (value: `'ca'`) + +* `CKB` (value: `'ckb'`) + +* `CS` (value: `'cs'`) + +* `CY` (value: `'cy'`) + +* `DA` (value: `'da'`) + +* `DE` (value: `'de'`) + +* `DSB` (value: `'dsb'`) + +* `EL` (value: `'el'`) + +* `EN` (value: `'en'`) + +* `EN_MINUS_AU` (value: `'en-au'`) + +* `EN_MINUS_GB` (value: `'en-gb'`) + +* `EO` (value: `'eo'`) + +* `ES` (value: `'es'`) + +* `ES_MINUS_AR` (value: `'es-ar'`) + +* `ES_MINUS_CO` (value: `'es-co'`) + +* `ES_MINUS_MX` (value: `'es-mx'`) + +* `ES_MINUS_NI` (value: `'es-ni'`) + +* `ES_MINUS_VE` (value: `'es-ve'`) + +* `ET` (value: `'et'`) + +* `EU` (value: `'eu'`) + +* `FA` (value: `'fa'`) + +* `FI` (value: `'fi'`) + +* `FR` (value: `'fr'`) + +* `FY` (value: `'fy'`) + +* `GA` (value: `'ga'`) + +* `GD` (value: `'gd'`) + +* `GL` (value: `'gl'`) + +* `HE` (value: `'he'`) + +* `HI` (value: `'hi'`) + +* `HR` (value: `'hr'`) + +* `HSB` (value: `'hsb'`) + +* `HU` (value: `'hu'`) + +* `HY` (value: `'hy'`) + +* `IA` (value: `'ia'`) + +* `ID` (value: `'id'`) + +* `IG` (value: `'ig'`) + +* `IO` (value: `'io'`) + +* `IS` (value: `'is'`) + +* `IT` (value: `'it'`) + +* `JA` (value: `'ja'`) + +* `KA` (value: `'ka'`) + +* `KAB` (value: `'kab'`) + +* `KK` (value: `'kk'`) + +* `KM` (value: `'km'`) + +* `KN` (value: `'kn'`) + +* `KO` (value: `'ko'`) + +* `KY` (value: `'ky'`) + +* `LB` (value: `'lb'`) + +* `LT` (value: `'lt'`) + +* `LV` (value: `'lv'`) + +* `MK` (value: `'mk'`) + +* `ML` (value: `'ml'`) + +* `MN` (value: `'mn'`) + +* `MR` (value: `'mr'`) + +* `MS` (value: `'ms'`) + +* `MY` (value: `'my'`) + +* `NB` (value: `'nb'`) + +* `NE` (value: `'ne'`) + +* `NL` (value: `'nl'`) + +* `NN` (value: `'nn'`) + +* `OS` (value: `'os'`) + +* `PA` (value: `'pa'`) + +* `PL` (value: `'pl'`) + +* `PT` (value: `'pt'`) + +* `PT_MINUS_BR` (value: `'pt-br'`) + +* `RO` (value: `'ro'`) + +* `RU` (value: `'ru'`) + +* `SK` (value: `'sk'`) + +* `SL` (value: `'sl'`) + +* `SQ` (value: `'sq'`) + +* `SR` (value: `'sr'`) + +* `SR_MINUS_LATN` (value: `'sr-latn'`) + +* `SV` (value: `'sv'`) + +* `SW` (value: `'sw'`) + +* `TA` (value: `'ta'`) + +* `TE` (value: `'te'`) + +* `TG` (value: `'tg'`) + +* `TH` (value: `'th'`) + +* `TK` (value: `'tk'`) + +* `TR` (value: `'tr'`) + +* `TT` (value: `'tt'`) + +* `UDM` (value: `'udm'`) + +* `UG` (value: `'ug'`) + +* `UK` (value: `'uk'`) + +* `UR` (value: `'ur'`) + +* `UZ` (value: `'uz'`) + +* `VI` (value: `'vi'`) + +* `ZH_MINUS_HANS` (value: `'zh-hans'`) + +* `ZH_MINUS_HANT` (value: `'zh-hant'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LastTaskStatusEnum.md b/docs/LastTaskStatusEnum.md new file mode 100644 index 000000000..a8299caf4 --- /dev/null +++ b/docs/LastTaskStatusEnum.md @@ -0,0 +1,28 @@ +# LastTaskStatusEnum + + +## Enum + +* `QUEUED` (value: `'queued'`) + +* `CONSUMED` (value: `'consumed'`) + +* `PREPROCESS` (value: `'preprocess'`) + +* `RUNNING` (value: `'running'`) + +* `POSTPROCESS` (value: `'postprocess'`) + +* `REJECTED` (value: `'rejected'`) + +* `DONE` (value: `'done'`) + +* `INFO` (value: `'info'`) + +* `WARNING` (value: `'warning'`) + +* `ERROR` (value: `'error'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/License.md b/docs/License.md new file mode 100644 index 000000000..d589d096a --- /dev/null +++ b/docs/License.md @@ -0,0 +1,35 @@ +# License + +License Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**license_uuid** | **UUID** | | [readonly] +**name** | **str** | | [readonly] +**key** | **str** | | +**expiry** | **datetime** | | [readonly] +**internal_users** | **int** | | [readonly] +**external_users** | **int** | | [readonly] + +## Example + +```python +from authentik_client.models.license import License + +# TODO update the JSON string below +json = "{}" +# create an instance of License from a JSON string +license_instance = License.from_json(json) +# print the JSON string representation of the object +print(License.to_json()) + +# convert the object into a dict +license_dict = license_instance.to_dict() +# create an instance of License from a dict +license_from_dict = License.from_dict(license_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LicenseFlagsEnum.md b/docs/LicenseFlagsEnum.md new file mode 100644 index 000000000..5885c8b52 --- /dev/null +++ b/docs/LicenseFlagsEnum.md @@ -0,0 +1,12 @@ +# LicenseFlagsEnum + + +## Enum + +* `TRIAL` (value: `'trial'`) + +* `NON_PRODUCTION` (value: `'non_production'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LicenseForecast.md b/docs/LicenseForecast.md new file mode 100644 index 000000000..d5a4d97bc --- /dev/null +++ b/docs/LicenseForecast.md @@ -0,0 +1,33 @@ +# LicenseForecast + +Serializer for license forecast + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**internal_users** | **int** | | +**external_users** | **int** | | +**forecasted_internal_users** | **int** | | +**forecasted_external_users** | **int** | | + +## Example + +```python +from authentik_client.models.license_forecast import LicenseForecast + +# TODO update the JSON string below +json = "{}" +# create an instance of LicenseForecast from a JSON string +license_forecast_instance = LicenseForecast.from_json(json) +# print the JSON string representation of the object +print(LicenseForecast.to_json()) + +# convert the object into a dict +license_forecast_dict = license_forecast_instance.to_dict() +# create an instance of LicenseForecast from a dict +license_forecast_from_dict = LicenseForecast.from_dict(license_forecast_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LicenseRequest.md b/docs/LicenseRequest.md new file mode 100644 index 000000000..f557e848c --- /dev/null +++ b/docs/LicenseRequest.md @@ -0,0 +1,30 @@ +# LicenseRequest + +License Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**key** | **str** | | + +## Example + +```python +from authentik_client.models.license_request import LicenseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of LicenseRequest from a JSON string +license_request_instance = LicenseRequest.from_json(json) +# print the JSON string representation of the object +print(LicenseRequest.to_json()) + +# convert the object into a dict +license_request_dict = license_request_instance.to_dict() +# create an instance of LicenseRequest from a dict +license_request_from_dict = LicenseRequest.from_dict(license_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LicenseStatusEnum.md b/docs/LicenseStatusEnum.md new file mode 100644 index 000000000..9c3972492 --- /dev/null +++ b/docs/LicenseStatusEnum.md @@ -0,0 +1,22 @@ +# LicenseStatusEnum + + +## Enum + +* `UNLICENSED` (value: `'unlicensed'`) + +* `VALID` (value: `'valid'`) + +* `EXPIRED` (value: `'expired'`) + +* `EXPIRY_SOON` (value: `'expiry_soon'`) + +* `LIMIT_EXCEEDED_ADMIN` (value: `'limit_exceeded_admin'`) + +* `LIMIT_EXCEEDED_USER` (value: `'limit_exceeded_user'`) + +* `READ_ONLY` (value: `'read_only'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LicenseSummary.md b/docs/LicenseSummary.md new file mode 100644 index 000000000..b35019f0c --- /dev/null +++ b/docs/LicenseSummary.md @@ -0,0 +1,34 @@ +# LicenseSummary + +Serializer for license status + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**internal_users** | **int** | | +**external_users** | **int** | | +**status** | [**LicenseSummaryStatusEnum**](LicenseSummaryStatusEnum.md) | | +**latest_valid** | **datetime** | | +**license_flags** | [**List[LicenseFlagsEnum]**](LicenseFlagsEnum.md) | | + +## Example + +```python +from authentik_client.models.license_summary import LicenseSummary + +# TODO update the JSON string below +json = "{}" +# create an instance of LicenseSummary from a JSON string +license_summary_instance = LicenseSummary.from_json(json) +# print the JSON string representation of the object +print(LicenseSummary.to_json()) + +# convert the object into a dict +license_summary_dict = license_summary_instance.to_dict() +# create an instance of LicenseSummary from a dict +license_summary_from_dict = LicenseSummary.from_dict(license_summary_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LicenseSummaryStatusEnum.md b/docs/LicenseSummaryStatusEnum.md new file mode 100644 index 000000000..79652756b --- /dev/null +++ b/docs/LicenseSummaryStatusEnum.md @@ -0,0 +1,22 @@ +# LicenseSummaryStatusEnum + + +## Enum + +* `UNLICENSED` (value: `'unlicensed'`) + +* `VALID` (value: `'valid'`) + +* `EXPIRED` (value: `'expired'`) + +* `EXPIRY_SOON` (value: `'expiry_soon'`) + +* `LIMIT_EXCEEDED_ADMIN` (value: `'limit_exceeded_admin'`) + +* `LIMIT_EXCEEDED_USER` (value: `'limit_exceeded_user'`) + +* `READ_ONLY` (value: `'read_only'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LifecycleApi.md b/docs/LifecycleApi.md new file mode 100644 index 000000000..cb097fe17 --- /dev/null +++ b/docs/LifecycleApi.md @@ -0,0 +1,810 @@ +# authentik_client.LifecycleApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**lifecycle_iterations_create**](LifecycleApi.md#lifecycle_iterations_create) | **POST** /lifecycle/iterations/ | +[**lifecycle_iterations_list_latest**](LifecycleApi.md#lifecycle_iterations_list_latest) | **GET** /lifecycle/iterations/latest/{content_type}/{object_id}/ | +[**lifecycle_iterations_list_open**](LifecycleApi.md#lifecycle_iterations_list_open) | **GET** /lifecycle/iterations/open/ | +[**lifecycle_reviews_create**](LifecycleApi.md#lifecycle_reviews_create) | **POST** /lifecycle/reviews/ | +[**lifecycle_rules_create**](LifecycleApi.md#lifecycle_rules_create) | **POST** /lifecycle/rules/ | +[**lifecycle_rules_destroy**](LifecycleApi.md#lifecycle_rules_destroy) | **DELETE** /lifecycle/rules/{id}/ | +[**lifecycle_rules_list**](LifecycleApi.md#lifecycle_rules_list) | **GET** /lifecycle/rules/ | +[**lifecycle_rules_partial_update**](LifecycleApi.md#lifecycle_rules_partial_update) | **PATCH** /lifecycle/rules/{id}/ | +[**lifecycle_rules_retrieve**](LifecycleApi.md#lifecycle_rules_retrieve) | **GET** /lifecycle/rules/{id}/ | +[**lifecycle_rules_update**](LifecycleApi.md#lifecycle_rules_update) | **PUT** /lifecycle/rules/{id}/ | + + +# **lifecycle_iterations_create** +> LifecycleIteration lifecycle_iterations_create(lifecycle_iteration_request) + +Mixin to validate that a valid enterprise license +exists before allowing to save the object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.lifecycle_iteration import LifecycleIteration +from authentik_client.models.lifecycle_iteration_request import LifecycleIterationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + lifecycle_iteration_request = authentik_client.LifecycleIterationRequest() # LifecycleIterationRequest | + + try: + api_response = api_instance.lifecycle_iterations_create(lifecycle_iteration_request) + print("The response of LifecycleApi->lifecycle_iterations_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_iterations_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **lifecycle_iteration_request** | [**LifecycleIterationRequest**](LifecycleIterationRequest.md)| | + +### Return type + +[**LifecycleIteration**](LifecycleIteration.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **lifecycle_iterations_list_latest** +> List[LifecycleIteration] lifecycle_iterations_list_latest(content_type, object_id, ordering=ordering, search=search, user_is_reviewer=user_is_reviewer) + +Mixin to validate that a valid enterprise license +exists before allowing to save the object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.lifecycle_iteration import LifecycleIteration +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + content_type = 'content_type_example' # str | + object_id = 'object_id_example' # str | + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + search = 'search_example' # str | A search term. (optional) + user_is_reviewer = True # bool | (optional) + + try: + api_response = api_instance.lifecycle_iterations_list_latest(content_type, object_id, ordering=ordering, search=search, user_is_reviewer=user_is_reviewer) + print("The response of LifecycleApi->lifecycle_iterations_list_latest:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_iterations_list_latest: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **content_type** | **str**| | + **object_id** | **str**| | + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **search** | **str**| A search term. | [optional] + **user_is_reviewer** | **bool**| | [optional] + +### Return type + +[**List[LifecycleIteration]**](LifecycleIteration.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **lifecycle_iterations_list_open** +> PaginatedLifecycleIterationList lifecycle_iterations_list_open(ordering=ordering, page=page, page_size=page_size, search=search, user_is_reviewer=user_is_reviewer) + +Mixin to validate that a valid enterprise license +exists before allowing to save the object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_lifecycle_iteration_list import PaginatedLifecycleIterationList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + user_is_reviewer = True # bool | (optional) + + try: + api_response = api_instance.lifecycle_iterations_list_open(ordering=ordering, page=page, page_size=page_size, search=search, user_is_reviewer=user_is_reviewer) + print("The response of LifecycleApi->lifecycle_iterations_list_open:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_iterations_list_open: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **user_is_reviewer** | **bool**| | [optional] + +### Return type + +[**PaginatedLifecycleIterationList**](PaginatedLifecycleIterationList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **lifecycle_reviews_create** +> Review lifecycle_reviews_create(review_request) + +Mixin to validate that a valid enterprise license +exists before allowing to save the object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.review import Review +from authentik_client.models.review_request import ReviewRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + review_request = authentik_client.ReviewRequest() # ReviewRequest | + + try: + api_response = api_instance.lifecycle_reviews_create(review_request) + print("The response of LifecycleApi->lifecycle_reviews_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_reviews_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **review_request** | [**ReviewRequest**](ReviewRequest.md)| | + +### Return type + +[**Review**](Review.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **lifecycle_rules_create** +> LifecycleRule lifecycle_rules_create(lifecycle_rule_request) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.lifecycle_rule import LifecycleRule +from authentik_client.models.lifecycle_rule_request import LifecycleRuleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + lifecycle_rule_request = authentik_client.LifecycleRuleRequest() # LifecycleRuleRequest | + + try: + api_response = api_instance.lifecycle_rules_create(lifecycle_rule_request) + print("The response of LifecycleApi->lifecycle_rules_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_rules_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **lifecycle_rule_request** | [**LifecycleRuleRequest**](LifecycleRuleRequest.md)| | + +### Return type + +[**LifecycleRule**](LifecycleRule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **lifecycle_rules_destroy** +> lifecycle_rules_destroy(id) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this lifecycle rule. + + try: + api_instance.lifecycle_rules_destroy(id) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_rules_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this lifecycle rule. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **lifecycle_rules_list** +> PaginatedLifecycleRuleList lifecycle_rules_list(content_type__model=content_type__model, ordering=ordering, page=page, page_size=page_size, search=search) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_lifecycle_rule_list import PaginatedLifecycleRuleList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + content_type__model = 'content_type__model_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.lifecycle_rules_list(content_type__model=content_type__model, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of LifecycleApi->lifecycle_rules_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_rules_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **content_type__model** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedLifecycleRuleList**](PaginatedLifecycleRuleList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **lifecycle_rules_partial_update** +> LifecycleRule lifecycle_rules_partial_update(id, patched_lifecycle_rule_request=patched_lifecycle_rule_request) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.lifecycle_rule import LifecycleRule +from authentik_client.models.patched_lifecycle_rule_request import PatchedLifecycleRuleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this lifecycle rule. + patched_lifecycle_rule_request = authentik_client.PatchedLifecycleRuleRequest() # PatchedLifecycleRuleRequest | (optional) + + try: + api_response = api_instance.lifecycle_rules_partial_update(id, patched_lifecycle_rule_request=patched_lifecycle_rule_request) + print("The response of LifecycleApi->lifecycle_rules_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_rules_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this lifecycle rule. | + **patched_lifecycle_rule_request** | [**PatchedLifecycleRuleRequest**](PatchedLifecycleRuleRequest.md)| | [optional] + +### Return type + +[**LifecycleRule**](LifecycleRule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **lifecycle_rules_retrieve** +> LifecycleRule lifecycle_rules_retrieve(id) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.lifecycle_rule import LifecycleRule +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this lifecycle rule. + + try: + api_response = api_instance.lifecycle_rules_retrieve(id) + print("The response of LifecycleApi->lifecycle_rules_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_rules_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this lifecycle rule. | + +### Return type + +[**LifecycleRule**](LifecycleRule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **lifecycle_rules_update** +> LifecycleRule lifecycle_rules_update(id, lifecycle_rule_request) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.lifecycle_rule import LifecycleRule +from authentik_client.models.lifecycle_rule_request import LifecycleRuleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.LifecycleApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this lifecycle rule. + lifecycle_rule_request = authentik_client.LifecycleRuleRequest() # LifecycleRuleRequest | + + try: + api_response = api_instance.lifecycle_rules_update(id, lifecycle_rule_request) + print("The response of LifecycleApi->lifecycle_rules_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling LifecycleApi->lifecycle_rules_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this lifecycle rule. | + **lifecycle_rule_request** | [**LifecycleRuleRequest**](LifecycleRuleRequest.md)| | + +### Return type + +[**LifecycleRule**](LifecycleRule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/LifecycleIteration.md b/docs/LifecycleIteration.md new file mode 100644 index 000000000..925929dec --- /dev/null +++ b/docs/LifecycleIteration.md @@ -0,0 +1,41 @@ +# LifecycleIteration + +Mixin to validate that a valid enterprise license exists before allowing to save the object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**content_type** | [**ContentTypeEnum**](ContentTypeEnum.md) | | +**object_id** | **str** | | [readonly] +**object_verbose** | **str** | | [readonly] +**object_admin_url** | **str** | | [readonly] +**state** | [**LifecycleIterationStateEnum**](LifecycleIterationStateEnum.md) | | [readonly] +**opened_on** | **datetime** | | [readonly] +**grace_period_end** | **datetime** | | [readonly] +**next_review_date** | **datetime** | | [readonly] +**reviews** | [**List[Review]**](Review.md) | | [readonly] +**rule** | [**RelatedRule**](RelatedRule.md) | | [readonly] +**user_can_review** | **bool** | | [readonly] + +## Example + +```python +from authentik_client.models.lifecycle_iteration import LifecycleIteration + +# TODO update the JSON string below +json = "{}" +# create an instance of LifecycleIteration from a JSON string +lifecycle_iteration_instance = LifecycleIteration.from_json(json) +# print the JSON string representation of the object +print(LifecycleIteration.to_json()) + +# convert the object into a dict +lifecycle_iteration_dict = lifecycle_iteration_instance.to_dict() +# create an instance of LifecycleIteration from a dict +lifecycle_iteration_from_dict = LifecycleIteration.from_dict(lifecycle_iteration_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LifecycleIterationRequest.md b/docs/LifecycleIterationRequest.md new file mode 100644 index 000000000..d08df4fb2 --- /dev/null +++ b/docs/LifecycleIterationRequest.md @@ -0,0 +1,30 @@ +# LifecycleIterationRequest + +Mixin to validate that a valid enterprise license exists before allowing to save the object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**content_type** | [**ContentTypeEnum**](ContentTypeEnum.md) | | + +## Example + +```python +from authentik_client.models.lifecycle_iteration_request import LifecycleIterationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of LifecycleIterationRequest from a JSON string +lifecycle_iteration_request_instance = LifecycleIterationRequest.from_json(json) +# print the JSON string representation of the object +print(LifecycleIterationRequest.to_json()) + +# convert the object into a dict +lifecycle_iteration_request_dict = lifecycle_iteration_request_instance.to_dict() +# create an instance of LifecycleIterationRequest from a dict +lifecycle_iteration_request_from_dict = LifecycleIterationRequest.from_dict(lifecycle_iteration_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LifecycleIterationStateEnum.md b/docs/LifecycleIterationStateEnum.md new file mode 100644 index 000000000..d3035982f --- /dev/null +++ b/docs/LifecycleIterationStateEnum.md @@ -0,0 +1,16 @@ +# LifecycleIterationStateEnum + + +## Enum + +* `REVIEWED` (value: `'REVIEWED'`) + +* `PENDING` (value: `'PENDING'`) + +* `OVERDUE` (value: `'OVERDUE'`) + +* `CANCELED` (value: `'CANCELED'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LifecycleRule.md b/docs/LifecycleRule.md new file mode 100644 index 000000000..9fa814523 --- /dev/null +++ b/docs/LifecycleRule.md @@ -0,0 +1,43 @@ +# LifecycleRule + +Mixin to validate that a valid enterprise license exists before allowing to save the object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**name** | **str** | | +**content_type** | [**ContentTypeEnum**](ContentTypeEnum.md) | | +**object_id** | **str** | | [optional] +**interval** | **str** | | [optional] +**grace_period** | **str** | | [optional] +**reviewer_groups** | **List[UUID]** | | [optional] +**reviewer_groups_obj** | [**List[ReviewerGroup]**](ReviewerGroup.md) | | [readonly] +**min_reviewers** | **int** | | [optional] +**min_reviewers_is_per_group** | **bool** | | [optional] +**reviewers** | **List[UUID]** | | +**reviewers_obj** | [**List[ReviewerUser]**](ReviewerUser.md) | | [readonly] +**notification_transports** | **List[UUID]** | Select which transports should be used to notify the reviewers. If none are selected, the notification will only be shown in the authentik UI. | [optional] +**target_verbose** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.lifecycle_rule import LifecycleRule + +# TODO update the JSON string below +json = "{}" +# create an instance of LifecycleRule from a JSON string +lifecycle_rule_instance = LifecycleRule.from_json(json) +# print the JSON string representation of the object +print(LifecycleRule.to_json()) + +# convert the object into a dict +lifecycle_rule_dict = lifecycle_rule_instance.to_dict() +# create an instance of LifecycleRule from a dict +lifecycle_rule_from_dict = LifecycleRule.from_dict(lifecycle_rule_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LifecycleRuleRequest.md b/docs/LifecycleRuleRequest.md new file mode 100644 index 000000000..f170fbbca --- /dev/null +++ b/docs/LifecycleRuleRequest.md @@ -0,0 +1,39 @@ +# LifecycleRuleRequest + +Mixin to validate that a valid enterprise license exists before allowing to save the object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**content_type** | [**ContentTypeEnum**](ContentTypeEnum.md) | | +**object_id** | **str** | | [optional] +**interval** | **str** | | [optional] +**grace_period** | **str** | | [optional] +**reviewer_groups** | **List[UUID]** | | [optional] +**min_reviewers** | **int** | | [optional] +**min_reviewers_is_per_group** | **bool** | | [optional] +**reviewers** | **List[UUID]** | | +**notification_transports** | **List[UUID]** | Select which transports should be used to notify the reviewers. If none are selected, the notification will only be shown in the authentik UI. | [optional] + +## Example + +```python +from authentik_client.models.lifecycle_rule_request import LifecycleRuleRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of LifecycleRuleRequest from a JSON string +lifecycle_rule_request_instance = LifecycleRuleRequest.from_json(json) +# print the JSON string representation of the object +print(LifecycleRuleRequest.to_json()) + +# convert the object into a dict +lifecycle_rule_request_dict = lifecycle_rule_request_instance.to_dict() +# create an instance of LifecycleRuleRequest from a dict +lifecycle_rule_request_from_dict = LifecycleRuleRequest.from_dict(lifecycle_rule_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Link.md b/docs/Link.md new file mode 100644 index 000000000..ce568bbd6 --- /dev/null +++ b/docs/Link.md @@ -0,0 +1,30 @@ +# Link + +Returns a single link + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**link** | **str** | | + +## Example + +```python +from authentik_client.models.link import Link + +# TODO update the JSON string below +json = "{}" +# create an instance of Link from a JSON string +link_instance = Link.from_json(json) +# print the JSON string representation of the object +print(Link.to_json()) + +# convert the object into a dict +link_dict = link_instance.to_dict() +# create an instance of Link from a dict +link_from_dict = Link.from_dict(link_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LogEvent.md b/docs/LogEvent.md new file mode 100644 index 000000000..69b8e9a35 --- /dev/null +++ b/docs/LogEvent.md @@ -0,0 +1,34 @@ +# LogEvent + +Single log message with all context logged. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**timestamp** | **datetime** | | +**log_level** | [**LogLevelEnum**](LogLevelEnum.md) | | +**logger** | **str** | | +**event** | **str** | | +**attributes** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.log_event import LogEvent + +# TODO update the JSON string below +json = "{}" +# create an instance of LogEvent from a JSON string +log_event_instance = LogEvent.from_json(json) +# print the JSON string representation of the object +print(LogEvent.to_json()) + +# convert the object into a dict +log_event_dict = log_event_instance.to_dict() +# create an instance of LogEvent from a dict +log_event_from_dict = LogEvent.from_dict(log_event_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LogLevelEnum.md b/docs/LogLevelEnum.md new file mode 100644 index 000000000..88ada29c9 --- /dev/null +++ b/docs/LogLevelEnum.md @@ -0,0 +1,24 @@ +# LogLevelEnum + + +## Enum + +* `CRITICAL` (value: `'critical'`) + +* `EXCEPTION` (value: `'exception'`) + +* `ERROR` (value: `'error'`) + +* `WARN` (value: `'warn'`) + +* `WARNING` (value: `'warning'`) + +* `INFO` (value: `'info'`) + +* `DEBUG` (value: `'debug'`) + +* `NOTSET` (value: `'notset'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LoginChallengeTypes.md b/docs/LoginChallengeTypes.md new file mode 100644 index 000000000..16737fcd9 --- /dev/null +++ b/docs/LoginChallengeTypes.md @@ -0,0 +1,40 @@ +# LoginChallengeTypes + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-source-telegram'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**to** | **str** | | +**final_redirect** | **bool** | | [optional] [default to False] +**client_id** | **str** | | +**scope** | **str** | | +**redirect_uri** | **str** | | +**state** | **str** | | +**slug** | **str** | | +**bot_username** | **str** | Telegram bot username | +**request_message_access** | **bool** | | + +## Example + +```python +from authentik_client.models.login_challenge_types import LoginChallengeTypes + +# TODO update the JSON string below +json = "{}" +# create an instance of LoginChallengeTypes from a JSON string +login_challenge_types_instance = LoginChallengeTypes.from_json(json) +# print the JSON string representation of the object +print(LoginChallengeTypes.to_json()) + +# convert the object into a dict +login_challenge_types_dict = login_challenge_types_instance.to_dict() +# create an instance of LoginChallengeTypes from a dict +login_challenge_types_from_dict = LoginChallengeTypes.from_dict(login_challenge_types_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LoginSource.md b/docs/LoginSource.md new file mode 100644 index 000000000..02baf98c0 --- /dev/null +++ b/docs/LoginSource.md @@ -0,0 +1,33 @@ +# LoginSource + +Serializer for Login buttons of sources + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**icon_url** | **str** | | [optional] +**promoted** | **bool** | | [optional] [default to False] +**challenge** | [**LoginChallengeTypes**](LoginChallengeTypes.md) | | + +## Example + +```python +from authentik_client.models.login_source import LoginSource + +# TODO update the JSON string below +json = "{}" +# create an instance of LoginSource from a JSON string +login_source_instance = LoginSource.from_json(json) +# print the JSON string representation of the object +print(LoginSource.to_json()) + +# convert the object into a dict +login_source_dict = login_source_instance.to_dict() +# create an instance of LoginSource from a dict +login_source_from_dict = LoginSource.from_dict(login_source_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LogoutURL.md b/docs/LogoutURL.md new file mode 100644 index 000000000..b6ae14d96 --- /dev/null +++ b/docs/LogoutURL.md @@ -0,0 +1,35 @@ +# LogoutURL + +Data for a single logout URL + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**url** | **str** | | +**provider_name** | **str** | | [optional] +**binding** | **str** | | [optional] +**saml_request** | **str** | | [optional] +**saml_response** | **str** | | [optional] +**saml_relay_state** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.logout_url import LogoutURL + +# TODO update the JSON string below +json = "{}" +# create an instance of LogoutURL from a JSON string +logout_url_instance = LogoutURL.from_json(json) +# print the JSON string representation of the object +print(LogoutURL.to_json()) + +# convert the object into a dict +logout_url_dict = logout_url_instance.to_dict() +# create an instance of LogoutURL from a dict +logout_url_from_dict = LogoutURL.from_dict(logout_url_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MDMConfigRequest.md b/docs/MDMConfigRequest.md new file mode 100644 index 000000000..4c0e079eb --- /dev/null +++ b/docs/MDMConfigRequest.md @@ -0,0 +1,31 @@ +# MDMConfigRequest + +Base serializer class which doesn't implement create/update methods + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**platform** | [**DeviceFactsOSFamily**](DeviceFactsOSFamily.md) | | +**enrollment_token** | **UUID** | | + +## Example + +```python +from authentik_client.models.mdm_config_request import MDMConfigRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of MDMConfigRequest from a JSON string +mdm_config_request_instance = MDMConfigRequest.from_json(json) +# print the JSON string representation of the object +print(MDMConfigRequest.to_json()) + +# convert the object into a dict +mdm_config_request_dict = mdm_config_request_instance.to_dict() +# create an instance of MDMConfigRequest from a dict +mdm_config_request_from_dict = MDMConfigRequest.from_dict(mdm_config_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MDMConfigResponse.md b/docs/MDMConfigResponse.md new file mode 100644 index 000000000..8859f2743 --- /dev/null +++ b/docs/MDMConfigResponse.md @@ -0,0 +1,32 @@ +# MDMConfigResponse + +Base serializer class which doesn't implement create/update methods + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**config** | **str** | | +**mime_type** | **str** | | +**filename** | **str** | | + +## Example + +```python +from authentik_client.models.mdm_config_response import MDMConfigResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of MDMConfigResponse from a JSON string +mdm_config_response_instance = MDMConfigResponse.from_json(json) +# print the JSON string representation of the object +print(MDMConfigResponse.to_json()) + +# convert the object into a dict +mdm_config_response_dict = mdm_config_response_instance.to_dict() +# create an instance of MDMConfigResponse from a dict +mdm_config_response_from_dict = MDMConfigResponse.from_dict(mdm_config_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ManagedApi.md b/docs/ManagedApi.md new file mode 100644 index 000000000..cd1deb8f3 --- /dev/null +++ b/docs/ManagedApi.md @@ -0,0 +1,802 @@ +# authentik_client.ManagedApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**managed_blueprints_apply_create**](ManagedApi.md#managed_blueprints_apply_create) | **POST** /managed/blueprints/{instance_uuid}/apply/ | +[**managed_blueprints_available_list**](ManagedApi.md#managed_blueprints_available_list) | **GET** /managed/blueprints/available/ | +[**managed_blueprints_create**](ManagedApi.md#managed_blueprints_create) | **POST** /managed/blueprints/ | +[**managed_blueprints_destroy**](ManagedApi.md#managed_blueprints_destroy) | **DELETE** /managed/blueprints/{instance_uuid}/ | +[**managed_blueprints_import_create**](ManagedApi.md#managed_blueprints_import_create) | **POST** /managed/blueprints/import/ | +[**managed_blueprints_list**](ManagedApi.md#managed_blueprints_list) | **GET** /managed/blueprints/ | +[**managed_blueprints_partial_update**](ManagedApi.md#managed_blueprints_partial_update) | **PATCH** /managed/blueprints/{instance_uuid}/ | +[**managed_blueprints_retrieve**](ManagedApi.md#managed_blueprints_retrieve) | **GET** /managed/blueprints/{instance_uuid}/ | +[**managed_blueprints_update**](ManagedApi.md#managed_blueprints_update) | **PUT** /managed/blueprints/{instance_uuid}/ | +[**managed_blueprints_used_by_list**](ManagedApi.md#managed_blueprints_used_by_list) | **GET** /managed/blueprints/{instance_uuid}/used_by/ | + + +# **managed_blueprints_apply_create** +> BlueprintInstance managed_blueprints_apply_create(instance_uuid) + +Apply a blueprint + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.blueprint_instance import BlueprintInstance +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + instance_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Blueprint Instance. + + try: + api_response = api_instance.managed_blueprints_apply_create(instance_uuid) + print("The response of ManagedApi->managed_blueprints_apply_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_apply_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **instance_uuid** | **UUID**| A UUID string identifying this Blueprint Instance. | + +### Return type + +[**BlueprintInstance**](BlueprintInstance.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **managed_blueprints_available_list** +> List[BlueprintFile] managed_blueprints_available_list() + +Get blueprints + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.blueprint_file import BlueprintFile +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + + try: + api_response = api_instance.managed_blueprints_available_list() + print("The response of ManagedApi->managed_blueprints_available_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_available_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[BlueprintFile]**](BlueprintFile.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **managed_blueprints_create** +> BlueprintInstance managed_blueprints_create(blueprint_instance_request) + +Blueprint instances + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.blueprint_instance import BlueprintInstance +from authentik_client.models.blueprint_instance_request import BlueprintInstanceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + blueprint_instance_request = authentik_client.BlueprintInstanceRequest() # BlueprintInstanceRequest | + + try: + api_response = api_instance.managed_blueprints_create(blueprint_instance_request) + print("The response of ManagedApi->managed_blueprints_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **blueprint_instance_request** | [**BlueprintInstanceRequest**](BlueprintInstanceRequest.md)| | + +### Return type + +[**BlueprintInstance**](BlueprintInstance.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **managed_blueprints_destroy** +> managed_blueprints_destroy(instance_uuid) + +Blueprint instances + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + instance_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Blueprint Instance. + + try: + api_instance.managed_blueprints_destroy(instance_uuid) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **instance_uuid** | **UUID**| A UUID string identifying this Blueprint Instance. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **managed_blueprints_import_create** +> BlueprintImportResult managed_blueprints_import_create(file=file, path=path, context=context) + +Import blueprint from .yaml file and apply it once, without creating an instance + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.blueprint_import_result import BlueprintImportResult +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + file = None # bytes | (optional) + path = 'path_example' # str | (optional) + context = 'context_example' # str | (optional) + + try: + api_response = api_instance.managed_blueprints_import_create(file=file, path=path, context=context) + print("The response of ManagedApi->managed_blueprints_import_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_import_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **file** | **bytes**| | [optional] + **path** | **str**| | [optional] + **context** | **str**| | [optional] + +### Return type + +[**BlueprintImportResult**](BlueprintImportResult.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: multipart/form-data + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **managed_blueprints_list** +> PaginatedBlueprintInstanceList managed_blueprints_list(name=name, ordering=ordering, page=page, page_size=page_size, path=path, search=search) + +Blueprint instances + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_blueprint_instance_list import PaginatedBlueprintInstanceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + path = 'path_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.managed_blueprints_list(name=name, ordering=ordering, page=page, page_size=page_size, path=path, search=search) + print("The response of ManagedApi->managed_blueprints_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **path** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedBlueprintInstanceList**](PaginatedBlueprintInstanceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **managed_blueprints_partial_update** +> BlueprintInstance managed_blueprints_partial_update(instance_uuid, patched_blueprint_instance_request=patched_blueprint_instance_request) + +Blueprint instances + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.blueprint_instance import BlueprintInstance +from authentik_client.models.patched_blueprint_instance_request import PatchedBlueprintInstanceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + instance_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Blueprint Instance. + patched_blueprint_instance_request = authentik_client.PatchedBlueprintInstanceRequest() # PatchedBlueprintInstanceRequest | (optional) + + try: + api_response = api_instance.managed_blueprints_partial_update(instance_uuid, patched_blueprint_instance_request=patched_blueprint_instance_request) + print("The response of ManagedApi->managed_blueprints_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **instance_uuid** | **UUID**| A UUID string identifying this Blueprint Instance. | + **patched_blueprint_instance_request** | [**PatchedBlueprintInstanceRequest**](PatchedBlueprintInstanceRequest.md)| | [optional] + +### Return type + +[**BlueprintInstance**](BlueprintInstance.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **managed_blueprints_retrieve** +> BlueprintInstance managed_blueprints_retrieve(instance_uuid) + +Blueprint instances + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.blueprint_instance import BlueprintInstance +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + instance_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Blueprint Instance. + + try: + api_response = api_instance.managed_blueprints_retrieve(instance_uuid) + print("The response of ManagedApi->managed_blueprints_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **instance_uuid** | **UUID**| A UUID string identifying this Blueprint Instance. | + +### Return type + +[**BlueprintInstance**](BlueprintInstance.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **managed_blueprints_update** +> BlueprintInstance managed_blueprints_update(instance_uuid, blueprint_instance_request) + +Blueprint instances + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.blueprint_instance import BlueprintInstance +from authentik_client.models.blueprint_instance_request import BlueprintInstanceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + instance_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Blueprint Instance. + blueprint_instance_request = authentik_client.BlueprintInstanceRequest() # BlueprintInstanceRequest | + + try: + api_response = api_instance.managed_blueprints_update(instance_uuid, blueprint_instance_request) + print("The response of ManagedApi->managed_blueprints_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **instance_uuid** | **UUID**| A UUID string identifying this Blueprint Instance. | + **blueprint_instance_request** | [**BlueprintInstanceRequest**](BlueprintInstanceRequest.md)| | + +### Return type + +[**BlueprintInstance**](BlueprintInstance.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **managed_blueprints_used_by_list** +> List[UsedBy] managed_blueprints_used_by_list(instance_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ManagedApi(api_client) + instance_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Blueprint Instance. + + try: + api_response = api_instance.managed_blueprints_used_by_list(instance_uuid) + print("The response of ManagedApi->managed_blueprints_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ManagedApi->managed_blueprints_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **instance_uuid** | **UUID**| A UUID string identifying this Blueprint Instance. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/MatchingModeEnum.md b/docs/MatchingModeEnum.md new file mode 100644 index 000000000..832b5eec0 --- /dev/null +++ b/docs/MatchingModeEnum.md @@ -0,0 +1,12 @@ +# MatchingModeEnum + + +## Enum + +* `STRICT` (value: `'strict'`) + +* `REGEX` (value: `'regex'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Metadata.md b/docs/Metadata.md new file mode 100644 index 000000000..8f9769ce7 --- /dev/null +++ b/docs/Metadata.md @@ -0,0 +1,31 @@ +# Metadata + +Serializer for blueprint metadata + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**labels** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.metadata import Metadata + +# TODO update the JSON string below +json = "{}" +# create an instance of Metadata from a JSON string +metadata_instance = Metadata.from_json(json) +# print the JSON string representation of the object +print(Metadata.to_json()) + +# convert the object into a dict +metadata_dict = metadata_instance.to_dict() +# create an instance of Metadata from a dict +metadata_from_dict = Metadata.from_dict(metadata_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MicrosoftEntraProvider.md b/docs/MicrosoftEntraProvider.md new file mode 100644 index 000000000..d07cae55b --- /dev/null +++ b/docs/MicrosoftEntraProvider.md @@ -0,0 +1,48 @@ +# MicrosoftEntraProvider + +MicrosoftEntraProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**client_id** | **str** | | +**tenant_id** | **str** | | +**exclude_users_service_account** | **bool** | | [optional] +**filter_group** | **UUID** | | [optional] +**user_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**group_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] + +## Example + +```python +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of MicrosoftEntraProvider from a JSON string +microsoft_entra_provider_instance = MicrosoftEntraProvider.from_json(json) +# print the JSON string representation of the object +print(MicrosoftEntraProvider.to_json()) + +# convert the object into a dict +microsoft_entra_provider_dict = microsoft_entra_provider_instance.to_dict() +# create an instance of MicrosoftEntraProvider from a dict +microsoft_entra_provider_from_dict = MicrosoftEntraProvider.from_dict(microsoft_entra_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MicrosoftEntraProviderGroup.md b/docs/MicrosoftEntraProviderGroup.md new file mode 100644 index 000000000..65fb7e0b3 --- /dev/null +++ b/docs/MicrosoftEntraProviderGroup.md @@ -0,0 +1,35 @@ +# MicrosoftEntraProviderGroup + +MicrosoftEntraProviderGroup Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**microsoft_id** | **str** | | +**group** | **UUID** | | +**group_obj** | [**PartialGroup**](PartialGroup.md) | | [readonly] +**provider** | **int** | | +**attributes** | **Dict[str, object]** | | [readonly] + +## Example + +```python +from authentik_client.models.microsoft_entra_provider_group import MicrosoftEntraProviderGroup + +# TODO update the JSON string below +json = "{}" +# create an instance of MicrosoftEntraProviderGroup from a JSON string +microsoft_entra_provider_group_instance = MicrosoftEntraProviderGroup.from_json(json) +# print the JSON string representation of the object +print(MicrosoftEntraProviderGroup.to_json()) + +# convert the object into a dict +microsoft_entra_provider_group_dict = microsoft_entra_provider_group_instance.to_dict() +# create an instance of MicrosoftEntraProviderGroup from a dict +microsoft_entra_provider_group_from_dict = MicrosoftEntraProviderGroup.from_dict(microsoft_entra_provider_group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MicrosoftEntraProviderGroupRequest.md b/docs/MicrosoftEntraProviderGroupRequest.md new file mode 100644 index 000000000..db8835d93 --- /dev/null +++ b/docs/MicrosoftEntraProviderGroupRequest.md @@ -0,0 +1,32 @@ +# MicrosoftEntraProviderGroupRequest + +MicrosoftEntraProviderGroup Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**microsoft_id** | **str** | | +**group** | **UUID** | | +**provider** | **int** | | + +## Example + +```python +from authentik_client.models.microsoft_entra_provider_group_request import MicrosoftEntraProviderGroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of MicrosoftEntraProviderGroupRequest from a JSON string +microsoft_entra_provider_group_request_instance = MicrosoftEntraProviderGroupRequest.from_json(json) +# print the JSON string representation of the object +print(MicrosoftEntraProviderGroupRequest.to_json()) + +# convert the object into a dict +microsoft_entra_provider_group_request_dict = microsoft_entra_provider_group_request_instance.to_dict() +# create an instance of MicrosoftEntraProviderGroupRequest from a dict +microsoft_entra_provider_group_request_from_dict = MicrosoftEntraProviderGroupRequest.from_dict(microsoft_entra_provider_group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MicrosoftEntraProviderMapping.md b/docs/MicrosoftEntraProviderMapping.md new file mode 100644 index 000000000..35cac3bb0 --- /dev/null +++ b/docs/MicrosoftEntraProviderMapping.md @@ -0,0 +1,37 @@ +# MicrosoftEntraProviderMapping + +MicrosoftEntraProviderMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of MicrosoftEntraProviderMapping from a JSON string +microsoft_entra_provider_mapping_instance = MicrosoftEntraProviderMapping.from_json(json) +# print the JSON string representation of the object +print(MicrosoftEntraProviderMapping.to_json()) + +# convert the object into a dict +microsoft_entra_provider_mapping_dict = microsoft_entra_provider_mapping_instance.to_dict() +# create an instance of MicrosoftEntraProviderMapping from a dict +microsoft_entra_provider_mapping_from_dict = MicrosoftEntraProviderMapping.from_dict(microsoft_entra_provider_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MicrosoftEntraProviderMappingRequest.md b/docs/MicrosoftEntraProviderMappingRequest.md new file mode 100644 index 000000000..208c53645 --- /dev/null +++ b/docs/MicrosoftEntraProviderMappingRequest.md @@ -0,0 +1,32 @@ +# MicrosoftEntraProviderMappingRequest + +MicrosoftEntraProviderMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.microsoft_entra_provider_mapping_request import MicrosoftEntraProviderMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of MicrosoftEntraProviderMappingRequest from a JSON string +microsoft_entra_provider_mapping_request_instance = MicrosoftEntraProviderMappingRequest.from_json(json) +# print the JSON string representation of the object +print(MicrosoftEntraProviderMappingRequest.to_json()) + +# convert the object into a dict +microsoft_entra_provider_mapping_request_dict = microsoft_entra_provider_mapping_request_instance.to_dict() +# create an instance of MicrosoftEntraProviderMappingRequest from a dict +microsoft_entra_provider_mapping_request_from_dict = MicrosoftEntraProviderMappingRequest.from_dict(microsoft_entra_provider_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MicrosoftEntraProviderRequest.md b/docs/MicrosoftEntraProviderRequest.md new file mode 100644 index 000000000..ecd85f08b --- /dev/null +++ b/docs/MicrosoftEntraProviderRequest.md @@ -0,0 +1,42 @@ +# MicrosoftEntraProviderRequest + +MicrosoftEntraProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**client_id** | **str** | | +**client_secret** | **str** | | +**tenant_id** | **str** | | +**exclude_users_service_account** | **bool** | | [optional] +**filter_group** | **UUID** | | [optional] +**user_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**group_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] + +## Example + +```python +from authentik_client.models.microsoft_entra_provider_request import MicrosoftEntraProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of MicrosoftEntraProviderRequest from a JSON string +microsoft_entra_provider_request_instance = MicrosoftEntraProviderRequest.from_json(json) +# print the JSON string representation of the object +print(MicrosoftEntraProviderRequest.to_json()) + +# convert the object into a dict +microsoft_entra_provider_request_dict = microsoft_entra_provider_request_instance.to_dict() +# create an instance of MicrosoftEntraProviderRequest from a dict +microsoft_entra_provider_request_from_dict = MicrosoftEntraProviderRequest.from_dict(microsoft_entra_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MicrosoftEntraProviderUser.md b/docs/MicrosoftEntraProviderUser.md new file mode 100644 index 000000000..ee473127b --- /dev/null +++ b/docs/MicrosoftEntraProviderUser.md @@ -0,0 +1,35 @@ +# MicrosoftEntraProviderUser + +MicrosoftEntraProviderUser Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**microsoft_id** | **str** | | +**user** | **int** | | +**user_obj** | [**PartialUser**](PartialUser.md) | | [readonly] +**provider** | **int** | | +**attributes** | **Dict[str, object]** | | [readonly] + +## Example + +```python +from authentik_client.models.microsoft_entra_provider_user import MicrosoftEntraProviderUser + +# TODO update the JSON string below +json = "{}" +# create an instance of MicrosoftEntraProviderUser from a JSON string +microsoft_entra_provider_user_instance = MicrosoftEntraProviderUser.from_json(json) +# print the JSON string representation of the object +print(MicrosoftEntraProviderUser.to_json()) + +# convert the object into a dict +microsoft_entra_provider_user_dict = microsoft_entra_provider_user_instance.to_dict() +# create an instance of MicrosoftEntraProviderUser from a dict +microsoft_entra_provider_user_from_dict = MicrosoftEntraProviderUser.from_dict(microsoft_entra_provider_user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MicrosoftEntraProviderUserRequest.md b/docs/MicrosoftEntraProviderUserRequest.md new file mode 100644 index 000000000..f6b4e8873 --- /dev/null +++ b/docs/MicrosoftEntraProviderUserRequest.md @@ -0,0 +1,32 @@ +# MicrosoftEntraProviderUserRequest + +MicrosoftEntraProviderUser Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**microsoft_id** | **str** | | +**user** | **int** | | +**provider** | **int** | | + +## Example + +```python +from authentik_client.models.microsoft_entra_provider_user_request import MicrosoftEntraProviderUserRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of MicrosoftEntraProviderUserRequest from a JSON string +microsoft_entra_provider_user_request_instance = MicrosoftEntraProviderUserRequest.from_json(json) +# print the JSON string representation of the object +print(MicrosoftEntraProviderUserRequest.to_json()) + +# convert the object into a dict +microsoft_entra_provider_user_request_dict = microsoft_entra_provider_user_request_instance.to_dict() +# create an instance of MicrosoftEntraProviderUserRequest from a dict +microsoft_entra_provider_user_request_from_dict = MicrosoftEntraProviderUserRequest.from_dict(microsoft_entra_provider_user_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ModelEnum.md b/docs/ModelEnum.md new file mode 100644 index 000000000..6dce90e7a --- /dev/null +++ b/docs/ModelEnum.md @@ -0,0 +1,252 @@ +# ModelEnum + + +## Enum + +* `AUTHENTIK_TENANTS_DOT_DOMAIN` (value: `'authentik_tenants.domain'`) + +* `AUTHENTIK_CORE_DOT_GROUP` (value: `'authentik_core.group'`) + +* `AUTHENTIK_CORE_DOT_USER` (value: `'authentik_core.user'`) + +* `AUTHENTIK_CORE_DOT_APPLICATION` (value: `'authentik_core.application'`) + +* `AUTHENTIK_CORE_DOT_APPLICATIONENTITLEMENT` (value: `'authentik_core.applicationentitlement'`) + +* `AUTHENTIK_CORE_DOT_TOKEN` (value: `'authentik_core.token'`) + +* `AUTHENTIK_CRYPTO_DOT_CERTIFICATEKEYPAIR` (value: `'authentik_crypto.certificatekeypair'`) + +* `AUTHENTIK_ENDPOINTS_DOT_DEVICEUSERBINDING` (value: `'authentik_endpoints.deviceuserbinding'`) + +* `AUTHENTIK_ENDPOINTS_DOT_DEVICEACCESSGROUP` (value: `'authentik_endpoints.deviceaccessgroup'`) + +* `AUTHENTIK_ENDPOINTS_DOT_ENDPOINTSTAGE` (value: `'authentik_endpoints.endpointstage'`) + +* `AUTHENTIK_ENDPOINTS_CONNECTORS_AGENT_DOT_AGENTCONNECTOR` (value: `'authentik_endpoints_connectors_agent.agentconnector'`) + +* `AUTHENTIK_ENDPOINTS_CONNECTORS_AGENT_DOT_AGENTDEVICEUSERBINDING` (value: `'authentik_endpoints_connectors_agent.agentdeviceuserbinding'`) + +* `AUTHENTIK_ENDPOINTS_CONNECTORS_AGENT_DOT_ENROLLMENTTOKEN` (value: `'authentik_endpoints_connectors_agent.enrollmenttoken'`) + +* `AUTHENTIK_ENTERPRISE_DOT_LICENSE` (value: `'authentik_enterprise.license'`) + +* `AUTHENTIK_EVENTS_DOT_EVENT` (value: `'authentik_events.event'`) + +* `AUTHENTIK_EVENTS_DOT_NOTIFICATIONTRANSPORT` (value: `'authentik_events.notificationtransport'`) + +* `AUTHENTIK_EVENTS_DOT_NOTIFICATION` (value: `'authentik_events.notification'`) + +* `AUTHENTIK_EVENTS_DOT_NOTIFICATIONRULE` (value: `'authentik_events.notificationrule'`) + +* `AUTHENTIK_EVENTS_DOT_NOTIFICATIONWEBHOOKMAPPING` (value: `'authentik_events.notificationwebhookmapping'`) + +* `AUTHENTIK_FLOWS_DOT_FLOW` (value: `'authentik_flows.flow'`) + +* `AUTHENTIK_FLOWS_DOT_FLOWSTAGEBINDING` (value: `'authentik_flows.flowstagebinding'`) + +* `AUTHENTIK_OUTPOSTS_DOT_DOCKERSERVICECONNECTION` (value: `'authentik_outposts.dockerserviceconnection'`) + +* `AUTHENTIK_OUTPOSTS_DOT_KUBERNETESSERVICECONNECTION` (value: `'authentik_outposts.kubernetesserviceconnection'`) + +* `AUTHENTIK_OUTPOSTS_DOT_OUTPOST` (value: `'authentik_outposts.outpost'`) + +* `AUTHENTIK_POLICIES_DUMMY_DOT_DUMMYPOLICY` (value: `'authentik_policies_dummy.dummypolicy'`) + +* `AUTHENTIK_POLICIES_EVENT_MATCHER_DOT_EVENTMATCHERPOLICY` (value: `'authentik_policies_event_matcher.eventmatcherpolicy'`) + +* `AUTHENTIK_POLICIES_EXPIRY_DOT_PASSWORDEXPIRYPOLICY` (value: `'authentik_policies_expiry.passwordexpirypolicy'`) + +* `AUTHENTIK_POLICIES_EXPRESSION_DOT_EXPRESSIONPOLICY` (value: `'authentik_policies_expression.expressionpolicy'`) + +* `AUTHENTIK_POLICIES_GEOIP_DOT_GEOIPPOLICY` (value: `'authentik_policies_geoip.geoippolicy'`) + +* `AUTHENTIK_POLICIES_PASSWORD_DOT_PASSWORDPOLICY` (value: `'authentik_policies_password.passwordpolicy'`) + +* `AUTHENTIK_POLICIES_REPUTATION_DOT_REPUTATIONPOLICY` (value: `'authentik_policies_reputation.reputationpolicy'`) + +* `AUTHENTIK_POLICIES_DOT_POLICYBINDING` (value: `'authentik_policies.policybinding'`) + +* `AUTHENTIK_PROVIDERS_LDAP_DOT_LDAPPROVIDER` (value: `'authentik_providers_ldap.ldapprovider'`) + +* `AUTHENTIK_PROVIDERS_OAUTH2_DOT_SCOPEMAPPING` (value: `'authentik_providers_oauth2.scopemapping'`) + +* `AUTHENTIK_PROVIDERS_OAUTH2_DOT_OAUTH2PROVIDER` (value: `'authentik_providers_oauth2.oauth2provider'`) + +* `AUTHENTIK_PROVIDERS_PROXY_DOT_PROXYPROVIDER` (value: `'authentik_providers_proxy.proxyprovider'`) + +* `AUTHENTIK_PROVIDERS_RAC_DOT_RACPROVIDER` (value: `'authentik_providers_rac.racprovider'`) + +* `AUTHENTIK_PROVIDERS_RAC_DOT_ENDPOINT` (value: `'authentik_providers_rac.endpoint'`) + +* `AUTHENTIK_PROVIDERS_RAC_DOT_RACPROPERTYMAPPING` (value: `'authentik_providers_rac.racpropertymapping'`) + +* `AUTHENTIK_PROVIDERS_RADIUS_DOT_RADIUSPROVIDER` (value: `'authentik_providers_radius.radiusprovider'`) + +* `AUTHENTIK_PROVIDERS_RADIUS_DOT_RADIUSPROVIDERPROPERTYMAPPING` (value: `'authentik_providers_radius.radiusproviderpropertymapping'`) + +* `AUTHENTIK_PROVIDERS_SAML_DOT_SAMLPROVIDER` (value: `'authentik_providers_saml.samlprovider'`) + +* `AUTHENTIK_PROVIDERS_SAML_DOT_SAMLPROPERTYMAPPING` (value: `'authentik_providers_saml.samlpropertymapping'`) + +* `AUTHENTIK_PROVIDERS_SCIM_DOT_SCIMPROVIDER` (value: `'authentik_providers_scim.scimprovider'`) + +* `AUTHENTIK_PROVIDERS_SCIM_DOT_SCIMMAPPING` (value: `'authentik_providers_scim.scimmapping'`) + +* `AUTHENTIK_RBAC_DOT_ROLE` (value: `'authentik_rbac.role'`) + +* `AUTHENTIK_RBAC_DOT_INITIALPERMISSIONS` (value: `'authentik_rbac.initialpermissions'`) + +* `AUTHENTIK_SOURCES_KERBEROS_DOT_KERBEROSSOURCE` (value: `'authentik_sources_kerberos.kerberossource'`) + +* `AUTHENTIK_SOURCES_KERBEROS_DOT_KERBEROSSOURCEPROPERTYMAPPING` (value: `'authentik_sources_kerberos.kerberossourcepropertymapping'`) + +* `AUTHENTIK_SOURCES_KERBEROS_DOT_USERKERBEROSSOURCECONNECTION` (value: `'authentik_sources_kerberos.userkerberossourceconnection'`) + +* `AUTHENTIK_SOURCES_KERBEROS_DOT_GROUPKERBEROSSOURCECONNECTION` (value: `'authentik_sources_kerberos.groupkerberossourceconnection'`) + +* `AUTHENTIK_SOURCES_LDAP_DOT_LDAPSOURCE` (value: `'authentik_sources_ldap.ldapsource'`) + +* `AUTHENTIK_SOURCES_LDAP_DOT_LDAPSOURCEPROPERTYMAPPING` (value: `'authentik_sources_ldap.ldapsourcepropertymapping'`) + +* `AUTHENTIK_SOURCES_LDAP_DOT_USERLDAPSOURCECONNECTION` (value: `'authentik_sources_ldap.userldapsourceconnection'`) + +* `AUTHENTIK_SOURCES_LDAP_DOT_GROUPLDAPSOURCECONNECTION` (value: `'authentik_sources_ldap.groupldapsourceconnection'`) + +* `AUTHENTIK_SOURCES_OAUTH_DOT_OAUTHSOURCE` (value: `'authentik_sources_oauth.oauthsource'`) + +* `AUTHENTIK_SOURCES_OAUTH_DOT_OAUTHSOURCEPROPERTYMAPPING` (value: `'authentik_sources_oauth.oauthsourcepropertymapping'`) + +* `AUTHENTIK_SOURCES_OAUTH_DOT_USEROAUTHSOURCECONNECTION` (value: `'authentik_sources_oauth.useroauthsourceconnection'`) + +* `AUTHENTIK_SOURCES_OAUTH_DOT_GROUPOAUTHSOURCECONNECTION` (value: `'authentik_sources_oauth.groupoauthsourceconnection'`) + +* `AUTHENTIK_SOURCES_PLEX_DOT_PLEXSOURCE` (value: `'authentik_sources_plex.plexsource'`) + +* `AUTHENTIK_SOURCES_PLEX_DOT_PLEXSOURCEPROPERTYMAPPING` (value: `'authentik_sources_plex.plexsourcepropertymapping'`) + +* `AUTHENTIK_SOURCES_PLEX_DOT_USERPLEXSOURCECONNECTION` (value: `'authentik_sources_plex.userplexsourceconnection'`) + +* `AUTHENTIK_SOURCES_PLEX_DOT_GROUPPLEXSOURCECONNECTION` (value: `'authentik_sources_plex.groupplexsourceconnection'`) + +* `AUTHENTIK_SOURCES_SAML_DOT_SAMLSOURCE` (value: `'authentik_sources_saml.samlsource'`) + +* `AUTHENTIK_SOURCES_SAML_DOT_SAMLSOURCEPROPERTYMAPPING` (value: `'authentik_sources_saml.samlsourcepropertymapping'`) + +* `AUTHENTIK_SOURCES_SAML_DOT_USERSAMLSOURCECONNECTION` (value: `'authentik_sources_saml.usersamlsourceconnection'`) + +* `AUTHENTIK_SOURCES_SAML_DOT_GROUPSAMLSOURCECONNECTION` (value: `'authentik_sources_saml.groupsamlsourceconnection'`) + +* `AUTHENTIK_SOURCES_SCIM_DOT_SCIMSOURCE` (value: `'authentik_sources_scim.scimsource'`) + +* `AUTHENTIK_SOURCES_SCIM_DOT_SCIMSOURCEPROPERTYMAPPING` (value: `'authentik_sources_scim.scimsourcepropertymapping'`) + +* `AUTHENTIK_SOURCES_TELEGRAM_DOT_TELEGRAMSOURCE` (value: `'authentik_sources_telegram.telegramsource'`) + +* `AUTHENTIK_SOURCES_TELEGRAM_DOT_TELEGRAMSOURCEPROPERTYMAPPING` (value: `'authentik_sources_telegram.telegramsourcepropertymapping'`) + +* `AUTHENTIK_SOURCES_TELEGRAM_DOT_USERTELEGRAMSOURCECONNECTION` (value: `'authentik_sources_telegram.usertelegramsourceconnection'`) + +* `AUTHENTIK_SOURCES_TELEGRAM_DOT_GROUPTELEGRAMSOURCECONNECTION` (value: `'authentik_sources_telegram.grouptelegramsourceconnection'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_DUO_DOT_AUTHENTICATORDUOSTAGE` (value: `'authentik_stages_authenticator_duo.authenticatorduostage'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_DUO_DOT_DUODEVICE` (value: `'authentik_stages_authenticator_duo.duodevice'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_EMAIL_DOT_AUTHENTICATOREMAILSTAGE` (value: `'authentik_stages_authenticator_email.authenticatoremailstage'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_EMAIL_DOT_EMAILDEVICE` (value: `'authentik_stages_authenticator_email.emaildevice'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_SMS_DOT_AUTHENTICATORSMSSTAGE` (value: `'authentik_stages_authenticator_sms.authenticatorsmsstage'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_SMS_DOT_SMSDEVICE` (value: `'authentik_stages_authenticator_sms.smsdevice'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_STATIC_DOT_AUTHENTICATORSTATICSTAGE` (value: `'authentik_stages_authenticator_static.authenticatorstaticstage'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_STATIC_DOT_STATICDEVICE` (value: `'authentik_stages_authenticator_static.staticdevice'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_TOTP_DOT_AUTHENTICATORTOTPSTAGE` (value: `'authentik_stages_authenticator_totp.authenticatortotpstage'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_TOTP_DOT_TOTPDEVICE` (value: `'authentik_stages_authenticator_totp.totpdevice'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_VALIDATE_DOT_AUTHENTICATORVALIDATESTAGE` (value: `'authentik_stages_authenticator_validate.authenticatorvalidatestage'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_WEBAUTHN_DOT_AUTHENTICATORWEBAUTHNSTAGE` (value: `'authentik_stages_authenticator_webauthn.authenticatorwebauthnstage'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_WEBAUTHN_DOT_WEBAUTHNDEVICE` (value: `'authentik_stages_authenticator_webauthn.webauthndevice'`) + +* `AUTHENTIK_STAGES_CAPTCHA_DOT_CAPTCHASTAGE` (value: `'authentik_stages_captcha.captchastage'`) + +* `AUTHENTIK_STAGES_CONSENT_DOT_CONSENTSTAGE` (value: `'authentik_stages_consent.consentstage'`) + +* `AUTHENTIK_STAGES_DENY_DOT_DENYSTAGE` (value: `'authentik_stages_deny.denystage'`) + +* `AUTHENTIK_STAGES_DUMMY_DOT_DUMMYSTAGE` (value: `'authentik_stages_dummy.dummystage'`) + +* `AUTHENTIK_STAGES_EMAIL_DOT_EMAILSTAGE` (value: `'authentik_stages_email.emailstage'`) + +* `AUTHENTIK_STAGES_IDENTIFICATION_DOT_IDENTIFICATIONSTAGE` (value: `'authentik_stages_identification.identificationstage'`) + +* `AUTHENTIK_STAGES_INVITATION_DOT_INVITATIONSTAGE` (value: `'authentik_stages_invitation.invitationstage'`) + +* `AUTHENTIK_STAGES_INVITATION_DOT_INVITATION` (value: `'authentik_stages_invitation.invitation'`) + +* `AUTHENTIK_STAGES_PASSWORD_DOT_PASSWORDSTAGE` (value: `'authentik_stages_password.passwordstage'`) + +* `AUTHENTIK_STAGES_PROMPT_DOT_PROMPT` (value: `'authentik_stages_prompt.prompt'`) + +* `AUTHENTIK_STAGES_PROMPT_DOT_PROMPTSTAGE` (value: `'authentik_stages_prompt.promptstage'`) + +* `AUTHENTIK_STAGES_REDIRECT_DOT_REDIRECTSTAGE` (value: `'authentik_stages_redirect.redirectstage'`) + +* `AUTHENTIK_STAGES_USER_DELETE_DOT_USERDELETESTAGE` (value: `'authentik_stages_user_delete.userdeletestage'`) + +* `AUTHENTIK_STAGES_USER_LOGIN_DOT_USERLOGINSTAGE` (value: `'authentik_stages_user_login.userloginstage'`) + +* `AUTHENTIK_STAGES_USER_LOGOUT_DOT_USERLOGOUTSTAGE` (value: `'authentik_stages_user_logout.userlogoutstage'`) + +* `AUTHENTIK_STAGES_USER_WRITE_DOT_USERWRITESTAGE` (value: `'authentik_stages_user_write.userwritestage'`) + +* `AUTHENTIK_TASKS_SCHEDULES_DOT_SCHEDULE` (value: `'authentik_tasks_schedules.schedule'`) + +* `AUTHENTIK_BRANDS_DOT_BRAND` (value: `'authentik_brands.brand'`) + +* `AUTHENTIK_BLUEPRINTS_DOT_BLUEPRINTINSTANCE` (value: `'authentik_blueprints.blueprintinstance'`) + +* `AUTHENTIK_ENDPOINTS_CONNECTORS_FLEET_DOT_FLEETCONNECTOR` (value: `'authentik_endpoints_connectors_fleet.fleetconnector'`) + +* `AUTHENTIK_ENDPOINTS_CONNECTORS_GOOGLE_CHROME_DOT_GOOGLECHROMECONNECTOR` (value: `'authentik_endpoints_connectors_google_chrome.googlechromeconnector'`) + +* `AUTHENTIK_LIFECYCLE_DOT_LIFECYCLERULE` (value: `'authentik_lifecycle.lifecyclerule'`) + +* `AUTHENTIK_LIFECYCLE_DOT_LIFECYCLEITERATION` (value: `'authentik_lifecycle.lifecycleiteration'`) + +* `AUTHENTIK_LIFECYCLE_DOT_REVIEW` (value: `'authentik_lifecycle.review'`) + +* `AUTHENTIK_POLICIES_UNIQUE_PASSWORD_DOT_UNIQUEPASSWORDPOLICY` (value: `'authentik_policies_unique_password.uniquepasswordpolicy'`) + +* `AUTHENTIK_PROVIDERS_GOOGLE_WORKSPACE_DOT_GOOGLEWORKSPACEPROVIDER` (value: `'authentik_providers_google_workspace.googleworkspaceprovider'`) + +* `AUTHENTIK_PROVIDERS_GOOGLE_WORKSPACE_DOT_GOOGLEWORKSPACEPROVIDERMAPPING` (value: `'authentik_providers_google_workspace.googleworkspaceprovidermapping'`) + +* `AUTHENTIK_PROVIDERS_MICROSOFT_ENTRA_DOT_MICROSOFTENTRAPROVIDER` (value: `'authentik_providers_microsoft_entra.microsoftentraprovider'`) + +* `AUTHENTIK_PROVIDERS_MICROSOFT_ENTRA_DOT_MICROSOFTENTRAPROVIDERMAPPING` (value: `'authentik_providers_microsoft_entra.microsoftentraprovidermapping'`) + +* `AUTHENTIK_PROVIDERS_SSF_DOT_SSFPROVIDER` (value: `'authentik_providers_ssf.ssfprovider'`) + +* `AUTHENTIK_PROVIDERS_WS_FEDERATION_DOT_WSFEDERATIONPROVIDER` (value: `'authentik_providers_ws_federation.wsfederationprovider'`) + +* `AUTHENTIK_REPORTS_DOT_DATAEXPORT` (value: `'authentik_reports.dataexport'`) + +* `AUTHENTIK_STAGES_ACCOUNT_LOCKDOWN_DOT_ACCOUNTLOCKDOWNSTAGE` (value: `'authentik_stages_account_lockdown.accountlockdownstage'`) + +* `AUTHENTIK_STAGES_AUTHENTICATOR_ENDPOINT_GDTC_DOT_AUTHENTICATORENDPOINTGDTCSTAGE` (value: `'authentik_stages_authenticator_endpoint_gdtc.authenticatorendpointgdtcstage'`) + +* `AUTHENTIK_STAGES_MTLS_DOT_MUTUALTLSSTAGE` (value: `'authentik_stages_mtls.mutualtlsstage'`) + +* `AUTHENTIK_STAGES_SOURCE_DOT_SOURCESTAGE` (value: `'authentik_stages_source.sourcestage'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ModelRequest.md b/docs/ModelRequest.md new file mode 100644 index 000000000..c56aa9c3a --- /dev/null +++ b/docs/ModelRequest.md @@ -0,0 +1,123 @@ +# ModelRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**delegated_subject** | **str** | | +**credentials** | **Dict[str, object]** | | +**scopes** | **str** | | [optional] +**exclude_users_service_account** | **bool** | | [optional] +**filter_group** | **UUID** | | [optional] +**user_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**group_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**default_group_email_domain** | **str** | | +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**base_dn** | **str** | DN under which objects are accessible. | [optional] +**certificate** | **UUID** | | [optional] +**tls_server_name** | **str** | | [optional] +**uid_start_number** | **int** | The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber | [optional] +**gid_start_number** | **int** | The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber | [optional] +**search_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**bind_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**mfa_support** | **bool** | When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon. | [optional] +**client_id** | **str** | | +**client_secret** | **str** | | +**tenant_id** | **str** | | +**client_type** | [**ClientTypeEnum**](ClientTypeEnum.md) | Confidential clients are capable of maintaining the confidentiality of their credentials. Public clients are incapable | [optional] +**grant_types** | [**List[GrantTypesEnum]**](GrantTypesEnum.md) | | [optional] +**access_code_validity** | **str** | Access codes not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**access_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_threshold** | **str** | When refreshing a token, if the refresh token is valid for less than this duration, it will be renewed. When set to seconds=0, token will always be renewed. (Format: hours=1;minutes=2;seconds=3). | [optional] +**include_claims_in_id_token** | **bool** | Include User claims from scopes in the id_token, for applications that don't access the userinfo endpoint. | [optional] +**signing_key** | **UUID** | Key used to sign the SSF Events. | +**encryption_key** | **UUID** | Key used to encrypt the tokens. When set, tokens will be encrypted and returned as JWEs. | [optional] +**redirect_uris** | [**List[RedirectURIRequest]**](RedirectURIRequest.md) | | +**logout_uri** | **str** | | [optional] +**logout_method** | [**SAMLLogoutMethods**](SAMLLogoutMethods.md) | Method to use for logout. Front-channel iframe loads all logout URLs simultaneously in hidden iframes. Front-channel native uses your active browser tab to send post requests and redirect to providers. Back-channel sends logout requests directly from the server without user interaction (requires POST SLS binding). | [optional] +**sub_mode** | [**SubModeEnum**](SubModeEnum.md) | Configure what data should be used as unique User Identifier. For most cases, the default should be fine. | [optional] +**issuer_mode** | [**IssuerModeEnum**](IssuerModeEnum.md) | Configure how the issuer field of the ID Token should be filled. | [optional] +**jwt_federation_sources** | **List[UUID]** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] +**internal_host** | **str** | | [optional] +**external_host** | **str** | | +**internal_host_ssl_validation** | **bool** | Validate SSL Certificates of upstream servers | [optional] +**skip_path_regex** | **str** | Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression. | [optional] +**basic_auth_enabled** | **bool** | Set a custom HTTP-Basic Authentication header based on values from authentik. | [optional] +**basic_auth_password_attribute** | **str** | User/Group Attribute used for the password part of the HTTP-Basic Header. | [optional] +**basic_auth_user_attribute** | **str** | User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used. | [optional] +**mode** | [**ProxyMode**](ProxyMode.md) | Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host. | [optional] +**intercept_header_auth** | **bool** | When enabled, this provider will intercept the authorization header and authenticate requests based on its value. | [optional] +**cookie_domain** | **str** | | [optional] +**settings** | **Dict[str, object]** | | [optional] +**connection_expiry** | **str** | Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**delete_token_on_disconnect** | **bool** | When set to true, connection tokens will be deleted upon disconnect. | [optional] +**client_networks** | **str** | List of CIDRs (comma-separated) that clients can connect from. A more specific CIDR will match before a looser one. Clients connecting from a non-specified CIDR will be dropped. | [optional] +**shared_secret** | **str** | Shared secret between clients and server to hash packets. | [optional] +**acs_url** | **str** | | +**sls_url** | **str** | Single Logout Service URL where the logout response should be sent. | [optional] +**audience** | **str** | Value of the audience restriction field of the assertion. When left empty, no audience restriction will be added. | [optional] +**issuer_override** | **str** | Also known as EntityID. Providing a value overrides the default issuer generated by authentik. | [optional] +**assertion_valid_not_before** | **str** | Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3). | [optional] +**assertion_valid_not_on_or_after** | **str** | Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**session_valid_not_on_or_after** | **str** | Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**name_id_mapping** | **UUID** | Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered | [optional] +**authn_context_class_ref_mapping** | **UUID** | Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Service Provider. | [optional] +**verification_kp** | **UUID** | When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default. | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**sign_assertion** | **bool** | | [optional] +**sign_response** | **bool** | | [optional] +**sign_logout_request** | **bool** | | [optional] +**sign_logout_response** | **bool** | | [optional] +**sp_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | This determines how authentik sends the response back to the Service Provider. | [optional] +**sls_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | This determines how authentik sends the logout response back to the Service Provider. | [optional] +**default_relay_state** | **str** | Default relay_state value for IDP-initiated logins | [optional] +**default_name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | | [optional] +**url** | **str** | Base URL to SCIM requests, usually ends in /v2 | +**verify_certificates** | **bool** | | [optional] +**token** | **str** | Authentication token | [optional] +**auth_mode** | [**SCIMAuthenticationModeEnum**](SCIMAuthenticationModeEnum.md) | | [optional] +**auth_oauth** | **UUID** | OAuth Source used for authentication | [optional] +**auth_oauth_params** | **Dict[str, object]** | Additional OAuth parameters, such as grant_type | [optional] +**compatibility_mode** | [**CompatibilityModeEnum**](CompatibilityModeEnum.md) | Alter authentik behavior for vendor-specific SCIM implementations. | [optional] +**service_provider_config_cache_timeout** | **str** | Cache duration for ServiceProviderConfig responses. Set minutes=0 to disable. | [optional] +**group_filters** | **List[UUID]** | Group filters used to define sync-scope for groups. | [optional] +**oidc_auth_providers** | **List[int]** | | [optional] +**event_retention** | **str** | | [optional] +**push_verify_certificates** | **bool** | | [optional] +**reply_url** | **str** | | +**wtrealm** | **str** | | + +## Example + +```python +from authentik_client.models.model_request import ModelRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ModelRequest from a JSON string +model_request_instance = ModelRequest.from_json(json) +# print the JSON string representation of the object +print(ModelRequest.to_json()) + +# convert the object into a dict +model_request_dict = model_request_instance.to_dict() +# create an instance of ModelRequest from a dict +model_request_from_dict = ModelRequest.from_dict(model_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MutualTLSStage.md b/docs/MutualTLSStage.md new file mode 100644 index 000000000..5abd15388 --- /dev/null +++ b/docs/MutualTLSStage.md @@ -0,0 +1,40 @@ +# MutualTLSStage + +MutualTLSStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**mode** | [**StageModeEnum**](StageModeEnum.md) | | +**certificate_authorities** | **List[UUID]** | Configure certificate authorities to validate the certificate against. This option has a higher priority than the `client_certificate` option on `Brand`. | [optional] +**cert_attribute** | [**CertAttributeEnum**](CertAttributeEnum.md) | | +**user_attribute** | [**UserAttributeEnum**](UserAttributeEnum.md) | | + +## Example + +```python +from authentik_client.models.mutual_tls_stage import MutualTLSStage + +# TODO update the JSON string below +json = "{}" +# create an instance of MutualTLSStage from a JSON string +mutual_tls_stage_instance = MutualTLSStage.from_json(json) +# print the JSON string representation of the object +print(MutualTLSStage.to_json()) + +# convert the object into a dict +mutual_tls_stage_dict = mutual_tls_stage_instance.to_dict() +# create an instance of MutualTLSStage from a dict +mutual_tls_stage_from_dict = MutualTLSStage.from_dict(mutual_tls_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/MutualTLSStageRequest.md b/docs/MutualTLSStageRequest.md new file mode 100644 index 000000000..6118d0627 --- /dev/null +++ b/docs/MutualTLSStageRequest.md @@ -0,0 +1,34 @@ +# MutualTLSStageRequest + +MutualTLSStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**mode** | [**StageModeEnum**](StageModeEnum.md) | | +**certificate_authorities** | **List[UUID]** | Configure certificate authorities to validate the certificate against. This option has a higher priority than the `client_certificate` option on `Brand`. | [optional] +**cert_attribute** | [**CertAttributeEnum**](CertAttributeEnum.md) | | +**user_attribute** | [**UserAttributeEnum**](UserAttributeEnum.md) | | + +## Example + +```python +from authentik_client.models.mutual_tls_stage_request import MutualTLSStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of MutualTLSStageRequest from a JSON string +mutual_tls_stage_request_instance = MutualTLSStageRequest.from_json(json) +# print the JSON string representation of the object +print(MutualTLSStageRequest.to_json()) + +# convert the object into a dict +mutual_tls_stage_request_dict = mutual_tls_stage_request_instance.to_dict() +# create an instance of MutualTLSStageRequest from a dict +mutual_tls_stage_request_from_dict = MutualTLSStageRequest.from_dict(mutual_tls_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NativeLogoutChallenge.md b/docs/NativeLogoutChallenge.md new file mode 100644 index 000000000..39c1f9c63 --- /dev/null +++ b/docs/NativeLogoutChallenge.md @@ -0,0 +1,40 @@ +# NativeLogoutChallenge + +Challenge for native browser logout + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-provider-saml-native-logout'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**provider_name** | **str** | | [optional] +**is_complete** | **bool** | | [optional] [default to False] +**post_url** | **str** | | [optional] +**redirect_url** | **str** | | [optional] +**saml_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | | [optional] +**saml_request** | **str** | | [optional] +**saml_response** | **str** | | [optional] +**saml_relay_state** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.native_logout_challenge import NativeLogoutChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of NativeLogoutChallenge from a JSON string +native_logout_challenge_instance = NativeLogoutChallenge.from_json(json) +# print the JSON string representation of the object +print(NativeLogoutChallenge.to_json()) + +# convert the object into a dict +native_logout_challenge_dict = native_logout_challenge_instance.to_dict() +# create an instance of NativeLogoutChallenge from a dict +native_logout_challenge_from_dict = NativeLogoutChallenge.from_dict(native_logout_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NativeLogoutChallengeResponseRequest.md b/docs/NativeLogoutChallengeResponseRequest.md new file mode 100644 index 000000000..a856085cf --- /dev/null +++ b/docs/NativeLogoutChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# NativeLogoutChallengeResponseRequest + +Response for native browser logout + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-provider-saml-native-logout'] + +## Example + +```python +from authentik_client.models.native_logout_challenge_response_request import NativeLogoutChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of NativeLogoutChallengeResponseRequest from a JSON string +native_logout_challenge_response_request_instance = NativeLogoutChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(NativeLogoutChallengeResponseRequest.to_json()) + +# convert the object into a dict +native_logout_challenge_response_request_dict = native_logout_challenge_response_request_instance.to_dict() +# create an instance of NativeLogoutChallengeResponseRequest from a dict +native_logout_challenge_response_request_from_dict = NativeLogoutChallengeResponseRequest.from_dict(native_logout_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Network.md b/docs/Network.md new file mode 100644 index 000000000..01d5fa170 --- /dev/null +++ b/docs/Network.md @@ -0,0 +1,32 @@ +# Network + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**hostname** | **str** | | +**firewall_enabled** | **bool** | | [optional] +**interfaces** | [**List[NetworkInterface]**](NetworkInterface.md) | | +**gateway** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.network import Network + +# TODO update the JSON string below +json = "{}" +# create an instance of Network from a JSON string +network_instance = Network.from_json(json) +# print the JSON string representation of the object +print(Network.to_json()) + +# convert the object into a dict +network_dict = network_instance.to_dict() +# create an instance of Network from a dict +network_from_dict = Network.from_dict(network_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NetworkBindingEnum.md b/docs/NetworkBindingEnum.md new file mode 100644 index 000000000..378c9d53a --- /dev/null +++ b/docs/NetworkBindingEnum.md @@ -0,0 +1,16 @@ +# NetworkBindingEnum + + +## Enum + +* `NO_BINDING` (value: `'no_binding'`) + +* `BIND_ASN` (value: `'bind_asn'`) + +* `BIND_ASN_NETWORK` (value: `'bind_asn_network'`) + +* `BIND_ASN_NETWORK_IP` (value: `'bind_asn_network_ip'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NetworkInterface.md b/docs/NetworkInterface.md new file mode 100644 index 000000000..34a60478c --- /dev/null +++ b/docs/NetworkInterface.md @@ -0,0 +1,32 @@ +# NetworkInterface + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**hardware_address** | **str** | | +**ip_addresses** | **List[str]** | | [optional] +**dns_servers** | **List[str]** | | [optional] + +## Example + +```python +from authentik_client.models.network_interface import NetworkInterface + +# TODO update the JSON string below +json = "{}" +# create an instance of NetworkInterface from a JSON string +network_interface_instance = NetworkInterface.from_json(json) +# print the JSON string representation of the object +print(NetworkInterface.to_json()) + +# convert the object into a dict +network_interface_dict = network_interface_instance.to_dict() +# create an instance of NetworkInterface from a dict +network_interface_from_dict = NetworkInterface.from_dict(network_interface_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NetworkInterfaceRequest.md b/docs/NetworkInterfaceRequest.md new file mode 100644 index 000000000..bfcdf66bc --- /dev/null +++ b/docs/NetworkInterfaceRequest.md @@ -0,0 +1,32 @@ +# NetworkInterfaceRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**hardware_address** | **str** | | +**ip_addresses** | **List[str]** | | [optional] +**dns_servers** | **List[str]** | | [optional] + +## Example + +```python +from authentik_client.models.network_interface_request import NetworkInterfaceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of NetworkInterfaceRequest from a JSON string +network_interface_request_instance = NetworkInterfaceRequest.from_json(json) +# print the JSON string representation of the object +print(NetworkInterfaceRequest.to_json()) + +# convert the object into a dict +network_interface_request_dict = network_interface_request_instance.to_dict() +# create an instance of NetworkInterfaceRequest from a dict +network_interface_request_from_dict = NetworkInterfaceRequest.from_dict(network_interface_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NetworkRequest.md b/docs/NetworkRequest.md new file mode 100644 index 000000000..82adc40c5 --- /dev/null +++ b/docs/NetworkRequest.md @@ -0,0 +1,32 @@ +# NetworkRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**hostname** | **str** | | +**firewall_enabled** | **bool** | | [optional] +**interfaces** | [**List[NetworkInterfaceRequest]**](NetworkInterfaceRequest.md) | | +**gateway** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.network_request import NetworkRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of NetworkRequest from a JSON string +network_request_instance = NetworkRequest.from_json(json) +# print the JSON string representation of the object +print(NetworkRequest.to_json()) + +# convert the object into a dict +network_request_dict = network_request_instance.to_dict() +# create an instance of NetworkRequest from a dict +network_request_from_dict = NetworkRequest.from_dict(network_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NotConfiguredActionEnum.md b/docs/NotConfiguredActionEnum.md new file mode 100644 index 000000000..2f5b652fc --- /dev/null +++ b/docs/NotConfiguredActionEnum.md @@ -0,0 +1,14 @@ +# NotConfiguredActionEnum + + +## Enum + +* `SKIP` (value: `'skip'`) + +* `DENY` (value: `'deny'`) + +* `CONFIGURE` (value: `'configure'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Notification.md b/docs/Notification.md new file mode 100644 index 000000000..2e5307941 --- /dev/null +++ b/docs/Notification.md @@ -0,0 +1,37 @@ +# Notification + +Notification Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**severity** | [**SeverityEnum**](SeverityEnum.md) | | [readonly] +**body** | **str** | | [readonly] +**hyperlink** | **str** | | [optional] +**hyperlink_label** | **str** | | [optional] +**created** | **datetime** | | [readonly] +**event** | [**Event**](Event.md) | | [optional] +**seen** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.notification import Notification + +# TODO update the JSON string below +json = "{}" +# create an instance of Notification from a JSON string +notification_instance = Notification.from_json(json) +# print the JSON string representation of the object +print(Notification.to_json()) + +# convert the object into a dict +notification_dict = notification_instance.to_dict() +# create an instance of Notification from a dict +notification_from_dict = Notification.from_dict(notification_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NotificationRequest.md b/docs/NotificationRequest.md new file mode 100644 index 000000000..89282cf9a --- /dev/null +++ b/docs/NotificationRequest.md @@ -0,0 +1,33 @@ +# NotificationRequest + +Notification Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**hyperlink** | **str** | | [optional] +**hyperlink_label** | **str** | | [optional] +**event** | [**EventRequest**](EventRequest.md) | | [optional] +**seen** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.notification_request import NotificationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of NotificationRequest from a JSON string +notification_request_instance = NotificationRequest.from_json(json) +# print the JSON string representation of the object +print(NotificationRequest.to_json()) + +# convert the object into a dict +notification_request_dict = notification_request_instance.to_dict() +# create an instance of NotificationRequest from a dict +notification_request_from_dict = NotificationRequest.from_dict(notification_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NotificationRule.md b/docs/NotificationRule.md new file mode 100644 index 000000000..e90636183 --- /dev/null +++ b/docs/NotificationRule.md @@ -0,0 +1,36 @@ +# NotificationRule + +NotificationRule Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**transports** | **List[UUID]** | Select which transports should be used to notify the user. If none are selected, the notification will only be shown in the authentik UI. | [optional] +**severity** | [**SeverityEnum**](SeverityEnum.md) | Controls which severity level the created notifications will have. | [optional] +**destination_group** | **UUID** | Define which group of users this notification should be sent and shown to. If left empty, Notification won't ben sent. | [optional] +**destination_group_obj** | [**Group**](Group.md) | | [readonly] +**destination_event_user** | **bool** | When enabled, notification will be sent to user the user that triggered the event.When destination_group is configured, notification is sent to both. | [optional] + +## Example + +```python +from authentik_client.models.notification_rule import NotificationRule + +# TODO update the JSON string below +json = "{}" +# create an instance of NotificationRule from a JSON string +notification_rule_instance = NotificationRule.from_json(json) +# print the JSON string representation of the object +print(NotificationRule.to_json()) + +# convert the object into a dict +notification_rule_dict = notification_rule_instance.to_dict() +# create an instance of NotificationRule from a dict +notification_rule_from_dict = NotificationRule.from_dict(notification_rule_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NotificationRuleRequest.md b/docs/NotificationRuleRequest.md new file mode 100644 index 000000000..05d40d123 --- /dev/null +++ b/docs/NotificationRuleRequest.md @@ -0,0 +1,34 @@ +# NotificationRuleRequest + +NotificationRule Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**transports** | **List[UUID]** | Select which transports should be used to notify the user. If none are selected, the notification will only be shown in the authentik UI. | [optional] +**severity** | [**SeverityEnum**](SeverityEnum.md) | Controls which severity level the created notifications will have. | [optional] +**destination_group** | **UUID** | Define which group of users this notification should be sent and shown to. If left empty, Notification won't ben sent. | [optional] +**destination_event_user** | **bool** | When enabled, notification will be sent to user the user that triggered the event.When destination_group is configured, notification is sent to both. | [optional] + +## Example + +```python +from authentik_client.models.notification_rule_request import NotificationRuleRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of NotificationRuleRequest from a JSON string +notification_rule_request_instance = NotificationRuleRequest.from_json(json) +# print the JSON string representation of the object +print(NotificationRuleRequest.to_json()) + +# convert the object into a dict +notification_rule_request_dict = notification_rule_request_instance.to_dict() +# create an instance of NotificationRuleRequest from a dict +notification_rule_request_from_dict = NotificationRuleRequest.from_dict(notification_rule_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NotificationTransport.md b/docs/NotificationTransport.md new file mode 100644 index 000000000..da1006e9b --- /dev/null +++ b/docs/NotificationTransport.md @@ -0,0 +1,40 @@ +# NotificationTransport + +NotificationTransport Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**mode** | [**TransportModeEnum**](TransportModeEnum.md) | | [optional] +**mode_verbose** | **str** | Return selected mode with a UI Label | [readonly] +**webhook_url** | **str** | | [optional] +**webhook_ca** | **UUID** | When set, the selected certificate is used to validate the certificate of the webhook server. | [optional] +**webhook_mapping_body** | **UUID** | Customize the body of the request. Mapping should return data that is JSON-serializable. | [optional] +**webhook_mapping_headers** | **UUID** | Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs | [optional] +**email_subject_prefix** | **str** | | [optional] +**email_template** | **str** | | [optional] +**send_once** | **bool** | Only send notification once, for example when sending a webhook into a chat channel. | [optional] + +## Example + +```python +from authentik_client.models.notification_transport import NotificationTransport + +# TODO update the JSON string below +json = "{}" +# create an instance of NotificationTransport from a JSON string +notification_transport_instance = NotificationTransport.from_json(json) +# print the JSON string representation of the object +print(NotificationTransport.to_json()) + +# convert the object into a dict +notification_transport_dict = notification_transport_instance.to_dict() +# create an instance of NotificationTransport from a dict +notification_transport_from_dict = NotificationTransport.from_dict(notification_transport_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NotificationTransportRequest.md b/docs/NotificationTransportRequest.md new file mode 100644 index 000000000..2ded4a891 --- /dev/null +++ b/docs/NotificationTransportRequest.md @@ -0,0 +1,38 @@ +# NotificationTransportRequest + +NotificationTransport Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**mode** | [**TransportModeEnum**](TransportModeEnum.md) | | [optional] +**webhook_url** | **str** | | [optional] +**webhook_ca** | **UUID** | When set, the selected certificate is used to validate the certificate of the webhook server. | [optional] +**webhook_mapping_body** | **UUID** | Customize the body of the request. Mapping should return data that is JSON-serializable. | [optional] +**webhook_mapping_headers** | **UUID** | Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs | [optional] +**email_subject_prefix** | **str** | | [optional] +**email_template** | **str** | | [optional] +**send_once** | **bool** | Only send notification once, for example when sending a webhook into a chat channel. | [optional] + +## Example + +```python +from authentik_client.models.notification_transport_request import NotificationTransportRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of NotificationTransportRequest from a JSON string +notification_transport_request_instance = NotificationTransportRequest.from_json(json) +# print the JSON string representation of the object +print(NotificationTransportRequest.to_json()) + +# convert the object into a dict +notification_transport_request_dict = notification_transport_request_instance.to_dict() +# create an instance of NotificationTransportRequest from a dict +notification_transport_request_from_dict = NotificationTransportRequest.from_dict(notification_transport_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NotificationTransportTest.md b/docs/NotificationTransportTest.md new file mode 100644 index 000000000..c9b176788 --- /dev/null +++ b/docs/NotificationTransportTest.md @@ -0,0 +1,30 @@ +# NotificationTransportTest + +Notification test serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**messages** | **List[str]** | | + +## Example + +```python +from authentik_client.models.notification_transport_test import NotificationTransportTest + +# TODO update the JSON string below +json = "{}" +# create an instance of NotificationTransportTest from a JSON string +notification_transport_test_instance = NotificationTransportTest.from_json(json) +# print the JSON string representation of the object +print(NotificationTransportTest.to_json()) + +# convert the object into a dict +notification_transport_test_dict = notification_transport_test_instance.to_dict() +# create an instance of NotificationTransportTest from a dict +notification_transport_test_from_dict = NotificationTransportTest.from_dict(notification_transport_test_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NotificationWebhookMapping.md b/docs/NotificationWebhookMapping.md new file mode 100644 index 000000000..102050bf5 --- /dev/null +++ b/docs/NotificationWebhookMapping.md @@ -0,0 +1,32 @@ +# NotificationWebhookMapping + +NotificationWebhookMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of NotificationWebhookMapping from a JSON string +notification_webhook_mapping_instance = NotificationWebhookMapping.from_json(json) +# print the JSON string representation of the object +print(NotificationWebhookMapping.to_json()) + +# convert the object into a dict +notification_webhook_mapping_dict = notification_webhook_mapping_instance.to_dict() +# create an instance of NotificationWebhookMapping from a dict +notification_webhook_mapping_from_dict = NotificationWebhookMapping.from_dict(notification_webhook_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/NotificationWebhookMappingRequest.md b/docs/NotificationWebhookMappingRequest.md new file mode 100644 index 000000000..e5a544764 --- /dev/null +++ b/docs/NotificationWebhookMappingRequest.md @@ -0,0 +1,31 @@ +# NotificationWebhookMappingRequest + +NotificationWebhookMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.notification_webhook_mapping_request import NotificationWebhookMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of NotificationWebhookMappingRequest from a JSON string +notification_webhook_mapping_request_instance = NotificationWebhookMappingRequest.from_json(json) +# print the JSON string representation of the object +print(NotificationWebhookMappingRequest.to_json()) + +# convert the object into a dict +notification_webhook_mapping_request_dict = notification_webhook_mapping_request_instance.to_dict() +# create an instance of NotificationWebhookMappingRequest from a dict +notification_webhook_mapping_request_from_dict = NotificationWebhookMappingRequest.from_dict(notification_webhook_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuth2Provider.md b/docs/OAuth2Provider.md new file mode 100644 index 000000000..4aec6bd25 --- /dev/null +++ b/docs/OAuth2Provider.md @@ -0,0 +1,61 @@ +# OAuth2Provider + +OAuth2Provider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_application_name** | **str** | Application's display Name. | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**client_type** | [**ClientTypeEnum**](ClientTypeEnum.md) | Confidential clients are capable of maintaining the confidentiality of their credentials. Public clients are incapable | [optional] +**grant_types** | [**List[GrantTypesEnum]**](GrantTypesEnum.md) | | [optional] +**client_id** | **str** | | [optional] +**client_secret** | **str** | | [optional] +**access_code_validity** | **str** | Access codes not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**access_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_threshold** | **str** | When refreshing a token, if the refresh token is valid for less than this duration, it will be renewed. When set to seconds=0, token will always be renewed. (Format: hours=1;minutes=2;seconds=3). | [optional] +**include_claims_in_id_token** | **bool** | Include User claims from scopes in the id_token, for applications that don't access the userinfo endpoint. | [optional] +**signing_key** | **UUID** | Key used to sign the tokens. | [optional] +**encryption_key** | **UUID** | Key used to encrypt the tokens. When set, tokens will be encrypted and returned as JWEs. | [optional] +**redirect_uris** | [**List[RedirectURI]**](RedirectURI.md) | | +**logout_uri** | **str** | | [optional] +**logout_method** | [**OAuth2ProviderLogoutMethodEnum**](OAuth2ProviderLogoutMethodEnum.md) | Backchannel logs out with server to server calls. Frontchannel uses iframes in your browser | [optional] +**sub_mode** | [**SubModeEnum**](SubModeEnum.md) | Configure what data should be used as unique User Identifier. For most cases, the default should be fine. | [optional] +**issuer_mode** | [**IssuerModeEnum**](IssuerModeEnum.md) | Configure how the issuer field of the ID Token should be filled. | [optional] +**jwt_federation_sources** | **List[UUID]** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] + +## Example + +```python +from authentik_client.models.o_auth2_provider import OAuth2Provider + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuth2Provider from a JSON string +o_auth2_provider_instance = OAuth2Provider.from_json(json) +# print the JSON string representation of the object +print(OAuth2Provider.to_json()) + +# convert the object into a dict +o_auth2_provider_dict = o_auth2_provider_instance.to_dict() +# create an instance of OAuth2Provider from a dict +o_auth2_provider_from_dict = OAuth2Provider.from_dict(o_auth2_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuth2ProviderLogoutMethodEnum.md b/docs/OAuth2ProviderLogoutMethodEnum.md new file mode 100644 index 000000000..3a5753825 --- /dev/null +++ b/docs/OAuth2ProviderLogoutMethodEnum.md @@ -0,0 +1,12 @@ +# OAuth2ProviderLogoutMethodEnum + + +## Enum + +* `BACKCHANNEL` (value: `'backchannel'`) + +* `FRONTCHANNEL` (value: `'frontchannel'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuth2ProviderRequest.md b/docs/OAuth2ProviderRequest.md new file mode 100644 index 000000000..07bd70d5a --- /dev/null +++ b/docs/OAuth2ProviderRequest.md @@ -0,0 +1,52 @@ +# OAuth2ProviderRequest + +OAuth2Provider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**client_type** | [**ClientTypeEnum**](ClientTypeEnum.md) | Confidential clients are capable of maintaining the confidentiality of their credentials. Public clients are incapable | [optional] +**grant_types** | [**List[GrantTypesEnum]**](GrantTypesEnum.md) | | [optional] +**client_id** | **str** | | [optional] +**client_secret** | **str** | | [optional] +**access_code_validity** | **str** | Access codes not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**access_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_threshold** | **str** | When refreshing a token, if the refresh token is valid for less than this duration, it will be renewed. When set to seconds=0, token will always be renewed. (Format: hours=1;minutes=2;seconds=3). | [optional] +**include_claims_in_id_token** | **bool** | Include User claims from scopes in the id_token, for applications that don't access the userinfo endpoint. | [optional] +**signing_key** | **UUID** | Key used to sign the tokens. | [optional] +**encryption_key** | **UUID** | Key used to encrypt the tokens. When set, tokens will be encrypted and returned as JWEs. | [optional] +**redirect_uris** | [**List[RedirectURIRequest]**](RedirectURIRequest.md) | | +**logout_uri** | **str** | | [optional] +**logout_method** | [**OAuth2ProviderLogoutMethodEnum**](OAuth2ProviderLogoutMethodEnum.md) | Backchannel logs out with server to server calls. Frontchannel uses iframes in your browser | [optional] +**sub_mode** | [**SubModeEnum**](SubModeEnum.md) | Configure what data should be used as unique User Identifier. For most cases, the default should be fine. | [optional] +**issuer_mode** | [**IssuerModeEnum**](IssuerModeEnum.md) | Configure how the issuer field of the ID Token should be filled. | [optional] +**jwt_federation_sources** | **List[UUID]** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] + +## Example + +```python +from authentik_client.models.o_auth2_provider_request import OAuth2ProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuth2ProviderRequest from a JSON string +o_auth2_provider_request_instance = OAuth2ProviderRequest.from_json(json) +# print the JSON string representation of the object +print(OAuth2ProviderRequest.to_json()) + +# convert the object into a dict +o_auth2_provider_request_dict = o_auth2_provider_request_instance.to_dict() +# create an instance of OAuth2ProviderRequest from a dict +o_auth2_provider_request_from_dict = OAuth2ProviderRequest.from_dict(o_auth2_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuth2ProviderSetupURLs.md b/docs/OAuth2ProviderSetupURLs.md new file mode 100644 index 000000000..653da0073 --- /dev/null +++ b/docs/OAuth2ProviderSetupURLs.md @@ -0,0 +1,36 @@ +# OAuth2ProviderSetupURLs + +OAuth2 Provider Metadata serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**issuer** | **str** | | [readonly] +**authorize** | **str** | | [readonly] +**token** | **str** | | [readonly] +**user_info** | **str** | | [readonly] +**provider_info** | **str** | | [readonly] +**logout** | **str** | | [readonly] +**jwks** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.o_auth2_provider_setup_urls import OAuth2ProviderSetupURLs + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuth2ProviderSetupURLs from a JSON string +o_auth2_provider_setup_urls_instance = OAuth2ProviderSetupURLs.from_json(json) +# print the JSON string representation of the object +print(OAuth2ProviderSetupURLs.to_json()) + +# convert the object into a dict +o_auth2_provider_setup_urls_dict = o_auth2_provider_setup_urls_instance.to_dict() +# create an instance of OAuth2ProviderSetupURLs from a dict +o_auth2_provider_setup_urls_from_dict = OAuth2ProviderSetupURLs.from_dict(o_auth2_provider_setup_urls_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuthDeviceCodeChallenge.md b/docs/OAuthDeviceCodeChallenge.md new file mode 100644 index 000000000..e6cf8d57b --- /dev/null +++ b/docs/OAuthDeviceCodeChallenge.md @@ -0,0 +1,32 @@ +# OAuthDeviceCodeChallenge + +OAuth Device code challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-provider-oauth2-device-code'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] + +## Example + +```python +from authentik_client.models.o_auth_device_code_challenge import OAuthDeviceCodeChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuthDeviceCodeChallenge from a JSON string +o_auth_device_code_challenge_instance = OAuthDeviceCodeChallenge.from_json(json) +# print the JSON string representation of the object +print(OAuthDeviceCodeChallenge.to_json()) + +# convert the object into a dict +o_auth_device_code_challenge_dict = o_auth_device_code_challenge_instance.to_dict() +# create an instance of OAuthDeviceCodeChallenge from a dict +o_auth_device_code_challenge_from_dict = OAuthDeviceCodeChallenge.from_dict(o_auth_device_code_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuthDeviceCodeChallengeResponseRequest.md b/docs/OAuthDeviceCodeChallengeResponseRequest.md new file mode 100644 index 000000000..ddd89d6f0 --- /dev/null +++ b/docs/OAuthDeviceCodeChallengeResponseRequest.md @@ -0,0 +1,31 @@ +# OAuthDeviceCodeChallengeResponseRequest + +Response that includes the user-entered device code + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-provider-oauth2-device-code'] +**code** | **str** | | + +## Example + +```python +from authentik_client.models.o_auth_device_code_challenge_response_request import OAuthDeviceCodeChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuthDeviceCodeChallengeResponseRequest from a JSON string +o_auth_device_code_challenge_response_request_instance = OAuthDeviceCodeChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(OAuthDeviceCodeChallengeResponseRequest.to_json()) + +# convert the object into a dict +o_auth_device_code_challenge_response_request_dict = o_auth_device_code_challenge_response_request_instance.to_dict() +# create an instance of OAuthDeviceCodeChallengeResponseRequest from a dict +o_auth_device_code_challenge_response_request_from_dict = OAuthDeviceCodeChallengeResponseRequest.from_dict(o_auth_device_code_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuthDeviceCodeFinishChallenge.md b/docs/OAuthDeviceCodeFinishChallenge.md new file mode 100644 index 000000000..632cc424e --- /dev/null +++ b/docs/OAuthDeviceCodeFinishChallenge.md @@ -0,0 +1,32 @@ +# OAuthDeviceCodeFinishChallenge + +Final challenge after user enters their code + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-provider-oauth2-device-code-finish'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] + +## Example + +```python +from authentik_client.models.o_auth_device_code_finish_challenge import OAuthDeviceCodeFinishChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuthDeviceCodeFinishChallenge from a JSON string +o_auth_device_code_finish_challenge_instance = OAuthDeviceCodeFinishChallenge.from_json(json) +# print the JSON string representation of the object +print(OAuthDeviceCodeFinishChallenge.to_json()) + +# convert the object into a dict +o_auth_device_code_finish_challenge_dict = o_auth_device_code_finish_challenge_instance.to_dict() +# create an instance of OAuthDeviceCodeFinishChallenge from a dict +o_auth_device_code_finish_challenge_from_dict = OAuthDeviceCodeFinishChallenge.from_dict(o_auth_device_code_finish_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuthDeviceCodeFinishChallengeResponseRequest.md b/docs/OAuthDeviceCodeFinishChallengeResponseRequest.md new file mode 100644 index 000000000..999551d70 --- /dev/null +++ b/docs/OAuthDeviceCodeFinishChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# OAuthDeviceCodeFinishChallengeResponseRequest + +Response that device has been authenticated and tab can be closed + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-provider-oauth2-device-code-finish'] + +## Example + +```python +from authentik_client.models.o_auth_device_code_finish_challenge_response_request import OAuthDeviceCodeFinishChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuthDeviceCodeFinishChallengeResponseRequest from a JSON string +o_auth_device_code_finish_challenge_response_request_instance = OAuthDeviceCodeFinishChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(OAuthDeviceCodeFinishChallengeResponseRequest.to_json()) + +# convert the object into a dict +o_auth_device_code_finish_challenge_response_request_dict = o_auth_device_code_finish_challenge_response_request_instance.to_dict() +# create an instance of OAuthDeviceCodeFinishChallengeResponseRequest from a dict +o_auth_device_code_finish_challenge_response_request_from_dict = OAuthDeviceCodeFinishChallengeResponseRequest.from_dict(o_auth_device_code_finish_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuthSource.md b/docs/OAuthSource.md new file mode 100644 index 000000000..4692c40af --- /dev/null +++ b/docs/OAuthSource.md @@ -0,0 +1,64 @@ +# OAuthSource + +OAuth Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [readonly] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**icon_url** | **str** | | [readonly] +**icon_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**provider_type** | [**ProviderTypeEnum**](ProviderTypeEnum.md) | | +**request_token_url** | **str** | URL used to request the initial token. This URL is only required for OAuth 1. | [optional] +**authorization_url** | **str** | URL the user is redirect to to conest the flow. | [optional] +**access_token_url** | **str** | URL used by authentik to retrieve tokens. | [optional] +**profile_url** | **str** | URL used by authentik to get user information. | [optional] +**pkce** | [**PKCEMethodEnum**](PKCEMethodEnum.md) | | [optional] +**consumer_key** | **str** | | +**callback_url** | **str** | Get OAuth Callback URL | [readonly] +**additional_scopes** | **str** | | [optional] +**type** | [**SourceType**](SourceType.md) | | [readonly] +**oidc_well_known_url** | **str** | | [optional] +**oidc_jwks_url** | **str** | | [optional] +**oidc_jwks** | **Dict[str, object]** | | [optional] +**authorization_code_auth_method** | [**AuthorizationCodeAuthMethodEnum**](AuthorizationCodeAuthMethodEnum.md) | How to perform authentication during an authorization_code token request flow | [optional] + +## Example + +```python +from authentik_client.models.o_auth_source import OAuthSource + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuthSource from a JSON string +o_auth_source_instance = OAuthSource.from_json(json) +# print the JSON string representation of the object +print(OAuthSource.to_json()) + +# convert the object into a dict +o_auth_source_dict = o_auth_source_instance.to_dict() +# create an instance of OAuthSource from a dict +o_auth_source_from_dict = OAuthSource.from_dict(o_auth_source_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuthSourcePropertyMapping.md b/docs/OAuthSourcePropertyMapping.md new file mode 100644 index 000000000..d17208ea2 --- /dev/null +++ b/docs/OAuthSourcePropertyMapping.md @@ -0,0 +1,37 @@ +# OAuthSourcePropertyMapping + +OAuthSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuthSourcePropertyMapping from a JSON string +o_auth_source_property_mapping_instance = OAuthSourcePropertyMapping.from_json(json) +# print the JSON string representation of the object +print(OAuthSourcePropertyMapping.to_json()) + +# convert the object into a dict +o_auth_source_property_mapping_dict = o_auth_source_property_mapping_instance.to_dict() +# create an instance of OAuthSourcePropertyMapping from a dict +o_auth_source_property_mapping_from_dict = OAuthSourcePropertyMapping.from_dict(o_auth_source_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuthSourcePropertyMappingRequest.md b/docs/OAuthSourcePropertyMappingRequest.md new file mode 100644 index 000000000..c9d9b1646 --- /dev/null +++ b/docs/OAuthSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# OAuthSourcePropertyMappingRequest + +OAuthSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.o_auth_source_property_mapping_request import OAuthSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuthSourcePropertyMappingRequest from a JSON string +o_auth_source_property_mapping_request_instance = OAuthSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(OAuthSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +o_auth_source_property_mapping_request_dict = o_auth_source_property_mapping_request_instance.to_dict() +# create an instance of OAuthSourcePropertyMappingRequest from a dict +o_auth_source_property_mapping_request_from_dict = OAuthSourcePropertyMappingRequest.from_dict(o_auth_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OAuthSourceRequest.md b/docs/OAuthSourceRequest.md new file mode 100644 index 000000000..20e48ac75 --- /dev/null +++ b/docs/OAuthSourceRequest.md @@ -0,0 +1,55 @@ +# OAuthSourceRequest + +OAuth Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**provider_type** | [**ProviderTypeEnum**](ProviderTypeEnum.md) | | +**request_token_url** | **str** | URL used to request the initial token. This URL is only required for OAuth 1. | [optional] +**authorization_url** | **str** | URL the user is redirect to to conest the flow. | [optional] +**access_token_url** | **str** | URL used by authentik to retrieve tokens. | [optional] +**profile_url** | **str** | URL used by authentik to get user information. | [optional] +**pkce** | [**PKCEMethodEnum**](PKCEMethodEnum.md) | | [optional] +**consumer_key** | **str** | | +**consumer_secret** | **str** | | +**additional_scopes** | **str** | | [optional] +**oidc_well_known_url** | **str** | | [optional] +**oidc_jwks_url** | **str** | | [optional] +**oidc_jwks** | **Dict[str, object]** | | [optional] +**authorization_code_auth_method** | [**AuthorizationCodeAuthMethodEnum**](AuthorizationCodeAuthMethodEnum.md) | How to perform authentication during an authorization_code token request flow | [optional] + +## Example + +```python +from authentik_client.models.o_auth_source_request import OAuthSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of OAuthSourceRequest from a JSON string +o_auth_source_request_instance = OAuthSourceRequest.from_json(json) +# print the JSON string representation of the object +print(OAuthSourceRequest.to_json()) + +# convert the object into a dict +o_auth_source_request_dict = o_auth_source_request_instance.to_dict() +# create an instance of OAuthSourceRequest from a dict +o_auth_source_request_from_dict = OAuthSourceRequest.from_dict(o_auth_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Oauth2Api.md b/docs/Oauth2Api.md new file mode 100644 index 000000000..86359c306 --- /dev/null +++ b/docs/Oauth2Api.md @@ -0,0 +1,965 @@ +# authentik_client.Oauth2Api + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**oauth2_access_tokens_destroy**](Oauth2Api.md#oauth2_access_tokens_destroy) | **DELETE** /oauth2/access_tokens/{id}/ | +[**oauth2_access_tokens_list**](Oauth2Api.md#oauth2_access_tokens_list) | **GET** /oauth2/access_tokens/ | +[**oauth2_access_tokens_retrieve**](Oauth2Api.md#oauth2_access_tokens_retrieve) | **GET** /oauth2/access_tokens/{id}/ | +[**oauth2_access_tokens_used_by_list**](Oauth2Api.md#oauth2_access_tokens_used_by_list) | **GET** /oauth2/access_tokens/{id}/used_by/ | +[**oauth2_authorization_codes_destroy**](Oauth2Api.md#oauth2_authorization_codes_destroy) | **DELETE** /oauth2/authorization_codes/{id}/ | +[**oauth2_authorization_codes_list**](Oauth2Api.md#oauth2_authorization_codes_list) | **GET** /oauth2/authorization_codes/ | +[**oauth2_authorization_codes_retrieve**](Oauth2Api.md#oauth2_authorization_codes_retrieve) | **GET** /oauth2/authorization_codes/{id}/ | +[**oauth2_authorization_codes_used_by_list**](Oauth2Api.md#oauth2_authorization_codes_used_by_list) | **GET** /oauth2/authorization_codes/{id}/used_by/ | +[**oauth2_refresh_tokens_destroy**](Oauth2Api.md#oauth2_refresh_tokens_destroy) | **DELETE** /oauth2/refresh_tokens/{id}/ | +[**oauth2_refresh_tokens_list**](Oauth2Api.md#oauth2_refresh_tokens_list) | **GET** /oauth2/refresh_tokens/ | +[**oauth2_refresh_tokens_retrieve**](Oauth2Api.md#oauth2_refresh_tokens_retrieve) | **GET** /oauth2/refresh_tokens/{id}/ | +[**oauth2_refresh_tokens_used_by_list**](Oauth2Api.md#oauth2_refresh_tokens_used_by_list) | **GET** /oauth2/refresh_tokens/{id}/used_by/ | + + +# **oauth2_access_tokens_destroy** +> oauth2_access_tokens_destroy(id) + +AccessToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + id = 56 # int | A unique integer value identifying this OAuth2 Access Token. + + try: + api_instance.oauth2_access_tokens_destroy(id) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_access_tokens_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2 Access Token. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_access_tokens_list** +> PaginatedTokenModelList oauth2_access_tokens_list(ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, user=user) + +AccessToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_token_model_list import PaginatedTokenModelList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.oauth2_access_tokens_list(ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, user=user) + print("The response of Oauth2Api->oauth2_access_tokens_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_access_tokens_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedTokenModelList**](PaginatedTokenModelList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_access_tokens_retrieve** +> TokenModel oauth2_access_tokens_retrieve(id) + +AccessToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.token_model import TokenModel +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + id = 56 # int | A unique integer value identifying this OAuth2 Access Token. + + try: + api_response = api_instance.oauth2_access_tokens_retrieve(id) + print("The response of Oauth2Api->oauth2_access_tokens_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_access_tokens_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2 Access Token. | + +### Return type + +[**TokenModel**](TokenModel.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_access_tokens_used_by_list** +> List[UsedBy] oauth2_access_tokens_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + id = 56 # int | A unique integer value identifying this OAuth2 Access Token. + + try: + api_response = api_instance.oauth2_access_tokens_used_by_list(id) + print("The response of Oauth2Api->oauth2_access_tokens_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_access_tokens_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2 Access Token. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_authorization_codes_destroy** +> oauth2_authorization_codes_destroy(id) + +AuthorizationCode Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + id = 56 # int | A unique integer value identifying this Authorization Code. + + try: + api_instance.oauth2_authorization_codes_destroy(id) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_authorization_codes_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Authorization Code. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_authorization_codes_list** +> PaginatedExpiringBaseGrantModelList oauth2_authorization_codes_list(ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, user=user) + +AuthorizationCode Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_expiring_base_grant_model_list import PaginatedExpiringBaseGrantModelList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.oauth2_authorization_codes_list(ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, user=user) + print("The response of Oauth2Api->oauth2_authorization_codes_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_authorization_codes_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedExpiringBaseGrantModelList**](PaginatedExpiringBaseGrantModelList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_authorization_codes_retrieve** +> ExpiringBaseGrantModel oauth2_authorization_codes_retrieve(id) + +AuthorizationCode Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.expiring_base_grant_model import ExpiringBaseGrantModel +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + id = 56 # int | A unique integer value identifying this Authorization Code. + + try: + api_response = api_instance.oauth2_authorization_codes_retrieve(id) + print("The response of Oauth2Api->oauth2_authorization_codes_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_authorization_codes_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Authorization Code. | + +### Return type + +[**ExpiringBaseGrantModel**](ExpiringBaseGrantModel.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_authorization_codes_used_by_list** +> List[UsedBy] oauth2_authorization_codes_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + id = 56 # int | A unique integer value identifying this Authorization Code. + + try: + api_response = api_instance.oauth2_authorization_codes_used_by_list(id) + print("The response of Oauth2Api->oauth2_authorization_codes_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_authorization_codes_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Authorization Code. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_refresh_tokens_destroy** +> oauth2_refresh_tokens_destroy(id) + +RefreshToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + id = 56 # int | A unique integer value identifying this OAuth2 Refresh Token. + + try: + api_instance.oauth2_refresh_tokens_destroy(id) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_refresh_tokens_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2 Refresh Token. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_refresh_tokens_list** +> PaginatedTokenModelList oauth2_refresh_tokens_list(ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, user=user) + +RefreshToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_token_model_list import PaginatedTokenModelList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.oauth2_refresh_tokens_list(ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, user=user) + print("The response of Oauth2Api->oauth2_refresh_tokens_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_refresh_tokens_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedTokenModelList**](PaginatedTokenModelList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_refresh_tokens_retrieve** +> TokenModel oauth2_refresh_tokens_retrieve(id) + +RefreshToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.token_model import TokenModel +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + id = 56 # int | A unique integer value identifying this OAuth2 Refresh Token. + + try: + api_response = api_instance.oauth2_refresh_tokens_retrieve(id) + print("The response of Oauth2Api->oauth2_refresh_tokens_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_refresh_tokens_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2 Refresh Token. | + +### Return type + +[**TokenModel**](TokenModel.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **oauth2_refresh_tokens_used_by_list** +> List[UsedBy] oauth2_refresh_tokens_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.Oauth2Api(api_client) + id = 56 # int | A unique integer value identifying this OAuth2 Refresh Token. + + try: + api_response = api_instance.oauth2_refresh_tokens_used_by_list(id) + print("The response of Oauth2Api->oauth2_refresh_tokens_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling Oauth2Api->oauth2_refresh_tokens_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2 Refresh Token. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/OpenIDConnectConfiguration.md b/docs/OpenIDConnectConfiguration.md new file mode 100644 index 000000000..fc09af4f3 --- /dev/null +++ b/docs/OpenIDConnectConfiguration.md @@ -0,0 +1,40 @@ +# OpenIDConnectConfiguration + +rest_framework Serializer for OIDC Configuration + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**issuer** | **str** | | +**authorization_endpoint** | **str** | | +**token_endpoint** | **str** | | +**userinfo_endpoint** | **str** | | +**end_session_endpoint** | **str** | | +**introspection_endpoint** | **str** | | +**jwks_uri** | **str** | | +**response_types_supported** | **List[str]** | | +**id_token_signing_alg_values_supported** | **List[str]** | | +**subject_types_supported** | **List[str]** | | +**token_endpoint_auth_methods_supported** | **List[str]** | | + +## Example + +```python +from authentik_client.models.open_id_connect_configuration import OpenIDConnectConfiguration + +# TODO update the JSON string below +json = "{}" +# create an instance of OpenIDConnectConfiguration from a JSON string +open_id_connect_configuration_instance = OpenIDConnectConfiguration.from_json(json) +# print the JSON string representation of the object +print(OpenIDConnectConfiguration.to_json()) + +# convert the object into a dict +open_id_connect_configuration_dict = open_id_connect_configuration_instance.to_dict() +# create an instance of OpenIDConnectConfiguration from a dict +open_id_connect_configuration_from_dict = OpenIDConnectConfiguration.from_dict(open_id_connect_configuration_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OperatingSystem.md b/docs/OperatingSystem.md new file mode 100644 index 000000000..781eed42f --- /dev/null +++ b/docs/OperatingSystem.md @@ -0,0 +1,33 @@ +# OperatingSystem + +For example: {\"family\":\"linux\",\"name\":\"Ubuntu\",\"version\":\"24.04.3 LTS (Noble Numbat)\",\"arch\":\"amd64\"} {\"family\": \"windows\",\"name\":\"Server 2022 Datacenter\",\"version\":\"10.0.20348.4405\",\"arch\":\"amd64\"} {\"family\": \"windows\",\"name\":\"Server 2022 Datacenter\",\"version\":\"10.0.20348.4405\",\"arch\":\"amd64\"} {\"family\": \"mac_os\", \"name\": \"\", \"version\": \"26.2\", \"arch\": \"arm64\"} + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**family** | [**DeviceFactsOSFamily**](DeviceFactsOSFamily.md) | | +**name** | **str** | Operating System name, such as 'Server 2022' or 'Ubuntu' | [optional] +**version** | **str** | Operating System version, must always be the version number but may contain build name | [optional] +**arch** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.operating_system import OperatingSystem + +# TODO update the JSON string below +json = "{}" +# create an instance of OperatingSystem from a JSON string +operating_system_instance = OperatingSystem.from_json(json) +# print the JSON string representation of the object +print(OperatingSystem.to_json()) + +# convert the object into a dict +operating_system_dict = operating_system_instance.to_dict() +# create an instance of OperatingSystem from a dict +operating_system_from_dict = OperatingSystem.from_dict(operating_system_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OperatingSystemRequest.md b/docs/OperatingSystemRequest.md new file mode 100644 index 000000000..b1172e018 --- /dev/null +++ b/docs/OperatingSystemRequest.md @@ -0,0 +1,33 @@ +# OperatingSystemRequest + +For example: {\"family\":\"linux\",\"name\":\"Ubuntu\",\"version\":\"24.04.3 LTS (Noble Numbat)\",\"arch\":\"amd64\"} {\"family\": \"windows\",\"name\":\"Server 2022 Datacenter\",\"version\":\"10.0.20348.4405\",\"arch\":\"amd64\"} {\"family\": \"windows\",\"name\":\"Server 2022 Datacenter\",\"version\":\"10.0.20348.4405\",\"arch\":\"amd64\"} {\"family\": \"mac_os\", \"name\": \"\", \"version\": \"26.2\", \"arch\": \"arm64\"} + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**family** | [**DeviceFactsOSFamily**](DeviceFactsOSFamily.md) | | +**name** | **str** | Operating System name, such as 'Server 2022' or 'Ubuntu' | [optional] +**version** | **str** | Operating System version, must always be the version number but may contain build name | [optional] +**arch** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.operating_system_request import OperatingSystemRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of OperatingSystemRequest from a JSON string +operating_system_request_instance = OperatingSystemRequest.from_json(json) +# print the JSON string representation of the object +print(OperatingSystemRequest.to_json()) + +# convert the object into a dict +operating_system_request_dict = operating_system_request_instance.to_dict() +# create an instance of OperatingSystemRequest from a dict +operating_system_request_from_dict = OperatingSystemRequest.from_dict(operating_system_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OutgoingSyncDeleteAction.md b/docs/OutgoingSyncDeleteAction.md new file mode 100644 index 000000000..fc60e195b --- /dev/null +++ b/docs/OutgoingSyncDeleteAction.md @@ -0,0 +1,14 @@ +# OutgoingSyncDeleteAction + + +## Enum + +* `DO_NOTHING` (value: `'do_nothing'`) + +* `DELETE` (value: `'delete'`) + +* `SUSPEND` (value: `'suspend'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Outpost.md b/docs/Outpost.md new file mode 100644 index 000000000..1f5e83b0e --- /dev/null +++ b/docs/Outpost.md @@ -0,0 +1,40 @@ +# Outpost + +Outpost Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**type** | [**OutpostTypeEnum**](OutpostTypeEnum.md) | | +**providers** | **List[int]** | | +**providers_obj** | [**List[Provider]**](Provider.md) | | [readonly] +**service_connection** | **UUID** | Select Service-Connection authentik should use to manage this outpost. Leave empty if authentik should not handle the deployment. | [optional] +**service_connection_obj** | [**ServiceConnection**](ServiceConnection.md) | | [readonly] +**refresh_interval_s** | **int** | | [readonly] +**token_identifier** | **str** | Get Token identifier | [readonly] +**config** | **Dict[str, object]** | | +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] + +## Example + +```python +from authentik_client.models.outpost import Outpost + +# TODO update the JSON string below +json = "{}" +# create an instance of Outpost from a JSON string +outpost_instance = Outpost.from_json(json) +# print the JSON string representation of the object +print(Outpost.to_json()) + +# convert the object into a dict +outpost_dict = outpost_instance.to_dict() +# create an instance of Outpost from a dict +outpost_from_dict = Outpost.from_dict(outpost_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OutpostDefaultConfig.md b/docs/OutpostDefaultConfig.md new file mode 100644 index 000000000..7f84c19d5 --- /dev/null +++ b/docs/OutpostDefaultConfig.md @@ -0,0 +1,30 @@ +# OutpostDefaultConfig + +Global default outpost config + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**config** | **Dict[str, object]** | | [readonly] + +## Example + +```python +from authentik_client.models.outpost_default_config import OutpostDefaultConfig + +# TODO update the JSON string below +json = "{}" +# create an instance of OutpostDefaultConfig from a JSON string +outpost_default_config_instance = OutpostDefaultConfig.from_json(json) +# print the JSON string representation of the object +print(OutpostDefaultConfig.to_json()) + +# convert the object into a dict +outpost_default_config_dict = outpost_default_config_instance.to_dict() +# create an instance of OutpostDefaultConfig from a dict +outpost_default_config_from_dict = OutpostDefaultConfig.from_dict(outpost_default_config_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OutpostHealth.md b/docs/OutpostHealth.md new file mode 100644 index 000000000..3ff6cf7cf --- /dev/null +++ b/docs/OutpostHealth.md @@ -0,0 +1,41 @@ +# OutpostHealth + +Outpost health status + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**uid** | **str** | | [readonly] +**last_seen** | **datetime** | | [readonly] +**version** | **str** | | [readonly] +**golang_version** | **str** | | [readonly] +**openssl_enabled** | **bool** | | [readonly] +**openssl_version** | **str** | | [readonly] +**fips_enabled** | **bool** | Get FIPS enabled | [readonly] +**version_should** | **str** | | [readonly] +**version_outdated** | **bool** | | [readonly] +**build_hash** | **str** | | [readonly] +**build_hash_should** | **str** | | [readonly] +**hostname** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.outpost_health import OutpostHealth + +# TODO update the JSON string below +json = "{}" +# create an instance of OutpostHealth from a JSON string +outpost_health_instance = OutpostHealth.from_json(json) +# print the JSON string representation of the object +print(OutpostHealth.to_json()) + +# convert the object into a dict +outpost_health_dict = outpost_health_instance.to_dict() +# create an instance of OutpostHealth from a dict +outpost_health_from_dict = OutpostHealth.from_dict(outpost_health_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OutpostRequest.md b/docs/OutpostRequest.md new file mode 100644 index 000000000..737e75c1c --- /dev/null +++ b/docs/OutpostRequest.md @@ -0,0 +1,35 @@ +# OutpostRequest + +Outpost Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**type** | [**OutpostTypeEnum**](OutpostTypeEnum.md) | | +**providers** | **List[int]** | | +**service_connection** | **UUID** | Select Service-Connection authentik should use to manage this outpost. Leave empty if authentik should not handle the deployment. | [optional] +**config** | **Dict[str, object]** | | +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] + +## Example + +```python +from authentik_client.models.outpost_request import OutpostRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of OutpostRequest from a JSON string +outpost_request_instance = OutpostRequest.from_json(json) +# print the JSON string representation of the object +print(OutpostRequest.to_json()) + +# convert the object into a dict +outpost_request_dict = outpost_request_instance.to_dict() +# create an instance of OutpostRequest from a dict +outpost_request_from_dict = OutpostRequest.from_dict(outpost_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OutpostTypeEnum.md b/docs/OutpostTypeEnum.md new file mode 100644 index 000000000..b6d9b89ea --- /dev/null +++ b/docs/OutpostTypeEnum.md @@ -0,0 +1,16 @@ +# OutpostTypeEnum + + +## Enum + +* `PROXY` (value: `'proxy'`) + +* `LDAP` (value: `'ldap'`) + +* `RADIUS` (value: `'radius'`) + +* `RAC` (value: `'rac'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/OutpostsApi.md b/docs/OutpostsApi.md new file mode 100644 index 000000000..ad7065456 --- /dev/null +++ b/docs/OutpostsApi.md @@ -0,0 +1,2765 @@ +# authentik_client.OutpostsApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**outposts_instances_create**](OutpostsApi.md#outposts_instances_create) | **POST** /outposts/instances/ | +[**outposts_instances_default_settings_retrieve**](OutpostsApi.md#outposts_instances_default_settings_retrieve) | **GET** /outposts/instances/default_settings/ | +[**outposts_instances_destroy**](OutpostsApi.md#outposts_instances_destroy) | **DELETE** /outposts/instances/{uuid}/ | +[**outposts_instances_health_list**](OutpostsApi.md#outposts_instances_health_list) | **GET** /outposts/instances/{uuid}/health/ | +[**outposts_instances_list**](OutpostsApi.md#outposts_instances_list) | **GET** /outposts/instances/ | +[**outposts_instances_partial_update**](OutpostsApi.md#outposts_instances_partial_update) | **PATCH** /outposts/instances/{uuid}/ | +[**outposts_instances_retrieve**](OutpostsApi.md#outposts_instances_retrieve) | **GET** /outposts/instances/{uuid}/ | +[**outposts_instances_update**](OutpostsApi.md#outposts_instances_update) | **PUT** /outposts/instances/{uuid}/ | +[**outposts_instances_used_by_list**](OutpostsApi.md#outposts_instances_used_by_list) | **GET** /outposts/instances/{uuid}/used_by/ | +[**outposts_ldap_access_check**](OutpostsApi.md#outposts_ldap_access_check) | **GET** /outposts/ldap/{id}/check_access/ | +[**outposts_ldap_list**](OutpostsApi.md#outposts_ldap_list) | **GET** /outposts/ldap/ | +[**outposts_proxy_list**](OutpostsApi.md#outposts_proxy_list) | **GET** /outposts/proxy/ | +[**outposts_radius_access_check**](OutpostsApi.md#outposts_radius_access_check) | **GET** /outposts/radius/{id}/check_access/ | +[**outposts_radius_list**](OutpostsApi.md#outposts_radius_list) | **GET** /outposts/radius/ | +[**outposts_service_connections_all_destroy**](OutpostsApi.md#outposts_service_connections_all_destroy) | **DELETE** /outposts/service_connections/all/{uuid}/ | +[**outposts_service_connections_all_list**](OutpostsApi.md#outposts_service_connections_all_list) | **GET** /outposts/service_connections/all/ | +[**outposts_service_connections_all_retrieve**](OutpostsApi.md#outposts_service_connections_all_retrieve) | **GET** /outposts/service_connections/all/{uuid}/ | +[**outposts_service_connections_all_state_retrieve**](OutpostsApi.md#outposts_service_connections_all_state_retrieve) | **GET** /outposts/service_connections/all/{uuid}/state/ | +[**outposts_service_connections_all_types_list**](OutpostsApi.md#outposts_service_connections_all_types_list) | **GET** /outposts/service_connections/all/types/ | +[**outposts_service_connections_all_used_by_list**](OutpostsApi.md#outposts_service_connections_all_used_by_list) | **GET** /outposts/service_connections/all/{uuid}/used_by/ | +[**outposts_service_connections_docker_create**](OutpostsApi.md#outposts_service_connections_docker_create) | **POST** /outposts/service_connections/docker/ | +[**outposts_service_connections_docker_destroy**](OutpostsApi.md#outposts_service_connections_docker_destroy) | **DELETE** /outposts/service_connections/docker/{uuid}/ | +[**outposts_service_connections_docker_list**](OutpostsApi.md#outposts_service_connections_docker_list) | **GET** /outposts/service_connections/docker/ | +[**outposts_service_connections_docker_partial_update**](OutpostsApi.md#outposts_service_connections_docker_partial_update) | **PATCH** /outposts/service_connections/docker/{uuid}/ | +[**outposts_service_connections_docker_retrieve**](OutpostsApi.md#outposts_service_connections_docker_retrieve) | **GET** /outposts/service_connections/docker/{uuid}/ | +[**outposts_service_connections_docker_update**](OutpostsApi.md#outposts_service_connections_docker_update) | **PUT** /outposts/service_connections/docker/{uuid}/ | +[**outposts_service_connections_docker_used_by_list**](OutpostsApi.md#outposts_service_connections_docker_used_by_list) | **GET** /outposts/service_connections/docker/{uuid}/used_by/ | +[**outposts_service_connections_kubernetes_create**](OutpostsApi.md#outposts_service_connections_kubernetes_create) | **POST** /outposts/service_connections/kubernetes/ | +[**outposts_service_connections_kubernetes_destroy**](OutpostsApi.md#outposts_service_connections_kubernetes_destroy) | **DELETE** /outposts/service_connections/kubernetes/{uuid}/ | +[**outposts_service_connections_kubernetes_list**](OutpostsApi.md#outposts_service_connections_kubernetes_list) | **GET** /outposts/service_connections/kubernetes/ | +[**outposts_service_connections_kubernetes_partial_update**](OutpostsApi.md#outposts_service_connections_kubernetes_partial_update) | **PATCH** /outposts/service_connections/kubernetes/{uuid}/ | +[**outposts_service_connections_kubernetes_retrieve**](OutpostsApi.md#outposts_service_connections_kubernetes_retrieve) | **GET** /outposts/service_connections/kubernetes/{uuid}/ | +[**outposts_service_connections_kubernetes_update**](OutpostsApi.md#outposts_service_connections_kubernetes_update) | **PUT** /outposts/service_connections/kubernetes/{uuid}/ | +[**outposts_service_connections_kubernetes_used_by_list**](OutpostsApi.md#outposts_service_connections_kubernetes_used_by_list) | **GET** /outposts/service_connections/kubernetes/{uuid}/used_by/ | + + +# **outposts_instances_create** +> Outpost outposts_instances_create(outpost_request) + +Outpost Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.outpost import Outpost +from authentik_client.models.outpost_request import OutpostRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + outpost_request = authentik_client.OutpostRequest() # OutpostRequest | + + try: + api_response = api_instance.outposts_instances_create(outpost_request) + print("The response of OutpostsApi->outposts_instances_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_instances_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **outpost_request** | [**OutpostRequest**](OutpostRequest.md)| | + +### Return type + +[**Outpost**](Outpost.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_instances_default_settings_retrieve** +> OutpostDefaultConfig outposts_instances_default_settings_retrieve() + +Global default outpost config + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.outpost_default_config import OutpostDefaultConfig +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + + try: + api_response = api_instance.outposts_instances_default_settings_retrieve() + print("The response of OutpostsApi->outposts_instances_default_settings_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_instances_default_settings_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**OutpostDefaultConfig**](OutpostDefaultConfig.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_instances_destroy** +> outposts_instances_destroy(uuid) + +Outpost Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost. + + try: + api_instance.outposts_instances_destroy(uuid) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_instances_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_instances_health_list** +> List[OutpostHealth] outposts_instances_health_list(uuid, managed__icontains=managed__icontains, managed__iexact=managed__iexact, name__icontains=name__icontains, name__iexact=name__iexact, ordering=ordering, providers__isnull=providers__isnull, providers_by_pk=providers_by_pk, search=search, service_connection__name__icontains=service_connection__name__icontains, service_connection__name__iexact=service_connection__name__iexact) + +Get outposts current health + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.outpost_health import OutpostHealth +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost. + managed__icontains = 'managed__icontains_example' # str | (optional) + managed__iexact = 'managed__iexact_example' # str | (optional) + name__icontains = 'name__icontains_example' # str | (optional) + name__iexact = 'name__iexact_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + providers__isnull = True # bool | (optional) + providers_by_pk = [56] # List[int] | (optional) + search = 'search_example' # str | A search term. (optional) + service_connection__name__icontains = 'service_connection__name__icontains_example' # str | (optional) + service_connection__name__iexact = 'service_connection__name__iexact_example' # str | (optional) + + try: + api_response = api_instance.outposts_instances_health_list(uuid, managed__icontains=managed__icontains, managed__iexact=managed__iexact, name__icontains=name__icontains, name__iexact=name__iexact, ordering=ordering, providers__isnull=providers__isnull, providers_by_pk=providers_by_pk, search=search, service_connection__name__icontains=service_connection__name__icontains, service_connection__name__iexact=service_connection__name__iexact) + print("The response of OutpostsApi->outposts_instances_health_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_instances_health_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost. | + **managed__icontains** | **str**| | [optional] + **managed__iexact** | **str**| | [optional] + **name__icontains** | **str**| | [optional] + **name__iexact** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **providers__isnull** | **bool**| | [optional] + **providers_by_pk** | [**List[int]**](int.md)| | [optional] + **search** | **str**| A search term. | [optional] + **service_connection__name__icontains** | **str**| | [optional] + **service_connection__name__iexact** | **str**| | [optional] + +### Return type + +[**List[OutpostHealth]**](OutpostHealth.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_instances_list** +> PaginatedOutpostList outposts_instances_list(managed__icontains=managed__icontains, managed__iexact=managed__iexact, name__icontains=name__icontains, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, providers__isnull=providers__isnull, providers_by_pk=providers_by_pk, search=search, service_connection__name__icontains=service_connection__name__icontains, service_connection__name__iexact=service_connection__name__iexact) + +Outpost Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_outpost_list import PaginatedOutpostList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + managed__icontains = 'managed__icontains_example' # str | (optional) + managed__iexact = 'managed__iexact_example' # str | (optional) + name__icontains = 'name__icontains_example' # str | (optional) + name__iexact = 'name__iexact_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + providers__isnull = True # bool | (optional) + providers_by_pk = [56] # List[int] | (optional) + search = 'search_example' # str | A search term. (optional) + service_connection__name__icontains = 'service_connection__name__icontains_example' # str | (optional) + service_connection__name__iexact = 'service_connection__name__iexact_example' # str | (optional) + + try: + api_response = api_instance.outposts_instances_list(managed__icontains=managed__icontains, managed__iexact=managed__iexact, name__icontains=name__icontains, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, providers__isnull=providers__isnull, providers_by_pk=providers_by_pk, search=search, service_connection__name__icontains=service_connection__name__icontains, service_connection__name__iexact=service_connection__name__iexact) + print("The response of OutpostsApi->outposts_instances_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_instances_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed__icontains** | **str**| | [optional] + **managed__iexact** | **str**| | [optional] + **name__icontains** | **str**| | [optional] + **name__iexact** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **providers__isnull** | **bool**| | [optional] + **providers_by_pk** | [**List[int]**](int.md)| | [optional] + **search** | **str**| A search term. | [optional] + **service_connection__name__icontains** | **str**| | [optional] + **service_connection__name__iexact** | **str**| | [optional] + +### Return type + +[**PaginatedOutpostList**](PaginatedOutpostList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_instances_partial_update** +> Outpost outposts_instances_partial_update(uuid, patched_outpost_request=patched_outpost_request) + +Outpost Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.outpost import Outpost +from authentik_client.models.patched_outpost_request import PatchedOutpostRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost. + patched_outpost_request = authentik_client.PatchedOutpostRequest() # PatchedOutpostRequest | (optional) + + try: + api_response = api_instance.outposts_instances_partial_update(uuid, patched_outpost_request=patched_outpost_request) + print("The response of OutpostsApi->outposts_instances_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_instances_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost. | + **patched_outpost_request** | [**PatchedOutpostRequest**](PatchedOutpostRequest.md)| | [optional] + +### Return type + +[**Outpost**](Outpost.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_instances_retrieve** +> Outpost outposts_instances_retrieve(uuid) + +Outpost Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.outpost import Outpost +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost. + + try: + api_response = api_instance.outposts_instances_retrieve(uuid) + print("The response of OutpostsApi->outposts_instances_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_instances_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost. | + +### Return type + +[**Outpost**](Outpost.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_instances_update** +> Outpost outposts_instances_update(uuid, outpost_request) + +Outpost Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.outpost import Outpost +from authentik_client.models.outpost_request import OutpostRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost. + outpost_request = authentik_client.OutpostRequest() # OutpostRequest | + + try: + api_response = api_instance.outposts_instances_update(uuid, outpost_request) + print("The response of OutpostsApi->outposts_instances_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_instances_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost. | + **outpost_request** | [**OutpostRequest**](OutpostRequest.md)| | + +### Return type + +[**Outpost**](Outpost.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_instances_used_by_list** +> List[UsedBy] outposts_instances_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost. + + try: + api_response = api_instance.outposts_instances_used_by_list(uuid) + print("The response of OutpostsApi->outposts_instances_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_instances_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_ldap_access_check** +> LDAPCheckAccess outposts_ldap_access_check(id, app_slug=app_slug) + +Check access to a single application by slug + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_check_access import LDAPCheckAccess +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + id = 56 # int | A unique integer value identifying this LDAP Provider. + app_slug = 'app_slug_example' # str | (optional) + + try: + api_response = api_instance.outposts_ldap_access_check(id, app_slug=app_slug) + print("The response of OutpostsApi->outposts_ldap_access_check:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_ldap_access_check: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this LDAP Provider. | + **app_slug** | **str**| | [optional] + +### Return type + +[**LDAPCheckAccess**](LDAPCheckAccess.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_ldap_list** +> PaginatedLDAPOutpostConfigList outposts_ldap_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +LDAPProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_ldap_outpost_config_list import PaginatedLDAPOutpostConfigList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.outposts_ldap_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of OutpostsApi->outposts_ldap_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_ldap_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedLDAPOutpostConfigList**](PaginatedLDAPOutpostConfigList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_proxy_list** +> PaginatedProxyOutpostConfigList outposts_proxy_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +ProxyProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_proxy_outpost_config_list import PaginatedProxyOutpostConfigList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.outposts_proxy_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of OutpostsApi->outposts_proxy_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_proxy_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedProxyOutpostConfigList**](PaginatedProxyOutpostConfigList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_radius_access_check** +> RadiusCheckAccess outposts_radius_access_check(id, app_slug=app_slug) + +Check access to a single application by slug + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.radius_check_access import RadiusCheckAccess +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + id = 56 # int | A unique integer value identifying this Radius Provider. + app_slug = 'app_slug_example' # str | (optional) + + try: + api_response = api_instance.outposts_radius_access_check(id, app_slug=app_slug) + print("The response of OutpostsApi->outposts_radius_access_check:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_radius_access_check: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Radius Provider. | + **app_slug** | **str**| | [optional] + +### Return type + +[**RadiusCheckAccess**](RadiusCheckAccess.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_radius_list** +> PaginatedRadiusOutpostConfigList outposts_radius_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +RadiusProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_radius_outpost_config_list import PaginatedRadiusOutpostConfigList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.outposts_radius_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of OutpostsApi->outposts_radius_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_radius_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedRadiusOutpostConfigList**](PaginatedRadiusOutpostConfigList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_all_destroy** +> outposts_service_connections_all_destroy(uuid) + +ServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost Service-Connection. + + try: + api_instance.outposts_service_connections_all_destroy(uuid) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_all_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost Service-Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_all_list** +> PaginatedServiceConnectionList outposts_service_connections_all_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +ServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_service_connection_list import PaginatedServiceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.outposts_service_connections_all_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of OutpostsApi->outposts_service_connections_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_all_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedServiceConnectionList**](PaginatedServiceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_all_retrieve** +> ServiceConnection outposts_service_connections_all_retrieve(uuid) + +ServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.service_connection import ServiceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost Service-Connection. + + try: + api_response = api_instance.outposts_service_connections_all_retrieve(uuid) + print("The response of OutpostsApi->outposts_service_connections_all_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_all_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost Service-Connection. | + +### Return type + +[**ServiceConnection**](ServiceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_all_state_retrieve** +> ServiceConnectionState outposts_service_connections_all_state_retrieve(uuid) + +Get the service connection's state + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.service_connection_state import ServiceConnectionState +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost Service-Connection. + + try: + api_response = api_instance.outposts_service_connections_all_state_retrieve(uuid) + print("The response of OutpostsApi->outposts_service_connections_all_state_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_all_state_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost Service-Connection. | + +### Return type + +[**ServiceConnectionState**](ServiceConnectionState.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_all_types_list** +> List[TypeCreate] outposts_service_connections_all_types_list() + +Get all creatable types + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.type_create import TypeCreate +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + + try: + api_response = api_instance.outposts_service_connections_all_types_list() + print("The response of OutpostsApi->outposts_service_connections_all_types_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_all_types_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[TypeCreate]**](TypeCreate.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_all_used_by_list** +> List[UsedBy] outposts_service_connections_all_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Outpost Service-Connection. + + try: + api_response = api_instance.outposts_service_connections_all_used_by_list(uuid) + print("The response of OutpostsApi->outposts_service_connections_all_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_all_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Outpost Service-Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_docker_create** +> DockerServiceConnection outposts_service_connections_docker_create(docker_service_connection_request) + +DockerServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.docker_service_connection import DockerServiceConnection +from authentik_client.models.docker_service_connection_request import DockerServiceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + docker_service_connection_request = authentik_client.DockerServiceConnectionRequest() # DockerServiceConnectionRequest | + + try: + api_response = api_instance.outposts_service_connections_docker_create(docker_service_connection_request) + print("The response of OutpostsApi->outposts_service_connections_docker_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_docker_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **docker_service_connection_request** | [**DockerServiceConnectionRequest**](DockerServiceConnectionRequest.md)| | + +### Return type + +[**DockerServiceConnection**](DockerServiceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_docker_destroy** +> outposts_service_connections_docker_destroy(uuid) + +DockerServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Docker Service-Connection. + + try: + api_instance.outposts_service_connections_docker_destroy(uuid) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_docker_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Docker Service-Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_docker_list** +> PaginatedDockerServiceConnectionList outposts_service_connections_docker_list(local=local, name=name, ordering=ordering, page=page, page_size=page_size, search=search, tls_authentication=tls_authentication, tls_verification=tls_verification, url=url) + +DockerServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_docker_service_connection_list import PaginatedDockerServiceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + local = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + tls_authentication = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + tls_verification = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + url = 'url_example' # str | (optional) + + try: + api_response = api_instance.outposts_service_connections_docker_list(local=local, name=name, ordering=ordering, page=page, page_size=page_size, search=search, tls_authentication=tls_authentication, tls_verification=tls_verification, url=url) + print("The response of OutpostsApi->outposts_service_connections_docker_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_docker_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **local** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **tls_authentication** | **UUID**| | [optional] + **tls_verification** | **UUID**| | [optional] + **url** | **str**| | [optional] + +### Return type + +[**PaginatedDockerServiceConnectionList**](PaginatedDockerServiceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_docker_partial_update** +> DockerServiceConnection outposts_service_connections_docker_partial_update(uuid, patched_docker_service_connection_request=patched_docker_service_connection_request) + +DockerServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.docker_service_connection import DockerServiceConnection +from authentik_client.models.patched_docker_service_connection_request import PatchedDockerServiceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Docker Service-Connection. + patched_docker_service_connection_request = authentik_client.PatchedDockerServiceConnectionRequest() # PatchedDockerServiceConnectionRequest | (optional) + + try: + api_response = api_instance.outposts_service_connections_docker_partial_update(uuid, patched_docker_service_connection_request=patched_docker_service_connection_request) + print("The response of OutpostsApi->outposts_service_connections_docker_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_docker_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Docker Service-Connection. | + **patched_docker_service_connection_request** | [**PatchedDockerServiceConnectionRequest**](PatchedDockerServiceConnectionRequest.md)| | [optional] + +### Return type + +[**DockerServiceConnection**](DockerServiceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_docker_retrieve** +> DockerServiceConnection outposts_service_connections_docker_retrieve(uuid) + +DockerServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.docker_service_connection import DockerServiceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Docker Service-Connection. + + try: + api_response = api_instance.outposts_service_connections_docker_retrieve(uuid) + print("The response of OutpostsApi->outposts_service_connections_docker_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_docker_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Docker Service-Connection. | + +### Return type + +[**DockerServiceConnection**](DockerServiceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_docker_update** +> DockerServiceConnection outposts_service_connections_docker_update(uuid, docker_service_connection_request) + +DockerServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.docker_service_connection import DockerServiceConnection +from authentik_client.models.docker_service_connection_request import DockerServiceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Docker Service-Connection. + docker_service_connection_request = authentik_client.DockerServiceConnectionRequest() # DockerServiceConnectionRequest | + + try: + api_response = api_instance.outposts_service_connections_docker_update(uuid, docker_service_connection_request) + print("The response of OutpostsApi->outposts_service_connections_docker_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_docker_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Docker Service-Connection. | + **docker_service_connection_request** | [**DockerServiceConnectionRequest**](DockerServiceConnectionRequest.md)| | + +### Return type + +[**DockerServiceConnection**](DockerServiceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_docker_used_by_list** +> List[UsedBy] outposts_service_connections_docker_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Docker Service-Connection. + + try: + api_response = api_instance.outposts_service_connections_docker_used_by_list(uuid) + print("The response of OutpostsApi->outposts_service_connections_docker_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_docker_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Docker Service-Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_kubernetes_create** +> KubernetesServiceConnection outposts_service_connections_kubernetes_create(kubernetes_service_connection_request) + +KubernetesServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection +from authentik_client.models.kubernetes_service_connection_request import KubernetesServiceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + kubernetes_service_connection_request = authentik_client.KubernetesServiceConnectionRequest() # KubernetesServiceConnectionRequest | + + try: + api_response = api_instance.outposts_service_connections_kubernetes_create(kubernetes_service_connection_request) + print("The response of OutpostsApi->outposts_service_connections_kubernetes_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_kubernetes_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kubernetes_service_connection_request** | [**KubernetesServiceConnectionRequest**](KubernetesServiceConnectionRequest.md)| | + +### Return type + +[**KubernetesServiceConnection**](KubernetesServiceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_kubernetes_destroy** +> outposts_service_connections_kubernetes_destroy(uuid) + +KubernetesServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kubernetes Service-Connection. + + try: + api_instance.outposts_service_connections_kubernetes_destroy(uuid) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_kubernetes_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Kubernetes Service-Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_kubernetes_list** +> PaginatedKubernetesServiceConnectionList outposts_service_connections_kubernetes_list(local=local, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +KubernetesServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_kubernetes_service_connection_list import PaginatedKubernetesServiceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + local = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.outposts_service_connections_kubernetes_list(local=local, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of OutpostsApi->outposts_service_connections_kubernetes_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_kubernetes_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **local** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedKubernetesServiceConnectionList**](PaginatedKubernetesServiceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_kubernetes_partial_update** +> KubernetesServiceConnection outposts_service_connections_kubernetes_partial_update(uuid, patched_kubernetes_service_connection_request=patched_kubernetes_service_connection_request) + +KubernetesServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection +from authentik_client.models.patched_kubernetes_service_connection_request import PatchedKubernetesServiceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kubernetes Service-Connection. + patched_kubernetes_service_connection_request = authentik_client.PatchedKubernetesServiceConnectionRequest() # PatchedKubernetesServiceConnectionRequest | (optional) + + try: + api_response = api_instance.outposts_service_connections_kubernetes_partial_update(uuid, patched_kubernetes_service_connection_request=patched_kubernetes_service_connection_request) + print("The response of OutpostsApi->outposts_service_connections_kubernetes_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_kubernetes_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Kubernetes Service-Connection. | + **patched_kubernetes_service_connection_request** | [**PatchedKubernetesServiceConnectionRequest**](PatchedKubernetesServiceConnectionRequest.md)| | [optional] + +### Return type + +[**KubernetesServiceConnection**](KubernetesServiceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_kubernetes_retrieve** +> KubernetesServiceConnection outposts_service_connections_kubernetes_retrieve(uuid) + +KubernetesServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kubernetes Service-Connection. + + try: + api_response = api_instance.outposts_service_connections_kubernetes_retrieve(uuid) + print("The response of OutpostsApi->outposts_service_connections_kubernetes_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_kubernetes_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Kubernetes Service-Connection. | + +### Return type + +[**KubernetesServiceConnection**](KubernetesServiceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_kubernetes_update** +> KubernetesServiceConnection outposts_service_connections_kubernetes_update(uuid, kubernetes_service_connection_request) + +KubernetesServiceConnection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection +from authentik_client.models.kubernetes_service_connection_request import KubernetesServiceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kubernetes Service-Connection. + kubernetes_service_connection_request = authentik_client.KubernetesServiceConnectionRequest() # KubernetesServiceConnectionRequest | + + try: + api_response = api_instance.outposts_service_connections_kubernetes_update(uuid, kubernetes_service_connection_request) + print("The response of OutpostsApi->outposts_service_connections_kubernetes_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_kubernetes_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Kubernetes Service-Connection. | + **kubernetes_service_connection_request** | [**KubernetesServiceConnectionRequest**](KubernetesServiceConnectionRequest.md)| | + +### Return type + +[**KubernetesServiceConnection**](KubernetesServiceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **outposts_service_connections_kubernetes_used_by_list** +> List[UsedBy] outposts_service_connections_kubernetes_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.OutpostsApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kubernetes Service-Connection. + + try: + api_response = api_instance.outposts_service_connections_kubernetes_used_by_list(uuid) + print("The response of OutpostsApi->outposts_service_connections_kubernetes_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling OutpostsApi->outposts_service_connections_kubernetes_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Kubernetes Service-Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/PKCEMethodEnum.md b/docs/PKCEMethodEnum.md new file mode 100644 index 000000000..90c65e277 --- /dev/null +++ b/docs/PKCEMethodEnum.md @@ -0,0 +1,14 @@ +# PKCEMethodEnum + + +## Enum + +* `NONE` (value: `'none'`) + +* `PLAIN` (value: `'plain'`) + +* `S256` (value: `'S256'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAccountLockdownStageList.md b/docs/PaginatedAccountLockdownStageList.md new file mode 100644 index 000000000..82f1562a3 --- /dev/null +++ b/docs/PaginatedAccountLockdownStageList.md @@ -0,0 +1,31 @@ +# PaginatedAccountLockdownStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AccountLockdownStage]**](AccountLockdownStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_account_lockdown_stage_list import PaginatedAccountLockdownStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAccountLockdownStageList from a JSON string +paginated_account_lockdown_stage_list_instance = PaginatedAccountLockdownStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAccountLockdownStageList.to_json()) + +# convert the object into a dict +paginated_account_lockdown_stage_list_dict = paginated_account_lockdown_stage_list_instance.to_dict() +# create an instance of PaginatedAccountLockdownStageList from a dict +paginated_account_lockdown_stage_list_from_dict = PaginatedAccountLockdownStageList.from_dict(paginated_account_lockdown_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAgentConnectorList.md b/docs/PaginatedAgentConnectorList.md new file mode 100644 index 000000000..799d30f71 --- /dev/null +++ b/docs/PaginatedAgentConnectorList.md @@ -0,0 +1,31 @@ +# PaginatedAgentConnectorList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AgentConnector]**](AgentConnector.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_agent_connector_list import PaginatedAgentConnectorList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAgentConnectorList from a JSON string +paginated_agent_connector_list_instance = PaginatedAgentConnectorList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAgentConnectorList.to_json()) + +# convert the object into a dict +paginated_agent_connector_list_dict = paginated_agent_connector_list_instance.to_dict() +# create an instance of PaginatedAgentConnectorList from a dict +paginated_agent_connector_list_from_dict = PaginatedAgentConnectorList.from_dict(paginated_agent_connector_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAppleIndependentSecureEnclaveList.md b/docs/PaginatedAppleIndependentSecureEnclaveList.md new file mode 100644 index 000000000..2e6a50f83 --- /dev/null +++ b/docs/PaginatedAppleIndependentSecureEnclaveList.md @@ -0,0 +1,31 @@ +# PaginatedAppleIndependentSecureEnclaveList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AppleIndependentSecureEnclave]**](AppleIndependentSecureEnclave.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_apple_independent_secure_enclave_list import PaginatedAppleIndependentSecureEnclaveList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAppleIndependentSecureEnclaveList from a JSON string +paginated_apple_independent_secure_enclave_list_instance = PaginatedAppleIndependentSecureEnclaveList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAppleIndependentSecureEnclaveList.to_json()) + +# convert the object into a dict +paginated_apple_independent_secure_enclave_list_dict = paginated_apple_independent_secure_enclave_list_instance.to_dict() +# create an instance of PaginatedAppleIndependentSecureEnclaveList from a dict +paginated_apple_independent_secure_enclave_list_from_dict = PaginatedAppleIndependentSecureEnclaveList.from_dict(paginated_apple_independent_secure_enclave_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedApplicationEntitlementList.md b/docs/PaginatedApplicationEntitlementList.md new file mode 100644 index 000000000..6647fa356 --- /dev/null +++ b/docs/PaginatedApplicationEntitlementList.md @@ -0,0 +1,31 @@ +# PaginatedApplicationEntitlementList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ApplicationEntitlement]**](ApplicationEntitlement.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_application_entitlement_list import PaginatedApplicationEntitlementList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedApplicationEntitlementList from a JSON string +paginated_application_entitlement_list_instance = PaginatedApplicationEntitlementList.from_json(json) +# print the JSON string representation of the object +print(PaginatedApplicationEntitlementList.to_json()) + +# convert the object into a dict +paginated_application_entitlement_list_dict = paginated_application_entitlement_list_instance.to_dict() +# create an instance of PaginatedApplicationEntitlementList from a dict +paginated_application_entitlement_list_from_dict = PaginatedApplicationEntitlementList.from_dict(paginated_application_entitlement_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedApplicationList.md b/docs/PaginatedApplicationList.md new file mode 100644 index 000000000..24bd3116b --- /dev/null +++ b/docs/PaginatedApplicationList.md @@ -0,0 +1,31 @@ +# PaginatedApplicationList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Application]**](Application.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_application_list import PaginatedApplicationList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedApplicationList from a JSON string +paginated_application_list_instance = PaginatedApplicationList.from_json(json) +# print the JSON string representation of the object +print(PaginatedApplicationList.to_json()) + +# convert the object into a dict +paginated_application_list_dict = paginated_application_list_instance.to_dict() +# create an instance of PaginatedApplicationList from a dict +paginated_application_list_from_dict = PaginatedApplicationList.from_dict(paginated_application_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAuthenticatedSessionList.md b/docs/PaginatedAuthenticatedSessionList.md new file mode 100644 index 000000000..e34d84168 --- /dev/null +++ b/docs/PaginatedAuthenticatedSessionList.md @@ -0,0 +1,31 @@ +# PaginatedAuthenticatedSessionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AuthenticatedSession]**](AuthenticatedSession.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_authenticated_session_list import PaginatedAuthenticatedSessionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAuthenticatedSessionList from a JSON string +paginated_authenticated_session_list_instance = PaginatedAuthenticatedSessionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAuthenticatedSessionList.to_json()) + +# convert the object into a dict +paginated_authenticated_session_list_dict = paginated_authenticated_session_list_instance.to_dict() +# create an instance of PaginatedAuthenticatedSessionList from a dict +paginated_authenticated_session_list_from_dict = PaginatedAuthenticatedSessionList.from_dict(paginated_authenticated_session_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAuthenticatorDuoStageList.md b/docs/PaginatedAuthenticatorDuoStageList.md new file mode 100644 index 000000000..333e7f98c --- /dev/null +++ b/docs/PaginatedAuthenticatorDuoStageList.md @@ -0,0 +1,31 @@ +# PaginatedAuthenticatorDuoStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AuthenticatorDuoStage]**](AuthenticatorDuoStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_authenticator_duo_stage_list import PaginatedAuthenticatorDuoStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAuthenticatorDuoStageList from a JSON string +paginated_authenticator_duo_stage_list_instance = PaginatedAuthenticatorDuoStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAuthenticatorDuoStageList.to_json()) + +# convert the object into a dict +paginated_authenticator_duo_stage_list_dict = paginated_authenticator_duo_stage_list_instance.to_dict() +# create an instance of PaginatedAuthenticatorDuoStageList from a dict +paginated_authenticator_duo_stage_list_from_dict = PaginatedAuthenticatorDuoStageList.from_dict(paginated_authenticator_duo_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAuthenticatorEmailStageList.md b/docs/PaginatedAuthenticatorEmailStageList.md new file mode 100644 index 000000000..150e4e7d8 --- /dev/null +++ b/docs/PaginatedAuthenticatorEmailStageList.md @@ -0,0 +1,31 @@ +# PaginatedAuthenticatorEmailStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AuthenticatorEmailStage]**](AuthenticatorEmailStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_authenticator_email_stage_list import PaginatedAuthenticatorEmailStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAuthenticatorEmailStageList from a JSON string +paginated_authenticator_email_stage_list_instance = PaginatedAuthenticatorEmailStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAuthenticatorEmailStageList.to_json()) + +# convert the object into a dict +paginated_authenticator_email_stage_list_dict = paginated_authenticator_email_stage_list_instance.to_dict() +# create an instance of PaginatedAuthenticatorEmailStageList from a dict +paginated_authenticator_email_stage_list_from_dict = PaginatedAuthenticatorEmailStageList.from_dict(paginated_authenticator_email_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAuthenticatorEndpointGDTCStageList.md b/docs/PaginatedAuthenticatorEndpointGDTCStageList.md new file mode 100644 index 000000000..a56583dc8 --- /dev/null +++ b/docs/PaginatedAuthenticatorEndpointGDTCStageList.md @@ -0,0 +1,31 @@ +# PaginatedAuthenticatorEndpointGDTCStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AuthenticatorEndpointGDTCStage]**](AuthenticatorEndpointGDTCStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_authenticator_endpoint_gdtc_stage_list import PaginatedAuthenticatorEndpointGDTCStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAuthenticatorEndpointGDTCStageList from a JSON string +paginated_authenticator_endpoint_gdtc_stage_list_instance = PaginatedAuthenticatorEndpointGDTCStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAuthenticatorEndpointGDTCStageList.to_json()) + +# convert the object into a dict +paginated_authenticator_endpoint_gdtc_stage_list_dict = paginated_authenticator_endpoint_gdtc_stage_list_instance.to_dict() +# create an instance of PaginatedAuthenticatorEndpointGDTCStageList from a dict +paginated_authenticator_endpoint_gdtc_stage_list_from_dict = PaginatedAuthenticatorEndpointGDTCStageList.from_dict(paginated_authenticator_endpoint_gdtc_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAuthenticatorSMSStageList.md b/docs/PaginatedAuthenticatorSMSStageList.md new file mode 100644 index 000000000..d6caedca6 --- /dev/null +++ b/docs/PaginatedAuthenticatorSMSStageList.md @@ -0,0 +1,31 @@ +# PaginatedAuthenticatorSMSStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AuthenticatorSMSStage]**](AuthenticatorSMSStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_authenticator_sms_stage_list import PaginatedAuthenticatorSMSStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAuthenticatorSMSStageList from a JSON string +paginated_authenticator_sms_stage_list_instance = PaginatedAuthenticatorSMSStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAuthenticatorSMSStageList.to_json()) + +# convert the object into a dict +paginated_authenticator_sms_stage_list_dict = paginated_authenticator_sms_stage_list_instance.to_dict() +# create an instance of PaginatedAuthenticatorSMSStageList from a dict +paginated_authenticator_sms_stage_list_from_dict = PaginatedAuthenticatorSMSStageList.from_dict(paginated_authenticator_sms_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAuthenticatorStaticStageList.md b/docs/PaginatedAuthenticatorStaticStageList.md new file mode 100644 index 000000000..1a2b3aaac --- /dev/null +++ b/docs/PaginatedAuthenticatorStaticStageList.md @@ -0,0 +1,31 @@ +# PaginatedAuthenticatorStaticStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AuthenticatorStaticStage]**](AuthenticatorStaticStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_authenticator_static_stage_list import PaginatedAuthenticatorStaticStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAuthenticatorStaticStageList from a JSON string +paginated_authenticator_static_stage_list_instance = PaginatedAuthenticatorStaticStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAuthenticatorStaticStageList.to_json()) + +# convert the object into a dict +paginated_authenticator_static_stage_list_dict = paginated_authenticator_static_stage_list_instance.to_dict() +# create an instance of PaginatedAuthenticatorStaticStageList from a dict +paginated_authenticator_static_stage_list_from_dict = PaginatedAuthenticatorStaticStageList.from_dict(paginated_authenticator_static_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAuthenticatorTOTPStageList.md b/docs/PaginatedAuthenticatorTOTPStageList.md new file mode 100644 index 000000000..1c55a1a71 --- /dev/null +++ b/docs/PaginatedAuthenticatorTOTPStageList.md @@ -0,0 +1,31 @@ +# PaginatedAuthenticatorTOTPStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AuthenticatorTOTPStage]**](AuthenticatorTOTPStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_authenticator_totp_stage_list import PaginatedAuthenticatorTOTPStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAuthenticatorTOTPStageList from a JSON string +paginated_authenticator_totp_stage_list_instance = PaginatedAuthenticatorTOTPStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAuthenticatorTOTPStageList.to_json()) + +# convert the object into a dict +paginated_authenticator_totp_stage_list_dict = paginated_authenticator_totp_stage_list_instance.to_dict() +# create an instance of PaginatedAuthenticatorTOTPStageList from a dict +paginated_authenticator_totp_stage_list_from_dict = PaginatedAuthenticatorTOTPStageList.from_dict(paginated_authenticator_totp_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAuthenticatorValidateStageList.md b/docs/PaginatedAuthenticatorValidateStageList.md new file mode 100644 index 000000000..c9e632790 --- /dev/null +++ b/docs/PaginatedAuthenticatorValidateStageList.md @@ -0,0 +1,31 @@ +# PaginatedAuthenticatorValidateStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AuthenticatorValidateStage]**](AuthenticatorValidateStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_authenticator_validate_stage_list import PaginatedAuthenticatorValidateStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAuthenticatorValidateStageList from a JSON string +paginated_authenticator_validate_stage_list_instance = PaginatedAuthenticatorValidateStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAuthenticatorValidateStageList.to_json()) + +# convert the object into a dict +paginated_authenticator_validate_stage_list_dict = paginated_authenticator_validate_stage_list_instance.to_dict() +# create an instance of PaginatedAuthenticatorValidateStageList from a dict +paginated_authenticator_validate_stage_list_from_dict = PaginatedAuthenticatorValidateStageList.from_dict(paginated_authenticator_validate_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedAuthenticatorWebAuthnStageList.md b/docs/PaginatedAuthenticatorWebAuthnStageList.md new file mode 100644 index 000000000..39a0219ca --- /dev/null +++ b/docs/PaginatedAuthenticatorWebAuthnStageList.md @@ -0,0 +1,31 @@ +# PaginatedAuthenticatorWebAuthnStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[AuthenticatorWebAuthnStage]**](AuthenticatorWebAuthnStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_authenticator_web_authn_stage_list import PaginatedAuthenticatorWebAuthnStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedAuthenticatorWebAuthnStageList from a JSON string +paginated_authenticator_web_authn_stage_list_instance = PaginatedAuthenticatorWebAuthnStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedAuthenticatorWebAuthnStageList.to_json()) + +# convert the object into a dict +paginated_authenticator_web_authn_stage_list_dict = paginated_authenticator_web_authn_stage_list_instance.to_dict() +# create an instance of PaginatedAuthenticatorWebAuthnStageList from a dict +paginated_authenticator_web_authn_stage_list_from_dict = PaginatedAuthenticatorWebAuthnStageList.from_dict(paginated_authenticator_web_authn_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedBlueprintInstanceList.md b/docs/PaginatedBlueprintInstanceList.md new file mode 100644 index 000000000..5b668b66a --- /dev/null +++ b/docs/PaginatedBlueprintInstanceList.md @@ -0,0 +1,31 @@ +# PaginatedBlueprintInstanceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[BlueprintInstance]**](BlueprintInstance.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_blueprint_instance_list import PaginatedBlueprintInstanceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedBlueprintInstanceList from a JSON string +paginated_blueprint_instance_list_instance = PaginatedBlueprintInstanceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedBlueprintInstanceList.to_json()) + +# convert the object into a dict +paginated_blueprint_instance_list_dict = paginated_blueprint_instance_list_instance.to_dict() +# create an instance of PaginatedBlueprintInstanceList from a dict +paginated_blueprint_instance_list_from_dict = PaginatedBlueprintInstanceList.from_dict(paginated_blueprint_instance_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedBrandList.md b/docs/PaginatedBrandList.md new file mode 100644 index 000000000..5db878d3d --- /dev/null +++ b/docs/PaginatedBrandList.md @@ -0,0 +1,31 @@ +# PaginatedBrandList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Brand]**](Brand.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_brand_list import PaginatedBrandList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedBrandList from a JSON string +paginated_brand_list_instance = PaginatedBrandList.from_json(json) +# print the JSON string representation of the object +print(PaginatedBrandList.to_json()) + +# convert the object into a dict +paginated_brand_list_dict = paginated_brand_list_instance.to_dict() +# create an instance of PaginatedBrandList from a dict +paginated_brand_list_from_dict = PaginatedBrandList.from_dict(paginated_brand_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedCaptchaStageList.md b/docs/PaginatedCaptchaStageList.md new file mode 100644 index 000000000..e7ed45b56 --- /dev/null +++ b/docs/PaginatedCaptchaStageList.md @@ -0,0 +1,31 @@ +# PaginatedCaptchaStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[CaptchaStage]**](CaptchaStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_captcha_stage_list import PaginatedCaptchaStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedCaptchaStageList from a JSON string +paginated_captcha_stage_list_instance = PaginatedCaptchaStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedCaptchaStageList.to_json()) + +# convert the object into a dict +paginated_captcha_stage_list_dict = paginated_captcha_stage_list_instance.to_dict() +# create an instance of PaginatedCaptchaStageList from a dict +paginated_captcha_stage_list_from_dict = PaginatedCaptchaStageList.from_dict(paginated_captcha_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedCertificateKeyPairList.md b/docs/PaginatedCertificateKeyPairList.md new file mode 100644 index 000000000..304101786 --- /dev/null +++ b/docs/PaginatedCertificateKeyPairList.md @@ -0,0 +1,31 @@ +# PaginatedCertificateKeyPairList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[CertificateKeyPair]**](CertificateKeyPair.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_certificate_key_pair_list import PaginatedCertificateKeyPairList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedCertificateKeyPairList from a JSON string +paginated_certificate_key_pair_list_instance = PaginatedCertificateKeyPairList.from_json(json) +# print the JSON string representation of the object +print(PaginatedCertificateKeyPairList.to_json()) + +# convert the object into a dict +paginated_certificate_key_pair_list_dict = paginated_certificate_key_pair_list_instance.to_dict() +# create an instance of PaginatedCertificateKeyPairList from a dict +paginated_certificate_key_pair_list_from_dict = PaginatedCertificateKeyPairList.from_dict(paginated_certificate_key_pair_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedConnectionTokenList.md b/docs/PaginatedConnectionTokenList.md new file mode 100644 index 000000000..618a63cf2 --- /dev/null +++ b/docs/PaginatedConnectionTokenList.md @@ -0,0 +1,31 @@ +# PaginatedConnectionTokenList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ConnectionToken]**](ConnectionToken.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_connection_token_list import PaginatedConnectionTokenList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedConnectionTokenList from a JSON string +paginated_connection_token_list_instance = PaginatedConnectionTokenList.from_json(json) +# print the JSON string representation of the object +print(PaginatedConnectionTokenList.to_json()) + +# convert the object into a dict +paginated_connection_token_list_dict = paginated_connection_token_list_instance.to_dict() +# create an instance of PaginatedConnectionTokenList from a dict +paginated_connection_token_list_from_dict = PaginatedConnectionTokenList.from_dict(paginated_connection_token_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedConnectorList.md b/docs/PaginatedConnectorList.md new file mode 100644 index 000000000..5808ab108 --- /dev/null +++ b/docs/PaginatedConnectorList.md @@ -0,0 +1,31 @@ +# PaginatedConnectorList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Connector]**](Connector.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_connector_list import PaginatedConnectorList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedConnectorList from a JSON string +paginated_connector_list_instance = PaginatedConnectorList.from_json(json) +# print the JSON string representation of the object +print(PaginatedConnectorList.to_json()) + +# convert the object into a dict +paginated_connector_list_dict = paginated_connector_list_instance.to_dict() +# create an instance of PaginatedConnectorList from a dict +paginated_connector_list_from_dict = PaginatedConnectorList.from_dict(paginated_connector_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedConsentStageList.md b/docs/PaginatedConsentStageList.md new file mode 100644 index 000000000..61bb87c61 --- /dev/null +++ b/docs/PaginatedConsentStageList.md @@ -0,0 +1,31 @@ +# PaginatedConsentStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ConsentStage]**](ConsentStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_consent_stage_list import PaginatedConsentStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedConsentStageList from a JSON string +paginated_consent_stage_list_instance = PaginatedConsentStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedConsentStageList.to_json()) + +# convert the object into a dict +paginated_consent_stage_list_dict = paginated_consent_stage_list_instance.to_dict() +# create an instance of PaginatedConsentStageList from a dict +paginated_consent_stage_list_from_dict = PaginatedConsentStageList.from_dict(paginated_consent_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedDataExportList.md b/docs/PaginatedDataExportList.md new file mode 100644 index 000000000..417a10307 --- /dev/null +++ b/docs/PaginatedDataExportList.md @@ -0,0 +1,31 @@ +# PaginatedDataExportList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[DataExport]**](DataExport.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_data_export_list import PaginatedDataExportList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedDataExportList from a JSON string +paginated_data_export_list_instance = PaginatedDataExportList.from_json(json) +# print the JSON string representation of the object +print(PaginatedDataExportList.to_json()) + +# convert the object into a dict +paginated_data_export_list_dict = paginated_data_export_list_instance.to_dict() +# create an instance of PaginatedDataExportList from a dict +paginated_data_export_list_from_dict = PaginatedDataExportList.from_dict(paginated_data_export_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedDenyStageList.md b/docs/PaginatedDenyStageList.md new file mode 100644 index 000000000..90fa3adb9 --- /dev/null +++ b/docs/PaginatedDenyStageList.md @@ -0,0 +1,31 @@ +# PaginatedDenyStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[DenyStage]**](DenyStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_deny_stage_list import PaginatedDenyStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedDenyStageList from a JSON string +paginated_deny_stage_list_instance = PaginatedDenyStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedDenyStageList.to_json()) + +# convert the object into a dict +paginated_deny_stage_list_dict = paginated_deny_stage_list_instance.to_dict() +# create an instance of PaginatedDenyStageList from a dict +paginated_deny_stage_list_from_dict = PaginatedDenyStageList.from_dict(paginated_deny_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedDeviceAccessGroupList.md b/docs/PaginatedDeviceAccessGroupList.md new file mode 100644 index 000000000..68ab4b61b --- /dev/null +++ b/docs/PaginatedDeviceAccessGroupList.md @@ -0,0 +1,31 @@ +# PaginatedDeviceAccessGroupList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[DeviceAccessGroup]**](DeviceAccessGroup.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_device_access_group_list import PaginatedDeviceAccessGroupList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedDeviceAccessGroupList from a JSON string +paginated_device_access_group_list_instance = PaginatedDeviceAccessGroupList.from_json(json) +# print the JSON string representation of the object +print(PaginatedDeviceAccessGroupList.to_json()) + +# convert the object into a dict +paginated_device_access_group_list_dict = paginated_device_access_group_list_instance.to_dict() +# create an instance of PaginatedDeviceAccessGroupList from a dict +paginated_device_access_group_list_from_dict = PaginatedDeviceAccessGroupList.from_dict(paginated_device_access_group_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedDeviceUserBindingList.md b/docs/PaginatedDeviceUserBindingList.md new file mode 100644 index 000000000..521ad15c4 --- /dev/null +++ b/docs/PaginatedDeviceUserBindingList.md @@ -0,0 +1,31 @@ +# PaginatedDeviceUserBindingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[DeviceUserBinding]**](DeviceUserBinding.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_device_user_binding_list import PaginatedDeviceUserBindingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedDeviceUserBindingList from a JSON string +paginated_device_user_binding_list_instance = PaginatedDeviceUserBindingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedDeviceUserBindingList.to_json()) + +# convert the object into a dict +paginated_device_user_binding_list_dict = paginated_device_user_binding_list_instance.to_dict() +# create an instance of PaginatedDeviceUserBindingList from a dict +paginated_device_user_binding_list_from_dict = PaginatedDeviceUserBindingList.from_dict(paginated_device_user_binding_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedDockerServiceConnectionList.md b/docs/PaginatedDockerServiceConnectionList.md new file mode 100644 index 000000000..69880f1d2 --- /dev/null +++ b/docs/PaginatedDockerServiceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedDockerServiceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[DockerServiceConnection]**](DockerServiceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_docker_service_connection_list import PaginatedDockerServiceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedDockerServiceConnectionList from a JSON string +paginated_docker_service_connection_list_instance = PaginatedDockerServiceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedDockerServiceConnectionList.to_json()) + +# convert the object into a dict +paginated_docker_service_connection_list_dict = paginated_docker_service_connection_list_instance.to_dict() +# create an instance of PaginatedDockerServiceConnectionList from a dict +paginated_docker_service_connection_list_from_dict = PaginatedDockerServiceConnectionList.from_dict(paginated_docker_service_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedDomainList.md b/docs/PaginatedDomainList.md new file mode 100644 index 000000000..612f14a64 --- /dev/null +++ b/docs/PaginatedDomainList.md @@ -0,0 +1,31 @@ +# PaginatedDomainList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Domain]**](Domain.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_domain_list import PaginatedDomainList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedDomainList from a JSON string +paginated_domain_list_instance = PaginatedDomainList.from_json(json) +# print the JSON string representation of the object +print(PaginatedDomainList.to_json()) + +# convert the object into a dict +paginated_domain_list_dict = paginated_domain_list_instance.to_dict() +# create an instance of PaginatedDomainList from a dict +paginated_domain_list_from_dict = PaginatedDomainList.from_dict(paginated_domain_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedDummyPolicyList.md b/docs/PaginatedDummyPolicyList.md new file mode 100644 index 000000000..f06621069 --- /dev/null +++ b/docs/PaginatedDummyPolicyList.md @@ -0,0 +1,31 @@ +# PaginatedDummyPolicyList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[DummyPolicy]**](DummyPolicy.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_dummy_policy_list import PaginatedDummyPolicyList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedDummyPolicyList from a JSON string +paginated_dummy_policy_list_instance = PaginatedDummyPolicyList.from_json(json) +# print the JSON string representation of the object +print(PaginatedDummyPolicyList.to_json()) + +# convert the object into a dict +paginated_dummy_policy_list_dict = paginated_dummy_policy_list_instance.to_dict() +# create an instance of PaginatedDummyPolicyList from a dict +paginated_dummy_policy_list_from_dict = PaginatedDummyPolicyList.from_dict(paginated_dummy_policy_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedDummyStageList.md b/docs/PaginatedDummyStageList.md new file mode 100644 index 000000000..5771fdd80 --- /dev/null +++ b/docs/PaginatedDummyStageList.md @@ -0,0 +1,31 @@ +# PaginatedDummyStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[DummyStage]**](DummyStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_dummy_stage_list import PaginatedDummyStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedDummyStageList from a JSON string +paginated_dummy_stage_list_instance = PaginatedDummyStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedDummyStageList.to_json()) + +# convert the object into a dict +paginated_dummy_stage_list_dict = paginated_dummy_stage_list_instance.to_dict() +# create an instance of PaginatedDummyStageList from a dict +paginated_dummy_stage_list_from_dict = PaginatedDummyStageList.from_dict(paginated_dummy_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedDuoDeviceList.md b/docs/PaginatedDuoDeviceList.md new file mode 100644 index 000000000..f05f0e632 --- /dev/null +++ b/docs/PaginatedDuoDeviceList.md @@ -0,0 +1,31 @@ +# PaginatedDuoDeviceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[DuoDevice]**](DuoDevice.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_duo_device_list import PaginatedDuoDeviceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedDuoDeviceList from a JSON string +paginated_duo_device_list_instance = PaginatedDuoDeviceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedDuoDeviceList.to_json()) + +# convert the object into a dict +paginated_duo_device_list_dict = paginated_duo_device_list_instance.to_dict() +# create an instance of PaginatedDuoDeviceList from a dict +paginated_duo_device_list_from_dict = PaginatedDuoDeviceList.from_dict(paginated_duo_device_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedEmailDeviceList.md b/docs/PaginatedEmailDeviceList.md new file mode 100644 index 000000000..820a19f27 --- /dev/null +++ b/docs/PaginatedEmailDeviceList.md @@ -0,0 +1,31 @@ +# PaginatedEmailDeviceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[EmailDevice]**](EmailDevice.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_email_device_list import PaginatedEmailDeviceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedEmailDeviceList from a JSON string +paginated_email_device_list_instance = PaginatedEmailDeviceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedEmailDeviceList.to_json()) + +# convert the object into a dict +paginated_email_device_list_dict = paginated_email_device_list_instance.to_dict() +# create an instance of PaginatedEmailDeviceList from a dict +paginated_email_device_list_from_dict = PaginatedEmailDeviceList.from_dict(paginated_email_device_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedEmailStageList.md b/docs/PaginatedEmailStageList.md new file mode 100644 index 000000000..b8029127b --- /dev/null +++ b/docs/PaginatedEmailStageList.md @@ -0,0 +1,31 @@ +# PaginatedEmailStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[EmailStage]**](EmailStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_email_stage_list import PaginatedEmailStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedEmailStageList from a JSON string +paginated_email_stage_list_instance = PaginatedEmailStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedEmailStageList.to_json()) + +# convert the object into a dict +paginated_email_stage_list_dict = paginated_email_stage_list_instance.to_dict() +# create an instance of PaginatedEmailStageList from a dict +paginated_email_stage_list_from_dict = PaginatedEmailStageList.from_dict(paginated_email_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedEndpointDeviceList.md b/docs/PaginatedEndpointDeviceList.md new file mode 100644 index 000000000..a0e97e795 --- /dev/null +++ b/docs/PaginatedEndpointDeviceList.md @@ -0,0 +1,31 @@ +# PaginatedEndpointDeviceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[EndpointDevice]**](EndpointDevice.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_endpoint_device_list import PaginatedEndpointDeviceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedEndpointDeviceList from a JSON string +paginated_endpoint_device_list_instance = PaginatedEndpointDeviceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedEndpointDeviceList.to_json()) + +# convert the object into a dict +paginated_endpoint_device_list_dict = paginated_endpoint_device_list_instance.to_dict() +# create an instance of PaginatedEndpointDeviceList from a dict +paginated_endpoint_device_list_from_dict = PaginatedEndpointDeviceList.from_dict(paginated_endpoint_device_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedEndpointList.md b/docs/PaginatedEndpointList.md new file mode 100644 index 000000000..42d9d4d2f --- /dev/null +++ b/docs/PaginatedEndpointList.md @@ -0,0 +1,31 @@ +# PaginatedEndpointList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Endpoint]**](Endpoint.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_endpoint_list import PaginatedEndpointList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedEndpointList from a JSON string +paginated_endpoint_list_instance = PaginatedEndpointList.from_json(json) +# print the JSON string representation of the object +print(PaginatedEndpointList.to_json()) + +# convert the object into a dict +paginated_endpoint_list_dict = paginated_endpoint_list_instance.to_dict() +# create an instance of PaginatedEndpointList from a dict +paginated_endpoint_list_from_dict = PaginatedEndpointList.from_dict(paginated_endpoint_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedEndpointStageList.md b/docs/PaginatedEndpointStageList.md new file mode 100644 index 000000000..43a13acaa --- /dev/null +++ b/docs/PaginatedEndpointStageList.md @@ -0,0 +1,31 @@ +# PaginatedEndpointStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[EndpointStage]**](EndpointStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_endpoint_stage_list import PaginatedEndpointStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedEndpointStageList from a JSON string +paginated_endpoint_stage_list_instance = PaginatedEndpointStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedEndpointStageList.to_json()) + +# convert the object into a dict +paginated_endpoint_stage_list_dict = paginated_endpoint_stage_list_instance.to_dict() +# create an instance of PaginatedEndpointStageList from a dict +paginated_endpoint_stage_list_from_dict = PaginatedEndpointStageList.from_dict(paginated_endpoint_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedEnrollmentTokenList.md b/docs/PaginatedEnrollmentTokenList.md new file mode 100644 index 000000000..5b6133f75 --- /dev/null +++ b/docs/PaginatedEnrollmentTokenList.md @@ -0,0 +1,31 @@ +# PaginatedEnrollmentTokenList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[EnrollmentToken]**](EnrollmentToken.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_enrollment_token_list import PaginatedEnrollmentTokenList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedEnrollmentTokenList from a JSON string +paginated_enrollment_token_list_instance = PaginatedEnrollmentTokenList.from_json(json) +# print the JSON string representation of the object +print(PaginatedEnrollmentTokenList.to_json()) + +# convert the object into a dict +paginated_enrollment_token_list_dict = paginated_enrollment_token_list_instance.to_dict() +# create an instance of PaginatedEnrollmentTokenList from a dict +paginated_enrollment_token_list_from_dict = PaginatedEnrollmentTokenList.from_dict(paginated_enrollment_token_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedEventList.md b/docs/PaginatedEventList.md new file mode 100644 index 000000000..23a3bfdca --- /dev/null +++ b/docs/PaginatedEventList.md @@ -0,0 +1,31 @@ +# PaginatedEventList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Event]**](Event.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_event_list import PaginatedEventList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedEventList from a JSON string +paginated_event_list_instance = PaginatedEventList.from_json(json) +# print the JSON string representation of the object +print(PaginatedEventList.to_json()) + +# convert the object into a dict +paginated_event_list_dict = paginated_event_list_instance.to_dict() +# create an instance of PaginatedEventList from a dict +paginated_event_list_from_dict = PaginatedEventList.from_dict(paginated_event_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedEventMatcherPolicyList.md b/docs/PaginatedEventMatcherPolicyList.md new file mode 100644 index 000000000..47b840bae --- /dev/null +++ b/docs/PaginatedEventMatcherPolicyList.md @@ -0,0 +1,31 @@ +# PaginatedEventMatcherPolicyList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[EventMatcherPolicy]**](EventMatcherPolicy.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_event_matcher_policy_list import PaginatedEventMatcherPolicyList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedEventMatcherPolicyList from a JSON string +paginated_event_matcher_policy_list_instance = PaginatedEventMatcherPolicyList.from_json(json) +# print the JSON string representation of the object +print(PaginatedEventMatcherPolicyList.to_json()) + +# convert the object into a dict +paginated_event_matcher_policy_list_dict = paginated_event_matcher_policy_list_instance.to_dict() +# create an instance of PaginatedEventMatcherPolicyList from a dict +paginated_event_matcher_policy_list_from_dict = PaginatedEventMatcherPolicyList.from_dict(paginated_event_matcher_policy_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedExpiringBaseGrantModelList.md b/docs/PaginatedExpiringBaseGrantModelList.md new file mode 100644 index 000000000..e58988050 --- /dev/null +++ b/docs/PaginatedExpiringBaseGrantModelList.md @@ -0,0 +1,31 @@ +# PaginatedExpiringBaseGrantModelList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ExpiringBaseGrantModel]**](ExpiringBaseGrantModel.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_expiring_base_grant_model_list import PaginatedExpiringBaseGrantModelList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedExpiringBaseGrantModelList from a JSON string +paginated_expiring_base_grant_model_list_instance = PaginatedExpiringBaseGrantModelList.from_json(json) +# print the JSON string representation of the object +print(PaginatedExpiringBaseGrantModelList.to_json()) + +# convert the object into a dict +paginated_expiring_base_grant_model_list_dict = paginated_expiring_base_grant_model_list_instance.to_dict() +# create an instance of PaginatedExpiringBaseGrantModelList from a dict +paginated_expiring_base_grant_model_list_from_dict = PaginatedExpiringBaseGrantModelList.from_dict(paginated_expiring_base_grant_model_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedExpressionPolicyList.md b/docs/PaginatedExpressionPolicyList.md new file mode 100644 index 000000000..44ea43172 --- /dev/null +++ b/docs/PaginatedExpressionPolicyList.md @@ -0,0 +1,31 @@ +# PaginatedExpressionPolicyList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ExpressionPolicy]**](ExpressionPolicy.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_expression_policy_list import PaginatedExpressionPolicyList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedExpressionPolicyList from a JSON string +paginated_expression_policy_list_instance = PaginatedExpressionPolicyList.from_json(json) +# print the JSON string representation of the object +print(PaginatedExpressionPolicyList.to_json()) + +# convert the object into a dict +paginated_expression_policy_list_dict = paginated_expression_policy_list_instance.to_dict() +# create an instance of PaginatedExpressionPolicyList from a dict +paginated_expression_policy_list_from_dict = PaginatedExpressionPolicyList.from_dict(paginated_expression_policy_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedExtraRoleObjectPermissionList.md b/docs/PaginatedExtraRoleObjectPermissionList.md new file mode 100644 index 000000000..e506b4441 --- /dev/null +++ b/docs/PaginatedExtraRoleObjectPermissionList.md @@ -0,0 +1,31 @@ +# PaginatedExtraRoleObjectPermissionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ExtraRoleObjectPermission]**](ExtraRoleObjectPermission.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_extra_role_object_permission_list import PaginatedExtraRoleObjectPermissionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedExtraRoleObjectPermissionList from a JSON string +paginated_extra_role_object_permission_list_instance = PaginatedExtraRoleObjectPermissionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedExtraRoleObjectPermissionList.to_json()) + +# convert the object into a dict +paginated_extra_role_object_permission_list_dict = paginated_extra_role_object_permission_list_instance.to_dict() +# create an instance of PaginatedExtraRoleObjectPermissionList from a dict +paginated_extra_role_object_permission_list_from_dict = PaginatedExtraRoleObjectPermissionList.from_dict(paginated_extra_role_object_permission_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedFleetConnectorList.md b/docs/PaginatedFleetConnectorList.md new file mode 100644 index 000000000..2375aa7e1 --- /dev/null +++ b/docs/PaginatedFleetConnectorList.md @@ -0,0 +1,31 @@ +# PaginatedFleetConnectorList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[FleetConnector]**](FleetConnector.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_fleet_connector_list import PaginatedFleetConnectorList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedFleetConnectorList from a JSON string +paginated_fleet_connector_list_instance = PaginatedFleetConnectorList.from_json(json) +# print the JSON string representation of the object +print(PaginatedFleetConnectorList.to_json()) + +# convert the object into a dict +paginated_fleet_connector_list_dict = paginated_fleet_connector_list_instance.to_dict() +# create an instance of PaginatedFleetConnectorList from a dict +paginated_fleet_connector_list_from_dict = PaginatedFleetConnectorList.from_dict(paginated_fleet_connector_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedFlowList.md b/docs/PaginatedFlowList.md new file mode 100644 index 000000000..bd2dd4f00 --- /dev/null +++ b/docs/PaginatedFlowList.md @@ -0,0 +1,31 @@ +# PaginatedFlowList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Flow]**](Flow.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_flow_list import PaginatedFlowList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedFlowList from a JSON string +paginated_flow_list_instance = PaginatedFlowList.from_json(json) +# print the JSON string representation of the object +print(PaginatedFlowList.to_json()) + +# convert the object into a dict +paginated_flow_list_dict = paginated_flow_list_instance.to_dict() +# create an instance of PaginatedFlowList from a dict +paginated_flow_list_from_dict = PaginatedFlowList.from_dict(paginated_flow_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedFlowStageBindingList.md b/docs/PaginatedFlowStageBindingList.md new file mode 100644 index 000000000..2c8f63be3 --- /dev/null +++ b/docs/PaginatedFlowStageBindingList.md @@ -0,0 +1,31 @@ +# PaginatedFlowStageBindingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[FlowStageBinding]**](FlowStageBinding.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_flow_stage_binding_list import PaginatedFlowStageBindingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedFlowStageBindingList from a JSON string +paginated_flow_stage_binding_list_instance = PaginatedFlowStageBindingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedFlowStageBindingList.to_json()) + +# convert the object into a dict +paginated_flow_stage_binding_list_dict = paginated_flow_stage_binding_list_instance.to_dict() +# create an instance of PaginatedFlowStageBindingList from a dict +paginated_flow_stage_binding_list_from_dict = PaginatedFlowStageBindingList.from_dict(paginated_flow_stage_binding_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGeoIPPolicyList.md b/docs/PaginatedGeoIPPolicyList.md new file mode 100644 index 000000000..1c74c4029 --- /dev/null +++ b/docs/PaginatedGeoIPPolicyList.md @@ -0,0 +1,31 @@ +# PaginatedGeoIPPolicyList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GeoIPPolicy]**](GeoIPPolicy.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_geo_ip_policy_list import PaginatedGeoIPPolicyList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGeoIPPolicyList from a JSON string +paginated_geo_ip_policy_list_instance = PaginatedGeoIPPolicyList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGeoIPPolicyList.to_json()) + +# convert the object into a dict +paginated_geo_ip_policy_list_dict = paginated_geo_ip_policy_list_instance.to_dict() +# create an instance of PaginatedGeoIPPolicyList from a dict +paginated_geo_ip_policy_list_from_dict = PaginatedGeoIPPolicyList.from_dict(paginated_geo_ip_policy_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGoogleChromeConnectorList.md b/docs/PaginatedGoogleChromeConnectorList.md new file mode 100644 index 000000000..2d11ad5c1 --- /dev/null +++ b/docs/PaginatedGoogleChromeConnectorList.md @@ -0,0 +1,31 @@ +# PaginatedGoogleChromeConnectorList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GoogleChromeConnector]**](GoogleChromeConnector.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_google_chrome_connector_list import PaginatedGoogleChromeConnectorList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGoogleChromeConnectorList from a JSON string +paginated_google_chrome_connector_list_instance = PaginatedGoogleChromeConnectorList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGoogleChromeConnectorList.to_json()) + +# convert the object into a dict +paginated_google_chrome_connector_list_dict = paginated_google_chrome_connector_list_instance.to_dict() +# create an instance of PaginatedGoogleChromeConnectorList from a dict +paginated_google_chrome_connector_list_from_dict = PaginatedGoogleChromeConnectorList.from_dict(paginated_google_chrome_connector_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGoogleEndpointDeviceList.md b/docs/PaginatedGoogleEndpointDeviceList.md new file mode 100644 index 000000000..aaf83d6cd --- /dev/null +++ b/docs/PaginatedGoogleEndpointDeviceList.md @@ -0,0 +1,31 @@ +# PaginatedGoogleEndpointDeviceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GoogleEndpointDevice]**](GoogleEndpointDevice.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_google_endpoint_device_list import PaginatedGoogleEndpointDeviceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGoogleEndpointDeviceList from a JSON string +paginated_google_endpoint_device_list_instance = PaginatedGoogleEndpointDeviceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGoogleEndpointDeviceList.to_json()) + +# convert the object into a dict +paginated_google_endpoint_device_list_dict = paginated_google_endpoint_device_list_instance.to_dict() +# create an instance of PaginatedGoogleEndpointDeviceList from a dict +paginated_google_endpoint_device_list_from_dict = PaginatedGoogleEndpointDeviceList.from_dict(paginated_google_endpoint_device_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGoogleWorkspaceProviderGroupList.md b/docs/PaginatedGoogleWorkspaceProviderGroupList.md new file mode 100644 index 000000000..3395603af --- /dev/null +++ b/docs/PaginatedGoogleWorkspaceProviderGroupList.md @@ -0,0 +1,31 @@ +# PaginatedGoogleWorkspaceProviderGroupList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GoogleWorkspaceProviderGroup]**](GoogleWorkspaceProviderGroup.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_google_workspace_provider_group_list import PaginatedGoogleWorkspaceProviderGroupList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGoogleWorkspaceProviderGroupList from a JSON string +paginated_google_workspace_provider_group_list_instance = PaginatedGoogleWorkspaceProviderGroupList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGoogleWorkspaceProviderGroupList.to_json()) + +# convert the object into a dict +paginated_google_workspace_provider_group_list_dict = paginated_google_workspace_provider_group_list_instance.to_dict() +# create an instance of PaginatedGoogleWorkspaceProviderGroupList from a dict +paginated_google_workspace_provider_group_list_from_dict = PaginatedGoogleWorkspaceProviderGroupList.from_dict(paginated_google_workspace_provider_group_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGoogleWorkspaceProviderList.md b/docs/PaginatedGoogleWorkspaceProviderList.md new file mode 100644 index 000000000..283e7a8a5 --- /dev/null +++ b/docs/PaginatedGoogleWorkspaceProviderList.md @@ -0,0 +1,31 @@ +# PaginatedGoogleWorkspaceProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GoogleWorkspaceProvider]**](GoogleWorkspaceProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_google_workspace_provider_list import PaginatedGoogleWorkspaceProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGoogleWorkspaceProviderList from a JSON string +paginated_google_workspace_provider_list_instance = PaginatedGoogleWorkspaceProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGoogleWorkspaceProviderList.to_json()) + +# convert the object into a dict +paginated_google_workspace_provider_list_dict = paginated_google_workspace_provider_list_instance.to_dict() +# create an instance of PaginatedGoogleWorkspaceProviderList from a dict +paginated_google_workspace_provider_list_from_dict = PaginatedGoogleWorkspaceProviderList.from_dict(paginated_google_workspace_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGoogleWorkspaceProviderMappingList.md b/docs/PaginatedGoogleWorkspaceProviderMappingList.md new file mode 100644 index 000000000..39a9ac51a --- /dev/null +++ b/docs/PaginatedGoogleWorkspaceProviderMappingList.md @@ -0,0 +1,31 @@ +# PaginatedGoogleWorkspaceProviderMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GoogleWorkspaceProviderMapping]**](GoogleWorkspaceProviderMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_google_workspace_provider_mapping_list import PaginatedGoogleWorkspaceProviderMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGoogleWorkspaceProviderMappingList from a JSON string +paginated_google_workspace_provider_mapping_list_instance = PaginatedGoogleWorkspaceProviderMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGoogleWorkspaceProviderMappingList.to_json()) + +# convert the object into a dict +paginated_google_workspace_provider_mapping_list_dict = paginated_google_workspace_provider_mapping_list_instance.to_dict() +# create an instance of PaginatedGoogleWorkspaceProviderMappingList from a dict +paginated_google_workspace_provider_mapping_list_from_dict = PaginatedGoogleWorkspaceProviderMappingList.from_dict(paginated_google_workspace_provider_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGoogleWorkspaceProviderUserList.md b/docs/PaginatedGoogleWorkspaceProviderUserList.md new file mode 100644 index 000000000..c332fbe47 --- /dev/null +++ b/docs/PaginatedGoogleWorkspaceProviderUserList.md @@ -0,0 +1,31 @@ +# PaginatedGoogleWorkspaceProviderUserList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GoogleWorkspaceProviderUser]**](GoogleWorkspaceProviderUser.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_google_workspace_provider_user_list import PaginatedGoogleWorkspaceProviderUserList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGoogleWorkspaceProviderUserList from a JSON string +paginated_google_workspace_provider_user_list_instance = PaginatedGoogleWorkspaceProviderUserList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGoogleWorkspaceProviderUserList.to_json()) + +# convert the object into a dict +paginated_google_workspace_provider_user_list_dict = paginated_google_workspace_provider_user_list_instance.to_dict() +# create an instance of PaginatedGoogleWorkspaceProviderUserList from a dict +paginated_google_workspace_provider_user_list_from_dict = PaginatedGoogleWorkspaceProviderUserList.from_dict(paginated_google_workspace_provider_user_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGroupKerberosSourceConnectionList.md b/docs/PaginatedGroupKerberosSourceConnectionList.md new file mode 100644 index 000000000..85a334c2b --- /dev/null +++ b/docs/PaginatedGroupKerberosSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedGroupKerberosSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GroupKerberosSourceConnection]**](GroupKerberosSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_group_kerberos_source_connection_list import PaginatedGroupKerberosSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGroupKerberosSourceConnectionList from a JSON string +paginated_group_kerberos_source_connection_list_instance = PaginatedGroupKerberosSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGroupKerberosSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_group_kerberos_source_connection_list_dict = paginated_group_kerberos_source_connection_list_instance.to_dict() +# create an instance of PaginatedGroupKerberosSourceConnectionList from a dict +paginated_group_kerberos_source_connection_list_from_dict = PaginatedGroupKerberosSourceConnectionList.from_dict(paginated_group_kerberos_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGroupLDAPSourceConnectionList.md b/docs/PaginatedGroupLDAPSourceConnectionList.md new file mode 100644 index 000000000..bc60b2dc1 --- /dev/null +++ b/docs/PaginatedGroupLDAPSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedGroupLDAPSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GroupLDAPSourceConnection]**](GroupLDAPSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_group_ldap_source_connection_list import PaginatedGroupLDAPSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGroupLDAPSourceConnectionList from a JSON string +paginated_group_ldap_source_connection_list_instance = PaginatedGroupLDAPSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGroupLDAPSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_group_ldap_source_connection_list_dict = paginated_group_ldap_source_connection_list_instance.to_dict() +# create an instance of PaginatedGroupLDAPSourceConnectionList from a dict +paginated_group_ldap_source_connection_list_from_dict = PaginatedGroupLDAPSourceConnectionList.from_dict(paginated_group_ldap_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGroupList.md b/docs/PaginatedGroupList.md new file mode 100644 index 000000000..61019341e --- /dev/null +++ b/docs/PaginatedGroupList.md @@ -0,0 +1,31 @@ +# PaginatedGroupList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Group]**](Group.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_group_list import PaginatedGroupList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGroupList from a JSON string +paginated_group_list_instance = PaginatedGroupList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGroupList.to_json()) + +# convert the object into a dict +paginated_group_list_dict = paginated_group_list_instance.to_dict() +# create an instance of PaginatedGroupList from a dict +paginated_group_list_from_dict = PaginatedGroupList.from_dict(paginated_group_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGroupOAuthSourceConnectionList.md b/docs/PaginatedGroupOAuthSourceConnectionList.md new file mode 100644 index 000000000..46f0b86aa --- /dev/null +++ b/docs/PaginatedGroupOAuthSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedGroupOAuthSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GroupOAuthSourceConnection]**](GroupOAuthSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_group_o_auth_source_connection_list import PaginatedGroupOAuthSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGroupOAuthSourceConnectionList from a JSON string +paginated_group_o_auth_source_connection_list_instance = PaginatedGroupOAuthSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGroupOAuthSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_group_o_auth_source_connection_list_dict = paginated_group_o_auth_source_connection_list_instance.to_dict() +# create an instance of PaginatedGroupOAuthSourceConnectionList from a dict +paginated_group_o_auth_source_connection_list_from_dict = PaginatedGroupOAuthSourceConnectionList.from_dict(paginated_group_o_auth_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGroupPlexSourceConnectionList.md b/docs/PaginatedGroupPlexSourceConnectionList.md new file mode 100644 index 000000000..0441591ab --- /dev/null +++ b/docs/PaginatedGroupPlexSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedGroupPlexSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GroupPlexSourceConnection]**](GroupPlexSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_group_plex_source_connection_list import PaginatedGroupPlexSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGroupPlexSourceConnectionList from a JSON string +paginated_group_plex_source_connection_list_instance = PaginatedGroupPlexSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGroupPlexSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_group_plex_source_connection_list_dict = paginated_group_plex_source_connection_list_instance.to_dict() +# create an instance of PaginatedGroupPlexSourceConnectionList from a dict +paginated_group_plex_source_connection_list_from_dict = PaginatedGroupPlexSourceConnectionList.from_dict(paginated_group_plex_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGroupSAMLSourceConnectionList.md b/docs/PaginatedGroupSAMLSourceConnectionList.md new file mode 100644 index 000000000..8b5473ad6 --- /dev/null +++ b/docs/PaginatedGroupSAMLSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedGroupSAMLSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GroupSAMLSourceConnection]**](GroupSAMLSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_group_saml_source_connection_list import PaginatedGroupSAMLSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGroupSAMLSourceConnectionList from a JSON string +paginated_group_saml_source_connection_list_instance = PaginatedGroupSAMLSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGroupSAMLSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_group_saml_source_connection_list_dict = paginated_group_saml_source_connection_list_instance.to_dict() +# create an instance of PaginatedGroupSAMLSourceConnectionList from a dict +paginated_group_saml_source_connection_list_from_dict = PaginatedGroupSAMLSourceConnectionList.from_dict(paginated_group_saml_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGroupSourceConnectionList.md b/docs/PaginatedGroupSourceConnectionList.md new file mode 100644 index 000000000..5b151d9a1 --- /dev/null +++ b/docs/PaginatedGroupSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedGroupSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GroupSourceConnection]**](GroupSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_group_source_connection_list import PaginatedGroupSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGroupSourceConnectionList from a JSON string +paginated_group_source_connection_list_instance = PaginatedGroupSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGroupSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_group_source_connection_list_dict = paginated_group_source_connection_list_instance.to_dict() +# create an instance of PaginatedGroupSourceConnectionList from a dict +paginated_group_source_connection_list_from_dict = PaginatedGroupSourceConnectionList.from_dict(paginated_group_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedGroupTelegramSourceConnectionList.md b/docs/PaginatedGroupTelegramSourceConnectionList.md new file mode 100644 index 000000000..f017b57cd --- /dev/null +++ b/docs/PaginatedGroupTelegramSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedGroupTelegramSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[GroupTelegramSourceConnection]**](GroupTelegramSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_group_telegram_source_connection_list import PaginatedGroupTelegramSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedGroupTelegramSourceConnectionList from a JSON string +paginated_group_telegram_source_connection_list_instance = PaginatedGroupTelegramSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedGroupTelegramSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_group_telegram_source_connection_list_dict = paginated_group_telegram_source_connection_list_instance.to_dict() +# create an instance of PaginatedGroupTelegramSourceConnectionList from a dict +paginated_group_telegram_source_connection_list_from_dict = PaginatedGroupTelegramSourceConnectionList.from_dict(paginated_group_telegram_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedIdentificationStageList.md b/docs/PaginatedIdentificationStageList.md new file mode 100644 index 000000000..26886dd7b --- /dev/null +++ b/docs/PaginatedIdentificationStageList.md @@ -0,0 +1,31 @@ +# PaginatedIdentificationStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[IdentificationStage]**](IdentificationStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_identification_stage_list import PaginatedIdentificationStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedIdentificationStageList from a JSON string +paginated_identification_stage_list_instance = PaginatedIdentificationStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedIdentificationStageList.to_json()) + +# convert the object into a dict +paginated_identification_stage_list_dict = paginated_identification_stage_list_instance.to_dict() +# create an instance of PaginatedIdentificationStageList from a dict +paginated_identification_stage_list_from_dict = PaginatedIdentificationStageList.from_dict(paginated_identification_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedInitialPermissionsList.md b/docs/PaginatedInitialPermissionsList.md new file mode 100644 index 000000000..bf525ff43 --- /dev/null +++ b/docs/PaginatedInitialPermissionsList.md @@ -0,0 +1,31 @@ +# PaginatedInitialPermissionsList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[InitialPermissions]**](InitialPermissions.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_initial_permissions_list import PaginatedInitialPermissionsList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedInitialPermissionsList from a JSON string +paginated_initial_permissions_list_instance = PaginatedInitialPermissionsList.from_json(json) +# print the JSON string representation of the object +print(PaginatedInitialPermissionsList.to_json()) + +# convert the object into a dict +paginated_initial_permissions_list_dict = paginated_initial_permissions_list_instance.to_dict() +# create an instance of PaginatedInitialPermissionsList from a dict +paginated_initial_permissions_list_from_dict = PaginatedInitialPermissionsList.from_dict(paginated_initial_permissions_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedInvitationList.md b/docs/PaginatedInvitationList.md new file mode 100644 index 000000000..443f45185 --- /dev/null +++ b/docs/PaginatedInvitationList.md @@ -0,0 +1,31 @@ +# PaginatedInvitationList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Invitation]**](Invitation.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_invitation_list import PaginatedInvitationList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedInvitationList from a JSON string +paginated_invitation_list_instance = PaginatedInvitationList.from_json(json) +# print the JSON string representation of the object +print(PaginatedInvitationList.to_json()) + +# convert the object into a dict +paginated_invitation_list_dict = paginated_invitation_list_instance.to_dict() +# create an instance of PaginatedInvitationList from a dict +paginated_invitation_list_from_dict = PaginatedInvitationList.from_dict(paginated_invitation_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedInvitationStageList.md b/docs/PaginatedInvitationStageList.md new file mode 100644 index 000000000..b20812ce9 --- /dev/null +++ b/docs/PaginatedInvitationStageList.md @@ -0,0 +1,31 @@ +# PaginatedInvitationStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[InvitationStage]**](InvitationStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_invitation_stage_list import PaginatedInvitationStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedInvitationStageList from a JSON string +paginated_invitation_stage_list_instance = PaginatedInvitationStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedInvitationStageList.to_json()) + +# convert the object into a dict +paginated_invitation_stage_list_dict = paginated_invitation_stage_list_instance.to_dict() +# create an instance of PaginatedInvitationStageList from a dict +paginated_invitation_stage_list_from_dict = PaginatedInvitationStageList.from_dict(paginated_invitation_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedKerberosSourceList.md b/docs/PaginatedKerberosSourceList.md new file mode 100644 index 000000000..e1da69b3f --- /dev/null +++ b/docs/PaginatedKerberosSourceList.md @@ -0,0 +1,31 @@ +# PaginatedKerberosSourceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[KerberosSource]**](KerberosSource.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_kerberos_source_list import PaginatedKerberosSourceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedKerberosSourceList from a JSON string +paginated_kerberos_source_list_instance = PaginatedKerberosSourceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedKerberosSourceList.to_json()) + +# convert the object into a dict +paginated_kerberos_source_list_dict = paginated_kerberos_source_list_instance.to_dict() +# create an instance of PaginatedKerberosSourceList from a dict +paginated_kerberos_source_list_from_dict = PaginatedKerberosSourceList.from_dict(paginated_kerberos_source_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedKerberosSourcePropertyMappingList.md b/docs/PaginatedKerberosSourcePropertyMappingList.md new file mode 100644 index 000000000..3c329103f --- /dev/null +++ b/docs/PaginatedKerberosSourcePropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedKerberosSourcePropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[KerberosSourcePropertyMapping]**](KerberosSourcePropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_kerberos_source_property_mapping_list import PaginatedKerberosSourcePropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedKerberosSourcePropertyMappingList from a JSON string +paginated_kerberos_source_property_mapping_list_instance = PaginatedKerberosSourcePropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedKerberosSourcePropertyMappingList.to_json()) + +# convert the object into a dict +paginated_kerberos_source_property_mapping_list_dict = paginated_kerberos_source_property_mapping_list_instance.to_dict() +# create an instance of PaginatedKerberosSourcePropertyMappingList from a dict +paginated_kerberos_source_property_mapping_list_from_dict = PaginatedKerberosSourcePropertyMappingList.from_dict(paginated_kerberos_source_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedKubernetesServiceConnectionList.md b/docs/PaginatedKubernetesServiceConnectionList.md new file mode 100644 index 000000000..8ad9813f3 --- /dev/null +++ b/docs/PaginatedKubernetesServiceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedKubernetesServiceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[KubernetesServiceConnection]**](KubernetesServiceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_kubernetes_service_connection_list import PaginatedKubernetesServiceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedKubernetesServiceConnectionList from a JSON string +paginated_kubernetes_service_connection_list_instance = PaginatedKubernetesServiceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedKubernetesServiceConnectionList.to_json()) + +# convert the object into a dict +paginated_kubernetes_service_connection_list_dict = paginated_kubernetes_service_connection_list_instance.to_dict() +# create an instance of PaginatedKubernetesServiceConnectionList from a dict +paginated_kubernetes_service_connection_list_from_dict = PaginatedKubernetesServiceConnectionList.from_dict(paginated_kubernetes_service_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedLDAPOutpostConfigList.md b/docs/PaginatedLDAPOutpostConfigList.md new file mode 100644 index 000000000..fe2d6f2bf --- /dev/null +++ b/docs/PaginatedLDAPOutpostConfigList.md @@ -0,0 +1,31 @@ +# PaginatedLDAPOutpostConfigList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[LDAPOutpostConfig]**](LDAPOutpostConfig.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_ldap_outpost_config_list import PaginatedLDAPOutpostConfigList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedLDAPOutpostConfigList from a JSON string +paginated_ldap_outpost_config_list_instance = PaginatedLDAPOutpostConfigList.from_json(json) +# print the JSON string representation of the object +print(PaginatedLDAPOutpostConfigList.to_json()) + +# convert the object into a dict +paginated_ldap_outpost_config_list_dict = paginated_ldap_outpost_config_list_instance.to_dict() +# create an instance of PaginatedLDAPOutpostConfigList from a dict +paginated_ldap_outpost_config_list_from_dict = PaginatedLDAPOutpostConfigList.from_dict(paginated_ldap_outpost_config_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedLDAPProviderList.md b/docs/PaginatedLDAPProviderList.md new file mode 100644 index 000000000..81b5c778d --- /dev/null +++ b/docs/PaginatedLDAPProviderList.md @@ -0,0 +1,31 @@ +# PaginatedLDAPProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[LDAPProvider]**](LDAPProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_ldap_provider_list import PaginatedLDAPProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedLDAPProviderList from a JSON string +paginated_ldap_provider_list_instance = PaginatedLDAPProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedLDAPProviderList.to_json()) + +# convert the object into a dict +paginated_ldap_provider_list_dict = paginated_ldap_provider_list_instance.to_dict() +# create an instance of PaginatedLDAPProviderList from a dict +paginated_ldap_provider_list_from_dict = PaginatedLDAPProviderList.from_dict(paginated_ldap_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedLDAPSourceList.md b/docs/PaginatedLDAPSourceList.md new file mode 100644 index 000000000..de3acf234 --- /dev/null +++ b/docs/PaginatedLDAPSourceList.md @@ -0,0 +1,31 @@ +# PaginatedLDAPSourceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[LDAPSource]**](LDAPSource.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_ldap_source_list import PaginatedLDAPSourceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedLDAPSourceList from a JSON string +paginated_ldap_source_list_instance = PaginatedLDAPSourceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedLDAPSourceList.to_json()) + +# convert the object into a dict +paginated_ldap_source_list_dict = paginated_ldap_source_list_instance.to_dict() +# create an instance of PaginatedLDAPSourceList from a dict +paginated_ldap_source_list_from_dict = PaginatedLDAPSourceList.from_dict(paginated_ldap_source_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedLDAPSourcePropertyMappingList.md b/docs/PaginatedLDAPSourcePropertyMappingList.md new file mode 100644 index 000000000..10012825a --- /dev/null +++ b/docs/PaginatedLDAPSourcePropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedLDAPSourcePropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[LDAPSourcePropertyMapping]**](LDAPSourcePropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_ldap_source_property_mapping_list import PaginatedLDAPSourcePropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedLDAPSourcePropertyMappingList from a JSON string +paginated_ldap_source_property_mapping_list_instance = PaginatedLDAPSourcePropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedLDAPSourcePropertyMappingList.to_json()) + +# convert the object into a dict +paginated_ldap_source_property_mapping_list_dict = paginated_ldap_source_property_mapping_list_instance.to_dict() +# create an instance of PaginatedLDAPSourcePropertyMappingList from a dict +paginated_ldap_source_property_mapping_list_from_dict = PaginatedLDAPSourcePropertyMappingList.from_dict(paginated_ldap_source_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedLicenseList.md b/docs/PaginatedLicenseList.md new file mode 100644 index 000000000..8ce1b52b2 --- /dev/null +++ b/docs/PaginatedLicenseList.md @@ -0,0 +1,31 @@ +# PaginatedLicenseList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[License]**](License.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_license_list import PaginatedLicenseList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedLicenseList from a JSON string +paginated_license_list_instance = PaginatedLicenseList.from_json(json) +# print the JSON string representation of the object +print(PaginatedLicenseList.to_json()) + +# convert the object into a dict +paginated_license_list_dict = paginated_license_list_instance.to_dict() +# create an instance of PaginatedLicenseList from a dict +paginated_license_list_from_dict = PaginatedLicenseList.from_dict(paginated_license_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedLifecycleIterationList.md b/docs/PaginatedLifecycleIterationList.md new file mode 100644 index 000000000..2b83dff14 --- /dev/null +++ b/docs/PaginatedLifecycleIterationList.md @@ -0,0 +1,31 @@ +# PaginatedLifecycleIterationList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[LifecycleIteration]**](LifecycleIteration.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_lifecycle_iteration_list import PaginatedLifecycleIterationList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedLifecycleIterationList from a JSON string +paginated_lifecycle_iteration_list_instance = PaginatedLifecycleIterationList.from_json(json) +# print the JSON string representation of the object +print(PaginatedLifecycleIterationList.to_json()) + +# convert the object into a dict +paginated_lifecycle_iteration_list_dict = paginated_lifecycle_iteration_list_instance.to_dict() +# create an instance of PaginatedLifecycleIterationList from a dict +paginated_lifecycle_iteration_list_from_dict = PaginatedLifecycleIterationList.from_dict(paginated_lifecycle_iteration_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedLifecycleRuleList.md b/docs/PaginatedLifecycleRuleList.md new file mode 100644 index 000000000..b48dd2b95 --- /dev/null +++ b/docs/PaginatedLifecycleRuleList.md @@ -0,0 +1,31 @@ +# PaginatedLifecycleRuleList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[LifecycleRule]**](LifecycleRule.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_lifecycle_rule_list import PaginatedLifecycleRuleList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedLifecycleRuleList from a JSON string +paginated_lifecycle_rule_list_instance = PaginatedLifecycleRuleList.from_json(json) +# print the JSON string representation of the object +print(PaginatedLifecycleRuleList.to_json()) + +# convert the object into a dict +paginated_lifecycle_rule_list_dict = paginated_lifecycle_rule_list_instance.to_dict() +# create an instance of PaginatedLifecycleRuleList from a dict +paginated_lifecycle_rule_list_from_dict = PaginatedLifecycleRuleList.from_dict(paginated_lifecycle_rule_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedMicrosoftEntraProviderGroupList.md b/docs/PaginatedMicrosoftEntraProviderGroupList.md new file mode 100644 index 000000000..3db480bb2 --- /dev/null +++ b/docs/PaginatedMicrosoftEntraProviderGroupList.md @@ -0,0 +1,31 @@ +# PaginatedMicrosoftEntraProviderGroupList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[MicrosoftEntraProviderGroup]**](MicrosoftEntraProviderGroup.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_microsoft_entra_provider_group_list import PaginatedMicrosoftEntraProviderGroupList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedMicrosoftEntraProviderGroupList from a JSON string +paginated_microsoft_entra_provider_group_list_instance = PaginatedMicrosoftEntraProviderGroupList.from_json(json) +# print the JSON string representation of the object +print(PaginatedMicrosoftEntraProviderGroupList.to_json()) + +# convert the object into a dict +paginated_microsoft_entra_provider_group_list_dict = paginated_microsoft_entra_provider_group_list_instance.to_dict() +# create an instance of PaginatedMicrosoftEntraProviderGroupList from a dict +paginated_microsoft_entra_provider_group_list_from_dict = PaginatedMicrosoftEntraProviderGroupList.from_dict(paginated_microsoft_entra_provider_group_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedMicrosoftEntraProviderList.md b/docs/PaginatedMicrosoftEntraProviderList.md new file mode 100644 index 000000000..114579edf --- /dev/null +++ b/docs/PaginatedMicrosoftEntraProviderList.md @@ -0,0 +1,31 @@ +# PaginatedMicrosoftEntraProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[MicrosoftEntraProvider]**](MicrosoftEntraProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_microsoft_entra_provider_list import PaginatedMicrosoftEntraProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedMicrosoftEntraProviderList from a JSON string +paginated_microsoft_entra_provider_list_instance = PaginatedMicrosoftEntraProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedMicrosoftEntraProviderList.to_json()) + +# convert the object into a dict +paginated_microsoft_entra_provider_list_dict = paginated_microsoft_entra_provider_list_instance.to_dict() +# create an instance of PaginatedMicrosoftEntraProviderList from a dict +paginated_microsoft_entra_provider_list_from_dict = PaginatedMicrosoftEntraProviderList.from_dict(paginated_microsoft_entra_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedMicrosoftEntraProviderMappingList.md b/docs/PaginatedMicrosoftEntraProviderMappingList.md new file mode 100644 index 000000000..267eb085e --- /dev/null +++ b/docs/PaginatedMicrosoftEntraProviderMappingList.md @@ -0,0 +1,31 @@ +# PaginatedMicrosoftEntraProviderMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[MicrosoftEntraProviderMapping]**](MicrosoftEntraProviderMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_microsoft_entra_provider_mapping_list import PaginatedMicrosoftEntraProviderMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedMicrosoftEntraProviderMappingList from a JSON string +paginated_microsoft_entra_provider_mapping_list_instance = PaginatedMicrosoftEntraProviderMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedMicrosoftEntraProviderMappingList.to_json()) + +# convert the object into a dict +paginated_microsoft_entra_provider_mapping_list_dict = paginated_microsoft_entra_provider_mapping_list_instance.to_dict() +# create an instance of PaginatedMicrosoftEntraProviderMappingList from a dict +paginated_microsoft_entra_provider_mapping_list_from_dict = PaginatedMicrosoftEntraProviderMappingList.from_dict(paginated_microsoft_entra_provider_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedMicrosoftEntraProviderUserList.md b/docs/PaginatedMicrosoftEntraProviderUserList.md new file mode 100644 index 000000000..493108e15 --- /dev/null +++ b/docs/PaginatedMicrosoftEntraProviderUserList.md @@ -0,0 +1,31 @@ +# PaginatedMicrosoftEntraProviderUserList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[MicrosoftEntraProviderUser]**](MicrosoftEntraProviderUser.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_microsoft_entra_provider_user_list import PaginatedMicrosoftEntraProviderUserList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedMicrosoftEntraProviderUserList from a JSON string +paginated_microsoft_entra_provider_user_list_instance = PaginatedMicrosoftEntraProviderUserList.from_json(json) +# print the JSON string representation of the object +print(PaginatedMicrosoftEntraProviderUserList.to_json()) + +# convert the object into a dict +paginated_microsoft_entra_provider_user_list_dict = paginated_microsoft_entra_provider_user_list_instance.to_dict() +# create an instance of PaginatedMicrosoftEntraProviderUserList from a dict +paginated_microsoft_entra_provider_user_list_from_dict = PaginatedMicrosoftEntraProviderUserList.from_dict(paginated_microsoft_entra_provider_user_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedMutualTLSStageList.md b/docs/PaginatedMutualTLSStageList.md new file mode 100644 index 000000000..9b845e8f0 --- /dev/null +++ b/docs/PaginatedMutualTLSStageList.md @@ -0,0 +1,31 @@ +# PaginatedMutualTLSStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[MutualTLSStage]**](MutualTLSStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_mutual_tls_stage_list import PaginatedMutualTLSStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedMutualTLSStageList from a JSON string +paginated_mutual_tls_stage_list_instance = PaginatedMutualTLSStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedMutualTLSStageList.to_json()) + +# convert the object into a dict +paginated_mutual_tls_stage_list_dict = paginated_mutual_tls_stage_list_instance.to_dict() +# create an instance of PaginatedMutualTLSStageList from a dict +paginated_mutual_tls_stage_list_from_dict = PaginatedMutualTLSStageList.from_dict(paginated_mutual_tls_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedNotificationList.md b/docs/PaginatedNotificationList.md new file mode 100644 index 000000000..31d4e21c3 --- /dev/null +++ b/docs/PaginatedNotificationList.md @@ -0,0 +1,31 @@ +# PaginatedNotificationList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Notification]**](Notification.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_notification_list import PaginatedNotificationList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedNotificationList from a JSON string +paginated_notification_list_instance = PaginatedNotificationList.from_json(json) +# print the JSON string representation of the object +print(PaginatedNotificationList.to_json()) + +# convert the object into a dict +paginated_notification_list_dict = paginated_notification_list_instance.to_dict() +# create an instance of PaginatedNotificationList from a dict +paginated_notification_list_from_dict = PaginatedNotificationList.from_dict(paginated_notification_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedNotificationRuleList.md b/docs/PaginatedNotificationRuleList.md new file mode 100644 index 000000000..5e56dfaad --- /dev/null +++ b/docs/PaginatedNotificationRuleList.md @@ -0,0 +1,31 @@ +# PaginatedNotificationRuleList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[NotificationRule]**](NotificationRule.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_notification_rule_list import PaginatedNotificationRuleList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedNotificationRuleList from a JSON string +paginated_notification_rule_list_instance = PaginatedNotificationRuleList.from_json(json) +# print the JSON string representation of the object +print(PaginatedNotificationRuleList.to_json()) + +# convert the object into a dict +paginated_notification_rule_list_dict = paginated_notification_rule_list_instance.to_dict() +# create an instance of PaginatedNotificationRuleList from a dict +paginated_notification_rule_list_from_dict = PaginatedNotificationRuleList.from_dict(paginated_notification_rule_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedNotificationTransportList.md b/docs/PaginatedNotificationTransportList.md new file mode 100644 index 000000000..d402d7b8f --- /dev/null +++ b/docs/PaginatedNotificationTransportList.md @@ -0,0 +1,31 @@ +# PaginatedNotificationTransportList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[NotificationTransport]**](NotificationTransport.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_notification_transport_list import PaginatedNotificationTransportList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedNotificationTransportList from a JSON string +paginated_notification_transport_list_instance = PaginatedNotificationTransportList.from_json(json) +# print the JSON string representation of the object +print(PaginatedNotificationTransportList.to_json()) + +# convert the object into a dict +paginated_notification_transport_list_dict = paginated_notification_transport_list_instance.to_dict() +# create an instance of PaginatedNotificationTransportList from a dict +paginated_notification_transport_list_from_dict = PaginatedNotificationTransportList.from_dict(paginated_notification_transport_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedNotificationWebhookMappingList.md b/docs/PaginatedNotificationWebhookMappingList.md new file mode 100644 index 000000000..cedcf096a --- /dev/null +++ b/docs/PaginatedNotificationWebhookMappingList.md @@ -0,0 +1,31 @@ +# PaginatedNotificationWebhookMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[NotificationWebhookMapping]**](NotificationWebhookMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_notification_webhook_mapping_list import PaginatedNotificationWebhookMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedNotificationWebhookMappingList from a JSON string +paginated_notification_webhook_mapping_list_instance = PaginatedNotificationWebhookMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedNotificationWebhookMappingList.to_json()) + +# convert the object into a dict +paginated_notification_webhook_mapping_list_dict = paginated_notification_webhook_mapping_list_instance.to_dict() +# create an instance of PaginatedNotificationWebhookMappingList from a dict +paginated_notification_webhook_mapping_list_from_dict = PaginatedNotificationWebhookMappingList.from_dict(paginated_notification_webhook_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedOAuth2ProviderList.md b/docs/PaginatedOAuth2ProviderList.md new file mode 100644 index 000000000..93a539e74 --- /dev/null +++ b/docs/PaginatedOAuth2ProviderList.md @@ -0,0 +1,31 @@ +# PaginatedOAuth2ProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[OAuth2Provider]**](OAuth2Provider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_o_auth2_provider_list import PaginatedOAuth2ProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedOAuth2ProviderList from a JSON string +paginated_o_auth2_provider_list_instance = PaginatedOAuth2ProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedOAuth2ProviderList.to_json()) + +# convert the object into a dict +paginated_o_auth2_provider_list_dict = paginated_o_auth2_provider_list_instance.to_dict() +# create an instance of PaginatedOAuth2ProviderList from a dict +paginated_o_auth2_provider_list_from_dict = PaginatedOAuth2ProviderList.from_dict(paginated_o_auth2_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedOAuthSourceList.md b/docs/PaginatedOAuthSourceList.md new file mode 100644 index 000000000..47aab4067 --- /dev/null +++ b/docs/PaginatedOAuthSourceList.md @@ -0,0 +1,31 @@ +# PaginatedOAuthSourceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[OAuthSource]**](OAuthSource.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_o_auth_source_list import PaginatedOAuthSourceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedOAuthSourceList from a JSON string +paginated_o_auth_source_list_instance = PaginatedOAuthSourceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedOAuthSourceList.to_json()) + +# convert the object into a dict +paginated_o_auth_source_list_dict = paginated_o_auth_source_list_instance.to_dict() +# create an instance of PaginatedOAuthSourceList from a dict +paginated_o_auth_source_list_from_dict = PaginatedOAuthSourceList.from_dict(paginated_o_auth_source_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedOAuthSourcePropertyMappingList.md b/docs/PaginatedOAuthSourcePropertyMappingList.md new file mode 100644 index 000000000..6aa2a0601 --- /dev/null +++ b/docs/PaginatedOAuthSourcePropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedOAuthSourcePropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[OAuthSourcePropertyMapping]**](OAuthSourcePropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_o_auth_source_property_mapping_list import PaginatedOAuthSourcePropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedOAuthSourcePropertyMappingList from a JSON string +paginated_o_auth_source_property_mapping_list_instance = PaginatedOAuthSourcePropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedOAuthSourcePropertyMappingList.to_json()) + +# convert the object into a dict +paginated_o_auth_source_property_mapping_list_dict = paginated_o_auth_source_property_mapping_list_instance.to_dict() +# create an instance of PaginatedOAuthSourcePropertyMappingList from a dict +paginated_o_auth_source_property_mapping_list_from_dict = PaginatedOAuthSourcePropertyMappingList.from_dict(paginated_o_auth_source_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedOutpostList.md b/docs/PaginatedOutpostList.md new file mode 100644 index 000000000..5f3ad9750 --- /dev/null +++ b/docs/PaginatedOutpostList.md @@ -0,0 +1,31 @@ +# PaginatedOutpostList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Outpost]**](Outpost.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_outpost_list import PaginatedOutpostList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedOutpostList from a JSON string +paginated_outpost_list_instance = PaginatedOutpostList.from_json(json) +# print the JSON string representation of the object +print(PaginatedOutpostList.to_json()) + +# convert the object into a dict +paginated_outpost_list_dict = paginated_outpost_list_instance.to_dict() +# create an instance of PaginatedOutpostList from a dict +paginated_outpost_list_from_dict = PaginatedOutpostList.from_dict(paginated_outpost_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPasswordExpiryPolicyList.md b/docs/PaginatedPasswordExpiryPolicyList.md new file mode 100644 index 000000000..379e0aaa9 --- /dev/null +++ b/docs/PaginatedPasswordExpiryPolicyList.md @@ -0,0 +1,31 @@ +# PaginatedPasswordExpiryPolicyList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[PasswordExpiryPolicy]**](PasswordExpiryPolicy.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_password_expiry_policy_list import PaginatedPasswordExpiryPolicyList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPasswordExpiryPolicyList from a JSON string +paginated_password_expiry_policy_list_instance = PaginatedPasswordExpiryPolicyList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPasswordExpiryPolicyList.to_json()) + +# convert the object into a dict +paginated_password_expiry_policy_list_dict = paginated_password_expiry_policy_list_instance.to_dict() +# create an instance of PaginatedPasswordExpiryPolicyList from a dict +paginated_password_expiry_policy_list_from_dict = PaginatedPasswordExpiryPolicyList.from_dict(paginated_password_expiry_policy_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPasswordPolicyList.md b/docs/PaginatedPasswordPolicyList.md new file mode 100644 index 000000000..da2b9b0f7 --- /dev/null +++ b/docs/PaginatedPasswordPolicyList.md @@ -0,0 +1,31 @@ +# PaginatedPasswordPolicyList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[PasswordPolicy]**](PasswordPolicy.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_password_policy_list import PaginatedPasswordPolicyList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPasswordPolicyList from a JSON string +paginated_password_policy_list_instance = PaginatedPasswordPolicyList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPasswordPolicyList.to_json()) + +# convert the object into a dict +paginated_password_policy_list_dict = paginated_password_policy_list_instance.to_dict() +# create an instance of PaginatedPasswordPolicyList from a dict +paginated_password_policy_list_from_dict = PaginatedPasswordPolicyList.from_dict(paginated_password_policy_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPasswordStageList.md b/docs/PaginatedPasswordStageList.md new file mode 100644 index 000000000..de12c31d0 --- /dev/null +++ b/docs/PaginatedPasswordStageList.md @@ -0,0 +1,31 @@ +# PaginatedPasswordStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[PasswordStage]**](PasswordStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_password_stage_list import PaginatedPasswordStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPasswordStageList from a JSON string +paginated_password_stage_list_instance = PaginatedPasswordStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPasswordStageList.to_json()) + +# convert the object into a dict +paginated_password_stage_list_dict = paginated_password_stage_list_instance.to_dict() +# create an instance of PaginatedPasswordStageList from a dict +paginated_password_stage_list_from_dict = PaginatedPasswordStageList.from_dict(paginated_password_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPermissionList.md b/docs/PaginatedPermissionList.md new file mode 100644 index 000000000..bc69b8372 --- /dev/null +++ b/docs/PaginatedPermissionList.md @@ -0,0 +1,31 @@ +# PaginatedPermissionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Permission]**](Permission.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_permission_list import PaginatedPermissionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPermissionList from a JSON string +paginated_permission_list_instance = PaginatedPermissionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPermissionList.to_json()) + +# convert the object into a dict +paginated_permission_list_dict = paginated_permission_list_instance.to_dict() +# create an instance of PaginatedPermissionList from a dict +paginated_permission_list_from_dict = PaginatedPermissionList.from_dict(paginated_permission_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPlexSourceList.md b/docs/PaginatedPlexSourceList.md new file mode 100644 index 000000000..2af74396f --- /dev/null +++ b/docs/PaginatedPlexSourceList.md @@ -0,0 +1,31 @@ +# PaginatedPlexSourceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[PlexSource]**](PlexSource.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_plex_source_list import PaginatedPlexSourceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPlexSourceList from a JSON string +paginated_plex_source_list_instance = PaginatedPlexSourceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPlexSourceList.to_json()) + +# convert the object into a dict +paginated_plex_source_list_dict = paginated_plex_source_list_instance.to_dict() +# create an instance of PaginatedPlexSourceList from a dict +paginated_plex_source_list_from_dict = PaginatedPlexSourceList.from_dict(paginated_plex_source_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPlexSourcePropertyMappingList.md b/docs/PaginatedPlexSourcePropertyMappingList.md new file mode 100644 index 000000000..d342cc144 --- /dev/null +++ b/docs/PaginatedPlexSourcePropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedPlexSourcePropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[PlexSourcePropertyMapping]**](PlexSourcePropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_plex_source_property_mapping_list import PaginatedPlexSourcePropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPlexSourcePropertyMappingList from a JSON string +paginated_plex_source_property_mapping_list_instance = PaginatedPlexSourcePropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPlexSourcePropertyMappingList.to_json()) + +# convert the object into a dict +paginated_plex_source_property_mapping_list_dict = paginated_plex_source_property_mapping_list_instance.to_dict() +# create an instance of PaginatedPlexSourcePropertyMappingList from a dict +paginated_plex_source_property_mapping_list_from_dict = PaginatedPlexSourcePropertyMappingList.from_dict(paginated_plex_source_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPolicyBindingList.md b/docs/PaginatedPolicyBindingList.md new file mode 100644 index 000000000..571ae01ea --- /dev/null +++ b/docs/PaginatedPolicyBindingList.md @@ -0,0 +1,31 @@ +# PaginatedPolicyBindingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[PolicyBinding]**](PolicyBinding.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_policy_binding_list import PaginatedPolicyBindingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPolicyBindingList from a JSON string +paginated_policy_binding_list_instance = PaginatedPolicyBindingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPolicyBindingList.to_json()) + +# convert the object into a dict +paginated_policy_binding_list_dict = paginated_policy_binding_list_instance.to_dict() +# create an instance of PaginatedPolicyBindingList from a dict +paginated_policy_binding_list_from_dict = PaginatedPolicyBindingList.from_dict(paginated_policy_binding_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPolicyList.md b/docs/PaginatedPolicyList.md new file mode 100644 index 000000000..0ebc06f36 --- /dev/null +++ b/docs/PaginatedPolicyList.md @@ -0,0 +1,31 @@ +# PaginatedPolicyList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Policy]**](Policy.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_policy_list import PaginatedPolicyList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPolicyList from a JSON string +paginated_policy_list_instance = PaginatedPolicyList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPolicyList.to_json()) + +# convert the object into a dict +paginated_policy_list_dict = paginated_policy_list_instance.to_dict() +# create an instance of PaginatedPolicyList from a dict +paginated_policy_list_from_dict = PaginatedPolicyList.from_dict(paginated_policy_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPromptList.md b/docs/PaginatedPromptList.md new file mode 100644 index 000000000..dd5ed0e5e --- /dev/null +++ b/docs/PaginatedPromptList.md @@ -0,0 +1,31 @@ +# PaginatedPromptList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Prompt]**](Prompt.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_prompt_list import PaginatedPromptList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPromptList from a JSON string +paginated_prompt_list_instance = PaginatedPromptList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPromptList.to_json()) + +# convert the object into a dict +paginated_prompt_list_dict = paginated_prompt_list_instance.to_dict() +# create an instance of PaginatedPromptList from a dict +paginated_prompt_list_from_dict = PaginatedPromptList.from_dict(paginated_prompt_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPromptStageList.md b/docs/PaginatedPromptStageList.md new file mode 100644 index 000000000..ddef46cce --- /dev/null +++ b/docs/PaginatedPromptStageList.md @@ -0,0 +1,31 @@ +# PaginatedPromptStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[PromptStage]**](PromptStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_prompt_stage_list import PaginatedPromptStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPromptStageList from a JSON string +paginated_prompt_stage_list_instance = PaginatedPromptStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPromptStageList.to_json()) + +# convert the object into a dict +paginated_prompt_stage_list_dict = paginated_prompt_stage_list_instance.to_dict() +# create an instance of PaginatedPromptStageList from a dict +paginated_prompt_stage_list_from_dict = PaginatedPromptStageList.from_dict(paginated_prompt_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedPropertyMappingList.md b/docs/PaginatedPropertyMappingList.md new file mode 100644 index 000000000..b76ac1a10 --- /dev/null +++ b/docs/PaginatedPropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedPropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[PropertyMapping]**](PropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_property_mapping_list import PaginatedPropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedPropertyMappingList from a JSON string +paginated_property_mapping_list_instance = PaginatedPropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedPropertyMappingList.to_json()) + +# convert the object into a dict +paginated_property_mapping_list_dict = paginated_property_mapping_list_instance.to_dict() +# create an instance of PaginatedPropertyMappingList from a dict +paginated_property_mapping_list_from_dict = PaginatedPropertyMappingList.from_dict(paginated_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedProviderList.md b/docs/PaginatedProviderList.md new file mode 100644 index 000000000..6cf5683c6 --- /dev/null +++ b/docs/PaginatedProviderList.md @@ -0,0 +1,31 @@ +# PaginatedProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Provider]**](Provider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_provider_list import PaginatedProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedProviderList from a JSON string +paginated_provider_list_instance = PaginatedProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedProviderList.to_json()) + +# convert the object into a dict +paginated_provider_list_dict = paginated_provider_list_instance.to_dict() +# create an instance of PaginatedProviderList from a dict +paginated_provider_list_from_dict = PaginatedProviderList.from_dict(paginated_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedProxyOutpostConfigList.md b/docs/PaginatedProxyOutpostConfigList.md new file mode 100644 index 000000000..6cb8b4f81 --- /dev/null +++ b/docs/PaginatedProxyOutpostConfigList.md @@ -0,0 +1,31 @@ +# PaginatedProxyOutpostConfigList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ProxyOutpostConfig]**](ProxyOutpostConfig.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_proxy_outpost_config_list import PaginatedProxyOutpostConfigList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedProxyOutpostConfigList from a JSON string +paginated_proxy_outpost_config_list_instance = PaginatedProxyOutpostConfigList.from_json(json) +# print the JSON string representation of the object +print(PaginatedProxyOutpostConfigList.to_json()) + +# convert the object into a dict +paginated_proxy_outpost_config_list_dict = paginated_proxy_outpost_config_list_instance.to_dict() +# create an instance of PaginatedProxyOutpostConfigList from a dict +paginated_proxy_outpost_config_list_from_dict = PaginatedProxyOutpostConfigList.from_dict(paginated_proxy_outpost_config_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedProxyProviderList.md b/docs/PaginatedProxyProviderList.md new file mode 100644 index 000000000..fd0bd13e2 --- /dev/null +++ b/docs/PaginatedProxyProviderList.md @@ -0,0 +1,31 @@ +# PaginatedProxyProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ProxyProvider]**](ProxyProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_proxy_provider_list import PaginatedProxyProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedProxyProviderList from a JSON string +paginated_proxy_provider_list_instance = PaginatedProxyProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedProxyProviderList.to_json()) + +# convert the object into a dict +paginated_proxy_provider_list_dict = paginated_proxy_provider_list_instance.to_dict() +# create an instance of PaginatedProxyProviderList from a dict +paginated_proxy_provider_list_from_dict = PaginatedProxyProviderList.from_dict(paginated_proxy_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedRACPropertyMappingList.md b/docs/PaginatedRACPropertyMappingList.md new file mode 100644 index 000000000..975561808 --- /dev/null +++ b/docs/PaginatedRACPropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedRACPropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[RACPropertyMapping]**](RACPropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_rac_property_mapping_list import PaginatedRACPropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedRACPropertyMappingList from a JSON string +paginated_rac_property_mapping_list_instance = PaginatedRACPropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedRACPropertyMappingList.to_json()) + +# convert the object into a dict +paginated_rac_property_mapping_list_dict = paginated_rac_property_mapping_list_instance.to_dict() +# create an instance of PaginatedRACPropertyMappingList from a dict +paginated_rac_property_mapping_list_from_dict = PaginatedRACPropertyMappingList.from_dict(paginated_rac_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedRACProviderList.md b/docs/PaginatedRACProviderList.md new file mode 100644 index 000000000..d29b50639 --- /dev/null +++ b/docs/PaginatedRACProviderList.md @@ -0,0 +1,31 @@ +# PaginatedRACProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[RACProvider]**](RACProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_rac_provider_list import PaginatedRACProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedRACProviderList from a JSON string +paginated_rac_provider_list_instance = PaginatedRACProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedRACProviderList.to_json()) + +# convert the object into a dict +paginated_rac_provider_list_dict = paginated_rac_provider_list_instance.to_dict() +# create an instance of PaginatedRACProviderList from a dict +paginated_rac_provider_list_from_dict = PaginatedRACProviderList.from_dict(paginated_rac_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedRadiusOutpostConfigList.md b/docs/PaginatedRadiusOutpostConfigList.md new file mode 100644 index 000000000..70e8a0310 --- /dev/null +++ b/docs/PaginatedRadiusOutpostConfigList.md @@ -0,0 +1,31 @@ +# PaginatedRadiusOutpostConfigList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[RadiusOutpostConfig]**](RadiusOutpostConfig.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_radius_outpost_config_list import PaginatedRadiusOutpostConfigList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedRadiusOutpostConfigList from a JSON string +paginated_radius_outpost_config_list_instance = PaginatedRadiusOutpostConfigList.from_json(json) +# print the JSON string representation of the object +print(PaginatedRadiusOutpostConfigList.to_json()) + +# convert the object into a dict +paginated_radius_outpost_config_list_dict = paginated_radius_outpost_config_list_instance.to_dict() +# create an instance of PaginatedRadiusOutpostConfigList from a dict +paginated_radius_outpost_config_list_from_dict = PaginatedRadiusOutpostConfigList.from_dict(paginated_radius_outpost_config_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedRadiusProviderList.md b/docs/PaginatedRadiusProviderList.md new file mode 100644 index 000000000..4df1d27b4 --- /dev/null +++ b/docs/PaginatedRadiusProviderList.md @@ -0,0 +1,31 @@ +# PaginatedRadiusProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[RadiusProvider]**](RadiusProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_radius_provider_list import PaginatedRadiusProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedRadiusProviderList from a JSON string +paginated_radius_provider_list_instance = PaginatedRadiusProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedRadiusProviderList.to_json()) + +# convert the object into a dict +paginated_radius_provider_list_dict = paginated_radius_provider_list_instance.to_dict() +# create an instance of PaginatedRadiusProviderList from a dict +paginated_radius_provider_list_from_dict = PaginatedRadiusProviderList.from_dict(paginated_radius_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedRadiusProviderPropertyMappingList.md b/docs/PaginatedRadiusProviderPropertyMappingList.md new file mode 100644 index 000000000..37bcea23c --- /dev/null +++ b/docs/PaginatedRadiusProviderPropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedRadiusProviderPropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[RadiusProviderPropertyMapping]**](RadiusProviderPropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_radius_provider_property_mapping_list import PaginatedRadiusProviderPropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedRadiusProviderPropertyMappingList from a JSON string +paginated_radius_provider_property_mapping_list_instance = PaginatedRadiusProviderPropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedRadiusProviderPropertyMappingList.to_json()) + +# convert the object into a dict +paginated_radius_provider_property_mapping_list_dict = paginated_radius_provider_property_mapping_list_instance.to_dict() +# create an instance of PaginatedRadiusProviderPropertyMappingList from a dict +paginated_radius_provider_property_mapping_list_from_dict = PaginatedRadiusProviderPropertyMappingList.from_dict(paginated_radius_provider_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedRedirectStageList.md b/docs/PaginatedRedirectStageList.md new file mode 100644 index 000000000..993196bab --- /dev/null +++ b/docs/PaginatedRedirectStageList.md @@ -0,0 +1,31 @@ +# PaginatedRedirectStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[RedirectStage]**](RedirectStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_redirect_stage_list import PaginatedRedirectStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedRedirectStageList from a JSON string +paginated_redirect_stage_list_instance = PaginatedRedirectStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedRedirectStageList.to_json()) + +# convert the object into a dict +paginated_redirect_stage_list_dict = paginated_redirect_stage_list_instance.to_dict() +# create an instance of PaginatedRedirectStageList from a dict +paginated_redirect_stage_list_from_dict = PaginatedRedirectStageList.from_dict(paginated_redirect_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedReputationList.md b/docs/PaginatedReputationList.md new file mode 100644 index 000000000..3b5dd60d6 --- /dev/null +++ b/docs/PaginatedReputationList.md @@ -0,0 +1,31 @@ +# PaginatedReputationList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Reputation]**](Reputation.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_reputation_list import PaginatedReputationList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedReputationList from a JSON string +paginated_reputation_list_instance = PaginatedReputationList.from_json(json) +# print the JSON string representation of the object +print(PaginatedReputationList.to_json()) + +# convert the object into a dict +paginated_reputation_list_dict = paginated_reputation_list_instance.to_dict() +# create an instance of PaginatedReputationList from a dict +paginated_reputation_list_from_dict = PaginatedReputationList.from_dict(paginated_reputation_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedReputationPolicyList.md b/docs/PaginatedReputationPolicyList.md new file mode 100644 index 000000000..4f2622b3a --- /dev/null +++ b/docs/PaginatedReputationPolicyList.md @@ -0,0 +1,31 @@ +# PaginatedReputationPolicyList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ReputationPolicy]**](ReputationPolicy.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_reputation_policy_list import PaginatedReputationPolicyList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedReputationPolicyList from a JSON string +paginated_reputation_policy_list_instance = PaginatedReputationPolicyList.from_json(json) +# print the JSON string representation of the object +print(PaginatedReputationPolicyList.to_json()) + +# convert the object into a dict +paginated_reputation_policy_list_dict = paginated_reputation_policy_list_instance.to_dict() +# create an instance of PaginatedReputationPolicyList from a dict +paginated_reputation_policy_list_from_dict = PaginatedReputationPolicyList.from_dict(paginated_reputation_policy_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedRoleAssignedObjectPermissionList.md b/docs/PaginatedRoleAssignedObjectPermissionList.md new file mode 100644 index 000000000..e79ef5a1d --- /dev/null +++ b/docs/PaginatedRoleAssignedObjectPermissionList.md @@ -0,0 +1,31 @@ +# PaginatedRoleAssignedObjectPermissionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[RoleAssignedObjectPermission]**](RoleAssignedObjectPermission.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_role_assigned_object_permission_list import PaginatedRoleAssignedObjectPermissionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedRoleAssignedObjectPermissionList from a JSON string +paginated_role_assigned_object_permission_list_instance = PaginatedRoleAssignedObjectPermissionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedRoleAssignedObjectPermissionList.to_json()) + +# convert the object into a dict +paginated_role_assigned_object_permission_list_dict = paginated_role_assigned_object_permission_list_instance.to_dict() +# create an instance of PaginatedRoleAssignedObjectPermissionList from a dict +paginated_role_assigned_object_permission_list_from_dict = PaginatedRoleAssignedObjectPermissionList.from_dict(paginated_role_assigned_object_permission_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedRoleList.md b/docs/PaginatedRoleList.md new file mode 100644 index 000000000..71d18aba4 --- /dev/null +++ b/docs/PaginatedRoleList.md @@ -0,0 +1,31 @@ +# PaginatedRoleList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Role]**](Role.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_role_list import PaginatedRoleList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedRoleList from a JSON string +paginated_role_list_instance = PaginatedRoleList.from_json(json) +# print the JSON string representation of the object +print(PaginatedRoleList.to_json()) + +# convert the object into a dict +paginated_role_list_dict = paginated_role_list_instance.to_dict() +# create an instance of PaginatedRoleList from a dict +paginated_role_list_from_dict = PaginatedRoleList.from_dict(paginated_role_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSAMLPropertyMappingList.md b/docs/PaginatedSAMLPropertyMappingList.md new file mode 100644 index 000000000..2b4add62e --- /dev/null +++ b/docs/PaginatedSAMLPropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedSAMLPropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SAMLPropertyMapping]**](SAMLPropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_saml_property_mapping_list import PaginatedSAMLPropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSAMLPropertyMappingList from a JSON string +paginated_saml_property_mapping_list_instance = PaginatedSAMLPropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSAMLPropertyMappingList.to_json()) + +# convert the object into a dict +paginated_saml_property_mapping_list_dict = paginated_saml_property_mapping_list_instance.to_dict() +# create an instance of PaginatedSAMLPropertyMappingList from a dict +paginated_saml_property_mapping_list_from_dict = PaginatedSAMLPropertyMappingList.from_dict(paginated_saml_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSAMLProviderList.md b/docs/PaginatedSAMLProviderList.md new file mode 100644 index 000000000..2352b571b --- /dev/null +++ b/docs/PaginatedSAMLProviderList.md @@ -0,0 +1,31 @@ +# PaginatedSAMLProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SAMLProvider]**](SAMLProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_saml_provider_list import PaginatedSAMLProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSAMLProviderList from a JSON string +paginated_saml_provider_list_instance = PaginatedSAMLProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSAMLProviderList.to_json()) + +# convert the object into a dict +paginated_saml_provider_list_dict = paginated_saml_provider_list_instance.to_dict() +# create an instance of PaginatedSAMLProviderList from a dict +paginated_saml_provider_list_from_dict = PaginatedSAMLProviderList.from_dict(paginated_saml_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSAMLSourceList.md b/docs/PaginatedSAMLSourceList.md new file mode 100644 index 000000000..1c0fbd94d --- /dev/null +++ b/docs/PaginatedSAMLSourceList.md @@ -0,0 +1,31 @@ +# PaginatedSAMLSourceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SAMLSource]**](SAMLSource.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_saml_source_list import PaginatedSAMLSourceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSAMLSourceList from a JSON string +paginated_saml_source_list_instance = PaginatedSAMLSourceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSAMLSourceList.to_json()) + +# convert the object into a dict +paginated_saml_source_list_dict = paginated_saml_source_list_instance.to_dict() +# create an instance of PaginatedSAMLSourceList from a dict +paginated_saml_source_list_from_dict = PaginatedSAMLSourceList.from_dict(paginated_saml_source_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSAMLSourcePropertyMappingList.md b/docs/PaginatedSAMLSourcePropertyMappingList.md new file mode 100644 index 000000000..f04e0ee40 --- /dev/null +++ b/docs/PaginatedSAMLSourcePropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedSAMLSourcePropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SAMLSourcePropertyMapping]**](SAMLSourcePropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_saml_source_property_mapping_list import PaginatedSAMLSourcePropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSAMLSourcePropertyMappingList from a JSON string +paginated_saml_source_property_mapping_list_instance = PaginatedSAMLSourcePropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSAMLSourcePropertyMappingList.to_json()) + +# convert the object into a dict +paginated_saml_source_property_mapping_list_dict = paginated_saml_source_property_mapping_list_instance.to_dict() +# create an instance of PaginatedSAMLSourcePropertyMappingList from a dict +paginated_saml_source_property_mapping_list_from_dict = PaginatedSAMLSourcePropertyMappingList.from_dict(paginated_saml_source_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSCIMMappingList.md b/docs/PaginatedSCIMMappingList.md new file mode 100644 index 000000000..29b76e987 --- /dev/null +++ b/docs/PaginatedSCIMMappingList.md @@ -0,0 +1,31 @@ +# PaginatedSCIMMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SCIMMapping]**](SCIMMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_scim_mapping_list import PaginatedSCIMMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSCIMMappingList from a JSON string +paginated_scim_mapping_list_instance = PaginatedSCIMMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSCIMMappingList.to_json()) + +# convert the object into a dict +paginated_scim_mapping_list_dict = paginated_scim_mapping_list_instance.to_dict() +# create an instance of PaginatedSCIMMappingList from a dict +paginated_scim_mapping_list_from_dict = PaginatedSCIMMappingList.from_dict(paginated_scim_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSCIMProviderGroupList.md b/docs/PaginatedSCIMProviderGroupList.md new file mode 100644 index 000000000..bf7f5e71a --- /dev/null +++ b/docs/PaginatedSCIMProviderGroupList.md @@ -0,0 +1,31 @@ +# PaginatedSCIMProviderGroupList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SCIMProviderGroup]**](SCIMProviderGroup.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_scim_provider_group_list import PaginatedSCIMProviderGroupList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSCIMProviderGroupList from a JSON string +paginated_scim_provider_group_list_instance = PaginatedSCIMProviderGroupList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSCIMProviderGroupList.to_json()) + +# convert the object into a dict +paginated_scim_provider_group_list_dict = paginated_scim_provider_group_list_instance.to_dict() +# create an instance of PaginatedSCIMProviderGroupList from a dict +paginated_scim_provider_group_list_from_dict = PaginatedSCIMProviderGroupList.from_dict(paginated_scim_provider_group_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSCIMProviderList.md b/docs/PaginatedSCIMProviderList.md new file mode 100644 index 000000000..02dd73db3 --- /dev/null +++ b/docs/PaginatedSCIMProviderList.md @@ -0,0 +1,31 @@ +# PaginatedSCIMProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SCIMProvider]**](SCIMProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_scim_provider_list import PaginatedSCIMProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSCIMProviderList from a JSON string +paginated_scim_provider_list_instance = PaginatedSCIMProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSCIMProviderList.to_json()) + +# convert the object into a dict +paginated_scim_provider_list_dict = paginated_scim_provider_list_instance.to_dict() +# create an instance of PaginatedSCIMProviderList from a dict +paginated_scim_provider_list_from_dict = PaginatedSCIMProviderList.from_dict(paginated_scim_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSCIMProviderUserList.md b/docs/PaginatedSCIMProviderUserList.md new file mode 100644 index 000000000..18a81e128 --- /dev/null +++ b/docs/PaginatedSCIMProviderUserList.md @@ -0,0 +1,31 @@ +# PaginatedSCIMProviderUserList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SCIMProviderUser]**](SCIMProviderUser.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_scim_provider_user_list import PaginatedSCIMProviderUserList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSCIMProviderUserList from a JSON string +paginated_scim_provider_user_list_instance = PaginatedSCIMProviderUserList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSCIMProviderUserList.to_json()) + +# convert the object into a dict +paginated_scim_provider_user_list_dict = paginated_scim_provider_user_list_instance.to_dict() +# create an instance of PaginatedSCIMProviderUserList from a dict +paginated_scim_provider_user_list_from_dict = PaginatedSCIMProviderUserList.from_dict(paginated_scim_provider_user_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSCIMSourceGroupList.md b/docs/PaginatedSCIMSourceGroupList.md new file mode 100644 index 000000000..8aa92ce0e --- /dev/null +++ b/docs/PaginatedSCIMSourceGroupList.md @@ -0,0 +1,31 @@ +# PaginatedSCIMSourceGroupList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SCIMSourceGroup]**](SCIMSourceGroup.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_scim_source_group_list import PaginatedSCIMSourceGroupList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSCIMSourceGroupList from a JSON string +paginated_scim_source_group_list_instance = PaginatedSCIMSourceGroupList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSCIMSourceGroupList.to_json()) + +# convert the object into a dict +paginated_scim_source_group_list_dict = paginated_scim_source_group_list_instance.to_dict() +# create an instance of PaginatedSCIMSourceGroupList from a dict +paginated_scim_source_group_list_from_dict = PaginatedSCIMSourceGroupList.from_dict(paginated_scim_source_group_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSCIMSourceList.md b/docs/PaginatedSCIMSourceList.md new file mode 100644 index 000000000..89bd8f329 --- /dev/null +++ b/docs/PaginatedSCIMSourceList.md @@ -0,0 +1,31 @@ +# PaginatedSCIMSourceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SCIMSource]**](SCIMSource.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_scim_source_list import PaginatedSCIMSourceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSCIMSourceList from a JSON string +paginated_scim_source_list_instance = PaginatedSCIMSourceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSCIMSourceList.to_json()) + +# convert the object into a dict +paginated_scim_source_list_dict = paginated_scim_source_list_instance.to_dict() +# create an instance of PaginatedSCIMSourceList from a dict +paginated_scim_source_list_from_dict = PaginatedSCIMSourceList.from_dict(paginated_scim_source_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSCIMSourcePropertyMappingList.md b/docs/PaginatedSCIMSourcePropertyMappingList.md new file mode 100644 index 000000000..288ee2758 --- /dev/null +++ b/docs/PaginatedSCIMSourcePropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedSCIMSourcePropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SCIMSourcePropertyMapping]**](SCIMSourcePropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_scim_source_property_mapping_list import PaginatedSCIMSourcePropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSCIMSourcePropertyMappingList from a JSON string +paginated_scim_source_property_mapping_list_instance = PaginatedSCIMSourcePropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSCIMSourcePropertyMappingList.to_json()) + +# convert the object into a dict +paginated_scim_source_property_mapping_list_dict = paginated_scim_source_property_mapping_list_instance.to_dict() +# create an instance of PaginatedSCIMSourcePropertyMappingList from a dict +paginated_scim_source_property_mapping_list_from_dict = PaginatedSCIMSourcePropertyMappingList.from_dict(paginated_scim_source_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSCIMSourceUserList.md b/docs/PaginatedSCIMSourceUserList.md new file mode 100644 index 000000000..a2c952c38 --- /dev/null +++ b/docs/PaginatedSCIMSourceUserList.md @@ -0,0 +1,31 @@ +# PaginatedSCIMSourceUserList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SCIMSourceUser]**](SCIMSourceUser.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_scim_source_user_list import PaginatedSCIMSourceUserList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSCIMSourceUserList from a JSON string +paginated_scim_source_user_list_instance = PaginatedSCIMSourceUserList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSCIMSourceUserList.to_json()) + +# convert the object into a dict +paginated_scim_source_user_list_dict = paginated_scim_source_user_list_instance.to_dict() +# create an instance of PaginatedSCIMSourceUserList from a dict +paginated_scim_source_user_list_from_dict = PaginatedSCIMSourceUserList.from_dict(paginated_scim_source_user_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSMSDeviceList.md b/docs/PaginatedSMSDeviceList.md new file mode 100644 index 000000000..2c3fb0a80 --- /dev/null +++ b/docs/PaginatedSMSDeviceList.md @@ -0,0 +1,31 @@ +# PaginatedSMSDeviceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SMSDevice]**](SMSDevice.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_sms_device_list import PaginatedSMSDeviceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSMSDeviceList from a JSON string +paginated_sms_device_list_instance = PaginatedSMSDeviceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSMSDeviceList.to_json()) + +# convert the object into a dict +paginated_sms_device_list_dict = paginated_sms_device_list_instance.to_dict() +# create an instance of PaginatedSMSDeviceList from a dict +paginated_sms_device_list_from_dict = PaginatedSMSDeviceList.from_dict(paginated_sms_device_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSSFProviderList.md b/docs/PaginatedSSFProviderList.md new file mode 100644 index 000000000..505370761 --- /dev/null +++ b/docs/PaginatedSSFProviderList.md @@ -0,0 +1,31 @@ +# PaginatedSSFProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SSFProvider]**](SSFProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_ssf_provider_list import PaginatedSSFProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSSFProviderList from a JSON string +paginated_ssf_provider_list_instance = PaginatedSSFProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSSFProviderList.to_json()) + +# convert the object into a dict +paginated_ssf_provider_list_dict = paginated_ssf_provider_list_instance.to_dict() +# create an instance of PaginatedSSFProviderList from a dict +paginated_ssf_provider_list_from_dict = PaginatedSSFProviderList.from_dict(paginated_ssf_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSSFStreamList.md b/docs/PaginatedSSFStreamList.md new file mode 100644 index 000000000..192c2cdbf --- /dev/null +++ b/docs/PaginatedSSFStreamList.md @@ -0,0 +1,31 @@ +# PaginatedSSFStreamList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SSFStream]**](SSFStream.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_ssf_stream_list import PaginatedSSFStreamList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSSFStreamList from a JSON string +paginated_ssf_stream_list_instance = PaginatedSSFStreamList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSSFStreamList.to_json()) + +# convert the object into a dict +paginated_ssf_stream_list_dict = paginated_ssf_stream_list_instance.to_dict() +# create an instance of PaginatedSSFStreamList from a dict +paginated_ssf_stream_list_from_dict = PaginatedSSFStreamList.from_dict(paginated_ssf_stream_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedScheduleList.md b/docs/PaginatedScheduleList.md new file mode 100644 index 000000000..27189b7b2 --- /dev/null +++ b/docs/PaginatedScheduleList.md @@ -0,0 +1,31 @@ +# PaginatedScheduleList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Schedule]**](Schedule.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_schedule_list import PaginatedScheduleList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedScheduleList from a JSON string +paginated_schedule_list_instance = PaginatedScheduleList.from_json(json) +# print the JSON string representation of the object +print(PaginatedScheduleList.to_json()) + +# convert the object into a dict +paginated_schedule_list_dict = paginated_schedule_list_instance.to_dict() +# create an instance of PaginatedScheduleList from a dict +paginated_schedule_list_from_dict = PaginatedScheduleList.from_dict(paginated_schedule_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedScopeMappingList.md b/docs/PaginatedScopeMappingList.md new file mode 100644 index 000000000..3b892631c --- /dev/null +++ b/docs/PaginatedScopeMappingList.md @@ -0,0 +1,31 @@ +# PaginatedScopeMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ScopeMapping]**](ScopeMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_scope_mapping_list import PaginatedScopeMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedScopeMappingList from a JSON string +paginated_scope_mapping_list_instance = PaginatedScopeMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedScopeMappingList.to_json()) + +# convert the object into a dict +paginated_scope_mapping_list_dict = paginated_scope_mapping_list_instance.to_dict() +# create an instance of PaginatedScopeMappingList from a dict +paginated_scope_mapping_list_from_dict = PaginatedScopeMappingList.from_dict(paginated_scope_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedServiceConnectionList.md b/docs/PaginatedServiceConnectionList.md new file mode 100644 index 000000000..3ec63d8ad --- /dev/null +++ b/docs/PaginatedServiceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedServiceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[ServiceConnection]**](ServiceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_service_connection_list import PaginatedServiceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedServiceConnectionList from a JSON string +paginated_service_connection_list_instance = PaginatedServiceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedServiceConnectionList.to_json()) + +# convert the object into a dict +paginated_service_connection_list_dict = paginated_service_connection_list_instance.to_dict() +# create an instance of PaginatedServiceConnectionList from a dict +paginated_service_connection_list_from_dict = PaginatedServiceConnectionList.from_dict(paginated_service_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSourceList.md b/docs/PaginatedSourceList.md new file mode 100644 index 000000000..9aa023b63 --- /dev/null +++ b/docs/PaginatedSourceList.md @@ -0,0 +1,31 @@ +# PaginatedSourceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Source]**](Source.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_source_list import PaginatedSourceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSourceList from a JSON string +paginated_source_list_instance = PaginatedSourceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSourceList.to_json()) + +# convert the object into a dict +paginated_source_list_dict = paginated_source_list_instance.to_dict() +# create an instance of PaginatedSourceList from a dict +paginated_source_list_from_dict = PaginatedSourceList.from_dict(paginated_source_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedSourceStageList.md b/docs/PaginatedSourceStageList.md new file mode 100644 index 000000000..07e306bb8 --- /dev/null +++ b/docs/PaginatedSourceStageList.md @@ -0,0 +1,31 @@ +# PaginatedSourceStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[SourceStage]**](SourceStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_source_stage_list import PaginatedSourceStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedSourceStageList from a JSON string +paginated_source_stage_list_instance = PaginatedSourceStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedSourceStageList.to_json()) + +# convert the object into a dict +paginated_source_stage_list_dict = paginated_source_stage_list_instance.to_dict() +# create an instance of PaginatedSourceStageList from a dict +paginated_source_stage_list_from_dict = PaginatedSourceStageList.from_dict(paginated_source_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedStageList.md b/docs/PaginatedStageList.md new file mode 100644 index 000000000..d799f685a --- /dev/null +++ b/docs/PaginatedStageList.md @@ -0,0 +1,31 @@ +# PaginatedStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Stage]**](Stage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_stage_list import PaginatedStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedStageList from a JSON string +paginated_stage_list_instance = PaginatedStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedStageList.to_json()) + +# convert the object into a dict +paginated_stage_list_dict = paginated_stage_list_instance.to_dict() +# create an instance of PaginatedStageList from a dict +paginated_stage_list_from_dict = PaginatedStageList.from_dict(paginated_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedStaticDeviceList.md b/docs/PaginatedStaticDeviceList.md new file mode 100644 index 000000000..285377ffa --- /dev/null +++ b/docs/PaginatedStaticDeviceList.md @@ -0,0 +1,31 @@ +# PaginatedStaticDeviceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[StaticDevice]**](StaticDevice.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_static_device_list import PaginatedStaticDeviceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedStaticDeviceList from a JSON string +paginated_static_device_list_instance = PaginatedStaticDeviceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedStaticDeviceList.to_json()) + +# convert the object into a dict +paginated_static_device_list_dict = paginated_static_device_list_instance.to_dict() +# create an instance of PaginatedStaticDeviceList from a dict +paginated_static_device_list_from_dict = PaginatedStaticDeviceList.from_dict(paginated_static_device_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedTOTPDeviceList.md b/docs/PaginatedTOTPDeviceList.md new file mode 100644 index 000000000..394a72a0d --- /dev/null +++ b/docs/PaginatedTOTPDeviceList.md @@ -0,0 +1,31 @@ +# PaginatedTOTPDeviceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[TOTPDevice]**](TOTPDevice.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_totp_device_list import PaginatedTOTPDeviceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedTOTPDeviceList from a JSON string +paginated_totp_device_list_instance = PaginatedTOTPDeviceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedTOTPDeviceList.to_json()) + +# convert the object into a dict +paginated_totp_device_list_dict = paginated_totp_device_list_instance.to_dict() +# create an instance of PaginatedTOTPDeviceList from a dict +paginated_totp_device_list_from_dict = PaginatedTOTPDeviceList.from_dict(paginated_totp_device_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedTaskList.md b/docs/PaginatedTaskList.md new file mode 100644 index 000000000..a9678c820 --- /dev/null +++ b/docs/PaginatedTaskList.md @@ -0,0 +1,31 @@ +# PaginatedTaskList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Task]**](Task.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_task_list import PaginatedTaskList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedTaskList from a JSON string +paginated_task_list_instance = PaginatedTaskList.from_json(json) +# print the JSON string representation of the object +print(PaginatedTaskList.to_json()) + +# convert the object into a dict +paginated_task_list_dict = paginated_task_list_instance.to_dict() +# create an instance of PaginatedTaskList from a dict +paginated_task_list_from_dict = PaginatedTaskList.from_dict(paginated_task_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedTelegramSourceList.md b/docs/PaginatedTelegramSourceList.md new file mode 100644 index 000000000..f8fdb1756 --- /dev/null +++ b/docs/PaginatedTelegramSourceList.md @@ -0,0 +1,31 @@ +# PaginatedTelegramSourceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[TelegramSource]**](TelegramSource.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_telegram_source_list import PaginatedTelegramSourceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedTelegramSourceList from a JSON string +paginated_telegram_source_list_instance = PaginatedTelegramSourceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedTelegramSourceList.to_json()) + +# convert the object into a dict +paginated_telegram_source_list_dict = paginated_telegram_source_list_instance.to_dict() +# create an instance of PaginatedTelegramSourceList from a dict +paginated_telegram_source_list_from_dict = PaginatedTelegramSourceList.from_dict(paginated_telegram_source_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedTelegramSourcePropertyMappingList.md b/docs/PaginatedTelegramSourcePropertyMappingList.md new file mode 100644 index 000000000..8d3cbb43d --- /dev/null +++ b/docs/PaginatedTelegramSourcePropertyMappingList.md @@ -0,0 +1,31 @@ +# PaginatedTelegramSourcePropertyMappingList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[TelegramSourcePropertyMapping]**](TelegramSourcePropertyMapping.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_telegram_source_property_mapping_list import PaginatedTelegramSourcePropertyMappingList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedTelegramSourcePropertyMappingList from a JSON string +paginated_telegram_source_property_mapping_list_instance = PaginatedTelegramSourcePropertyMappingList.from_json(json) +# print the JSON string representation of the object +print(PaginatedTelegramSourcePropertyMappingList.to_json()) + +# convert the object into a dict +paginated_telegram_source_property_mapping_list_dict = paginated_telegram_source_property_mapping_list_instance.to_dict() +# create an instance of PaginatedTelegramSourcePropertyMappingList from a dict +paginated_telegram_source_property_mapping_list_from_dict = PaginatedTelegramSourcePropertyMappingList.from_dict(paginated_telegram_source_property_mapping_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedTenantList.md b/docs/PaginatedTenantList.md new file mode 100644 index 000000000..65ef3d9a0 --- /dev/null +++ b/docs/PaginatedTenantList.md @@ -0,0 +1,31 @@ +# PaginatedTenantList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Tenant]**](Tenant.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_tenant_list import PaginatedTenantList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedTenantList from a JSON string +paginated_tenant_list_instance = PaginatedTenantList.from_json(json) +# print the JSON string representation of the object +print(PaginatedTenantList.to_json()) + +# convert the object into a dict +paginated_tenant_list_dict = paginated_tenant_list_instance.to_dict() +# create an instance of PaginatedTenantList from a dict +paginated_tenant_list_from_dict = PaginatedTenantList.from_dict(paginated_tenant_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedTokenList.md b/docs/PaginatedTokenList.md new file mode 100644 index 000000000..62d7e2cbe --- /dev/null +++ b/docs/PaginatedTokenList.md @@ -0,0 +1,31 @@ +# PaginatedTokenList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[Token]**](Token.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_token_list import PaginatedTokenList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedTokenList from a JSON string +paginated_token_list_instance = PaginatedTokenList.from_json(json) +# print the JSON string representation of the object +print(PaginatedTokenList.to_json()) + +# convert the object into a dict +paginated_token_list_dict = paginated_token_list_instance.to_dict() +# create an instance of PaginatedTokenList from a dict +paginated_token_list_from_dict = PaginatedTokenList.from_dict(paginated_token_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedTokenModelList.md b/docs/PaginatedTokenModelList.md new file mode 100644 index 000000000..664d584d5 --- /dev/null +++ b/docs/PaginatedTokenModelList.md @@ -0,0 +1,31 @@ +# PaginatedTokenModelList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[TokenModel]**](TokenModel.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_token_model_list import PaginatedTokenModelList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedTokenModelList from a JSON string +paginated_token_model_list_instance = PaginatedTokenModelList.from_json(json) +# print the JSON string representation of the object +print(PaginatedTokenModelList.to_json()) + +# convert the object into a dict +paginated_token_model_list_dict = paginated_token_model_list_instance.to_dict() +# create an instance of PaginatedTokenModelList from a dict +paginated_token_model_list_from_dict = PaginatedTokenModelList.from_dict(paginated_token_model_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUniquePasswordPolicyList.md b/docs/PaginatedUniquePasswordPolicyList.md new file mode 100644 index 000000000..64e84b980 --- /dev/null +++ b/docs/PaginatedUniquePasswordPolicyList.md @@ -0,0 +1,31 @@ +# PaginatedUniquePasswordPolicyList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UniquePasswordPolicy]**](UniquePasswordPolicy.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_unique_password_policy_list import PaginatedUniquePasswordPolicyList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUniquePasswordPolicyList from a JSON string +paginated_unique_password_policy_list_instance = PaginatedUniquePasswordPolicyList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUniquePasswordPolicyList.to_json()) + +# convert the object into a dict +paginated_unique_password_policy_list_dict = paginated_unique_password_policy_list_instance.to_dict() +# create an instance of PaginatedUniquePasswordPolicyList from a dict +paginated_unique_password_policy_list_from_dict = PaginatedUniquePasswordPolicyList.from_dict(paginated_unique_password_policy_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserConsentList.md b/docs/PaginatedUserConsentList.md new file mode 100644 index 000000000..42eb3ce2e --- /dev/null +++ b/docs/PaginatedUserConsentList.md @@ -0,0 +1,31 @@ +# PaginatedUserConsentList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserConsent]**](UserConsent.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_consent_list import PaginatedUserConsentList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserConsentList from a JSON string +paginated_user_consent_list_instance = PaginatedUserConsentList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserConsentList.to_json()) + +# convert the object into a dict +paginated_user_consent_list_dict = paginated_user_consent_list_instance.to_dict() +# create an instance of PaginatedUserConsentList from a dict +paginated_user_consent_list_from_dict = PaginatedUserConsentList.from_dict(paginated_user_consent_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserDeleteStageList.md b/docs/PaginatedUserDeleteStageList.md new file mode 100644 index 000000000..b78b3d1f0 --- /dev/null +++ b/docs/PaginatedUserDeleteStageList.md @@ -0,0 +1,31 @@ +# PaginatedUserDeleteStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserDeleteStage]**](UserDeleteStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_delete_stage_list import PaginatedUserDeleteStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserDeleteStageList from a JSON string +paginated_user_delete_stage_list_instance = PaginatedUserDeleteStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserDeleteStageList.to_json()) + +# convert the object into a dict +paginated_user_delete_stage_list_dict = paginated_user_delete_stage_list_instance.to_dict() +# create an instance of PaginatedUserDeleteStageList from a dict +paginated_user_delete_stage_list_from_dict = PaginatedUserDeleteStageList.from_dict(paginated_user_delete_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserKerberosSourceConnectionList.md b/docs/PaginatedUserKerberosSourceConnectionList.md new file mode 100644 index 000000000..f8edb79e7 --- /dev/null +++ b/docs/PaginatedUserKerberosSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedUserKerberosSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserKerberosSourceConnection]**](UserKerberosSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_kerberos_source_connection_list import PaginatedUserKerberosSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserKerberosSourceConnectionList from a JSON string +paginated_user_kerberos_source_connection_list_instance = PaginatedUserKerberosSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserKerberosSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_user_kerberos_source_connection_list_dict = paginated_user_kerberos_source_connection_list_instance.to_dict() +# create an instance of PaginatedUserKerberosSourceConnectionList from a dict +paginated_user_kerberos_source_connection_list_from_dict = PaginatedUserKerberosSourceConnectionList.from_dict(paginated_user_kerberos_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserLDAPSourceConnectionList.md b/docs/PaginatedUserLDAPSourceConnectionList.md new file mode 100644 index 000000000..3633a1ee1 --- /dev/null +++ b/docs/PaginatedUserLDAPSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedUserLDAPSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserLDAPSourceConnection]**](UserLDAPSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_ldap_source_connection_list import PaginatedUserLDAPSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserLDAPSourceConnectionList from a JSON string +paginated_user_ldap_source_connection_list_instance = PaginatedUserLDAPSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserLDAPSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_user_ldap_source_connection_list_dict = paginated_user_ldap_source_connection_list_instance.to_dict() +# create an instance of PaginatedUserLDAPSourceConnectionList from a dict +paginated_user_ldap_source_connection_list_from_dict = PaginatedUserLDAPSourceConnectionList.from_dict(paginated_user_ldap_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserList.md b/docs/PaginatedUserList.md new file mode 100644 index 000000000..fb64eb4be --- /dev/null +++ b/docs/PaginatedUserList.md @@ -0,0 +1,31 @@ +# PaginatedUserList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[User]**](User.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_list import PaginatedUserList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserList from a JSON string +paginated_user_list_instance = PaginatedUserList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserList.to_json()) + +# convert the object into a dict +paginated_user_list_dict = paginated_user_list_instance.to_dict() +# create an instance of PaginatedUserList from a dict +paginated_user_list_from_dict = PaginatedUserList.from_dict(paginated_user_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserLoginStageList.md b/docs/PaginatedUserLoginStageList.md new file mode 100644 index 000000000..13d877365 --- /dev/null +++ b/docs/PaginatedUserLoginStageList.md @@ -0,0 +1,31 @@ +# PaginatedUserLoginStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserLoginStage]**](UserLoginStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_login_stage_list import PaginatedUserLoginStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserLoginStageList from a JSON string +paginated_user_login_stage_list_instance = PaginatedUserLoginStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserLoginStageList.to_json()) + +# convert the object into a dict +paginated_user_login_stage_list_dict = paginated_user_login_stage_list_instance.to_dict() +# create an instance of PaginatedUserLoginStageList from a dict +paginated_user_login_stage_list_from_dict = PaginatedUserLoginStageList.from_dict(paginated_user_login_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserLogoutStageList.md b/docs/PaginatedUserLogoutStageList.md new file mode 100644 index 000000000..770039474 --- /dev/null +++ b/docs/PaginatedUserLogoutStageList.md @@ -0,0 +1,31 @@ +# PaginatedUserLogoutStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserLogoutStage]**](UserLogoutStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_logout_stage_list import PaginatedUserLogoutStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserLogoutStageList from a JSON string +paginated_user_logout_stage_list_instance = PaginatedUserLogoutStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserLogoutStageList.to_json()) + +# convert the object into a dict +paginated_user_logout_stage_list_dict = paginated_user_logout_stage_list_instance.to_dict() +# create an instance of PaginatedUserLogoutStageList from a dict +paginated_user_logout_stage_list_from_dict = PaginatedUserLogoutStageList.from_dict(paginated_user_logout_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserOAuthSourceConnectionList.md b/docs/PaginatedUserOAuthSourceConnectionList.md new file mode 100644 index 000000000..202716945 --- /dev/null +++ b/docs/PaginatedUserOAuthSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedUserOAuthSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserOAuthSourceConnection]**](UserOAuthSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_o_auth_source_connection_list import PaginatedUserOAuthSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserOAuthSourceConnectionList from a JSON string +paginated_user_o_auth_source_connection_list_instance = PaginatedUserOAuthSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserOAuthSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_user_o_auth_source_connection_list_dict = paginated_user_o_auth_source_connection_list_instance.to_dict() +# create an instance of PaginatedUserOAuthSourceConnectionList from a dict +paginated_user_o_auth_source_connection_list_from_dict = PaginatedUserOAuthSourceConnectionList.from_dict(paginated_user_o_auth_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserPlexSourceConnectionList.md b/docs/PaginatedUserPlexSourceConnectionList.md new file mode 100644 index 000000000..f760501a9 --- /dev/null +++ b/docs/PaginatedUserPlexSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedUserPlexSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserPlexSourceConnection]**](UserPlexSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_plex_source_connection_list import PaginatedUserPlexSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserPlexSourceConnectionList from a JSON string +paginated_user_plex_source_connection_list_instance = PaginatedUserPlexSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserPlexSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_user_plex_source_connection_list_dict = paginated_user_plex_source_connection_list_instance.to_dict() +# create an instance of PaginatedUserPlexSourceConnectionList from a dict +paginated_user_plex_source_connection_list_from_dict = PaginatedUserPlexSourceConnectionList.from_dict(paginated_user_plex_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserSAMLSourceConnectionList.md b/docs/PaginatedUserSAMLSourceConnectionList.md new file mode 100644 index 000000000..f4405033e --- /dev/null +++ b/docs/PaginatedUserSAMLSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedUserSAMLSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserSAMLSourceConnection]**](UserSAMLSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_saml_source_connection_list import PaginatedUserSAMLSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserSAMLSourceConnectionList from a JSON string +paginated_user_saml_source_connection_list_instance = PaginatedUserSAMLSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserSAMLSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_user_saml_source_connection_list_dict = paginated_user_saml_source_connection_list_instance.to_dict() +# create an instance of PaginatedUserSAMLSourceConnectionList from a dict +paginated_user_saml_source_connection_list_from_dict = PaginatedUserSAMLSourceConnectionList.from_dict(paginated_user_saml_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserSourceConnectionList.md b/docs/PaginatedUserSourceConnectionList.md new file mode 100644 index 000000000..46289780b --- /dev/null +++ b/docs/PaginatedUserSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedUserSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserSourceConnection]**](UserSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_source_connection_list import PaginatedUserSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserSourceConnectionList from a JSON string +paginated_user_source_connection_list_instance = PaginatedUserSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_user_source_connection_list_dict = paginated_user_source_connection_list_instance.to_dict() +# create an instance of PaginatedUserSourceConnectionList from a dict +paginated_user_source_connection_list_from_dict = PaginatedUserSourceConnectionList.from_dict(paginated_user_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserTelegramSourceConnectionList.md b/docs/PaginatedUserTelegramSourceConnectionList.md new file mode 100644 index 000000000..9f1dad73c --- /dev/null +++ b/docs/PaginatedUserTelegramSourceConnectionList.md @@ -0,0 +1,31 @@ +# PaginatedUserTelegramSourceConnectionList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserTelegramSourceConnection]**](UserTelegramSourceConnection.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_telegram_source_connection_list import PaginatedUserTelegramSourceConnectionList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserTelegramSourceConnectionList from a JSON string +paginated_user_telegram_source_connection_list_instance = PaginatedUserTelegramSourceConnectionList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserTelegramSourceConnectionList.to_json()) + +# convert the object into a dict +paginated_user_telegram_source_connection_list_dict = paginated_user_telegram_source_connection_list_instance.to_dict() +# create an instance of PaginatedUserTelegramSourceConnectionList from a dict +paginated_user_telegram_source_connection_list_from_dict = PaginatedUserTelegramSourceConnectionList.from_dict(paginated_user_telegram_source_connection_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedUserWriteStageList.md b/docs/PaginatedUserWriteStageList.md new file mode 100644 index 000000000..0f2201ec7 --- /dev/null +++ b/docs/PaginatedUserWriteStageList.md @@ -0,0 +1,31 @@ +# PaginatedUserWriteStageList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[UserWriteStage]**](UserWriteStage.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_user_write_stage_list import PaginatedUserWriteStageList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedUserWriteStageList from a JSON string +paginated_user_write_stage_list_instance = PaginatedUserWriteStageList.from_json(json) +# print the JSON string representation of the object +print(PaginatedUserWriteStageList.to_json()) + +# convert the object into a dict +paginated_user_write_stage_list_dict = paginated_user_write_stage_list_instance.to_dict() +# create an instance of PaginatedUserWriteStageList from a dict +paginated_user_write_stage_list_from_dict = PaginatedUserWriteStageList.from_dict(paginated_user_write_stage_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedWSFederationProviderList.md b/docs/PaginatedWSFederationProviderList.md new file mode 100644 index 000000000..20c312f6e --- /dev/null +++ b/docs/PaginatedWSFederationProviderList.md @@ -0,0 +1,31 @@ +# PaginatedWSFederationProviderList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[WSFederationProvider]**](WSFederationProvider.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_ws_federation_provider_list import PaginatedWSFederationProviderList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedWSFederationProviderList from a JSON string +paginated_ws_federation_provider_list_instance = PaginatedWSFederationProviderList.from_json(json) +# print the JSON string representation of the object +print(PaginatedWSFederationProviderList.to_json()) + +# convert the object into a dict +paginated_ws_federation_provider_list_dict = paginated_ws_federation_provider_list_instance.to_dict() +# create an instance of PaginatedWSFederationProviderList from a dict +paginated_ws_federation_provider_list_from_dict = PaginatedWSFederationProviderList.from_dict(paginated_ws_federation_provider_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedWebAuthnDeviceList.md b/docs/PaginatedWebAuthnDeviceList.md new file mode 100644 index 000000000..3851019fa --- /dev/null +++ b/docs/PaginatedWebAuthnDeviceList.md @@ -0,0 +1,31 @@ +# PaginatedWebAuthnDeviceList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[WebAuthnDevice]**](WebAuthnDevice.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_web_authn_device_list import PaginatedWebAuthnDeviceList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedWebAuthnDeviceList from a JSON string +paginated_web_authn_device_list_instance = PaginatedWebAuthnDeviceList.from_json(json) +# print the JSON string representation of the object +print(PaginatedWebAuthnDeviceList.to_json()) + +# convert the object into a dict +paginated_web_authn_device_list_dict = paginated_web_authn_device_list_instance.to_dict() +# create an instance of PaginatedWebAuthnDeviceList from a dict +paginated_web_authn_device_list_from_dict = PaginatedWebAuthnDeviceList.from_dict(paginated_web_authn_device_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PaginatedWebAuthnDeviceTypeList.md b/docs/PaginatedWebAuthnDeviceTypeList.md new file mode 100644 index 000000000..d2335d33d --- /dev/null +++ b/docs/PaginatedWebAuthnDeviceTypeList.md @@ -0,0 +1,31 @@ +# PaginatedWebAuthnDeviceTypeList + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pagination** | [**Pagination**](Pagination.md) | | +**results** | [**List[WebAuthnDeviceType]**](WebAuthnDeviceType.md) | | +**autocomplete** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.paginated_web_authn_device_type_list import PaginatedWebAuthnDeviceTypeList + +# TODO update the JSON string below +json = "{}" +# create an instance of PaginatedWebAuthnDeviceTypeList from a JSON string +paginated_web_authn_device_type_list_instance = PaginatedWebAuthnDeviceTypeList.from_json(json) +# print the JSON string representation of the object +print(PaginatedWebAuthnDeviceTypeList.to_json()) + +# convert the object into a dict +paginated_web_authn_device_type_list_dict = paginated_web_authn_device_type_list_instance.to_dict() +# create an instance of PaginatedWebAuthnDeviceTypeList from a dict +paginated_web_authn_device_type_list_from_dict = PaginatedWebAuthnDeviceTypeList.from_dict(paginated_web_authn_device_type_list_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Pagination.md b/docs/Pagination.md new file mode 100644 index 000000000..50a74634a --- /dev/null +++ b/docs/Pagination.md @@ -0,0 +1,35 @@ +# Pagination + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**next** | **float** | | +**previous** | **float** | | +**count** | **float** | | +**current** | **float** | | +**total_pages** | **float** | | +**start_index** | **float** | | +**end_index** | **float** | | + +## Example + +```python +from authentik_client.models.pagination import Pagination + +# TODO update the JSON string below +json = "{}" +# create an instance of Pagination from a JSON string +pagination_instance = Pagination.from_json(json) +# print the JSON string representation of the object +print(Pagination.to_json()) + +# convert the object into a dict +pagination_dict = pagination_instance.to_dict() +# create an instance of Pagination from a dict +pagination_from_dict = Pagination.from_dict(pagination_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PartialGroup.md b/docs/PartialGroup.md new file mode 100644 index 000000000..81bc00fee --- /dev/null +++ b/docs/PartialGroup.md @@ -0,0 +1,34 @@ +# PartialGroup + +Partial Group Serializer, does not include child relations. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**num_pk** | **int** | Get a numerical, int32 ID for the group | [readonly] +**name** | **str** | | +**is_superuser** | **bool** | Users added to this group will be superusers. | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.partial_group import PartialGroup + +# TODO update the JSON string below +json = "{}" +# create an instance of PartialGroup from a JSON string +partial_group_instance = PartialGroup.from_json(json) +# print the JSON string representation of the object +print(PartialGroup.to_json()) + +# convert the object into a dict +partial_group_dict = partial_group_instance.to_dict() +# create an instance of PartialGroup from a dict +partial_group_from_dict = PartialGroup.from_dict(partial_group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PartialUser.md b/docs/PartialUser.md new file mode 100644 index 000000000..b2ae02395 --- /dev/null +++ b/docs/PartialUser.md @@ -0,0 +1,37 @@ +# PartialUser + +Partial User Serializer, does not include child relations. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**username** | **str** | Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only. | +**name** | **str** | User's display name. | +**is_active** | **bool** | Designates whether this user should be treated as active. Unselect this instead of deleting accounts. | [optional] +**last_login** | **datetime** | | [optional] +**email** | **str** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] +**uid** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.partial_user import PartialUser + +# TODO update the JSON string below +json = "{}" +# create an instance of PartialUser from a JSON string +partial_user_instance = PartialUser.from_json(json) +# print the JSON string representation of the object +print(PartialUser.to_json()) + +# convert the object into a dict +partial_user_dict = partial_user_instance.to_dict() +# create an instance of PartialUser from a dict +partial_user_from_dict = PartialUser.from_dict(partial_user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PasswordChallenge.md b/docs/PasswordChallenge.md new file mode 100644 index 000000000..d4f864d4c --- /dev/null +++ b/docs/PasswordChallenge.md @@ -0,0 +1,36 @@ +# PasswordChallenge + +Password challenge UI fields + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-password'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**recovery_url** | **str** | | [optional] +**allow_show_password** | **bool** | | [optional] [default to False] + +## Example + +```python +from authentik_client.models.password_challenge import PasswordChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordChallenge from a JSON string +password_challenge_instance = PasswordChallenge.from_json(json) +# print the JSON string representation of the object +print(PasswordChallenge.to_json()) + +# convert the object into a dict +password_challenge_dict = password_challenge_instance.to_dict() +# create an instance of PasswordChallenge from a dict +password_challenge_from_dict = PasswordChallenge.from_dict(password_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PasswordChallengeResponseRequest.md b/docs/PasswordChallengeResponseRequest.md new file mode 100644 index 000000000..0a707387a --- /dev/null +++ b/docs/PasswordChallengeResponseRequest.md @@ -0,0 +1,31 @@ +# PasswordChallengeResponseRequest + +Password challenge response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-password'] +**password** | **str** | | + +## Example + +```python +from authentik_client.models.password_challenge_response_request import PasswordChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordChallengeResponseRequest from a JSON string +password_challenge_response_request_instance = PasswordChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(PasswordChallengeResponseRequest.to_json()) + +# convert the object into a dict +password_challenge_response_request_dict = password_challenge_response_request_instance.to_dict() +# create an instance of PasswordChallengeResponseRequest from a dict +password_challenge_response_request_from_dict = PasswordChallengeResponseRequest.from_dict(password_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PasswordExpiryPolicy.md b/docs/PasswordExpiryPolicy.md new file mode 100644 index 000000000..5561b7daf --- /dev/null +++ b/docs/PasswordExpiryPolicy.md @@ -0,0 +1,39 @@ +# PasswordExpiryPolicy + +Password Expiry Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**bound_to** | **int** | Return objects policy is bound to | [readonly] +**days** | **int** | | +**deny_only** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordExpiryPolicy from a JSON string +password_expiry_policy_instance = PasswordExpiryPolicy.from_json(json) +# print the JSON string representation of the object +print(PasswordExpiryPolicy.to_json()) + +# convert the object into a dict +password_expiry_policy_dict = password_expiry_policy_instance.to_dict() +# create an instance of PasswordExpiryPolicy from a dict +password_expiry_policy_from_dict = PasswordExpiryPolicy.from_dict(password_expiry_policy_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PasswordExpiryPolicyRequest.md b/docs/PasswordExpiryPolicyRequest.md new file mode 100644 index 000000000..946b020d4 --- /dev/null +++ b/docs/PasswordExpiryPolicyRequest.md @@ -0,0 +1,33 @@ +# PasswordExpiryPolicyRequest + +Password Expiry Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**days** | **int** | | +**deny_only** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.password_expiry_policy_request import PasswordExpiryPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordExpiryPolicyRequest from a JSON string +password_expiry_policy_request_instance = PasswordExpiryPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PasswordExpiryPolicyRequest.to_json()) + +# convert the object into a dict +password_expiry_policy_request_dict = password_expiry_policy_request_instance.to_dict() +# create an instance of PasswordExpiryPolicyRequest from a dict +password_expiry_policy_request_from_dict = PasswordExpiryPolicyRequest.from_dict(password_expiry_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PasswordPolicy.md b/docs/PasswordPolicy.md new file mode 100644 index 000000000..59a5009ba --- /dev/null +++ b/docs/PasswordPolicy.md @@ -0,0 +1,50 @@ +# PasswordPolicy + +Password Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**bound_to** | **int** | Return objects policy is bound to | [readonly] +**password_field** | **str** | Field key to check, field keys defined in Prompt stages are available. | [optional] +**amount_digits** | **int** | | [optional] +**amount_uppercase** | **int** | | [optional] +**amount_lowercase** | **int** | | [optional] +**amount_symbols** | **int** | | [optional] +**length_min** | **int** | | [optional] +**symbol_charset** | **str** | | [optional] +**error_message** | **str** | | [optional] +**check_static_rules** | **bool** | | [optional] +**check_have_i_been_pwned** | **bool** | | [optional] +**check_zxcvbn** | **bool** | | [optional] +**hibp_allowed_count** | **int** | How many times the password hash is allowed to be on haveibeenpwned | [optional] +**zxcvbn_score_threshold** | **int** | If the zxcvbn score is equal or less than this value, the policy will fail. | [optional] + +## Example + +```python +from authentik_client.models.password_policy import PasswordPolicy + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordPolicy from a JSON string +password_policy_instance = PasswordPolicy.from_json(json) +# print the JSON string representation of the object +print(PasswordPolicy.to_json()) + +# convert the object into a dict +password_policy_dict = password_policy_instance.to_dict() +# create an instance of PasswordPolicy from a dict +password_policy_from_dict = PasswordPolicy.from_dict(password_policy_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PasswordPolicyRequest.md b/docs/PasswordPolicyRequest.md new file mode 100644 index 000000000..c28e1f9b5 --- /dev/null +++ b/docs/PasswordPolicyRequest.md @@ -0,0 +1,44 @@ +# PasswordPolicyRequest + +Password Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**password_field** | **str** | Field key to check, field keys defined in Prompt stages are available. | [optional] +**amount_digits** | **int** | | [optional] +**amount_uppercase** | **int** | | [optional] +**amount_lowercase** | **int** | | [optional] +**amount_symbols** | **int** | | [optional] +**length_min** | **int** | | [optional] +**symbol_charset** | **str** | | [optional] +**error_message** | **str** | | [optional] +**check_static_rules** | **bool** | | [optional] +**check_have_i_been_pwned** | **bool** | | [optional] +**check_zxcvbn** | **bool** | | [optional] +**hibp_allowed_count** | **int** | How many times the password hash is allowed to be on haveibeenpwned | [optional] +**zxcvbn_score_threshold** | **int** | If the zxcvbn score is equal or less than this value, the policy will fail. | [optional] + +## Example + +```python +from authentik_client.models.password_policy_request import PasswordPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordPolicyRequest from a JSON string +password_policy_request_instance = PasswordPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PasswordPolicyRequest.to_json()) + +# convert the object into a dict +password_policy_request_dict = password_policy_request_instance.to_dict() +# create an instance of PasswordPolicyRequest from a dict +password_policy_request_from_dict = PasswordPolicyRequest.from_dict(password_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PasswordStage.md b/docs/PasswordStage.md new file mode 100644 index 000000000..9b7c00242 --- /dev/null +++ b/docs/PasswordStage.md @@ -0,0 +1,40 @@ +# PasswordStage + +PasswordStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**backends** | [**List[BackendsEnum]**](BackendsEnum.md) | Selection of backends to test the password against. | +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**failed_attempts_before_cancel** | **int** | How many attempts a user has before the flow is canceled. To lock the user out, use a reputation policy and a user_write stage. | [optional] +**allow_show_password** | **bool** | When enabled, provides a 'show password' button with the password input field. | [optional] + +## Example + +```python +from authentik_client.models.password_stage import PasswordStage + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordStage from a JSON string +password_stage_instance = PasswordStage.from_json(json) +# print the JSON string representation of the object +print(PasswordStage.to_json()) + +# convert the object into a dict +password_stage_dict = password_stage_instance.to_dict() +# create an instance of PasswordStage from a dict +password_stage_from_dict = PasswordStage.from_dict(password_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PasswordStageRequest.md b/docs/PasswordStageRequest.md new file mode 100644 index 000000000..956334b6b --- /dev/null +++ b/docs/PasswordStageRequest.md @@ -0,0 +1,34 @@ +# PasswordStageRequest + +PasswordStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**backends** | [**List[BackendsEnum]**](BackendsEnum.md) | Selection of backends to test the password against. | +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**failed_attempts_before_cancel** | **int** | How many attempts a user has before the flow is canceled. To lock the user out, use a reputation policy and a user_write stage. | [optional] +**allow_show_password** | **bool** | When enabled, provides a 'show password' button with the password input field. | [optional] + +## Example + +```python +from authentik_client.models.password_stage_request import PasswordStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PasswordStageRequest from a JSON string +password_stage_request_instance = PasswordStageRequest.from_json(json) +# print the JSON string representation of the object +print(PasswordStageRequest.to_json()) + +# convert the object into a dict +password_stage_request_dict = password_stage_request_instance.to_dict() +# create an instance of PasswordStageRequest from a dict +password_stage_request_from_dict = PasswordStageRequest.from_dict(password_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAccountLockdownStageRequest.md b/docs/PatchedAccountLockdownStageRequest.md new file mode 100644 index 000000000..4c8061361 --- /dev/null +++ b/docs/PatchedAccountLockdownStageRequest.md @@ -0,0 +1,35 @@ +# PatchedAccountLockdownStageRequest + +AccountLockdownStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**deactivate_user** | **bool** | Deactivate the user account (set is_active to False) | [optional] +**set_unusable_password** | **bool** | Set an unusable password for the user | [optional] +**delete_sessions** | **bool** | Delete all active sessions for the user | [optional] +**revoke_tokens** | **bool** | Revoke all tokens for the user (API, app password, recovery, verification, OAuth) | [optional] +**self_service_completion_flow** | **UUID** | Flow to redirect users to after self-service lockdown. This flow should not require authentication since the user's session is deleted. | [optional] + +## Example + +```python +from authentik_client.models.patched_account_lockdown_stage_request import PatchedAccountLockdownStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAccountLockdownStageRequest from a JSON string +patched_account_lockdown_stage_request_instance = PatchedAccountLockdownStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAccountLockdownStageRequest.to_json()) + +# convert the object into a dict +patched_account_lockdown_stage_request_dict = patched_account_lockdown_stage_request_instance.to_dict() +# create an instance of PatchedAccountLockdownStageRequest from a dict +patched_account_lockdown_stage_request_from_dict = PatchedAccountLockdownStageRequest.from_dict(patched_account_lockdown_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAgentConnectorRequest.md b/docs/PatchedAgentConnectorRequest.md new file mode 100644 index 000000000..d2d73fe5b --- /dev/null +++ b/docs/PatchedAgentConnectorRequest.md @@ -0,0 +1,42 @@ +# PatchedAgentConnectorRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | [optional] +**enabled** | **bool** | | [optional] +**snapshot_expiry** | **str** | | [optional] +**auth_session_duration** | **str** | | [optional] +**auth_terminate_session_on_expiry** | **bool** | | [optional] +**refresh_interval** | **str** | | [optional] +**authorization_flow** | **UUID** | | [optional] +**nss_uid_offset** | **int** | | [optional] +**nss_gid_offset** | **int** | | [optional] +**challenge_key** | **UUID** | | [optional] +**challenge_idle_timeout** | **str** | | [optional] +**challenge_trigger_check_in** | **bool** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_agent_connector_request import PatchedAgentConnectorRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAgentConnectorRequest from a JSON string +patched_agent_connector_request_instance = PatchedAgentConnectorRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAgentConnectorRequest.to_json()) + +# convert the object into a dict +patched_agent_connector_request_dict = patched_agent_connector_request_instance.to_dict() +# create an instance of PatchedAgentConnectorRequest from a dict +patched_agent_connector_request_from_dict = PatchedAgentConnectorRequest.from_dict(patched_agent_connector_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAppleIndependentSecureEnclaveRequest.md b/docs/PatchedAppleIndependentSecureEnclaveRequest.md new file mode 100644 index 000000000..e1e95cef4 --- /dev/null +++ b/docs/PatchedAppleIndependentSecureEnclaveRequest.md @@ -0,0 +1,33 @@ +# PatchedAppleIndependentSecureEnclaveRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**uuid** | **UUID** | | [optional] +**user** | **int** | The user that this device belongs to. | [optional] +**apple_secure_enclave_key** | **str** | | [optional] +**apple_enclave_key_id** | **str** | | [optional] +**device_type** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_apple_independent_secure_enclave_request import PatchedAppleIndependentSecureEnclaveRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAppleIndependentSecureEnclaveRequest from a JSON string +patched_apple_independent_secure_enclave_request_instance = PatchedAppleIndependentSecureEnclaveRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAppleIndependentSecureEnclaveRequest.to_json()) + +# convert the object into a dict +patched_apple_independent_secure_enclave_request_dict = patched_apple_independent_secure_enclave_request_instance.to_dict() +# create an instance of PatchedAppleIndependentSecureEnclaveRequest from a dict +patched_apple_independent_secure_enclave_request_from_dict = PatchedAppleIndependentSecureEnclaveRequest.from_dict(patched_apple_independent_secure_enclave_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedApplicationEntitlementRequest.md b/docs/PatchedApplicationEntitlementRequest.md new file mode 100644 index 000000000..456dcbde8 --- /dev/null +++ b/docs/PatchedApplicationEntitlementRequest.md @@ -0,0 +1,32 @@ +# PatchedApplicationEntitlementRequest + +ApplicationEntitlement Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**app** | **UUID** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_application_entitlement_request import PatchedApplicationEntitlementRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedApplicationEntitlementRequest from a JSON string +patched_application_entitlement_request_instance = PatchedApplicationEntitlementRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedApplicationEntitlementRequest.to_json()) + +# convert the object into a dict +patched_application_entitlement_request_dict = patched_application_entitlement_request_instance.to_dict() +# create an instance of PatchedApplicationEntitlementRequest from a dict +patched_application_entitlement_request_from_dict = PatchedApplicationEntitlementRequest.from_dict(patched_application_entitlement_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedApplicationRequest.md b/docs/PatchedApplicationRequest.md new file mode 100644 index 000000000..949387738 --- /dev/null +++ b/docs/PatchedApplicationRequest.md @@ -0,0 +1,41 @@ +# PatchedApplicationRequest + +Application Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Application's display Name. | [optional] +**slug** | **str** | Internal application name, used in URLs. | [optional] +**provider** | **int** | | [optional] +**backchannel_providers** | **List[int]** | | [optional] +**open_in_new_tab** | **bool** | Open launch URL in a new browser tab or window. | [optional] +**meta_launch_url** | **str** | | [optional] +**meta_icon** | **str** | | [optional] +**meta_description** | **str** | | [optional] +**meta_publisher** | **str** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**group** | **str** | | [optional] +**meta_hide** | **bool** | Hide this application from the user's My applications page. | [optional] + +## Example + +```python +from authentik_client.models.patched_application_request import PatchedApplicationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedApplicationRequest from a JSON string +patched_application_request_instance = PatchedApplicationRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedApplicationRequest.to_json()) + +# convert the object into a dict +patched_application_request_dict = patched_application_request_instance.to_dict() +# create an instance of PatchedApplicationRequest from a dict +patched_application_request_from_dict = PatchedApplicationRequest.from_dict(patched_application_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAuthenticatorDuoStageRequest.md b/docs/PatchedAuthenticatorDuoStageRequest.md new file mode 100644 index 000000000..2fbe3512d --- /dev/null +++ b/docs/PatchedAuthenticatorDuoStageRequest.md @@ -0,0 +1,37 @@ +# PatchedAuthenticatorDuoStageRequest + +AuthenticatorDuoStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**client_id** | **str** | | [optional] +**client_secret** | **str** | | [optional] +**api_hostname** | **str** | | [optional] +**admin_integration_key** | **str** | | [optional] +**admin_secret_key** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_authenticator_duo_stage_request import PatchedAuthenticatorDuoStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAuthenticatorDuoStageRequest from a JSON string +patched_authenticator_duo_stage_request_instance = PatchedAuthenticatorDuoStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAuthenticatorDuoStageRequest.to_json()) + +# convert the object into a dict +patched_authenticator_duo_stage_request_dict = patched_authenticator_duo_stage_request_instance.to_dict() +# create an instance of PatchedAuthenticatorDuoStageRequest from a dict +patched_authenticator_duo_stage_request_from_dict = PatchedAuthenticatorDuoStageRequest.from_dict(patched_authenticator_duo_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAuthenticatorEmailStageRequest.md b/docs/PatchedAuthenticatorEmailStageRequest.md new file mode 100644 index 000000000..75d687d42 --- /dev/null +++ b/docs/PatchedAuthenticatorEmailStageRequest.md @@ -0,0 +1,44 @@ +# PatchedAuthenticatorEmailStageRequest + +AuthenticatorEmailStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**use_global_settings** | **bool** | When enabled, global Email connection settings will be used and connection settings below will be ignored. | [optional] +**host** | **str** | | [optional] +**port** | **int** | | [optional] +**username** | **str** | | [optional] +**password** | **str** | | [optional] +**use_tls** | **bool** | | [optional] +**use_ssl** | **bool** | | [optional] +**timeout** | **int** | | [optional] +**from_address** | **str** | | [optional] +**subject** | **str** | | [optional] +**token_expiry** | **str** | Time the token sent is valid (Format: hours=3,minutes=17,seconds=300). | [optional] +**template** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_authenticator_email_stage_request import PatchedAuthenticatorEmailStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAuthenticatorEmailStageRequest from a JSON string +patched_authenticator_email_stage_request_instance = PatchedAuthenticatorEmailStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAuthenticatorEmailStageRequest.to_json()) + +# convert the object into a dict +patched_authenticator_email_stage_request_dict = patched_authenticator_email_stage_request_instance.to_dict() +# create an instance of PatchedAuthenticatorEmailStageRequest from a dict +patched_authenticator_email_stage_request_from_dict = PatchedAuthenticatorEmailStageRequest.from_dict(patched_authenticator_email_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAuthenticatorEndpointGDTCStageRequest.md b/docs/PatchedAuthenticatorEndpointGDTCStageRequest.md new file mode 100644 index 000000000..8efef7381 --- /dev/null +++ b/docs/PatchedAuthenticatorEndpointGDTCStageRequest.md @@ -0,0 +1,33 @@ +# PatchedAuthenticatorEndpointGDTCStageRequest + +AuthenticatorEndpointGDTCStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**credentials** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_authenticator_endpoint_gdtc_stage_request import PatchedAuthenticatorEndpointGDTCStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAuthenticatorEndpointGDTCStageRequest from a JSON string +patched_authenticator_endpoint_gdtc_stage_request_instance = PatchedAuthenticatorEndpointGDTCStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAuthenticatorEndpointGDTCStageRequest.to_json()) + +# convert the object into a dict +patched_authenticator_endpoint_gdtc_stage_request_dict = patched_authenticator_endpoint_gdtc_stage_request_instance.to_dict() +# create an instance of PatchedAuthenticatorEndpointGDTCStageRequest from a dict +patched_authenticator_endpoint_gdtc_stage_request_from_dict = PatchedAuthenticatorEndpointGDTCStageRequest.from_dict(patched_authenticator_endpoint_gdtc_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAuthenticatorSMSStageRequest.md b/docs/PatchedAuthenticatorSMSStageRequest.md new file mode 100644 index 000000000..4094d0413 --- /dev/null +++ b/docs/PatchedAuthenticatorSMSStageRequest.md @@ -0,0 +1,40 @@ +# PatchedAuthenticatorSMSStageRequest + +AuthenticatorSMSStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**provider** | [**ProviderEnum**](ProviderEnum.md) | | [optional] +**from_number** | **str** | | [optional] +**account_sid** | **str** | | [optional] +**auth** | **str** | | [optional] +**auth_password** | **str** | | [optional] +**auth_type** | [**AuthTypeEnum**](AuthTypeEnum.md) | | [optional] +**verify_only** | **bool** | When enabled, the Phone number is only used during enrollment to verify the users authenticity. Only a hash of the phone number is saved to ensure it is not reused in the future. | [optional] +**mapping** | **UUID** | Optionally modify the payload being sent to custom providers. | [optional] + +## Example + +```python +from authentik_client.models.patched_authenticator_sms_stage_request import PatchedAuthenticatorSMSStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAuthenticatorSMSStageRequest from a JSON string +patched_authenticator_sms_stage_request_instance = PatchedAuthenticatorSMSStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAuthenticatorSMSStageRequest.to_json()) + +# convert the object into a dict +patched_authenticator_sms_stage_request_dict = patched_authenticator_sms_stage_request_instance.to_dict() +# create an instance of PatchedAuthenticatorSMSStageRequest from a dict +patched_authenticator_sms_stage_request_from_dict = PatchedAuthenticatorSMSStageRequest.from_dict(patched_authenticator_sms_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAuthenticatorStaticStageRequest.md b/docs/PatchedAuthenticatorStaticStageRequest.md new file mode 100644 index 000000000..bcc17e8b1 --- /dev/null +++ b/docs/PatchedAuthenticatorStaticStageRequest.md @@ -0,0 +1,34 @@ +# PatchedAuthenticatorStaticStageRequest + +AuthenticatorStaticStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**token_count** | **int** | | [optional] +**token_length** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.patched_authenticator_static_stage_request import PatchedAuthenticatorStaticStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAuthenticatorStaticStageRequest from a JSON string +patched_authenticator_static_stage_request_instance = PatchedAuthenticatorStaticStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAuthenticatorStaticStageRequest.to_json()) + +# convert the object into a dict +patched_authenticator_static_stage_request_dict = patched_authenticator_static_stage_request_instance.to_dict() +# create an instance of PatchedAuthenticatorStaticStageRequest from a dict +patched_authenticator_static_stage_request_from_dict = PatchedAuthenticatorStaticStageRequest.from_dict(patched_authenticator_static_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAuthenticatorTOTPStageRequest.md b/docs/PatchedAuthenticatorTOTPStageRequest.md new file mode 100644 index 000000000..844dd5889 --- /dev/null +++ b/docs/PatchedAuthenticatorTOTPStageRequest.md @@ -0,0 +1,33 @@ +# PatchedAuthenticatorTOTPStageRequest + +AuthenticatorTOTPStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**digits** | [**DigitsEnum**](DigitsEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.patched_authenticator_totp_stage_request import PatchedAuthenticatorTOTPStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAuthenticatorTOTPStageRequest from a JSON string +patched_authenticator_totp_stage_request_instance = PatchedAuthenticatorTOTPStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAuthenticatorTOTPStageRequest.to_json()) + +# convert the object into a dict +patched_authenticator_totp_stage_request_dict = patched_authenticator_totp_stage_request_instance.to_dict() +# create an instance of PatchedAuthenticatorTOTPStageRequest from a dict +patched_authenticator_totp_stage_request_from_dict = PatchedAuthenticatorTOTPStageRequest.from_dict(patched_authenticator_totp_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAuthenticatorValidateStageRequest.md b/docs/PatchedAuthenticatorValidateStageRequest.md new file mode 100644 index 000000000..573b4fcd0 --- /dev/null +++ b/docs/PatchedAuthenticatorValidateStageRequest.md @@ -0,0 +1,41 @@ +# PatchedAuthenticatorValidateStageRequest + +AuthenticatorValidateStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**not_configured_action** | [**NotConfiguredActionEnum**](NotConfiguredActionEnum.md) | | [optional] +**device_classes** | [**List[DeviceClassesEnum]**](DeviceClassesEnum.md) | Device classes which can be used to authenticate | [optional] +**configuration_stages** | **List[UUID]** | Stages used to configure Authenticator when user doesn't have any compatible devices. After this configuration Stage passes, the user is not prompted again. | [optional] +**last_auth_threshold** | **str** | If any of the user's device has been used within this threshold, this stage will be skipped | [optional] +**webauthn_user_verification** | [**UserVerificationEnum**](UserVerificationEnum.md) | Enforce user verification for WebAuthn devices. | [optional] +**webauthn_hints** | [**List[WebAuthnHintEnum]**](WebAuthnHintEnum.md) | | [optional] +**webauthn_allowed_device_types** | **List[UUID]** | | [optional] +**email_otp_throttling_factor** | **float** | | [optional] +**sms_otp_throttling_factor** | **float** | | [optional] +**totp_otp_throttling_factor** | **float** | | [optional] +**static_otp_throttling_factor** | **float** | | [optional] + +## Example + +```python +from authentik_client.models.patched_authenticator_validate_stage_request import PatchedAuthenticatorValidateStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAuthenticatorValidateStageRequest from a JSON string +patched_authenticator_validate_stage_request_instance = PatchedAuthenticatorValidateStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAuthenticatorValidateStageRequest.to_json()) + +# convert the object into a dict +patched_authenticator_validate_stage_request_dict = patched_authenticator_validate_stage_request_instance.to_dict() +# create an instance of PatchedAuthenticatorValidateStageRequest from a dict +patched_authenticator_validate_stage_request_from_dict = PatchedAuthenticatorValidateStageRequest.from_dict(patched_authenticator_validate_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedAuthenticatorWebAuthnStageRequest.md b/docs/PatchedAuthenticatorWebAuthnStageRequest.md new file mode 100644 index 000000000..5df2dee00 --- /dev/null +++ b/docs/PatchedAuthenticatorWebAuthnStageRequest.md @@ -0,0 +1,39 @@ +# PatchedAuthenticatorWebAuthnStageRequest + +AuthenticatorWebAuthnStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**friendly_name** | **str** | | [optional] +**user_verification** | [**UserVerificationEnum**](UserVerificationEnum.md) | | [optional] +**authenticator_attachment** | [**AuthenticatorAttachmentEnum**](AuthenticatorAttachmentEnum.md) | | [optional] +**resident_key_requirement** | [**UserVerificationEnum**](UserVerificationEnum.md) | | [optional] +**hints** | [**List[WebAuthnHintEnum]**](WebAuthnHintEnum.md) | | [optional] +**device_type_restrictions** | **List[UUID]** | | [optional] +**prevent_duplicate_devices** | **bool** | When enabled, a given device can only be registered once. | [optional] +**max_attempts** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.patched_authenticator_web_authn_stage_request import PatchedAuthenticatorWebAuthnStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedAuthenticatorWebAuthnStageRequest from a JSON string +patched_authenticator_web_authn_stage_request_instance = PatchedAuthenticatorWebAuthnStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedAuthenticatorWebAuthnStageRequest.to_json()) + +# convert the object into a dict +patched_authenticator_web_authn_stage_request_dict = patched_authenticator_web_authn_stage_request_instance.to_dict() +# create an instance of PatchedAuthenticatorWebAuthnStageRequest from a dict +patched_authenticator_web_authn_stage_request_from_dict = PatchedAuthenticatorWebAuthnStageRequest.from_dict(patched_authenticator_web_authn_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedBlueprintInstanceRequest.md b/docs/PatchedBlueprintInstanceRequest.md new file mode 100644 index 000000000..3c6f1167d --- /dev/null +++ b/docs/PatchedBlueprintInstanceRequest.md @@ -0,0 +1,34 @@ +# PatchedBlueprintInstanceRequest + +Info about a single blueprint instance file + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**path** | **str** | | [optional] [default to ''] +**context** | **Dict[str, object]** | | [optional] +**enabled** | **bool** | | [optional] +**content** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_blueprint_instance_request import PatchedBlueprintInstanceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedBlueprintInstanceRequest from a JSON string +patched_blueprint_instance_request_instance = PatchedBlueprintInstanceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedBlueprintInstanceRequest.to_json()) + +# convert the object into a dict +patched_blueprint_instance_request_dict = patched_blueprint_instance_request_instance.to_dict() +# create an instance of PatchedBlueprintInstanceRequest from a dict +patched_blueprint_instance_request_from_dict = PatchedBlueprintInstanceRequest.from_dict(patched_blueprint_instance_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedBrandRequest.md b/docs/PatchedBrandRequest.md new file mode 100644 index 000000000..08e124f74 --- /dev/null +++ b/docs/PatchedBrandRequest.md @@ -0,0 +1,47 @@ +# PatchedBrandRequest + +Brand Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**domain** | **str** | Domain that activates this brand. Can be a superset, i.e. `a.b` for `aa.b` and `ba.b` | [optional] +**default** | **bool** | | [optional] +**branding_title** | **str** | | [optional] +**branding_logo** | **str** | | [optional] +**branding_favicon** | **str** | | [optional] +**branding_custom_css** | **str** | | [optional] +**branding_default_flow_background** | **str** | | [optional] +**flow_authentication** | **UUID** | | [optional] +**flow_invalidation** | **UUID** | | [optional] +**flow_recovery** | **UUID** | | [optional] +**flow_unenrollment** | **UUID** | | [optional] +**flow_user_settings** | **UUID** | | [optional] +**flow_device_code** | **UUID** | | [optional] +**flow_lockdown** | **UUID** | | [optional] +**default_application** | **UUID** | When set, external users will be redirected to this application after authenticating. | [optional] +**web_certificate** | **UUID** | Web Certificate used by the authentik Core webserver. | [optional] +**client_certificates** | **List[UUID]** | Certificates used for client authentication. | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_brand_request import PatchedBrandRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedBrandRequest from a JSON string +patched_brand_request_instance = PatchedBrandRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedBrandRequest.to_json()) + +# convert the object into a dict +patched_brand_request_dict = patched_brand_request_instance.to_dict() +# create an instance of PatchedBrandRequest from a dict +patched_brand_request_from_dict = PatchedBrandRequest.from_dict(patched_brand_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedCaptchaStageRequest.md b/docs/PatchedCaptchaStageRequest.md new file mode 100644 index 000000000..2e02be3f4 --- /dev/null +++ b/docs/PatchedCaptchaStageRequest.md @@ -0,0 +1,38 @@ +# PatchedCaptchaStageRequest + +CaptchaStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**public_key** | **str** | Public key, acquired your captcha Provider. | [optional] +**private_key** | **str** | Private key, acquired your captcha Provider. | [optional] +**js_url** | **str** | | [optional] +**api_url** | **str** | | [optional] +**interactive** | **bool** | | [optional] +**score_min_threshold** | **float** | | [optional] +**score_max_threshold** | **float** | | [optional] +**error_on_invalid_score** | **bool** | When enabled and the received captcha score is outside of the given threshold, the stage will show an error message. When not enabled, the flow will continue, but the data from the captcha will be available in the context for policy decisions | [optional] + +## Example + +```python +from authentik_client.models.patched_captcha_stage_request import PatchedCaptchaStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedCaptchaStageRequest from a JSON string +patched_captcha_stage_request_instance = PatchedCaptchaStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedCaptchaStageRequest.to_json()) + +# convert the object into a dict +patched_captcha_stage_request_dict = patched_captcha_stage_request_instance.to_dict() +# create an instance of PatchedCaptchaStageRequest from a dict +patched_captcha_stage_request_from_dict = PatchedCaptchaStageRequest.from_dict(patched_captcha_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedCertificateKeyPairRequest.md b/docs/PatchedCertificateKeyPairRequest.md new file mode 100644 index 000000000..90d184070 --- /dev/null +++ b/docs/PatchedCertificateKeyPairRequest.md @@ -0,0 +1,32 @@ +# PatchedCertificateKeyPairRequest + +CertificateKeyPair Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**certificate_data** | **str** | PEM-encoded Certificate data | [optional] +**key_data** | **str** | Optional Private Key. If this is set, you can use this keypair for encryption. | [optional] + +## Example + +```python +from authentik_client.models.patched_certificate_key_pair_request import PatchedCertificateKeyPairRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedCertificateKeyPairRequest from a JSON string +patched_certificate_key_pair_request_instance = PatchedCertificateKeyPairRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedCertificateKeyPairRequest.to_json()) + +# convert the object into a dict +patched_certificate_key_pair_request_dict = patched_certificate_key_pair_request_instance.to_dict() +# create an instance of PatchedCertificateKeyPairRequest from a dict +patched_certificate_key_pair_request_from_dict = PatchedCertificateKeyPairRequest.from_dict(patched_certificate_key_pair_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedConnectionTokenRequest.md b/docs/PatchedConnectionTokenRequest.md new file mode 100644 index 000000000..b74e9db80 --- /dev/null +++ b/docs/PatchedConnectionTokenRequest.md @@ -0,0 +1,32 @@ +# PatchedConnectionTokenRequest + +ConnectionToken Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [optional] +**provider** | **int** | | [optional] +**endpoint** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.patched_connection_token_request import PatchedConnectionTokenRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedConnectionTokenRequest from a JSON string +patched_connection_token_request_instance = PatchedConnectionTokenRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedConnectionTokenRequest.to_json()) + +# convert the object into a dict +patched_connection_token_request_dict = patched_connection_token_request_instance.to_dict() +# create an instance of PatchedConnectionTokenRequest from a dict +patched_connection_token_request_from_dict = PatchedConnectionTokenRequest.from_dict(patched_connection_token_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedConsentStageRequest.md b/docs/PatchedConsentStageRequest.md new file mode 100644 index 000000000..615b09a89 --- /dev/null +++ b/docs/PatchedConsentStageRequest.md @@ -0,0 +1,32 @@ +# PatchedConsentStageRequest + +ConsentStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**mode** | [**ConsentModeEnum**](ConsentModeEnum.md) | | [optional] +**consent_expire_in** | **str** | Offset after which consent expires. (Format: hours=1;minutes=2;seconds=3). | [optional] + +## Example + +```python +from authentik_client.models.patched_consent_stage_request import PatchedConsentStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedConsentStageRequest from a JSON string +patched_consent_stage_request_instance = PatchedConsentStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedConsentStageRequest.to_json()) + +# convert the object into a dict +patched_consent_stage_request_dict = patched_consent_stage_request_instance.to_dict() +# create an instance of PatchedConsentStageRequest from a dict +patched_consent_stage_request_from_dict = PatchedConsentStageRequest.from_dict(patched_consent_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedDenyStageRequest.md b/docs/PatchedDenyStageRequest.md new file mode 100644 index 000000000..1bfea9c15 --- /dev/null +++ b/docs/PatchedDenyStageRequest.md @@ -0,0 +1,31 @@ +# PatchedDenyStageRequest + +DenyStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**deny_message** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_deny_stage_request import PatchedDenyStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedDenyStageRequest from a JSON string +patched_deny_stage_request_instance = PatchedDenyStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedDenyStageRequest.to_json()) + +# convert the object into a dict +patched_deny_stage_request_dict = patched_deny_stage_request_instance.to_dict() +# create an instance of PatchedDenyStageRequest from a dict +patched_deny_stage_request_from_dict = PatchedDenyStageRequest.from_dict(patched_deny_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedDeviceAccessGroupRequest.md b/docs/PatchedDeviceAccessGroupRequest.md new file mode 100644 index 000000000..ef586a92b --- /dev/null +++ b/docs/PatchedDeviceAccessGroupRequest.md @@ -0,0 +1,30 @@ +# PatchedDeviceAccessGroupRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_device_access_group_request import PatchedDeviceAccessGroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedDeviceAccessGroupRequest from a JSON string +patched_device_access_group_request_instance = PatchedDeviceAccessGroupRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedDeviceAccessGroupRequest.to_json()) + +# convert the object into a dict +patched_device_access_group_request_dict = patched_device_access_group_request_instance.to_dict() +# create an instance of PatchedDeviceAccessGroupRequest from a dict +patched_device_access_group_request_from_dict = PatchedDeviceAccessGroupRequest.from_dict(patched_device_access_group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedDeviceUserBindingRequest.md b/docs/PatchedDeviceUserBindingRequest.md new file mode 100644 index 000000000..65bcb3831 --- /dev/null +++ b/docs/PatchedDeviceUserBindingRequest.md @@ -0,0 +1,39 @@ +# PatchedDeviceUserBindingRequest + +PolicyBinding Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**policy** | **UUID** | | [optional] +**group** | **UUID** | | [optional] +**user** | **int** | | [optional] +**target** | **UUID** | | [optional] +**negate** | **bool** | Negates the outcome of the policy. Messages are unaffected. | [optional] +**enabled** | **bool** | | [optional] +**order** | **int** | | [optional] +**timeout** | **int** | Timeout after which Policy execution is terminated. | [optional] +**failure_result** | **bool** | Result if the Policy execution fails. | [optional] +**is_primary** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_device_user_binding_request import PatchedDeviceUserBindingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedDeviceUserBindingRequest from a JSON string +patched_device_user_binding_request_instance = PatchedDeviceUserBindingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedDeviceUserBindingRequest.to_json()) + +# convert the object into a dict +patched_device_user_binding_request_dict = patched_device_user_binding_request_instance.to_dict() +# create an instance of PatchedDeviceUserBindingRequest from a dict +patched_device_user_binding_request_from_dict = PatchedDeviceUserBindingRequest.from_dict(patched_device_user_binding_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedDockerServiceConnectionRequest.md b/docs/PatchedDockerServiceConnectionRequest.md new file mode 100644 index 000000000..a9983d8a6 --- /dev/null +++ b/docs/PatchedDockerServiceConnectionRequest.md @@ -0,0 +1,34 @@ +# PatchedDockerServiceConnectionRequest + +DockerServiceConnection Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**local** | **bool** | If enabled, use the local connection. Required Docker socket/Kubernetes Integration | [optional] +**url** | **str** | Can be in the format of 'unix://<path>' when connecting to a local docker daemon, or 'https://<hostname>:2376' when connecting to a remote system. | [optional] +**tls_verification** | **UUID** | CA which the endpoint's Certificate is verified against. Can be left empty for no validation. | [optional] +**tls_authentication** | **UUID** | Certificate/Key used for authentication. Can be left empty for no authentication. | [optional] + +## Example + +```python +from authentik_client.models.patched_docker_service_connection_request import PatchedDockerServiceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedDockerServiceConnectionRequest from a JSON string +patched_docker_service_connection_request_instance = PatchedDockerServiceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedDockerServiceConnectionRequest.to_json()) + +# convert the object into a dict +patched_docker_service_connection_request_dict = patched_docker_service_connection_request_instance.to_dict() +# create an instance of PatchedDockerServiceConnectionRequest from a dict +patched_docker_service_connection_request_from_dict = PatchedDockerServiceConnectionRequest.from_dict(patched_docker_service_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedDomainRequest.md b/docs/PatchedDomainRequest.md new file mode 100644 index 000000000..3474e333d --- /dev/null +++ b/docs/PatchedDomainRequest.md @@ -0,0 +1,32 @@ +# PatchedDomainRequest + +Domain Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**domain** | **str** | | [optional] +**is_primary** | **bool** | | [optional] +**tenant** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.patched_domain_request import PatchedDomainRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedDomainRequest from a JSON string +patched_domain_request_instance = PatchedDomainRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedDomainRequest.to_json()) + +# convert the object into a dict +patched_domain_request_dict = patched_domain_request_instance.to_dict() +# create an instance of PatchedDomainRequest from a dict +patched_domain_request_from_dict = PatchedDomainRequest.from_dict(patched_domain_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedDummyPolicyRequest.md b/docs/PatchedDummyPolicyRequest.md new file mode 100644 index 000000000..5faef2855 --- /dev/null +++ b/docs/PatchedDummyPolicyRequest.md @@ -0,0 +1,34 @@ +# PatchedDummyPolicyRequest + +Dummy Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**result** | **bool** | | [optional] +**wait_min** | **int** | | [optional] +**wait_max** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.patched_dummy_policy_request import PatchedDummyPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedDummyPolicyRequest from a JSON string +patched_dummy_policy_request_instance = PatchedDummyPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedDummyPolicyRequest.to_json()) + +# convert the object into a dict +patched_dummy_policy_request_dict = patched_dummy_policy_request_instance.to_dict() +# create an instance of PatchedDummyPolicyRequest from a dict +patched_dummy_policy_request_from_dict = PatchedDummyPolicyRequest.from_dict(patched_dummy_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedDummyStageRequest.md b/docs/PatchedDummyStageRequest.md new file mode 100644 index 000000000..24fd292d3 --- /dev/null +++ b/docs/PatchedDummyStageRequest.md @@ -0,0 +1,31 @@ +# PatchedDummyStageRequest + +DummyStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**throw_error** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_dummy_stage_request import PatchedDummyStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedDummyStageRequest from a JSON string +patched_dummy_stage_request_instance = PatchedDummyStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedDummyStageRequest.to_json()) + +# convert the object into a dict +patched_dummy_stage_request_dict = patched_dummy_stage_request_instance.to_dict() +# create an instance of PatchedDummyStageRequest from a dict +patched_dummy_stage_request_from_dict = PatchedDummyStageRequest.from_dict(patched_dummy_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedDuoDeviceRequest.md b/docs/PatchedDuoDeviceRequest.md new file mode 100644 index 000000000..51b72aba1 --- /dev/null +++ b/docs/PatchedDuoDeviceRequest.md @@ -0,0 +1,30 @@ +# PatchedDuoDeviceRequest + +Serializer for Duo authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | [optional] + +## Example + +```python +from authentik_client.models.patched_duo_device_request import PatchedDuoDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedDuoDeviceRequest from a JSON string +patched_duo_device_request_instance = PatchedDuoDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedDuoDeviceRequest.to_json()) + +# convert the object into a dict +patched_duo_device_request_dict = patched_duo_device_request_instance.to_dict() +# create an instance of PatchedDuoDeviceRequest from a dict +patched_duo_device_request_from_dict = PatchedDuoDeviceRequest.from_dict(patched_duo_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedEmailDeviceRequest.md b/docs/PatchedEmailDeviceRequest.md new file mode 100644 index 000000000..625514754 --- /dev/null +++ b/docs/PatchedEmailDeviceRequest.md @@ -0,0 +1,30 @@ +# PatchedEmailDeviceRequest + +Serializer for email authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | [optional] + +## Example + +```python +from authentik_client.models.patched_email_device_request import PatchedEmailDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedEmailDeviceRequest from a JSON string +patched_email_device_request_instance = PatchedEmailDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedEmailDeviceRequest.to_json()) + +# convert the object into a dict +patched_email_device_request_dict = patched_email_device_request_instance.to_dict() +# create an instance of PatchedEmailDeviceRequest from a dict +patched_email_device_request_from_dict = PatchedEmailDeviceRequest.from_dict(patched_email_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedEmailStageRequest.md b/docs/PatchedEmailStageRequest.md new file mode 100644 index 000000000..9c10d1d37 --- /dev/null +++ b/docs/PatchedEmailStageRequest.md @@ -0,0 +1,45 @@ +# PatchedEmailStageRequest + +EmailStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**use_global_settings** | **bool** | When enabled, global Email connection settings will be used and connection settings below will be ignored. | [optional] +**host** | **str** | | [optional] +**port** | **int** | | [optional] +**username** | **str** | | [optional] +**password** | **str** | | [optional] +**use_tls** | **bool** | | [optional] +**use_ssl** | **bool** | | [optional] +**timeout** | **int** | | [optional] +**from_address** | **str** | | [optional] +**token_expiry** | **str** | Time the token sent is valid (Format: hours=3,minutes=17,seconds=300). | [optional] +**subject** | **str** | | [optional] +**template** | **str** | | [optional] +**activate_user_on_success** | **bool** | Activate users upon completion of stage. | [optional] +**recovery_max_attempts** | **int** | | [optional] +**recovery_cache_timeout** | **str** | The time window used to count recent account recovery attempts. If the number of attempts exceed recovery_max_attempts within this period, further attempts will be rate-limited. (Format: hours=1;minutes=2;seconds=3). | [optional] + +## Example + +```python +from authentik_client.models.patched_email_stage_request import PatchedEmailStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedEmailStageRequest from a JSON string +patched_email_stage_request_instance = PatchedEmailStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedEmailStageRequest.to_json()) + +# convert the object into a dict +patched_email_stage_request_dict = patched_email_stage_request_instance.to_dict() +# create an instance of PatchedEmailStageRequest from a dict +patched_email_stage_request_from_dict = PatchedEmailStageRequest.from_dict(patched_email_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedEndpointDeviceRequest.md b/docs/PatchedEndpointDeviceRequest.md new file mode 100644 index 000000000..1d2349b00 --- /dev/null +++ b/docs/PatchedEndpointDeviceRequest.md @@ -0,0 +1,35 @@ +# PatchedEndpointDeviceRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_uuid** | **UUID** | | [optional] +**name** | **str** | | [optional] +**access_group** | **UUID** | | [optional] +**access_group_obj** | [**DeviceAccessGroupRequest**](DeviceAccessGroupRequest.md) | | [optional] +**expiring** | **bool** | | [optional] +**expires** | **datetime** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_endpoint_device_request import PatchedEndpointDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedEndpointDeviceRequest from a JSON string +patched_endpoint_device_request_instance = PatchedEndpointDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedEndpointDeviceRequest.to_json()) + +# convert the object into a dict +patched_endpoint_device_request_dict = patched_endpoint_device_request_instance.to_dict() +# create an instance of PatchedEndpointDeviceRequest from a dict +patched_endpoint_device_request_from_dict = PatchedEndpointDeviceRequest.from_dict(patched_endpoint_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedEndpointRequest.md b/docs/PatchedEndpointRequest.md new file mode 100644 index 000000000..ee3ebbe83 --- /dev/null +++ b/docs/PatchedEndpointRequest.md @@ -0,0 +1,37 @@ +# PatchedEndpointRequest + +Endpoint Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**provider** | **int** | | [optional] +**protocol** | [**ProtocolEnum**](ProtocolEnum.md) | | [optional] +**host** | **str** | | [optional] +**settings** | **Dict[str, object]** | | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**auth_mode** | [**EndpointAuthModeEnum**](EndpointAuthModeEnum.md) | | [optional] +**maximum_connections** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.patched_endpoint_request import PatchedEndpointRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedEndpointRequest from a JSON string +patched_endpoint_request_instance = PatchedEndpointRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedEndpointRequest.to_json()) + +# convert the object into a dict +patched_endpoint_request_dict = patched_endpoint_request_instance.to_dict() +# create an instance of PatchedEndpointRequest from a dict +patched_endpoint_request_from_dict = PatchedEndpointRequest.from_dict(patched_endpoint_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedEndpointStageRequest.md b/docs/PatchedEndpointStageRequest.md new file mode 100644 index 000000000..8073d58f6 --- /dev/null +++ b/docs/PatchedEndpointStageRequest.md @@ -0,0 +1,32 @@ +# PatchedEndpointStageRequest + +EndpointStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**connector** | **UUID** | | [optional] +**mode** | [**StageModeEnum**](StageModeEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.patched_endpoint_stage_request import PatchedEndpointStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedEndpointStageRequest from a JSON string +patched_endpoint_stage_request_instance = PatchedEndpointStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedEndpointStageRequest.to_json()) + +# convert the object into a dict +patched_endpoint_stage_request_dict = patched_endpoint_stage_request_instance.to_dict() +# create an instance of PatchedEndpointStageRequest from a dict +patched_endpoint_stage_request_from_dict = PatchedEndpointStageRequest.from_dict(patched_endpoint_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedEnrollmentTokenRequest.md b/docs/PatchedEnrollmentTokenRequest.md new file mode 100644 index 000000000..fcdbf344d --- /dev/null +++ b/docs/PatchedEnrollmentTokenRequest.md @@ -0,0 +1,33 @@ +# PatchedEnrollmentTokenRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**device_group** | **UUID** | | [optional] +**connector** | **UUID** | | [optional] +**name** | **str** | | [optional] +**expiring** | **bool** | | [optional] +**expires** | **datetime** | | [optional] + +## Example + +```python +from authentik_client.models.patched_enrollment_token_request import PatchedEnrollmentTokenRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedEnrollmentTokenRequest from a JSON string +patched_enrollment_token_request_instance = PatchedEnrollmentTokenRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedEnrollmentTokenRequest.to_json()) + +# convert the object into a dict +patched_enrollment_token_request_dict = patched_enrollment_token_request_instance.to_dict() +# create an instance of PatchedEnrollmentTokenRequest from a dict +patched_enrollment_token_request_from_dict = PatchedEnrollmentTokenRequest.from_dict(patched_enrollment_token_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedEventMatcherPolicyRequest.md b/docs/PatchedEventMatcherPolicyRequest.md new file mode 100644 index 000000000..e607a1ffd --- /dev/null +++ b/docs/PatchedEventMatcherPolicyRequest.md @@ -0,0 +1,36 @@ +# PatchedEventMatcherPolicyRequest + +Event Matcher Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**action** | [**EventActions**](EventActions.md) | Match created events with this action type. When left empty, all action types will be matched. | [optional] +**client_ip** | **str** | Matches Event's Client IP (strict matching, for network matching use an Expression Policy) | [optional] +**app** | [**AppEnum**](AppEnum.md) | Match events created by selected application. When left empty, all applications are matched. | [optional] +**model** | [**ModelEnum**](ModelEnum.md) | Match events created by selected model. When left empty, all models are matched. When an app is selected, all the application's models are matched. | [optional] +**query** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_event_matcher_policy_request import PatchedEventMatcherPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedEventMatcherPolicyRequest from a JSON string +patched_event_matcher_policy_request_instance = PatchedEventMatcherPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedEventMatcherPolicyRequest.to_json()) + +# convert the object into a dict +patched_event_matcher_policy_request_dict = patched_event_matcher_policy_request_instance.to_dict() +# create an instance of PatchedEventMatcherPolicyRequest from a dict +patched_event_matcher_policy_request_from_dict = PatchedEventMatcherPolicyRequest.from_dict(patched_event_matcher_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedEventRequest.md b/docs/PatchedEventRequest.md new file mode 100644 index 000000000..249bee56d --- /dev/null +++ b/docs/PatchedEventRequest.md @@ -0,0 +1,36 @@ +# PatchedEventRequest + +Event Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user** | **Dict[str, object]** | | [optional] +**action** | [**EventActions**](EventActions.md) | | [optional] +**app** | **str** | | [optional] +**context** | **Dict[str, object]** | | [optional] +**client_ip** | **str** | | [optional] +**expires** | **datetime** | | [optional] +**brand** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_event_request import PatchedEventRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedEventRequest from a JSON string +patched_event_request_instance = PatchedEventRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedEventRequest.to_json()) + +# convert the object into a dict +patched_event_request_dict = patched_event_request_instance.to_dict() +# create an instance of PatchedEventRequest from a dict +patched_event_request_from_dict = PatchedEventRequest.from_dict(patched_event_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedExpressionPolicyRequest.md b/docs/PatchedExpressionPolicyRequest.md new file mode 100644 index 000000000..28bf3ce6d --- /dev/null +++ b/docs/PatchedExpressionPolicyRequest.md @@ -0,0 +1,32 @@ +# PatchedExpressionPolicyRequest + +Group Membership Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_expression_policy_request import PatchedExpressionPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedExpressionPolicyRequest from a JSON string +patched_expression_policy_request_instance = PatchedExpressionPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedExpressionPolicyRequest.to_json()) + +# convert the object into a dict +patched_expression_policy_request_dict = patched_expression_policy_request_instance.to_dict() +# create an instance of PatchedExpressionPolicyRequest from a dict +patched_expression_policy_request_from_dict = PatchedExpressionPolicyRequest.from_dict(patched_expression_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedFleetConnectorRequest.md b/docs/PatchedFleetConnectorRequest.md new file mode 100644 index 000000000..52c2c5b33 --- /dev/null +++ b/docs/PatchedFleetConnectorRequest.md @@ -0,0 +1,37 @@ +# PatchedFleetConnectorRequest + +FleetConnector Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | [optional] +**enabled** | **bool** | | [optional] +**url** | **str** | | [optional] +**token** | **str** | | [optional] +**headers_mapping** | **UUID** | Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs | [optional] +**map_users** | **bool** | | [optional] +**map_teams_access_group** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_fleet_connector_request import PatchedFleetConnectorRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedFleetConnectorRequest from a JSON string +patched_fleet_connector_request_instance = PatchedFleetConnectorRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedFleetConnectorRequest.to_json()) + +# convert the object into a dict +patched_fleet_connector_request_dict = patched_fleet_connector_request_instance.to_dict() +# create an instance of PatchedFleetConnectorRequest from a dict +patched_fleet_connector_request_from_dict = PatchedFleetConnectorRequest.from_dict(patched_fleet_connector_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedFlowRequest.md b/docs/PatchedFlowRequest.md new file mode 100644 index 000000000..3bc2c5237 --- /dev/null +++ b/docs/PatchedFlowRequest.md @@ -0,0 +1,39 @@ +# PatchedFlowRequest + +Flow Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**slug** | **str** | Visible in the URL. | [optional] +**title** | **str** | Shown as the Title in Flow pages. | [optional] +**designation** | [**FlowDesignationEnum**](FlowDesignationEnum.md) | Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik. | [optional] +**background** | **str** | Background shown during execution | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**compatibility_mode** | **bool** | Enable compatibility mode, increases compatibility with password managers on mobile devices. | [optional] +**layout** | [**FlowLayoutEnum**](FlowLayoutEnum.md) | | [optional] +**denied_action** | [**DeniedActionEnum**](DeniedActionEnum.md) | Configure what should happen when a flow denies access to a user. | [optional] +**authentication** | [**AuthenticationEnum**](AuthenticationEnum.md) | Required level of authentication and authorization to access a flow. | [optional] + +## Example + +```python +from authentik_client.models.patched_flow_request import PatchedFlowRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedFlowRequest from a JSON string +patched_flow_request_instance = PatchedFlowRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedFlowRequest.to_json()) + +# convert the object into a dict +patched_flow_request_dict = patched_flow_request_instance.to_dict() +# create an instance of PatchedFlowRequest from a dict +patched_flow_request_from_dict = PatchedFlowRequest.from_dict(patched_flow_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedFlowStageBindingRequest.md b/docs/PatchedFlowStageBindingRequest.md new file mode 100644 index 000000000..d93228b1e --- /dev/null +++ b/docs/PatchedFlowStageBindingRequest.md @@ -0,0 +1,36 @@ +# PatchedFlowStageBindingRequest + +FlowStageBinding Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**target** | **UUID** | | [optional] +**stage** | **UUID** | | [optional] +**evaluate_on_plan** | **bool** | Evaluate policies during the Flow planning process. | [optional] +**re_evaluate_policies** | **bool** | Evaluate policies when the Stage is presented to the user. | [optional] +**order** | **int** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**invalid_response_action** | [**InvalidResponseActionEnum**](InvalidResponseActionEnum.md) | Configure how the flow executor should handle an invalid response to a challenge. RETRY returns the error message and a similar challenge to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT restarts the flow while keeping the current context. | [optional] + +## Example + +```python +from authentik_client.models.patched_flow_stage_binding_request import PatchedFlowStageBindingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedFlowStageBindingRequest from a JSON string +patched_flow_stage_binding_request_instance = PatchedFlowStageBindingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedFlowStageBindingRequest.to_json()) + +# convert the object into a dict +patched_flow_stage_binding_request_dict = patched_flow_stage_binding_request_instance.to_dict() +# create an instance of PatchedFlowStageBindingRequest from a dict +patched_flow_stage_binding_request_from_dict = PatchedFlowStageBindingRequest.from_dict(patched_flow_stage_binding_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGeoIPPolicyRequest.md b/docs/PatchedGeoIPPolicyRequest.md new file mode 100644 index 000000000..89a5e1ca5 --- /dev/null +++ b/docs/PatchedGeoIPPolicyRequest.md @@ -0,0 +1,39 @@ +# PatchedGeoIPPolicyRequest + +GeoIP Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**asns** | **List[int]** | | [optional] +**countries** | [**List[CountryCodeEnum]**](CountryCodeEnum.md) | | [optional] +**check_history_distance** | **bool** | | [optional] +**history_max_distance_km** | **int** | | [optional] +**distance_tolerance_km** | **int** | | [optional] +**history_login_count** | **int** | | [optional] +**check_impossible_travel** | **bool** | | [optional] +**impossible_tolerance_km** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.patched_geo_ip_policy_request import PatchedGeoIPPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGeoIPPolicyRequest from a JSON string +patched_geo_ip_policy_request_instance = PatchedGeoIPPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGeoIPPolicyRequest.to_json()) + +# convert the object into a dict +patched_geo_ip_policy_request_dict = patched_geo_ip_policy_request_instance.to_dict() +# create an instance of PatchedGeoIPPolicyRequest from a dict +patched_geo_ip_policy_request_from_dict = PatchedGeoIPPolicyRequest.from_dict(patched_geo_ip_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGoogleChromeConnectorRequest.md b/docs/PatchedGoogleChromeConnectorRequest.md new file mode 100644 index 000000000..0b8d878fe --- /dev/null +++ b/docs/PatchedGoogleChromeConnectorRequest.md @@ -0,0 +1,33 @@ +# PatchedGoogleChromeConnectorRequest + +GoogleChromeConnector Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**connector_uuid** | **UUID** | | [optional] +**name** | **str** | | [optional] +**enabled** | **bool** | | [optional] +**credentials** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_google_chrome_connector_request import PatchedGoogleChromeConnectorRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGoogleChromeConnectorRequest from a JSON string +patched_google_chrome_connector_request_instance = PatchedGoogleChromeConnectorRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGoogleChromeConnectorRequest.to_json()) + +# convert the object into a dict +patched_google_chrome_connector_request_dict = patched_google_chrome_connector_request_instance.to_dict() +# create an instance of PatchedGoogleChromeConnectorRequest from a dict +patched_google_chrome_connector_request_from_dict = PatchedGoogleChromeConnectorRequest.from_dict(patched_google_chrome_connector_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGoogleEndpointDeviceRequest.md b/docs/PatchedGoogleEndpointDeviceRequest.md new file mode 100644 index 000000000..870af92d3 --- /dev/null +++ b/docs/PatchedGoogleEndpointDeviceRequest.md @@ -0,0 +1,31 @@ +# PatchedGoogleEndpointDeviceRequest + +Serializer for Endpoint authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [optional] +**name** | **str** | The human-readable name of this device. | [optional] + +## Example + +```python +from authentik_client.models.patched_google_endpoint_device_request import PatchedGoogleEndpointDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGoogleEndpointDeviceRequest from a JSON string +patched_google_endpoint_device_request_instance = PatchedGoogleEndpointDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGoogleEndpointDeviceRequest.to_json()) + +# convert the object into a dict +patched_google_endpoint_device_request_dict = patched_google_endpoint_device_request_instance.to_dict() +# create an instance of PatchedGoogleEndpointDeviceRequest from a dict +patched_google_endpoint_device_request_from_dict = PatchedGoogleEndpointDeviceRequest.from_dict(patched_google_endpoint_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGoogleWorkspaceProviderMappingRequest.md b/docs/PatchedGoogleWorkspaceProviderMappingRequest.md new file mode 100644 index 000000000..d89926037 --- /dev/null +++ b/docs/PatchedGoogleWorkspaceProviderMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedGoogleWorkspaceProviderMappingRequest + +GoogleWorkspaceProviderMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_google_workspace_provider_mapping_request import PatchedGoogleWorkspaceProviderMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGoogleWorkspaceProviderMappingRequest from a JSON string +patched_google_workspace_provider_mapping_request_instance = PatchedGoogleWorkspaceProviderMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGoogleWorkspaceProviderMappingRequest.to_json()) + +# convert the object into a dict +patched_google_workspace_provider_mapping_request_dict = patched_google_workspace_provider_mapping_request_instance.to_dict() +# create an instance of PatchedGoogleWorkspaceProviderMappingRequest from a dict +patched_google_workspace_provider_mapping_request_from_dict = PatchedGoogleWorkspaceProviderMappingRequest.from_dict(patched_google_workspace_provider_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGoogleWorkspaceProviderRequest.md b/docs/PatchedGoogleWorkspaceProviderRequest.md new file mode 100644 index 000000000..ca15fc2f7 --- /dev/null +++ b/docs/PatchedGoogleWorkspaceProviderRequest.md @@ -0,0 +1,43 @@ +# PatchedGoogleWorkspaceProviderRequest + +GoogleWorkspaceProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**delegated_subject** | **str** | | [optional] +**credentials** | **Dict[str, object]** | | [optional] +**scopes** | **str** | | [optional] +**exclude_users_service_account** | **bool** | | [optional] +**filter_group** | **UUID** | | [optional] +**user_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**group_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**default_group_email_domain** | **str** | | [optional] +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] + +## Example + +```python +from authentik_client.models.patched_google_workspace_provider_request import PatchedGoogleWorkspaceProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGoogleWorkspaceProviderRequest from a JSON string +patched_google_workspace_provider_request_instance = PatchedGoogleWorkspaceProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGoogleWorkspaceProviderRequest.to_json()) + +# convert the object into a dict +patched_google_workspace_provider_request_dict = patched_google_workspace_provider_request_instance.to_dict() +# create an instance of PatchedGoogleWorkspaceProviderRequest from a dict +patched_google_workspace_provider_request_from_dict = PatchedGoogleWorkspaceProviderRequest.from_dict(patched_google_workspace_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGroupKerberosSourceConnectionRequest.md b/docs/PatchedGroupKerberosSourceConnectionRequest.md new file mode 100644 index 000000000..276ea62a0 --- /dev/null +++ b/docs/PatchedGroupKerberosSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedGroupKerberosSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_group_kerberos_source_connection_request import PatchedGroupKerberosSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGroupKerberosSourceConnectionRequest from a JSON string +patched_group_kerberos_source_connection_request_instance = PatchedGroupKerberosSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGroupKerberosSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_group_kerberos_source_connection_request_dict = patched_group_kerberos_source_connection_request_instance.to_dict() +# create an instance of PatchedGroupKerberosSourceConnectionRequest from a dict +patched_group_kerberos_source_connection_request_from_dict = PatchedGroupKerberosSourceConnectionRequest.from_dict(patched_group_kerberos_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGroupLDAPSourceConnectionRequest.md b/docs/PatchedGroupLDAPSourceConnectionRequest.md new file mode 100644 index 000000000..7c7e02e15 --- /dev/null +++ b/docs/PatchedGroupLDAPSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedGroupLDAPSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_group_ldap_source_connection_request import PatchedGroupLDAPSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGroupLDAPSourceConnectionRequest from a JSON string +patched_group_ldap_source_connection_request_instance = PatchedGroupLDAPSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGroupLDAPSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_group_ldap_source_connection_request_dict = patched_group_ldap_source_connection_request_instance.to_dict() +# create an instance of PatchedGroupLDAPSourceConnectionRequest from a dict +patched_group_ldap_source_connection_request_from_dict = PatchedGroupLDAPSourceConnectionRequest.from_dict(patched_group_ldap_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGroupOAuthSourceConnectionRequest.md b/docs/PatchedGroupOAuthSourceConnectionRequest.md new file mode 100644 index 000000000..28a1b7495 --- /dev/null +++ b/docs/PatchedGroupOAuthSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedGroupOAuthSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_group_o_auth_source_connection_request import PatchedGroupOAuthSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGroupOAuthSourceConnectionRequest from a JSON string +patched_group_o_auth_source_connection_request_instance = PatchedGroupOAuthSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGroupOAuthSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_group_o_auth_source_connection_request_dict = patched_group_o_auth_source_connection_request_instance.to_dict() +# create an instance of PatchedGroupOAuthSourceConnectionRequest from a dict +patched_group_o_auth_source_connection_request_from_dict = PatchedGroupOAuthSourceConnectionRequest.from_dict(patched_group_o_auth_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGroupPlexSourceConnectionRequest.md b/docs/PatchedGroupPlexSourceConnectionRequest.md new file mode 100644 index 000000000..2a70d7efa --- /dev/null +++ b/docs/PatchedGroupPlexSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedGroupPlexSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_group_plex_source_connection_request import PatchedGroupPlexSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGroupPlexSourceConnectionRequest from a JSON string +patched_group_plex_source_connection_request_instance = PatchedGroupPlexSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGroupPlexSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_group_plex_source_connection_request_dict = patched_group_plex_source_connection_request_instance.to_dict() +# create an instance of PatchedGroupPlexSourceConnectionRequest from a dict +patched_group_plex_source_connection_request_from_dict = PatchedGroupPlexSourceConnectionRequest.from_dict(patched_group_plex_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGroupRequest.md b/docs/PatchedGroupRequest.md new file mode 100644 index 000000000..3875a9758 --- /dev/null +++ b/docs/PatchedGroupRequest.md @@ -0,0 +1,35 @@ +# PatchedGroupRequest + +Group Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**is_superuser** | **bool** | Users added to this group will be superusers. | [optional] +**parents** | **List[UUID]** | | [optional] +**users** | **List[int]** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] +**roles** | **List[UUID]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_group_request import PatchedGroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGroupRequest from a JSON string +patched_group_request_instance = PatchedGroupRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGroupRequest.to_json()) + +# convert the object into a dict +patched_group_request_dict = patched_group_request_instance.to_dict() +# create an instance of PatchedGroupRequest from a dict +patched_group_request_from_dict = PatchedGroupRequest.from_dict(patched_group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGroupSAMLSourceConnectionRequest.md b/docs/PatchedGroupSAMLSourceConnectionRequest.md new file mode 100644 index 000000000..b491b979a --- /dev/null +++ b/docs/PatchedGroupSAMLSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedGroupSAMLSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_group_saml_source_connection_request import PatchedGroupSAMLSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGroupSAMLSourceConnectionRequest from a JSON string +patched_group_saml_source_connection_request_instance = PatchedGroupSAMLSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGroupSAMLSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_group_saml_source_connection_request_dict = patched_group_saml_source_connection_request_instance.to_dict() +# create an instance of PatchedGroupSAMLSourceConnectionRequest from a dict +patched_group_saml_source_connection_request_from_dict = PatchedGroupSAMLSourceConnectionRequest.from_dict(patched_group_saml_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGroupSourceConnectionRequest.md b/docs/PatchedGroupSourceConnectionRequest.md new file mode 100644 index 000000000..44261238c --- /dev/null +++ b/docs/PatchedGroupSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedGroupSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_group_source_connection_request import PatchedGroupSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGroupSourceConnectionRequest from a JSON string +patched_group_source_connection_request_instance = PatchedGroupSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGroupSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_group_source_connection_request_dict = patched_group_source_connection_request_instance.to_dict() +# create an instance of PatchedGroupSourceConnectionRequest from a dict +patched_group_source_connection_request_from_dict = PatchedGroupSourceConnectionRequest.from_dict(patched_group_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedGroupTelegramSourceConnectionRequest.md b/docs/PatchedGroupTelegramSourceConnectionRequest.md new file mode 100644 index 000000000..ce206563b --- /dev/null +++ b/docs/PatchedGroupTelegramSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedGroupTelegramSourceConnectionRequest + +Group Source Connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_group_telegram_source_connection_request import PatchedGroupTelegramSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedGroupTelegramSourceConnectionRequest from a JSON string +patched_group_telegram_source_connection_request_instance = PatchedGroupTelegramSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedGroupTelegramSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_group_telegram_source_connection_request_dict = patched_group_telegram_source_connection_request_instance.to_dict() +# create an instance of PatchedGroupTelegramSourceConnectionRequest from a dict +patched_group_telegram_source_connection_request_from_dict = PatchedGroupTelegramSourceConnectionRequest.from_dict(patched_group_telegram_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedIdentificationStageRequest.md b/docs/PatchedIdentificationStageRequest.md new file mode 100644 index 000000000..c9839679b --- /dev/null +++ b/docs/PatchedIdentificationStageRequest.md @@ -0,0 +1,43 @@ +# PatchedIdentificationStageRequest + +IdentificationStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**user_fields** | [**List[UserFieldsEnum]**](UserFieldsEnum.md) | Fields of the user object to match against. (Hold shift to select multiple options) | [optional] +**password_stage** | **UUID** | When set, shows a password field, instead of showing the password field as separate step. | [optional] +**captcha_stage** | **UUID** | When set, adds functionality exactly like a Captcha stage, but baked into the Identification stage. | [optional] +**case_insensitive_matching** | **bool** | When enabled, user fields are matched regardless of their casing. | [optional] +**show_matched_user** | **bool** | When a valid username/email has been entered, and this option is enabled, the user's username and avatar will be shown. Otherwise, the text that the user entered will be shown | [optional] +**enrollment_flow** | **UUID** | Optional enrollment flow, which is linked at the bottom of the page. | [optional] +**recovery_flow** | **UUID** | Optional recovery flow, which is linked at the bottom of the page. | [optional] +**passwordless_flow** | **UUID** | Optional passwordless flow, which is linked at the bottom of the page. | [optional] +**sources** | **List[UUID]** | Specify which sources should be shown. | [optional] +**show_source_labels** | **bool** | | [optional] +**pretend_user_exists** | **bool** | When enabled, the stage will succeed and continue even when incorrect user info is entered. | [optional] +**enable_remember_me** | **bool** | Show the user the 'Remember me on this device' toggle, allowing repeat users to skip straight to entering their password. | [optional] +**webauthn_stage** | **UUID** | When set, and conditional WebAuthn is available, allow the user to use their passkey as a first factor. | [optional] + +## Example + +```python +from authentik_client.models.patched_identification_stage_request import PatchedIdentificationStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedIdentificationStageRequest from a JSON string +patched_identification_stage_request_instance = PatchedIdentificationStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedIdentificationStageRequest.to_json()) + +# convert the object into a dict +patched_identification_stage_request_dict = patched_identification_stage_request_instance.to_dict() +# create an instance of PatchedIdentificationStageRequest from a dict +patched_identification_stage_request_from_dict = PatchedIdentificationStageRequest.from_dict(patched_identification_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedInitialPermissionsRequest.md b/docs/PatchedInitialPermissionsRequest.md new file mode 100644 index 000000000..bb93beee8 --- /dev/null +++ b/docs/PatchedInitialPermissionsRequest.md @@ -0,0 +1,32 @@ +# PatchedInitialPermissionsRequest + +InitialPermissions serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**role** | **UUID** | | [optional] +**permissions** | **List[int]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_initial_permissions_request import PatchedInitialPermissionsRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedInitialPermissionsRequest from a JSON string +patched_initial_permissions_request_instance = PatchedInitialPermissionsRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedInitialPermissionsRequest.to_json()) + +# convert the object into a dict +patched_initial_permissions_request_dict = patched_initial_permissions_request_instance.to_dict() +# create an instance of PatchedInitialPermissionsRequest from a dict +patched_initial_permissions_request_from_dict = PatchedInitialPermissionsRequest.from_dict(patched_initial_permissions_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedInvitationRequest.md b/docs/PatchedInvitationRequest.md new file mode 100644 index 000000000..c0b28e905 --- /dev/null +++ b/docs/PatchedInvitationRequest.md @@ -0,0 +1,34 @@ +# PatchedInvitationRequest + +Invitation Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**expires** | **datetime** | | [optional] +**fixed_data** | **Dict[str, object]** | | [optional] +**single_use** | **bool** | When enabled, the invitation will be deleted after usage. | [optional] +**flow** | **UUID** | When set, only the configured flow can use this invitation. | [optional] + +## Example + +```python +from authentik_client.models.patched_invitation_request import PatchedInvitationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedInvitationRequest from a JSON string +patched_invitation_request_instance = PatchedInvitationRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedInvitationRequest.to_json()) + +# convert the object into a dict +patched_invitation_request_dict = patched_invitation_request_instance.to_dict() +# create an instance of PatchedInvitationRequest from a dict +patched_invitation_request_from_dict = PatchedInvitationRequest.from_dict(patched_invitation_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedInvitationStageRequest.md b/docs/PatchedInvitationStageRequest.md new file mode 100644 index 000000000..4fc36e6a4 --- /dev/null +++ b/docs/PatchedInvitationStageRequest.md @@ -0,0 +1,31 @@ +# PatchedInvitationStageRequest + +InvitationStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**continue_flow_without_invitation** | **bool** | If this flag is set, this Stage will jump to the next Stage when no Invitation is given. By default this Stage will cancel the Flow when no invitation is given. | [optional] + +## Example + +```python +from authentik_client.models.patched_invitation_stage_request import PatchedInvitationStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedInvitationStageRequest from a JSON string +patched_invitation_stage_request_instance = PatchedInvitationStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedInvitationStageRequest.to_json()) + +# convert the object into a dict +patched_invitation_stage_request_dict = patched_invitation_stage_request_instance.to_dict() +# create an instance of PatchedInvitationStageRequest from a dict +patched_invitation_stage_request_from_dict = PatchedInvitationStageRequest.from_dict(patched_invitation_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedKerberosSourcePropertyMappingRequest.md b/docs/PatchedKerberosSourcePropertyMappingRequest.md new file mode 100644 index 000000000..157c0c6bd --- /dev/null +++ b/docs/PatchedKerberosSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedKerberosSourcePropertyMappingRequest + +Kerberos PropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_kerberos_source_property_mapping_request import PatchedKerberosSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedKerberosSourcePropertyMappingRequest from a JSON string +patched_kerberos_source_property_mapping_request_instance = PatchedKerberosSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedKerberosSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_kerberos_source_property_mapping_request_dict = patched_kerberos_source_property_mapping_request_instance.to_dict() +# create an instance of PatchedKerberosSourcePropertyMappingRequest from a dict +patched_kerberos_source_property_mapping_request_from_dict = PatchedKerberosSourcePropertyMappingRequest.from_dict(patched_kerberos_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedKerberosSourceRequest.md b/docs/PatchedKerberosSourceRequest.md new file mode 100644 index 000000000..7aeff16e6 --- /dev/null +++ b/docs/PatchedKerberosSourceRequest.md @@ -0,0 +1,56 @@ +# PatchedKerberosSourceRequest + +Kerberos Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | [optional] +**slug** | **str** | Internal source name, used in URLs. | [optional] +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**realm** | **str** | Kerberos realm | [optional] +**krb5_conf** | **str** | Custom krb5.conf to use. Uses the system one by default | [optional] +**kadmin_type** | [**KadminTypeEnum**](KadminTypeEnum.md) | KAdmin server type | [optional] +**sync_users** | **bool** | Sync users from Kerberos into authentik | [optional] +**sync_users_password** | **bool** | When a user changes their password, sync it back to Kerberos | [optional] +**sync_principal** | **str** | Principal to authenticate to kadmin for sync. | [optional] +**sync_password** | **str** | Password to authenticate to kadmin for sync | [optional] +**sync_keytab** | **str** | Keytab to authenticate to kadmin for sync. Must be base64-encoded or in the form TYPE:residual | [optional] +**sync_ccache** | **str** | Credentials cache to authenticate to kadmin for sync. Must be in the form TYPE:residual | [optional] +**spnego_server_name** | **str** | Force the use of a specific server name for SPNEGO. Must be in the form HTTP@hostname | [optional] +**spnego_keytab** | **str** | SPNEGO keytab base64-encoded or path to keytab in the form FILE:path | [optional] +**spnego_ccache** | **str** | Credential cache to use for SPNEGO in form type:residual | [optional] +**password_login_update_internal_password** | **bool** | If enabled, the authentik-stored password will be updated upon login with the Kerberos password backend | [optional] +**sync_outgoing_trigger_mode** | [**SyncOutgoingTriggerModeEnum**](SyncOutgoingTriggerModeEnum.md) | When to trigger sync for outgoing providers | [optional] + +## Example + +```python +from authentik_client.models.patched_kerberos_source_request import PatchedKerberosSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedKerberosSourceRequest from a JSON string +patched_kerberos_source_request_instance = PatchedKerberosSourceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedKerberosSourceRequest.to_json()) + +# convert the object into a dict +patched_kerberos_source_request_dict = patched_kerberos_source_request_instance.to_dict() +# create an instance of PatchedKerberosSourceRequest from a dict +patched_kerberos_source_request_from_dict = PatchedKerberosSourceRequest.from_dict(patched_kerberos_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedKubernetesServiceConnectionRequest.md b/docs/PatchedKubernetesServiceConnectionRequest.md new file mode 100644 index 000000000..c7a7747b8 --- /dev/null +++ b/docs/PatchedKubernetesServiceConnectionRequest.md @@ -0,0 +1,33 @@ +# PatchedKubernetesServiceConnectionRequest + +KubernetesServiceConnection Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**local** | **bool** | If enabled, use the local connection. Required Docker socket/Kubernetes Integration | [optional] +**kubeconfig** | **Dict[str, object]** | Paste your kubeconfig here. authentik will automatically use the currently selected context. | [optional] +**verify_ssl** | **bool** | Verify SSL Certificates of the Kubernetes API endpoint | [optional] + +## Example + +```python +from authentik_client.models.patched_kubernetes_service_connection_request import PatchedKubernetesServiceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedKubernetesServiceConnectionRequest from a JSON string +patched_kubernetes_service_connection_request_instance = PatchedKubernetesServiceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedKubernetesServiceConnectionRequest.to_json()) + +# convert the object into a dict +patched_kubernetes_service_connection_request_dict = patched_kubernetes_service_connection_request_instance.to_dict() +# create an instance of PatchedKubernetesServiceConnectionRequest from a dict +patched_kubernetes_service_connection_request_from_dict = PatchedKubernetesServiceConnectionRequest.from_dict(patched_kubernetes_service_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedLDAPProviderRequest.md b/docs/PatchedLDAPProviderRequest.md new file mode 100644 index 000000000..2564672ae --- /dev/null +++ b/docs/PatchedLDAPProviderRequest.md @@ -0,0 +1,42 @@ +# PatchedLDAPProviderRequest + +LDAPProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | [optional] +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**base_dn** | **str** | DN under which objects are accessible. | [optional] +**certificate** | **UUID** | | [optional] +**tls_server_name** | **str** | | [optional] +**uid_start_number** | **int** | The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber | [optional] +**gid_start_number** | **int** | The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber | [optional] +**search_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**bind_mode** | [**LDAPAPIAccessMode**](LDAPAPIAccessMode.md) | | [optional] +**mfa_support** | **bool** | When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon. | [optional] + +## Example + +```python +from authentik_client.models.patched_ldap_provider_request import PatchedLDAPProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedLDAPProviderRequest from a JSON string +patched_ldap_provider_request_instance = PatchedLDAPProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedLDAPProviderRequest.to_json()) + +# convert the object into a dict +patched_ldap_provider_request_dict = patched_ldap_provider_request_instance.to_dict() +# create an instance of PatchedLDAPProviderRequest from a dict +patched_ldap_provider_request_from_dict = PatchedLDAPProviderRequest.from_dict(patched_ldap_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedLDAPSourcePropertyMappingRequest.md b/docs/PatchedLDAPSourcePropertyMappingRequest.md new file mode 100644 index 000000000..41ddc6ec2 --- /dev/null +++ b/docs/PatchedLDAPSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedLDAPSourcePropertyMappingRequest + +LDAP PropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_ldap_source_property_mapping_request import PatchedLDAPSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedLDAPSourcePropertyMappingRequest from a JSON string +patched_ldap_source_property_mapping_request_instance = PatchedLDAPSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedLDAPSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_ldap_source_property_mapping_request_dict = patched_ldap_source_property_mapping_request_instance.to_dict() +# create an instance of PatchedLDAPSourcePropertyMappingRequest from a dict +patched_ldap_source_property_mapping_request_from_dict = PatchedLDAPSourcePropertyMappingRequest.from_dict(patched_ldap_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedLDAPSourceRequest.md b/docs/PatchedLDAPSourceRequest.md new file mode 100644 index 000000000..af018ae26 --- /dev/null +++ b/docs/PatchedLDAPSourceRequest.md @@ -0,0 +1,64 @@ +# PatchedLDAPSourceRequest + +LDAP Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | [optional] +**slug** | **str** | Internal source name, used in URLs. | [optional] +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**server_uri** | **str** | | [optional] +**peer_certificate** | **UUID** | Optionally verify the LDAP Server's Certificate against the CA Chain in this keypair. | [optional] +**client_certificate** | **UUID** | Client certificate to authenticate against the LDAP Server's Certificate. | [optional] +**bind_cn** | **str** | | [optional] +**bind_password** | **str** | | [optional] +**start_tls** | **bool** | | [optional] +**sni** | **bool** | | [optional] +**base_dn** | **str** | | [optional] +**additional_user_dn** | **str** | Prepended to Base DN for User-queries. | [optional] +**additional_group_dn** | **str** | Prepended to Base DN for Group-queries. | [optional] +**user_object_filter** | **str** | Consider Objects matching this filter to be Users. | [optional] +**group_object_filter** | **str** | Consider Objects matching this filter to be Groups. | [optional] +**group_membership_field** | **str** | Field which contains members of a group. | [optional] +**user_membership_attribute** | **str** | Attribute which matches the value of `group_membership_field`. | [optional] +**object_uniqueness_field** | **str** | Field which contains a unique Identifier. | [optional] +**password_login_update_internal_password** | **bool** | Update internal authentik password when login succeeds with LDAP | [optional] +**sync_users** | **bool** | | [optional] +**sync_users_password** | **bool** | When a user changes their password, sync it back to LDAP. This can only be enabled on a single LDAP source. | [optional] +**sync_groups** | **bool** | | [optional] +**sync_parent_group** | **UUID** | | [optional] +**lookup_groups_from_user** | **bool** | Lookup group membership based on a user attribute instead of a group attribute. This allows nested group resolution on systems like FreeIPA and Active Directory | [optional] +**delete_not_found_objects** | **bool** | Delete authentik users and groups which were previously supplied by this source, but are now missing from it. | [optional] +**sync_outgoing_trigger_mode** | [**SyncOutgoingTriggerModeEnum**](SyncOutgoingTriggerModeEnum.md) | When to trigger sync for outgoing providers | [optional] + +## Example + +```python +from authentik_client.models.patched_ldap_source_request import PatchedLDAPSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedLDAPSourceRequest from a JSON string +patched_ldap_source_request_instance = PatchedLDAPSourceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedLDAPSourceRequest.to_json()) + +# convert the object into a dict +patched_ldap_source_request_dict = patched_ldap_source_request_instance.to_dict() +# create an instance of PatchedLDAPSourceRequest from a dict +patched_ldap_source_request_from_dict = PatchedLDAPSourceRequest.from_dict(patched_ldap_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedLicenseRequest.md b/docs/PatchedLicenseRequest.md new file mode 100644 index 000000000..cd221ec4a --- /dev/null +++ b/docs/PatchedLicenseRequest.md @@ -0,0 +1,30 @@ +# PatchedLicenseRequest + +License Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**key** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_license_request import PatchedLicenseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedLicenseRequest from a JSON string +patched_license_request_instance = PatchedLicenseRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedLicenseRequest.to_json()) + +# convert the object into a dict +patched_license_request_dict = patched_license_request_instance.to_dict() +# create an instance of PatchedLicenseRequest from a dict +patched_license_request_from_dict = PatchedLicenseRequest.from_dict(patched_license_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedLifecycleRuleRequest.md b/docs/PatchedLifecycleRuleRequest.md new file mode 100644 index 000000000..1c9e0e77d --- /dev/null +++ b/docs/PatchedLifecycleRuleRequest.md @@ -0,0 +1,39 @@ +# PatchedLifecycleRuleRequest + +Mixin to validate that a valid enterprise license exists before allowing to save the object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**content_type** | [**ContentTypeEnum**](ContentTypeEnum.md) | | [optional] +**object_id** | **str** | | [optional] +**interval** | **str** | | [optional] +**grace_period** | **str** | | [optional] +**reviewer_groups** | **List[UUID]** | | [optional] +**min_reviewers** | **int** | | [optional] +**min_reviewers_is_per_group** | **bool** | | [optional] +**reviewers** | **List[UUID]** | | [optional] +**notification_transports** | **List[UUID]** | Select which transports should be used to notify the reviewers. If none are selected, the notification will only be shown in the authentik UI. | [optional] + +## Example + +```python +from authentik_client.models.patched_lifecycle_rule_request import PatchedLifecycleRuleRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedLifecycleRuleRequest from a JSON string +patched_lifecycle_rule_request_instance = PatchedLifecycleRuleRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedLifecycleRuleRequest.to_json()) + +# convert the object into a dict +patched_lifecycle_rule_request_dict = patched_lifecycle_rule_request_instance.to_dict() +# create an instance of PatchedLifecycleRuleRequest from a dict +patched_lifecycle_rule_request_from_dict = PatchedLifecycleRuleRequest.from_dict(patched_lifecycle_rule_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedMicrosoftEntraProviderMappingRequest.md b/docs/PatchedMicrosoftEntraProviderMappingRequest.md new file mode 100644 index 000000000..64fe86ea2 --- /dev/null +++ b/docs/PatchedMicrosoftEntraProviderMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedMicrosoftEntraProviderMappingRequest + +MicrosoftEntraProviderMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_microsoft_entra_provider_mapping_request import PatchedMicrosoftEntraProviderMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedMicrosoftEntraProviderMappingRequest from a JSON string +patched_microsoft_entra_provider_mapping_request_instance = PatchedMicrosoftEntraProviderMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedMicrosoftEntraProviderMappingRequest.to_json()) + +# convert the object into a dict +patched_microsoft_entra_provider_mapping_request_dict = patched_microsoft_entra_provider_mapping_request_instance.to_dict() +# create an instance of PatchedMicrosoftEntraProviderMappingRequest from a dict +patched_microsoft_entra_provider_mapping_request_from_dict = PatchedMicrosoftEntraProviderMappingRequest.from_dict(patched_microsoft_entra_provider_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedMicrosoftEntraProviderRequest.md b/docs/PatchedMicrosoftEntraProviderRequest.md new file mode 100644 index 000000000..20dbd642e --- /dev/null +++ b/docs/PatchedMicrosoftEntraProviderRequest.md @@ -0,0 +1,42 @@ +# PatchedMicrosoftEntraProviderRequest + +MicrosoftEntraProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**client_id** | **str** | | [optional] +**client_secret** | **str** | | [optional] +**tenant_id** | **str** | | [optional] +**exclude_users_service_account** | **bool** | | [optional] +**filter_group** | **UUID** | | [optional] +**user_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**group_delete_action** | [**OutgoingSyncDeleteAction**](OutgoingSyncDeleteAction.md) | | [optional] +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] + +## Example + +```python +from authentik_client.models.patched_microsoft_entra_provider_request import PatchedMicrosoftEntraProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedMicrosoftEntraProviderRequest from a JSON string +patched_microsoft_entra_provider_request_instance = PatchedMicrosoftEntraProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedMicrosoftEntraProviderRequest.to_json()) + +# convert the object into a dict +patched_microsoft_entra_provider_request_dict = patched_microsoft_entra_provider_request_instance.to_dict() +# create an instance of PatchedMicrosoftEntraProviderRequest from a dict +patched_microsoft_entra_provider_request_from_dict = PatchedMicrosoftEntraProviderRequest.from_dict(patched_microsoft_entra_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedMutualTLSStageRequest.md b/docs/PatchedMutualTLSStageRequest.md new file mode 100644 index 000000000..c15bd26f7 --- /dev/null +++ b/docs/PatchedMutualTLSStageRequest.md @@ -0,0 +1,34 @@ +# PatchedMutualTLSStageRequest + +MutualTLSStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**mode** | [**StageModeEnum**](StageModeEnum.md) | | [optional] +**certificate_authorities** | **List[UUID]** | Configure certificate authorities to validate the certificate against. This option has a higher priority than the `client_certificate` option on `Brand`. | [optional] +**cert_attribute** | [**CertAttributeEnum**](CertAttributeEnum.md) | | [optional] +**user_attribute** | [**UserAttributeEnum**](UserAttributeEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.patched_mutual_tls_stage_request import PatchedMutualTLSStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedMutualTLSStageRequest from a JSON string +patched_mutual_tls_stage_request_instance = PatchedMutualTLSStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedMutualTLSStageRequest.to_json()) + +# convert the object into a dict +patched_mutual_tls_stage_request_dict = patched_mutual_tls_stage_request_instance.to_dict() +# create an instance of PatchedMutualTLSStageRequest from a dict +patched_mutual_tls_stage_request_from_dict = PatchedMutualTLSStageRequest.from_dict(patched_mutual_tls_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedNotificationRequest.md b/docs/PatchedNotificationRequest.md new file mode 100644 index 000000000..4d3c13754 --- /dev/null +++ b/docs/PatchedNotificationRequest.md @@ -0,0 +1,33 @@ +# PatchedNotificationRequest + +Notification Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**hyperlink** | **str** | | [optional] +**hyperlink_label** | **str** | | [optional] +**event** | [**EventRequest**](EventRequest.md) | | [optional] +**seen** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_notification_request import PatchedNotificationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedNotificationRequest from a JSON string +patched_notification_request_instance = PatchedNotificationRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedNotificationRequest.to_json()) + +# convert the object into a dict +patched_notification_request_dict = patched_notification_request_instance.to_dict() +# create an instance of PatchedNotificationRequest from a dict +patched_notification_request_from_dict = PatchedNotificationRequest.from_dict(patched_notification_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedNotificationRuleRequest.md b/docs/PatchedNotificationRuleRequest.md new file mode 100644 index 000000000..62d4915c6 --- /dev/null +++ b/docs/PatchedNotificationRuleRequest.md @@ -0,0 +1,34 @@ +# PatchedNotificationRuleRequest + +NotificationRule Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**transports** | **List[UUID]** | Select which transports should be used to notify the user. If none are selected, the notification will only be shown in the authentik UI. | [optional] +**severity** | [**SeverityEnum**](SeverityEnum.md) | Controls which severity level the created notifications will have. | [optional] +**destination_group** | **UUID** | Define which group of users this notification should be sent and shown to. If left empty, Notification won't ben sent. | [optional] +**destination_event_user** | **bool** | When enabled, notification will be sent to user the user that triggered the event.When destination_group is configured, notification is sent to both. | [optional] + +## Example + +```python +from authentik_client.models.patched_notification_rule_request import PatchedNotificationRuleRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedNotificationRuleRequest from a JSON string +patched_notification_rule_request_instance = PatchedNotificationRuleRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedNotificationRuleRequest.to_json()) + +# convert the object into a dict +patched_notification_rule_request_dict = patched_notification_rule_request_instance.to_dict() +# create an instance of PatchedNotificationRuleRequest from a dict +patched_notification_rule_request_from_dict = PatchedNotificationRuleRequest.from_dict(patched_notification_rule_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedNotificationTransportRequest.md b/docs/PatchedNotificationTransportRequest.md new file mode 100644 index 000000000..d579b9389 --- /dev/null +++ b/docs/PatchedNotificationTransportRequest.md @@ -0,0 +1,38 @@ +# PatchedNotificationTransportRequest + +NotificationTransport Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**mode** | [**TransportModeEnum**](TransportModeEnum.md) | | [optional] +**webhook_url** | **str** | | [optional] +**webhook_ca** | **UUID** | When set, the selected certificate is used to validate the certificate of the webhook server. | [optional] +**webhook_mapping_body** | **UUID** | Customize the body of the request. Mapping should return data that is JSON-serializable. | [optional] +**webhook_mapping_headers** | **UUID** | Configure additional headers to be sent. Mapping should return a dictionary of key-value pairs | [optional] +**email_subject_prefix** | **str** | | [optional] +**email_template** | **str** | | [optional] +**send_once** | **bool** | Only send notification once, for example when sending a webhook into a chat channel. | [optional] + +## Example + +```python +from authentik_client.models.patched_notification_transport_request import PatchedNotificationTransportRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedNotificationTransportRequest from a JSON string +patched_notification_transport_request_instance = PatchedNotificationTransportRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedNotificationTransportRequest.to_json()) + +# convert the object into a dict +patched_notification_transport_request_dict = patched_notification_transport_request_instance.to_dict() +# create an instance of PatchedNotificationTransportRequest from a dict +patched_notification_transport_request_from_dict = PatchedNotificationTransportRequest.from_dict(patched_notification_transport_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedNotificationWebhookMappingRequest.md b/docs/PatchedNotificationWebhookMappingRequest.md new file mode 100644 index 000000000..28ff08773 --- /dev/null +++ b/docs/PatchedNotificationWebhookMappingRequest.md @@ -0,0 +1,31 @@ +# PatchedNotificationWebhookMappingRequest + +NotificationWebhookMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_notification_webhook_mapping_request import PatchedNotificationWebhookMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedNotificationWebhookMappingRequest from a JSON string +patched_notification_webhook_mapping_request_instance = PatchedNotificationWebhookMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedNotificationWebhookMappingRequest.to_json()) + +# convert the object into a dict +patched_notification_webhook_mapping_request_dict = patched_notification_webhook_mapping_request_instance.to_dict() +# create an instance of PatchedNotificationWebhookMappingRequest from a dict +patched_notification_webhook_mapping_request_from_dict = PatchedNotificationWebhookMappingRequest.from_dict(patched_notification_webhook_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedOAuth2ProviderRequest.md b/docs/PatchedOAuth2ProviderRequest.md new file mode 100644 index 000000000..a5a472138 --- /dev/null +++ b/docs/PatchedOAuth2ProviderRequest.md @@ -0,0 +1,52 @@ +# PatchedOAuth2ProviderRequest + +OAuth2Provider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | [optional] +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**client_type** | [**ClientTypeEnum**](ClientTypeEnum.md) | Confidential clients are capable of maintaining the confidentiality of their credentials. Public clients are incapable | [optional] +**grant_types** | [**List[GrantTypesEnum]**](GrantTypesEnum.md) | | [optional] +**client_id** | **str** | | [optional] +**client_secret** | **str** | | [optional] +**access_code_validity** | **str** | Access codes not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**access_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_threshold** | **str** | When refreshing a token, if the refresh token is valid for less than this duration, it will be renewed. When set to seconds=0, token will always be renewed. (Format: hours=1;minutes=2;seconds=3). | [optional] +**include_claims_in_id_token** | **bool** | Include User claims from scopes in the id_token, for applications that don't access the userinfo endpoint. | [optional] +**signing_key** | **UUID** | Key used to sign the tokens. | [optional] +**encryption_key** | **UUID** | Key used to encrypt the tokens. When set, tokens will be encrypted and returned as JWEs. | [optional] +**redirect_uris** | [**List[RedirectURIRequest]**](RedirectURIRequest.md) | | [optional] +**logout_uri** | **str** | | [optional] +**logout_method** | [**OAuth2ProviderLogoutMethodEnum**](OAuth2ProviderLogoutMethodEnum.md) | Backchannel logs out with server to server calls. Frontchannel uses iframes in your browser | [optional] +**sub_mode** | [**SubModeEnum**](SubModeEnum.md) | Configure what data should be used as unique User Identifier. For most cases, the default should be fine. | [optional] +**issuer_mode** | [**IssuerModeEnum**](IssuerModeEnum.md) | Configure how the issuer field of the ID Token should be filled. | [optional] +**jwt_federation_sources** | **List[UUID]** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_o_auth2_provider_request import PatchedOAuth2ProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedOAuth2ProviderRequest from a JSON string +patched_o_auth2_provider_request_instance = PatchedOAuth2ProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedOAuth2ProviderRequest.to_json()) + +# convert the object into a dict +patched_o_auth2_provider_request_dict = patched_o_auth2_provider_request_instance.to_dict() +# create an instance of PatchedOAuth2ProviderRequest from a dict +patched_o_auth2_provider_request_from_dict = PatchedOAuth2ProviderRequest.from_dict(patched_o_auth2_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedOAuthSourcePropertyMappingRequest.md b/docs/PatchedOAuthSourcePropertyMappingRequest.md new file mode 100644 index 000000000..629c1652b --- /dev/null +++ b/docs/PatchedOAuthSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedOAuthSourcePropertyMappingRequest + +OAuthSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_o_auth_source_property_mapping_request import PatchedOAuthSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedOAuthSourcePropertyMappingRequest from a JSON string +patched_o_auth_source_property_mapping_request_instance = PatchedOAuthSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedOAuthSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_o_auth_source_property_mapping_request_dict = patched_o_auth_source_property_mapping_request_instance.to_dict() +# create an instance of PatchedOAuthSourcePropertyMappingRequest from a dict +patched_o_auth_source_property_mapping_request_from_dict = PatchedOAuthSourcePropertyMappingRequest.from_dict(patched_o_auth_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedOAuthSourceRequest.md b/docs/PatchedOAuthSourceRequest.md new file mode 100644 index 000000000..ab0519bc0 --- /dev/null +++ b/docs/PatchedOAuthSourceRequest.md @@ -0,0 +1,55 @@ +# PatchedOAuthSourceRequest + +OAuth Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | [optional] +**slug** | **str** | Internal source name, used in URLs. | [optional] +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**provider_type** | [**ProviderTypeEnum**](ProviderTypeEnum.md) | | [optional] +**request_token_url** | **str** | URL used to request the initial token. This URL is only required for OAuth 1. | [optional] +**authorization_url** | **str** | URL the user is redirect to to conest the flow. | [optional] +**access_token_url** | **str** | URL used by authentik to retrieve tokens. | [optional] +**profile_url** | **str** | URL used by authentik to get user information. | [optional] +**pkce** | [**PKCEMethodEnum**](PKCEMethodEnum.md) | | [optional] +**consumer_key** | **str** | | [optional] +**consumer_secret** | **str** | | [optional] +**additional_scopes** | **str** | | [optional] +**oidc_well_known_url** | **str** | | [optional] +**oidc_jwks_url** | **str** | | [optional] +**oidc_jwks** | **Dict[str, object]** | | [optional] +**authorization_code_auth_method** | [**AuthorizationCodeAuthMethodEnum**](AuthorizationCodeAuthMethodEnum.md) | How to perform authentication during an authorization_code token request flow | [optional] + +## Example + +```python +from authentik_client.models.patched_o_auth_source_request import PatchedOAuthSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedOAuthSourceRequest from a JSON string +patched_o_auth_source_request_instance = PatchedOAuthSourceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedOAuthSourceRequest.to_json()) + +# convert the object into a dict +patched_o_auth_source_request_dict = patched_o_auth_source_request_instance.to_dict() +# create an instance of PatchedOAuthSourceRequest from a dict +patched_o_auth_source_request_from_dict = PatchedOAuthSourceRequest.from_dict(patched_o_auth_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedOutpostRequest.md b/docs/PatchedOutpostRequest.md new file mode 100644 index 000000000..de7c032b4 --- /dev/null +++ b/docs/PatchedOutpostRequest.md @@ -0,0 +1,35 @@ +# PatchedOutpostRequest + +Outpost Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**type** | [**OutpostTypeEnum**](OutpostTypeEnum.md) | | [optional] +**providers** | **List[int]** | | [optional] +**service_connection** | **UUID** | Select Service-Connection authentik should use to manage this outpost. Leave empty if authentik should not handle the deployment. | [optional] +**config** | **Dict[str, object]** | | [optional] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] + +## Example + +```python +from authentik_client.models.patched_outpost_request import PatchedOutpostRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedOutpostRequest from a JSON string +patched_outpost_request_instance = PatchedOutpostRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedOutpostRequest.to_json()) + +# convert the object into a dict +patched_outpost_request_dict = patched_outpost_request_instance.to_dict() +# create an instance of PatchedOutpostRequest from a dict +patched_outpost_request_from_dict = PatchedOutpostRequest.from_dict(patched_outpost_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedPasswordExpiryPolicyRequest.md b/docs/PatchedPasswordExpiryPolicyRequest.md new file mode 100644 index 000000000..eec4674b1 --- /dev/null +++ b/docs/PatchedPasswordExpiryPolicyRequest.md @@ -0,0 +1,33 @@ +# PatchedPasswordExpiryPolicyRequest + +Password Expiry Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**days** | **int** | | [optional] +**deny_only** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_password_expiry_policy_request import PatchedPasswordExpiryPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedPasswordExpiryPolicyRequest from a JSON string +patched_password_expiry_policy_request_instance = PatchedPasswordExpiryPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedPasswordExpiryPolicyRequest.to_json()) + +# convert the object into a dict +patched_password_expiry_policy_request_dict = patched_password_expiry_policy_request_instance.to_dict() +# create an instance of PatchedPasswordExpiryPolicyRequest from a dict +patched_password_expiry_policy_request_from_dict = PatchedPasswordExpiryPolicyRequest.from_dict(patched_password_expiry_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedPasswordPolicyRequest.md b/docs/PatchedPasswordPolicyRequest.md new file mode 100644 index 000000000..ff5c9551d --- /dev/null +++ b/docs/PatchedPasswordPolicyRequest.md @@ -0,0 +1,44 @@ +# PatchedPasswordPolicyRequest + +Password Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**password_field** | **str** | Field key to check, field keys defined in Prompt stages are available. | [optional] +**amount_digits** | **int** | | [optional] +**amount_uppercase** | **int** | | [optional] +**amount_lowercase** | **int** | | [optional] +**amount_symbols** | **int** | | [optional] +**length_min** | **int** | | [optional] +**symbol_charset** | **str** | | [optional] +**error_message** | **str** | | [optional] +**check_static_rules** | **bool** | | [optional] +**check_have_i_been_pwned** | **bool** | | [optional] +**check_zxcvbn** | **bool** | | [optional] +**hibp_allowed_count** | **int** | How many times the password hash is allowed to be on haveibeenpwned | [optional] +**zxcvbn_score_threshold** | **int** | If the zxcvbn score is equal or less than this value, the policy will fail. | [optional] + +## Example + +```python +from authentik_client.models.patched_password_policy_request import PatchedPasswordPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedPasswordPolicyRequest from a JSON string +patched_password_policy_request_instance = PatchedPasswordPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedPasswordPolicyRequest.to_json()) + +# convert the object into a dict +patched_password_policy_request_dict = patched_password_policy_request_instance.to_dict() +# create an instance of PatchedPasswordPolicyRequest from a dict +patched_password_policy_request_from_dict = PatchedPasswordPolicyRequest.from_dict(patched_password_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedPasswordStageRequest.md b/docs/PatchedPasswordStageRequest.md new file mode 100644 index 000000000..5b1cf0208 --- /dev/null +++ b/docs/PatchedPasswordStageRequest.md @@ -0,0 +1,34 @@ +# PatchedPasswordStageRequest + +PasswordStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**backends** | [**List[BackendsEnum]**](BackendsEnum.md) | Selection of backends to test the password against. | [optional] +**configure_flow** | **UUID** | Flow used by an authenticated user to configure this Stage. If empty, user will not be able to configure this stage. | [optional] +**failed_attempts_before_cancel** | **int** | How many attempts a user has before the flow is canceled. To lock the user out, use a reputation policy and a user_write stage. | [optional] +**allow_show_password** | **bool** | When enabled, provides a 'show password' button with the password input field. | [optional] + +## Example + +```python +from authentik_client.models.patched_password_stage_request import PatchedPasswordStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedPasswordStageRequest from a JSON string +patched_password_stage_request_instance = PatchedPasswordStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedPasswordStageRequest.to_json()) + +# convert the object into a dict +patched_password_stage_request_dict = patched_password_stage_request_instance.to_dict() +# create an instance of PatchedPasswordStageRequest from a dict +patched_password_stage_request_from_dict = PatchedPasswordStageRequest.from_dict(patched_password_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedPermissionAssignRequest.md b/docs/PatchedPermissionAssignRequest.md new file mode 100644 index 000000000..b0dbf0d18 --- /dev/null +++ b/docs/PatchedPermissionAssignRequest.md @@ -0,0 +1,32 @@ +# PatchedPermissionAssignRequest + +Request to assign a new permission + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**permissions** | **List[str]** | | [optional] +**model** | [**ModelEnum**](ModelEnum.md) | | [optional] +**object_pk** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_permission_assign_request import PatchedPermissionAssignRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedPermissionAssignRequest from a JSON string +patched_permission_assign_request_instance = PatchedPermissionAssignRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedPermissionAssignRequest.to_json()) + +# convert the object into a dict +patched_permission_assign_request_dict = patched_permission_assign_request_instance.to_dict() +# create an instance of PatchedPermissionAssignRequest from a dict +patched_permission_assign_request_from_dict = PatchedPermissionAssignRequest.from_dict(patched_permission_assign_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedPlexSourcePropertyMappingRequest.md b/docs/PatchedPlexSourcePropertyMappingRequest.md new file mode 100644 index 000000000..8497b347f --- /dev/null +++ b/docs/PatchedPlexSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedPlexSourcePropertyMappingRequest + +PlexSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_plex_source_property_mapping_request import PatchedPlexSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedPlexSourcePropertyMappingRequest from a JSON string +patched_plex_source_property_mapping_request_instance = PatchedPlexSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedPlexSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_plex_source_property_mapping_request_dict = patched_plex_source_property_mapping_request_instance.to_dict() +# create an instance of PatchedPlexSourcePropertyMappingRequest from a dict +patched_plex_source_property_mapping_request_from_dict = PatchedPlexSourcePropertyMappingRequest.from_dict(patched_plex_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedPlexSourceRequest.md b/docs/PatchedPlexSourceRequest.md new file mode 100644 index 000000000..09b3a3ce5 --- /dev/null +++ b/docs/PatchedPlexSourceRequest.md @@ -0,0 +1,46 @@ +# PatchedPlexSourceRequest + +Plex Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | [optional] +**slug** | **str** | Internal source name, used in URLs. | [optional] +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**client_id** | **str** | Client identifier used to talk to Plex. | [optional] +**allowed_servers** | **List[str]** | Which servers a user has to be a member of to be granted access. Empty list allows every server. | [optional] +**allow_friends** | **bool** | Allow friends to authenticate, even if you don't share a server. | [optional] +**plex_token** | **str** | Plex token used to check friends | [optional] + +## Example + +```python +from authentik_client.models.patched_plex_source_request import PatchedPlexSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedPlexSourceRequest from a JSON string +patched_plex_source_request_instance = PatchedPlexSourceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedPlexSourceRequest.to_json()) + +# convert the object into a dict +patched_plex_source_request_dict = patched_plex_source_request_instance.to_dict() +# create an instance of PatchedPlexSourceRequest from a dict +patched_plex_source_request_from_dict = PatchedPlexSourceRequest.from_dict(patched_plex_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedPolicyBindingRequest.md b/docs/PatchedPolicyBindingRequest.md new file mode 100644 index 000000000..52b089ded --- /dev/null +++ b/docs/PatchedPolicyBindingRequest.md @@ -0,0 +1,38 @@ +# PatchedPolicyBindingRequest + +PolicyBinding Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**policy** | **UUID** | | [optional] +**group** | **UUID** | | [optional] +**user** | **int** | | [optional] +**target** | **UUID** | | [optional] +**negate** | **bool** | Negates the outcome of the policy. Messages are unaffected. | [optional] +**enabled** | **bool** | | [optional] +**order** | **int** | | [optional] +**timeout** | **int** | Timeout after which Policy execution is terminated. | [optional] +**failure_result** | **bool** | Result if the Policy execution fails. | [optional] + +## Example + +```python +from authentik_client.models.patched_policy_binding_request import PatchedPolicyBindingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedPolicyBindingRequest from a JSON string +patched_policy_binding_request_instance = PatchedPolicyBindingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedPolicyBindingRequest.to_json()) + +# convert the object into a dict +patched_policy_binding_request_dict = patched_policy_binding_request_instance.to_dict() +# create an instance of PatchedPolicyBindingRequest from a dict +patched_policy_binding_request_from_dict = PatchedPolicyBindingRequest.from_dict(patched_policy_binding_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedPromptRequest.md b/docs/PatchedPromptRequest.md new file mode 100644 index 000000000..98145b1f0 --- /dev/null +++ b/docs/PatchedPromptRequest.md @@ -0,0 +1,40 @@ +# PatchedPromptRequest + +Prompt Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**field_key** | **str** | Name of the form field, also used to store the value | [optional] +**label** | **str** | | [optional] +**type** | [**PromptTypeEnum**](PromptTypeEnum.md) | | [optional] +**required** | **bool** | | [optional] +**placeholder** | **str** | Optionally provide a short hint that describes the expected input value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple choices. | [optional] +**initial_value** | **str** | Optionally pre-fill the input with an initial value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple default choices. | [optional] +**order** | **int** | | [optional] +**sub_text** | **str** | | [optional] +**placeholder_expression** | **bool** | | [optional] +**initial_value_expression** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_prompt_request import PatchedPromptRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedPromptRequest from a JSON string +patched_prompt_request_instance = PatchedPromptRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedPromptRequest.to_json()) + +# convert the object into a dict +patched_prompt_request_dict = patched_prompt_request_instance.to_dict() +# create an instance of PatchedPromptRequest from a dict +patched_prompt_request_from_dict = PatchedPromptRequest.from_dict(patched_prompt_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedPromptStageRequest.md b/docs/PatchedPromptStageRequest.md new file mode 100644 index 000000000..f98bb9d37 --- /dev/null +++ b/docs/PatchedPromptStageRequest.md @@ -0,0 +1,32 @@ +# PatchedPromptStageRequest + +PromptStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**fields** | **List[UUID]** | | [optional] +**validation_policies** | **List[UUID]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_prompt_stage_request import PatchedPromptStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedPromptStageRequest from a JSON string +patched_prompt_stage_request_instance = PatchedPromptStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedPromptStageRequest.to_json()) + +# convert the object into a dict +patched_prompt_stage_request_dict = patched_prompt_stage_request_instance.to_dict() +# create an instance of PatchedPromptStageRequest from a dict +patched_prompt_stage_request_from_dict = PatchedPromptStageRequest.from_dict(patched_prompt_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedProxyProviderRequest.md b/docs/PatchedProxyProviderRequest.md new file mode 100644 index 000000000..ddb6d408d --- /dev/null +++ b/docs/PatchedProxyProviderRequest.md @@ -0,0 +1,49 @@ +# PatchedProxyProviderRequest + +ProxyProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | [optional] +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**internal_host** | **str** | | [optional] +**external_host** | **str** | | [optional] +**internal_host_ssl_validation** | **bool** | Validate SSL Certificates of upstream servers | [optional] +**certificate** | **UUID** | | [optional] +**skip_path_regex** | **str** | Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression. | [optional] +**basic_auth_enabled** | **bool** | Set a custom HTTP-Basic Authentication header based on values from authentik. | [optional] +**basic_auth_password_attribute** | **str** | User/Group Attribute used for the password part of the HTTP-Basic Header. | [optional] +**basic_auth_user_attribute** | **str** | User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used. | [optional] +**mode** | [**ProxyMode**](ProxyMode.md) | Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host. | [optional] +**intercept_header_auth** | **bool** | When enabled, this provider will intercept the authorization header and authenticate requests based on its value. | [optional] +**cookie_domain** | **str** | | [optional] +**jwt_federation_sources** | **List[UUID]** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] +**access_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] + +## Example + +```python +from authentik_client.models.patched_proxy_provider_request import PatchedProxyProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedProxyProviderRequest from a JSON string +patched_proxy_provider_request_instance = PatchedProxyProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedProxyProviderRequest.to_json()) + +# convert the object into a dict +patched_proxy_provider_request_dict = patched_proxy_provider_request_instance.to_dict() +# create an instance of PatchedProxyProviderRequest from a dict +patched_proxy_provider_request_from_dict = PatchedProxyProviderRequest.from_dict(patched_proxy_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedRACPropertyMappingRequest.md b/docs/PatchedRACPropertyMappingRequest.md new file mode 100644 index 000000000..522ed2dc8 --- /dev/null +++ b/docs/PatchedRACPropertyMappingRequest.md @@ -0,0 +1,33 @@ +# PatchedRACPropertyMappingRequest + +RACPropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] +**static_settings** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_rac_property_mapping_request import PatchedRACPropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedRACPropertyMappingRequest from a JSON string +patched_rac_property_mapping_request_instance = PatchedRACPropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedRACPropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_rac_property_mapping_request_dict = patched_rac_property_mapping_request_instance.to_dict() +# create an instance of PatchedRACPropertyMappingRequest from a dict +patched_rac_property_mapping_request_from_dict = PatchedRACPropertyMappingRequest.from_dict(patched_rac_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedRACProviderRequest.md b/docs/PatchedRACProviderRequest.md new file mode 100644 index 000000000..7a634260b --- /dev/null +++ b/docs/PatchedRACProviderRequest.md @@ -0,0 +1,36 @@ +# PatchedRACProviderRequest + +RACProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**settings** | **Dict[str, object]** | | [optional] +**connection_expiry** | **str** | Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**delete_token_on_disconnect** | **bool** | When set to true, connection tokens will be deleted upon disconnect. | [optional] + +## Example + +```python +from authentik_client.models.patched_rac_provider_request import PatchedRACProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedRACProviderRequest from a JSON string +patched_rac_provider_request_instance = PatchedRACProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedRACProviderRequest.to_json()) + +# convert the object into a dict +patched_rac_provider_request_dict = patched_rac_provider_request_instance.to_dict() +# create an instance of PatchedRACProviderRequest from a dict +patched_rac_provider_request_from_dict = PatchedRACProviderRequest.from_dict(patched_rac_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedRadiusProviderPropertyMappingRequest.md b/docs/PatchedRadiusProviderPropertyMappingRequest.md new file mode 100644 index 000000000..7efb3d0ad --- /dev/null +++ b/docs/PatchedRadiusProviderPropertyMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedRadiusProviderPropertyMappingRequest + +RadiusProviderPropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_radius_provider_property_mapping_request import PatchedRadiusProviderPropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedRadiusProviderPropertyMappingRequest from a JSON string +patched_radius_provider_property_mapping_request_instance = PatchedRadiusProviderPropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedRadiusProviderPropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_radius_provider_property_mapping_request_dict = patched_radius_provider_property_mapping_request_instance.to_dict() +# create an instance of PatchedRadiusProviderPropertyMappingRequest from a dict +patched_radius_provider_property_mapping_request_from_dict = PatchedRadiusProviderPropertyMappingRequest.from_dict(patched_radius_provider_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedRadiusProviderRequest.md b/docs/PatchedRadiusProviderRequest.md new file mode 100644 index 000000000..e4965ff0c --- /dev/null +++ b/docs/PatchedRadiusProviderRequest.md @@ -0,0 +1,38 @@ +# PatchedRadiusProviderRequest + +RadiusProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | [optional] +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**client_networks** | **str** | List of CIDRs (comma-separated) that clients can connect from. A more specific CIDR will match before a looser one. Clients connecting from a non-specified CIDR will be dropped. | [optional] +**shared_secret** | **str** | Shared secret between clients and server to hash packets. | [optional] +**mfa_support** | **bool** | When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon. | [optional] +**certificate** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.patched_radius_provider_request import PatchedRadiusProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedRadiusProviderRequest from a JSON string +patched_radius_provider_request_instance = PatchedRadiusProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedRadiusProviderRequest.to_json()) + +# convert the object into a dict +patched_radius_provider_request_dict = patched_radius_provider_request_instance.to_dict() +# create an instance of PatchedRadiusProviderRequest from a dict +patched_radius_provider_request_from_dict = PatchedRadiusProviderRequest.from_dict(patched_radius_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedRedirectStageRequest.md b/docs/PatchedRedirectStageRequest.md new file mode 100644 index 000000000..a8cf66e8d --- /dev/null +++ b/docs/PatchedRedirectStageRequest.md @@ -0,0 +1,34 @@ +# PatchedRedirectStageRequest + +RedirectStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**keep_context** | **bool** | | [optional] +**mode** | [**RedirectStageModeEnum**](RedirectStageModeEnum.md) | | [optional] +**target_static** | **str** | | [optional] +**target_flow** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.patched_redirect_stage_request import PatchedRedirectStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedRedirectStageRequest from a JSON string +patched_redirect_stage_request_instance = PatchedRedirectStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedRedirectStageRequest.to_json()) + +# convert the object into a dict +patched_redirect_stage_request_dict = patched_redirect_stage_request_instance.to_dict() +# create an instance of PatchedRedirectStageRequest from a dict +patched_redirect_stage_request_from_dict = PatchedRedirectStageRequest.from_dict(patched_redirect_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedReputationPolicyRequest.md b/docs/PatchedReputationPolicyRequest.md new file mode 100644 index 000000000..9cf099b00 --- /dev/null +++ b/docs/PatchedReputationPolicyRequest.md @@ -0,0 +1,34 @@ +# PatchedReputationPolicyRequest + +Reputation Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**check_ip** | **bool** | | [optional] +**check_username** | **bool** | | [optional] +**threshold** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.patched_reputation_policy_request import PatchedReputationPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedReputationPolicyRequest from a JSON string +patched_reputation_policy_request_instance = PatchedReputationPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedReputationPolicyRequest.to_json()) + +# convert the object into a dict +patched_reputation_policy_request_dict = patched_reputation_policy_request_instance.to_dict() +# create an instance of PatchedReputationPolicyRequest from a dict +patched_reputation_policy_request_from_dict = PatchedReputationPolicyRequest.from_dict(patched_reputation_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedRoleRequest.md b/docs/PatchedRoleRequest.md new file mode 100644 index 000000000..b6623bac2 --- /dev/null +++ b/docs/PatchedRoleRequest.md @@ -0,0 +1,30 @@ +# PatchedRoleRequest + +Role serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_role_request import PatchedRoleRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedRoleRequest from a JSON string +patched_role_request_instance = PatchedRoleRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedRoleRequest.to_json()) + +# convert the object into a dict +patched_role_request_dict = patched_role_request_instance.to_dict() +# create an instance of PatchedRoleRequest from a dict +patched_role_request_from_dict = PatchedRoleRequest.from_dict(patched_role_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSAMLPropertyMappingRequest.md b/docs/PatchedSAMLPropertyMappingRequest.md new file mode 100644 index 000000000..f06e92df2 --- /dev/null +++ b/docs/PatchedSAMLPropertyMappingRequest.md @@ -0,0 +1,34 @@ +# PatchedSAMLPropertyMappingRequest + +SAMLPropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] +**saml_name** | **str** | | [optional] +**friendly_name** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_saml_property_mapping_request import PatchedSAMLPropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSAMLPropertyMappingRequest from a JSON string +patched_saml_property_mapping_request_instance = PatchedSAMLPropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSAMLPropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_saml_property_mapping_request_dict = patched_saml_property_mapping_request_instance.to_dict() +# create an instance of PatchedSAMLPropertyMappingRequest from a dict +patched_saml_property_mapping_request_from_dict = PatchedSAMLPropertyMappingRequest.from_dict(patched_saml_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSAMLProviderRequest.md b/docs/PatchedSAMLProviderRequest.md new file mode 100644 index 000000000..7deace92a --- /dev/null +++ b/docs/PatchedSAMLProviderRequest.md @@ -0,0 +1,57 @@ +# PatchedSAMLProviderRequest + +SAMLProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | [optional] +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**acs_url** | **str** | | [optional] +**sls_url** | **str** | Single Logout Service URL where the logout response should be sent. | [optional] +**audience** | **str** | Value of the audience restriction field of the assertion. When left empty, no audience restriction will be added. | [optional] +**issuer_override** | **str** | Also known as EntityID. Providing a value overrides the default issuer generated by authentik. | [optional] +**assertion_valid_not_before** | **str** | Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3). | [optional] +**assertion_valid_not_on_or_after** | **str** | Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**session_valid_not_on_or_after** | **str** | Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**name_id_mapping** | **UUID** | Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered | [optional] +**authn_context_class_ref_mapping** | **UUID** | Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Service Provider. | [optional] +**verification_kp** | **UUID** | When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default. | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**sign_assertion** | **bool** | | [optional] +**sign_response** | **bool** | | [optional] +**sign_logout_request** | **bool** | | [optional] +**sign_logout_response** | **bool** | | [optional] +**sp_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | This determines how authentik sends the response back to the Service Provider. | [optional] +**sls_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | This determines how authentik sends the logout response back to the Service Provider. | [optional] +**logout_method** | [**SAMLLogoutMethods**](SAMLLogoutMethods.md) | Method to use for logout. Front-channel iframe loads all logout URLs simultaneously in hidden iframes. Front-channel native uses your active browser tab to send post requests and redirect to providers. Back-channel sends logout requests directly from the server without user interaction (requires POST SLS binding). | [optional] +**default_relay_state** | **str** | Default relay_state value for IDP-initiated logins | [optional] +**default_name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.patched_saml_provider_request import PatchedSAMLProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSAMLProviderRequest from a JSON string +patched_saml_provider_request_instance = PatchedSAMLProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSAMLProviderRequest.to_json()) + +# convert the object into a dict +patched_saml_provider_request_dict = patched_saml_provider_request_instance.to_dict() +# create an instance of PatchedSAMLProviderRequest from a dict +patched_saml_provider_request_from_dict = PatchedSAMLProviderRequest.from_dict(patched_saml_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSAMLSourcePropertyMappingRequest.md b/docs/PatchedSAMLSourcePropertyMappingRequest.md new file mode 100644 index 000000000..011888c44 --- /dev/null +++ b/docs/PatchedSAMLSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedSAMLSourcePropertyMappingRequest + +SAMLSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_saml_source_property_mapping_request import PatchedSAMLSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSAMLSourcePropertyMappingRequest from a JSON string +patched_saml_source_property_mapping_request_instance = PatchedSAMLSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSAMLSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_saml_source_property_mapping_request_dict = patched_saml_source_property_mapping_request_instance.to_dict() +# create an instance of PatchedSAMLSourcePropertyMappingRequest from a dict +patched_saml_source_property_mapping_request_from_dict = PatchedSAMLSourcePropertyMappingRequest.from_dict(patched_saml_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSAMLSourceRequest.md b/docs/PatchedSAMLSourceRequest.md new file mode 100644 index 000000000..0d9ba3cd6 --- /dev/null +++ b/docs/PatchedSAMLSourceRequest.md @@ -0,0 +1,58 @@ +# PatchedSAMLSourceRequest + +SAMLSource Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | [optional] +**slug** | **str** | Internal source name, used in URLs. | [optional] +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**pre_authentication_flow** | **UUID** | Flow used before authentication. | [optional] +**issuer** | **str** | Also known as Entity ID. Defaults the Metadata URL. | [optional] +**sso_url** | **str** | URL that the initial Login request is sent to. | [optional] +**slo_url** | **str** | Optional URL if your IDP supports Single-Logout. | [optional] +**allow_idp_initiated** | **bool** | Allows authentication flows initiated by the IdP. This can be a security risk, as no validation of the request ID is done. | [optional] +**force_authn** | **bool** | When enabled, the IdP will re-authenticate the user even if a session exists. | [optional] +**name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | NameID Policy sent to the IdP. Can be unset, in which case no Policy is sent. | [optional] +**binding_type** | [**BindingTypeEnum**](BindingTypeEnum.md) | | [optional] +**verification_kp** | **UUID** | When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default. | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Identity Provider. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**temporary_user_delete_after** | **str** | Time offset when temporary users should be deleted. This only applies if your IDP uses the NameID Format 'transient', and the user doesn't log out manually. (Format: hours=1;minutes=2;seconds=3). | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**signed_assertion** | **bool** | | [optional] +**signed_response** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_saml_source_request import PatchedSAMLSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSAMLSourceRequest from a JSON string +patched_saml_source_request_instance = PatchedSAMLSourceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSAMLSourceRequest.to_json()) + +# convert the object into a dict +patched_saml_source_request_dict = patched_saml_source_request_instance.to_dict() +# create an instance of PatchedSAMLSourceRequest from a dict +patched_saml_source_request_from_dict = PatchedSAMLSourceRequest.from_dict(patched_saml_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSCIMMappingRequest.md b/docs/PatchedSCIMMappingRequest.md new file mode 100644 index 000000000..a7185072b --- /dev/null +++ b/docs/PatchedSCIMMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedSCIMMappingRequest + +SCIMMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_scim_mapping_request import PatchedSCIMMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSCIMMappingRequest from a JSON string +patched_scim_mapping_request_instance = PatchedSCIMMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSCIMMappingRequest.to_json()) + +# convert the object into a dict +patched_scim_mapping_request_dict = patched_scim_mapping_request_instance.to_dict() +# create an instance of PatchedSCIMMappingRequest from a dict +patched_scim_mapping_request_from_dict = PatchedSCIMMappingRequest.from_dict(patched_scim_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSCIMProviderRequest.md b/docs/PatchedSCIMProviderRequest.md new file mode 100644 index 000000000..0b8f86492 --- /dev/null +++ b/docs/PatchedSCIMProviderRequest.md @@ -0,0 +1,45 @@ +# PatchedSCIMProviderRequest + +SCIMProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**url** | **str** | Base URL to SCIM requests, usually ends in /v2 | [optional] +**verify_certificates** | **bool** | | [optional] +**token** | **str** | Authentication token | [optional] +**auth_mode** | [**SCIMAuthenticationModeEnum**](SCIMAuthenticationModeEnum.md) | | [optional] +**auth_oauth** | **UUID** | OAuth Source used for authentication | [optional] +**auth_oauth_params** | **Dict[str, object]** | Additional OAuth parameters, such as grant_type | [optional] +**compatibility_mode** | [**CompatibilityModeEnum**](CompatibilityModeEnum.md) | Alter authentik behavior for vendor-specific SCIM implementations. | [optional] +**service_provider_config_cache_timeout** | **str** | Cache duration for ServiceProviderConfig responses. Set minutes=0 to disable. | [optional] +**exclude_users_service_account** | **bool** | | [optional] +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**group_filters** | **List[UUID]** | Group filters used to define sync-scope for groups. | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] + +## Example + +```python +from authentik_client.models.patched_scim_provider_request import PatchedSCIMProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSCIMProviderRequest from a JSON string +patched_scim_provider_request_instance = PatchedSCIMProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSCIMProviderRequest.to_json()) + +# convert the object into a dict +patched_scim_provider_request_dict = patched_scim_provider_request_instance.to_dict() +# create an instance of PatchedSCIMProviderRequest from a dict +patched_scim_provider_request_from_dict = PatchedSCIMProviderRequest.from_dict(patched_scim_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSCIMSourceGroupRequest.md b/docs/PatchedSCIMSourceGroupRequest.md new file mode 100644 index 000000000..56ff929c8 --- /dev/null +++ b/docs/PatchedSCIMSourceGroupRequest.md @@ -0,0 +1,34 @@ +# PatchedSCIMSourceGroupRequest + +SCIMSourceGroup Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | [optional] +**external_id** | **str** | | [optional] +**group** | **UUID** | | [optional] +**source** | **UUID** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_scim_source_group_request import PatchedSCIMSourceGroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSCIMSourceGroupRequest from a JSON string +patched_scim_source_group_request_instance = PatchedSCIMSourceGroupRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSCIMSourceGroupRequest.to_json()) + +# convert the object into a dict +patched_scim_source_group_request_dict = patched_scim_source_group_request_instance.to_dict() +# create an instance of PatchedSCIMSourceGroupRequest from a dict +patched_scim_source_group_request_from_dict = PatchedSCIMSourceGroupRequest.from_dict(patched_scim_source_group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSCIMSourcePropertyMappingRequest.md b/docs/PatchedSCIMSourcePropertyMappingRequest.md new file mode 100644 index 000000000..57ab8e3c6 --- /dev/null +++ b/docs/PatchedSCIMSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedSCIMSourcePropertyMappingRequest + +SCIMSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_scim_source_property_mapping_request import PatchedSCIMSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSCIMSourcePropertyMappingRequest from a JSON string +patched_scim_source_property_mapping_request_instance = PatchedSCIMSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSCIMSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_scim_source_property_mapping_request_dict = patched_scim_source_property_mapping_request_instance.to_dict() +# create an instance of PatchedSCIMSourcePropertyMappingRequest from a dict +patched_scim_source_property_mapping_request_from_dict = PatchedSCIMSourcePropertyMappingRequest.from_dict(patched_scim_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSCIMSourceRequest.md b/docs/PatchedSCIMSourceRequest.md new file mode 100644 index 000000000..f4a268999 --- /dev/null +++ b/docs/PatchedSCIMSourceRequest.md @@ -0,0 +1,35 @@ +# PatchedSCIMSourceRequest + +SCIMSource Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | [optional] +**slug** | **str** | Internal source name, used in URLs. | [optional] +**enabled** | **bool** | | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**user_path_template** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_scim_source_request import PatchedSCIMSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSCIMSourceRequest from a JSON string +patched_scim_source_request_instance = PatchedSCIMSourceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSCIMSourceRequest.to_json()) + +# convert the object into a dict +patched_scim_source_request_dict = patched_scim_source_request_instance.to_dict() +# create an instance of PatchedSCIMSourceRequest from a dict +patched_scim_source_request_from_dict = PatchedSCIMSourceRequest.from_dict(patched_scim_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSCIMSourceUserRequest.md b/docs/PatchedSCIMSourceUserRequest.md new file mode 100644 index 000000000..3f14676d4 --- /dev/null +++ b/docs/PatchedSCIMSourceUserRequest.md @@ -0,0 +1,34 @@ +# PatchedSCIMSourceUserRequest + +SCIMSourceUser Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | [optional] +**external_id** | **str** | | [optional] +**user** | **int** | | [optional] +**source** | **UUID** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.patched_scim_source_user_request import PatchedSCIMSourceUserRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSCIMSourceUserRequest from a JSON string +patched_scim_source_user_request_instance = PatchedSCIMSourceUserRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSCIMSourceUserRequest.to_json()) + +# convert the object into a dict +patched_scim_source_user_request_dict = patched_scim_source_user_request_instance.to_dict() +# create an instance of PatchedSCIMSourceUserRequest from a dict +patched_scim_source_user_request_from_dict = PatchedSCIMSourceUserRequest.from_dict(patched_scim_source_user_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSMSDeviceRequest.md b/docs/PatchedSMSDeviceRequest.md new file mode 100644 index 000000000..2401a194c --- /dev/null +++ b/docs/PatchedSMSDeviceRequest.md @@ -0,0 +1,30 @@ +# PatchedSMSDeviceRequest + +Serializer for sms authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | [optional] + +## Example + +```python +from authentik_client.models.patched_sms_device_request import PatchedSMSDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSMSDeviceRequest from a JSON string +patched_sms_device_request_instance = PatchedSMSDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSMSDeviceRequest.to_json()) + +# convert the object into a dict +patched_sms_device_request_dict = patched_sms_device_request_instance.to_dict() +# create an instance of PatchedSMSDeviceRequest from a dict +patched_sms_device_request_from_dict = PatchedSMSDeviceRequest.from_dict(patched_sms_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSSFProviderRequest.md b/docs/PatchedSSFProviderRequest.md new file mode 100644 index 000000000..0e5ba5e30 --- /dev/null +++ b/docs/PatchedSSFProviderRequest.md @@ -0,0 +1,34 @@ +# PatchedSSFProviderRequest + +SSFProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**signing_key** | **UUID** | Key used to sign the SSF Events. | [optional] +**oidc_auth_providers** | **List[int]** | | [optional] +**event_retention** | **str** | | [optional] +**push_verify_certificates** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_ssf_provider_request import PatchedSSFProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSSFProviderRequest from a JSON string +patched_ssf_provider_request_instance = PatchedSSFProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSSFProviderRequest.to_json()) + +# convert the object into a dict +patched_ssf_provider_request_dict = patched_ssf_provider_request_instance.to_dict() +# create an instance of PatchedSSFProviderRequest from a dict +patched_ssf_provider_request_from_dict = PatchedSSFProviderRequest.from_dict(patched_ssf_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedScheduleRequest.md b/docs/PatchedScheduleRequest.md new file mode 100644 index 000000000..1aa7451be --- /dev/null +++ b/docs/PatchedScheduleRequest.md @@ -0,0 +1,31 @@ +# PatchedScheduleRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**rel_obj_id** | **str** | | [optional] +**crontab** | **str** | When to schedule tasks | [optional] +**paused** | **bool** | Pause this schedule | [optional] + +## Example + +```python +from authentik_client.models.patched_schedule_request import PatchedScheduleRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedScheduleRequest from a JSON string +patched_schedule_request_instance = PatchedScheduleRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedScheduleRequest.to_json()) + +# convert the object into a dict +patched_schedule_request_dict = patched_schedule_request_instance.to_dict() +# create an instance of PatchedScheduleRequest from a dict +patched_schedule_request_from_dict = PatchedScheduleRequest.from_dict(patched_schedule_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedScopeMappingRequest.md b/docs/PatchedScopeMappingRequest.md new file mode 100644 index 000000000..f17280403 --- /dev/null +++ b/docs/PatchedScopeMappingRequest.md @@ -0,0 +1,34 @@ +# PatchedScopeMappingRequest + +ScopeMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] +**scope_name** | **str** | Scope name requested by the client | [optional] +**description** | **str** | Description shown to the user when consenting. If left empty, the user won't be informed. | [optional] + +## Example + +```python +from authentik_client.models.patched_scope_mapping_request import PatchedScopeMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedScopeMappingRequest from a JSON string +patched_scope_mapping_request_instance = PatchedScopeMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedScopeMappingRequest.to_json()) + +# convert the object into a dict +patched_scope_mapping_request_dict = patched_scope_mapping_request_instance.to_dict() +# create an instance of PatchedScopeMappingRequest from a dict +patched_scope_mapping_request_from_dict = PatchedScopeMappingRequest.from_dict(patched_scope_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSettingsRequest.md b/docs/PatchedSettingsRequest.md new file mode 100644 index 000000000..3ebe2db3d --- /dev/null +++ b/docs/PatchedSettingsRequest.md @@ -0,0 +1,45 @@ +# PatchedSettingsRequest + +Settings Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**avatars** | **str** | Configure how authentik should show avatars for users. | [optional] +**default_user_change_name** | **bool** | Enable the ability for users to change their name. | [optional] +**default_user_change_email** | **bool** | Enable the ability for users to change their email address. | [optional] +**default_user_change_username** | **bool** | Enable the ability for users to change their username. | [optional] +**event_retention** | **str** | Events will be deleted after this duration.(Format: weeks=3;days=2;hours=3,seconds=2). | [optional] +**reputation_lower_limit** | **int** | Reputation cannot decrease lower than this value. Zero or negative. | [optional] +**reputation_upper_limit** | **int** | Reputation cannot increase higher than this value. Zero or positive. | [optional] +**footer_links** | **object** | | [optional] +**gdpr_compliance** | **bool** | When enabled, all the events caused by a user will be deleted upon the user's deletion. | [optional] +**impersonation** | **bool** | Globally enable/disable impersonation. | [optional] +**impersonation_require_reason** | **bool** | Require administrators to provide a reason for impersonating a user. | [optional] +**default_token_duration** | **str** | Default token duration | [optional] +**default_token_length** | **int** | Default token length | [optional] +**pagination_default_page_size** | **int** | Default page size for API responses, if no size was requested. | [optional] +**pagination_max_page_size** | **int** | Maximum page size | [optional] +**flags** | [**PatchedSettingsRequestFlags**](PatchedSettingsRequestFlags.md) | | [optional] + +## Example + +```python +from authentik_client.models.patched_settings_request import PatchedSettingsRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSettingsRequest from a JSON string +patched_settings_request_instance = PatchedSettingsRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSettingsRequest.to_json()) + +# convert the object into a dict +patched_settings_request_dict = patched_settings_request_instance.to_dict() +# create an instance of PatchedSettingsRequest from a dict +patched_settings_request_from_dict = PatchedSettingsRequest.from_dict(patched_settings_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSettingsRequestFlags.md b/docs/PatchedSettingsRequestFlags.md new file mode 100644 index 000000000..9e6ba5e71 --- /dev/null +++ b/docs/PatchedSettingsRequestFlags.md @@ -0,0 +1,32 @@ +# PatchedSettingsRequestFlags + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**core_default_app_access** | **bool** | Configure if applications without any policy/group/user bindings should be accessible to any user. | +**enterprise_audit_include_expanded_diff** | **bool** | Include additional information in audit logs, may incur a performance penalty. | +**flows_continuous_login** | **bool** | Upon successful authentication, re-start authentication in other open tabs. | +**flows_refresh_others** | **bool** | Refresh other tabs after successful authentication. | + +## Example + +```python +from authentik_client.models.patched_settings_request_flags import PatchedSettingsRequestFlags + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSettingsRequestFlags from a JSON string +patched_settings_request_flags_instance = PatchedSettingsRequestFlags.from_json(json) +# print the JSON string representation of the object +print(PatchedSettingsRequestFlags.to_json()) + +# convert the object into a dict +patched_settings_request_flags_dict = patched_settings_request_flags_instance.to_dict() +# create an instance of PatchedSettingsRequestFlags from a dict +patched_settings_request_flags_from_dict = PatchedSettingsRequestFlags.from_dict(patched_settings_request_flags_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedSourceStageRequest.md b/docs/PatchedSourceStageRequest.md new file mode 100644 index 000000000..a6b6df57d --- /dev/null +++ b/docs/PatchedSourceStageRequest.md @@ -0,0 +1,32 @@ +# PatchedSourceStageRequest + +SourceStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**source** | **UUID** | | [optional] +**resume_timeout** | **str** | Amount of time a user can take to return from the source to continue the flow (Format: hours=-1;minutes=-2;seconds=-3) | [optional] + +## Example + +```python +from authentik_client.models.patched_source_stage_request import PatchedSourceStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedSourceStageRequest from a JSON string +patched_source_stage_request_instance = PatchedSourceStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedSourceStageRequest.to_json()) + +# convert the object into a dict +patched_source_stage_request_dict = patched_source_stage_request_instance.to_dict() +# create an instance of PatchedSourceStageRequest from a dict +patched_source_stage_request_from_dict = PatchedSourceStageRequest.from_dict(patched_source_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedStaticDeviceRequest.md b/docs/PatchedStaticDeviceRequest.md new file mode 100644 index 000000000..877d2bae4 --- /dev/null +++ b/docs/PatchedStaticDeviceRequest.md @@ -0,0 +1,30 @@ +# PatchedStaticDeviceRequest + +Serializer for static authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | [optional] + +## Example + +```python +from authentik_client.models.patched_static_device_request import PatchedStaticDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedStaticDeviceRequest from a JSON string +patched_static_device_request_instance = PatchedStaticDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedStaticDeviceRequest.to_json()) + +# convert the object into a dict +patched_static_device_request_dict = patched_static_device_request_instance.to_dict() +# create an instance of PatchedStaticDeviceRequest from a dict +patched_static_device_request_from_dict = PatchedStaticDeviceRequest.from_dict(patched_static_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedTOTPDeviceRequest.md b/docs/PatchedTOTPDeviceRequest.md new file mode 100644 index 000000000..ab15c1931 --- /dev/null +++ b/docs/PatchedTOTPDeviceRequest.md @@ -0,0 +1,30 @@ +# PatchedTOTPDeviceRequest + +Serializer for totp authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | [optional] + +## Example + +```python +from authentik_client.models.patched_totp_device_request import PatchedTOTPDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedTOTPDeviceRequest from a JSON string +patched_totp_device_request_instance = PatchedTOTPDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedTOTPDeviceRequest.to_json()) + +# convert the object into a dict +patched_totp_device_request_dict = patched_totp_device_request_instance.to_dict() +# create an instance of PatchedTOTPDeviceRequest from a dict +patched_totp_device_request_from_dict = PatchedTOTPDeviceRequest.from_dict(patched_totp_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedTelegramSourcePropertyMappingRequest.md b/docs/PatchedTelegramSourcePropertyMappingRequest.md new file mode 100644 index 000000000..7ebaed986 --- /dev/null +++ b/docs/PatchedTelegramSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# PatchedTelegramSourcePropertyMappingRequest + +TelegramSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | [optional] +**expression** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_telegram_source_property_mapping_request import PatchedTelegramSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedTelegramSourcePropertyMappingRequest from a JSON string +patched_telegram_source_property_mapping_request_instance = PatchedTelegramSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedTelegramSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +patched_telegram_source_property_mapping_request_dict = patched_telegram_source_property_mapping_request_instance.to_dict() +# create an instance of PatchedTelegramSourcePropertyMappingRequest from a dict +patched_telegram_source_property_mapping_request_from_dict = PatchedTelegramSourcePropertyMappingRequest.from_dict(patched_telegram_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedTelegramSourceRequest.md b/docs/PatchedTelegramSourceRequest.md new file mode 100644 index 000000000..eeb6c063e --- /dev/null +++ b/docs/PatchedTelegramSourceRequest.md @@ -0,0 +1,45 @@ +# PatchedTelegramSourceRequest + +Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | [optional] +**slug** | **str** | Internal source name, used in URLs. | [optional] +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**bot_username** | **str** | Telegram bot username | [optional] +**bot_token** | **str** | Telegram bot token | [optional] +**request_message_access** | **bool** | Request access to send messages from your bot. | [optional] +**pre_authentication_flow** | **UUID** | Flow used before authentication. | [optional] + +## Example + +```python +from authentik_client.models.patched_telegram_source_request import PatchedTelegramSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedTelegramSourceRequest from a JSON string +patched_telegram_source_request_instance = PatchedTelegramSourceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedTelegramSourceRequest.to_json()) + +# convert the object into a dict +patched_telegram_source_request_dict = patched_telegram_source_request_instance.to_dict() +# create an instance of PatchedTelegramSourceRequest from a dict +patched_telegram_source_request_from_dict = PatchedTelegramSourceRequest.from_dict(patched_telegram_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedTenantRequest.md b/docs/PatchedTenantRequest.md new file mode 100644 index 000000000..60311ccac --- /dev/null +++ b/docs/PatchedTenantRequest.md @@ -0,0 +1,32 @@ +# PatchedTenantRequest + +Tenant Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**schema_name** | **str** | | [optional] +**name** | **str** | | [optional] +**ready** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_tenant_request import PatchedTenantRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedTenantRequest from a JSON string +patched_tenant_request_instance = PatchedTenantRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedTenantRequest.to_json()) + +# convert the object into a dict +patched_tenant_request_dict = patched_tenant_request_instance.to_dict() +# create an instance of PatchedTenantRequest from a dict +patched_tenant_request_from_dict = PatchedTenantRequest.from_dict(patched_tenant_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedTokenRequest.md b/docs/PatchedTokenRequest.md new file mode 100644 index 000000000..358d31dc1 --- /dev/null +++ b/docs/PatchedTokenRequest.md @@ -0,0 +1,36 @@ +# PatchedTokenRequest + +Token Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**identifier** | **str** | | [optional] +**intent** | [**IntentEnum**](IntentEnum.md) | | [optional] +**user** | **int** | | [optional] +**description** | **str** | | [optional] +**expires** | **datetime** | | [optional] +**expiring** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.patched_token_request import PatchedTokenRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedTokenRequest from a JSON string +patched_token_request_instance = PatchedTokenRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedTokenRequest.to_json()) + +# convert the object into a dict +patched_token_request_dict = patched_token_request_instance.to_dict() +# create an instance of PatchedTokenRequest from a dict +patched_token_request_from_dict = PatchedTokenRequest.from_dict(patched_token_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUniquePasswordPolicyRequest.md b/docs/PatchedUniquePasswordPolicyRequest.md new file mode 100644 index 000000000..b54452db9 --- /dev/null +++ b/docs/PatchedUniquePasswordPolicyRequest.md @@ -0,0 +1,33 @@ +# PatchedUniquePasswordPolicyRequest + +Password Uniqueness Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**password_field** | **str** | Field key to check, field keys defined in Prompt stages are available. | [optional] +**num_historical_passwords** | **int** | Number of passwords to check against. | [optional] + +## Example + +```python +from authentik_client.models.patched_unique_password_policy_request import PatchedUniquePasswordPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUniquePasswordPolicyRequest from a JSON string +patched_unique_password_policy_request_instance = PatchedUniquePasswordPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUniquePasswordPolicyRequest.to_json()) + +# convert the object into a dict +patched_unique_password_policy_request_dict = patched_unique_password_policy_request_instance.to_dict() +# create an instance of PatchedUniquePasswordPolicyRequest from a dict +patched_unique_password_policy_request_from_dict = PatchedUniquePasswordPolicyRequest.from_dict(patched_unique_password_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserDeleteStageRequest.md b/docs/PatchedUserDeleteStageRequest.md new file mode 100644 index 000000000..1bc059105 --- /dev/null +++ b/docs/PatchedUserDeleteStageRequest.md @@ -0,0 +1,30 @@ +# PatchedUserDeleteStageRequest + +UserDeleteStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_delete_stage_request import PatchedUserDeleteStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserDeleteStageRequest from a JSON string +patched_user_delete_stage_request_instance = PatchedUserDeleteStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserDeleteStageRequest.to_json()) + +# convert the object into a dict +patched_user_delete_stage_request_dict = patched_user_delete_stage_request_instance.to_dict() +# create an instance of PatchedUserDeleteStageRequest from a dict +patched_user_delete_stage_request_from_dict = PatchedUserDeleteStageRequest.from_dict(patched_user_delete_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserKerberosSourceConnectionRequest.md b/docs/PatchedUserKerberosSourceConnectionRequest.md new file mode 100644 index 000000000..e0ae7168a --- /dev/null +++ b/docs/PatchedUserKerberosSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedUserKerberosSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_kerberos_source_connection_request import PatchedUserKerberosSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserKerberosSourceConnectionRequest from a JSON string +patched_user_kerberos_source_connection_request_instance = PatchedUserKerberosSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserKerberosSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_user_kerberos_source_connection_request_dict = patched_user_kerberos_source_connection_request_instance.to_dict() +# create an instance of PatchedUserKerberosSourceConnectionRequest from a dict +patched_user_kerberos_source_connection_request_from_dict = PatchedUserKerberosSourceConnectionRequest.from_dict(patched_user_kerberos_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserLDAPSourceConnectionRequest.md b/docs/PatchedUserLDAPSourceConnectionRequest.md new file mode 100644 index 000000000..5010e754e --- /dev/null +++ b/docs/PatchedUserLDAPSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedUserLDAPSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_ldap_source_connection_request import PatchedUserLDAPSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserLDAPSourceConnectionRequest from a JSON string +patched_user_ldap_source_connection_request_instance = PatchedUserLDAPSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserLDAPSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_user_ldap_source_connection_request_dict = patched_user_ldap_source_connection_request_instance.to_dict() +# create an instance of PatchedUserLDAPSourceConnectionRequest from a dict +patched_user_ldap_source_connection_request_from_dict = PatchedUserLDAPSourceConnectionRequest.from_dict(patched_user_ldap_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserLoginStageRequest.md b/docs/PatchedUserLoginStageRequest.md new file mode 100644 index 000000000..ce8f37f2a --- /dev/null +++ b/docs/PatchedUserLoginStageRequest.md @@ -0,0 +1,36 @@ +# PatchedUserLoginStageRequest + +UserLoginStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**session_duration** | **str** | Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**terminate_other_sessions** | **bool** | Terminate all other sessions of the user logging in. | [optional] +**remember_me_offset** | **str** | Offset the session will be extended by when the user picks the remember me option. Default of 0 means that the remember me option will not be shown. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**network_binding** | [**NetworkBindingEnum**](NetworkBindingEnum.md) | Bind sessions created by this stage to the configured network | [optional] +**geoip_binding** | [**GeoipBindingEnum**](GeoipBindingEnum.md) | Bind sessions created by this stage to the configured GeoIP location | [optional] +**remember_device** | **str** | When set to a non-zero value, authentik will save a cookie with a longer expiry,to remember the device the user is logging in from. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] + +## Example + +```python +from authentik_client.models.patched_user_login_stage_request import PatchedUserLoginStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserLoginStageRequest from a JSON string +patched_user_login_stage_request_instance = PatchedUserLoginStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserLoginStageRequest.to_json()) + +# convert the object into a dict +patched_user_login_stage_request_dict = patched_user_login_stage_request_instance.to_dict() +# create an instance of PatchedUserLoginStageRequest from a dict +patched_user_login_stage_request_from_dict = PatchedUserLoginStageRequest.from_dict(patched_user_login_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserLogoutStageRequest.md b/docs/PatchedUserLogoutStageRequest.md new file mode 100644 index 000000000..c4b6b864b --- /dev/null +++ b/docs/PatchedUserLogoutStageRequest.md @@ -0,0 +1,30 @@ +# PatchedUserLogoutStageRequest + +UserLogoutStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_logout_stage_request import PatchedUserLogoutStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserLogoutStageRequest from a JSON string +patched_user_logout_stage_request_instance = PatchedUserLogoutStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserLogoutStageRequest.to_json()) + +# convert the object into a dict +patched_user_logout_stage_request_dict = patched_user_logout_stage_request_instance.to_dict() +# create an instance of PatchedUserLogoutStageRequest from a dict +patched_user_logout_stage_request_from_dict = PatchedUserLogoutStageRequest.from_dict(patched_user_logout_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserOAuthSourceConnectionRequest.md b/docs/PatchedUserOAuthSourceConnectionRequest.md new file mode 100644 index 000000000..5f7ed5418 --- /dev/null +++ b/docs/PatchedUserOAuthSourceConnectionRequest.md @@ -0,0 +1,33 @@ +# PatchedUserOAuthSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] +**access_token** | **str** | | [optional] +**expires** | **datetime** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_o_auth_source_connection_request import PatchedUserOAuthSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserOAuthSourceConnectionRequest from a JSON string +patched_user_o_auth_source_connection_request_instance = PatchedUserOAuthSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserOAuthSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_user_o_auth_source_connection_request_dict = patched_user_o_auth_source_connection_request_instance.to_dict() +# create an instance of PatchedUserOAuthSourceConnectionRequest from a dict +patched_user_o_auth_source_connection_request_from_dict = PatchedUserOAuthSourceConnectionRequest.from_dict(patched_user_o_auth_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserPlexSourceConnectionRequest.md b/docs/PatchedUserPlexSourceConnectionRequest.md new file mode 100644 index 000000000..e354ab32d --- /dev/null +++ b/docs/PatchedUserPlexSourceConnectionRequest.md @@ -0,0 +1,32 @@ +# PatchedUserPlexSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] +**plex_token** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_plex_source_connection_request import PatchedUserPlexSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserPlexSourceConnectionRequest from a JSON string +patched_user_plex_source_connection_request_instance = PatchedUserPlexSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserPlexSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_user_plex_source_connection_request_dict = patched_user_plex_source_connection_request_instance.to_dict() +# create an instance of PatchedUserPlexSourceConnectionRequest from a dict +patched_user_plex_source_connection_request_from_dict = PatchedUserPlexSourceConnectionRequest.from_dict(patched_user_plex_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserRequest.md b/docs/PatchedUserRequest.md new file mode 100644 index 000000000..4bb213e70 --- /dev/null +++ b/docs/PatchedUserRequest.md @@ -0,0 +1,39 @@ +# PatchedUserRequest + +User Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**username** | **str** | | [optional] +**name** | **str** | User's display name. | [optional] +**is_active** | **bool** | Designates whether this user should be treated as active. Unselect this instead of deleting accounts. | [optional] +**last_login** | **datetime** | | [optional] +**groups** | **List[UUID]** | | [optional] +**roles** | **List[UUID]** | | [optional] +**email** | **str** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] +**path** | **str** | | [optional] +**type** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_request import PatchedUserRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserRequest from a JSON string +patched_user_request_instance = PatchedUserRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserRequest.to_json()) + +# convert the object into a dict +patched_user_request_dict = patched_user_request_instance.to_dict() +# create an instance of PatchedUserRequest from a dict +patched_user_request_from_dict = PatchedUserRequest.from_dict(patched_user_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserSAMLSourceConnectionRequest.md b/docs/PatchedUserSAMLSourceConnectionRequest.md new file mode 100644 index 000000000..629c67377 --- /dev/null +++ b/docs/PatchedUserSAMLSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedUserSAMLSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_saml_source_connection_request import PatchedUserSAMLSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserSAMLSourceConnectionRequest from a JSON string +patched_user_saml_source_connection_request_instance = PatchedUserSAMLSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserSAMLSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_user_saml_source_connection_request_dict = patched_user_saml_source_connection_request_instance.to_dict() +# create an instance of PatchedUserSAMLSourceConnectionRequest from a dict +patched_user_saml_source_connection_request_from_dict = PatchedUserSAMLSourceConnectionRequest.from_dict(patched_user_saml_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserSourceConnectionRequest.md b/docs/PatchedUserSourceConnectionRequest.md new file mode 100644 index 000000000..4522a7afc --- /dev/null +++ b/docs/PatchedUserSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedUserSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_source_connection_request import PatchedUserSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserSourceConnectionRequest from a JSON string +patched_user_source_connection_request_instance = PatchedUserSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_user_source_connection_request_dict = patched_user_source_connection_request_instance.to_dict() +# create an instance of PatchedUserSourceConnectionRequest from a dict +patched_user_source_connection_request_from_dict = PatchedUserSourceConnectionRequest.from_dict(patched_user_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserTelegramSourceConnectionRequest.md b/docs/PatchedUserTelegramSourceConnectionRequest.md new file mode 100644 index 000000000..3629a1a5a --- /dev/null +++ b/docs/PatchedUserTelegramSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# PatchedUserTelegramSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | [optional] +**identifier** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_telegram_source_connection_request import PatchedUserTelegramSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserTelegramSourceConnectionRequest from a JSON string +patched_user_telegram_source_connection_request_instance = PatchedUserTelegramSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserTelegramSourceConnectionRequest.to_json()) + +# convert the object into a dict +patched_user_telegram_source_connection_request_dict = patched_user_telegram_source_connection_request_instance.to_dict() +# create an instance of PatchedUserTelegramSourceConnectionRequest from a dict +patched_user_telegram_source_connection_request_from_dict = PatchedUserTelegramSourceConnectionRequest.from_dict(patched_user_telegram_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedUserWriteStageRequest.md b/docs/PatchedUserWriteStageRequest.md new file mode 100644 index 000000000..82f61bc4b --- /dev/null +++ b/docs/PatchedUserWriteStageRequest.md @@ -0,0 +1,35 @@ +# PatchedUserWriteStageRequest + +UserWriteStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**user_creation_mode** | [**UserCreationModeEnum**](UserCreationModeEnum.md) | | [optional] +**create_users_as_inactive** | **bool** | When set, newly created users are inactive and cannot login. | [optional] +**create_users_group** | **UUID** | Optionally add newly created users to this group. | [optional] +**user_type** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional] +**user_path_template** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_user_write_stage_request import PatchedUserWriteStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedUserWriteStageRequest from a JSON string +patched_user_write_stage_request_instance = PatchedUserWriteStageRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedUserWriteStageRequest.to_json()) + +# convert the object into a dict +patched_user_write_stage_request_dict = patched_user_write_stage_request_instance.to_dict() +# create an instance of PatchedUserWriteStageRequest from a dict +patched_user_write_stage_request_from_dict = PatchedUserWriteStageRequest.from_dict(patched_user_write_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedWSFederationProviderRequest.md b/docs/PatchedWSFederationProviderRequest.md new file mode 100644 index 000000000..979acf61a --- /dev/null +++ b/docs/PatchedWSFederationProviderRequest.md @@ -0,0 +1,48 @@ +# PatchedWSFederationProviderRequest + +WSFederationProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | [optional] +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | [optional] +**property_mappings** | **List[UUID]** | | [optional] +**reply_url** | **str** | | [optional] +**wtrealm** | **str** | | [optional] +**assertion_valid_not_before** | **str** | Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3). | [optional] +**assertion_valid_not_on_or_after** | **str** | Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**session_valid_not_on_or_after** | **str** | Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**name_id_mapping** | **UUID** | Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered | [optional] +**authn_context_class_ref_mapping** | **UUID** | Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Service Provider. | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**sign_assertion** | **bool** | | [optional] +**sign_logout_request** | **bool** | | [optional] +**default_name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.patched_ws_federation_provider_request import PatchedWSFederationProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedWSFederationProviderRequest from a JSON string +patched_ws_federation_provider_request_instance = PatchedWSFederationProviderRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedWSFederationProviderRequest.to_json()) + +# convert the object into a dict +patched_ws_federation_provider_request_dict = patched_ws_federation_provider_request_instance.to_dict() +# create an instance of PatchedWSFederationProviderRequest from a dict +patched_ws_federation_provider_request_from_dict = PatchedWSFederationProviderRequest.from_dict(patched_ws_federation_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PatchedWebAuthnDeviceRequest.md b/docs/PatchedWebAuthnDeviceRequest.md new file mode 100644 index 000000000..4c7c5b269 --- /dev/null +++ b/docs/PatchedWebAuthnDeviceRequest.md @@ -0,0 +1,30 @@ +# PatchedWebAuthnDeviceRequest + +Serializer for WebAuthn authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.patched_web_authn_device_request import PatchedWebAuthnDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PatchedWebAuthnDeviceRequest from a JSON string +patched_web_authn_device_request_instance = PatchedWebAuthnDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(PatchedWebAuthnDeviceRequest.to_json()) + +# convert the object into a dict +patched_web_authn_device_request_dict = patched_web_authn_device_request_instance.to_dict() +# create an instance of PatchedWebAuthnDeviceRequest from a dict +patched_web_authn_device_request_from_dict = PatchedWebAuthnDeviceRequest.from_dict(patched_web_authn_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Permission.md b/docs/Permission.md new file mode 100644 index 000000000..76a325413 --- /dev/null +++ b/docs/Permission.md @@ -0,0 +1,36 @@ +# Permission + +Global permission + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | [readonly] +**name** | **str** | | +**codename** | **str** | | +**model** | **str** | | [readonly] +**app_label** | **str** | | [readonly] +**app_label_verbose** | **str** | Human-readable app label | [readonly] +**model_verbose** | **str** | Human-readable model name | [readonly] + +## Example + +```python +from authentik_client.models.permission import Permission + +# TODO update the JSON string below +json = "{}" +# create an instance of Permission from a JSON string +permission_instance = Permission.from_json(json) +# print the JSON string representation of the object +print(Permission.to_json()) + +# convert the object into a dict +permission_dict = permission_instance.to_dict() +# create an instance of Permission from a dict +permission_from_dict = Permission.from_dict(permission_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PermissionAssignRequest.md b/docs/PermissionAssignRequest.md new file mode 100644 index 000000000..99b947eb6 --- /dev/null +++ b/docs/PermissionAssignRequest.md @@ -0,0 +1,32 @@ +# PermissionAssignRequest + +Request to assign a new permission + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**permissions** | **List[str]** | | +**model** | [**ModelEnum**](ModelEnum.md) | | [optional] +**object_pk** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.permission_assign_request import PermissionAssignRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PermissionAssignRequest from a JSON string +permission_assign_request_instance = PermissionAssignRequest.from_json(json) +# print the JSON string representation of the object +print(PermissionAssignRequest.to_json()) + +# convert the object into a dict +permission_assign_request_dict = permission_assign_request_instance.to_dict() +# create an instance of PermissionAssignRequest from a dict +permission_assign_request_from_dict = PermissionAssignRequest.from_dict(permission_assign_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PermissionAssignResult.md b/docs/PermissionAssignResult.md new file mode 100644 index 000000000..82dd9826d --- /dev/null +++ b/docs/PermissionAssignResult.md @@ -0,0 +1,30 @@ +# PermissionAssignResult + +Result from assigning permissions to a user/role + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | + +## Example + +```python +from authentik_client.models.permission_assign_result import PermissionAssignResult + +# TODO update the JSON string below +json = "{}" +# create an instance of PermissionAssignResult from a JSON string +permission_assign_result_instance = PermissionAssignResult.from_json(json) +# print the JSON string representation of the object +print(PermissionAssignResult.to_json()) + +# convert the object into a dict +permission_assign_result_dict = permission_assign_result_instance.to_dict() +# create an instance of PermissionAssignResult from a dict +permission_assign_result_from_dict = PermissionAssignResult.from_dict(permission_assign_result_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PlexAuthenticationChallenge.md b/docs/PlexAuthenticationChallenge.md new file mode 100644 index 000000000..689609d54 --- /dev/null +++ b/docs/PlexAuthenticationChallenge.md @@ -0,0 +1,34 @@ +# PlexAuthenticationChallenge + +Challenge shown to the user in identification stage + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-source-plex'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**client_id** | **str** | | +**slug** | **str** | | + +## Example + +```python +from authentik_client.models.plex_authentication_challenge import PlexAuthenticationChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of PlexAuthenticationChallenge from a JSON string +plex_authentication_challenge_instance = PlexAuthenticationChallenge.from_json(json) +# print the JSON string representation of the object +print(PlexAuthenticationChallenge.to_json()) + +# convert the object into a dict +plex_authentication_challenge_dict = plex_authentication_challenge_instance.to_dict() +# create an instance of PlexAuthenticationChallenge from a dict +plex_authentication_challenge_from_dict = PlexAuthenticationChallenge.from_dict(plex_authentication_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PlexAuthenticationChallengeResponseRequest.md b/docs/PlexAuthenticationChallengeResponseRequest.md new file mode 100644 index 000000000..5b0956b8a --- /dev/null +++ b/docs/PlexAuthenticationChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# PlexAuthenticationChallengeResponseRequest + +Pseudo class for plex response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-source-plex'] + +## Example + +```python +from authentik_client.models.plex_authentication_challenge_response_request import PlexAuthenticationChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PlexAuthenticationChallengeResponseRequest from a JSON string +plex_authentication_challenge_response_request_instance = PlexAuthenticationChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(PlexAuthenticationChallengeResponseRequest.to_json()) + +# convert the object into a dict +plex_authentication_challenge_response_request_dict = plex_authentication_challenge_response_request_instance.to_dict() +# create an instance of PlexAuthenticationChallengeResponseRequest from a dict +plex_authentication_challenge_response_request_from_dict = PlexAuthenticationChallengeResponseRequest.from_dict(plex_authentication_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PlexSource.md b/docs/PlexSource.md new file mode 100644 index 000000000..fbcb24ee6 --- /dev/null +++ b/docs/PlexSource.md @@ -0,0 +1,54 @@ +# PlexSource + +Plex Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [readonly] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**icon_url** | **str** | | [readonly] +**icon_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**client_id** | **str** | Client identifier used to talk to Plex. | [optional] +**allowed_servers** | **List[str]** | Which servers a user has to be a member of to be granted access. Empty list allows every server. | [optional] +**allow_friends** | **bool** | Allow friends to authenticate, even if you don't share a server. | [optional] +**plex_token** | **str** | Plex token used to check friends | + +## Example + +```python +from authentik_client.models.plex_source import PlexSource + +# TODO update the JSON string below +json = "{}" +# create an instance of PlexSource from a JSON string +plex_source_instance = PlexSource.from_json(json) +# print the JSON string representation of the object +print(PlexSource.to_json()) + +# convert the object into a dict +plex_source_dict = plex_source_instance.to_dict() +# create an instance of PlexSource from a dict +plex_source_from_dict = PlexSource.from_dict(plex_source_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PlexSourcePropertyMapping.md b/docs/PlexSourcePropertyMapping.md new file mode 100644 index 000000000..f2aed7c21 --- /dev/null +++ b/docs/PlexSourcePropertyMapping.md @@ -0,0 +1,37 @@ +# PlexSourcePropertyMapping + +PlexSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of PlexSourcePropertyMapping from a JSON string +plex_source_property_mapping_instance = PlexSourcePropertyMapping.from_json(json) +# print the JSON string representation of the object +print(PlexSourcePropertyMapping.to_json()) + +# convert the object into a dict +plex_source_property_mapping_dict = plex_source_property_mapping_instance.to_dict() +# create an instance of PlexSourcePropertyMapping from a dict +plex_source_property_mapping_from_dict = PlexSourcePropertyMapping.from_dict(plex_source_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PlexSourcePropertyMappingRequest.md b/docs/PlexSourcePropertyMappingRequest.md new file mode 100644 index 000000000..9b2f9b1b1 --- /dev/null +++ b/docs/PlexSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# PlexSourcePropertyMappingRequest + +PlexSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.plex_source_property_mapping_request import PlexSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PlexSourcePropertyMappingRequest from a JSON string +plex_source_property_mapping_request_instance = PlexSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(PlexSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +plex_source_property_mapping_request_dict = plex_source_property_mapping_request_instance.to_dict() +# create an instance of PlexSourcePropertyMappingRequest from a dict +plex_source_property_mapping_request_from_dict = PlexSourcePropertyMappingRequest.from_dict(plex_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PlexSourceRequest.md b/docs/PlexSourceRequest.md new file mode 100644 index 000000000..aebd96f00 --- /dev/null +++ b/docs/PlexSourceRequest.md @@ -0,0 +1,46 @@ +# PlexSourceRequest + +Plex Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**client_id** | **str** | Client identifier used to talk to Plex. | [optional] +**allowed_servers** | **List[str]** | Which servers a user has to be a member of to be granted access. Empty list allows every server. | [optional] +**allow_friends** | **bool** | Allow friends to authenticate, even if you don't share a server. | [optional] +**plex_token** | **str** | Plex token used to check friends | + +## Example + +```python +from authentik_client.models.plex_source_request import PlexSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PlexSourceRequest from a JSON string +plex_source_request_instance = PlexSourceRequest.from_json(json) +# print the JSON string representation of the object +print(PlexSourceRequest.to_json()) + +# convert the object into a dict +plex_source_request_dict = plex_source_request_instance.to_dict() +# create an instance of PlexSourceRequest from a dict +plex_source_request_from_dict = PlexSourceRequest.from_dict(plex_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PlexTokenRedeemRequest.md b/docs/PlexTokenRedeemRequest.md new file mode 100644 index 000000000..bd358a09c --- /dev/null +++ b/docs/PlexTokenRedeemRequest.md @@ -0,0 +1,30 @@ +# PlexTokenRedeemRequest + +Serializer to redeem a plex token + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**plex_token** | **str** | | + +## Example + +```python +from authentik_client.models.plex_token_redeem_request import PlexTokenRedeemRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PlexTokenRedeemRequest from a JSON string +plex_token_redeem_request_instance = PlexTokenRedeemRequest.from_json(json) +# print the JSON string representation of the object +print(PlexTokenRedeemRequest.to_json()) + +# convert the object into a dict +plex_token_redeem_request_dict = plex_token_redeem_request_instance.to_dict() +# create an instance of PlexTokenRedeemRequest from a dict +plex_token_redeem_request_from_dict = PlexTokenRedeemRequest.from_dict(plex_token_redeem_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PoliciesApi.md b/docs/PoliciesApi.md new file mode 100644 index 000000000..16df474b5 --- /dev/null +++ b/docs/PoliciesApi.md @@ -0,0 +1,6172 @@ +# authentik_client.PoliciesApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**policies_all_cache_clear_create**](PoliciesApi.md#policies_all_cache_clear_create) | **POST** /policies/all/cache_clear/ | +[**policies_all_cache_info_retrieve**](PoliciesApi.md#policies_all_cache_info_retrieve) | **GET** /policies/all/cache_info/ | +[**policies_all_destroy**](PoliciesApi.md#policies_all_destroy) | **DELETE** /policies/all/{policy_uuid}/ | +[**policies_all_list**](PoliciesApi.md#policies_all_list) | **GET** /policies/all/ | +[**policies_all_retrieve**](PoliciesApi.md#policies_all_retrieve) | **GET** /policies/all/{policy_uuid}/ | +[**policies_all_test_create**](PoliciesApi.md#policies_all_test_create) | **POST** /policies/all/{policy_uuid}/test/ | +[**policies_all_types_list**](PoliciesApi.md#policies_all_types_list) | **GET** /policies/all/types/ | +[**policies_all_used_by_list**](PoliciesApi.md#policies_all_used_by_list) | **GET** /policies/all/{policy_uuid}/used_by/ | +[**policies_bindings_create**](PoliciesApi.md#policies_bindings_create) | **POST** /policies/bindings/ | +[**policies_bindings_destroy**](PoliciesApi.md#policies_bindings_destroy) | **DELETE** /policies/bindings/{policy_binding_uuid}/ | +[**policies_bindings_list**](PoliciesApi.md#policies_bindings_list) | **GET** /policies/bindings/ | +[**policies_bindings_partial_update**](PoliciesApi.md#policies_bindings_partial_update) | **PATCH** /policies/bindings/{policy_binding_uuid}/ | +[**policies_bindings_retrieve**](PoliciesApi.md#policies_bindings_retrieve) | **GET** /policies/bindings/{policy_binding_uuid}/ | +[**policies_bindings_update**](PoliciesApi.md#policies_bindings_update) | **PUT** /policies/bindings/{policy_binding_uuid}/ | +[**policies_bindings_used_by_list**](PoliciesApi.md#policies_bindings_used_by_list) | **GET** /policies/bindings/{policy_binding_uuid}/used_by/ | +[**policies_dummy_create**](PoliciesApi.md#policies_dummy_create) | **POST** /policies/dummy/ | +[**policies_dummy_destroy**](PoliciesApi.md#policies_dummy_destroy) | **DELETE** /policies/dummy/{policy_uuid}/ | +[**policies_dummy_list**](PoliciesApi.md#policies_dummy_list) | **GET** /policies/dummy/ | +[**policies_dummy_partial_update**](PoliciesApi.md#policies_dummy_partial_update) | **PATCH** /policies/dummy/{policy_uuid}/ | +[**policies_dummy_retrieve**](PoliciesApi.md#policies_dummy_retrieve) | **GET** /policies/dummy/{policy_uuid}/ | +[**policies_dummy_update**](PoliciesApi.md#policies_dummy_update) | **PUT** /policies/dummy/{policy_uuid}/ | +[**policies_dummy_used_by_list**](PoliciesApi.md#policies_dummy_used_by_list) | **GET** /policies/dummy/{policy_uuid}/used_by/ | +[**policies_event_matcher_create**](PoliciesApi.md#policies_event_matcher_create) | **POST** /policies/event_matcher/ | +[**policies_event_matcher_destroy**](PoliciesApi.md#policies_event_matcher_destroy) | **DELETE** /policies/event_matcher/{policy_uuid}/ | +[**policies_event_matcher_list**](PoliciesApi.md#policies_event_matcher_list) | **GET** /policies/event_matcher/ | +[**policies_event_matcher_partial_update**](PoliciesApi.md#policies_event_matcher_partial_update) | **PATCH** /policies/event_matcher/{policy_uuid}/ | +[**policies_event_matcher_retrieve**](PoliciesApi.md#policies_event_matcher_retrieve) | **GET** /policies/event_matcher/{policy_uuid}/ | +[**policies_event_matcher_update**](PoliciesApi.md#policies_event_matcher_update) | **PUT** /policies/event_matcher/{policy_uuid}/ | +[**policies_event_matcher_used_by_list**](PoliciesApi.md#policies_event_matcher_used_by_list) | **GET** /policies/event_matcher/{policy_uuid}/used_by/ | +[**policies_expression_create**](PoliciesApi.md#policies_expression_create) | **POST** /policies/expression/ | +[**policies_expression_destroy**](PoliciesApi.md#policies_expression_destroy) | **DELETE** /policies/expression/{policy_uuid}/ | +[**policies_expression_list**](PoliciesApi.md#policies_expression_list) | **GET** /policies/expression/ | +[**policies_expression_partial_update**](PoliciesApi.md#policies_expression_partial_update) | **PATCH** /policies/expression/{policy_uuid}/ | +[**policies_expression_retrieve**](PoliciesApi.md#policies_expression_retrieve) | **GET** /policies/expression/{policy_uuid}/ | +[**policies_expression_update**](PoliciesApi.md#policies_expression_update) | **PUT** /policies/expression/{policy_uuid}/ | +[**policies_expression_used_by_list**](PoliciesApi.md#policies_expression_used_by_list) | **GET** /policies/expression/{policy_uuid}/used_by/ | +[**policies_geoip_create**](PoliciesApi.md#policies_geoip_create) | **POST** /policies/geoip/ | +[**policies_geoip_destroy**](PoliciesApi.md#policies_geoip_destroy) | **DELETE** /policies/geoip/{policy_uuid}/ | +[**policies_geoip_iso3166_list**](PoliciesApi.md#policies_geoip_iso3166_list) | **GET** /policies/geoip_iso3166/ | +[**policies_geoip_list**](PoliciesApi.md#policies_geoip_list) | **GET** /policies/geoip/ | +[**policies_geoip_partial_update**](PoliciesApi.md#policies_geoip_partial_update) | **PATCH** /policies/geoip/{policy_uuid}/ | +[**policies_geoip_retrieve**](PoliciesApi.md#policies_geoip_retrieve) | **GET** /policies/geoip/{policy_uuid}/ | +[**policies_geoip_update**](PoliciesApi.md#policies_geoip_update) | **PUT** /policies/geoip/{policy_uuid}/ | +[**policies_geoip_used_by_list**](PoliciesApi.md#policies_geoip_used_by_list) | **GET** /policies/geoip/{policy_uuid}/used_by/ | +[**policies_password_create**](PoliciesApi.md#policies_password_create) | **POST** /policies/password/ | +[**policies_password_destroy**](PoliciesApi.md#policies_password_destroy) | **DELETE** /policies/password/{policy_uuid}/ | +[**policies_password_expiry_create**](PoliciesApi.md#policies_password_expiry_create) | **POST** /policies/password_expiry/ | +[**policies_password_expiry_destroy**](PoliciesApi.md#policies_password_expiry_destroy) | **DELETE** /policies/password_expiry/{policy_uuid}/ | +[**policies_password_expiry_list**](PoliciesApi.md#policies_password_expiry_list) | **GET** /policies/password_expiry/ | +[**policies_password_expiry_partial_update**](PoliciesApi.md#policies_password_expiry_partial_update) | **PATCH** /policies/password_expiry/{policy_uuid}/ | +[**policies_password_expiry_retrieve**](PoliciesApi.md#policies_password_expiry_retrieve) | **GET** /policies/password_expiry/{policy_uuid}/ | +[**policies_password_expiry_update**](PoliciesApi.md#policies_password_expiry_update) | **PUT** /policies/password_expiry/{policy_uuid}/ | +[**policies_password_expiry_used_by_list**](PoliciesApi.md#policies_password_expiry_used_by_list) | **GET** /policies/password_expiry/{policy_uuid}/used_by/ | +[**policies_password_list**](PoliciesApi.md#policies_password_list) | **GET** /policies/password/ | +[**policies_password_partial_update**](PoliciesApi.md#policies_password_partial_update) | **PATCH** /policies/password/{policy_uuid}/ | +[**policies_password_retrieve**](PoliciesApi.md#policies_password_retrieve) | **GET** /policies/password/{policy_uuid}/ | +[**policies_password_update**](PoliciesApi.md#policies_password_update) | **PUT** /policies/password/{policy_uuid}/ | +[**policies_password_used_by_list**](PoliciesApi.md#policies_password_used_by_list) | **GET** /policies/password/{policy_uuid}/used_by/ | +[**policies_reputation_create**](PoliciesApi.md#policies_reputation_create) | **POST** /policies/reputation/ | +[**policies_reputation_destroy**](PoliciesApi.md#policies_reputation_destroy) | **DELETE** /policies/reputation/{policy_uuid}/ | +[**policies_reputation_list**](PoliciesApi.md#policies_reputation_list) | **GET** /policies/reputation/ | +[**policies_reputation_partial_update**](PoliciesApi.md#policies_reputation_partial_update) | **PATCH** /policies/reputation/{policy_uuid}/ | +[**policies_reputation_retrieve**](PoliciesApi.md#policies_reputation_retrieve) | **GET** /policies/reputation/{policy_uuid}/ | +[**policies_reputation_scores_destroy**](PoliciesApi.md#policies_reputation_scores_destroy) | **DELETE** /policies/reputation/scores/{reputation_uuid}/ | +[**policies_reputation_scores_list**](PoliciesApi.md#policies_reputation_scores_list) | **GET** /policies/reputation/scores/ | +[**policies_reputation_scores_retrieve**](PoliciesApi.md#policies_reputation_scores_retrieve) | **GET** /policies/reputation/scores/{reputation_uuid}/ | +[**policies_reputation_scores_used_by_list**](PoliciesApi.md#policies_reputation_scores_used_by_list) | **GET** /policies/reputation/scores/{reputation_uuid}/used_by/ | +[**policies_reputation_update**](PoliciesApi.md#policies_reputation_update) | **PUT** /policies/reputation/{policy_uuid}/ | +[**policies_reputation_used_by_list**](PoliciesApi.md#policies_reputation_used_by_list) | **GET** /policies/reputation/{policy_uuid}/used_by/ | +[**policies_unique_password_create**](PoliciesApi.md#policies_unique_password_create) | **POST** /policies/unique_password/ | +[**policies_unique_password_destroy**](PoliciesApi.md#policies_unique_password_destroy) | **DELETE** /policies/unique_password/{policy_uuid}/ | +[**policies_unique_password_list**](PoliciesApi.md#policies_unique_password_list) | **GET** /policies/unique_password/ | +[**policies_unique_password_partial_update**](PoliciesApi.md#policies_unique_password_partial_update) | **PATCH** /policies/unique_password/{policy_uuid}/ | +[**policies_unique_password_retrieve**](PoliciesApi.md#policies_unique_password_retrieve) | **GET** /policies/unique_password/{policy_uuid}/ | +[**policies_unique_password_update**](PoliciesApi.md#policies_unique_password_update) | **PUT** /policies/unique_password/{policy_uuid}/ | +[**policies_unique_password_used_by_list**](PoliciesApi.md#policies_unique_password_used_by_list) | **GET** /policies/unique_password/{policy_uuid}/used_by/ | + + +# **policies_all_cache_clear_create** +> policies_all_cache_clear_create() + +Clear policy cache + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + + try: + api_instance.policies_all_cache_clear_create() + except Exception as e: + print("Exception when calling PoliciesApi->policies_all_cache_clear_create: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully cleared cache | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_all_cache_info_retrieve** +> Cache policies_all_cache_info_retrieve() + +Info about cached policies + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.cache import Cache +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + + try: + api_response = api_instance.policies_all_cache_info_retrieve() + print("The response of PoliciesApi->policies_all_cache_info_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_all_cache_info_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**Cache**](Cache.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_all_destroy** +> policies_all_destroy(policy_uuid) + +Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Policy. + + try: + api_instance.policies_all_destroy(policy_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_all_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Policy. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_all_list** +> PaginatedPolicyList policies_all_list(bindings__isnull=bindings__isnull, ordering=ordering, page=page, page_size=page_size, promptstage__isnull=promptstage__isnull, search=search) + +Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_policy_list import PaginatedPolicyList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + bindings__isnull = True # bool | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + promptstage__isnull = True # bool | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.policies_all_list(bindings__isnull=bindings__isnull, ordering=ordering, page=page, page_size=page_size, promptstage__isnull=promptstage__isnull, search=search) + print("The response of PoliciesApi->policies_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_all_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **bindings__isnull** | **bool**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **promptstage__isnull** | **bool**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedPolicyList**](PaginatedPolicyList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_all_retrieve** +> Policy policies_all_retrieve(policy_uuid) + +Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.policy import Policy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Policy. + + try: + api_response = api_instance.policies_all_retrieve(policy_uuid) + print("The response of PoliciesApi->policies_all_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_all_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Policy. | + +### Return type + +[**Policy**](Policy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_all_test_create** +> PolicyTestResult policies_all_test_create(policy_uuid, policy_test_request) + +Test policy + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.policy_test_request import PolicyTestRequest +from authentik_client.models.policy_test_result import PolicyTestResult +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Policy. + policy_test_request = authentik_client.PolicyTestRequest() # PolicyTestRequest | + + try: + api_response = api_instance.policies_all_test_create(policy_uuid, policy_test_request) + print("The response of PoliciesApi->policies_all_test_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_all_test_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Policy. | + **policy_test_request** | [**PolicyTestRequest**](PolicyTestRequest.md)| | + +### Return type + +[**PolicyTestResult**](PolicyTestResult.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Invalid parameters | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_all_types_list** +> List[TypeCreate] policies_all_types_list() + +Get all creatable types + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.type_create import TypeCreate +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + + try: + api_response = api_instance.policies_all_types_list() + print("The response of PoliciesApi->policies_all_types_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_all_types_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[TypeCreate]**](TypeCreate.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_all_used_by_list** +> List[UsedBy] policies_all_used_by_list(policy_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Policy. + + try: + api_response = api_instance.policies_all_used_by_list(policy_uuid) + print("The response of PoliciesApi->policies_all_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_all_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Policy. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_bindings_create** +> PolicyBinding policies_bindings_create(policy_binding_request) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.policy_binding import PolicyBinding +from authentik_client.models.policy_binding_request import PolicyBindingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_binding_request = authentik_client.PolicyBindingRequest() # PolicyBindingRequest | + + try: + api_response = api_instance.policies_bindings_create(policy_binding_request) + print("The response of PoliciesApi->policies_bindings_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_bindings_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_request** | [**PolicyBindingRequest**](PolicyBindingRequest.md)| | + +### Return type + +[**PolicyBinding**](PolicyBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_bindings_destroy** +> policies_bindings_destroy(policy_binding_uuid) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Policy Binding. + + try: + api_instance.policies_bindings_destroy(policy_binding_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_bindings_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Policy Binding. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_bindings_list** +> PaginatedPolicyBindingList policies_bindings_list(enabled=enabled, order=order, ordering=ordering, page=page, page_size=page_size, policy=policy, policy__isnull=policy__isnull, search=search, target=target, target_in=target_in, timeout=timeout) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_policy_binding_list import PaginatedPolicyBindingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + enabled = True # bool | (optional) + order = 56 # int | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + policy = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + policy__isnull = True # bool | (optional) + search = 'search_example' # str | A search term. (optional) + target = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + target_in = None # List[UUID] | (optional) + timeout = 56 # int | (optional) + + try: + api_response = api_instance.policies_bindings_list(enabled=enabled, order=order, ordering=ordering, page=page, page_size=page_size, policy=policy, policy__isnull=policy__isnull, search=search, target=target, target_in=target_in, timeout=timeout) + print("The response of PoliciesApi->policies_bindings_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_bindings_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **enabled** | **bool**| | [optional] + **order** | **int**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **policy** | **UUID**| | [optional] + **policy__isnull** | **bool**| | [optional] + **search** | **str**| A search term. | [optional] + **target** | **UUID**| | [optional] + **target_in** | [**List[UUID]**](UUID.md)| | [optional] + **timeout** | **int**| | [optional] + +### Return type + +[**PaginatedPolicyBindingList**](PaginatedPolicyBindingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_bindings_partial_update** +> PolicyBinding policies_bindings_partial_update(policy_binding_uuid, patched_policy_binding_request=patched_policy_binding_request) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_policy_binding_request import PatchedPolicyBindingRequest +from authentik_client.models.policy_binding import PolicyBinding +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Policy Binding. + patched_policy_binding_request = authentik_client.PatchedPolicyBindingRequest() # PatchedPolicyBindingRequest | (optional) + + try: + api_response = api_instance.policies_bindings_partial_update(policy_binding_uuid, patched_policy_binding_request=patched_policy_binding_request) + print("The response of PoliciesApi->policies_bindings_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_bindings_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Policy Binding. | + **patched_policy_binding_request** | [**PatchedPolicyBindingRequest**](PatchedPolicyBindingRequest.md)| | [optional] + +### Return type + +[**PolicyBinding**](PolicyBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_bindings_retrieve** +> PolicyBinding policies_bindings_retrieve(policy_binding_uuid) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.policy_binding import PolicyBinding +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Policy Binding. + + try: + api_response = api_instance.policies_bindings_retrieve(policy_binding_uuid) + print("The response of PoliciesApi->policies_bindings_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_bindings_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Policy Binding. | + +### Return type + +[**PolicyBinding**](PolicyBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_bindings_update** +> PolicyBinding policies_bindings_update(policy_binding_uuid, policy_binding_request) + +PolicyBinding Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.policy_binding import PolicyBinding +from authentik_client.models.policy_binding_request import PolicyBindingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Policy Binding. + policy_binding_request = authentik_client.PolicyBindingRequest() # PolicyBindingRequest | + + try: + api_response = api_instance.policies_bindings_update(policy_binding_uuid, policy_binding_request) + print("The response of PoliciesApi->policies_bindings_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_bindings_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Policy Binding. | + **policy_binding_request** | [**PolicyBindingRequest**](PolicyBindingRequest.md)| | + +### Return type + +[**PolicyBinding**](PolicyBinding.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_bindings_used_by_list** +> List[UsedBy] policies_bindings_used_by_list(policy_binding_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_binding_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Policy Binding. + + try: + api_response = api_instance.policies_bindings_used_by_list(policy_binding_uuid) + print("The response of PoliciesApi->policies_bindings_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_bindings_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_binding_uuid** | **UUID**| A UUID string identifying this Policy Binding. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_dummy_create** +> DummyPolicy policies_dummy_create(dummy_policy_request) + +Dummy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.dummy_policy import DummyPolicy +from authentik_client.models.dummy_policy_request import DummyPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + dummy_policy_request = authentik_client.DummyPolicyRequest() # DummyPolicyRequest | + + try: + api_response = api_instance.policies_dummy_create(dummy_policy_request) + print("The response of PoliciesApi->policies_dummy_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_dummy_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **dummy_policy_request** | [**DummyPolicyRequest**](DummyPolicyRequest.md)| | + +### Return type + +[**DummyPolicy**](DummyPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_dummy_destroy** +> policies_dummy_destroy(policy_uuid) + +Dummy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Policy. + + try: + api_instance.policies_dummy_destroy(policy_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_dummy_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Dummy Policy. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_dummy_list** +> PaginatedDummyPolicyList policies_dummy_list(created=created, execution_logging=execution_logging, last_updated=last_updated, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, result=result, search=search, wait_max=wait_max, wait_min=wait_min) + +Dummy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_dummy_policy_list import PaginatedDummyPolicyList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + created = '2013-10-20T19:20:30+01:00' # datetime | (optional) + execution_logging = True # bool | (optional) + last_updated = '2013-10-20T19:20:30+01:00' # datetime | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + result = True # bool | (optional) + search = 'search_example' # str | A search term. (optional) + wait_max = 56 # int | (optional) + wait_min = 56 # int | (optional) + + try: + api_response = api_instance.policies_dummy_list(created=created, execution_logging=execution_logging, last_updated=last_updated, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, result=result, search=search, wait_max=wait_max, wait_min=wait_min) + print("The response of PoliciesApi->policies_dummy_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_dummy_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **created** | **datetime**| | [optional] + **execution_logging** | **bool**| | [optional] + **last_updated** | **datetime**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **policy_uuid** | **UUID**| | [optional] + **result** | **bool**| | [optional] + **search** | **str**| A search term. | [optional] + **wait_max** | **int**| | [optional] + **wait_min** | **int**| | [optional] + +### Return type + +[**PaginatedDummyPolicyList**](PaginatedDummyPolicyList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_dummy_partial_update** +> DummyPolicy policies_dummy_partial_update(policy_uuid, patched_dummy_policy_request=patched_dummy_policy_request) + +Dummy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.dummy_policy import DummyPolicy +from authentik_client.models.patched_dummy_policy_request import PatchedDummyPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Policy. + patched_dummy_policy_request = authentik_client.PatchedDummyPolicyRequest() # PatchedDummyPolicyRequest | (optional) + + try: + api_response = api_instance.policies_dummy_partial_update(policy_uuid, patched_dummy_policy_request=patched_dummy_policy_request) + print("The response of PoliciesApi->policies_dummy_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_dummy_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Dummy Policy. | + **patched_dummy_policy_request** | [**PatchedDummyPolicyRequest**](PatchedDummyPolicyRequest.md)| | [optional] + +### Return type + +[**DummyPolicy**](DummyPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_dummy_retrieve** +> DummyPolicy policies_dummy_retrieve(policy_uuid) + +Dummy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.dummy_policy import DummyPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Policy. + + try: + api_response = api_instance.policies_dummy_retrieve(policy_uuid) + print("The response of PoliciesApi->policies_dummy_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_dummy_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Dummy Policy. | + +### Return type + +[**DummyPolicy**](DummyPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_dummy_update** +> DummyPolicy policies_dummy_update(policy_uuid, dummy_policy_request) + +Dummy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.dummy_policy import DummyPolicy +from authentik_client.models.dummy_policy_request import DummyPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Policy. + dummy_policy_request = authentik_client.DummyPolicyRequest() # DummyPolicyRequest | + + try: + api_response = api_instance.policies_dummy_update(policy_uuid, dummy_policy_request) + print("The response of PoliciesApi->policies_dummy_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_dummy_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Dummy Policy. | + **dummy_policy_request** | [**DummyPolicyRequest**](DummyPolicyRequest.md)| | + +### Return type + +[**DummyPolicy**](DummyPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_dummy_used_by_list** +> List[UsedBy] policies_dummy_used_by_list(policy_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Policy. + + try: + api_response = api_instance.policies_dummy_used_by_list(policy_uuid) + print("The response of PoliciesApi->policies_dummy_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_dummy_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Dummy Policy. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_event_matcher_create** +> EventMatcherPolicy policies_event_matcher_create(event_matcher_policy_request) + +Event Matcher Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event_matcher_policy import EventMatcherPolicy +from authentik_client.models.event_matcher_policy_request import EventMatcherPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + event_matcher_policy_request = authentik_client.EventMatcherPolicyRequest() # EventMatcherPolicyRequest | + + try: + api_response = api_instance.policies_event_matcher_create(event_matcher_policy_request) + print("The response of PoliciesApi->policies_event_matcher_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_event_matcher_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **event_matcher_policy_request** | [**EventMatcherPolicyRequest**](EventMatcherPolicyRequest.md)| | + +### Return type + +[**EventMatcherPolicy**](EventMatcherPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_event_matcher_destroy** +> policies_event_matcher_destroy(policy_uuid) + +Event Matcher Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Event Matcher Policy. + + try: + api_instance.policies_event_matcher_destroy(policy_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_event_matcher_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Event Matcher Policy. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_event_matcher_list** +> PaginatedEventMatcherPolicyList policies_event_matcher_list(action=action, app=app, client_ip=client_ip, created=created, execution_logging=execution_logging, last_updated=last_updated, model=model, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, query=query, search=search) + +Event Matcher Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_event_matcher_policy_list import PaginatedEventMatcherPolicyList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + action = authentik_client.EventActions() # EventActions | (optional) + app = 'app_example' # str | (optional) + client_ip = 'client_ip_example' # str | (optional) + created = '2013-10-20T19:20:30+01:00' # datetime | (optional) + execution_logging = True # bool | (optional) + last_updated = '2013-10-20T19:20:30+01:00' # datetime | (optional) + model = 'model_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + query = 'query_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.policies_event_matcher_list(action=action, app=app, client_ip=client_ip, created=created, execution_logging=execution_logging, last_updated=last_updated, model=model, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, query=query, search=search) + print("The response of PoliciesApi->policies_event_matcher_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_event_matcher_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **action** | [**EventActions**](.md)| | [optional] + **app** | **str**| | [optional] + **client_ip** | **str**| | [optional] + **created** | **datetime**| | [optional] + **execution_logging** | **bool**| | [optional] + **last_updated** | **datetime**| | [optional] + **model** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **policy_uuid** | **UUID**| | [optional] + **query** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedEventMatcherPolicyList**](PaginatedEventMatcherPolicyList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_event_matcher_partial_update** +> EventMatcherPolicy policies_event_matcher_partial_update(policy_uuid, patched_event_matcher_policy_request=patched_event_matcher_policy_request) + +Event Matcher Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event_matcher_policy import EventMatcherPolicy +from authentik_client.models.patched_event_matcher_policy_request import PatchedEventMatcherPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Event Matcher Policy. + patched_event_matcher_policy_request = authentik_client.PatchedEventMatcherPolicyRequest() # PatchedEventMatcherPolicyRequest | (optional) + + try: + api_response = api_instance.policies_event_matcher_partial_update(policy_uuid, patched_event_matcher_policy_request=patched_event_matcher_policy_request) + print("The response of PoliciesApi->policies_event_matcher_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_event_matcher_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Event Matcher Policy. | + **patched_event_matcher_policy_request** | [**PatchedEventMatcherPolicyRequest**](PatchedEventMatcherPolicyRequest.md)| | [optional] + +### Return type + +[**EventMatcherPolicy**](EventMatcherPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_event_matcher_retrieve** +> EventMatcherPolicy policies_event_matcher_retrieve(policy_uuid) + +Event Matcher Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event_matcher_policy import EventMatcherPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Event Matcher Policy. + + try: + api_response = api_instance.policies_event_matcher_retrieve(policy_uuid) + print("The response of PoliciesApi->policies_event_matcher_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_event_matcher_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Event Matcher Policy. | + +### Return type + +[**EventMatcherPolicy**](EventMatcherPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_event_matcher_update** +> EventMatcherPolicy policies_event_matcher_update(policy_uuid, event_matcher_policy_request) + +Event Matcher Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.event_matcher_policy import EventMatcherPolicy +from authentik_client.models.event_matcher_policy_request import EventMatcherPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Event Matcher Policy. + event_matcher_policy_request = authentik_client.EventMatcherPolicyRequest() # EventMatcherPolicyRequest | + + try: + api_response = api_instance.policies_event_matcher_update(policy_uuid, event_matcher_policy_request) + print("The response of PoliciesApi->policies_event_matcher_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_event_matcher_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Event Matcher Policy. | + **event_matcher_policy_request** | [**EventMatcherPolicyRequest**](EventMatcherPolicyRequest.md)| | + +### Return type + +[**EventMatcherPolicy**](EventMatcherPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_event_matcher_used_by_list** +> List[UsedBy] policies_event_matcher_used_by_list(policy_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Event Matcher Policy. + + try: + api_response = api_instance.policies_event_matcher_used_by_list(policy_uuid) + print("The response of PoliciesApi->policies_event_matcher_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_event_matcher_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Event Matcher Policy. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_expression_create** +> ExpressionPolicy policies_expression_create(expression_policy_request) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.expression_policy import ExpressionPolicy +from authentik_client.models.expression_policy_request import ExpressionPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + expression_policy_request = authentik_client.ExpressionPolicyRequest() # ExpressionPolicyRequest | + + try: + api_response = api_instance.policies_expression_create(expression_policy_request) + print("The response of PoliciesApi->policies_expression_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_expression_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **expression_policy_request** | [**ExpressionPolicyRequest**](ExpressionPolicyRequest.md)| | + +### Return type + +[**ExpressionPolicy**](ExpressionPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_expression_destroy** +> policies_expression_destroy(policy_uuid) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Expression Policy. + + try: + api_instance.policies_expression_destroy(policy_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_expression_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Expression Policy. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_expression_list** +> PaginatedExpressionPolicyList policies_expression_list(created=created, execution_logging=execution_logging, expression=expression, last_updated=last_updated, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, search=search) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_expression_policy_list import PaginatedExpressionPolicyList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + created = '2013-10-20T19:20:30+01:00' # datetime | (optional) + execution_logging = True # bool | (optional) + expression = 'expression_example' # str | (optional) + last_updated = '2013-10-20T19:20:30+01:00' # datetime | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.policies_expression_list(created=created, execution_logging=execution_logging, expression=expression, last_updated=last_updated, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, search=search) + print("The response of PoliciesApi->policies_expression_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_expression_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **created** | **datetime**| | [optional] + **execution_logging** | **bool**| | [optional] + **expression** | **str**| | [optional] + **last_updated** | **datetime**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **policy_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedExpressionPolicyList**](PaginatedExpressionPolicyList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_expression_partial_update** +> ExpressionPolicy policies_expression_partial_update(policy_uuid, patched_expression_policy_request=patched_expression_policy_request) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.expression_policy import ExpressionPolicy +from authentik_client.models.patched_expression_policy_request import PatchedExpressionPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Expression Policy. + patched_expression_policy_request = authentik_client.PatchedExpressionPolicyRequest() # PatchedExpressionPolicyRequest | (optional) + + try: + api_response = api_instance.policies_expression_partial_update(policy_uuid, patched_expression_policy_request=patched_expression_policy_request) + print("The response of PoliciesApi->policies_expression_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_expression_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Expression Policy. | + **patched_expression_policy_request** | [**PatchedExpressionPolicyRequest**](PatchedExpressionPolicyRequest.md)| | [optional] + +### Return type + +[**ExpressionPolicy**](ExpressionPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_expression_retrieve** +> ExpressionPolicy policies_expression_retrieve(policy_uuid) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.expression_policy import ExpressionPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Expression Policy. + + try: + api_response = api_instance.policies_expression_retrieve(policy_uuid) + print("The response of PoliciesApi->policies_expression_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_expression_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Expression Policy. | + +### Return type + +[**ExpressionPolicy**](ExpressionPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_expression_update** +> ExpressionPolicy policies_expression_update(policy_uuid, expression_policy_request) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.expression_policy import ExpressionPolicy +from authentik_client.models.expression_policy_request import ExpressionPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Expression Policy. + expression_policy_request = authentik_client.ExpressionPolicyRequest() # ExpressionPolicyRequest | + + try: + api_response = api_instance.policies_expression_update(policy_uuid, expression_policy_request) + print("The response of PoliciesApi->policies_expression_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_expression_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Expression Policy. | + **expression_policy_request** | [**ExpressionPolicyRequest**](ExpressionPolicyRequest.md)| | + +### Return type + +[**ExpressionPolicy**](ExpressionPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_expression_used_by_list** +> List[UsedBy] policies_expression_used_by_list(policy_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Expression Policy. + + try: + api_response = api_instance.policies_expression_used_by_list(policy_uuid) + print("The response of PoliciesApi->policies_expression_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_expression_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Expression Policy. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_geoip_create** +> GeoIPPolicy policies_geoip_create(geo_ip_policy_request) + +GeoIP Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.geo_ip_policy import GeoIPPolicy +from authentik_client.models.geo_ip_policy_request import GeoIPPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + geo_ip_policy_request = authentik_client.GeoIPPolicyRequest() # GeoIPPolicyRequest | + + try: + api_response = api_instance.policies_geoip_create(geo_ip_policy_request) + print("The response of PoliciesApi->policies_geoip_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_geoip_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **geo_ip_policy_request** | [**GeoIPPolicyRequest**](GeoIPPolicyRequest.md)| | + +### Return type + +[**GeoIPPolicy**](GeoIPPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_geoip_destroy** +> policies_geoip_destroy(policy_uuid) + +GeoIP Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this GeoIP Policy. + + try: + api_instance.policies_geoip_destroy(policy_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_geoip_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this GeoIP Policy. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_geoip_iso3166_list** +> List[DetailedCountry] policies_geoip_iso3166_list() + +Get all countries in ISO-3166-1 + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.detailed_country import DetailedCountry +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + + try: + api_response = api_instance.policies_geoip_iso3166_list() + print("The response of PoliciesApi->policies_geoip_iso3166_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_geoip_iso3166_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[DetailedCountry]**](DetailedCountry.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_geoip_list** +> PaginatedGeoIPPolicyList policies_geoip_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +GeoIP Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_geo_ip_policy_list import PaginatedGeoIPPolicyList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.policies_geoip_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PoliciesApi->policies_geoip_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_geoip_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedGeoIPPolicyList**](PaginatedGeoIPPolicyList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_geoip_partial_update** +> GeoIPPolicy policies_geoip_partial_update(policy_uuid, patched_geo_ip_policy_request=patched_geo_ip_policy_request) + +GeoIP Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.geo_ip_policy import GeoIPPolicy +from authentik_client.models.patched_geo_ip_policy_request import PatchedGeoIPPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this GeoIP Policy. + patched_geo_ip_policy_request = authentik_client.PatchedGeoIPPolicyRequest() # PatchedGeoIPPolicyRequest | (optional) + + try: + api_response = api_instance.policies_geoip_partial_update(policy_uuid, patched_geo_ip_policy_request=patched_geo_ip_policy_request) + print("The response of PoliciesApi->policies_geoip_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_geoip_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this GeoIP Policy. | + **patched_geo_ip_policy_request** | [**PatchedGeoIPPolicyRequest**](PatchedGeoIPPolicyRequest.md)| | [optional] + +### Return type + +[**GeoIPPolicy**](GeoIPPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_geoip_retrieve** +> GeoIPPolicy policies_geoip_retrieve(policy_uuid) + +GeoIP Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.geo_ip_policy import GeoIPPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this GeoIP Policy. + + try: + api_response = api_instance.policies_geoip_retrieve(policy_uuid) + print("The response of PoliciesApi->policies_geoip_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_geoip_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this GeoIP Policy. | + +### Return type + +[**GeoIPPolicy**](GeoIPPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_geoip_update** +> GeoIPPolicy policies_geoip_update(policy_uuid, geo_ip_policy_request) + +GeoIP Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.geo_ip_policy import GeoIPPolicy +from authentik_client.models.geo_ip_policy_request import GeoIPPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this GeoIP Policy. + geo_ip_policy_request = authentik_client.GeoIPPolicyRequest() # GeoIPPolicyRequest | + + try: + api_response = api_instance.policies_geoip_update(policy_uuid, geo_ip_policy_request) + print("The response of PoliciesApi->policies_geoip_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_geoip_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this GeoIP Policy. | + **geo_ip_policy_request** | [**GeoIPPolicyRequest**](GeoIPPolicyRequest.md)| | + +### Return type + +[**GeoIPPolicy**](GeoIPPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_geoip_used_by_list** +> List[UsedBy] policies_geoip_used_by_list(policy_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this GeoIP Policy. + + try: + api_response = api_instance.policies_geoip_used_by_list(policy_uuid) + print("The response of PoliciesApi->policies_geoip_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_geoip_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this GeoIP Policy. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_create** +> PasswordPolicy policies_password_create(password_policy_request) + +Password Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_policy import PasswordPolicy +from authentik_client.models.password_policy_request import PasswordPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + password_policy_request = authentik_client.PasswordPolicyRequest() # PasswordPolicyRequest | + + try: + api_response = api_instance.policies_password_create(password_policy_request) + print("The response of PoliciesApi->policies_password_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **password_policy_request** | [**PasswordPolicyRequest**](PasswordPolicyRequest.md)| | + +### Return type + +[**PasswordPolicy**](PasswordPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_destroy** +> policies_password_destroy(policy_uuid) + +Password Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Policy. + + try: + api_instance.policies_password_destroy(policy_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Policy. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_expiry_create** +> PasswordExpiryPolicy policies_password_expiry_create(password_expiry_policy_request) + +Password Expiry Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy +from authentik_client.models.password_expiry_policy_request import PasswordExpiryPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + password_expiry_policy_request = authentik_client.PasswordExpiryPolicyRequest() # PasswordExpiryPolicyRequest | + + try: + api_response = api_instance.policies_password_expiry_create(password_expiry_policy_request) + print("The response of PoliciesApi->policies_password_expiry_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_expiry_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **password_expiry_policy_request** | [**PasswordExpiryPolicyRequest**](PasswordExpiryPolicyRequest.md)| | + +### Return type + +[**PasswordExpiryPolicy**](PasswordExpiryPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_expiry_destroy** +> policies_password_expiry_destroy(policy_uuid) + +Password Expiry Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Expiry Policy. + + try: + api_instance.policies_password_expiry_destroy(policy_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_expiry_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Expiry Policy. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_expiry_list** +> PaginatedPasswordExpiryPolicyList policies_password_expiry_list(created=created, days=days, deny_only=deny_only, execution_logging=execution_logging, last_updated=last_updated, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, search=search) + +Password Expiry Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_password_expiry_policy_list import PaginatedPasswordExpiryPolicyList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + created = '2013-10-20T19:20:30+01:00' # datetime | (optional) + days = 56 # int | (optional) + deny_only = True # bool | (optional) + execution_logging = True # bool | (optional) + last_updated = '2013-10-20T19:20:30+01:00' # datetime | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.policies_password_expiry_list(created=created, days=days, deny_only=deny_only, execution_logging=execution_logging, last_updated=last_updated, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, search=search) + print("The response of PoliciesApi->policies_password_expiry_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_expiry_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **created** | **datetime**| | [optional] + **days** | **int**| | [optional] + **deny_only** | **bool**| | [optional] + **execution_logging** | **bool**| | [optional] + **last_updated** | **datetime**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **policy_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedPasswordExpiryPolicyList**](PaginatedPasswordExpiryPolicyList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_expiry_partial_update** +> PasswordExpiryPolicy policies_password_expiry_partial_update(policy_uuid, patched_password_expiry_policy_request=patched_password_expiry_policy_request) + +Password Expiry Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy +from authentik_client.models.patched_password_expiry_policy_request import PatchedPasswordExpiryPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Expiry Policy. + patched_password_expiry_policy_request = authentik_client.PatchedPasswordExpiryPolicyRequest() # PatchedPasswordExpiryPolicyRequest | (optional) + + try: + api_response = api_instance.policies_password_expiry_partial_update(policy_uuid, patched_password_expiry_policy_request=patched_password_expiry_policy_request) + print("The response of PoliciesApi->policies_password_expiry_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_expiry_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Expiry Policy. | + **patched_password_expiry_policy_request** | [**PatchedPasswordExpiryPolicyRequest**](PatchedPasswordExpiryPolicyRequest.md)| | [optional] + +### Return type + +[**PasswordExpiryPolicy**](PasswordExpiryPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_expiry_retrieve** +> PasswordExpiryPolicy policies_password_expiry_retrieve(policy_uuid) + +Password Expiry Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Expiry Policy. + + try: + api_response = api_instance.policies_password_expiry_retrieve(policy_uuid) + print("The response of PoliciesApi->policies_password_expiry_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_expiry_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Expiry Policy. | + +### Return type + +[**PasswordExpiryPolicy**](PasswordExpiryPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_expiry_update** +> PasswordExpiryPolicy policies_password_expiry_update(policy_uuid, password_expiry_policy_request) + +Password Expiry Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy +from authentik_client.models.password_expiry_policy_request import PasswordExpiryPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Expiry Policy. + password_expiry_policy_request = authentik_client.PasswordExpiryPolicyRequest() # PasswordExpiryPolicyRequest | + + try: + api_response = api_instance.policies_password_expiry_update(policy_uuid, password_expiry_policy_request) + print("The response of PoliciesApi->policies_password_expiry_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_expiry_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Expiry Policy. | + **password_expiry_policy_request** | [**PasswordExpiryPolicyRequest**](PasswordExpiryPolicyRequest.md)| | + +### Return type + +[**PasswordExpiryPolicy**](PasswordExpiryPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_expiry_used_by_list** +> List[UsedBy] policies_password_expiry_used_by_list(policy_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Expiry Policy. + + try: + api_response = api_instance.policies_password_expiry_used_by_list(policy_uuid) + print("The response of PoliciesApi->policies_password_expiry_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_expiry_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Expiry Policy. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_list** +> PaginatedPasswordPolicyList policies_password_list(amount_digits=amount_digits, amount_lowercase=amount_lowercase, amount_symbols=amount_symbols, amount_uppercase=amount_uppercase, check_have_i_been_pwned=check_have_i_been_pwned, check_static_rules=check_static_rules, check_zxcvbn=check_zxcvbn, created=created, error_message=error_message, execution_logging=execution_logging, hibp_allowed_count=hibp_allowed_count, last_updated=last_updated, length_min=length_min, name=name, ordering=ordering, page=page, page_size=page_size, password_field=password_field, policy_uuid=policy_uuid, search=search, symbol_charset=symbol_charset, zxcvbn_score_threshold=zxcvbn_score_threshold) + +Password Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_password_policy_list import PaginatedPasswordPolicyList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + amount_digits = 56 # int | (optional) + amount_lowercase = 56 # int | (optional) + amount_symbols = 56 # int | (optional) + amount_uppercase = 56 # int | (optional) + check_have_i_been_pwned = True # bool | (optional) + check_static_rules = True # bool | (optional) + check_zxcvbn = True # bool | (optional) + created = '2013-10-20T19:20:30+01:00' # datetime | (optional) + error_message = 'error_message_example' # str | (optional) + execution_logging = True # bool | (optional) + hibp_allowed_count = 56 # int | (optional) + last_updated = '2013-10-20T19:20:30+01:00' # datetime | (optional) + length_min = 56 # int | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + password_field = 'password_field_example' # str | (optional) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + symbol_charset = 'symbol_charset_example' # str | (optional) + zxcvbn_score_threshold = 56 # int | (optional) + + try: + api_response = api_instance.policies_password_list(amount_digits=amount_digits, amount_lowercase=amount_lowercase, amount_symbols=amount_symbols, amount_uppercase=amount_uppercase, check_have_i_been_pwned=check_have_i_been_pwned, check_static_rules=check_static_rules, check_zxcvbn=check_zxcvbn, created=created, error_message=error_message, execution_logging=execution_logging, hibp_allowed_count=hibp_allowed_count, last_updated=last_updated, length_min=length_min, name=name, ordering=ordering, page=page, page_size=page_size, password_field=password_field, policy_uuid=policy_uuid, search=search, symbol_charset=symbol_charset, zxcvbn_score_threshold=zxcvbn_score_threshold) + print("The response of PoliciesApi->policies_password_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **amount_digits** | **int**| | [optional] + **amount_lowercase** | **int**| | [optional] + **amount_symbols** | **int**| | [optional] + **amount_uppercase** | **int**| | [optional] + **check_have_i_been_pwned** | **bool**| | [optional] + **check_static_rules** | **bool**| | [optional] + **check_zxcvbn** | **bool**| | [optional] + **created** | **datetime**| | [optional] + **error_message** | **str**| | [optional] + **execution_logging** | **bool**| | [optional] + **hibp_allowed_count** | **int**| | [optional] + **last_updated** | **datetime**| | [optional] + **length_min** | **int**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **password_field** | **str**| | [optional] + **policy_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + **symbol_charset** | **str**| | [optional] + **zxcvbn_score_threshold** | **int**| | [optional] + +### Return type + +[**PaginatedPasswordPolicyList**](PaginatedPasswordPolicyList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_partial_update** +> PasswordPolicy policies_password_partial_update(policy_uuid, patched_password_policy_request=patched_password_policy_request) + +Password Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_policy import PasswordPolicy +from authentik_client.models.patched_password_policy_request import PatchedPasswordPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Policy. + patched_password_policy_request = authentik_client.PatchedPasswordPolicyRequest() # PatchedPasswordPolicyRequest | (optional) + + try: + api_response = api_instance.policies_password_partial_update(policy_uuid, patched_password_policy_request=patched_password_policy_request) + print("The response of PoliciesApi->policies_password_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Policy. | + **patched_password_policy_request** | [**PatchedPasswordPolicyRequest**](PatchedPasswordPolicyRequest.md)| | [optional] + +### Return type + +[**PasswordPolicy**](PasswordPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_retrieve** +> PasswordPolicy policies_password_retrieve(policy_uuid) + +Password Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_policy import PasswordPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Policy. + + try: + api_response = api_instance.policies_password_retrieve(policy_uuid) + print("The response of PoliciesApi->policies_password_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Policy. | + +### Return type + +[**PasswordPolicy**](PasswordPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_update** +> PasswordPolicy policies_password_update(policy_uuid, password_policy_request) + +Password Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_policy import PasswordPolicy +from authentik_client.models.password_policy_request import PasswordPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Policy. + password_policy_request = authentik_client.PasswordPolicyRequest() # PasswordPolicyRequest | + + try: + api_response = api_instance.policies_password_update(policy_uuid, password_policy_request) + print("The response of PoliciesApi->policies_password_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Policy. | + **password_policy_request** | [**PasswordPolicyRequest**](PasswordPolicyRequest.md)| | + +### Return type + +[**PasswordPolicy**](PasswordPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_password_used_by_list** +> List[UsedBy] policies_password_used_by_list(policy_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Policy. + + try: + api_response = api_instance.policies_password_used_by_list(policy_uuid) + print("The response of PoliciesApi->policies_password_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_password_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Policy. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_create** +> ReputationPolicy policies_reputation_create(reputation_policy_request) + +Reputation Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.reputation_policy import ReputationPolicy +from authentik_client.models.reputation_policy_request import ReputationPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + reputation_policy_request = authentik_client.ReputationPolicyRequest() # ReputationPolicyRequest | + + try: + api_response = api_instance.policies_reputation_create(reputation_policy_request) + print("The response of PoliciesApi->policies_reputation_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **reputation_policy_request** | [**ReputationPolicyRequest**](ReputationPolicyRequest.md)| | + +### Return type + +[**ReputationPolicy**](ReputationPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_destroy** +> policies_reputation_destroy(policy_uuid) + +Reputation Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Reputation Policy. + + try: + api_instance.policies_reputation_destroy(policy_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Reputation Policy. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_list** +> PaginatedReputationPolicyList policies_reputation_list(check_ip=check_ip, check_username=check_username, created=created, execution_logging=execution_logging, last_updated=last_updated, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, search=search, threshold=threshold) + +Reputation Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_reputation_policy_list import PaginatedReputationPolicyList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + check_ip = True # bool | (optional) + check_username = True # bool | (optional) + created = '2013-10-20T19:20:30+01:00' # datetime | (optional) + execution_logging = True # bool | (optional) + last_updated = '2013-10-20T19:20:30+01:00' # datetime | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + threshold = 56 # int | (optional) + + try: + api_response = api_instance.policies_reputation_list(check_ip=check_ip, check_username=check_username, created=created, execution_logging=execution_logging, last_updated=last_updated, name=name, ordering=ordering, page=page, page_size=page_size, policy_uuid=policy_uuid, search=search, threshold=threshold) + print("The response of PoliciesApi->policies_reputation_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **check_ip** | **bool**| | [optional] + **check_username** | **bool**| | [optional] + **created** | **datetime**| | [optional] + **execution_logging** | **bool**| | [optional] + **last_updated** | **datetime**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **policy_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + **threshold** | **int**| | [optional] + +### Return type + +[**PaginatedReputationPolicyList**](PaginatedReputationPolicyList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_partial_update** +> ReputationPolicy policies_reputation_partial_update(policy_uuid, patched_reputation_policy_request=patched_reputation_policy_request) + +Reputation Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_reputation_policy_request import PatchedReputationPolicyRequest +from authentik_client.models.reputation_policy import ReputationPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Reputation Policy. + patched_reputation_policy_request = authentik_client.PatchedReputationPolicyRequest() # PatchedReputationPolicyRequest | (optional) + + try: + api_response = api_instance.policies_reputation_partial_update(policy_uuid, patched_reputation_policy_request=patched_reputation_policy_request) + print("The response of PoliciesApi->policies_reputation_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Reputation Policy. | + **patched_reputation_policy_request** | [**PatchedReputationPolicyRequest**](PatchedReputationPolicyRequest.md)| | [optional] + +### Return type + +[**ReputationPolicy**](ReputationPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_retrieve** +> ReputationPolicy policies_reputation_retrieve(policy_uuid) + +Reputation Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.reputation_policy import ReputationPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Reputation Policy. + + try: + api_response = api_instance.policies_reputation_retrieve(policy_uuid) + print("The response of PoliciesApi->policies_reputation_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Reputation Policy. | + +### Return type + +[**ReputationPolicy**](ReputationPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_scores_destroy** +> policies_reputation_scores_destroy(reputation_uuid) + +Reputation Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + reputation_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Reputation Score. + + try: + api_instance.policies_reputation_scores_destroy(reputation_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_scores_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **reputation_uuid** | **UUID**| A UUID string identifying this Reputation Score. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_scores_list** +> PaginatedReputationList policies_reputation_scores_list(identifier=identifier, identifier_in=identifier_in, ip=ip, ordering=ordering, page=page, page_size=page_size, score=score, search=search) + +Reputation Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_reputation_list import PaginatedReputationList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + identifier = 'identifier_example' # str | (optional) + identifier_in = ['identifier_in_example'] # List[str] | Multiple values may be separated by commas. (optional) + ip = 'ip_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + score = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.policies_reputation_scores_list(identifier=identifier, identifier_in=identifier_in, ip=ip, ordering=ordering, page=page, page_size=page_size, score=score, search=search) + print("The response of PoliciesApi->policies_reputation_scores_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_scores_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identifier** | **str**| | [optional] + **identifier_in** | [**List[str]**](str.md)| Multiple values may be separated by commas. | [optional] + **ip** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **score** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedReputationList**](PaginatedReputationList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_scores_retrieve** +> Reputation policies_reputation_scores_retrieve(reputation_uuid) + +Reputation Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.reputation import Reputation +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + reputation_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Reputation Score. + + try: + api_response = api_instance.policies_reputation_scores_retrieve(reputation_uuid) + print("The response of PoliciesApi->policies_reputation_scores_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_scores_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **reputation_uuid** | **UUID**| A UUID string identifying this Reputation Score. | + +### Return type + +[**Reputation**](Reputation.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_scores_used_by_list** +> List[UsedBy] policies_reputation_scores_used_by_list(reputation_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + reputation_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Reputation Score. + + try: + api_response = api_instance.policies_reputation_scores_used_by_list(reputation_uuid) + print("The response of PoliciesApi->policies_reputation_scores_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_scores_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **reputation_uuid** | **UUID**| A UUID string identifying this Reputation Score. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_update** +> ReputationPolicy policies_reputation_update(policy_uuid, reputation_policy_request) + +Reputation Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.reputation_policy import ReputationPolicy +from authentik_client.models.reputation_policy_request import ReputationPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Reputation Policy. + reputation_policy_request = authentik_client.ReputationPolicyRequest() # ReputationPolicyRequest | + + try: + api_response = api_instance.policies_reputation_update(policy_uuid, reputation_policy_request) + print("The response of PoliciesApi->policies_reputation_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Reputation Policy. | + **reputation_policy_request** | [**ReputationPolicyRequest**](ReputationPolicyRequest.md)| | + +### Return type + +[**ReputationPolicy**](ReputationPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_reputation_used_by_list** +> List[UsedBy] policies_reputation_used_by_list(policy_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Reputation Policy. + + try: + api_response = api_instance.policies_reputation_used_by_list(policy_uuid) + print("The response of PoliciesApi->policies_reputation_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_reputation_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Reputation Policy. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_unique_password_create** +> UniquePasswordPolicy policies_unique_password_create(unique_password_policy_request) + +Password Uniqueness Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.unique_password_policy import UniquePasswordPolicy +from authentik_client.models.unique_password_policy_request import UniquePasswordPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + unique_password_policy_request = authentik_client.UniquePasswordPolicyRequest() # UniquePasswordPolicyRequest | + + try: + api_response = api_instance.policies_unique_password_create(unique_password_policy_request) + print("The response of PoliciesApi->policies_unique_password_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_unique_password_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **unique_password_policy_request** | [**UniquePasswordPolicyRequest**](UniquePasswordPolicyRequest.md)| | + +### Return type + +[**UniquePasswordPolicy**](UniquePasswordPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_unique_password_destroy** +> policies_unique_password_destroy(policy_uuid) + +Password Uniqueness Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Uniqueness Policy. + + try: + api_instance.policies_unique_password_destroy(policy_uuid) + except Exception as e: + print("Exception when calling PoliciesApi->policies_unique_password_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Uniqueness Policy. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_unique_password_list** +> PaginatedUniquePasswordPolicyList policies_unique_password_list(created=created, execution_logging=execution_logging, last_updated=last_updated, name=name, num_historical_passwords=num_historical_passwords, ordering=ordering, page=page, page_size=page_size, password_field=password_field, policy_uuid=policy_uuid, search=search) + +Password Uniqueness Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_unique_password_policy_list import PaginatedUniquePasswordPolicyList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + created = '2013-10-20T19:20:30+01:00' # datetime | (optional) + execution_logging = True # bool | (optional) + last_updated = '2013-10-20T19:20:30+01:00' # datetime | (optional) + name = 'name_example' # str | (optional) + num_historical_passwords = 56 # int | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + password_field = 'password_field_example' # str | (optional) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.policies_unique_password_list(created=created, execution_logging=execution_logging, last_updated=last_updated, name=name, num_historical_passwords=num_historical_passwords, ordering=ordering, page=page, page_size=page_size, password_field=password_field, policy_uuid=policy_uuid, search=search) + print("The response of PoliciesApi->policies_unique_password_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_unique_password_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **created** | **datetime**| | [optional] + **execution_logging** | **bool**| | [optional] + **last_updated** | **datetime**| | [optional] + **name** | **str**| | [optional] + **num_historical_passwords** | **int**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **password_field** | **str**| | [optional] + **policy_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedUniquePasswordPolicyList**](PaginatedUniquePasswordPolicyList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_unique_password_partial_update** +> UniquePasswordPolicy policies_unique_password_partial_update(policy_uuid, patched_unique_password_policy_request=patched_unique_password_policy_request) + +Password Uniqueness Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_unique_password_policy_request import PatchedUniquePasswordPolicyRequest +from authentik_client.models.unique_password_policy import UniquePasswordPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Uniqueness Policy. + patched_unique_password_policy_request = authentik_client.PatchedUniquePasswordPolicyRequest() # PatchedUniquePasswordPolicyRequest | (optional) + + try: + api_response = api_instance.policies_unique_password_partial_update(policy_uuid, patched_unique_password_policy_request=patched_unique_password_policy_request) + print("The response of PoliciesApi->policies_unique_password_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_unique_password_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Uniqueness Policy. | + **patched_unique_password_policy_request** | [**PatchedUniquePasswordPolicyRequest**](PatchedUniquePasswordPolicyRequest.md)| | [optional] + +### Return type + +[**UniquePasswordPolicy**](UniquePasswordPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_unique_password_retrieve** +> UniquePasswordPolicy policies_unique_password_retrieve(policy_uuid) + +Password Uniqueness Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.unique_password_policy import UniquePasswordPolicy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Uniqueness Policy. + + try: + api_response = api_instance.policies_unique_password_retrieve(policy_uuid) + print("The response of PoliciesApi->policies_unique_password_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_unique_password_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Uniqueness Policy. | + +### Return type + +[**UniquePasswordPolicy**](UniquePasswordPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_unique_password_update** +> UniquePasswordPolicy policies_unique_password_update(policy_uuid, unique_password_policy_request) + +Password Uniqueness Policy Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.unique_password_policy import UniquePasswordPolicy +from authentik_client.models.unique_password_policy_request import UniquePasswordPolicyRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Uniqueness Policy. + unique_password_policy_request = authentik_client.UniquePasswordPolicyRequest() # UniquePasswordPolicyRequest | + + try: + api_response = api_instance.policies_unique_password_update(policy_uuid, unique_password_policy_request) + print("The response of PoliciesApi->policies_unique_password_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_unique_password_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Uniqueness Policy. | + **unique_password_policy_request** | [**UniquePasswordPolicyRequest**](UniquePasswordPolicyRequest.md)| | + +### Return type + +[**UniquePasswordPolicy**](UniquePasswordPolicy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **policies_unique_password_used_by_list** +> List[UsedBy] policies_unique_password_used_by_list(policy_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PoliciesApi(api_client) + policy_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Uniqueness Policy. + + try: + api_response = api_instance.policies_unique_password_used_by_list(policy_uuid) + print("The response of PoliciesApi->policies_unique_password_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PoliciesApi->policies_unique_password_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policy_uuid** | **UUID**| A UUID string identifying this Password Uniqueness Policy. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/Policy.md b/docs/Policy.md new file mode 100644 index 000000000..df7fa3983 --- /dev/null +++ b/docs/Policy.md @@ -0,0 +1,37 @@ +# Policy + +Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**bound_to** | **int** | Return objects policy is bound to | [readonly] + +## Example + +```python +from authentik_client.models.policy import Policy + +# TODO update the JSON string below +json = "{}" +# create an instance of Policy from a JSON string +policy_instance = Policy.from_json(json) +# print the JSON string representation of the object +print(Policy.to_json()) + +# convert the object into a dict +policy_dict = policy_instance.to_dict() +# create an instance of Policy from a dict +policy_from_dict = Policy.from_dict(policy_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PolicyBinding.md b/docs/PolicyBinding.md new file mode 100644 index 000000000..505816133 --- /dev/null +++ b/docs/PolicyBinding.md @@ -0,0 +1,42 @@ +# PolicyBinding + +PolicyBinding Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**policy** | **UUID** | | [optional] +**group** | **UUID** | | [optional] +**user** | **int** | | [optional] +**policy_obj** | [**Policy**](Policy.md) | | [readonly] +**group_obj** | [**PartialGroup**](PartialGroup.md) | | [readonly] +**user_obj** | [**PartialUser**](PartialUser.md) | | [readonly] +**target** | **UUID** | | +**negate** | **bool** | Negates the outcome of the policy. Messages are unaffected. | [optional] +**enabled** | **bool** | | [optional] +**order** | **int** | | +**timeout** | **int** | Timeout after which Policy execution is terminated. | [optional] +**failure_result** | **bool** | Result if the Policy execution fails. | [optional] + +## Example + +```python +from authentik_client.models.policy_binding import PolicyBinding + +# TODO update the JSON string below +json = "{}" +# create an instance of PolicyBinding from a JSON string +policy_binding_instance = PolicyBinding.from_json(json) +# print the JSON string representation of the object +print(PolicyBinding.to_json()) + +# convert the object into a dict +policy_binding_dict = policy_binding_instance.to_dict() +# create an instance of PolicyBinding from a dict +policy_binding_from_dict = PolicyBinding.from_dict(policy_binding_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PolicyBindingRequest.md b/docs/PolicyBindingRequest.md new file mode 100644 index 000000000..d06753181 --- /dev/null +++ b/docs/PolicyBindingRequest.md @@ -0,0 +1,38 @@ +# PolicyBindingRequest + +PolicyBinding Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**policy** | **UUID** | | [optional] +**group** | **UUID** | | [optional] +**user** | **int** | | [optional] +**target** | **UUID** | | +**negate** | **bool** | Negates the outcome of the policy. Messages are unaffected. | [optional] +**enabled** | **bool** | | [optional] +**order** | **int** | | +**timeout** | **int** | Timeout after which Policy execution is terminated. | [optional] +**failure_result** | **bool** | Result if the Policy execution fails. | [optional] + +## Example + +```python +from authentik_client.models.policy_binding_request import PolicyBindingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PolicyBindingRequest from a JSON string +policy_binding_request_instance = PolicyBindingRequest.from_json(json) +# print the JSON string representation of the object +print(PolicyBindingRequest.to_json()) + +# convert the object into a dict +policy_binding_request_dict = policy_binding_request_instance.to_dict() +# create an instance of PolicyBindingRequest from a dict +policy_binding_request_from_dict = PolicyBindingRequest.from_dict(policy_binding_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PolicyEngineMode.md b/docs/PolicyEngineMode.md new file mode 100644 index 000000000..cba5a4170 --- /dev/null +++ b/docs/PolicyEngineMode.md @@ -0,0 +1,12 @@ +# PolicyEngineMode + + +## Enum + +* `ALL` (value: `'all'`) + +* `ANY` (value: `'any'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PolicyTestRequest.md b/docs/PolicyTestRequest.md new file mode 100644 index 000000000..4d1d9e5e6 --- /dev/null +++ b/docs/PolicyTestRequest.md @@ -0,0 +1,31 @@ +# PolicyTestRequest + +Test policy execution for a user with context + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user** | **int** | | +**context** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.policy_test_request import PolicyTestRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PolicyTestRequest from a JSON string +policy_test_request_instance = PolicyTestRequest.from_json(json) +# print the JSON string representation of the object +print(PolicyTestRequest.to_json()) + +# convert the object into a dict +policy_test_request_dict = policy_test_request_instance.to_dict() +# create an instance of PolicyTestRequest from a dict +policy_test_request_from_dict = PolicyTestRequest.from_dict(policy_test_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PolicyTestResult.md b/docs/PolicyTestResult.md new file mode 100644 index 000000000..ae2a6108d --- /dev/null +++ b/docs/PolicyTestResult.md @@ -0,0 +1,32 @@ +# PolicyTestResult + +result of a policy test + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**passing** | **bool** | | +**messages** | **List[str]** | | [readonly] +**log_messages** | [**List[LogEvent]**](LogEvent.md) | | [readonly] + +## Example + +```python +from authentik_client.models.policy_test_result import PolicyTestResult + +# TODO update the JSON string below +json = "{}" +# create an instance of PolicyTestResult from a JSON string +policy_test_result_instance = PolicyTestResult.from_json(json) +# print the JSON string representation of the object +print(PolicyTestResult.to_json()) + +# convert the object into a dict +policy_test_result_dict = policy_test_result_instance.to_dict() +# create an instance of PolicyTestResult from a dict +policy_test_result_from_dict = PolicyTestResult.from_dict(policy_test_result_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Process.md b/docs/Process.md new file mode 100644 index 000000000..f41a8b285 --- /dev/null +++ b/docs/Process.md @@ -0,0 +1,31 @@ +# Process + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | +**name** | **str** | | +**user** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.process import Process + +# TODO update the JSON string below +json = "{}" +# create an instance of Process from a JSON string +process_instance = Process.from_json(json) +# print the JSON string representation of the object +print(Process.to_json()) + +# convert the object into a dict +process_dict = process_instance.to_dict() +# create an instance of Process from a dict +process_from_dict = Process.from_dict(process_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ProcessRequest.md b/docs/ProcessRequest.md new file mode 100644 index 000000000..085cf8444 --- /dev/null +++ b/docs/ProcessRequest.md @@ -0,0 +1,31 @@ +# ProcessRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | +**name** | **str** | | +**user** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.process_request import ProcessRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ProcessRequest from a JSON string +process_request_instance = ProcessRequest.from_json(json) +# print the JSON string representation of the object +print(ProcessRequest.to_json()) + +# convert the object into a dict +process_request_dict = process_request_instance.to_dict() +# create an instance of ProcessRequest from a dict +process_request_from_dict = ProcessRequest.from_dict(process_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Prompt.md b/docs/Prompt.md new file mode 100644 index 000000000..bea35a153 --- /dev/null +++ b/docs/Prompt.md @@ -0,0 +1,42 @@ +# Prompt + +Prompt Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**field_key** | **str** | Name of the form field, also used to store the value | +**label** | **str** | | +**type** | [**PromptTypeEnum**](PromptTypeEnum.md) | | +**required** | **bool** | | [optional] +**placeholder** | **str** | Optionally provide a short hint that describes the expected input value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple choices. | [optional] +**initial_value** | **str** | Optionally pre-fill the input with an initial value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple default choices. | [optional] +**order** | **int** | | [optional] +**prompt_stages_obj** | [**List[PromptStage]**](PromptStage.md) | | [readonly] +**sub_text** | **str** | | [optional] +**placeholder_expression** | **bool** | | [optional] +**initial_value_expression** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.prompt import Prompt + +# TODO update the JSON string below +json = "{}" +# create an instance of Prompt from a JSON string +prompt_instance = Prompt.from_json(json) +# print the JSON string representation of the object +print(Prompt.to_json()) + +# convert the object into a dict +prompt_dict = prompt_instance.to_dict() +# create an instance of Prompt from a dict +prompt_from_dict = Prompt.from_dict(prompt_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PromptChallenge.md b/docs/PromptChallenge.md new file mode 100644 index 000000000..25d428e3c --- /dev/null +++ b/docs/PromptChallenge.md @@ -0,0 +1,33 @@ +# PromptChallenge + +Initial challenge being sent, define fields + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-prompt'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**fields** | [**List[StagePrompt]**](StagePrompt.md) | | + +## Example + +```python +from authentik_client.models.prompt_challenge import PromptChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of PromptChallenge from a JSON string +prompt_challenge_instance = PromptChallenge.from_json(json) +# print the JSON string representation of the object +print(PromptChallenge.to_json()) + +# convert the object into a dict +prompt_challenge_dict = prompt_challenge_instance.to_dict() +# create an instance of PromptChallenge from a dict +prompt_challenge_from_dict = PromptChallenge.from_dict(prompt_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PromptChallengeResponseRequest.md b/docs/PromptChallengeResponseRequest.md new file mode 100644 index 000000000..9cfec474d --- /dev/null +++ b/docs/PromptChallengeResponseRequest.md @@ -0,0 +1,30 @@ +# PromptChallengeResponseRequest + +Validate response, fields are dynamically created based on the stage + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-prompt'] + +## Example + +```python +from authentik_client.models.prompt_challenge_response_request import PromptChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PromptChallengeResponseRequest from a JSON string +prompt_challenge_response_request_instance = PromptChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(PromptChallengeResponseRequest.to_json()) + +# convert the object into a dict +prompt_challenge_response_request_dict = prompt_challenge_response_request_instance.to_dict() +# create an instance of PromptChallengeResponseRequest from a dict +prompt_challenge_response_request_from_dict = PromptChallengeResponseRequest.from_dict(prompt_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PromptChoice.md b/docs/PromptChoice.md new file mode 100644 index 000000000..4b2c6fe04 --- /dev/null +++ b/docs/PromptChoice.md @@ -0,0 +1,31 @@ +# PromptChoice + +Serializer for a single Choice field + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**value** | **str** | | +**label** | **str** | | + +## Example + +```python +from authentik_client.models.prompt_choice import PromptChoice + +# TODO update the JSON string below +json = "{}" +# create an instance of PromptChoice from a JSON string +prompt_choice_instance = PromptChoice.from_json(json) +# print the JSON string representation of the object +print(PromptChoice.to_json()) + +# convert the object into a dict +prompt_choice_dict = prompt_choice_instance.to_dict() +# create an instance of PromptChoice from a dict +prompt_choice_from_dict = PromptChoice.from_dict(prompt_choice_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PromptRequest.md b/docs/PromptRequest.md new file mode 100644 index 000000000..2a8ac30e5 --- /dev/null +++ b/docs/PromptRequest.md @@ -0,0 +1,40 @@ +# PromptRequest + +Prompt Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**field_key** | **str** | Name of the form field, also used to store the value | +**label** | **str** | | +**type** | [**PromptTypeEnum**](PromptTypeEnum.md) | | +**required** | **bool** | | [optional] +**placeholder** | **str** | Optionally provide a short hint that describes the expected input value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple choices. | [optional] +**initial_value** | **str** | Optionally pre-fill the input with an initial value. When creating a fixed choice field, enable interpreting as expression and return a list to return multiple default choices. | [optional] +**order** | **int** | | [optional] +**sub_text** | **str** | | [optional] +**placeholder_expression** | **bool** | | [optional] +**initial_value_expression** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.prompt_request import PromptRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PromptRequest from a JSON string +prompt_request_instance = PromptRequest.from_json(json) +# print the JSON string representation of the object +print(PromptRequest.to_json()) + +# convert the object into a dict +prompt_request_dict = prompt_request_instance.to_dict() +# create an instance of PromptRequest from a dict +prompt_request_from_dict = PromptRequest.from_dict(prompt_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PromptStage.md b/docs/PromptStage.md new file mode 100644 index 000000000..82cfe51e9 --- /dev/null +++ b/docs/PromptStage.md @@ -0,0 +1,38 @@ +# PromptStage + +PromptStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**fields** | **List[UUID]** | | +**validation_policies** | **List[UUID]** | | [optional] + +## Example + +```python +from authentik_client.models.prompt_stage import PromptStage + +# TODO update the JSON string below +json = "{}" +# create an instance of PromptStage from a JSON string +prompt_stage_instance = PromptStage.from_json(json) +# print the JSON string representation of the object +print(PromptStage.to_json()) + +# convert the object into a dict +prompt_stage_dict = prompt_stage_instance.to_dict() +# create an instance of PromptStage from a dict +prompt_stage_from_dict = PromptStage.from_dict(prompt_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PromptStageRequest.md b/docs/PromptStageRequest.md new file mode 100644 index 000000000..c86995bc4 --- /dev/null +++ b/docs/PromptStageRequest.md @@ -0,0 +1,32 @@ +# PromptStageRequest + +PromptStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**fields** | **List[UUID]** | | +**validation_policies** | **List[UUID]** | | [optional] + +## Example + +```python +from authentik_client.models.prompt_stage_request import PromptStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PromptStageRequest from a JSON string +prompt_stage_request_instance = PromptStageRequest.from_json(json) +# print the JSON string representation of the object +print(PromptStageRequest.to_json()) + +# convert the object into a dict +prompt_stage_request_dict = prompt_stage_request_instance.to_dict() +# create an instance of PromptStageRequest from a dict +prompt_stage_request_from_dict = PromptStageRequest.from_dict(prompt_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PromptTypeEnum.md b/docs/PromptTypeEnum.md new file mode 100644 index 000000000..3b30130e1 --- /dev/null +++ b/docs/PromptTypeEnum.md @@ -0,0 +1,50 @@ +# PromptTypeEnum + + +## Enum + +* `TEXT` (value: `'text'`) + +* `TEXT_AREA` (value: `'text_area'`) + +* `TEXT_READ_ONLY` (value: `'text_read_only'`) + +* `TEXT_AREA_READ_ONLY` (value: `'text_area_read_only'`) + +* `USERNAME` (value: `'username'`) + +* `EMAIL` (value: `'email'`) + +* `PASSWORD` (value: `'password'`) + +* `NUMBER` (value: `'number'`) + +* `CHECKBOX` (value: `'checkbox'`) + +* `RADIO_MINUS_BUTTON_MINUS_GROUP` (value: `'radio-button-group'`) + +* `DROPDOWN` (value: `'dropdown'`) + +* `DATE` (value: `'date'`) + +* `DATE_MINUS_TIME` (value: `'date-time'`) + +* `FILE` (value: `'file'`) + +* `SEPARATOR` (value: `'separator'`) + +* `HIDDEN` (value: `'hidden'`) + +* `STATIC` (value: `'static'`) + +* `ALERT_INFO` (value: `'alert_info'`) + +* `ALERT_WARNING` (value: `'alert_warning'`) + +* `ALERT_DANGER` (value: `'alert_danger'`) + +* `AK_MINUS_LOCALE` (value: `'ak-locale'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PropertyMapping.md b/docs/PropertyMapping.md new file mode 100644 index 000000000..5f64ac2a6 --- /dev/null +++ b/docs/PropertyMapping.md @@ -0,0 +1,37 @@ +# PropertyMapping + +PropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.property_mapping import PropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of PropertyMapping from a JSON string +property_mapping_instance = PropertyMapping.from_json(json) +# print the JSON string representation of the object +print(PropertyMapping.to_json()) + +# convert the object into a dict +property_mapping_dict = property_mapping_instance.to_dict() +# create an instance of PropertyMapping from a dict +property_mapping_from_dict = PropertyMapping.from_dict(property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PropertyMappingPreview.md b/docs/PropertyMappingPreview.md new file mode 100644 index 000000000..9662bd8a7 --- /dev/null +++ b/docs/PropertyMappingPreview.md @@ -0,0 +1,30 @@ +# PropertyMappingPreview + +Preview how the current user is mapped via the property mappings selected in a provider + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**preview** | **Dict[str, object]** | | [readonly] + +## Example + +```python +from authentik_client.models.property_mapping_preview import PropertyMappingPreview + +# TODO update the JSON string below +json = "{}" +# create an instance of PropertyMappingPreview from a JSON string +property_mapping_preview_instance = PropertyMappingPreview.from_json(json) +# print the JSON string representation of the object +print(PropertyMappingPreview.to_json()) + +# convert the object into a dict +property_mapping_preview_dict = property_mapping_preview_instance.to_dict() +# create an instance of PropertyMappingPreview from a dict +property_mapping_preview_from_dict = PropertyMappingPreview.from_dict(property_mapping_preview_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PropertyMappingTestRequest.md b/docs/PropertyMappingTestRequest.md new file mode 100644 index 000000000..02aab4ce4 --- /dev/null +++ b/docs/PropertyMappingTestRequest.md @@ -0,0 +1,32 @@ +# PropertyMappingTestRequest + +Test property mapping execution for a user/group with context + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user** | **int** | | [optional] +**context** | **Dict[str, object]** | | [optional] +**group** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.property_mapping_test_request import PropertyMappingTestRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of PropertyMappingTestRequest from a JSON string +property_mapping_test_request_instance = PropertyMappingTestRequest.from_json(json) +# print the JSON string representation of the object +print(PropertyMappingTestRequest.to_json()) + +# convert the object into a dict +property_mapping_test_request_dict = property_mapping_test_request_instance.to_dict() +# create an instance of PropertyMappingTestRequest from a dict +property_mapping_test_request_from_dict = PropertyMappingTestRequest.from_dict(property_mapping_test_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PropertyMappingTestResult.md b/docs/PropertyMappingTestResult.md new file mode 100644 index 000000000..43cefdb48 --- /dev/null +++ b/docs/PropertyMappingTestResult.md @@ -0,0 +1,31 @@ +# PropertyMappingTestResult + +Result of a Property-mapping test + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**result** | **str** | | [readonly] +**successful** | **bool** | | [readonly] + +## Example + +```python +from authentik_client.models.property_mapping_test_result import PropertyMappingTestResult + +# TODO update the JSON string below +json = "{}" +# create an instance of PropertyMappingTestResult from a JSON string +property_mapping_test_result_instance = PropertyMappingTestResult.from_json(json) +# print the JSON string representation of the object +print(PropertyMappingTestResult.to_json()) + +# convert the object into a dict +property_mapping_test_result_dict = property_mapping_test_result_instance.to_dict() +# create an instance of PropertyMappingTestResult from a dict +property_mapping_test_result_from_dict = PropertyMappingTestResult.from_dict(property_mapping_test_result_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/PropertymappingsApi.md b/docs/PropertymappingsApi.md new file mode 100644 index 000000000..aa6214228 --- /dev/null +++ b/docs/PropertymappingsApi.md @@ -0,0 +1,8920 @@ +# authentik_client.PropertymappingsApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**propertymappings_all_destroy**](PropertymappingsApi.md#propertymappings_all_destroy) | **DELETE** /propertymappings/all/{pm_uuid}/ | +[**propertymappings_all_list**](PropertymappingsApi.md#propertymappings_all_list) | **GET** /propertymappings/all/ | +[**propertymappings_all_retrieve**](PropertymappingsApi.md#propertymappings_all_retrieve) | **GET** /propertymappings/all/{pm_uuid}/ | +[**propertymappings_all_test_create**](PropertymappingsApi.md#propertymappings_all_test_create) | **POST** /propertymappings/all/{pm_uuid}/test/ | +[**propertymappings_all_types_list**](PropertymappingsApi.md#propertymappings_all_types_list) | **GET** /propertymappings/all/types/ | +[**propertymappings_all_used_by_list**](PropertymappingsApi.md#propertymappings_all_used_by_list) | **GET** /propertymappings/all/{pm_uuid}/used_by/ | +[**propertymappings_notification_create**](PropertymappingsApi.md#propertymappings_notification_create) | **POST** /propertymappings/notification/ | +[**propertymappings_notification_destroy**](PropertymappingsApi.md#propertymappings_notification_destroy) | **DELETE** /propertymappings/notification/{pm_uuid}/ | +[**propertymappings_notification_list**](PropertymappingsApi.md#propertymappings_notification_list) | **GET** /propertymappings/notification/ | +[**propertymappings_notification_partial_update**](PropertymappingsApi.md#propertymappings_notification_partial_update) | **PATCH** /propertymappings/notification/{pm_uuid}/ | +[**propertymappings_notification_retrieve**](PropertymappingsApi.md#propertymappings_notification_retrieve) | **GET** /propertymappings/notification/{pm_uuid}/ | +[**propertymappings_notification_update**](PropertymappingsApi.md#propertymappings_notification_update) | **PUT** /propertymappings/notification/{pm_uuid}/ | +[**propertymappings_notification_used_by_list**](PropertymappingsApi.md#propertymappings_notification_used_by_list) | **GET** /propertymappings/notification/{pm_uuid}/used_by/ | +[**propertymappings_provider_google_workspace_create**](PropertymappingsApi.md#propertymappings_provider_google_workspace_create) | **POST** /propertymappings/provider/google_workspace/ | +[**propertymappings_provider_google_workspace_destroy**](PropertymappingsApi.md#propertymappings_provider_google_workspace_destroy) | **DELETE** /propertymappings/provider/google_workspace/{pm_uuid}/ | +[**propertymappings_provider_google_workspace_list**](PropertymappingsApi.md#propertymappings_provider_google_workspace_list) | **GET** /propertymappings/provider/google_workspace/ | +[**propertymappings_provider_google_workspace_partial_update**](PropertymappingsApi.md#propertymappings_provider_google_workspace_partial_update) | **PATCH** /propertymappings/provider/google_workspace/{pm_uuid}/ | +[**propertymappings_provider_google_workspace_retrieve**](PropertymappingsApi.md#propertymappings_provider_google_workspace_retrieve) | **GET** /propertymappings/provider/google_workspace/{pm_uuid}/ | +[**propertymappings_provider_google_workspace_update**](PropertymappingsApi.md#propertymappings_provider_google_workspace_update) | **PUT** /propertymappings/provider/google_workspace/{pm_uuid}/ | +[**propertymappings_provider_google_workspace_used_by_list**](PropertymappingsApi.md#propertymappings_provider_google_workspace_used_by_list) | **GET** /propertymappings/provider/google_workspace/{pm_uuid}/used_by/ | +[**propertymappings_provider_microsoft_entra_create**](PropertymappingsApi.md#propertymappings_provider_microsoft_entra_create) | **POST** /propertymappings/provider/microsoft_entra/ | +[**propertymappings_provider_microsoft_entra_destroy**](PropertymappingsApi.md#propertymappings_provider_microsoft_entra_destroy) | **DELETE** /propertymappings/provider/microsoft_entra/{pm_uuid}/ | +[**propertymappings_provider_microsoft_entra_list**](PropertymappingsApi.md#propertymappings_provider_microsoft_entra_list) | **GET** /propertymappings/provider/microsoft_entra/ | +[**propertymappings_provider_microsoft_entra_partial_update**](PropertymappingsApi.md#propertymappings_provider_microsoft_entra_partial_update) | **PATCH** /propertymappings/provider/microsoft_entra/{pm_uuid}/ | +[**propertymappings_provider_microsoft_entra_retrieve**](PropertymappingsApi.md#propertymappings_provider_microsoft_entra_retrieve) | **GET** /propertymappings/provider/microsoft_entra/{pm_uuid}/ | +[**propertymappings_provider_microsoft_entra_update**](PropertymappingsApi.md#propertymappings_provider_microsoft_entra_update) | **PUT** /propertymappings/provider/microsoft_entra/{pm_uuid}/ | +[**propertymappings_provider_microsoft_entra_used_by_list**](PropertymappingsApi.md#propertymappings_provider_microsoft_entra_used_by_list) | **GET** /propertymappings/provider/microsoft_entra/{pm_uuid}/used_by/ | +[**propertymappings_provider_rac_create**](PropertymappingsApi.md#propertymappings_provider_rac_create) | **POST** /propertymappings/provider/rac/ | +[**propertymappings_provider_rac_destroy**](PropertymappingsApi.md#propertymappings_provider_rac_destroy) | **DELETE** /propertymappings/provider/rac/{pm_uuid}/ | +[**propertymappings_provider_rac_list**](PropertymappingsApi.md#propertymappings_provider_rac_list) | **GET** /propertymappings/provider/rac/ | +[**propertymappings_provider_rac_partial_update**](PropertymappingsApi.md#propertymappings_provider_rac_partial_update) | **PATCH** /propertymappings/provider/rac/{pm_uuid}/ | +[**propertymappings_provider_rac_retrieve**](PropertymappingsApi.md#propertymappings_provider_rac_retrieve) | **GET** /propertymappings/provider/rac/{pm_uuid}/ | +[**propertymappings_provider_rac_update**](PropertymappingsApi.md#propertymappings_provider_rac_update) | **PUT** /propertymappings/provider/rac/{pm_uuid}/ | +[**propertymappings_provider_rac_used_by_list**](PropertymappingsApi.md#propertymappings_provider_rac_used_by_list) | **GET** /propertymappings/provider/rac/{pm_uuid}/used_by/ | +[**propertymappings_provider_radius_create**](PropertymappingsApi.md#propertymappings_provider_radius_create) | **POST** /propertymappings/provider/radius/ | +[**propertymappings_provider_radius_destroy**](PropertymappingsApi.md#propertymappings_provider_radius_destroy) | **DELETE** /propertymappings/provider/radius/{pm_uuid}/ | +[**propertymappings_provider_radius_list**](PropertymappingsApi.md#propertymappings_provider_radius_list) | **GET** /propertymappings/provider/radius/ | +[**propertymappings_provider_radius_partial_update**](PropertymappingsApi.md#propertymappings_provider_radius_partial_update) | **PATCH** /propertymappings/provider/radius/{pm_uuid}/ | +[**propertymappings_provider_radius_retrieve**](PropertymappingsApi.md#propertymappings_provider_radius_retrieve) | **GET** /propertymappings/provider/radius/{pm_uuid}/ | +[**propertymappings_provider_radius_update**](PropertymappingsApi.md#propertymappings_provider_radius_update) | **PUT** /propertymappings/provider/radius/{pm_uuid}/ | +[**propertymappings_provider_radius_used_by_list**](PropertymappingsApi.md#propertymappings_provider_radius_used_by_list) | **GET** /propertymappings/provider/radius/{pm_uuid}/used_by/ | +[**propertymappings_provider_saml_create**](PropertymappingsApi.md#propertymappings_provider_saml_create) | **POST** /propertymappings/provider/saml/ | +[**propertymappings_provider_saml_destroy**](PropertymappingsApi.md#propertymappings_provider_saml_destroy) | **DELETE** /propertymappings/provider/saml/{pm_uuid}/ | +[**propertymappings_provider_saml_list**](PropertymappingsApi.md#propertymappings_provider_saml_list) | **GET** /propertymappings/provider/saml/ | +[**propertymappings_provider_saml_partial_update**](PropertymappingsApi.md#propertymappings_provider_saml_partial_update) | **PATCH** /propertymappings/provider/saml/{pm_uuid}/ | +[**propertymappings_provider_saml_retrieve**](PropertymappingsApi.md#propertymappings_provider_saml_retrieve) | **GET** /propertymappings/provider/saml/{pm_uuid}/ | +[**propertymappings_provider_saml_update**](PropertymappingsApi.md#propertymappings_provider_saml_update) | **PUT** /propertymappings/provider/saml/{pm_uuid}/ | +[**propertymappings_provider_saml_used_by_list**](PropertymappingsApi.md#propertymappings_provider_saml_used_by_list) | **GET** /propertymappings/provider/saml/{pm_uuid}/used_by/ | +[**propertymappings_provider_scim_create**](PropertymappingsApi.md#propertymappings_provider_scim_create) | **POST** /propertymappings/provider/scim/ | +[**propertymappings_provider_scim_destroy**](PropertymappingsApi.md#propertymappings_provider_scim_destroy) | **DELETE** /propertymappings/provider/scim/{pm_uuid}/ | +[**propertymappings_provider_scim_list**](PropertymappingsApi.md#propertymappings_provider_scim_list) | **GET** /propertymappings/provider/scim/ | +[**propertymappings_provider_scim_partial_update**](PropertymappingsApi.md#propertymappings_provider_scim_partial_update) | **PATCH** /propertymappings/provider/scim/{pm_uuid}/ | +[**propertymappings_provider_scim_retrieve**](PropertymappingsApi.md#propertymappings_provider_scim_retrieve) | **GET** /propertymappings/provider/scim/{pm_uuid}/ | +[**propertymappings_provider_scim_update**](PropertymappingsApi.md#propertymappings_provider_scim_update) | **PUT** /propertymappings/provider/scim/{pm_uuid}/ | +[**propertymappings_provider_scim_used_by_list**](PropertymappingsApi.md#propertymappings_provider_scim_used_by_list) | **GET** /propertymappings/provider/scim/{pm_uuid}/used_by/ | +[**propertymappings_provider_scope_create**](PropertymappingsApi.md#propertymappings_provider_scope_create) | **POST** /propertymappings/provider/scope/ | +[**propertymappings_provider_scope_destroy**](PropertymappingsApi.md#propertymappings_provider_scope_destroy) | **DELETE** /propertymappings/provider/scope/{pm_uuid}/ | +[**propertymappings_provider_scope_list**](PropertymappingsApi.md#propertymappings_provider_scope_list) | **GET** /propertymappings/provider/scope/ | +[**propertymappings_provider_scope_partial_update**](PropertymappingsApi.md#propertymappings_provider_scope_partial_update) | **PATCH** /propertymappings/provider/scope/{pm_uuid}/ | +[**propertymappings_provider_scope_retrieve**](PropertymappingsApi.md#propertymappings_provider_scope_retrieve) | **GET** /propertymappings/provider/scope/{pm_uuid}/ | +[**propertymappings_provider_scope_update**](PropertymappingsApi.md#propertymappings_provider_scope_update) | **PUT** /propertymappings/provider/scope/{pm_uuid}/ | +[**propertymappings_provider_scope_used_by_list**](PropertymappingsApi.md#propertymappings_provider_scope_used_by_list) | **GET** /propertymappings/provider/scope/{pm_uuid}/used_by/ | +[**propertymappings_source_kerberos_create**](PropertymappingsApi.md#propertymappings_source_kerberos_create) | **POST** /propertymappings/source/kerberos/ | +[**propertymappings_source_kerberos_destroy**](PropertymappingsApi.md#propertymappings_source_kerberos_destroy) | **DELETE** /propertymappings/source/kerberos/{pm_uuid}/ | +[**propertymappings_source_kerberos_list**](PropertymappingsApi.md#propertymappings_source_kerberos_list) | **GET** /propertymappings/source/kerberos/ | +[**propertymappings_source_kerberos_partial_update**](PropertymappingsApi.md#propertymappings_source_kerberos_partial_update) | **PATCH** /propertymappings/source/kerberos/{pm_uuid}/ | +[**propertymappings_source_kerberos_retrieve**](PropertymappingsApi.md#propertymappings_source_kerberos_retrieve) | **GET** /propertymappings/source/kerberos/{pm_uuid}/ | +[**propertymappings_source_kerberos_update**](PropertymappingsApi.md#propertymappings_source_kerberos_update) | **PUT** /propertymappings/source/kerberos/{pm_uuid}/ | +[**propertymappings_source_kerberos_used_by_list**](PropertymappingsApi.md#propertymappings_source_kerberos_used_by_list) | **GET** /propertymappings/source/kerberos/{pm_uuid}/used_by/ | +[**propertymappings_source_ldap_create**](PropertymappingsApi.md#propertymappings_source_ldap_create) | **POST** /propertymappings/source/ldap/ | +[**propertymappings_source_ldap_destroy**](PropertymappingsApi.md#propertymappings_source_ldap_destroy) | **DELETE** /propertymappings/source/ldap/{pm_uuid}/ | +[**propertymappings_source_ldap_list**](PropertymappingsApi.md#propertymappings_source_ldap_list) | **GET** /propertymappings/source/ldap/ | +[**propertymappings_source_ldap_partial_update**](PropertymappingsApi.md#propertymappings_source_ldap_partial_update) | **PATCH** /propertymappings/source/ldap/{pm_uuid}/ | +[**propertymappings_source_ldap_retrieve**](PropertymappingsApi.md#propertymappings_source_ldap_retrieve) | **GET** /propertymappings/source/ldap/{pm_uuid}/ | +[**propertymappings_source_ldap_update**](PropertymappingsApi.md#propertymappings_source_ldap_update) | **PUT** /propertymappings/source/ldap/{pm_uuid}/ | +[**propertymappings_source_ldap_used_by_list**](PropertymappingsApi.md#propertymappings_source_ldap_used_by_list) | **GET** /propertymappings/source/ldap/{pm_uuid}/used_by/ | +[**propertymappings_source_oauth_create**](PropertymappingsApi.md#propertymappings_source_oauth_create) | **POST** /propertymappings/source/oauth/ | +[**propertymappings_source_oauth_destroy**](PropertymappingsApi.md#propertymappings_source_oauth_destroy) | **DELETE** /propertymappings/source/oauth/{pm_uuid}/ | +[**propertymappings_source_oauth_list**](PropertymappingsApi.md#propertymappings_source_oauth_list) | **GET** /propertymappings/source/oauth/ | +[**propertymappings_source_oauth_partial_update**](PropertymappingsApi.md#propertymappings_source_oauth_partial_update) | **PATCH** /propertymappings/source/oauth/{pm_uuid}/ | +[**propertymappings_source_oauth_retrieve**](PropertymappingsApi.md#propertymappings_source_oauth_retrieve) | **GET** /propertymappings/source/oauth/{pm_uuid}/ | +[**propertymappings_source_oauth_update**](PropertymappingsApi.md#propertymappings_source_oauth_update) | **PUT** /propertymappings/source/oauth/{pm_uuid}/ | +[**propertymappings_source_oauth_used_by_list**](PropertymappingsApi.md#propertymappings_source_oauth_used_by_list) | **GET** /propertymappings/source/oauth/{pm_uuid}/used_by/ | +[**propertymappings_source_plex_create**](PropertymappingsApi.md#propertymappings_source_plex_create) | **POST** /propertymappings/source/plex/ | +[**propertymappings_source_plex_destroy**](PropertymappingsApi.md#propertymappings_source_plex_destroy) | **DELETE** /propertymappings/source/plex/{pm_uuid}/ | +[**propertymappings_source_plex_list**](PropertymappingsApi.md#propertymappings_source_plex_list) | **GET** /propertymappings/source/plex/ | +[**propertymappings_source_plex_partial_update**](PropertymappingsApi.md#propertymappings_source_plex_partial_update) | **PATCH** /propertymappings/source/plex/{pm_uuid}/ | +[**propertymappings_source_plex_retrieve**](PropertymappingsApi.md#propertymappings_source_plex_retrieve) | **GET** /propertymappings/source/plex/{pm_uuid}/ | +[**propertymappings_source_plex_update**](PropertymappingsApi.md#propertymappings_source_plex_update) | **PUT** /propertymappings/source/plex/{pm_uuid}/ | +[**propertymappings_source_plex_used_by_list**](PropertymappingsApi.md#propertymappings_source_plex_used_by_list) | **GET** /propertymappings/source/plex/{pm_uuid}/used_by/ | +[**propertymappings_source_saml_create**](PropertymappingsApi.md#propertymappings_source_saml_create) | **POST** /propertymappings/source/saml/ | +[**propertymappings_source_saml_destroy**](PropertymappingsApi.md#propertymappings_source_saml_destroy) | **DELETE** /propertymappings/source/saml/{pm_uuid}/ | +[**propertymappings_source_saml_list**](PropertymappingsApi.md#propertymappings_source_saml_list) | **GET** /propertymappings/source/saml/ | +[**propertymappings_source_saml_partial_update**](PropertymappingsApi.md#propertymappings_source_saml_partial_update) | **PATCH** /propertymappings/source/saml/{pm_uuid}/ | +[**propertymappings_source_saml_retrieve**](PropertymappingsApi.md#propertymappings_source_saml_retrieve) | **GET** /propertymappings/source/saml/{pm_uuid}/ | +[**propertymappings_source_saml_update**](PropertymappingsApi.md#propertymappings_source_saml_update) | **PUT** /propertymappings/source/saml/{pm_uuid}/ | +[**propertymappings_source_saml_used_by_list**](PropertymappingsApi.md#propertymappings_source_saml_used_by_list) | **GET** /propertymappings/source/saml/{pm_uuid}/used_by/ | +[**propertymappings_source_scim_create**](PropertymappingsApi.md#propertymappings_source_scim_create) | **POST** /propertymappings/source/scim/ | +[**propertymappings_source_scim_destroy**](PropertymappingsApi.md#propertymappings_source_scim_destroy) | **DELETE** /propertymappings/source/scim/{pm_uuid}/ | +[**propertymappings_source_scim_list**](PropertymappingsApi.md#propertymappings_source_scim_list) | **GET** /propertymappings/source/scim/ | +[**propertymappings_source_scim_partial_update**](PropertymappingsApi.md#propertymappings_source_scim_partial_update) | **PATCH** /propertymappings/source/scim/{pm_uuid}/ | +[**propertymappings_source_scim_retrieve**](PropertymappingsApi.md#propertymappings_source_scim_retrieve) | **GET** /propertymappings/source/scim/{pm_uuid}/ | +[**propertymappings_source_scim_update**](PropertymappingsApi.md#propertymappings_source_scim_update) | **PUT** /propertymappings/source/scim/{pm_uuid}/ | +[**propertymappings_source_scim_used_by_list**](PropertymappingsApi.md#propertymappings_source_scim_used_by_list) | **GET** /propertymappings/source/scim/{pm_uuid}/used_by/ | +[**propertymappings_source_telegram_create**](PropertymappingsApi.md#propertymappings_source_telegram_create) | **POST** /propertymappings/source/telegram/ | +[**propertymappings_source_telegram_destroy**](PropertymappingsApi.md#propertymappings_source_telegram_destroy) | **DELETE** /propertymappings/source/telegram/{pm_uuid}/ | +[**propertymappings_source_telegram_list**](PropertymappingsApi.md#propertymappings_source_telegram_list) | **GET** /propertymappings/source/telegram/ | +[**propertymappings_source_telegram_partial_update**](PropertymappingsApi.md#propertymappings_source_telegram_partial_update) | **PATCH** /propertymappings/source/telegram/{pm_uuid}/ | +[**propertymappings_source_telegram_retrieve**](PropertymappingsApi.md#propertymappings_source_telegram_retrieve) | **GET** /propertymappings/source/telegram/{pm_uuid}/ | +[**propertymappings_source_telegram_update**](PropertymappingsApi.md#propertymappings_source_telegram_update) | **PUT** /propertymappings/source/telegram/{pm_uuid}/ | +[**propertymappings_source_telegram_used_by_list**](PropertymappingsApi.md#propertymappings_source_telegram_used_by_list) | **GET** /propertymappings/source/telegram/{pm_uuid}/used_by/ | + + +# **propertymappings_all_destroy** +> propertymappings_all_destroy(pm_uuid) + +PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Property Mapping. + + try: + api_instance.propertymappings_all_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_all_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_all_list** +> PaginatedPropertyMappingList propertymappings_all_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_property_mapping_list import PaginatedPropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_all_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_all_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedPropertyMappingList**](PaginatedPropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_all_retrieve** +> PropertyMapping propertymappings_all_retrieve(pm_uuid) + +PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.property_mapping import PropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Property Mapping. + + try: + api_response = api_instance.propertymappings_all_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_all_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_all_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Property Mapping. | + +### Return type + +[**PropertyMapping**](PropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_all_test_create** +> PropertyMappingTestResult propertymappings_all_test_create(pm_uuid, format_result=format_result, property_mapping_test_request=property_mapping_test_request) + +Test Property Mapping + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.property_mapping_test_request import PropertyMappingTestRequest +from authentik_client.models.property_mapping_test_result import PropertyMappingTestResult +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Property Mapping. + format_result = True # bool | (optional) + property_mapping_test_request = authentik_client.PropertyMappingTestRequest() # PropertyMappingTestRequest | (optional) + + try: + api_response = api_instance.propertymappings_all_test_create(pm_uuid, format_result=format_result, property_mapping_test_request=property_mapping_test_request) + print("The response of PropertymappingsApi->propertymappings_all_test_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_all_test_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Property Mapping. | + **format_result** | **bool**| | [optional] + **property_mapping_test_request** | [**PropertyMappingTestRequest**](PropertyMappingTestRequest.md)| | [optional] + +### Return type + +[**PropertyMappingTestResult**](PropertyMappingTestResult.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Invalid parameters | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_all_types_list** +> List[TypeCreate] propertymappings_all_types_list() + +Get all creatable types + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.type_create import TypeCreate +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + + try: + api_response = api_instance.propertymappings_all_types_list() + print("The response of PropertymappingsApi->propertymappings_all_types_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_all_types_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[TypeCreate]**](TypeCreate.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_all_used_by_list** +> List[UsedBy] propertymappings_all_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Property Mapping. + + try: + api_response = api_instance.propertymappings_all_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_all_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_all_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_notification_create** +> NotificationWebhookMapping propertymappings_notification_create(notification_webhook_mapping_request) + +NotificationWebhookMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping +from authentik_client.models.notification_webhook_mapping_request import NotificationWebhookMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + notification_webhook_mapping_request = authentik_client.NotificationWebhookMappingRequest() # NotificationWebhookMappingRequest | + + try: + api_response = api_instance.propertymappings_notification_create(notification_webhook_mapping_request) + print("The response of PropertymappingsApi->propertymappings_notification_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_notification_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **notification_webhook_mapping_request** | [**NotificationWebhookMappingRequest**](NotificationWebhookMappingRequest.md)| | + +### Return type + +[**NotificationWebhookMapping**](NotificationWebhookMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_notification_destroy** +> propertymappings_notification_destroy(pm_uuid) + +NotificationWebhookMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Webhook Mapping. + + try: + api_instance.propertymappings_notification_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_notification_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Webhook Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_notification_list** +> PaginatedNotificationWebhookMappingList propertymappings_notification_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +NotificationWebhookMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_notification_webhook_mapping_list import PaginatedNotificationWebhookMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_notification_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_notification_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_notification_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedNotificationWebhookMappingList**](PaginatedNotificationWebhookMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_notification_partial_update** +> NotificationWebhookMapping propertymappings_notification_partial_update(pm_uuid, patched_notification_webhook_mapping_request=patched_notification_webhook_mapping_request) + +NotificationWebhookMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping +from authentik_client.models.patched_notification_webhook_mapping_request import PatchedNotificationWebhookMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Webhook Mapping. + patched_notification_webhook_mapping_request = authentik_client.PatchedNotificationWebhookMappingRequest() # PatchedNotificationWebhookMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_notification_partial_update(pm_uuid, patched_notification_webhook_mapping_request=patched_notification_webhook_mapping_request) + print("The response of PropertymappingsApi->propertymappings_notification_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_notification_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Webhook Mapping. | + **patched_notification_webhook_mapping_request** | [**PatchedNotificationWebhookMappingRequest**](PatchedNotificationWebhookMappingRequest.md)| | [optional] + +### Return type + +[**NotificationWebhookMapping**](NotificationWebhookMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_notification_retrieve** +> NotificationWebhookMapping propertymappings_notification_retrieve(pm_uuid) + +NotificationWebhookMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Webhook Mapping. + + try: + api_response = api_instance.propertymappings_notification_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_notification_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_notification_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Webhook Mapping. | + +### Return type + +[**NotificationWebhookMapping**](NotificationWebhookMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_notification_update** +> NotificationWebhookMapping propertymappings_notification_update(pm_uuid, notification_webhook_mapping_request) + +NotificationWebhookMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping +from authentik_client.models.notification_webhook_mapping_request import NotificationWebhookMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Webhook Mapping. + notification_webhook_mapping_request = authentik_client.NotificationWebhookMappingRequest() # NotificationWebhookMappingRequest | + + try: + api_response = api_instance.propertymappings_notification_update(pm_uuid, notification_webhook_mapping_request) + print("The response of PropertymappingsApi->propertymappings_notification_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_notification_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Webhook Mapping. | + **notification_webhook_mapping_request** | [**NotificationWebhookMappingRequest**](NotificationWebhookMappingRequest.md)| | + +### Return type + +[**NotificationWebhookMapping**](NotificationWebhookMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_notification_used_by_list** +> List[UsedBy] propertymappings_notification_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Webhook Mapping. + + try: + api_response = api_instance.propertymappings_notification_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_notification_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_notification_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Webhook Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_google_workspace_create** +> GoogleWorkspaceProviderMapping propertymappings_provider_google_workspace_create(google_workspace_provider_mapping_request) + +GoogleWorkspaceProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping +from authentik_client.models.google_workspace_provider_mapping_request import GoogleWorkspaceProviderMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + google_workspace_provider_mapping_request = authentik_client.GoogleWorkspaceProviderMappingRequest() # GoogleWorkspaceProviderMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_google_workspace_create(google_workspace_provider_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_google_workspace_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_google_workspace_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **google_workspace_provider_mapping_request** | [**GoogleWorkspaceProviderMappingRequest**](GoogleWorkspaceProviderMappingRequest.md)| | + +### Return type + +[**GoogleWorkspaceProviderMapping**](GoogleWorkspaceProviderMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_google_workspace_destroy** +> propertymappings_provider_google_workspace_destroy(pm_uuid) + +GoogleWorkspaceProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider Mapping. + + try: + api_instance.propertymappings_provider_google_workspace_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_google_workspace_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Google Workspace Provider Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_google_workspace_list** +> PaginatedGoogleWorkspaceProviderMappingList propertymappings_provider_google_workspace_list(expression=expression, managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, pm_uuid=pm_uuid, search=search) + +GoogleWorkspaceProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_google_workspace_provider_mapping_list import PaginatedGoogleWorkspaceProviderMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + expression = 'expression_example' # str | (optional) + managed = ['managed_example'] # List[str] | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_provider_google_workspace_list(expression=expression, managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, pm_uuid=pm_uuid, search=search) + print("The response of PropertymappingsApi->propertymappings_provider_google_workspace_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_google_workspace_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **expression** | **str**| | [optional] + **managed** | [**List[str]**](str.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pm_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedGoogleWorkspaceProviderMappingList**](PaginatedGoogleWorkspaceProviderMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_google_workspace_partial_update** +> GoogleWorkspaceProviderMapping propertymappings_provider_google_workspace_partial_update(pm_uuid, patched_google_workspace_provider_mapping_request=patched_google_workspace_provider_mapping_request) + +GoogleWorkspaceProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping +from authentik_client.models.patched_google_workspace_provider_mapping_request import PatchedGoogleWorkspaceProviderMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider Mapping. + patched_google_workspace_provider_mapping_request = authentik_client.PatchedGoogleWorkspaceProviderMappingRequest() # PatchedGoogleWorkspaceProviderMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_provider_google_workspace_partial_update(pm_uuid, patched_google_workspace_provider_mapping_request=patched_google_workspace_provider_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_google_workspace_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_google_workspace_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Google Workspace Provider Mapping. | + **patched_google_workspace_provider_mapping_request** | [**PatchedGoogleWorkspaceProviderMappingRequest**](PatchedGoogleWorkspaceProviderMappingRequest.md)| | [optional] + +### Return type + +[**GoogleWorkspaceProviderMapping**](GoogleWorkspaceProviderMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_google_workspace_retrieve** +> GoogleWorkspaceProviderMapping propertymappings_provider_google_workspace_retrieve(pm_uuid) + +GoogleWorkspaceProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider Mapping. + + try: + api_response = api_instance.propertymappings_provider_google_workspace_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_google_workspace_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_google_workspace_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Google Workspace Provider Mapping. | + +### Return type + +[**GoogleWorkspaceProviderMapping**](GoogleWorkspaceProviderMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_google_workspace_update** +> GoogleWorkspaceProviderMapping propertymappings_provider_google_workspace_update(pm_uuid, google_workspace_provider_mapping_request) + +GoogleWorkspaceProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping +from authentik_client.models.google_workspace_provider_mapping_request import GoogleWorkspaceProviderMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider Mapping. + google_workspace_provider_mapping_request = authentik_client.GoogleWorkspaceProviderMappingRequest() # GoogleWorkspaceProviderMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_google_workspace_update(pm_uuid, google_workspace_provider_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_google_workspace_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_google_workspace_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Google Workspace Provider Mapping. | + **google_workspace_provider_mapping_request** | [**GoogleWorkspaceProviderMappingRequest**](GoogleWorkspaceProviderMappingRequest.md)| | + +### Return type + +[**GoogleWorkspaceProviderMapping**](GoogleWorkspaceProviderMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_google_workspace_used_by_list** +> List[UsedBy] propertymappings_provider_google_workspace_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider Mapping. + + try: + api_response = api_instance.propertymappings_provider_google_workspace_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_google_workspace_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_google_workspace_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Google Workspace Provider Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_microsoft_entra_create** +> MicrosoftEntraProviderMapping propertymappings_provider_microsoft_entra_create(microsoft_entra_provider_mapping_request) + +MicrosoftEntraProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping +from authentik_client.models.microsoft_entra_provider_mapping_request import MicrosoftEntraProviderMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + microsoft_entra_provider_mapping_request = authentik_client.MicrosoftEntraProviderMappingRequest() # MicrosoftEntraProviderMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_microsoft_entra_create(microsoft_entra_provider_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_microsoft_entra_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_microsoft_entra_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **microsoft_entra_provider_mapping_request** | [**MicrosoftEntraProviderMappingRequest**](MicrosoftEntraProviderMappingRequest.md)| | + +### Return type + +[**MicrosoftEntraProviderMapping**](MicrosoftEntraProviderMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_microsoft_entra_destroy** +> propertymappings_provider_microsoft_entra_destroy(pm_uuid) + +MicrosoftEntraProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider Mapping. + + try: + api_instance.propertymappings_provider_microsoft_entra_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_microsoft_entra_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Microsoft Entra Provider Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_microsoft_entra_list** +> PaginatedMicrosoftEntraProviderMappingList propertymappings_provider_microsoft_entra_list(expression=expression, managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, pm_uuid=pm_uuid, search=search) + +MicrosoftEntraProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_microsoft_entra_provider_mapping_list import PaginatedMicrosoftEntraProviderMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + expression = 'expression_example' # str | (optional) + managed = ['managed_example'] # List[str] | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_provider_microsoft_entra_list(expression=expression, managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, pm_uuid=pm_uuid, search=search) + print("The response of PropertymappingsApi->propertymappings_provider_microsoft_entra_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_microsoft_entra_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **expression** | **str**| | [optional] + **managed** | [**List[str]**](str.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pm_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedMicrosoftEntraProviderMappingList**](PaginatedMicrosoftEntraProviderMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_microsoft_entra_partial_update** +> MicrosoftEntraProviderMapping propertymappings_provider_microsoft_entra_partial_update(pm_uuid, patched_microsoft_entra_provider_mapping_request=patched_microsoft_entra_provider_mapping_request) + +MicrosoftEntraProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping +from authentik_client.models.patched_microsoft_entra_provider_mapping_request import PatchedMicrosoftEntraProviderMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider Mapping. + patched_microsoft_entra_provider_mapping_request = authentik_client.PatchedMicrosoftEntraProviderMappingRequest() # PatchedMicrosoftEntraProviderMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_provider_microsoft_entra_partial_update(pm_uuid, patched_microsoft_entra_provider_mapping_request=patched_microsoft_entra_provider_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_microsoft_entra_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_microsoft_entra_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Microsoft Entra Provider Mapping. | + **patched_microsoft_entra_provider_mapping_request** | [**PatchedMicrosoftEntraProviderMappingRequest**](PatchedMicrosoftEntraProviderMappingRequest.md)| | [optional] + +### Return type + +[**MicrosoftEntraProviderMapping**](MicrosoftEntraProviderMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_microsoft_entra_retrieve** +> MicrosoftEntraProviderMapping propertymappings_provider_microsoft_entra_retrieve(pm_uuid) + +MicrosoftEntraProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider Mapping. + + try: + api_response = api_instance.propertymappings_provider_microsoft_entra_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_microsoft_entra_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_microsoft_entra_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Microsoft Entra Provider Mapping. | + +### Return type + +[**MicrosoftEntraProviderMapping**](MicrosoftEntraProviderMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_microsoft_entra_update** +> MicrosoftEntraProviderMapping propertymappings_provider_microsoft_entra_update(pm_uuid, microsoft_entra_provider_mapping_request) + +MicrosoftEntraProviderMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping +from authentik_client.models.microsoft_entra_provider_mapping_request import MicrosoftEntraProviderMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider Mapping. + microsoft_entra_provider_mapping_request = authentik_client.MicrosoftEntraProviderMappingRequest() # MicrosoftEntraProviderMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_microsoft_entra_update(pm_uuid, microsoft_entra_provider_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_microsoft_entra_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_microsoft_entra_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Microsoft Entra Provider Mapping. | + **microsoft_entra_provider_mapping_request** | [**MicrosoftEntraProviderMappingRequest**](MicrosoftEntraProviderMappingRequest.md)| | + +### Return type + +[**MicrosoftEntraProviderMapping**](MicrosoftEntraProviderMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_microsoft_entra_used_by_list** +> List[UsedBy] propertymappings_provider_microsoft_entra_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider Mapping. + + try: + api_response = api_instance.propertymappings_provider_microsoft_entra_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_microsoft_entra_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_microsoft_entra_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Microsoft Entra Provider Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_rac_create** +> RACPropertyMapping propertymappings_provider_rac_create(rac_property_mapping_request) + +RACPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.rac_property_mapping import RACPropertyMapping +from authentik_client.models.rac_property_mapping_request import RACPropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + rac_property_mapping_request = authentik_client.RACPropertyMappingRequest() # RACPropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_rac_create(rac_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_rac_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_rac_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **rac_property_mapping_request** | [**RACPropertyMappingRequest**](RACPropertyMappingRequest.md)| | + +### Return type + +[**RACPropertyMapping**](RACPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_rac_destroy** +> propertymappings_provider_rac_destroy(pm_uuid) + +RACPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Provider Property Mapping. + + try: + api_instance.propertymappings_provider_rac_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_rac_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this RAC Provider Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_rac_list** +> PaginatedRACPropertyMappingList propertymappings_provider_rac_list(managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +RACPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_rac_property_mapping_list import PaginatedRACPropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_provider_rac_list(managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_provider_rac_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_rac_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedRACPropertyMappingList**](PaginatedRACPropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_rac_partial_update** +> RACPropertyMapping propertymappings_provider_rac_partial_update(pm_uuid, patched_rac_property_mapping_request=patched_rac_property_mapping_request) + +RACPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_rac_property_mapping_request import PatchedRACPropertyMappingRequest +from authentik_client.models.rac_property_mapping import RACPropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Provider Property Mapping. + patched_rac_property_mapping_request = authentik_client.PatchedRACPropertyMappingRequest() # PatchedRACPropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_provider_rac_partial_update(pm_uuid, patched_rac_property_mapping_request=patched_rac_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_rac_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_rac_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this RAC Provider Property Mapping. | + **patched_rac_property_mapping_request** | [**PatchedRACPropertyMappingRequest**](PatchedRACPropertyMappingRequest.md)| | [optional] + +### Return type + +[**RACPropertyMapping**](RACPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_rac_retrieve** +> RACPropertyMapping propertymappings_provider_rac_retrieve(pm_uuid) + +RACPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.rac_property_mapping import RACPropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Provider Property Mapping. + + try: + api_response = api_instance.propertymappings_provider_rac_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_rac_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_rac_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this RAC Provider Property Mapping. | + +### Return type + +[**RACPropertyMapping**](RACPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_rac_update** +> RACPropertyMapping propertymappings_provider_rac_update(pm_uuid, rac_property_mapping_request) + +RACPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.rac_property_mapping import RACPropertyMapping +from authentik_client.models.rac_property_mapping_request import RACPropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Provider Property Mapping. + rac_property_mapping_request = authentik_client.RACPropertyMappingRequest() # RACPropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_rac_update(pm_uuid, rac_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_rac_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_rac_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this RAC Provider Property Mapping. | + **rac_property_mapping_request** | [**RACPropertyMappingRequest**](RACPropertyMappingRequest.md)| | + +### Return type + +[**RACPropertyMapping**](RACPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_rac_used_by_list** +> List[UsedBy] propertymappings_provider_rac_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Provider Property Mapping. + + try: + api_response = api_instance.propertymappings_provider_rac_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_rac_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_rac_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this RAC Provider Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_radius_create** +> RadiusProviderPropertyMapping propertymappings_provider_radius_create(radius_provider_property_mapping_request) + +RadiusProviderPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping +from authentik_client.models.radius_provider_property_mapping_request import RadiusProviderPropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + radius_provider_property_mapping_request = authentik_client.RadiusProviderPropertyMappingRequest() # RadiusProviderPropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_radius_create(radius_provider_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_radius_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_radius_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **radius_provider_property_mapping_request** | [**RadiusProviderPropertyMappingRequest**](RadiusProviderPropertyMappingRequest.md)| | + +### Return type + +[**RadiusProviderPropertyMapping**](RadiusProviderPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_radius_destroy** +> propertymappings_provider_radius_destroy(pm_uuid) + +RadiusProviderPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Radius Provider Property Mapping. + + try: + api_instance.propertymappings_provider_radius_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_radius_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Radius Provider Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_radius_list** +> PaginatedRadiusProviderPropertyMappingList propertymappings_provider_radius_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +RadiusProviderPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_radius_provider_property_mapping_list import PaginatedRadiusProviderPropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_provider_radius_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_provider_radius_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_radius_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedRadiusProviderPropertyMappingList**](PaginatedRadiusProviderPropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_radius_partial_update** +> RadiusProviderPropertyMapping propertymappings_provider_radius_partial_update(pm_uuid, patched_radius_provider_property_mapping_request=patched_radius_provider_property_mapping_request) + +RadiusProviderPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_radius_provider_property_mapping_request import PatchedRadiusProviderPropertyMappingRequest +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Radius Provider Property Mapping. + patched_radius_provider_property_mapping_request = authentik_client.PatchedRadiusProviderPropertyMappingRequest() # PatchedRadiusProviderPropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_provider_radius_partial_update(pm_uuid, patched_radius_provider_property_mapping_request=patched_radius_provider_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_radius_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_radius_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Radius Provider Property Mapping. | + **patched_radius_provider_property_mapping_request** | [**PatchedRadiusProviderPropertyMappingRequest**](PatchedRadiusProviderPropertyMappingRequest.md)| | [optional] + +### Return type + +[**RadiusProviderPropertyMapping**](RadiusProviderPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_radius_retrieve** +> RadiusProviderPropertyMapping propertymappings_provider_radius_retrieve(pm_uuid) + +RadiusProviderPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Radius Provider Property Mapping. + + try: + api_response = api_instance.propertymappings_provider_radius_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_radius_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_radius_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Radius Provider Property Mapping. | + +### Return type + +[**RadiusProviderPropertyMapping**](RadiusProviderPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_radius_update** +> RadiusProviderPropertyMapping propertymappings_provider_radius_update(pm_uuid, radius_provider_property_mapping_request) + +RadiusProviderPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping +from authentik_client.models.radius_provider_property_mapping_request import RadiusProviderPropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Radius Provider Property Mapping. + radius_provider_property_mapping_request = authentik_client.RadiusProviderPropertyMappingRequest() # RadiusProviderPropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_radius_update(pm_uuid, radius_provider_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_radius_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_radius_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Radius Provider Property Mapping. | + **radius_provider_property_mapping_request** | [**RadiusProviderPropertyMappingRequest**](RadiusProviderPropertyMappingRequest.md)| | + +### Return type + +[**RadiusProviderPropertyMapping**](RadiusProviderPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_radius_used_by_list** +> List[UsedBy] propertymappings_provider_radius_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Radius Provider Property Mapping. + + try: + api_response = api_instance.propertymappings_provider_radius_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_radius_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_radius_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Radius Provider Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_saml_create** +> SAMLPropertyMapping propertymappings_provider_saml_create(saml_property_mapping_request) + +SAMLPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping +from authentik_client.models.saml_property_mapping_request import SAMLPropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + saml_property_mapping_request = authentik_client.SAMLPropertyMappingRequest() # SAMLPropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_saml_create(saml_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_saml_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_saml_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **saml_property_mapping_request** | [**SAMLPropertyMappingRequest**](SAMLPropertyMappingRequest.md)| | + +### Return type + +[**SAMLPropertyMapping**](SAMLPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_saml_destroy** +> propertymappings_provider_saml_destroy(pm_uuid) + +SAMLPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Provider Property Mapping. + + try: + api_instance.propertymappings_provider_saml_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_saml_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Provider Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_saml_list** +> PaginatedSAMLPropertyMappingList propertymappings_provider_saml_list(friendly_name=friendly_name, managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, saml_name=saml_name, search=search) + +SAMLPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_saml_property_mapping_list import PaginatedSAMLPropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + friendly_name = 'friendly_name_example' # str | (optional) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + saml_name = 'saml_name_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_provider_saml_list(friendly_name=friendly_name, managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, saml_name=saml_name, search=search) + print("The response of PropertymappingsApi->propertymappings_provider_saml_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_saml_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **friendly_name** | **str**| | [optional] + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **saml_name** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedSAMLPropertyMappingList**](PaginatedSAMLPropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_saml_partial_update** +> SAMLPropertyMapping propertymappings_provider_saml_partial_update(pm_uuid, patched_saml_property_mapping_request=patched_saml_property_mapping_request) + +SAMLPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_saml_property_mapping_request import PatchedSAMLPropertyMappingRequest +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Provider Property Mapping. + patched_saml_property_mapping_request = authentik_client.PatchedSAMLPropertyMappingRequest() # PatchedSAMLPropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_provider_saml_partial_update(pm_uuid, patched_saml_property_mapping_request=patched_saml_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_saml_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_saml_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Provider Property Mapping. | + **patched_saml_property_mapping_request** | [**PatchedSAMLPropertyMappingRequest**](PatchedSAMLPropertyMappingRequest.md)| | [optional] + +### Return type + +[**SAMLPropertyMapping**](SAMLPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_saml_retrieve** +> SAMLPropertyMapping propertymappings_provider_saml_retrieve(pm_uuid) + +SAMLPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Provider Property Mapping. + + try: + api_response = api_instance.propertymappings_provider_saml_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_saml_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_saml_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Provider Property Mapping. | + +### Return type + +[**SAMLPropertyMapping**](SAMLPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_saml_update** +> SAMLPropertyMapping propertymappings_provider_saml_update(pm_uuid, saml_property_mapping_request) + +SAMLPropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping +from authentik_client.models.saml_property_mapping_request import SAMLPropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Provider Property Mapping. + saml_property_mapping_request = authentik_client.SAMLPropertyMappingRequest() # SAMLPropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_saml_update(pm_uuid, saml_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_saml_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_saml_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Provider Property Mapping. | + **saml_property_mapping_request** | [**SAMLPropertyMappingRequest**](SAMLPropertyMappingRequest.md)| | + +### Return type + +[**SAMLPropertyMapping**](SAMLPropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_saml_used_by_list** +> List[UsedBy] propertymappings_provider_saml_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Provider Property Mapping. + + try: + api_response = api_instance.propertymappings_provider_saml_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_saml_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_saml_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Provider Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scim_create** +> SCIMMapping propertymappings_provider_scim_create(scim_mapping_request) + +SCIMMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_mapping import SCIMMapping +from authentik_client.models.scim_mapping_request import SCIMMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + scim_mapping_request = authentik_client.SCIMMappingRequest() # SCIMMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_scim_create(scim_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_scim_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scim_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scim_mapping_request** | [**SCIMMappingRequest**](SCIMMappingRequest.md)| | + +### Return type + +[**SCIMMapping**](SCIMMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scim_destroy** +> propertymappings_provider_scim_destroy(pm_uuid) + +SCIMMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Provider Mapping. + + try: + api_instance.propertymappings_provider_scim_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scim_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Provider Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scim_list** +> PaginatedSCIMMappingList propertymappings_provider_scim_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +SCIMMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_scim_mapping_list import PaginatedSCIMMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_provider_scim_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_provider_scim_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scim_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedSCIMMappingList**](PaginatedSCIMMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scim_partial_update** +> SCIMMapping propertymappings_provider_scim_partial_update(pm_uuid, patched_scim_mapping_request=patched_scim_mapping_request) + +SCIMMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_scim_mapping_request import PatchedSCIMMappingRequest +from authentik_client.models.scim_mapping import SCIMMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Provider Mapping. + patched_scim_mapping_request = authentik_client.PatchedSCIMMappingRequest() # PatchedSCIMMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_provider_scim_partial_update(pm_uuid, patched_scim_mapping_request=patched_scim_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_scim_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scim_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Provider Mapping. | + **patched_scim_mapping_request** | [**PatchedSCIMMappingRequest**](PatchedSCIMMappingRequest.md)| | [optional] + +### Return type + +[**SCIMMapping**](SCIMMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scim_retrieve** +> SCIMMapping propertymappings_provider_scim_retrieve(pm_uuid) + +SCIMMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_mapping import SCIMMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Provider Mapping. + + try: + api_response = api_instance.propertymappings_provider_scim_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_scim_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scim_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Provider Mapping. | + +### Return type + +[**SCIMMapping**](SCIMMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scim_update** +> SCIMMapping propertymappings_provider_scim_update(pm_uuid, scim_mapping_request) + +SCIMMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_mapping import SCIMMapping +from authentik_client.models.scim_mapping_request import SCIMMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Provider Mapping. + scim_mapping_request = authentik_client.SCIMMappingRequest() # SCIMMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_scim_update(pm_uuid, scim_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_scim_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scim_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Provider Mapping. | + **scim_mapping_request** | [**SCIMMappingRequest**](SCIMMappingRequest.md)| | + +### Return type + +[**SCIMMapping**](SCIMMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scim_used_by_list** +> List[UsedBy] propertymappings_provider_scim_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Provider Mapping. + + try: + api_response = api_instance.propertymappings_provider_scim_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_scim_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scim_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Provider Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scope_create** +> ScopeMapping propertymappings_provider_scope_create(scope_mapping_request) + +ScopeMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scope_mapping import ScopeMapping +from authentik_client.models.scope_mapping_request import ScopeMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + scope_mapping_request = authentik_client.ScopeMappingRequest() # ScopeMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_scope_create(scope_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_scope_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scope_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scope_mapping_request** | [**ScopeMappingRequest**](ScopeMappingRequest.md)| | + +### Return type + +[**ScopeMapping**](ScopeMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scope_destroy** +> propertymappings_provider_scope_destroy(pm_uuid) + +ScopeMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Scope Mapping. + + try: + api_instance.propertymappings_provider_scope_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scope_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Scope Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scope_list** +> PaginatedScopeMappingList propertymappings_provider_scope_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, scope_name=scope_name, search=search) + +ScopeMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_scope_mapping_list import PaginatedScopeMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + scope_name = 'scope_name_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_provider_scope_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, scope_name=scope_name, search=search) + print("The response of PropertymappingsApi->propertymappings_provider_scope_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scope_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **scope_name** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedScopeMappingList**](PaginatedScopeMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scope_partial_update** +> ScopeMapping propertymappings_provider_scope_partial_update(pm_uuid, patched_scope_mapping_request=patched_scope_mapping_request) + +ScopeMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_scope_mapping_request import PatchedScopeMappingRequest +from authentik_client.models.scope_mapping import ScopeMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Scope Mapping. + patched_scope_mapping_request = authentik_client.PatchedScopeMappingRequest() # PatchedScopeMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_provider_scope_partial_update(pm_uuid, patched_scope_mapping_request=patched_scope_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_scope_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scope_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Scope Mapping. | + **patched_scope_mapping_request** | [**PatchedScopeMappingRequest**](PatchedScopeMappingRequest.md)| | [optional] + +### Return type + +[**ScopeMapping**](ScopeMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scope_retrieve** +> ScopeMapping propertymappings_provider_scope_retrieve(pm_uuid) + +ScopeMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scope_mapping import ScopeMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Scope Mapping. + + try: + api_response = api_instance.propertymappings_provider_scope_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_scope_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scope_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Scope Mapping. | + +### Return type + +[**ScopeMapping**](ScopeMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scope_update** +> ScopeMapping propertymappings_provider_scope_update(pm_uuid, scope_mapping_request) + +ScopeMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scope_mapping import ScopeMapping +from authentik_client.models.scope_mapping_request import ScopeMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Scope Mapping. + scope_mapping_request = authentik_client.ScopeMappingRequest() # ScopeMappingRequest | + + try: + api_response = api_instance.propertymappings_provider_scope_update(pm_uuid, scope_mapping_request) + print("The response of PropertymappingsApi->propertymappings_provider_scope_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scope_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Scope Mapping. | + **scope_mapping_request** | [**ScopeMappingRequest**](ScopeMappingRequest.md)| | + +### Return type + +[**ScopeMapping**](ScopeMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_provider_scope_used_by_list** +> List[UsedBy] propertymappings_provider_scope_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Scope Mapping. + + try: + api_response = api_instance.propertymappings_provider_scope_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_provider_scope_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_provider_scope_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Scope Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_kerberos_create** +> KerberosSourcePropertyMapping propertymappings_source_kerberos_create(kerberos_source_property_mapping_request) + +KerberosSource PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping +from authentik_client.models.kerberos_source_property_mapping_request import KerberosSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + kerberos_source_property_mapping_request = authentik_client.KerberosSourcePropertyMappingRequest() # KerberosSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_kerberos_create(kerberos_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_kerberos_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_kerberos_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kerberos_source_property_mapping_request** | [**KerberosSourcePropertyMappingRequest**](KerberosSourcePropertyMappingRequest.md)| | + +### Return type + +[**KerberosSourcePropertyMapping**](KerberosSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_kerberos_destroy** +> propertymappings_source_kerberos_destroy(pm_uuid) + +KerberosSource PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kerberos Source Property Mapping. + + try: + api_instance.propertymappings_source_kerberos_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_kerberos_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Kerberos Source Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_kerberos_list** +> PaginatedKerberosSourcePropertyMappingList propertymappings_source_kerberos_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +KerberosSource PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_kerberos_source_property_mapping_list import PaginatedKerberosSourcePropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_source_kerberos_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_source_kerberos_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_kerberos_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedKerberosSourcePropertyMappingList**](PaginatedKerberosSourcePropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_kerberos_partial_update** +> KerberosSourcePropertyMapping propertymappings_source_kerberos_partial_update(pm_uuid, patched_kerberos_source_property_mapping_request=patched_kerberos_source_property_mapping_request) + +KerberosSource PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping +from authentik_client.models.patched_kerberos_source_property_mapping_request import PatchedKerberosSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kerberos Source Property Mapping. + patched_kerberos_source_property_mapping_request = authentik_client.PatchedKerberosSourcePropertyMappingRequest() # PatchedKerberosSourcePropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_source_kerberos_partial_update(pm_uuid, patched_kerberos_source_property_mapping_request=patched_kerberos_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_kerberos_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_kerberos_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Kerberos Source Property Mapping. | + **patched_kerberos_source_property_mapping_request** | [**PatchedKerberosSourcePropertyMappingRequest**](PatchedKerberosSourcePropertyMappingRequest.md)| | [optional] + +### Return type + +[**KerberosSourcePropertyMapping**](KerberosSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_kerberos_retrieve** +> KerberosSourcePropertyMapping propertymappings_source_kerberos_retrieve(pm_uuid) + +KerberosSource PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kerberos Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_kerberos_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_kerberos_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_kerberos_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Kerberos Source Property Mapping. | + +### Return type + +[**KerberosSourcePropertyMapping**](KerberosSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_kerberos_update** +> KerberosSourcePropertyMapping propertymappings_source_kerberos_update(pm_uuid, kerberos_source_property_mapping_request) + +KerberosSource PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping +from authentik_client.models.kerberos_source_property_mapping_request import KerberosSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kerberos Source Property Mapping. + kerberos_source_property_mapping_request = authentik_client.KerberosSourcePropertyMappingRequest() # KerberosSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_kerberos_update(pm_uuid, kerberos_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_kerberos_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_kerberos_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Kerberos Source Property Mapping. | + **kerberos_source_property_mapping_request** | [**KerberosSourcePropertyMappingRequest**](KerberosSourcePropertyMappingRequest.md)| | + +### Return type + +[**KerberosSourcePropertyMapping**](KerberosSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_kerberos_used_by_list** +> List[UsedBy] propertymappings_source_kerberos_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Kerberos Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_kerberos_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_kerberos_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_kerberos_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Kerberos Source Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_ldap_create** +> LDAPSourcePropertyMapping propertymappings_source_ldap_create(ldap_source_property_mapping_request) + +LDAP PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping +from authentik_client.models.ldap_source_property_mapping_request import LDAPSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + ldap_source_property_mapping_request = authentik_client.LDAPSourcePropertyMappingRequest() # LDAPSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_ldap_create(ldap_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_ldap_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_ldap_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ldap_source_property_mapping_request** | [**LDAPSourcePropertyMappingRequest**](LDAPSourcePropertyMappingRequest.md)| | + +### Return type + +[**LDAPSourcePropertyMapping**](LDAPSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_ldap_destroy** +> propertymappings_source_ldap_destroy(pm_uuid) + +LDAP PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this LDAP Source Property Mapping. + + try: + api_instance.propertymappings_source_ldap_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_ldap_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this LDAP Source Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_ldap_list** +> PaginatedLDAPSourcePropertyMappingList propertymappings_source_ldap_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +LDAP PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_ldap_source_property_mapping_list import PaginatedLDAPSourcePropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_source_ldap_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_source_ldap_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_ldap_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedLDAPSourcePropertyMappingList**](PaginatedLDAPSourcePropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_ldap_partial_update** +> LDAPSourcePropertyMapping propertymappings_source_ldap_partial_update(pm_uuid, patched_ldap_source_property_mapping_request=patched_ldap_source_property_mapping_request) + +LDAP PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping +from authentik_client.models.patched_ldap_source_property_mapping_request import PatchedLDAPSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this LDAP Source Property Mapping. + patched_ldap_source_property_mapping_request = authentik_client.PatchedLDAPSourcePropertyMappingRequest() # PatchedLDAPSourcePropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_source_ldap_partial_update(pm_uuid, patched_ldap_source_property_mapping_request=patched_ldap_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_ldap_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_ldap_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this LDAP Source Property Mapping. | + **patched_ldap_source_property_mapping_request** | [**PatchedLDAPSourcePropertyMappingRequest**](PatchedLDAPSourcePropertyMappingRequest.md)| | [optional] + +### Return type + +[**LDAPSourcePropertyMapping**](LDAPSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_ldap_retrieve** +> LDAPSourcePropertyMapping propertymappings_source_ldap_retrieve(pm_uuid) + +LDAP PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this LDAP Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_ldap_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_ldap_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_ldap_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this LDAP Source Property Mapping. | + +### Return type + +[**LDAPSourcePropertyMapping**](LDAPSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_ldap_update** +> LDAPSourcePropertyMapping propertymappings_source_ldap_update(pm_uuid, ldap_source_property_mapping_request) + +LDAP PropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping +from authentik_client.models.ldap_source_property_mapping_request import LDAPSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this LDAP Source Property Mapping. + ldap_source_property_mapping_request = authentik_client.LDAPSourcePropertyMappingRequest() # LDAPSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_ldap_update(pm_uuid, ldap_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_ldap_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_ldap_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this LDAP Source Property Mapping. | + **ldap_source_property_mapping_request** | [**LDAPSourcePropertyMappingRequest**](LDAPSourcePropertyMappingRequest.md)| | + +### Return type + +[**LDAPSourcePropertyMapping**](LDAPSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_ldap_used_by_list** +> List[UsedBy] propertymappings_source_ldap_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this LDAP Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_ldap_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_ldap_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_ldap_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this LDAP Source Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_oauth_create** +> OAuthSourcePropertyMapping propertymappings_source_oauth_create(o_auth_source_property_mapping_request) + +OAuthSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping +from authentik_client.models.o_auth_source_property_mapping_request import OAuthSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + o_auth_source_property_mapping_request = authentik_client.OAuthSourcePropertyMappingRequest() # OAuthSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_oauth_create(o_auth_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_oauth_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_oauth_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **o_auth_source_property_mapping_request** | [**OAuthSourcePropertyMappingRequest**](OAuthSourcePropertyMappingRequest.md)| | + +### Return type + +[**OAuthSourcePropertyMapping**](OAuthSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_oauth_destroy** +> propertymappings_source_oauth_destroy(pm_uuid) + +OAuthSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this OAuth Source Property Mapping. + + try: + api_instance.propertymappings_source_oauth_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_oauth_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this OAuth Source Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_oauth_list** +> PaginatedOAuthSourcePropertyMappingList propertymappings_source_oauth_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +OAuthSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_o_auth_source_property_mapping_list import PaginatedOAuthSourcePropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_source_oauth_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_source_oauth_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_oauth_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedOAuthSourcePropertyMappingList**](PaginatedOAuthSourcePropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_oauth_partial_update** +> OAuthSourcePropertyMapping propertymappings_source_oauth_partial_update(pm_uuid, patched_o_auth_source_property_mapping_request=patched_o_auth_source_property_mapping_request) + +OAuthSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping +from authentik_client.models.patched_o_auth_source_property_mapping_request import PatchedOAuthSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this OAuth Source Property Mapping. + patched_o_auth_source_property_mapping_request = authentik_client.PatchedOAuthSourcePropertyMappingRequest() # PatchedOAuthSourcePropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_source_oauth_partial_update(pm_uuid, patched_o_auth_source_property_mapping_request=patched_o_auth_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_oauth_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_oauth_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this OAuth Source Property Mapping. | + **patched_o_auth_source_property_mapping_request** | [**PatchedOAuthSourcePropertyMappingRequest**](PatchedOAuthSourcePropertyMappingRequest.md)| | [optional] + +### Return type + +[**OAuthSourcePropertyMapping**](OAuthSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_oauth_retrieve** +> OAuthSourcePropertyMapping propertymappings_source_oauth_retrieve(pm_uuid) + +OAuthSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this OAuth Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_oauth_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_oauth_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_oauth_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this OAuth Source Property Mapping. | + +### Return type + +[**OAuthSourcePropertyMapping**](OAuthSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_oauth_update** +> OAuthSourcePropertyMapping propertymappings_source_oauth_update(pm_uuid, o_auth_source_property_mapping_request) + +OAuthSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping +from authentik_client.models.o_auth_source_property_mapping_request import OAuthSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this OAuth Source Property Mapping. + o_auth_source_property_mapping_request = authentik_client.OAuthSourcePropertyMappingRequest() # OAuthSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_oauth_update(pm_uuid, o_auth_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_oauth_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_oauth_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this OAuth Source Property Mapping. | + **o_auth_source_property_mapping_request** | [**OAuthSourcePropertyMappingRequest**](OAuthSourcePropertyMappingRequest.md)| | + +### Return type + +[**OAuthSourcePropertyMapping**](OAuthSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_oauth_used_by_list** +> List[UsedBy] propertymappings_source_oauth_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this OAuth Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_oauth_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_oauth_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_oauth_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this OAuth Source Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_plex_create** +> PlexSourcePropertyMapping propertymappings_source_plex_create(plex_source_property_mapping_request) + +PlexSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping +from authentik_client.models.plex_source_property_mapping_request import PlexSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + plex_source_property_mapping_request = authentik_client.PlexSourcePropertyMappingRequest() # PlexSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_plex_create(plex_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_plex_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_plex_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **plex_source_property_mapping_request** | [**PlexSourcePropertyMappingRequest**](PlexSourcePropertyMappingRequest.md)| | + +### Return type + +[**PlexSourcePropertyMapping**](PlexSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_plex_destroy** +> propertymappings_source_plex_destroy(pm_uuid) + +PlexSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Plex Source Property Mapping. + + try: + api_instance.propertymappings_source_plex_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_plex_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Plex Source Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_plex_list** +> PaginatedPlexSourcePropertyMappingList propertymappings_source_plex_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +PlexSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_plex_source_property_mapping_list import PaginatedPlexSourcePropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_source_plex_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_source_plex_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_plex_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedPlexSourcePropertyMappingList**](PaginatedPlexSourcePropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_plex_partial_update** +> PlexSourcePropertyMapping propertymappings_source_plex_partial_update(pm_uuid, patched_plex_source_property_mapping_request=patched_plex_source_property_mapping_request) + +PlexSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_plex_source_property_mapping_request import PatchedPlexSourcePropertyMappingRequest +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Plex Source Property Mapping. + patched_plex_source_property_mapping_request = authentik_client.PatchedPlexSourcePropertyMappingRequest() # PatchedPlexSourcePropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_source_plex_partial_update(pm_uuid, patched_plex_source_property_mapping_request=patched_plex_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_plex_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_plex_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Plex Source Property Mapping. | + **patched_plex_source_property_mapping_request** | [**PatchedPlexSourcePropertyMappingRequest**](PatchedPlexSourcePropertyMappingRequest.md)| | [optional] + +### Return type + +[**PlexSourcePropertyMapping**](PlexSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_plex_retrieve** +> PlexSourcePropertyMapping propertymappings_source_plex_retrieve(pm_uuid) + +PlexSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Plex Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_plex_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_plex_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_plex_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Plex Source Property Mapping. | + +### Return type + +[**PlexSourcePropertyMapping**](PlexSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_plex_update** +> PlexSourcePropertyMapping propertymappings_source_plex_update(pm_uuid, plex_source_property_mapping_request) + +PlexSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping +from authentik_client.models.plex_source_property_mapping_request import PlexSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Plex Source Property Mapping. + plex_source_property_mapping_request = authentik_client.PlexSourcePropertyMappingRequest() # PlexSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_plex_update(pm_uuid, plex_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_plex_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_plex_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Plex Source Property Mapping. | + **plex_source_property_mapping_request** | [**PlexSourcePropertyMappingRequest**](PlexSourcePropertyMappingRequest.md)| | + +### Return type + +[**PlexSourcePropertyMapping**](PlexSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_plex_used_by_list** +> List[UsedBy] propertymappings_source_plex_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Plex Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_plex_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_plex_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_plex_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Plex Source Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_saml_create** +> SAMLSourcePropertyMapping propertymappings_source_saml_create(saml_source_property_mapping_request) + +SAMLSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping +from authentik_client.models.saml_source_property_mapping_request import SAMLSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + saml_source_property_mapping_request = authentik_client.SAMLSourcePropertyMappingRequest() # SAMLSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_saml_create(saml_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_saml_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_saml_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **saml_source_property_mapping_request** | [**SAMLSourcePropertyMappingRequest**](SAMLSourcePropertyMappingRequest.md)| | + +### Return type + +[**SAMLSourcePropertyMapping**](SAMLSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_saml_destroy** +> propertymappings_source_saml_destroy(pm_uuid) + +SAMLSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Source Property Mapping. + + try: + api_instance.propertymappings_source_saml_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_saml_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Source Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_saml_list** +> PaginatedSAMLSourcePropertyMappingList propertymappings_source_saml_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +SAMLSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_saml_source_property_mapping_list import PaginatedSAMLSourcePropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_source_saml_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_source_saml_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_saml_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedSAMLSourcePropertyMappingList**](PaginatedSAMLSourcePropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_saml_partial_update** +> SAMLSourcePropertyMapping propertymappings_source_saml_partial_update(pm_uuid, patched_saml_source_property_mapping_request=patched_saml_source_property_mapping_request) + +SAMLSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_saml_source_property_mapping_request import PatchedSAMLSourcePropertyMappingRequest +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Source Property Mapping. + patched_saml_source_property_mapping_request = authentik_client.PatchedSAMLSourcePropertyMappingRequest() # PatchedSAMLSourcePropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_source_saml_partial_update(pm_uuid, patched_saml_source_property_mapping_request=patched_saml_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_saml_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_saml_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Source Property Mapping. | + **patched_saml_source_property_mapping_request** | [**PatchedSAMLSourcePropertyMappingRequest**](PatchedSAMLSourcePropertyMappingRequest.md)| | [optional] + +### Return type + +[**SAMLSourcePropertyMapping**](SAMLSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_saml_retrieve** +> SAMLSourcePropertyMapping propertymappings_source_saml_retrieve(pm_uuid) + +SAMLSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_saml_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_saml_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_saml_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Source Property Mapping. | + +### Return type + +[**SAMLSourcePropertyMapping**](SAMLSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_saml_update** +> SAMLSourcePropertyMapping propertymappings_source_saml_update(pm_uuid, saml_source_property_mapping_request) + +SAMLSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping +from authentik_client.models.saml_source_property_mapping_request import SAMLSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Source Property Mapping. + saml_source_property_mapping_request = authentik_client.SAMLSourcePropertyMappingRequest() # SAMLSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_saml_update(pm_uuid, saml_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_saml_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_saml_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Source Property Mapping. | + **saml_source_property_mapping_request** | [**SAMLSourcePropertyMappingRequest**](SAMLSourcePropertyMappingRequest.md)| | + +### Return type + +[**SAMLSourcePropertyMapping**](SAMLSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_saml_used_by_list** +> List[UsedBy] propertymappings_source_saml_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SAML Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_saml_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_saml_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_saml_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SAML Source Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_scim_create** +> SCIMSourcePropertyMapping propertymappings_source_scim_create(scim_source_property_mapping_request) + +SCIMSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping +from authentik_client.models.scim_source_property_mapping_request import SCIMSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + scim_source_property_mapping_request = authentik_client.SCIMSourcePropertyMappingRequest() # SCIMSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_scim_create(scim_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_scim_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_scim_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scim_source_property_mapping_request** | [**SCIMSourcePropertyMappingRequest**](SCIMSourcePropertyMappingRequest.md)| | + +### Return type + +[**SCIMSourcePropertyMapping**](SCIMSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_scim_destroy** +> propertymappings_source_scim_destroy(pm_uuid) + +SCIMSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Source Property Mapping. + + try: + api_instance.propertymappings_source_scim_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_scim_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Source Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_scim_list** +> PaginatedSCIMSourcePropertyMappingList propertymappings_source_scim_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +SCIMSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_scim_source_property_mapping_list import PaginatedSCIMSourcePropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_source_scim_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_source_scim_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_scim_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedSCIMSourcePropertyMappingList**](PaginatedSCIMSourcePropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_scim_partial_update** +> SCIMSourcePropertyMapping propertymappings_source_scim_partial_update(pm_uuid, patched_scim_source_property_mapping_request=patched_scim_source_property_mapping_request) + +SCIMSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_scim_source_property_mapping_request import PatchedSCIMSourcePropertyMappingRequest +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Source Property Mapping. + patched_scim_source_property_mapping_request = authentik_client.PatchedSCIMSourcePropertyMappingRequest() # PatchedSCIMSourcePropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_source_scim_partial_update(pm_uuid, patched_scim_source_property_mapping_request=patched_scim_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_scim_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_scim_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Source Property Mapping. | + **patched_scim_source_property_mapping_request** | [**PatchedSCIMSourcePropertyMappingRequest**](PatchedSCIMSourcePropertyMappingRequest.md)| | [optional] + +### Return type + +[**SCIMSourcePropertyMapping**](SCIMSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_scim_retrieve** +> SCIMSourcePropertyMapping propertymappings_source_scim_retrieve(pm_uuid) + +SCIMSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_scim_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_scim_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_scim_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Source Property Mapping. | + +### Return type + +[**SCIMSourcePropertyMapping**](SCIMSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_scim_update** +> SCIMSourcePropertyMapping propertymappings_source_scim_update(pm_uuid, scim_source_property_mapping_request) + +SCIMSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping +from authentik_client.models.scim_source_property_mapping_request import SCIMSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Source Property Mapping. + scim_source_property_mapping_request = authentik_client.SCIMSourcePropertyMappingRequest() # SCIMSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_scim_update(pm_uuid, scim_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_scim_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_scim_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Source Property Mapping. | + **scim_source_property_mapping_request** | [**SCIMSourcePropertyMappingRequest**](SCIMSourcePropertyMappingRequest.md)| | + +### Return type + +[**SCIMSourcePropertyMapping**](SCIMSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_scim_used_by_list** +> List[UsedBy] propertymappings_source_scim_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SCIM Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_scim_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_scim_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_scim_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this SCIM Source Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_telegram_create** +> TelegramSourcePropertyMapping propertymappings_source_telegram_create(telegram_source_property_mapping_request) + +TelegramSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping +from authentik_client.models.telegram_source_property_mapping_request import TelegramSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + telegram_source_property_mapping_request = authentik_client.TelegramSourcePropertyMappingRequest() # TelegramSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_telegram_create(telegram_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_telegram_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_telegram_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **telegram_source_property_mapping_request** | [**TelegramSourcePropertyMappingRequest**](TelegramSourcePropertyMappingRequest.md)| | + +### Return type + +[**TelegramSourcePropertyMapping**](TelegramSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_telegram_destroy** +> propertymappings_source_telegram_destroy(pm_uuid) + +TelegramSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Telegram Source Property Mapping. + + try: + api_instance.propertymappings_source_telegram_destroy(pm_uuid) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_telegram_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Telegram Source Property Mapping. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_telegram_list** +> PaginatedTelegramSourcePropertyMappingList propertymappings_source_telegram_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +TelegramSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_telegram_source_property_mapping_list import PaginatedTelegramSourcePropertyMappingList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.propertymappings_source_telegram_list(managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of PropertymappingsApi->propertymappings_source_telegram_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_telegram_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedTelegramSourcePropertyMappingList**](PaginatedTelegramSourcePropertyMappingList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_telegram_partial_update** +> TelegramSourcePropertyMapping propertymappings_source_telegram_partial_update(pm_uuid, patched_telegram_source_property_mapping_request=patched_telegram_source_property_mapping_request) + +TelegramSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_telegram_source_property_mapping_request import PatchedTelegramSourcePropertyMappingRequest +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Telegram Source Property Mapping. + patched_telegram_source_property_mapping_request = authentik_client.PatchedTelegramSourcePropertyMappingRequest() # PatchedTelegramSourcePropertyMappingRequest | (optional) + + try: + api_response = api_instance.propertymappings_source_telegram_partial_update(pm_uuid, patched_telegram_source_property_mapping_request=patched_telegram_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_telegram_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_telegram_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Telegram Source Property Mapping. | + **patched_telegram_source_property_mapping_request** | [**PatchedTelegramSourcePropertyMappingRequest**](PatchedTelegramSourcePropertyMappingRequest.md)| | [optional] + +### Return type + +[**TelegramSourcePropertyMapping**](TelegramSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_telegram_retrieve** +> TelegramSourcePropertyMapping propertymappings_source_telegram_retrieve(pm_uuid) + +TelegramSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Telegram Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_telegram_retrieve(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_telegram_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_telegram_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Telegram Source Property Mapping. | + +### Return type + +[**TelegramSourcePropertyMapping**](TelegramSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_telegram_update** +> TelegramSourcePropertyMapping propertymappings_source_telegram_update(pm_uuid, telegram_source_property_mapping_request) + +TelegramSourcePropertyMapping Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping +from authentik_client.models.telegram_source_property_mapping_request import TelegramSourcePropertyMappingRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Telegram Source Property Mapping. + telegram_source_property_mapping_request = authentik_client.TelegramSourcePropertyMappingRequest() # TelegramSourcePropertyMappingRequest | + + try: + api_response = api_instance.propertymappings_source_telegram_update(pm_uuid, telegram_source_property_mapping_request) + print("The response of PropertymappingsApi->propertymappings_source_telegram_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_telegram_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Telegram Source Property Mapping. | + **telegram_source_property_mapping_request** | [**TelegramSourcePropertyMappingRequest**](TelegramSourcePropertyMappingRequest.md)| | + +### Return type + +[**TelegramSourcePropertyMapping**](TelegramSourcePropertyMapping.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **propertymappings_source_telegram_used_by_list** +> List[UsedBy] propertymappings_source_telegram_used_by_list(pm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.PropertymappingsApi(api_client) + pm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Telegram Source Property Mapping. + + try: + api_response = api_instance.propertymappings_source_telegram_used_by_list(pm_uuid) + print("The response of PropertymappingsApi->propertymappings_source_telegram_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling PropertymappingsApi->propertymappings_source_telegram_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pm_uuid** | **UUID**| A UUID string identifying this Telegram Source Property Mapping. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/ProtocolEnum.md b/docs/ProtocolEnum.md new file mode 100644 index 000000000..099fc38f1 --- /dev/null +++ b/docs/ProtocolEnum.md @@ -0,0 +1,14 @@ +# ProtocolEnum + + +## Enum + +* `RDP` (value: `'rdp'`) + +* `VNC` (value: `'vnc'`) + +* `SSH` (value: `'ssh'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Provider.md b/docs/Provider.md new file mode 100644 index 000000000..8ea415607 --- /dev/null +++ b/docs/Provider.md @@ -0,0 +1,43 @@ +# Provider + +Provider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_application_name** | **str** | Application's display Name. | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.provider import Provider + +# TODO update the JSON string below +json = "{}" +# create an instance of Provider from a JSON string +provider_instance = Provider.from_json(json) +# print the JSON string representation of the object +print(Provider.to_json()) + +# convert the object into a dict +provider_dict = provider_instance.to_dict() +# create an instance of Provider from a dict +provider_from_dict = Provider.from_dict(provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ProviderEnum.md b/docs/ProviderEnum.md new file mode 100644 index 000000000..ff870220c --- /dev/null +++ b/docs/ProviderEnum.md @@ -0,0 +1,12 @@ +# ProviderEnum + + +## Enum + +* `TWILIO` (value: `'twilio'`) + +* `GENERIC` (value: `'generic'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ProviderModelEnum.md b/docs/ProviderModelEnum.md new file mode 100644 index 000000000..a89118aa0 --- /dev/null +++ b/docs/ProviderModelEnum.md @@ -0,0 +1,30 @@ +# ProviderModelEnum + + +## Enum + +* `AUTHENTIK_PROVIDERS_GOOGLE_WORKSPACE_DOT_GOOGLEWORKSPACEPROVIDER` (value: `'authentik_providers_google_workspace.googleworkspaceprovider'`) + +* `AUTHENTIK_PROVIDERS_LDAP_DOT_LDAPPROVIDER` (value: `'authentik_providers_ldap.ldapprovider'`) + +* `AUTHENTIK_PROVIDERS_MICROSOFT_ENTRA_DOT_MICROSOFTENTRAPROVIDER` (value: `'authentik_providers_microsoft_entra.microsoftentraprovider'`) + +* `AUTHENTIK_PROVIDERS_OAUTH2_DOT_OAUTH2PROVIDER` (value: `'authentik_providers_oauth2.oauth2provider'`) + +* `AUTHENTIK_PROVIDERS_PROXY_DOT_PROXYPROVIDER` (value: `'authentik_providers_proxy.proxyprovider'`) + +* `AUTHENTIK_PROVIDERS_RAC_DOT_RACPROVIDER` (value: `'authentik_providers_rac.racprovider'`) + +* `AUTHENTIK_PROVIDERS_RADIUS_DOT_RADIUSPROVIDER` (value: `'authentik_providers_radius.radiusprovider'`) + +* `AUTHENTIK_PROVIDERS_SAML_DOT_SAMLPROVIDER` (value: `'authentik_providers_saml.samlprovider'`) + +* `AUTHENTIK_PROVIDERS_SCIM_DOT_SCIMPROVIDER` (value: `'authentik_providers_scim.scimprovider'`) + +* `AUTHENTIK_PROVIDERS_SSF_DOT_SSFPROVIDER` (value: `'authentik_providers_ssf.ssfprovider'`) + +* `AUTHENTIK_PROVIDERS_WS_FEDERATION_DOT_WSFEDERATIONPROVIDER` (value: `'authentik_providers_ws_federation.wsfederationprovider'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ProviderTypeEnum.md b/docs/ProviderTypeEnum.md new file mode 100644 index 000000000..9201c93cc --- /dev/null +++ b/docs/ProviderTypeEnum.md @@ -0,0 +1,42 @@ +# ProviderTypeEnum + + +## Enum + +* `OPENIDCONNECT` (value: `'openidconnect'`) + +* `APPLE` (value: `'apple'`) + +* `ENTRAID` (value: `'entraid'`) + +* `AZUREAD` (value: `'azuread'`) + +* `DISCORD` (value: `'discord'`) + +* `FACEBOOK` (value: `'facebook'`) + +* `GITHUB` (value: `'github'`) + +* `GITLAB` (value: `'gitlab'`) + +* `GOOGLE` (value: `'google'`) + +* `MAILCOW` (value: `'mailcow'`) + +* `OKTA` (value: `'okta'`) + +* `PATREON` (value: `'patreon'`) + +* `REDDIT` (value: `'reddit'`) + +* `SLACK` (value: `'slack'`) + +* `TWITCH` (value: `'twitch'`) + +* `TWITTER` (value: `'twitter'`) + +* `WECHAT` (value: `'wechat'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ProvidersApi.md b/docs/ProvidersApi.md new file mode 100644 index 000000000..baab96369 --- /dev/null +++ b/docs/ProvidersApi.md @@ -0,0 +1,10201 @@ +# authentik_client.ProvidersApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**providers_all_destroy**](ProvidersApi.md#providers_all_destroy) | **DELETE** /providers/all/{id}/ | +[**providers_all_list**](ProvidersApi.md#providers_all_list) | **GET** /providers/all/ | +[**providers_all_retrieve**](ProvidersApi.md#providers_all_retrieve) | **GET** /providers/all/{id}/ | +[**providers_all_types_list**](ProvidersApi.md#providers_all_types_list) | **GET** /providers/all/types/ | +[**providers_all_used_by_list**](ProvidersApi.md#providers_all_used_by_list) | **GET** /providers/all/{id}/used_by/ | +[**providers_google_workspace_create**](ProvidersApi.md#providers_google_workspace_create) | **POST** /providers/google_workspace/ | +[**providers_google_workspace_destroy**](ProvidersApi.md#providers_google_workspace_destroy) | **DELETE** /providers/google_workspace/{id}/ | +[**providers_google_workspace_groups_create**](ProvidersApi.md#providers_google_workspace_groups_create) | **POST** /providers/google_workspace_groups/ | +[**providers_google_workspace_groups_destroy**](ProvidersApi.md#providers_google_workspace_groups_destroy) | **DELETE** /providers/google_workspace_groups/{id}/ | +[**providers_google_workspace_groups_list**](ProvidersApi.md#providers_google_workspace_groups_list) | **GET** /providers/google_workspace_groups/ | +[**providers_google_workspace_groups_retrieve**](ProvidersApi.md#providers_google_workspace_groups_retrieve) | **GET** /providers/google_workspace_groups/{id}/ | +[**providers_google_workspace_groups_used_by_list**](ProvidersApi.md#providers_google_workspace_groups_used_by_list) | **GET** /providers/google_workspace_groups/{id}/used_by/ | +[**providers_google_workspace_list**](ProvidersApi.md#providers_google_workspace_list) | **GET** /providers/google_workspace/ | +[**providers_google_workspace_partial_update**](ProvidersApi.md#providers_google_workspace_partial_update) | **PATCH** /providers/google_workspace/{id}/ | +[**providers_google_workspace_retrieve**](ProvidersApi.md#providers_google_workspace_retrieve) | **GET** /providers/google_workspace/{id}/ | +[**providers_google_workspace_sync_object_create**](ProvidersApi.md#providers_google_workspace_sync_object_create) | **POST** /providers/google_workspace/{id}/sync/object/ | +[**providers_google_workspace_sync_status_retrieve**](ProvidersApi.md#providers_google_workspace_sync_status_retrieve) | **GET** /providers/google_workspace/{id}/sync/status/ | +[**providers_google_workspace_update**](ProvidersApi.md#providers_google_workspace_update) | **PUT** /providers/google_workspace/{id}/ | +[**providers_google_workspace_used_by_list**](ProvidersApi.md#providers_google_workspace_used_by_list) | **GET** /providers/google_workspace/{id}/used_by/ | +[**providers_google_workspace_users_create**](ProvidersApi.md#providers_google_workspace_users_create) | **POST** /providers/google_workspace_users/ | +[**providers_google_workspace_users_destroy**](ProvidersApi.md#providers_google_workspace_users_destroy) | **DELETE** /providers/google_workspace_users/{id}/ | +[**providers_google_workspace_users_list**](ProvidersApi.md#providers_google_workspace_users_list) | **GET** /providers/google_workspace_users/ | +[**providers_google_workspace_users_retrieve**](ProvidersApi.md#providers_google_workspace_users_retrieve) | **GET** /providers/google_workspace_users/{id}/ | +[**providers_google_workspace_users_used_by_list**](ProvidersApi.md#providers_google_workspace_users_used_by_list) | **GET** /providers/google_workspace_users/{id}/used_by/ | +[**providers_ldap_create**](ProvidersApi.md#providers_ldap_create) | **POST** /providers/ldap/ | +[**providers_ldap_destroy**](ProvidersApi.md#providers_ldap_destroy) | **DELETE** /providers/ldap/{id}/ | +[**providers_ldap_list**](ProvidersApi.md#providers_ldap_list) | **GET** /providers/ldap/ | +[**providers_ldap_partial_update**](ProvidersApi.md#providers_ldap_partial_update) | **PATCH** /providers/ldap/{id}/ | +[**providers_ldap_retrieve**](ProvidersApi.md#providers_ldap_retrieve) | **GET** /providers/ldap/{id}/ | +[**providers_ldap_update**](ProvidersApi.md#providers_ldap_update) | **PUT** /providers/ldap/{id}/ | +[**providers_ldap_used_by_list**](ProvidersApi.md#providers_ldap_used_by_list) | **GET** /providers/ldap/{id}/used_by/ | +[**providers_microsoft_entra_create**](ProvidersApi.md#providers_microsoft_entra_create) | **POST** /providers/microsoft_entra/ | +[**providers_microsoft_entra_destroy**](ProvidersApi.md#providers_microsoft_entra_destroy) | **DELETE** /providers/microsoft_entra/{id}/ | +[**providers_microsoft_entra_groups_create**](ProvidersApi.md#providers_microsoft_entra_groups_create) | **POST** /providers/microsoft_entra_groups/ | +[**providers_microsoft_entra_groups_destroy**](ProvidersApi.md#providers_microsoft_entra_groups_destroy) | **DELETE** /providers/microsoft_entra_groups/{id}/ | +[**providers_microsoft_entra_groups_list**](ProvidersApi.md#providers_microsoft_entra_groups_list) | **GET** /providers/microsoft_entra_groups/ | +[**providers_microsoft_entra_groups_retrieve**](ProvidersApi.md#providers_microsoft_entra_groups_retrieve) | **GET** /providers/microsoft_entra_groups/{id}/ | +[**providers_microsoft_entra_groups_used_by_list**](ProvidersApi.md#providers_microsoft_entra_groups_used_by_list) | **GET** /providers/microsoft_entra_groups/{id}/used_by/ | +[**providers_microsoft_entra_list**](ProvidersApi.md#providers_microsoft_entra_list) | **GET** /providers/microsoft_entra/ | +[**providers_microsoft_entra_partial_update**](ProvidersApi.md#providers_microsoft_entra_partial_update) | **PATCH** /providers/microsoft_entra/{id}/ | +[**providers_microsoft_entra_retrieve**](ProvidersApi.md#providers_microsoft_entra_retrieve) | **GET** /providers/microsoft_entra/{id}/ | +[**providers_microsoft_entra_sync_object_create**](ProvidersApi.md#providers_microsoft_entra_sync_object_create) | **POST** /providers/microsoft_entra/{id}/sync/object/ | +[**providers_microsoft_entra_sync_status_retrieve**](ProvidersApi.md#providers_microsoft_entra_sync_status_retrieve) | **GET** /providers/microsoft_entra/{id}/sync/status/ | +[**providers_microsoft_entra_update**](ProvidersApi.md#providers_microsoft_entra_update) | **PUT** /providers/microsoft_entra/{id}/ | +[**providers_microsoft_entra_used_by_list**](ProvidersApi.md#providers_microsoft_entra_used_by_list) | **GET** /providers/microsoft_entra/{id}/used_by/ | +[**providers_microsoft_entra_users_create**](ProvidersApi.md#providers_microsoft_entra_users_create) | **POST** /providers/microsoft_entra_users/ | +[**providers_microsoft_entra_users_destroy**](ProvidersApi.md#providers_microsoft_entra_users_destroy) | **DELETE** /providers/microsoft_entra_users/{id}/ | +[**providers_microsoft_entra_users_list**](ProvidersApi.md#providers_microsoft_entra_users_list) | **GET** /providers/microsoft_entra_users/ | +[**providers_microsoft_entra_users_retrieve**](ProvidersApi.md#providers_microsoft_entra_users_retrieve) | **GET** /providers/microsoft_entra_users/{id}/ | +[**providers_microsoft_entra_users_used_by_list**](ProvidersApi.md#providers_microsoft_entra_users_used_by_list) | **GET** /providers/microsoft_entra_users/{id}/used_by/ | +[**providers_oauth2_create**](ProvidersApi.md#providers_oauth2_create) | **POST** /providers/oauth2/ | +[**providers_oauth2_destroy**](ProvidersApi.md#providers_oauth2_destroy) | **DELETE** /providers/oauth2/{id}/ | +[**providers_oauth2_list**](ProvidersApi.md#providers_oauth2_list) | **GET** /providers/oauth2/ | +[**providers_oauth2_partial_update**](ProvidersApi.md#providers_oauth2_partial_update) | **PATCH** /providers/oauth2/{id}/ | +[**providers_oauth2_preview_user_retrieve**](ProvidersApi.md#providers_oauth2_preview_user_retrieve) | **GET** /providers/oauth2/{id}/preview_user/ | +[**providers_oauth2_retrieve**](ProvidersApi.md#providers_oauth2_retrieve) | **GET** /providers/oauth2/{id}/ | +[**providers_oauth2_setup_urls_retrieve**](ProvidersApi.md#providers_oauth2_setup_urls_retrieve) | **GET** /providers/oauth2/{id}/setup_urls/ | +[**providers_oauth2_update**](ProvidersApi.md#providers_oauth2_update) | **PUT** /providers/oauth2/{id}/ | +[**providers_oauth2_used_by_list**](ProvidersApi.md#providers_oauth2_used_by_list) | **GET** /providers/oauth2/{id}/used_by/ | +[**providers_proxy_create**](ProvidersApi.md#providers_proxy_create) | **POST** /providers/proxy/ | +[**providers_proxy_destroy**](ProvidersApi.md#providers_proxy_destroy) | **DELETE** /providers/proxy/{id}/ | +[**providers_proxy_list**](ProvidersApi.md#providers_proxy_list) | **GET** /providers/proxy/ | +[**providers_proxy_partial_update**](ProvidersApi.md#providers_proxy_partial_update) | **PATCH** /providers/proxy/{id}/ | +[**providers_proxy_retrieve**](ProvidersApi.md#providers_proxy_retrieve) | **GET** /providers/proxy/{id}/ | +[**providers_proxy_update**](ProvidersApi.md#providers_proxy_update) | **PUT** /providers/proxy/{id}/ | +[**providers_proxy_used_by_list**](ProvidersApi.md#providers_proxy_used_by_list) | **GET** /providers/proxy/{id}/used_by/ | +[**providers_rac_create**](ProvidersApi.md#providers_rac_create) | **POST** /providers/rac/ | +[**providers_rac_destroy**](ProvidersApi.md#providers_rac_destroy) | **DELETE** /providers/rac/{id}/ | +[**providers_rac_list**](ProvidersApi.md#providers_rac_list) | **GET** /providers/rac/ | +[**providers_rac_partial_update**](ProvidersApi.md#providers_rac_partial_update) | **PATCH** /providers/rac/{id}/ | +[**providers_rac_retrieve**](ProvidersApi.md#providers_rac_retrieve) | **GET** /providers/rac/{id}/ | +[**providers_rac_update**](ProvidersApi.md#providers_rac_update) | **PUT** /providers/rac/{id}/ | +[**providers_rac_used_by_list**](ProvidersApi.md#providers_rac_used_by_list) | **GET** /providers/rac/{id}/used_by/ | +[**providers_radius_create**](ProvidersApi.md#providers_radius_create) | **POST** /providers/radius/ | +[**providers_radius_destroy**](ProvidersApi.md#providers_radius_destroy) | **DELETE** /providers/radius/{id}/ | +[**providers_radius_list**](ProvidersApi.md#providers_radius_list) | **GET** /providers/radius/ | +[**providers_radius_partial_update**](ProvidersApi.md#providers_radius_partial_update) | **PATCH** /providers/radius/{id}/ | +[**providers_radius_retrieve**](ProvidersApi.md#providers_radius_retrieve) | **GET** /providers/radius/{id}/ | +[**providers_radius_update**](ProvidersApi.md#providers_radius_update) | **PUT** /providers/radius/{id}/ | +[**providers_radius_used_by_list**](ProvidersApi.md#providers_radius_used_by_list) | **GET** /providers/radius/{id}/used_by/ | +[**providers_saml_create**](ProvidersApi.md#providers_saml_create) | **POST** /providers/saml/ | +[**providers_saml_destroy**](ProvidersApi.md#providers_saml_destroy) | **DELETE** /providers/saml/{id}/ | +[**providers_saml_import_metadata_create**](ProvidersApi.md#providers_saml_import_metadata_create) | **POST** /providers/saml/import_metadata/ | +[**providers_saml_list**](ProvidersApi.md#providers_saml_list) | **GET** /providers/saml/ | +[**providers_saml_metadata_retrieve**](ProvidersApi.md#providers_saml_metadata_retrieve) | **GET** /providers/saml/{id}/metadata/ | +[**providers_saml_partial_update**](ProvidersApi.md#providers_saml_partial_update) | **PATCH** /providers/saml/{id}/ | +[**providers_saml_preview_user_retrieve**](ProvidersApi.md#providers_saml_preview_user_retrieve) | **GET** /providers/saml/{id}/preview_user/ | +[**providers_saml_retrieve**](ProvidersApi.md#providers_saml_retrieve) | **GET** /providers/saml/{id}/ | +[**providers_saml_update**](ProvidersApi.md#providers_saml_update) | **PUT** /providers/saml/{id}/ | +[**providers_saml_used_by_list**](ProvidersApi.md#providers_saml_used_by_list) | **GET** /providers/saml/{id}/used_by/ | +[**providers_scim_create**](ProvidersApi.md#providers_scim_create) | **POST** /providers/scim/ | +[**providers_scim_destroy**](ProvidersApi.md#providers_scim_destroy) | **DELETE** /providers/scim/{id}/ | +[**providers_scim_groups_create**](ProvidersApi.md#providers_scim_groups_create) | **POST** /providers/scim_groups/ | +[**providers_scim_groups_destroy**](ProvidersApi.md#providers_scim_groups_destroy) | **DELETE** /providers/scim_groups/{id}/ | +[**providers_scim_groups_list**](ProvidersApi.md#providers_scim_groups_list) | **GET** /providers/scim_groups/ | +[**providers_scim_groups_retrieve**](ProvidersApi.md#providers_scim_groups_retrieve) | **GET** /providers/scim_groups/{id}/ | +[**providers_scim_groups_used_by_list**](ProvidersApi.md#providers_scim_groups_used_by_list) | **GET** /providers/scim_groups/{id}/used_by/ | +[**providers_scim_list**](ProvidersApi.md#providers_scim_list) | **GET** /providers/scim/ | +[**providers_scim_partial_update**](ProvidersApi.md#providers_scim_partial_update) | **PATCH** /providers/scim/{id}/ | +[**providers_scim_retrieve**](ProvidersApi.md#providers_scim_retrieve) | **GET** /providers/scim/{id}/ | +[**providers_scim_sync_object_create**](ProvidersApi.md#providers_scim_sync_object_create) | **POST** /providers/scim/{id}/sync/object/ | +[**providers_scim_sync_status_retrieve**](ProvidersApi.md#providers_scim_sync_status_retrieve) | **GET** /providers/scim/{id}/sync/status/ | +[**providers_scim_update**](ProvidersApi.md#providers_scim_update) | **PUT** /providers/scim/{id}/ | +[**providers_scim_used_by_list**](ProvidersApi.md#providers_scim_used_by_list) | **GET** /providers/scim/{id}/used_by/ | +[**providers_scim_users_create**](ProvidersApi.md#providers_scim_users_create) | **POST** /providers/scim_users/ | +[**providers_scim_users_destroy**](ProvidersApi.md#providers_scim_users_destroy) | **DELETE** /providers/scim_users/{id}/ | +[**providers_scim_users_list**](ProvidersApi.md#providers_scim_users_list) | **GET** /providers/scim_users/ | +[**providers_scim_users_retrieve**](ProvidersApi.md#providers_scim_users_retrieve) | **GET** /providers/scim_users/{id}/ | +[**providers_scim_users_used_by_list**](ProvidersApi.md#providers_scim_users_used_by_list) | **GET** /providers/scim_users/{id}/used_by/ | +[**providers_ssf_create**](ProvidersApi.md#providers_ssf_create) | **POST** /providers/ssf/ | +[**providers_ssf_destroy**](ProvidersApi.md#providers_ssf_destroy) | **DELETE** /providers/ssf/{id}/ | +[**providers_ssf_list**](ProvidersApi.md#providers_ssf_list) | **GET** /providers/ssf/ | +[**providers_ssf_partial_update**](ProvidersApi.md#providers_ssf_partial_update) | **PATCH** /providers/ssf/{id}/ | +[**providers_ssf_retrieve**](ProvidersApi.md#providers_ssf_retrieve) | **GET** /providers/ssf/{id}/ | +[**providers_ssf_update**](ProvidersApi.md#providers_ssf_update) | **PUT** /providers/ssf/{id}/ | +[**providers_ssf_used_by_list**](ProvidersApi.md#providers_ssf_used_by_list) | **GET** /providers/ssf/{id}/used_by/ | +[**providers_wsfed_create**](ProvidersApi.md#providers_wsfed_create) | **POST** /providers/wsfed/ | +[**providers_wsfed_destroy**](ProvidersApi.md#providers_wsfed_destroy) | **DELETE** /providers/wsfed/{id}/ | +[**providers_wsfed_list**](ProvidersApi.md#providers_wsfed_list) | **GET** /providers/wsfed/ | +[**providers_wsfed_metadata_retrieve**](ProvidersApi.md#providers_wsfed_metadata_retrieve) | **GET** /providers/wsfed/{id}/metadata/ | +[**providers_wsfed_partial_update**](ProvidersApi.md#providers_wsfed_partial_update) | **PATCH** /providers/wsfed/{id}/ | +[**providers_wsfed_preview_user_retrieve**](ProvidersApi.md#providers_wsfed_preview_user_retrieve) | **GET** /providers/wsfed/{id}/preview_user/ | +[**providers_wsfed_retrieve**](ProvidersApi.md#providers_wsfed_retrieve) | **GET** /providers/wsfed/{id}/ | +[**providers_wsfed_update**](ProvidersApi.md#providers_wsfed_update) | **PUT** /providers/wsfed/{id}/ | +[**providers_wsfed_used_by_list**](ProvidersApi.md#providers_wsfed_used_by_list) | **GET** /providers/wsfed/{id}/used_by/ | + + +# **providers_all_destroy** +> providers_all_destroy(id) + +Provider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this provider. + + try: + api_instance.providers_all_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_all_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_all_list** +> PaginatedProviderList providers_all_list(application__isnull=application__isnull, backchannel=backchannel, ordering=ordering, page=page, page_size=page_size, search=search) + +Provider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_provider_list import PaginatedProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + application__isnull = True # bool | (optional) + backchannel = True # bool | When not set all providers are returned. When set to true, only backchannel providers are returned. When set to false, backchannel providers are excluded (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.providers_all_list(application__isnull=application__isnull, backchannel=backchannel, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of ProvidersApi->providers_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_all_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **application__isnull** | **bool**| | [optional] + **backchannel** | **bool**| When not set all providers are returned. When set to true, only backchannel providers are returned. When set to false, backchannel providers are excluded | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedProviderList**](PaginatedProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_all_retrieve** +> Provider providers_all_retrieve(id) + +Provider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.provider import Provider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this provider. + + try: + api_response = api_instance.providers_all_retrieve(id) + print("The response of ProvidersApi->providers_all_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_all_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this provider. | + +### Return type + +[**Provider**](Provider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_all_types_list** +> List[TypeCreate] providers_all_types_list() + +Get all creatable types + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.type_create import TypeCreate +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + + try: + api_response = api_instance.providers_all_types_list() + print("The response of ProvidersApi->providers_all_types_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_all_types_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[TypeCreate]**](TypeCreate.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_all_used_by_list** +> List[UsedBy] providers_all_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this provider. + + try: + api_response = api_instance.providers_all_used_by_list(id) + print("The response of ProvidersApi->providers_all_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_all_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_create** +> GoogleWorkspaceProvider providers_google_workspace_create(google_workspace_provider_request) + +GoogleWorkspaceProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider +from authentik_client.models.google_workspace_provider_request import GoogleWorkspaceProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + google_workspace_provider_request = authentik_client.GoogleWorkspaceProviderRequest() # GoogleWorkspaceProviderRequest | + + try: + api_response = api_instance.providers_google_workspace_create(google_workspace_provider_request) + print("The response of ProvidersApi->providers_google_workspace_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **google_workspace_provider_request** | [**GoogleWorkspaceProviderRequest**](GoogleWorkspaceProviderRequest.md)| | + +### Return type + +[**GoogleWorkspaceProvider**](GoogleWorkspaceProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_destroy** +> providers_google_workspace_destroy(id) + +GoogleWorkspaceProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Google Workspace Provider. + + try: + api_instance.providers_google_workspace_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Google Workspace Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_groups_create** +> GoogleWorkspaceProviderGroup providers_google_workspace_groups_create(google_workspace_provider_group_request) + +GoogleWorkspaceProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider_group import GoogleWorkspaceProviderGroup +from authentik_client.models.google_workspace_provider_group_request import GoogleWorkspaceProviderGroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + google_workspace_provider_group_request = authentik_client.GoogleWorkspaceProviderGroupRequest() # GoogleWorkspaceProviderGroupRequest | + + try: + api_response = api_instance.providers_google_workspace_groups_create(google_workspace_provider_group_request) + print("The response of ProvidersApi->providers_google_workspace_groups_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_groups_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **google_workspace_provider_group_request** | [**GoogleWorkspaceProviderGroupRequest**](GoogleWorkspaceProviderGroupRequest.md)| | + +### Return type + +[**GoogleWorkspaceProviderGroup**](GoogleWorkspaceProviderGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_groups_destroy** +> providers_google_workspace_groups_destroy(id) + +GoogleWorkspaceProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider Group. + + try: + api_instance.providers_google_workspace_groups_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_groups_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Google Workspace Provider Group. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_groups_list** +> PaginatedGoogleWorkspaceProviderGroupList providers_google_workspace_groups_list(group__group_uuid=group__group_uuid, group__name=group__name, ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search) + +GoogleWorkspaceProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_google_workspace_provider_group_list import PaginatedGoogleWorkspaceProviderGroupList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + group__group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + group__name = 'group__name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider__id = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.providers_google_workspace_groups_list(group__group_uuid=group__group_uuid, group__name=group__name, ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search) + print("The response of ProvidersApi->providers_google_workspace_groups_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_groups_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group__group_uuid** | **UUID**| | [optional] + **group__name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider__id** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedGoogleWorkspaceProviderGroupList**](PaginatedGoogleWorkspaceProviderGroupList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_groups_retrieve** +> GoogleWorkspaceProviderGroup providers_google_workspace_groups_retrieve(id) + +GoogleWorkspaceProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider_group import GoogleWorkspaceProviderGroup +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider Group. + + try: + api_response = api_instance.providers_google_workspace_groups_retrieve(id) + print("The response of ProvidersApi->providers_google_workspace_groups_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_groups_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Google Workspace Provider Group. | + +### Return type + +[**GoogleWorkspaceProviderGroup**](GoogleWorkspaceProviderGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_groups_used_by_list** +> List[UsedBy] providers_google_workspace_groups_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider Group. + + try: + api_response = api_instance.providers_google_workspace_groups_used_by_list(id) + print("The response of ProvidersApi->providers_google_workspace_groups_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_groups_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Google Workspace Provider Group. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_list** +> PaginatedGoogleWorkspaceProviderList providers_google_workspace_list(delegated_subject=delegated_subject, exclude_users_service_account=exclude_users_service_account, filter_group=filter_group, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +GoogleWorkspaceProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_google_workspace_provider_list import PaginatedGoogleWorkspaceProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + delegated_subject = 'delegated_subject_example' # str | (optional) + exclude_users_service_account = True # bool | (optional) + filter_group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.providers_google_workspace_list(delegated_subject=delegated_subject, exclude_users_service_account=exclude_users_service_account, filter_group=filter_group, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of ProvidersApi->providers_google_workspace_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **delegated_subject** | **str**| | [optional] + **exclude_users_service_account** | **bool**| | [optional] + **filter_group** | **UUID**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedGoogleWorkspaceProviderList**](PaginatedGoogleWorkspaceProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_partial_update** +> GoogleWorkspaceProvider providers_google_workspace_partial_update(id, patched_google_workspace_provider_request=patched_google_workspace_provider_request) + +GoogleWorkspaceProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider +from authentik_client.models.patched_google_workspace_provider_request import PatchedGoogleWorkspaceProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Google Workspace Provider. + patched_google_workspace_provider_request = authentik_client.PatchedGoogleWorkspaceProviderRequest() # PatchedGoogleWorkspaceProviderRequest | (optional) + + try: + api_response = api_instance.providers_google_workspace_partial_update(id, patched_google_workspace_provider_request=patched_google_workspace_provider_request) + print("The response of ProvidersApi->providers_google_workspace_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Google Workspace Provider. | + **patched_google_workspace_provider_request** | [**PatchedGoogleWorkspaceProviderRequest**](PatchedGoogleWorkspaceProviderRequest.md)| | [optional] + +### Return type + +[**GoogleWorkspaceProvider**](GoogleWorkspaceProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_retrieve** +> GoogleWorkspaceProvider providers_google_workspace_retrieve(id) + +GoogleWorkspaceProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Google Workspace Provider. + + try: + api_response = api_instance.providers_google_workspace_retrieve(id) + print("The response of ProvidersApi->providers_google_workspace_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Google Workspace Provider. | + +### Return type + +[**GoogleWorkspaceProvider**](GoogleWorkspaceProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_sync_object_create** +> SyncObjectResult providers_google_workspace_sync_object_create(id, sync_object_request) + +Sync/Re-sync a single user/group object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sync_object_request import SyncObjectRequest +from authentik_client.models.sync_object_result import SyncObjectResult +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Google Workspace Provider. + sync_object_request = authentik_client.SyncObjectRequest() # SyncObjectRequest | + + try: + api_response = api_instance.providers_google_workspace_sync_object_create(id, sync_object_request) + print("The response of ProvidersApi->providers_google_workspace_sync_object_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_sync_object_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Google Workspace Provider. | + **sync_object_request** | [**SyncObjectRequest**](SyncObjectRequest.md)| | + +### Return type + +[**SyncObjectResult**](SyncObjectResult.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_sync_status_retrieve** +> SyncStatus providers_google_workspace_sync_status_retrieve(id) + +Get provider's sync status + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sync_status import SyncStatus +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Google Workspace Provider. + + try: + api_response = api_instance.providers_google_workspace_sync_status_retrieve(id) + print("The response of ProvidersApi->providers_google_workspace_sync_status_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_sync_status_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Google Workspace Provider. | + +### Return type + +[**SyncStatus**](SyncStatus.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_update** +> GoogleWorkspaceProvider providers_google_workspace_update(id, google_workspace_provider_request) + +GoogleWorkspaceProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider +from authentik_client.models.google_workspace_provider_request import GoogleWorkspaceProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Google Workspace Provider. + google_workspace_provider_request = authentik_client.GoogleWorkspaceProviderRequest() # GoogleWorkspaceProviderRequest | + + try: + api_response = api_instance.providers_google_workspace_update(id, google_workspace_provider_request) + print("The response of ProvidersApi->providers_google_workspace_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Google Workspace Provider. | + **google_workspace_provider_request** | [**GoogleWorkspaceProviderRequest**](GoogleWorkspaceProviderRequest.md)| | + +### Return type + +[**GoogleWorkspaceProvider**](GoogleWorkspaceProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_used_by_list** +> List[UsedBy] providers_google_workspace_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Google Workspace Provider. + + try: + api_response = api_instance.providers_google_workspace_used_by_list(id) + print("The response of ProvidersApi->providers_google_workspace_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Google Workspace Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_users_create** +> GoogleWorkspaceProviderUser providers_google_workspace_users_create(google_workspace_provider_user_request) + +GoogleWorkspaceProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider_user import GoogleWorkspaceProviderUser +from authentik_client.models.google_workspace_provider_user_request import GoogleWorkspaceProviderUserRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + google_workspace_provider_user_request = authentik_client.GoogleWorkspaceProviderUserRequest() # GoogleWorkspaceProviderUserRequest | + + try: + api_response = api_instance.providers_google_workspace_users_create(google_workspace_provider_user_request) + print("The response of ProvidersApi->providers_google_workspace_users_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_users_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **google_workspace_provider_user_request** | [**GoogleWorkspaceProviderUserRequest**](GoogleWorkspaceProviderUserRequest.md)| | + +### Return type + +[**GoogleWorkspaceProviderUser**](GoogleWorkspaceProviderUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_users_destroy** +> providers_google_workspace_users_destroy(id) + +GoogleWorkspaceProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider User. + + try: + api_instance.providers_google_workspace_users_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_users_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Google Workspace Provider User. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_users_list** +> PaginatedGoogleWorkspaceProviderUserList providers_google_workspace_users_list(ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search, user__id=user__id, user__username=user__username) + +GoogleWorkspaceProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_google_workspace_provider_user_list import PaginatedGoogleWorkspaceProviderUserList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider__id = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + user__id = 56 # int | (optional) + user__username = 'user__username_example' # str | (optional) + + try: + api_response = api_instance.providers_google_workspace_users_list(ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search, user__id=user__id, user__username=user__username) + print("The response of ProvidersApi->providers_google_workspace_users_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_users_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider__id** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **user__id** | **int**| | [optional] + **user__username** | **str**| | [optional] + +### Return type + +[**PaginatedGoogleWorkspaceProviderUserList**](PaginatedGoogleWorkspaceProviderUserList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_users_retrieve** +> GoogleWorkspaceProviderUser providers_google_workspace_users_retrieve(id) + +GoogleWorkspaceProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.google_workspace_provider_user import GoogleWorkspaceProviderUser +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider User. + + try: + api_response = api_instance.providers_google_workspace_users_retrieve(id) + print("The response of ProvidersApi->providers_google_workspace_users_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_users_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Google Workspace Provider User. | + +### Return type + +[**GoogleWorkspaceProviderUser**](GoogleWorkspaceProviderUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_google_workspace_users_used_by_list** +> List[UsedBy] providers_google_workspace_users_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Google Workspace Provider User. + + try: + api_response = api_instance.providers_google_workspace_users_used_by_list(id) + print("The response of ProvidersApi->providers_google_workspace_users_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_google_workspace_users_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Google Workspace Provider User. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ldap_create** +> LDAPProvider providers_ldap_create(ldap_provider_request) + +LDAPProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_provider import LDAPProvider +from authentik_client.models.ldap_provider_request import LDAPProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + ldap_provider_request = authentik_client.LDAPProviderRequest() # LDAPProviderRequest | + + try: + api_response = api_instance.providers_ldap_create(ldap_provider_request) + print("The response of ProvidersApi->providers_ldap_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ldap_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ldap_provider_request** | [**LDAPProviderRequest**](LDAPProviderRequest.md)| | + +### Return type + +[**LDAPProvider**](LDAPProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ldap_destroy** +> providers_ldap_destroy(id) + +LDAPProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this LDAP Provider. + + try: + api_instance.providers_ldap_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ldap_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this LDAP Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ldap_list** +> PaginatedLDAPProviderList providers_ldap_list(application__isnull=application__isnull, authorization_flow__slug__iexact=authorization_flow__slug__iexact, base_dn__iexact=base_dn__iexact, certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, certificate__name__iexact=certificate__name__iexact, gid_start_number__iexact=gid_start_number__iexact, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, search=search, tls_server_name__iexact=tls_server_name__iexact, uid_start_number__iexact=uid_start_number__iexact) + +LDAPProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_ldap_provider_list import PaginatedLDAPProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + application__isnull = True # bool | (optional) + authorization_flow__slug__iexact = 'authorization_flow__slug__iexact_example' # str | (optional) + base_dn__iexact = 'base_dn__iexact_example' # str | (optional) + certificate__kp_uuid__iexact = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + certificate__name__iexact = 'certificate__name__iexact_example' # str | (optional) + gid_start_number__iexact = 56 # int | (optional) + name__iexact = 'name__iexact_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + tls_server_name__iexact = 'tls_server_name__iexact_example' # str | (optional) + uid_start_number__iexact = 56 # int | (optional) + + try: + api_response = api_instance.providers_ldap_list(application__isnull=application__isnull, authorization_flow__slug__iexact=authorization_flow__slug__iexact, base_dn__iexact=base_dn__iexact, certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, certificate__name__iexact=certificate__name__iexact, gid_start_number__iexact=gid_start_number__iexact, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, search=search, tls_server_name__iexact=tls_server_name__iexact, uid_start_number__iexact=uid_start_number__iexact) + print("The response of ProvidersApi->providers_ldap_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ldap_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **application__isnull** | **bool**| | [optional] + **authorization_flow__slug__iexact** | **str**| | [optional] + **base_dn__iexact** | **str**| | [optional] + **certificate__kp_uuid__iexact** | **UUID**| | [optional] + **certificate__name__iexact** | **str**| | [optional] + **gid_start_number__iexact** | **int**| | [optional] + **name__iexact** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **tls_server_name__iexact** | **str**| | [optional] + **uid_start_number__iexact** | **int**| | [optional] + +### Return type + +[**PaginatedLDAPProviderList**](PaginatedLDAPProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ldap_partial_update** +> LDAPProvider providers_ldap_partial_update(id, patched_ldap_provider_request=patched_ldap_provider_request) + +LDAPProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_provider import LDAPProvider +from authentik_client.models.patched_ldap_provider_request import PatchedLDAPProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this LDAP Provider. + patched_ldap_provider_request = authentik_client.PatchedLDAPProviderRequest() # PatchedLDAPProviderRequest | (optional) + + try: + api_response = api_instance.providers_ldap_partial_update(id, patched_ldap_provider_request=patched_ldap_provider_request) + print("The response of ProvidersApi->providers_ldap_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ldap_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this LDAP Provider. | + **patched_ldap_provider_request** | [**PatchedLDAPProviderRequest**](PatchedLDAPProviderRequest.md)| | [optional] + +### Return type + +[**LDAPProvider**](LDAPProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ldap_retrieve** +> LDAPProvider providers_ldap_retrieve(id) + +LDAPProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_provider import LDAPProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this LDAP Provider. + + try: + api_response = api_instance.providers_ldap_retrieve(id) + print("The response of ProvidersApi->providers_ldap_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ldap_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this LDAP Provider. | + +### Return type + +[**LDAPProvider**](LDAPProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ldap_update** +> LDAPProvider providers_ldap_update(id, ldap_provider_request) + +LDAPProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_provider import LDAPProvider +from authentik_client.models.ldap_provider_request import LDAPProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this LDAP Provider. + ldap_provider_request = authentik_client.LDAPProviderRequest() # LDAPProviderRequest | + + try: + api_response = api_instance.providers_ldap_update(id, ldap_provider_request) + print("The response of ProvidersApi->providers_ldap_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ldap_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this LDAP Provider. | + **ldap_provider_request** | [**LDAPProviderRequest**](LDAPProviderRequest.md)| | + +### Return type + +[**LDAPProvider**](LDAPProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ldap_used_by_list** +> List[UsedBy] providers_ldap_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this LDAP Provider. + + try: + api_response = api_instance.providers_ldap_used_by_list(id) + print("The response of ProvidersApi->providers_ldap_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ldap_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this LDAP Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_create** +> MicrosoftEntraProvider providers_microsoft_entra_create(microsoft_entra_provider_request) + +MicrosoftEntraProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider +from authentik_client.models.microsoft_entra_provider_request import MicrosoftEntraProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + microsoft_entra_provider_request = authentik_client.MicrosoftEntraProviderRequest() # MicrosoftEntraProviderRequest | + + try: + api_response = api_instance.providers_microsoft_entra_create(microsoft_entra_provider_request) + print("The response of ProvidersApi->providers_microsoft_entra_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **microsoft_entra_provider_request** | [**MicrosoftEntraProviderRequest**](MicrosoftEntraProviderRequest.md)| | + +### Return type + +[**MicrosoftEntraProvider**](MicrosoftEntraProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_destroy** +> providers_microsoft_entra_destroy(id) + +MicrosoftEntraProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Microsoft Entra Provider. + + try: + api_instance.providers_microsoft_entra_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Microsoft Entra Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_groups_create** +> MicrosoftEntraProviderGroup providers_microsoft_entra_groups_create(microsoft_entra_provider_group_request) + +MicrosoftEntraProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider_group import MicrosoftEntraProviderGroup +from authentik_client.models.microsoft_entra_provider_group_request import MicrosoftEntraProviderGroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + microsoft_entra_provider_group_request = authentik_client.MicrosoftEntraProviderGroupRequest() # MicrosoftEntraProviderGroupRequest | + + try: + api_response = api_instance.providers_microsoft_entra_groups_create(microsoft_entra_provider_group_request) + print("The response of ProvidersApi->providers_microsoft_entra_groups_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_groups_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **microsoft_entra_provider_group_request** | [**MicrosoftEntraProviderGroupRequest**](MicrosoftEntraProviderGroupRequest.md)| | + +### Return type + +[**MicrosoftEntraProviderGroup**](MicrosoftEntraProviderGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_groups_destroy** +> providers_microsoft_entra_groups_destroy(id) + +MicrosoftEntraProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider Group. + + try: + api_instance.providers_microsoft_entra_groups_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_groups_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Microsoft Entra Provider Group. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_groups_list** +> PaginatedMicrosoftEntraProviderGroupList providers_microsoft_entra_groups_list(group__group_uuid=group__group_uuid, group__name=group__name, ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search) + +MicrosoftEntraProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_microsoft_entra_provider_group_list import PaginatedMicrosoftEntraProviderGroupList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + group__group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + group__name = 'group__name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider__id = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.providers_microsoft_entra_groups_list(group__group_uuid=group__group_uuid, group__name=group__name, ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search) + print("The response of ProvidersApi->providers_microsoft_entra_groups_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_groups_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group__group_uuid** | **UUID**| | [optional] + **group__name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider__id** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedMicrosoftEntraProviderGroupList**](PaginatedMicrosoftEntraProviderGroupList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_groups_retrieve** +> MicrosoftEntraProviderGroup providers_microsoft_entra_groups_retrieve(id) + +MicrosoftEntraProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider_group import MicrosoftEntraProviderGroup +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider Group. + + try: + api_response = api_instance.providers_microsoft_entra_groups_retrieve(id) + print("The response of ProvidersApi->providers_microsoft_entra_groups_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_groups_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Microsoft Entra Provider Group. | + +### Return type + +[**MicrosoftEntraProviderGroup**](MicrosoftEntraProviderGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_groups_used_by_list** +> List[UsedBy] providers_microsoft_entra_groups_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider Group. + + try: + api_response = api_instance.providers_microsoft_entra_groups_used_by_list(id) + print("The response of ProvidersApi->providers_microsoft_entra_groups_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_groups_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Microsoft Entra Provider Group. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_list** +> PaginatedMicrosoftEntraProviderList providers_microsoft_entra_list(exclude_users_service_account=exclude_users_service_account, filter_group=filter_group, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +MicrosoftEntraProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_microsoft_entra_provider_list import PaginatedMicrosoftEntraProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + exclude_users_service_account = True # bool | (optional) + filter_group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.providers_microsoft_entra_list(exclude_users_service_account=exclude_users_service_account, filter_group=filter_group, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of ProvidersApi->providers_microsoft_entra_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **exclude_users_service_account** | **bool**| | [optional] + **filter_group** | **UUID**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedMicrosoftEntraProviderList**](PaginatedMicrosoftEntraProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_partial_update** +> MicrosoftEntraProvider providers_microsoft_entra_partial_update(id, patched_microsoft_entra_provider_request=patched_microsoft_entra_provider_request) + +MicrosoftEntraProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider +from authentik_client.models.patched_microsoft_entra_provider_request import PatchedMicrosoftEntraProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Microsoft Entra Provider. + patched_microsoft_entra_provider_request = authentik_client.PatchedMicrosoftEntraProviderRequest() # PatchedMicrosoftEntraProviderRequest | (optional) + + try: + api_response = api_instance.providers_microsoft_entra_partial_update(id, patched_microsoft_entra_provider_request=patched_microsoft_entra_provider_request) + print("The response of ProvidersApi->providers_microsoft_entra_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Microsoft Entra Provider. | + **patched_microsoft_entra_provider_request** | [**PatchedMicrosoftEntraProviderRequest**](PatchedMicrosoftEntraProviderRequest.md)| | [optional] + +### Return type + +[**MicrosoftEntraProvider**](MicrosoftEntraProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_retrieve** +> MicrosoftEntraProvider providers_microsoft_entra_retrieve(id) + +MicrosoftEntraProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Microsoft Entra Provider. + + try: + api_response = api_instance.providers_microsoft_entra_retrieve(id) + print("The response of ProvidersApi->providers_microsoft_entra_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Microsoft Entra Provider. | + +### Return type + +[**MicrosoftEntraProvider**](MicrosoftEntraProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_sync_object_create** +> SyncObjectResult providers_microsoft_entra_sync_object_create(id, sync_object_request) + +Sync/Re-sync a single user/group object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sync_object_request import SyncObjectRequest +from authentik_client.models.sync_object_result import SyncObjectResult +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Microsoft Entra Provider. + sync_object_request = authentik_client.SyncObjectRequest() # SyncObjectRequest | + + try: + api_response = api_instance.providers_microsoft_entra_sync_object_create(id, sync_object_request) + print("The response of ProvidersApi->providers_microsoft_entra_sync_object_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_sync_object_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Microsoft Entra Provider. | + **sync_object_request** | [**SyncObjectRequest**](SyncObjectRequest.md)| | + +### Return type + +[**SyncObjectResult**](SyncObjectResult.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_sync_status_retrieve** +> SyncStatus providers_microsoft_entra_sync_status_retrieve(id) + +Get provider's sync status + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sync_status import SyncStatus +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Microsoft Entra Provider. + + try: + api_response = api_instance.providers_microsoft_entra_sync_status_retrieve(id) + print("The response of ProvidersApi->providers_microsoft_entra_sync_status_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_sync_status_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Microsoft Entra Provider. | + +### Return type + +[**SyncStatus**](SyncStatus.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_update** +> MicrosoftEntraProvider providers_microsoft_entra_update(id, microsoft_entra_provider_request) + +MicrosoftEntraProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider +from authentik_client.models.microsoft_entra_provider_request import MicrosoftEntraProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Microsoft Entra Provider. + microsoft_entra_provider_request = authentik_client.MicrosoftEntraProviderRequest() # MicrosoftEntraProviderRequest | + + try: + api_response = api_instance.providers_microsoft_entra_update(id, microsoft_entra_provider_request) + print("The response of ProvidersApi->providers_microsoft_entra_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Microsoft Entra Provider. | + **microsoft_entra_provider_request** | [**MicrosoftEntraProviderRequest**](MicrosoftEntraProviderRequest.md)| | + +### Return type + +[**MicrosoftEntraProvider**](MicrosoftEntraProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_used_by_list** +> List[UsedBy] providers_microsoft_entra_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Microsoft Entra Provider. + + try: + api_response = api_instance.providers_microsoft_entra_used_by_list(id) + print("The response of ProvidersApi->providers_microsoft_entra_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Microsoft Entra Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_users_create** +> MicrosoftEntraProviderUser providers_microsoft_entra_users_create(microsoft_entra_provider_user_request) + +MicrosoftEntraProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider_user import MicrosoftEntraProviderUser +from authentik_client.models.microsoft_entra_provider_user_request import MicrosoftEntraProviderUserRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + microsoft_entra_provider_user_request = authentik_client.MicrosoftEntraProviderUserRequest() # MicrosoftEntraProviderUserRequest | + + try: + api_response = api_instance.providers_microsoft_entra_users_create(microsoft_entra_provider_user_request) + print("The response of ProvidersApi->providers_microsoft_entra_users_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_users_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **microsoft_entra_provider_user_request** | [**MicrosoftEntraProviderUserRequest**](MicrosoftEntraProviderUserRequest.md)| | + +### Return type + +[**MicrosoftEntraProviderUser**](MicrosoftEntraProviderUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_users_destroy** +> providers_microsoft_entra_users_destroy(id) + +MicrosoftEntraProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider User. + + try: + api_instance.providers_microsoft_entra_users_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_users_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Microsoft Entra Provider User. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_users_list** +> PaginatedMicrosoftEntraProviderUserList providers_microsoft_entra_users_list(ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search, user__id=user__id, user__username=user__username) + +MicrosoftEntraProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_microsoft_entra_provider_user_list import PaginatedMicrosoftEntraProviderUserList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider__id = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + user__id = 56 # int | (optional) + user__username = 'user__username_example' # str | (optional) + + try: + api_response = api_instance.providers_microsoft_entra_users_list(ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search, user__id=user__id, user__username=user__username) + print("The response of ProvidersApi->providers_microsoft_entra_users_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_users_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider__id** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **user__id** | **int**| | [optional] + **user__username** | **str**| | [optional] + +### Return type + +[**PaginatedMicrosoftEntraProviderUserList**](PaginatedMicrosoftEntraProviderUserList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_users_retrieve** +> MicrosoftEntraProviderUser providers_microsoft_entra_users_retrieve(id) + +MicrosoftEntraProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.microsoft_entra_provider_user import MicrosoftEntraProviderUser +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider User. + + try: + api_response = api_instance.providers_microsoft_entra_users_retrieve(id) + print("The response of ProvidersApi->providers_microsoft_entra_users_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_users_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Microsoft Entra Provider User. | + +### Return type + +[**MicrosoftEntraProviderUser**](MicrosoftEntraProviderUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_microsoft_entra_users_used_by_list** +> List[UsedBy] providers_microsoft_entra_users_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Microsoft Entra Provider User. + + try: + api_response = api_instance.providers_microsoft_entra_users_used_by_list(id) + print("The response of ProvidersApi->providers_microsoft_entra_users_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_microsoft_entra_users_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Microsoft Entra Provider User. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_oauth2_create** +> OAuth2Provider providers_oauth2_create(o_auth2_provider_request) + +OAuth2Provider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth2_provider import OAuth2Provider +from authentik_client.models.o_auth2_provider_request import OAuth2ProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + o_auth2_provider_request = authentik_client.OAuth2ProviderRequest() # OAuth2ProviderRequest | + + try: + api_response = api_instance.providers_oauth2_create(o_auth2_provider_request) + print("The response of ProvidersApi->providers_oauth2_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_oauth2_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **o_auth2_provider_request** | [**OAuth2ProviderRequest**](OAuth2ProviderRequest.md)| | + +### Return type + +[**OAuth2Provider**](OAuth2Provider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_oauth2_destroy** +> providers_oauth2_destroy(id) + +OAuth2Provider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this OAuth2/OpenID Provider. + + try: + api_instance.providers_oauth2_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_oauth2_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2/OpenID Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_oauth2_list** +> PaginatedOAuth2ProviderList providers_oauth2_list(access_code_validity=access_code_validity, access_token_validity=access_token_validity, application=application, authorization_flow=authorization_flow, client_id=client_id, client_type=client_type, include_claims_in_id_token=include_claims_in_id_token, issuer_mode=issuer_mode, name=name, ordering=ordering, page=page, page_size=page_size, property_mappings=property_mappings, refresh_token_validity=refresh_token_validity, search=search, signing_key=signing_key, sub_mode=sub_mode) + +OAuth2Provider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_o_auth2_provider_list import PaginatedOAuth2ProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + access_code_validity = 'access_code_validity_example' # str | (optional) + access_token_validity = 'access_token_validity_example' # str | (optional) + application = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + authorization_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + client_id = 'client_id_example' # str | (optional) + client_type = authentik_client.ClientTypeEnum() # ClientTypeEnum | (optional) + include_claims_in_id_token = True # bool | (optional) + issuer_mode = authentik_client.IssuerModeEnum() # IssuerModeEnum | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + property_mappings = None # List[UUID] | (optional) + refresh_token_validity = 'refresh_token_validity_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + signing_key = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + sub_mode = authentik_client.SubModeEnum() # SubModeEnum | (optional) + + try: + api_response = api_instance.providers_oauth2_list(access_code_validity=access_code_validity, access_token_validity=access_token_validity, application=application, authorization_flow=authorization_flow, client_id=client_id, client_type=client_type, include_claims_in_id_token=include_claims_in_id_token, issuer_mode=issuer_mode, name=name, ordering=ordering, page=page, page_size=page_size, property_mappings=property_mappings, refresh_token_validity=refresh_token_validity, search=search, signing_key=signing_key, sub_mode=sub_mode) + print("The response of ProvidersApi->providers_oauth2_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_oauth2_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **access_code_validity** | **str**| | [optional] + **access_token_validity** | **str**| | [optional] + **application** | **UUID**| | [optional] + **authorization_flow** | **UUID**| | [optional] + **client_id** | **str**| | [optional] + **client_type** | [**ClientTypeEnum**](.md)| | [optional] + **include_claims_in_id_token** | **bool**| | [optional] + **issuer_mode** | [**IssuerModeEnum**](.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **property_mappings** | [**List[UUID]**](UUID.md)| | [optional] + **refresh_token_validity** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + **signing_key** | **UUID**| | [optional] + **sub_mode** | [**SubModeEnum**](.md)| | [optional] + +### Return type + +[**PaginatedOAuth2ProviderList**](PaginatedOAuth2ProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_oauth2_partial_update** +> OAuth2Provider providers_oauth2_partial_update(id, patched_o_auth2_provider_request=patched_o_auth2_provider_request) + +OAuth2Provider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth2_provider import OAuth2Provider +from authentik_client.models.patched_o_auth2_provider_request import PatchedOAuth2ProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this OAuth2/OpenID Provider. + patched_o_auth2_provider_request = authentik_client.PatchedOAuth2ProviderRequest() # PatchedOAuth2ProviderRequest | (optional) + + try: + api_response = api_instance.providers_oauth2_partial_update(id, patched_o_auth2_provider_request=patched_o_auth2_provider_request) + print("The response of ProvidersApi->providers_oauth2_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_oauth2_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2/OpenID Provider. | + **patched_o_auth2_provider_request** | [**PatchedOAuth2ProviderRequest**](PatchedOAuth2ProviderRequest.md)| | [optional] + +### Return type + +[**OAuth2Provider**](OAuth2Provider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_oauth2_preview_user_retrieve** +> PropertyMappingPreview providers_oauth2_preview_user_retrieve(id, for_user=for_user) + +Preview user data for provider + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.property_mapping_preview import PropertyMappingPreview +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this OAuth2/OpenID Provider. + for_user = 56 # int | (optional) + + try: + api_response = api_instance.providers_oauth2_preview_user_retrieve(id, for_user=for_user) + print("The response of ProvidersApi->providers_oauth2_preview_user_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_oauth2_preview_user_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2/OpenID Provider. | + **for_user** | **int**| | [optional] + +### Return type + +[**PropertyMappingPreview**](PropertyMappingPreview.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_oauth2_retrieve** +> OAuth2Provider providers_oauth2_retrieve(id) + +OAuth2Provider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth2_provider import OAuth2Provider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this OAuth2/OpenID Provider. + + try: + api_response = api_instance.providers_oauth2_retrieve(id) + print("The response of ProvidersApi->providers_oauth2_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_oauth2_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2/OpenID Provider. | + +### Return type + +[**OAuth2Provider**](OAuth2Provider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_oauth2_setup_urls_retrieve** +> OAuth2ProviderSetupURLs providers_oauth2_setup_urls_retrieve(id) + +Get Providers setup URLs + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth2_provider_setup_urls import OAuth2ProviderSetupURLs +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this OAuth2/OpenID Provider. + + try: + api_response = api_instance.providers_oauth2_setup_urls_retrieve(id) + print("The response of ProvidersApi->providers_oauth2_setup_urls_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_oauth2_setup_urls_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2/OpenID Provider. | + +### Return type + +[**OAuth2ProviderSetupURLs**](OAuth2ProviderSetupURLs.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**404** | Provider has no application assigned | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_oauth2_update** +> OAuth2Provider providers_oauth2_update(id, o_auth2_provider_request) + +OAuth2Provider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth2_provider import OAuth2Provider +from authentik_client.models.o_auth2_provider_request import OAuth2ProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this OAuth2/OpenID Provider. + o_auth2_provider_request = authentik_client.OAuth2ProviderRequest() # OAuth2ProviderRequest | + + try: + api_response = api_instance.providers_oauth2_update(id, o_auth2_provider_request) + print("The response of ProvidersApi->providers_oauth2_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_oauth2_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2/OpenID Provider. | + **o_auth2_provider_request** | [**OAuth2ProviderRequest**](OAuth2ProviderRequest.md)| | + +### Return type + +[**OAuth2Provider**](OAuth2Provider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_oauth2_used_by_list** +> List[UsedBy] providers_oauth2_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this OAuth2/OpenID Provider. + + try: + api_response = api_instance.providers_oauth2_used_by_list(id) + print("The response of ProvidersApi->providers_oauth2_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_oauth2_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this OAuth2/OpenID Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_proxy_create** +> ProxyProvider providers_proxy_create(proxy_provider_request) + +ProxyProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.proxy_provider import ProxyProvider +from authentik_client.models.proxy_provider_request import ProxyProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + proxy_provider_request = authentik_client.ProxyProviderRequest() # ProxyProviderRequest | + + try: + api_response = api_instance.providers_proxy_create(proxy_provider_request) + print("The response of ProvidersApi->providers_proxy_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_proxy_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **proxy_provider_request** | [**ProxyProviderRequest**](ProxyProviderRequest.md)| | + +### Return type + +[**ProxyProvider**](ProxyProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_proxy_destroy** +> providers_proxy_destroy(id) + +ProxyProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Proxy Provider. + + try: + api_instance.providers_proxy_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_proxy_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Proxy Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_proxy_list** +> PaginatedProxyProviderList providers_proxy_list(application__isnull=application__isnull, authorization_flow__slug__iexact=authorization_flow__slug__iexact, basic_auth_enabled__iexact=basic_auth_enabled__iexact, basic_auth_password_attribute__iexact=basic_auth_password_attribute__iexact, basic_auth_user_attribute__iexact=basic_auth_user_attribute__iexact, certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, certificate__name__iexact=certificate__name__iexact, cookie_domain__iexact=cookie_domain__iexact, external_host__iexact=external_host__iexact, internal_host__iexact=internal_host__iexact, internal_host_ssl_validation__iexact=internal_host_ssl_validation__iexact, mode__iexact=mode__iexact, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, property_mappings__iexact=property_mappings__iexact, search=search, skip_path_regex__iexact=skip_path_regex__iexact) + +ProxyProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_proxy_provider_list import PaginatedProxyProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + application__isnull = True # bool | (optional) + authorization_flow__slug__iexact = 'authorization_flow__slug__iexact_example' # str | (optional) + basic_auth_enabled__iexact = True # bool | (optional) + basic_auth_password_attribute__iexact = 'basic_auth_password_attribute__iexact_example' # str | (optional) + basic_auth_user_attribute__iexact = 'basic_auth_user_attribute__iexact_example' # str | (optional) + certificate__kp_uuid__iexact = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + certificate__name__iexact = 'certificate__name__iexact_example' # str | (optional) + cookie_domain__iexact = 'cookie_domain__iexact_example' # str | (optional) + external_host__iexact = 'external_host__iexact_example' # str | (optional) + internal_host__iexact = 'internal_host__iexact_example' # str | (optional) + internal_host_ssl_validation__iexact = True # bool | (optional) + mode__iexact = 'mode__iexact_example' # str | (optional) + name__iexact = 'name__iexact_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + property_mappings__iexact = None # List[UUID] | (optional) + search = 'search_example' # str | A search term. (optional) + skip_path_regex__iexact = 'skip_path_regex__iexact_example' # str | (optional) + + try: + api_response = api_instance.providers_proxy_list(application__isnull=application__isnull, authorization_flow__slug__iexact=authorization_flow__slug__iexact, basic_auth_enabled__iexact=basic_auth_enabled__iexact, basic_auth_password_attribute__iexact=basic_auth_password_attribute__iexact, basic_auth_user_attribute__iexact=basic_auth_user_attribute__iexact, certificate__kp_uuid__iexact=certificate__kp_uuid__iexact, certificate__name__iexact=certificate__name__iexact, cookie_domain__iexact=cookie_domain__iexact, external_host__iexact=external_host__iexact, internal_host__iexact=internal_host__iexact, internal_host_ssl_validation__iexact=internal_host_ssl_validation__iexact, mode__iexact=mode__iexact, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, property_mappings__iexact=property_mappings__iexact, search=search, skip_path_regex__iexact=skip_path_regex__iexact) + print("The response of ProvidersApi->providers_proxy_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_proxy_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **application__isnull** | **bool**| | [optional] + **authorization_flow__slug__iexact** | **str**| | [optional] + **basic_auth_enabled__iexact** | **bool**| | [optional] + **basic_auth_password_attribute__iexact** | **str**| | [optional] + **basic_auth_user_attribute__iexact** | **str**| | [optional] + **certificate__kp_uuid__iexact** | **UUID**| | [optional] + **certificate__name__iexact** | **str**| | [optional] + **cookie_domain__iexact** | **str**| | [optional] + **external_host__iexact** | **str**| | [optional] + **internal_host__iexact** | **str**| | [optional] + **internal_host_ssl_validation__iexact** | **bool**| | [optional] + **mode__iexact** | **str**| | [optional] + **name__iexact** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **property_mappings__iexact** | [**List[UUID]**](UUID.md)| | [optional] + **search** | **str**| A search term. | [optional] + **skip_path_regex__iexact** | **str**| | [optional] + +### Return type + +[**PaginatedProxyProviderList**](PaginatedProxyProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_proxy_partial_update** +> ProxyProvider providers_proxy_partial_update(id, patched_proxy_provider_request=patched_proxy_provider_request) + +ProxyProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_proxy_provider_request import PatchedProxyProviderRequest +from authentik_client.models.proxy_provider import ProxyProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Proxy Provider. + patched_proxy_provider_request = authentik_client.PatchedProxyProviderRequest() # PatchedProxyProviderRequest | (optional) + + try: + api_response = api_instance.providers_proxy_partial_update(id, patched_proxy_provider_request=patched_proxy_provider_request) + print("The response of ProvidersApi->providers_proxy_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_proxy_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Proxy Provider. | + **patched_proxy_provider_request** | [**PatchedProxyProviderRequest**](PatchedProxyProviderRequest.md)| | [optional] + +### Return type + +[**ProxyProvider**](ProxyProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_proxy_retrieve** +> ProxyProvider providers_proxy_retrieve(id) + +ProxyProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.proxy_provider import ProxyProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Proxy Provider. + + try: + api_response = api_instance.providers_proxy_retrieve(id) + print("The response of ProvidersApi->providers_proxy_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_proxy_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Proxy Provider. | + +### Return type + +[**ProxyProvider**](ProxyProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_proxy_update** +> ProxyProvider providers_proxy_update(id, proxy_provider_request) + +ProxyProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.proxy_provider import ProxyProvider +from authentik_client.models.proxy_provider_request import ProxyProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Proxy Provider. + proxy_provider_request = authentik_client.ProxyProviderRequest() # ProxyProviderRequest | + + try: + api_response = api_instance.providers_proxy_update(id, proxy_provider_request) + print("The response of ProvidersApi->providers_proxy_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_proxy_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Proxy Provider. | + **proxy_provider_request** | [**ProxyProviderRequest**](ProxyProviderRequest.md)| | + +### Return type + +[**ProxyProvider**](ProxyProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_proxy_used_by_list** +> List[UsedBy] providers_proxy_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Proxy Provider. + + try: + api_response = api_instance.providers_proxy_used_by_list(id) + print("The response of ProvidersApi->providers_proxy_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_proxy_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Proxy Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_rac_create** +> RACProvider providers_rac_create(rac_provider_request) + +RACProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.rac_provider import RACProvider +from authentik_client.models.rac_provider_request import RACProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + rac_provider_request = authentik_client.RACProviderRequest() # RACProviderRequest | + + try: + api_response = api_instance.providers_rac_create(rac_provider_request) + print("The response of ProvidersApi->providers_rac_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_rac_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **rac_provider_request** | [**RACProviderRequest**](RACProviderRequest.md)| | + +### Return type + +[**RACProvider**](RACProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_rac_destroy** +> providers_rac_destroy(id) + +RACProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this RAC Provider. + + try: + api_instance.providers_rac_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_rac_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this RAC Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_rac_list** +> PaginatedRACProviderList providers_rac_list(application__isnull=application__isnull, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, search=search) + +RACProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_rac_provider_list import PaginatedRACProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + application__isnull = True # bool | (optional) + name__iexact = 'name__iexact_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.providers_rac_list(application__isnull=application__isnull, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of ProvidersApi->providers_rac_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_rac_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **application__isnull** | **bool**| | [optional] + **name__iexact** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedRACProviderList**](PaginatedRACProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_rac_partial_update** +> RACProvider providers_rac_partial_update(id, patched_rac_provider_request=patched_rac_provider_request) + +RACProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_rac_provider_request import PatchedRACProviderRequest +from authentik_client.models.rac_provider import RACProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this RAC Provider. + patched_rac_provider_request = authentik_client.PatchedRACProviderRequest() # PatchedRACProviderRequest | (optional) + + try: + api_response = api_instance.providers_rac_partial_update(id, patched_rac_provider_request=patched_rac_provider_request) + print("The response of ProvidersApi->providers_rac_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_rac_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this RAC Provider. | + **patched_rac_provider_request** | [**PatchedRACProviderRequest**](PatchedRACProviderRequest.md)| | [optional] + +### Return type + +[**RACProvider**](RACProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_rac_retrieve** +> RACProvider providers_rac_retrieve(id) + +RACProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.rac_provider import RACProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this RAC Provider. + + try: + api_response = api_instance.providers_rac_retrieve(id) + print("The response of ProvidersApi->providers_rac_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_rac_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this RAC Provider. | + +### Return type + +[**RACProvider**](RACProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_rac_update** +> RACProvider providers_rac_update(id, rac_provider_request) + +RACProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.rac_provider import RACProvider +from authentik_client.models.rac_provider_request import RACProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this RAC Provider. + rac_provider_request = authentik_client.RACProviderRequest() # RACProviderRequest | + + try: + api_response = api_instance.providers_rac_update(id, rac_provider_request) + print("The response of ProvidersApi->providers_rac_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_rac_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this RAC Provider. | + **rac_provider_request** | [**RACProviderRequest**](RACProviderRequest.md)| | + +### Return type + +[**RACProvider**](RACProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_rac_used_by_list** +> List[UsedBy] providers_rac_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this RAC Provider. + + try: + api_response = api_instance.providers_rac_used_by_list(id) + print("The response of ProvidersApi->providers_rac_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_rac_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this RAC Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_radius_create** +> RadiusProvider providers_radius_create(radius_provider_request) + +RadiusProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.radius_provider import RadiusProvider +from authentik_client.models.radius_provider_request import RadiusProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + radius_provider_request = authentik_client.RadiusProviderRequest() # RadiusProviderRequest | + + try: + api_response = api_instance.providers_radius_create(radius_provider_request) + print("The response of ProvidersApi->providers_radius_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_radius_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **radius_provider_request** | [**RadiusProviderRequest**](RadiusProviderRequest.md)| | + +### Return type + +[**RadiusProvider**](RadiusProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_radius_destroy** +> providers_radius_destroy(id) + +RadiusProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Radius Provider. + + try: + api_instance.providers_radius_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_radius_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Radius Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_radius_list** +> PaginatedRadiusProviderList providers_radius_list(application__isnull=application__isnull, authorization_flow__slug__iexact=authorization_flow__slug__iexact, client_networks__iexact=client_networks__iexact, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, search=search) + +RadiusProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_radius_provider_list import PaginatedRadiusProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + application__isnull = True # bool | (optional) + authorization_flow__slug__iexact = 'authorization_flow__slug__iexact_example' # str | (optional) + client_networks__iexact = 'client_networks__iexact_example' # str | (optional) + name__iexact = 'name__iexact_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.providers_radius_list(application__isnull=application__isnull, authorization_flow__slug__iexact=authorization_flow__slug__iexact, client_networks__iexact=client_networks__iexact, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of ProvidersApi->providers_radius_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_radius_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **application__isnull** | **bool**| | [optional] + **authorization_flow__slug__iexact** | **str**| | [optional] + **client_networks__iexact** | **str**| | [optional] + **name__iexact** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedRadiusProviderList**](PaginatedRadiusProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_radius_partial_update** +> RadiusProvider providers_radius_partial_update(id, patched_radius_provider_request=patched_radius_provider_request) + +RadiusProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_radius_provider_request import PatchedRadiusProviderRequest +from authentik_client.models.radius_provider import RadiusProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Radius Provider. + patched_radius_provider_request = authentik_client.PatchedRadiusProviderRequest() # PatchedRadiusProviderRequest | (optional) + + try: + api_response = api_instance.providers_radius_partial_update(id, patched_radius_provider_request=patched_radius_provider_request) + print("The response of ProvidersApi->providers_radius_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_radius_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Radius Provider. | + **patched_radius_provider_request** | [**PatchedRadiusProviderRequest**](PatchedRadiusProviderRequest.md)| | [optional] + +### Return type + +[**RadiusProvider**](RadiusProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_radius_retrieve** +> RadiusProvider providers_radius_retrieve(id) + +RadiusProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.radius_provider import RadiusProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Radius Provider. + + try: + api_response = api_instance.providers_radius_retrieve(id) + print("The response of ProvidersApi->providers_radius_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_radius_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Radius Provider. | + +### Return type + +[**RadiusProvider**](RadiusProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_radius_update** +> RadiusProvider providers_radius_update(id, radius_provider_request) + +RadiusProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.radius_provider import RadiusProvider +from authentik_client.models.radius_provider_request import RadiusProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Radius Provider. + radius_provider_request = authentik_client.RadiusProviderRequest() # RadiusProviderRequest | + + try: + api_response = api_instance.providers_radius_update(id, radius_provider_request) + print("The response of ProvidersApi->providers_radius_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_radius_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Radius Provider. | + **radius_provider_request** | [**RadiusProviderRequest**](RadiusProviderRequest.md)| | + +### Return type + +[**RadiusProvider**](RadiusProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_radius_used_by_list** +> List[UsedBy] providers_radius_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Radius Provider. + + try: + api_response = api_instance.providers_radius_used_by_list(id) + print("The response of ProvidersApi->providers_radius_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_radius_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Radius Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_create** +> SAMLProvider providers_saml_create(saml_provider_request) + +SAMLProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_provider import SAMLProvider +from authentik_client.models.saml_provider_request import SAMLProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + saml_provider_request = authentik_client.SAMLProviderRequest() # SAMLProviderRequest | + + try: + api_response = api_instance.providers_saml_create(saml_provider_request) + print("The response of ProvidersApi->providers_saml_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **saml_provider_request** | [**SAMLProviderRequest**](SAMLProviderRequest.md)| | + +### Return type + +[**SAMLProvider**](SAMLProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_destroy** +> providers_saml_destroy(id) + +SAMLProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SAML Provider. + + try: + api_instance.providers_saml_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SAML Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_import_metadata_create** +> SAMLProvider providers_saml_import_metadata_create(name, authorization_flow, invalidation_flow, file) + +Create provider from SAML Metadata + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_provider import SAMLProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + name = 'name_example' # str | + authorization_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | + invalidation_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | + file = None # bytes | + + try: + api_response = api_instance.providers_saml_import_metadata_create(name, authorization_flow, invalidation_flow, file) + print("The response of ProvidersApi->providers_saml_import_metadata_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_import_metadata_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | + **authorization_flow** | **UUID**| | + **invalidation_flow** | **UUID**| | + **file** | **bytes**| | + +### Return type + +[**SAMLProvider**](SAMLProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: multipart/form-data + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_list** +> PaginatedSAMLProviderList providers_saml_list(acs_url=acs_url, assertion_valid_not_before=assertion_valid_not_before, assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, audience=audience, authentication_flow=authentication_flow, authn_context_class_ref_mapping=authn_context_class_ref_mapping, authorization_flow=authorization_flow, backchannel_application=backchannel_application, default_name_id_policy=default_name_id_policy, default_relay_state=default_relay_state, digest_algorithm=digest_algorithm, encryption_kp=encryption_kp, invalidation_flow=invalidation_flow, is_backchannel=is_backchannel, issuer_override=issuer_override, logout_method=logout_method, name=name, name_id_mapping=name_id_mapping, ordering=ordering, page=page, page_size=page_size, property_mappings=property_mappings, search=search, session_valid_not_on_or_after=session_valid_not_on_or_after, sign_assertion=sign_assertion, sign_logout_request=sign_logout_request, sign_logout_response=sign_logout_response, sign_response=sign_response, signature_algorithm=signature_algorithm, signing_kp=signing_kp, sls_binding=sls_binding, sls_url=sls_url, sp_binding=sp_binding, verification_kp=verification_kp) + +SAMLProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.paginated_saml_provider_list import PaginatedSAMLProviderList +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + acs_url = 'acs_url_example' # str | (optional) + assertion_valid_not_before = 'assertion_valid_not_before_example' # str | (optional) + assertion_valid_not_on_or_after = 'assertion_valid_not_on_or_after_example' # str | (optional) + audience = 'audience_example' # str | (optional) + authentication_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + authn_context_class_ref_mapping = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + authorization_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + backchannel_application = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + default_name_id_policy = authentik_client.SAMLNameIDPolicyEnum() # SAMLNameIDPolicyEnum | (optional) + default_relay_state = 'default_relay_state_example' # str | (optional) + digest_algorithm = authentik_client.DigestAlgorithmEnum() # DigestAlgorithmEnum | (optional) + encryption_kp = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + invalidation_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + is_backchannel = True # bool | (optional) + issuer_override = 'issuer_override_example' # str | (optional) + logout_method = authentik_client.SAMLLogoutMethods() # SAMLLogoutMethods | (optional) + name = 'name_example' # str | (optional) + name_id_mapping = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + property_mappings = None # List[UUID] | (optional) + search = 'search_example' # str | A search term. (optional) + session_valid_not_on_or_after = 'session_valid_not_on_or_after_example' # str | (optional) + sign_assertion = True # bool | (optional) + sign_logout_request = True # bool | (optional) + sign_logout_response = True # bool | (optional) + sign_response = True # bool | (optional) + signature_algorithm = authentik_client.SignatureAlgorithmEnum() # SignatureAlgorithmEnum | (optional) + signing_kp = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + sls_binding = authentik_client.SAMLBindingsEnum() # SAMLBindingsEnum | (optional) + sls_url = 'sls_url_example' # str | (optional) + sp_binding = authentik_client.SAMLBindingsEnum() # SAMLBindingsEnum | (optional) + verification_kp = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.providers_saml_list(acs_url=acs_url, assertion_valid_not_before=assertion_valid_not_before, assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, audience=audience, authentication_flow=authentication_flow, authn_context_class_ref_mapping=authn_context_class_ref_mapping, authorization_flow=authorization_flow, backchannel_application=backchannel_application, default_name_id_policy=default_name_id_policy, default_relay_state=default_relay_state, digest_algorithm=digest_algorithm, encryption_kp=encryption_kp, invalidation_flow=invalidation_flow, is_backchannel=is_backchannel, issuer_override=issuer_override, logout_method=logout_method, name=name, name_id_mapping=name_id_mapping, ordering=ordering, page=page, page_size=page_size, property_mappings=property_mappings, search=search, session_valid_not_on_or_after=session_valid_not_on_or_after, sign_assertion=sign_assertion, sign_logout_request=sign_logout_request, sign_logout_response=sign_logout_response, sign_response=sign_response, signature_algorithm=signature_algorithm, signing_kp=signing_kp, sls_binding=sls_binding, sls_url=sls_url, sp_binding=sp_binding, verification_kp=verification_kp) + print("The response of ProvidersApi->providers_saml_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **acs_url** | **str**| | [optional] + **assertion_valid_not_before** | **str**| | [optional] + **assertion_valid_not_on_or_after** | **str**| | [optional] + **audience** | **str**| | [optional] + **authentication_flow** | **UUID**| | [optional] + **authn_context_class_ref_mapping** | **UUID**| | [optional] + **authorization_flow** | **UUID**| | [optional] + **backchannel_application** | **UUID**| | [optional] + **default_name_id_policy** | [**SAMLNameIDPolicyEnum**](.md)| | [optional] + **default_relay_state** | **str**| | [optional] + **digest_algorithm** | [**DigestAlgorithmEnum**](.md)| | [optional] + **encryption_kp** | **UUID**| | [optional] + **invalidation_flow** | **UUID**| | [optional] + **is_backchannel** | **bool**| | [optional] + **issuer_override** | **str**| | [optional] + **logout_method** | [**SAMLLogoutMethods**](.md)| | [optional] + **name** | **str**| | [optional] + **name_id_mapping** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **property_mappings** | [**List[UUID]**](UUID.md)| | [optional] + **search** | **str**| A search term. | [optional] + **session_valid_not_on_or_after** | **str**| | [optional] + **sign_assertion** | **bool**| | [optional] + **sign_logout_request** | **bool**| | [optional] + **sign_logout_response** | **bool**| | [optional] + **sign_response** | **bool**| | [optional] + **signature_algorithm** | [**SignatureAlgorithmEnum**](.md)| | [optional] + **signing_kp** | **UUID**| | [optional] + **sls_binding** | [**SAMLBindingsEnum**](.md)| | [optional] + **sls_url** | **str**| | [optional] + **sp_binding** | [**SAMLBindingsEnum**](.md)| | [optional] + **verification_kp** | **UUID**| | [optional] + +### Return type + +[**PaginatedSAMLProviderList**](PaginatedSAMLProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_metadata_retrieve** +> SAMLMetadata providers_saml_metadata_retrieve(id, download=download, force_binding=force_binding) + +Return metadata as XML string + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_metadata import SAMLMetadata +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SAML Provider. + download = True # bool | (optional) + force_binding = authentik_client.ForceBindingEnum() # ForceBindingEnum | (optional) + + try: + api_response = api_instance.providers_saml_metadata_retrieve(id, download=download, force_binding=force_binding) + print("The response of ProvidersApi->providers_saml_metadata_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_metadata_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SAML Provider. | + **download** | **bool**| | [optional] + **force_binding** | [**ForceBindingEnum**](.md)| | [optional] + +### Return type + +[**SAMLMetadata**](SAMLMetadata.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json, application/xml + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**404** | Provider has no application assigned | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_partial_update** +> SAMLProvider providers_saml_partial_update(id, patched_saml_provider_request=patched_saml_provider_request) + +SAMLProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_saml_provider_request import PatchedSAMLProviderRequest +from authentik_client.models.saml_provider import SAMLProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SAML Provider. + patched_saml_provider_request = authentik_client.PatchedSAMLProviderRequest() # PatchedSAMLProviderRequest | (optional) + + try: + api_response = api_instance.providers_saml_partial_update(id, patched_saml_provider_request=patched_saml_provider_request) + print("The response of ProvidersApi->providers_saml_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SAML Provider. | + **patched_saml_provider_request** | [**PatchedSAMLProviderRequest**](PatchedSAMLProviderRequest.md)| | [optional] + +### Return type + +[**SAMLProvider**](SAMLProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_preview_user_retrieve** +> PropertyMappingPreview providers_saml_preview_user_retrieve(id, for_user=for_user) + +Preview user data for provider + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.property_mapping_preview import PropertyMappingPreview +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SAML Provider. + for_user = 56 # int | (optional) + + try: + api_response = api_instance.providers_saml_preview_user_retrieve(id, for_user=for_user) + print("The response of ProvidersApi->providers_saml_preview_user_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_preview_user_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SAML Provider. | + **for_user** | **int**| | [optional] + +### Return type + +[**PropertyMappingPreview**](PropertyMappingPreview.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_retrieve** +> SAMLProvider providers_saml_retrieve(id) + +SAMLProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_provider import SAMLProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SAML Provider. + + try: + api_response = api_instance.providers_saml_retrieve(id) + print("The response of ProvidersApi->providers_saml_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SAML Provider. | + +### Return type + +[**SAMLProvider**](SAMLProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_update** +> SAMLProvider providers_saml_update(id, saml_provider_request) + +SAMLProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_provider import SAMLProvider +from authentik_client.models.saml_provider_request import SAMLProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SAML Provider. + saml_provider_request = authentik_client.SAMLProviderRequest() # SAMLProviderRequest | + + try: + api_response = api_instance.providers_saml_update(id, saml_provider_request) + print("The response of ProvidersApi->providers_saml_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SAML Provider. | + **saml_provider_request** | [**SAMLProviderRequest**](SAMLProviderRequest.md)| | + +### Return type + +[**SAMLProvider**](SAMLProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_saml_used_by_list** +> List[UsedBy] providers_saml_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SAML Provider. + + try: + api_response = api_instance.providers_saml_used_by_list(id) + print("The response of ProvidersApi->providers_saml_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_saml_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SAML Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_create** +> SCIMProvider providers_scim_create(scim_provider_request) + +SCIMProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_provider import SCIMProvider +from authentik_client.models.scim_provider_request import SCIMProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + scim_provider_request = authentik_client.SCIMProviderRequest() # SCIMProviderRequest | + + try: + api_response = api_instance.providers_scim_create(scim_provider_request) + print("The response of ProvidersApi->providers_scim_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scim_provider_request** | [**SCIMProviderRequest**](SCIMProviderRequest.md)| | + +### Return type + +[**SCIMProvider**](SCIMProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_destroy** +> providers_scim_destroy(id) + +SCIMProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SCIM Provider. + + try: + api_instance.providers_scim_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SCIM Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_groups_create** +> SCIMProviderGroup providers_scim_groups_create(scim_provider_group_request) + +SCIMProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_provider_group import SCIMProviderGroup +from authentik_client.models.scim_provider_group_request import SCIMProviderGroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + scim_provider_group_request = authentik_client.SCIMProviderGroupRequest() # SCIMProviderGroupRequest | + + try: + api_response = api_instance.providers_scim_groups_create(scim_provider_group_request) + print("The response of ProvidersApi->providers_scim_groups_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_groups_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scim_provider_group_request** | [**SCIMProviderGroupRequest**](SCIMProviderGroupRequest.md)| | + +### Return type + +[**SCIMProviderGroup**](SCIMProviderGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_groups_destroy** +> providers_scim_groups_destroy(id) + +SCIMProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this scim provider group. + + try: + api_instance.providers_scim_groups_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_groups_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this scim provider group. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_groups_list** +> PaginatedSCIMProviderGroupList providers_scim_groups_list(group__group_uuid=group__group_uuid, group__name=group__name, ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search) + +SCIMProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_scim_provider_group_list import PaginatedSCIMProviderGroupList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + group__group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + group__name = 'group__name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider__id = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.providers_scim_groups_list(group__group_uuid=group__group_uuid, group__name=group__name, ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search) + print("The response of ProvidersApi->providers_scim_groups_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_groups_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group__group_uuid** | **UUID**| | [optional] + **group__name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider__id** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedSCIMProviderGroupList**](PaginatedSCIMProviderGroupList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_groups_retrieve** +> SCIMProviderGroup providers_scim_groups_retrieve(id) + +SCIMProviderGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_provider_group import SCIMProviderGroup +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this scim provider group. + + try: + api_response = api_instance.providers_scim_groups_retrieve(id) + print("The response of ProvidersApi->providers_scim_groups_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_groups_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this scim provider group. | + +### Return type + +[**SCIMProviderGroup**](SCIMProviderGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_groups_used_by_list** +> List[UsedBy] providers_scim_groups_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this scim provider group. + + try: + api_response = api_instance.providers_scim_groups_used_by_list(id) + print("The response of ProvidersApi->providers_scim_groups_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_groups_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this scim provider group. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_list** +> PaginatedSCIMProviderList providers_scim_list(exclude_users_service_account=exclude_users_service_account, group_filters=group_filters, name=name, ordering=ordering, page=page, page_size=page_size, search=search, url=url) + +SCIMProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_scim_provider_list import PaginatedSCIMProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + exclude_users_service_account = True # bool | (optional) + group_filters = None # List[UUID] | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + url = 'url_example' # str | (optional) + + try: + api_response = api_instance.providers_scim_list(exclude_users_service_account=exclude_users_service_account, group_filters=group_filters, name=name, ordering=ordering, page=page, page_size=page_size, search=search, url=url) + print("The response of ProvidersApi->providers_scim_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **exclude_users_service_account** | **bool**| | [optional] + **group_filters** | [**List[UUID]**](UUID.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **url** | **str**| | [optional] + +### Return type + +[**PaginatedSCIMProviderList**](PaginatedSCIMProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_partial_update** +> SCIMProvider providers_scim_partial_update(id, patched_scim_provider_request=patched_scim_provider_request) + +SCIMProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_scim_provider_request import PatchedSCIMProviderRequest +from authentik_client.models.scim_provider import SCIMProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SCIM Provider. + patched_scim_provider_request = authentik_client.PatchedSCIMProviderRequest() # PatchedSCIMProviderRequest | (optional) + + try: + api_response = api_instance.providers_scim_partial_update(id, patched_scim_provider_request=patched_scim_provider_request) + print("The response of ProvidersApi->providers_scim_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SCIM Provider. | + **patched_scim_provider_request** | [**PatchedSCIMProviderRequest**](PatchedSCIMProviderRequest.md)| | [optional] + +### Return type + +[**SCIMProvider**](SCIMProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_retrieve** +> SCIMProvider providers_scim_retrieve(id) + +SCIMProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_provider import SCIMProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SCIM Provider. + + try: + api_response = api_instance.providers_scim_retrieve(id) + print("The response of ProvidersApi->providers_scim_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SCIM Provider. | + +### Return type + +[**SCIMProvider**](SCIMProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_sync_object_create** +> SyncObjectResult providers_scim_sync_object_create(id, sync_object_request) + +Sync/Re-sync a single user/group object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sync_object_request import SyncObjectRequest +from authentik_client.models.sync_object_result import SyncObjectResult +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SCIM Provider. + sync_object_request = authentik_client.SyncObjectRequest() # SyncObjectRequest | + + try: + api_response = api_instance.providers_scim_sync_object_create(id, sync_object_request) + print("The response of ProvidersApi->providers_scim_sync_object_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_sync_object_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SCIM Provider. | + **sync_object_request** | [**SyncObjectRequest**](SyncObjectRequest.md)| | + +### Return type + +[**SyncObjectResult**](SyncObjectResult.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_sync_status_retrieve** +> SyncStatus providers_scim_sync_status_retrieve(id) + +Get provider's sync status + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sync_status import SyncStatus +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SCIM Provider. + + try: + api_response = api_instance.providers_scim_sync_status_retrieve(id) + print("The response of ProvidersApi->providers_scim_sync_status_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_sync_status_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SCIM Provider. | + +### Return type + +[**SyncStatus**](SyncStatus.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_update** +> SCIMProvider providers_scim_update(id, scim_provider_request) + +SCIMProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_provider import SCIMProvider +from authentik_client.models.scim_provider_request import SCIMProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SCIM Provider. + scim_provider_request = authentik_client.SCIMProviderRequest() # SCIMProviderRequest | + + try: + api_response = api_instance.providers_scim_update(id, scim_provider_request) + print("The response of ProvidersApi->providers_scim_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SCIM Provider. | + **scim_provider_request** | [**SCIMProviderRequest**](SCIMProviderRequest.md)| | + +### Return type + +[**SCIMProvider**](SCIMProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_used_by_list** +> List[UsedBy] providers_scim_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this SCIM Provider. + + try: + api_response = api_instance.providers_scim_used_by_list(id) + print("The response of ProvidersApi->providers_scim_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this SCIM Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_users_create** +> SCIMProviderUser providers_scim_users_create(scim_provider_user_request) + +SCIMProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_provider_user import SCIMProviderUser +from authentik_client.models.scim_provider_user_request import SCIMProviderUserRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + scim_provider_user_request = authentik_client.SCIMProviderUserRequest() # SCIMProviderUserRequest | + + try: + api_response = api_instance.providers_scim_users_create(scim_provider_user_request) + print("The response of ProvidersApi->providers_scim_users_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_users_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scim_provider_user_request** | [**SCIMProviderUserRequest**](SCIMProviderUserRequest.md)| | + +### Return type + +[**SCIMProviderUser**](SCIMProviderUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_users_destroy** +> providers_scim_users_destroy(id) + +SCIMProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this scim provider user. + + try: + api_instance.providers_scim_users_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_users_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this scim provider user. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_users_list** +> PaginatedSCIMProviderUserList providers_scim_users_list(ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search, user__id=user__id, user__username=user__username) + +SCIMProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_scim_provider_user_list import PaginatedSCIMProviderUserList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider__id = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + user__id = 56 # int | (optional) + user__username = 'user__username_example' # str | (optional) + + try: + api_response = api_instance.providers_scim_users_list(ordering=ordering, page=page, page_size=page_size, provider__id=provider__id, search=search, user__id=user__id, user__username=user__username) + print("The response of ProvidersApi->providers_scim_users_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_users_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider__id** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **user__id** | **int**| | [optional] + **user__username** | **str**| | [optional] + +### Return type + +[**PaginatedSCIMProviderUserList**](PaginatedSCIMProviderUserList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_users_retrieve** +> SCIMProviderUser providers_scim_users_retrieve(id) + +SCIMProviderUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_provider_user import SCIMProviderUser +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this scim provider user. + + try: + api_response = api_instance.providers_scim_users_retrieve(id) + print("The response of ProvidersApi->providers_scim_users_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_users_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this scim provider user. | + +### Return type + +[**SCIMProviderUser**](SCIMProviderUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_scim_users_used_by_list** +> List[UsedBy] providers_scim_users_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this scim provider user. + + try: + api_response = api_instance.providers_scim_users_used_by_list(id) + print("The response of ProvidersApi->providers_scim_users_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_scim_users_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this scim provider user. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ssf_create** +> SSFProvider providers_ssf_create(ssf_provider_request) + +SSFProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ssf_provider import SSFProvider +from authentik_client.models.ssf_provider_request import SSFProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + ssf_provider_request = authentik_client.SSFProviderRequest() # SSFProviderRequest | + + try: + api_response = api_instance.providers_ssf_create(ssf_provider_request) + print("The response of ProvidersApi->providers_ssf_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ssf_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ssf_provider_request** | [**SSFProviderRequest**](SSFProviderRequest.md)| | + +### Return type + +[**SSFProvider**](SSFProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ssf_destroy** +> providers_ssf_destroy(id) + +SSFProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Shared Signals Framework Provider. + + try: + api_instance.providers_ssf_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ssf_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Shared Signals Framework Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ssf_list** +> PaginatedSSFProviderList providers_ssf_list(application__isnull=application__isnull, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, search=search) + +SSFProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_ssf_provider_list import PaginatedSSFProviderList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + application__isnull = True # bool | (optional) + name__iexact = 'name__iexact_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.providers_ssf_list(application__isnull=application__isnull, name__iexact=name__iexact, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of ProvidersApi->providers_ssf_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ssf_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **application__isnull** | **bool**| | [optional] + **name__iexact** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedSSFProviderList**](PaginatedSSFProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ssf_partial_update** +> SSFProvider providers_ssf_partial_update(id, patched_ssf_provider_request=patched_ssf_provider_request) + +SSFProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_ssf_provider_request import PatchedSSFProviderRequest +from authentik_client.models.ssf_provider import SSFProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Shared Signals Framework Provider. + patched_ssf_provider_request = authentik_client.PatchedSSFProviderRequest() # PatchedSSFProviderRequest | (optional) + + try: + api_response = api_instance.providers_ssf_partial_update(id, patched_ssf_provider_request=patched_ssf_provider_request) + print("The response of ProvidersApi->providers_ssf_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ssf_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Shared Signals Framework Provider. | + **patched_ssf_provider_request** | [**PatchedSSFProviderRequest**](PatchedSSFProviderRequest.md)| | [optional] + +### Return type + +[**SSFProvider**](SSFProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ssf_retrieve** +> SSFProvider providers_ssf_retrieve(id) + +SSFProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ssf_provider import SSFProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Shared Signals Framework Provider. + + try: + api_response = api_instance.providers_ssf_retrieve(id) + print("The response of ProvidersApi->providers_ssf_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ssf_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Shared Signals Framework Provider. | + +### Return type + +[**SSFProvider**](SSFProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ssf_update** +> SSFProvider providers_ssf_update(id, ssf_provider_request) + +SSFProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ssf_provider import SSFProvider +from authentik_client.models.ssf_provider_request import SSFProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Shared Signals Framework Provider. + ssf_provider_request = authentik_client.SSFProviderRequest() # SSFProviderRequest | + + try: + api_response = api_instance.providers_ssf_update(id, ssf_provider_request) + print("The response of ProvidersApi->providers_ssf_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ssf_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Shared Signals Framework Provider. | + **ssf_provider_request** | [**SSFProviderRequest**](SSFProviderRequest.md)| | + +### Return type + +[**SSFProvider**](SSFProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_ssf_used_by_list** +> List[UsedBy] providers_ssf_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this Shared Signals Framework Provider. + + try: + api_response = api_instance.providers_ssf_used_by_list(id) + print("The response of ProvidersApi->providers_ssf_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_ssf_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Shared Signals Framework Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_wsfed_create** +> WSFederationProvider providers_wsfed_create(ws_federation_provider_request) + +WSFederationProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ws_federation_provider import WSFederationProvider +from authentik_client.models.ws_federation_provider_request import WSFederationProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + ws_federation_provider_request = authentik_client.WSFederationProviderRequest() # WSFederationProviderRequest | + + try: + api_response = api_instance.providers_wsfed_create(ws_federation_provider_request) + print("The response of ProvidersApi->providers_wsfed_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_wsfed_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ws_federation_provider_request** | [**WSFederationProviderRequest**](WSFederationProviderRequest.md)| | + +### Return type + +[**WSFederationProvider**](WSFederationProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_wsfed_destroy** +> providers_wsfed_destroy(id) + +WSFederationProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this WS-Federation Provider. + + try: + api_instance.providers_wsfed_destroy(id) + except Exception as e: + print("Exception when calling ProvidersApi->providers_wsfed_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WS-Federation Provider. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_wsfed_list** +> PaginatedWSFederationProviderList providers_wsfed_list(acs_url=acs_url, assertion_valid_not_before=assertion_valid_not_before, assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, audience=audience, authentication_flow=authentication_flow, authn_context_class_ref_mapping=authn_context_class_ref_mapping, authorization_flow=authorization_flow, backchannel_application=backchannel_application, default_name_id_policy=default_name_id_policy, default_relay_state=default_relay_state, digest_algorithm=digest_algorithm, encryption_kp=encryption_kp, invalidation_flow=invalidation_flow, is_backchannel=is_backchannel, issuer_override=issuer_override, logout_method=logout_method, name=name, name_id_mapping=name_id_mapping, ordering=ordering, page=page, page_size=page_size, property_mappings=property_mappings, search=search, session_valid_not_on_or_after=session_valid_not_on_or_after, sign_assertion=sign_assertion, sign_logout_request=sign_logout_request, sign_logout_response=sign_logout_response, sign_response=sign_response, signature_algorithm=signature_algorithm, signing_kp=signing_kp, sls_binding=sls_binding, sls_url=sls_url, sp_binding=sp_binding, verification_kp=verification_kp) + +WSFederationProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.paginated_ws_federation_provider_list import PaginatedWSFederationProviderList +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + acs_url = 'acs_url_example' # str | (optional) + assertion_valid_not_before = 'assertion_valid_not_before_example' # str | (optional) + assertion_valid_not_on_or_after = 'assertion_valid_not_on_or_after_example' # str | (optional) + audience = 'audience_example' # str | (optional) + authentication_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + authn_context_class_ref_mapping = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + authorization_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + backchannel_application = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + default_name_id_policy = authentik_client.SAMLNameIDPolicyEnum() # SAMLNameIDPolicyEnum | (optional) + default_relay_state = 'default_relay_state_example' # str | (optional) + digest_algorithm = authentik_client.DigestAlgorithmEnum() # DigestAlgorithmEnum | (optional) + encryption_kp = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + invalidation_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + is_backchannel = True # bool | (optional) + issuer_override = 'issuer_override_example' # str | (optional) + logout_method = authentik_client.SAMLLogoutMethods() # SAMLLogoutMethods | (optional) + name = 'name_example' # str | (optional) + name_id_mapping = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + property_mappings = None # List[UUID] | (optional) + search = 'search_example' # str | A search term. (optional) + session_valid_not_on_or_after = 'session_valid_not_on_or_after_example' # str | (optional) + sign_assertion = True # bool | (optional) + sign_logout_request = True # bool | (optional) + sign_logout_response = True # bool | (optional) + sign_response = True # bool | (optional) + signature_algorithm = authentik_client.SignatureAlgorithmEnum() # SignatureAlgorithmEnum | (optional) + signing_kp = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + sls_binding = authentik_client.SAMLBindingsEnum() # SAMLBindingsEnum | (optional) + sls_url = 'sls_url_example' # str | (optional) + sp_binding = authentik_client.SAMLBindingsEnum() # SAMLBindingsEnum | (optional) + verification_kp = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.providers_wsfed_list(acs_url=acs_url, assertion_valid_not_before=assertion_valid_not_before, assertion_valid_not_on_or_after=assertion_valid_not_on_or_after, audience=audience, authentication_flow=authentication_flow, authn_context_class_ref_mapping=authn_context_class_ref_mapping, authorization_flow=authorization_flow, backchannel_application=backchannel_application, default_name_id_policy=default_name_id_policy, default_relay_state=default_relay_state, digest_algorithm=digest_algorithm, encryption_kp=encryption_kp, invalidation_flow=invalidation_flow, is_backchannel=is_backchannel, issuer_override=issuer_override, logout_method=logout_method, name=name, name_id_mapping=name_id_mapping, ordering=ordering, page=page, page_size=page_size, property_mappings=property_mappings, search=search, session_valid_not_on_or_after=session_valid_not_on_or_after, sign_assertion=sign_assertion, sign_logout_request=sign_logout_request, sign_logout_response=sign_logout_response, sign_response=sign_response, signature_algorithm=signature_algorithm, signing_kp=signing_kp, sls_binding=sls_binding, sls_url=sls_url, sp_binding=sp_binding, verification_kp=verification_kp) + print("The response of ProvidersApi->providers_wsfed_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_wsfed_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **acs_url** | **str**| | [optional] + **assertion_valid_not_before** | **str**| | [optional] + **assertion_valid_not_on_or_after** | **str**| | [optional] + **audience** | **str**| | [optional] + **authentication_flow** | **UUID**| | [optional] + **authn_context_class_ref_mapping** | **UUID**| | [optional] + **authorization_flow** | **UUID**| | [optional] + **backchannel_application** | **UUID**| | [optional] + **default_name_id_policy** | [**SAMLNameIDPolicyEnum**](.md)| | [optional] + **default_relay_state** | **str**| | [optional] + **digest_algorithm** | [**DigestAlgorithmEnum**](.md)| | [optional] + **encryption_kp** | **UUID**| | [optional] + **invalidation_flow** | **UUID**| | [optional] + **is_backchannel** | **bool**| | [optional] + **issuer_override** | **str**| | [optional] + **logout_method** | [**SAMLLogoutMethods**](.md)| | [optional] + **name** | **str**| | [optional] + **name_id_mapping** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **property_mappings** | [**List[UUID]**](UUID.md)| | [optional] + **search** | **str**| A search term. | [optional] + **session_valid_not_on_or_after** | **str**| | [optional] + **sign_assertion** | **bool**| | [optional] + **sign_logout_request** | **bool**| | [optional] + **sign_logout_response** | **bool**| | [optional] + **sign_response** | **bool**| | [optional] + **signature_algorithm** | [**SignatureAlgorithmEnum**](.md)| | [optional] + **signing_kp** | **UUID**| | [optional] + **sls_binding** | [**SAMLBindingsEnum**](.md)| | [optional] + **sls_url** | **str**| | [optional] + **sp_binding** | [**SAMLBindingsEnum**](.md)| | [optional] + **verification_kp** | **UUID**| | [optional] + +### Return type + +[**PaginatedWSFederationProviderList**](PaginatedWSFederationProviderList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_wsfed_metadata_retrieve** +> SAMLMetadata providers_wsfed_metadata_retrieve(id, download=download, force_binding=force_binding) + +Return metadata as XML string + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_metadata import SAMLMetadata +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this WS-Federation Provider. + download = True # bool | (optional) + force_binding = authentik_client.ForceBindingEnum() # ForceBindingEnum | (optional) + + try: + api_response = api_instance.providers_wsfed_metadata_retrieve(id, download=download, force_binding=force_binding) + print("The response of ProvidersApi->providers_wsfed_metadata_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_wsfed_metadata_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WS-Federation Provider. | + **download** | **bool**| | [optional] + **force_binding** | [**ForceBindingEnum**](.md)| | [optional] + +### Return type + +[**SAMLMetadata**](SAMLMetadata.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json, application/xml + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**404** | Provider has no application assigned | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_wsfed_partial_update** +> WSFederationProvider providers_wsfed_partial_update(id, patched_ws_federation_provider_request=patched_ws_federation_provider_request) + +WSFederationProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_ws_federation_provider_request import PatchedWSFederationProviderRequest +from authentik_client.models.ws_federation_provider import WSFederationProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this WS-Federation Provider. + patched_ws_federation_provider_request = authentik_client.PatchedWSFederationProviderRequest() # PatchedWSFederationProviderRequest | (optional) + + try: + api_response = api_instance.providers_wsfed_partial_update(id, patched_ws_federation_provider_request=patched_ws_federation_provider_request) + print("The response of ProvidersApi->providers_wsfed_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_wsfed_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WS-Federation Provider. | + **patched_ws_federation_provider_request** | [**PatchedWSFederationProviderRequest**](PatchedWSFederationProviderRequest.md)| | [optional] + +### Return type + +[**WSFederationProvider**](WSFederationProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_wsfed_preview_user_retrieve** +> PropertyMappingPreview providers_wsfed_preview_user_retrieve(id, for_user=for_user) + +Preview user data for provider + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.property_mapping_preview import PropertyMappingPreview +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this WS-Federation Provider. + for_user = 56 # int | (optional) + + try: + api_response = api_instance.providers_wsfed_preview_user_retrieve(id, for_user=for_user) + print("The response of ProvidersApi->providers_wsfed_preview_user_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_wsfed_preview_user_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WS-Federation Provider. | + **for_user** | **int**| | [optional] + +### Return type + +[**PropertyMappingPreview**](PropertyMappingPreview.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_wsfed_retrieve** +> WSFederationProvider providers_wsfed_retrieve(id) + +WSFederationProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ws_federation_provider import WSFederationProvider +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this WS-Federation Provider. + + try: + api_response = api_instance.providers_wsfed_retrieve(id) + print("The response of ProvidersApi->providers_wsfed_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_wsfed_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WS-Federation Provider. | + +### Return type + +[**WSFederationProvider**](WSFederationProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_wsfed_update** +> WSFederationProvider providers_wsfed_update(id, ws_federation_provider_request) + +WSFederationProvider Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ws_federation_provider import WSFederationProvider +from authentik_client.models.ws_federation_provider_request import WSFederationProviderRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this WS-Federation Provider. + ws_federation_provider_request = authentik_client.WSFederationProviderRequest() # WSFederationProviderRequest | + + try: + api_response = api_instance.providers_wsfed_update(id, ws_federation_provider_request) + print("The response of ProvidersApi->providers_wsfed_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_wsfed_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WS-Federation Provider. | + **ws_federation_provider_request** | [**WSFederationProviderRequest**](WSFederationProviderRequest.md)| | + +### Return type + +[**WSFederationProvider**](WSFederationProvider.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **providers_wsfed_used_by_list** +> List[UsedBy] providers_wsfed_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ProvidersApi(api_client) + id = 56 # int | A unique integer value identifying this WS-Federation Provider. + + try: + api_response = api_instance.providers_wsfed_used_by_list(id) + print("The response of ProvidersApi->providers_wsfed_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ProvidersApi->providers_wsfed_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this WS-Federation Provider. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/ProxyMode.md b/docs/ProxyMode.md new file mode 100644 index 000000000..3df0b9607 --- /dev/null +++ b/docs/ProxyMode.md @@ -0,0 +1,14 @@ +# ProxyMode + + +## Enum + +* `PROXY` (value: `'proxy'`) + +* `FORWARD_SINGLE` (value: `'forward_single'`) + +* `FORWARD_DOMAIN` (value: `'forward_domain'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ProxyOutpostConfig.md b/docs/ProxyOutpostConfig.md new file mode 100644 index 000000000..b4d883a90 --- /dev/null +++ b/docs/ProxyOutpostConfig.md @@ -0,0 +1,50 @@ +# ProxyOutpostConfig + +Proxy provider serializer for outposts + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**internal_host** | **str** | | [optional] +**external_host** | **str** | | +**internal_host_ssl_validation** | **bool** | Validate SSL Certificates of upstream servers | [optional] +**client_id** | **str** | | [optional] +**client_secret** | **str** | | [optional] +**oidc_configuration** | [**OpenIDConnectConfiguration**](OpenIDConnectConfiguration.md) | | [readonly] +**cookie_secret** | **str** | | [optional] +**certificate** | **UUID** | | [optional] +**skip_path_regex** | **str** | Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression. | [optional] +**basic_auth_enabled** | **bool** | Set a custom HTTP-Basic Authentication header based on values from authentik. | [optional] +**basic_auth_password_attribute** | **str** | User/Group Attribute used for the password part of the HTTP-Basic Header. | [optional] +**basic_auth_user_attribute** | **str** | User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used. | [optional] +**mode** | [**ProxyMode**](ProxyMode.md) | Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host. | [optional] +**cookie_domain** | **str** | | [optional] +**access_token_validity** | **float** | Get token validity as second count | [readonly] +**intercept_header_auth** | **bool** | When enabled, this provider will intercept the authorization header and authenticate requests based on its value. | [optional] +**scopes_to_request** | **List[str]** | Get all the scope names the outpost should request, including custom-defined ones | [readonly] +**assigned_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_application_name** | **str** | Application's display Name. | [readonly] + +## Example + +```python +from authentik_client.models.proxy_outpost_config import ProxyOutpostConfig + +# TODO update the JSON string below +json = "{}" +# create an instance of ProxyOutpostConfig from a JSON string +proxy_outpost_config_instance = ProxyOutpostConfig.from_json(json) +# print the JSON string representation of the object +print(ProxyOutpostConfig.to_json()) + +# convert the object into a dict +proxy_outpost_config_dict = proxy_outpost_config_instance.to_dict() +# create an instance of ProxyOutpostConfig from a dict +proxy_outpost_config_from_dict = ProxyOutpostConfig.from_dict(proxy_outpost_config_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ProxyProvider.md b/docs/ProxyProvider.md new file mode 100644 index 000000000..a2558b39d --- /dev/null +++ b/docs/ProxyProvider.md @@ -0,0 +1,61 @@ +# ProxyProvider + +ProxyProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_application_name** | **str** | Application's display Name. | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**client_id** | **str** | | [readonly] +**internal_host** | **str** | | [optional] +**external_host** | **str** | | +**internal_host_ssl_validation** | **bool** | Validate SSL Certificates of upstream servers | [optional] +**certificate** | **UUID** | | [optional] +**skip_path_regex** | **str** | Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression. | [optional] +**basic_auth_enabled** | **bool** | Set a custom HTTP-Basic Authentication header based on values from authentik. | [optional] +**basic_auth_password_attribute** | **str** | User/Group Attribute used for the password part of the HTTP-Basic Header. | [optional] +**basic_auth_user_attribute** | **str** | User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used. | [optional] +**mode** | [**ProxyMode**](ProxyMode.md) | Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host. | [optional] +**intercept_header_auth** | **bool** | When enabled, this provider will intercept the authorization header and authenticate requests based on its value. | [optional] +**redirect_uris** | [**List[RedirectURI]**](RedirectURI.md) | | [readonly] +**cookie_domain** | **str** | | [optional] +**jwt_federation_sources** | **List[UUID]** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] +**access_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**outpost_set** | **List[str]** | | [readonly] + +## Example + +```python +from authentik_client.models.proxy_provider import ProxyProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of ProxyProvider from a JSON string +proxy_provider_instance = ProxyProvider.from_json(json) +# print the JSON string representation of the object +print(ProxyProvider.to_json()) + +# convert the object into a dict +proxy_provider_dict = proxy_provider_instance.to_dict() +# create an instance of ProxyProvider from a dict +proxy_provider_from_dict = ProxyProvider.from_dict(proxy_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ProxyProviderRequest.md b/docs/ProxyProviderRequest.md new file mode 100644 index 000000000..fc69482e6 --- /dev/null +++ b/docs/ProxyProviderRequest.md @@ -0,0 +1,49 @@ +# ProxyProviderRequest + +ProxyProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**internal_host** | **str** | | [optional] +**external_host** | **str** | | +**internal_host_ssl_validation** | **bool** | Validate SSL Certificates of upstream servers | [optional] +**certificate** | **UUID** | | [optional] +**skip_path_regex** | **str** | Regular expressions for which authentication is not required. Each new line is interpreted as a new Regular Expression. | [optional] +**basic_auth_enabled** | **bool** | Set a custom HTTP-Basic Authentication header based on values from authentik. | [optional] +**basic_auth_password_attribute** | **str** | User/Group Attribute used for the password part of the HTTP-Basic Header. | [optional] +**basic_auth_user_attribute** | **str** | User/Group Attribute used for the user part of the HTTP-Basic Header. If not set, the user's Email address is used. | [optional] +**mode** | [**ProxyMode**](ProxyMode.md) | Enable support for forwardAuth in traefik and nginx auth_request. Exclusive with internal_host. | [optional] +**intercept_header_auth** | **bool** | When enabled, this provider will intercept the authorization header and authenticate requests based on its value. | [optional] +**cookie_domain** | **str** | | [optional] +**jwt_federation_sources** | **List[UUID]** | | [optional] +**jwt_federation_providers** | **List[int]** | | [optional] +**access_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**refresh_token_validity** | **str** | Tokens not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] + +## Example + +```python +from authentik_client.models.proxy_provider_request import ProxyProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ProxyProviderRequest from a JSON string +proxy_provider_request_instance = ProxyProviderRequest.from_json(json) +# print the JSON string representation of the object +print(ProxyProviderRequest.to_json()) + +# convert the object into a dict +proxy_provider_request_dict = proxy_provider_request_instance.to_dict() +# create an instance of ProxyProviderRequest from a dict +proxy_provider_request_from_dict = ProxyProviderRequest.from_dict(proxy_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RACPropertyMapping.md b/docs/RACPropertyMapping.md new file mode 100644 index 000000000..4943a161f --- /dev/null +++ b/docs/RACPropertyMapping.md @@ -0,0 +1,38 @@ +# RACPropertyMapping + +RACPropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | [optional] +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**static_settings** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.rac_property_mapping import RACPropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of RACPropertyMapping from a JSON string +rac_property_mapping_instance = RACPropertyMapping.from_json(json) +# print the JSON string representation of the object +print(RACPropertyMapping.to_json()) + +# convert the object into a dict +rac_property_mapping_dict = rac_property_mapping_instance.to_dict() +# create an instance of RACPropertyMapping from a dict +rac_property_mapping_from_dict = RACPropertyMapping.from_dict(rac_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RACPropertyMappingRequest.md b/docs/RACPropertyMappingRequest.md new file mode 100644 index 000000000..5de473769 --- /dev/null +++ b/docs/RACPropertyMappingRequest.md @@ -0,0 +1,33 @@ +# RACPropertyMappingRequest + +RACPropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | [optional] +**static_settings** | **Dict[str, object]** | | + +## Example + +```python +from authentik_client.models.rac_property_mapping_request import RACPropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of RACPropertyMappingRequest from a JSON string +rac_property_mapping_request_instance = RACPropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(RACPropertyMappingRequest.to_json()) + +# convert the object into a dict +rac_property_mapping_request_dict = rac_property_mapping_request_instance.to_dict() +# create an instance of RACPropertyMappingRequest from a dict +rac_property_mapping_request_from_dict = RACPropertyMappingRequest.from_dict(rac_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RACProvider.md b/docs/RACProvider.md new file mode 100644 index 000000000..7cc01aaff --- /dev/null +++ b/docs/RACProvider.md @@ -0,0 +1,46 @@ +# RACProvider + +RACProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_application_name** | **str** | Application's display Name. | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**settings** | **Dict[str, object]** | | [optional] +**outpost_set** | **List[str]** | | [readonly] +**connection_expiry** | **str** | Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**delete_token_on_disconnect** | **bool** | When set to true, connection tokens will be deleted upon disconnect. | [optional] + +## Example + +```python +from authentik_client.models.rac_provider import RACProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of RACProvider from a JSON string +rac_provider_instance = RACProvider.from_json(json) +# print the JSON string representation of the object +print(RACProvider.to_json()) + +# convert the object into a dict +rac_provider_dict = rac_provider_instance.to_dict() +# create an instance of RACProvider from a dict +rac_provider_from_dict = RACProvider.from_dict(rac_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RACProviderRequest.md b/docs/RACProviderRequest.md new file mode 100644 index 000000000..6b72e87a6 --- /dev/null +++ b/docs/RACProviderRequest.md @@ -0,0 +1,36 @@ +# RACProviderRequest + +RACProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**property_mappings** | **List[UUID]** | | [optional] +**settings** | **Dict[str, object]** | | [optional] +**connection_expiry** | **str** | Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**delete_token_on_disconnect** | **bool** | When set to true, connection tokens will be deleted upon disconnect. | [optional] + +## Example + +```python +from authentik_client.models.rac_provider_request import RACProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of RACProviderRequest from a JSON string +rac_provider_request_instance = RACProviderRequest.from_json(json) +# print the JSON string representation of the object +print(RACProviderRequest.to_json()) + +# convert the object into a dict +rac_provider_request_dict = rac_provider_request_instance.to_dict() +# create an instance of RACProviderRequest from a dict +rac_provider_request_from_dict = RACProviderRequest.from_dict(rac_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RacApi.md b/docs/RacApi.md new file mode 100644 index 000000000..4be569735 --- /dev/null +++ b/docs/RacApi.md @@ -0,0 +1,1053 @@ +# authentik_client.RacApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**rac_connection_tokens_destroy**](RacApi.md#rac_connection_tokens_destroy) | **DELETE** /rac/connection_tokens/{connection_token_uuid}/ | +[**rac_connection_tokens_list**](RacApi.md#rac_connection_tokens_list) | **GET** /rac/connection_tokens/ | +[**rac_connection_tokens_partial_update**](RacApi.md#rac_connection_tokens_partial_update) | **PATCH** /rac/connection_tokens/{connection_token_uuid}/ | +[**rac_connection_tokens_retrieve**](RacApi.md#rac_connection_tokens_retrieve) | **GET** /rac/connection_tokens/{connection_token_uuid}/ | +[**rac_connection_tokens_update**](RacApi.md#rac_connection_tokens_update) | **PUT** /rac/connection_tokens/{connection_token_uuid}/ | +[**rac_connection_tokens_used_by_list**](RacApi.md#rac_connection_tokens_used_by_list) | **GET** /rac/connection_tokens/{connection_token_uuid}/used_by/ | +[**rac_endpoints_create**](RacApi.md#rac_endpoints_create) | **POST** /rac/endpoints/ | +[**rac_endpoints_destroy**](RacApi.md#rac_endpoints_destroy) | **DELETE** /rac/endpoints/{pbm_uuid}/ | +[**rac_endpoints_list**](RacApi.md#rac_endpoints_list) | **GET** /rac/endpoints/ | +[**rac_endpoints_partial_update**](RacApi.md#rac_endpoints_partial_update) | **PATCH** /rac/endpoints/{pbm_uuid}/ | +[**rac_endpoints_retrieve**](RacApi.md#rac_endpoints_retrieve) | **GET** /rac/endpoints/{pbm_uuid}/ | +[**rac_endpoints_update**](RacApi.md#rac_endpoints_update) | **PUT** /rac/endpoints/{pbm_uuid}/ | +[**rac_endpoints_used_by_list**](RacApi.md#rac_endpoints_used_by_list) | **GET** /rac/endpoints/{pbm_uuid}/used_by/ | + + +# **rac_connection_tokens_destroy** +> rac_connection_tokens_destroy(connection_token_uuid) + +ConnectionToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + connection_token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Connection token. + + try: + api_instance.rac_connection_tokens_destroy(connection_token_uuid) + except Exception as e: + print("Exception when calling RacApi->rac_connection_tokens_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connection_token_uuid** | **UUID**| A UUID string identifying this RAC Connection token. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_connection_tokens_list** +> PaginatedConnectionTokenList rac_connection_tokens_list(endpoint=endpoint, ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, session__user=session__user) + +ConnectionToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_connection_token_list import PaginatedConnectionTokenList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + endpoint = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + session__user = 56 # int | (optional) + + try: + api_response = api_instance.rac_connection_tokens_list(endpoint=endpoint, ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, session__user=session__user) + print("The response of RacApi->rac_connection_tokens_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_connection_tokens_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **endpoint** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **session__user** | **int**| | [optional] + +### Return type + +[**PaginatedConnectionTokenList**](PaginatedConnectionTokenList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_connection_tokens_partial_update** +> ConnectionToken rac_connection_tokens_partial_update(connection_token_uuid, patched_connection_token_request=patched_connection_token_request) + +ConnectionToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.connection_token import ConnectionToken +from authentik_client.models.patched_connection_token_request import PatchedConnectionTokenRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + connection_token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Connection token. + patched_connection_token_request = authentik_client.PatchedConnectionTokenRequest() # PatchedConnectionTokenRequest | (optional) + + try: + api_response = api_instance.rac_connection_tokens_partial_update(connection_token_uuid, patched_connection_token_request=patched_connection_token_request) + print("The response of RacApi->rac_connection_tokens_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_connection_tokens_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connection_token_uuid** | **UUID**| A UUID string identifying this RAC Connection token. | + **patched_connection_token_request** | [**PatchedConnectionTokenRequest**](PatchedConnectionTokenRequest.md)| | [optional] + +### Return type + +[**ConnectionToken**](ConnectionToken.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_connection_tokens_retrieve** +> ConnectionToken rac_connection_tokens_retrieve(connection_token_uuid) + +ConnectionToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.connection_token import ConnectionToken +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + connection_token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Connection token. + + try: + api_response = api_instance.rac_connection_tokens_retrieve(connection_token_uuid) + print("The response of RacApi->rac_connection_tokens_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_connection_tokens_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connection_token_uuid** | **UUID**| A UUID string identifying this RAC Connection token. | + +### Return type + +[**ConnectionToken**](ConnectionToken.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_connection_tokens_update** +> ConnectionToken rac_connection_tokens_update(connection_token_uuid, connection_token_request) + +ConnectionToken Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.connection_token import ConnectionToken +from authentik_client.models.connection_token_request import ConnectionTokenRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + connection_token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Connection token. + connection_token_request = authentik_client.ConnectionTokenRequest() # ConnectionTokenRequest | + + try: + api_response = api_instance.rac_connection_tokens_update(connection_token_uuid, connection_token_request) + print("The response of RacApi->rac_connection_tokens_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_connection_tokens_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connection_token_uuid** | **UUID**| A UUID string identifying this RAC Connection token. | + **connection_token_request** | [**ConnectionTokenRequest**](ConnectionTokenRequest.md)| | + +### Return type + +[**ConnectionToken**](ConnectionToken.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_connection_tokens_used_by_list** +> List[UsedBy] rac_connection_tokens_used_by_list(connection_token_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + connection_token_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Connection token. + + try: + api_response = api_instance.rac_connection_tokens_used_by_list(connection_token_uuid) + print("The response of RacApi->rac_connection_tokens_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_connection_tokens_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **connection_token_uuid** | **UUID**| A UUID string identifying this RAC Connection token. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_endpoints_create** +> Endpoint rac_endpoints_create(endpoint_request) + +Endpoint Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint import Endpoint +from authentik_client.models.endpoint_request import EndpointRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + endpoint_request = authentik_client.EndpointRequest() # EndpointRequest | + + try: + api_response = api_instance.rac_endpoints_create(endpoint_request) + print("The response of RacApi->rac_endpoints_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_endpoints_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **endpoint_request** | [**EndpointRequest**](EndpointRequest.md)| | + +### Return type + +[**Endpoint**](Endpoint.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_endpoints_destroy** +> rac_endpoints_destroy(pbm_uuid) + +Endpoint Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Endpoint. + + try: + api_instance.rac_endpoints_destroy(pbm_uuid) + except Exception as e: + print("Exception when calling RacApi->rac_endpoints_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this RAC Endpoint. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_endpoints_list** +> PaginatedEndpointList rac_endpoints_list(name=name, ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, superuser_full_list=superuser_full_list) + +List accessible endpoints + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_endpoint_list import PaginatedEndpointList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + superuser_full_list = True # bool | (optional) + + try: + api_response = api_instance.rac_endpoints_list(name=name, ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, superuser_full_list=superuser_full_list) + print("The response of RacApi->rac_endpoints_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_endpoints_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **superuser_full_list** | **bool**| | [optional] + +### Return type + +[**PaginatedEndpointList**](PaginatedEndpointList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_endpoints_partial_update** +> Endpoint rac_endpoints_partial_update(pbm_uuid, patched_endpoint_request=patched_endpoint_request) + +Endpoint Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint import Endpoint +from authentik_client.models.patched_endpoint_request import PatchedEndpointRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Endpoint. + patched_endpoint_request = authentik_client.PatchedEndpointRequest() # PatchedEndpointRequest | (optional) + + try: + api_response = api_instance.rac_endpoints_partial_update(pbm_uuid, patched_endpoint_request=patched_endpoint_request) + print("The response of RacApi->rac_endpoints_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_endpoints_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this RAC Endpoint. | + **patched_endpoint_request** | [**PatchedEndpointRequest**](PatchedEndpointRequest.md)| | [optional] + +### Return type + +[**Endpoint**](Endpoint.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_endpoints_retrieve** +> Endpoint rac_endpoints_retrieve(pbm_uuid) + +Endpoint Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint import Endpoint +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Endpoint. + + try: + api_response = api_instance.rac_endpoints_retrieve(pbm_uuid) + print("The response of RacApi->rac_endpoints_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_endpoints_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this RAC Endpoint. | + +### Return type + +[**Endpoint**](Endpoint.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_endpoints_update** +> Endpoint rac_endpoints_update(pbm_uuid, endpoint_request) + +Endpoint Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint import Endpoint +from authentik_client.models.endpoint_request import EndpointRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Endpoint. + endpoint_request = authentik_client.EndpointRequest() # EndpointRequest | + + try: + api_response = api_instance.rac_endpoints_update(pbm_uuid, endpoint_request) + print("The response of RacApi->rac_endpoints_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_endpoints_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this RAC Endpoint. | + **endpoint_request** | [**EndpointRequest**](EndpointRequest.md)| | + +### Return type + +[**Endpoint**](Endpoint.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rac_endpoints_used_by_list** +> List[UsedBy] rac_endpoints_used_by_list(pbm_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RacApi(api_client) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this RAC Endpoint. + + try: + api_response = api_instance.rac_endpoints_used_by_list(pbm_uuid) + print("The response of RacApi->rac_endpoints_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RacApi->rac_endpoints_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pbm_uuid** | **UUID**| A UUID string identifying this RAC Endpoint. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/RadiusCheckAccess.md b/docs/RadiusCheckAccess.md new file mode 100644 index 000000000..af61c31a6 --- /dev/null +++ b/docs/RadiusCheckAccess.md @@ -0,0 +1,31 @@ +# RadiusCheckAccess + +Base serializer class which doesn't implement create/update methods + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | **str** | | [optional] +**access** | [**PolicyTestResult**](PolicyTestResult.md) | | + +## Example + +```python +from authentik_client.models.radius_check_access import RadiusCheckAccess + +# TODO update the JSON string below +json = "{}" +# create an instance of RadiusCheckAccess from a JSON string +radius_check_access_instance = RadiusCheckAccess.from_json(json) +# print the JSON string representation of the object +print(RadiusCheckAccess.to_json()) + +# convert the object into a dict +radius_check_access_dict = radius_check_access_instance.to_dict() +# create an instance of RadiusCheckAccess from a dict +radius_check_access_from_dict = RadiusCheckAccess.from_dict(radius_check_access_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RadiusOutpostConfig.md b/docs/RadiusOutpostConfig.md new file mode 100644 index 000000000..70c9023f6 --- /dev/null +++ b/docs/RadiusOutpostConfig.md @@ -0,0 +1,37 @@ +# RadiusOutpostConfig + +RadiusProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**application_slug** | **str** | | +**auth_flow_slug** | **str** | | +**client_networks** | **str** | List of CIDRs (comma-separated) that clients can connect from. A more specific CIDR will match before a looser one. Clients connecting from a non-specified CIDR will be dropped. | [optional] +**shared_secret** | **str** | Shared secret between clients and server to hash packets. | [optional] +**mfa_support** | **bool** | When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon. | [optional] +**certificate** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.radius_outpost_config import RadiusOutpostConfig + +# TODO update the JSON string below +json = "{}" +# create an instance of RadiusOutpostConfig from a JSON string +radius_outpost_config_instance = RadiusOutpostConfig.from_json(json) +# print the JSON string representation of the object +print(RadiusOutpostConfig.to_json()) + +# convert the object into a dict +radius_outpost_config_dict = radius_outpost_config_instance.to_dict() +# create an instance of RadiusOutpostConfig from a dict +radius_outpost_config_from_dict = RadiusOutpostConfig.from_dict(radius_outpost_config_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RadiusProvider.md b/docs/RadiusProvider.md new file mode 100644 index 000000000..b7674a8d8 --- /dev/null +++ b/docs/RadiusProvider.md @@ -0,0 +1,48 @@ +# RadiusProvider + +RadiusProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_application_name** | **str** | Application's display Name. | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**client_networks** | **str** | List of CIDRs (comma-separated) that clients can connect from. A more specific CIDR will match before a looser one. Clients connecting from a non-specified CIDR will be dropped. | [optional] +**shared_secret** | **str** | Shared secret between clients and server to hash packets. | [optional] +**outpost_set** | **List[str]** | | [readonly] +**mfa_support** | **bool** | When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon. | [optional] +**certificate** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.radius_provider import RadiusProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of RadiusProvider from a JSON string +radius_provider_instance = RadiusProvider.from_json(json) +# print the JSON string representation of the object +print(RadiusProvider.to_json()) + +# convert the object into a dict +radius_provider_dict = radius_provider_instance.to_dict() +# create an instance of RadiusProvider from a dict +radius_provider_from_dict = RadiusProvider.from_dict(radius_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RadiusProviderPropertyMapping.md b/docs/RadiusProviderPropertyMapping.md new file mode 100644 index 000000000..2d4cacf2e --- /dev/null +++ b/docs/RadiusProviderPropertyMapping.md @@ -0,0 +1,37 @@ +# RadiusProviderPropertyMapping + +RadiusProviderPropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of RadiusProviderPropertyMapping from a JSON string +radius_provider_property_mapping_instance = RadiusProviderPropertyMapping.from_json(json) +# print the JSON string representation of the object +print(RadiusProviderPropertyMapping.to_json()) + +# convert the object into a dict +radius_provider_property_mapping_dict = radius_provider_property_mapping_instance.to_dict() +# create an instance of RadiusProviderPropertyMapping from a dict +radius_provider_property_mapping_from_dict = RadiusProviderPropertyMapping.from_dict(radius_provider_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RadiusProviderPropertyMappingRequest.md b/docs/RadiusProviderPropertyMappingRequest.md new file mode 100644 index 000000000..447c3c4da --- /dev/null +++ b/docs/RadiusProviderPropertyMappingRequest.md @@ -0,0 +1,32 @@ +# RadiusProviderPropertyMappingRequest + +RadiusProviderPropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.radius_provider_property_mapping_request import RadiusProviderPropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of RadiusProviderPropertyMappingRequest from a JSON string +radius_provider_property_mapping_request_instance = RadiusProviderPropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(RadiusProviderPropertyMappingRequest.to_json()) + +# convert the object into a dict +radius_provider_property_mapping_request_dict = radius_provider_property_mapping_request_instance.to_dict() +# create an instance of RadiusProviderPropertyMappingRequest from a dict +radius_provider_property_mapping_request_from_dict = RadiusProviderPropertyMappingRequest.from_dict(radius_provider_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RadiusProviderRequest.md b/docs/RadiusProviderRequest.md new file mode 100644 index 000000000..3923bf516 --- /dev/null +++ b/docs/RadiusProviderRequest.md @@ -0,0 +1,38 @@ +# RadiusProviderRequest + +RadiusProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**client_networks** | **str** | List of CIDRs (comma-separated) that clients can connect from. A more specific CIDR will match before a looser one. Clients connecting from a non-specified CIDR will be dropped. | [optional] +**shared_secret** | **str** | Shared secret between clients and server to hash packets. | [optional] +**mfa_support** | **bool** | When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon. | [optional] +**certificate** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.radius_provider_request import RadiusProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of RadiusProviderRequest from a JSON string +radius_provider_request_instance = RadiusProviderRequest.from_json(json) +# print the JSON string representation of the object +print(RadiusProviderRequest.to_json()) + +# convert the object into a dict +radius_provider_request_dict = radius_provider_request_instance.to_dict() +# create an instance of RadiusProviderRequest from a dict +radius_provider_request_from_dict = RadiusProviderRequest.from_dict(radius_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RbacApi.md b/docs/RbacApi.md new file mode 100644 index 000000000..2ceadc2a7 --- /dev/null +++ b/docs/RbacApi.md @@ -0,0 +1,1797 @@ +# authentik_client.RbacApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**rbac_initial_permissions_create**](RbacApi.md#rbac_initial_permissions_create) | **POST** /rbac/initial_permissions/ | +[**rbac_initial_permissions_destroy**](RbacApi.md#rbac_initial_permissions_destroy) | **DELETE** /rbac/initial_permissions/{id}/ | +[**rbac_initial_permissions_list**](RbacApi.md#rbac_initial_permissions_list) | **GET** /rbac/initial_permissions/ | +[**rbac_initial_permissions_partial_update**](RbacApi.md#rbac_initial_permissions_partial_update) | **PATCH** /rbac/initial_permissions/{id}/ | +[**rbac_initial_permissions_retrieve**](RbacApi.md#rbac_initial_permissions_retrieve) | **GET** /rbac/initial_permissions/{id}/ | +[**rbac_initial_permissions_update**](RbacApi.md#rbac_initial_permissions_update) | **PUT** /rbac/initial_permissions/{id}/ | +[**rbac_initial_permissions_used_by_list**](RbacApi.md#rbac_initial_permissions_used_by_list) | **GET** /rbac/initial_permissions/{id}/used_by/ | +[**rbac_permissions_assigned_by_roles_assign**](RbacApi.md#rbac_permissions_assigned_by_roles_assign) | **POST** /rbac/permissions/assigned_by_roles/{uuid}/assign/ | +[**rbac_permissions_assigned_by_roles_list**](RbacApi.md#rbac_permissions_assigned_by_roles_list) | **GET** /rbac/permissions/assigned_by_roles/ | +[**rbac_permissions_assigned_by_roles_unassign_partial_update**](RbacApi.md#rbac_permissions_assigned_by_roles_unassign_partial_update) | **PATCH** /rbac/permissions/assigned_by_roles/{uuid}/unassign/ | +[**rbac_permissions_list**](RbacApi.md#rbac_permissions_list) | **GET** /rbac/permissions/ | +[**rbac_permissions_retrieve**](RbacApi.md#rbac_permissions_retrieve) | **GET** /rbac/permissions/{id}/ | +[**rbac_permissions_roles_list**](RbacApi.md#rbac_permissions_roles_list) | **GET** /rbac/permissions/roles/ | +[**rbac_roles_add_user_create**](RbacApi.md#rbac_roles_add_user_create) | **POST** /rbac/roles/{uuid}/add_user/ | +[**rbac_roles_create**](RbacApi.md#rbac_roles_create) | **POST** /rbac/roles/ | +[**rbac_roles_destroy**](RbacApi.md#rbac_roles_destroy) | **DELETE** /rbac/roles/{uuid}/ | +[**rbac_roles_list**](RbacApi.md#rbac_roles_list) | **GET** /rbac/roles/ | +[**rbac_roles_partial_update**](RbacApi.md#rbac_roles_partial_update) | **PATCH** /rbac/roles/{uuid}/ | +[**rbac_roles_remove_user_create**](RbacApi.md#rbac_roles_remove_user_create) | **POST** /rbac/roles/{uuid}/remove_user/ | +[**rbac_roles_retrieve**](RbacApi.md#rbac_roles_retrieve) | **GET** /rbac/roles/{uuid}/ | +[**rbac_roles_update**](RbacApi.md#rbac_roles_update) | **PUT** /rbac/roles/{uuid}/ | +[**rbac_roles_used_by_list**](RbacApi.md#rbac_roles_used_by_list) | **GET** /rbac/roles/{uuid}/used_by/ | + + +# **rbac_initial_permissions_create** +> InitialPermissions rbac_initial_permissions_create(initial_permissions_request) + +InitialPermissions viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.initial_permissions import InitialPermissions +from authentik_client.models.initial_permissions_request import InitialPermissionsRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + initial_permissions_request = authentik_client.InitialPermissionsRequest() # InitialPermissionsRequest | + + try: + api_response = api_instance.rbac_initial_permissions_create(initial_permissions_request) + print("The response of RbacApi->rbac_initial_permissions_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_initial_permissions_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **initial_permissions_request** | [**InitialPermissionsRequest**](InitialPermissionsRequest.md)| | + +### Return type + +[**InitialPermissions**](InitialPermissions.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_initial_permissions_destroy** +> rbac_initial_permissions_destroy(id) + +InitialPermissions viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + id = 56 # int | A unique integer value identifying this Initial Permissions. + + try: + api_instance.rbac_initial_permissions_destroy(id) + except Exception as e: + print("Exception when calling RbacApi->rbac_initial_permissions_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Initial Permissions. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_initial_permissions_list** +> PaginatedInitialPermissionsList rbac_initial_permissions_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +InitialPermissions viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_initial_permissions_list import PaginatedInitialPermissionsList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.rbac_initial_permissions_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of RbacApi->rbac_initial_permissions_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_initial_permissions_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedInitialPermissionsList**](PaginatedInitialPermissionsList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_initial_permissions_partial_update** +> InitialPermissions rbac_initial_permissions_partial_update(id, patched_initial_permissions_request=patched_initial_permissions_request) + +InitialPermissions viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.initial_permissions import InitialPermissions +from authentik_client.models.patched_initial_permissions_request import PatchedInitialPermissionsRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + id = 56 # int | A unique integer value identifying this Initial Permissions. + patched_initial_permissions_request = authentik_client.PatchedInitialPermissionsRequest() # PatchedInitialPermissionsRequest | (optional) + + try: + api_response = api_instance.rbac_initial_permissions_partial_update(id, patched_initial_permissions_request=patched_initial_permissions_request) + print("The response of RbacApi->rbac_initial_permissions_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_initial_permissions_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Initial Permissions. | + **patched_initial_permissions_request** | [**PatchedInitialPermissionsRequest**](PatchedInitialPermissionsRequest.md)| | [optional] + +### Return type + +[**InitialPermissions**](InitialPermissions.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_initial_permissions_retrieve** +> InitialPermissions rbac_initial_permissions_retrieve(id) + +InitialPermissions viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.initial_permissions import InitialPermissions +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + id = 56 # int | A unique integer value identifying this Initial Permissions. + + try: + api_response = api_instance.rbac_initial_permissions_retrieve(id) + print("The response of RbacApi->rbac_initial_permissions_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_initial_permissions_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Initial Permissions. | + +### Return type + +[**InitialPermissions**](InitialPermissions.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_initial_permissions_update** +> InitialPermissions rbac_initial_permissions_update(id, initial_permissions_request) + +InitialPermissions viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.initial_permissions import InitialPermissions +from authentik_client.models.initial_permissions_request import InitialPermissionsRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + id = 56 # int | A unique integer value identifying this Initial Permissions. + initial_permissions_request = authentik_client.InitialPermissionsRequest() # InitialPermissionsRequest | + + try: + api_response = api_instance.rbac_initial_permissions_update(id, initial_permissions_request) + print("The response of RbacApi->rbac_initial_permissions_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_initial_permissions_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Initial Permissions. | + **initial_permissions_request** | [**InitialPermissionsRequest**](InitialPermissionsRequest.md)| | + +### Return type + +[**InitialPermissions**](InitialPermissions.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_initial_permissions_used_by_list** +> List[UsedBy] rbac_initial_permissions_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + id = 56 # int | A unique integer value identifying this Initial Permissions. + + try: + api_response = api_instance.rbac_initial_permissions_used_by_list(id) + print("The response of RbacApi->rbac_initial_permissions_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_initial_permissions_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Initial Permissions. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_permissions_assigned_by_roles_assign** +> List[PermissionAssignResult] rbac_permissions_assigned_by_roles_assign(uuid, permission_assign_request) + +Assign permission(s) to role. When `object_pk` is set, the permissions +are only assigned to the specific object, otherwise they are assigned globally. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.permission_assign_request import PermissionAssignRequest +from authentik_client.models.permission_assign_result import PermissionAssignResult +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Role. + permission_assign_request = authentik_client.PermissionAssignRequest() # PermissionAssignRequest | + + try: + api_response = api_instance.rbac_permissions_assigned_by_roles_assign(uuid, permission_assign_request) + print("The response of RbacApi->rbac_permissions_assigned_by_roles_assign:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_permissions_assigned_by_roles_assign: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Role. | + **permission_assign_request** | [**PermissionAssignRequest**](PermissionAssignRequest.md)| | + +### Return type + +[**List[PermissionAssignResult]**](PermissionAssignResult.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_permissions_assigned_by_roles_list** +> PaginatedRoleAssignedObjectPermissionList rbac_permissions_assigned_by_roles_list(model, object_pk=object_pk, ordering=ordering, page=page, page_size=page_size, search=search) + +Get assigned object permissions for a single object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_role_assigned_object_permission_list import PaginatedRoleAssignedObjectPermissionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + model = 'model_example' # str | + object_pk = 'object_pk_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.rbac_permissions_assigned_by_roles_list(model, object_pk=object_pk, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of RbacApi->rbac_permissions_assigned_by_roles_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_permissions_assigned_by_roles_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **model** | **str**| | + **object_pk** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedRoleAssignedObjectPermissionList**](PaginatedRoleAssignedObjectPermissionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_permissions_assigned_by_roles_unassign_partial_update** +> rbac_permissions_assigned_by_roles_unassign_partial_update(uuid, patched_permission_assign_request=patched_permission_assign_request) + +Unassign permission(s) to role. When `object_pk` is set, the permissions +are only assigned to the specific object, otherwise they are assigned globally. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_permission_assign_request import PatchedPermissionAssignRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Role. + patched_permission_assign_request = authentik_client.PatchedPermissionAssignRequest() # PatchedPermissionAssignRequest | (optional) + + try: + api_instance.rbac_permissions_assigned_by_roles_unassign_partial_update(uuid, patched_permission_assign_request=patched_permission_assign_request) + except Exception as e: + print("Exception when calling RbacApi->rbac_permissions_assigned_by_roles_unassign_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Role. | + **patched_permission_assign_request** | [**PatchedPermissionAssignRequest**](PatchedPermissionAssignRequest.md)| | [optional] + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Successfully unassigned | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_permissions_list** +> PaginatedPermissionList rbac_permissions_list(codename=codename, content_type__app_label=content_type__app_label, content_type__model=content_type__model, ordering=ordering, page=page, page_size=page_size, role=role, search=search) + +Read-only list of all permissions, filterable by model and app + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_permission_list import PaginatedPermissionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + codename = 'codename_example' # str | (optional) + content_type__app_label = 'content_type__app_label_example' # str | (optional) + content_type__model = 'content_type__model_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + role = 'role_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.rbac_permissions_list(codename=codename, content_type__app_label=content_type__app_label, content_type__model=content_type__model, ordering=ordering, page=page, page_size=page_size, role=role, search=search) + print("The response of RbacApi->rbac_permissions_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_permissions_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **codename** | **str**| | [optional] + **content_type__app_label** | **str**| | [optional] + **content_type__model** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **role** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedPermissionList**](PaginatedPermissionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_permissions_retrieve** +> Permission rbac_permissions_retrieve(id) + +Read-only list of all permissions, filterable by model and app + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.permission import Permission +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + id = 56 # int | A unique integer value identifying this permission. + + try: + api_response = api_instance.rbac_permissions_retrieve(id) + print("The response of RbacApi->rbac_permissions_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_permissions_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this permission. | + +### Return type + +[**Permission**](Permission.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_permissions_roles_list** +> PaginatedExtraRoleObjectPermissionList rbac_permissions_roles_list(ordering=ordering, page=page, page_size=page_size, search=search, uuid=uuid) + +Get a role's assigned object permissions + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_extra_role_object_permission_list import PaginatedExtraRoleObjectPermissionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.rbac_permissions_roles_list(ordering=ordering, page=page, page_size=page_size, search=search, uuid=uuid) + print("The response of RbacApi->rbac_permissions_roles_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_permissions_roles_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedExtraRoleObjectPermissionList**](PaginatedExtraRoleObjectPermissionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_roles_add_user_create** +> rbac_roles_add_user_create(uuid, user_account_serializer_for_role_request) + +Add user to role + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_account_serializer_for_role_request import UserAccountSerializerForRoleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Role. + user_account_serializer_for_role_request = authentik_client.UserAccountSerializerForRoleRequest() # UserAccountSerializerForRoleRequest | + + try: + api_instance.rbac_roles_add_user_create(uuid, user_account_serializer_for_role_request) + except Exception as e: + print("Exception when calling RbacApi->rbac_roles_add_user_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Role. | + **user_account_serializer_for_role_request** | [**UserAccountSerializerForRoleRequest**](UserAccountSerializerForRoleRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | User added | - | +**404** | User not found | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_roles_create** +> Role rbac_roles_create(role_request) + +Role viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.role import Role +from authentik_client.models.role_request import RoleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + role_request = authentik_client.RoleRequest() # RoleRequest | + + try: + api_response = api_instance.rbac_roles_create(role_request) + print("The response of RbacApi->rbac_roles_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_roles_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **role_request** | [**RoleRequest**](RoleRequest.md)| | + +### Return type + +[**Role**](Role.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_roles_destroy** +> rbac_roles_destroy(uuid) + +Role viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Role. + + try: + api_instance.rbac_roles_destroy(uuid) + except Exception as e: + print("Exception when calling RbacApi->rbac_roles_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Role. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_roles_list** +> PaginatedRoleList rbac_roles_list(groups=groups, inherited=inherited, managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search, users=users) + +Role viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_role_list import PaginatedRoleList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + groups = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + inherited = True # bool | Include inherited roles (requires users or groups filter) (optional) + managed = ['managed_example'] # List[str] | (optional) + managed__isnull = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + users = 56 # int | (optional) + + try: + api_response = api_instance.rbac_roles_list(groups=groups, inherited=inherited, managed=managed, managed__isnull=managed__isnull, name=name, ordering=ordering, page=page, page_size=page_size, search=search, users=users) + print("The response of RbacApi->rbac_roles_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_roles_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **groups** | **UUID**| | [optional] + **inherited** | **bool**| Include inherited roles (requires users or groups filter) | [optional] + **managed** | [**List[str]**](str.md)| | [optional] + **managed__isnull** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **users** | **int**| | [optional] + +### Return type + +[**PaginatedRoleList**](PaginatedRoleList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_roles_partial_update** +> Role rbac_roles_partial_update(uuid, patched_role_request=patched_role_request) + +Role viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_role_request import PatchedRoleRequest +from authentik_client.models.role import Role +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Role. + patched_role_request = authentik_client.PatchedRoleRequest() # PatchedRoleRequest | (optional) + + try: + api_response = api_instance.rbac_roles_partial_update(uuid, patched_role_request=patched_role_request) + print("The response of RbacApi->rbac_roles_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_roles_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Role. | + **patched_role_request** | [**PatchedRoleRequest**](PatchedRoleRequest.md)| | [optional] + +### Return type + +[**Role**](Role.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_roles_remove_user_create** +> rbac_roles_remove_user_create(uuid, user_account_serializer_for_role_request) + +Remove user from role + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_account_serializer_for_role_request import UserAccountSerializerForRoleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Role. + user_account_serializer_for_role_request = authentik_client.UserAccountSerializerForRoleRequest() # UserAccountSerializerForRoleRequest | + + try: + api_instance.rbac_roles_remove_user_create(uuid, user_account_serializer_for_role_request) + except Exception as e: + print("Exception when calling RbacApi->rbac_roles_remove_user_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Role. | + **user_account_serializer_for_role_request** | [**UserAccountSerializerForRoleRequest**](UserAccountSerializerForRoleRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | User removed | - | +**404** | User not found | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_roles_retrieve** +> Role rbac_roles_retrieve(uuid) + +Role viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.role import Role +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Role. + + try: + api_response = api_instance.rbac_roles_retrieve(uuid) + print("The response of RbacApi->rbac_roles_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_roles_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Role. | + +### Return type + +[**Role**](Role.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_roles_update** +> Role rbac_roles_update(uuid, role_request) + +Role viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.role import Role +from authentik_client.models.role_request import RoleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Role. + role_request = authentik_client.RoleRequest() # RoleRequest | + + try: + api_response = api_instance.rbac_roles_update(uuid, role_request) + print("The response of RbacApi->rbac_roles_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_roles_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Role. | + **role_request** | [**RoleRequest**](RoleRequest.md)| | + +### Return type + +[**Role**](Role.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **rbac_roles_used_by_list** +> List[UsedBy] rbac_roles_used_by_list(uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RbacApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Role. + + try: + api_response = api_instance.rbac_roles_used_by_list(uuid) + print("The response of RbacApi->rbac_roles_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RbacApi->rbac_roles_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this Role. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/RedirectChallenge.md b/docs/RedirectChallenge.md new file mode 100644 index 000000000..d7b7d4f74 --- /dev/null +++ b/docs/RedirectChallenge.md @@ -0,0 +1,34 @@ +# RedirectChallenge + +Challenge type to redirect the client + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'xak-flow-redirect'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**to** | **str** | | +**final_redirect** | **bool** | | [optional] [default to False] + +## Example + +```python +from authentik_client.models.redirect_challenge import RedirectChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of RedirectChallenge from a JSON string +redirect_challenge_instance = RedirectChallenge.from_json(json) +# print the JSON string representation of the object +print(RedirectChallenge.to_json()) + +# convert the object into a dict +redirect_challenge_dict = redirect_challenge_instance.to_dict() +# create an instance of RedirectChallenge from a dict +redirect_challenge_from_dict = RedirectChallenge.from_dict(redirect_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RedirectChallengeResponseRequest.md b/docs/RedirectChallengeResponseRequest.md new file mode 100644 index 000000000..64b395b27 --- /dev/null +++ b/docs/RedirectChallengeResponseRequest.md @@ -0,0 +1,31 @@ +# RedirectChallengeResponseRequest + +Redirect challenge response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'xak-flow-redirect'] +**to** | **str** | | + +## Example + +```python +from authentik_client.models.redirect_challenge_response_request import RedirectChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of RedirectChallengeResponseRequest from a JSON string +redirect_challenge_response_request_instance = RedirectChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(RedirectChallengeResponseRequest.to_json()) + +# convert the object into a dict +redirect_challenge_response_request_dict = redirect_challenge_response_request_instance.to_dict() +# create an instance of RedirectChallengeResponseRequest from a dict +redirect_challenge_response_request_from_dict = RedirectChallengeResponseRequest.from_dict(redirect_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RedirectStage.md b/docs/RedirectStage.md new file mode 100644 index 000000000..4d81bed8d --- /dev/null +++ b/docs/RedirectStage.md @@ -0,0 +1,40 @@ +# RedirectStage + +RedirectStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**keep_context** | **bool** | | [optional] +**mode** | [**RedirectStageModeEnum**](RedirectStageModeEnum.md) | | +**target_static** | **str** | | [optional] +**target_flow** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.redirect_stage import RedirectStage + +# TODO update the JSON string below +json = "{}" +# create an instance of RedirectStage from a JSON string +redirect_stage_instance = RedirectStage.from_json(json) +# print the JSON string representation of the object +print(RedirectStage.to_json()) + +# convert the object into a dict +redirect_stage_dict = redirect_stage_instance.to_dict() +# create an instance of RedirectStage from a dict +redirect_stage_from_dict = RedirectStage.from_dict(redirect_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RedirectStageModeEnum.md b/docs/RedirectStageModeEnum.md new file mode 100644 index 000000000..df19490db --- /dev/null +++ b/docs/RedirectStageModeEnum.md @@ -0,0 +1,12 @@ +# RedirectStageModeEnum + + +## Enum + +* `STATIC` (value: `'static'`) + +* `FLOW` (value: `'flow'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RedirectStageRequest.md b/docs/RedirectStageRequest.md new file mode 100644 index 000000000..01c1c5ac4 --- /dev/null +++ b/docs/RedirectStageRequest.md @@ -0,0 +1,34 @@ +# RedirectStageRequest + +RedirectStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**keep_context** | **bool** | | [optional] +**mode** | [**RedirectStageModeEnum**](RedirectStageModeEnum.md) | | +**target_static** | **str** | | [optional] +**target_flow** | **UUID** | | [optional] + +## Example + +```python +from authentik_client.models.redirect_stage_request import RedirectStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of RedirectStageRequest from a JSON string +redirect_stage_request_instance = RedirectStageRequest.from_json(json) +# print the JSON string representation of the object +print(RedirectStageRequest.to_json()) + +# convert the object into a dict +redirect_stage_request_dict = redirect_stage_request_instance.to_dict() +# create an instance of RedirectStageRequest from a dict +redirect_stage_request_from_dict = RedirectStageRequest.from_dict(redirect_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RedirectURI.md b/docs/RedirectURI.md new file mode 100644 index 000000000..96d8dad13 --- /dev/null +++ b/docs/RedirectURI.md @@ -0,0 +1,32 @@ +# RedirectURI + +A single allowed redirect URI entry + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**matching_mode** | [**MatchingModeEnum**](MatchingModeEnum.md) | | +**url** | **str** | | +**redirect_uri_type** | [**RedirectURITypeEnum**](RedirectURITypeEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.redirect_uri import RedirectURI + +# TODO update the JSON string below +json = "{}" +# create an instance of RedirectURI from a JSON string +redirect_uri_instance = RedirectURI.from_json(json) +# print the JSON string representation of the object +print(RedirectURI.to_json()) + +# convert the object into a dict +redirect_uri_dict = redirect_uri_instance.to_dict() +# create an instance of RedirectURI from a dict +redirect_uri_from_dict = RedirectURI.from_dict(redirect_uri_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RedirectURIRequest.md b/docs/RedirectURIRequest.md new file mode 100644 index 000000000..15a2c8ec3 --- /dev/null +++ b/docs/RedirectURIRequest.md @@ -0,0 +1,32 @@ +# RedirectURIRequest + +A single allowed redirect URI entry + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**matching_mode** | [**MatchingModeEnum**](MatchingModeEnum.md) | | +**url** | **str** | | +**redirect_uri_type** | [**RedirectURITypeEnum**](RedirectURITypeEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.redirect_uri_request import RedirectURIRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of RedirectURIRequest from a JSON string +redirect_uri_request_instance = RedirectURIRequest.from_json(json) +# print the JSON string representation of the object +print(RedirectURIRequest.to_json()) + +# convert the object into a dict +redirect_uri_request_dict = redirect_uri_request_instance.to_dict() +# create an instance of RedirectURIRequest from a dict +redirect_uri_request_from_dict = RedirectURIRequest.from_dict(redirect_uri_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RedirectURITypeEnum.md b/docs/RedirectURITypeEnum.md new file mode 100644 index 000000000..3ea12418e --- /dev/null +++ b/docs/RedirectURITypeEnum.md @@ -0,0 +1,12 @@ +# RedirectURITypeEnum + + +## Enum + +* `AUTHORIZATION` (value: `'authorization'`) + +* `LOGOUT` (value: `'logout'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RelatedGroup.md b/docs/RelatedGroup.md new file mode 100644 index 000000000..de24d522d --- /dev/null +++ b/docs/RelatedGroup.md @@ -0,0 +1,34 @@ +# RelatedGroup + +Stripped down group serializer to show relevant children/parents for groups + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**is_superuser** | **bool** | Users added to this group will be superusers. | [optional] +**attributes** | **Dict[str, object]** | | [optional] +**group_uuid** | **UUID** | | [readonly] + +## Example + +```python +from authentik_client.models.related_group import RelatedGroup + +# TODO update the JSON string below +json = "{}" +# create an instance of RelatedGroup from a JSON string +related_group_instance = RelatedGroup.from_json(json) +# print the JSON string representation of the object +print(RelatedGroup.to_json()) + +# convert the object into a dict +related_group_dict = related_group_instance.to_dict() +# create an instance of RelatedGroup from a dict +related_group_from_dict = RelatedGroup.from_dict(related_group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RelatedRule.md b/docs/RelatedRule.md new file mode 100644 index 000000000..c7e4d556d --- /dev/null +++ b/docs/RelatedRule.md @@ -0,0 +1,34 @@ +# RelatedRule + +Mixin to validate that a valid enterprise license exists before allowing to save the object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [optional] +**name** | **str** | | +**reviewer_groups** | [**List[ReviewerGroup]**](ReviewerGroup.md) | | [readonly] +**min_reviewers** | **int** | | [readonly] +**reviewers** | [**List[ReviewerUser]**](ReviewerUser.md) | | [readonly] + +## Example + +```python +from authentik_client.models.related_rule import RelatedRule + +# TODO update the JSON string below +json = "{}" +# create an instance of RelatedRule from a JSON string +related_rule_instance = RelatedRule.from_json(json) +# print the JSON string representation of the object +print(RelatedRule.to_json()) + +# convert the object into a dict +related_rule_dict = related_rule_instance.to_dict() +# create an instance of RelatedRule from a dict +related_rule_from_dict = RelatedRule.from_dict(related_rule_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ReportsApi.md b/docs/ReportsApi.md new file mode 100644 index 000000000..166c57c53 --- /dev/null +++ b/docs/ReportsApi.md @@ -0,0 +1,239 @@ +# authentik_client.ReportsApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**reports_exports_destroy**](ReportsApi.md#reports_exports_destroy) | **DELETE** /reports/exports/{id}/ | +[**reports_exports_list**](ReportsApi.md#reports_exports_list) | **GET** /reports/exports/ | +[**reports_exports_retrieve**](ReportsApi.md#reports_exports_retrieve) | **GET** /reports/exports/{id}/ | + + +# **reports_exports_destroy** +> reports_exports_destroy(id) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ReportsApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Data Export. + + try: + api_instance.reports_exports_destroy(id) + except Exception as e: + print("Exception when calling ReportsApi->reports_exports_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Data Export. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **reports_exports_list** +> PaginatedDataExportList reports_exports_list(ordering=ordering, page=page, page_size=page_size, search=search) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_data_export_list import PaginatedDataExportList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ReportsApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.reports_exports_list(ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of ReportsApi->reports_exports_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ReportsApi->reports_exports_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedDataExportList**](PaginatedDataExportList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **reports_exports_retrieve** +> DataExport reports_exports_retrieve(id) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.data_export import DataExport +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.ReportsApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Data Export. + + try: + api_response = api_instance.reports_exports_retrieve(id) + print("The response of ReportsApi->reports_exports_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling ReportsApi->reports_exports_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Data Export. | + +### Return type + +[**DataExport**](DataExport.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/Reputation.md b/docs/Reputation.md new file mode 100644 index 000000000..a38ceb8a0 --- /dev/null +++ b/docs/Reputation.md @@ -0,0 +1,36 @@ +# Reputation + +Reputation Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [optional] +**identifier** | **str** | | +**ip** | **str** | | +**ip_geo_data** | **Dict[str, object]** | | [optional] +**ip_asn_data** | **Dict[str, object]** | | [optional] +**score** | **int** | | [optional] +**updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.reputation import Reputation + +# TODO update the JSON string below +json = "{}" +# create an instance of Reputation from a JSON string +reputation_instance = Reputation.from_json(json) +# print the JSON string representation of the object +print(Reputation.to_json()) + +# convert the object into a dict +reputation_dict = reputation_instance.to_dict() +# create an instance of Reputation from a dict +reputation_from_dict = Reputation.from_dict(reputation_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ReputationPolicy.md b/docs/ReputationPolicy.md new file mode 100644 index 000000000..659b49d32 --- /dev/null +++ b/docs/ReputationPolicy.md @@ -0,0 +1,40 @@ +# ReputationPolicy + +Reputation Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**bound_to** | **int** | Return objects policy is bound to | [readonly] +**check_ip** | **bool** | | [optional] +**check_username** | **bool** | | [optional] +**threshold** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.reputation_policy import ReputationPolicy + +# TODO update the JSON string below +json = "{}" +# create an instance of ReputationPolicy from a JSON string +reputation_policy_instance = ReputationPolicy.from_json(json) +# print the JSON string representation of the object +print(ReputationPolicy.to_json()) + +# convert the object into a dict +reputation_policy_dict = reputation_policy_instance.to_dict() +# create an instance of ReputationPolicy from a dict +reputation_policy_from_dict = ReputationPolicy.from_dict(reputation_policy_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ReputationPolicyRequest.md b/docs/ReputationPolicyRequest.md new file mode 100644 index 000000000..a71f82d58 --- /dev/null +++ b/docs/ReputationPolicyRequest.md @@ -0,0 +1,34 @@ +# ReputationPolicyRequest + +Reputation Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**check_ip** | **bool** | | [optional] +**check_username** | **bool** | | [optional] +**threshold** | **int** | | [optional] + +## Example + +```python +from authentik_client.models.reputation_policy_request import ReputationPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ReputationPolicyRequest from a JSON string +reputation_policy_request_instance = ReputationPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(ReputationPolicyRequest.to_json()) + +# convert the object into a dict +reputation_policy_request_dict = reputation_policy_request_instance.to_dict() +# create an instance of ReputationPolicyRequest from a dict +reputation_policy_request_from_dict = ReputationPolicyRequest.from_dict(reputation_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Review.md b/docs/Review.md new file mode 100644 index 000000000..414bdf698 --- /dev/null +++ b/docs/Review.md @@ -0,0 +1,34 @@ +# Review + +Mixin to validate that a valid enterprise license exists before allowing to save the object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**iteration** | **UUID** | | +**reviewer** | [**ReviewerUser**](ReviewerUser.md) | | [readonly] +**timestamp** | **datetime** | | [readonly] +**note** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.review import Review + +# TODO update the JSON string below +json = "{}" +# create an instance of Review from a JSON string +review_instance = Review.from_json(json) +# print the JSON string representation of the object +print(Review.to_json()) + +# convert the object into a dict +review_dict = review_instance.to_dict() +# create an instance of Review from a dict +review_from_dict = Review.from_dict(review_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ReviewRequest.md b/docs/ReviewRequest.md new file mode 100644 index 000000000..d4400246e --- /dev/null +++ b/docs/ReviewRequest.md @@ -0,0 +1,31 @@ +# ReviewRequest + +Mixin to validate that a valid enterprise license exists before allowing to save the object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**iteration** | **UUID** | | +**note** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.review_request import ReviewRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ReviewRequest from a JSON string +review_request_instance = ReviewRequest.from_json(json) +# print the JSON string representation of the object +print(ReviewRequest.to_json()) + +# convert the object into a dict +review_request_dict = review_request_instance.to_dict() +# create an instance of ReviewRequest from a dict +review_request_from_dict = ReviewRequest.from_dict(review_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ReviewerGroup.md b/docs/ReviewerGroup.md new file mode 100644 index 000000000..a7a860dcc --- /dev/null +++ b/docs/ReviewerGroup.md @@ -0,0 +1,30 @@ +# ReviewerGroup + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | + +## Example + +```python +from authentik_client.models.reviewer_group import ReviewerGroup + +# TODO update the JSON string below +json = "{}" +# create an instance of ReviewerGroup from a JSON string +reviewer_group_instance = ReviewerGroup.from_json(json) +# print the JSON string representation of the object +print(ReviewerGroup.to_json()) + +# convert the object into a dict +reviewer_group_dict = reviewer_group_instance.to_dict() +# create an instance of ReviewerGroup from a dict +reviewer_group_from_dict = ReviewerGroup.from_dict(reviewer_group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ReviewerUser.md b/docs/ReviewerUser.md new file mode 100644 index 000000000..16b7dfe28 --- /dev/null +++ b/docs/ReviewerUser.md @@ -0,0 +1,32 @@ +# ReviewerUser + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**uuid** | **UUID** | | [readonly] +**username** | **str** | Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only. | +**name** | **str** | User's display name. | + +## Example + +```python +from authentik_client.models.reviewer_user import ReviewerUser + +# TODO update the JSON string below +json = "{}" +# create an instance of ReviewerUser from a JSON string +reviewer_user_instance = ReviewerUser.from_json(json) +# print the JSON string representation of the object +print(ReviewerUser.to_json()) + +# convert the object into a dict +reviewer_user_dict = reviewer_user_instance.to_dict() +# create an instance of ReviewerUser from a dict +reviewer_user_from_dict = ReviewerUser.from_dict(reviewer_user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Role.md b/docs/Role.md new file mode 100644 index 000000000..d052972c4 --- /dev/null +++ b/docs/Role.md @@ -0,0 +1,31 @@ +# Role + +Role serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | + +## Example + +```python +from authentik_client.models.role import Role + +# TODO update the JSON string below +json = "{}" +# create an instance of Role from a JSON string +role_instance = Role.from_json(json) +# print the JSON string representation of the object +print(Role.to_json()) + +# convert the object into a dict +role_dict = role_instance.to_dict() +# create an instance of Role from a dict +role_from_dict = Role.from_dict(role_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RoleAssignedObjectPermission.md b/docs/RoleAssignedObjectPermission.md new file mode 100644 index 000000000..b2cd61fc4 --- /dev/null +++ b/docs/RoleAssignedObjectPermission.md @@ -0,0 +1,33 @@ +# RoleAssignedObjectPermission + +Roles assigned object permission serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**role_pk** | **str** | | [readonly] +**name** | **str** | | [readonly] +**object_permissions** | [**List[RoleObjectPermission]**](RoleObjectPermission.md) | | +**model_permissions** | [**List[RoleModelPermission]**](RoleModelPermission.md) | | + +## Example + +```python +from authentik_client.models.role_assigned_object_permission import RoleAssignedObjectPermission + +# TODO update the JSON string below +json = "{}" +# create an instance of RoleAssignedObjectPermission from a JSON string +role_assigned_object_permission_instance = RoleAssignedObjectPermission.from_json(json) +# print the JSON string representation of the object +print(RoleAssignedObjectPermission.to_json()) + +# convert the object into a dict +role_assigned_object_permission_dict = role_assigned_object_permission_instance.to_dict() +# create an instance of RoleAssignedObjectPermission from a dict +role_assigned_object_permission_from_dict = RoleAssignedObjectPermission.from_dict(role_assigned_object_permission_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RoleModelPermission.md b/docs/RoleModelPermission.md new file mode 100644 index 000000000..371a431a0 --- /dev/null +++ b/docs/RoleModelPermission.md @@ -0,0 +1,34 @@ +# RoleModelPermission + +Role-bound object level permission + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | [readonly] +**codename** | **str** | | [readonly] +**model** | **str** | | [readonly] +**app_label** | **str** | | [readonly] +**name** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.role_model_permission import RoleModelPermission + +# TODO update the JSON string below +json = "{}" +# create an instance of RoleModelPermission from a JSON string +role_model_permission_instance = RoleModelPermission.from_json(json) +# print the JSON string representation of the object +print(RoleModelPermission.to_json()) + +# convert the object into a dict +role_model_permission_dict = role_model_permission_instance.to_dict() +# create an instance of RoleModelPermission from a dict +role_model_permission_from_dict = RoleModelPermission.from_dict(role_model_permission_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RoleObjectPermission.md b/docs/RoleObjectPermission.md new file mode 100644 index 000000000..4fff3c379 --- /dev/null +++ b/docs/RoleObjectPermission.md @@ -0,0 +1,35 @@ +# RoleObjectPermission + +Role-bound object level permission + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | [readonly] +**codename** | **str** | | [readonly] +**model** | **str** | | [readonly] +**app_label** | **str** | | [readonly] +**object_pk** | **str** | | +**name** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.role_object_permission import RoleObjectPermission + +# TODO update the JSON string below +json = "{}" +# create an instance of RoleObjectPermission from a JSON string +role_object_permission_instance = RoleObjectPermission.from_json(json) +# print the JSON string representation of the object +print(RoleObjectPermission.to_json()) + +# convert the object into a dict +role_object_permission_dict = role_object_permission_instance.to_dict() +# create an instance of RoleObjectPermission from a dict +role_object_permission_from_dict = RoleObjectPermission.from_dict(role_object_permission_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RoleRequest.md b/docs/RoleRequest.md new file mode 100644 index 000000000..3a3be5b70 --- /dev/null +++ b/docs/RoleRequest.md @@ -0,0 +1,30 @@ +# RoleRequest + +Role serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | + +## Example + +```python +from authentik_client.models.role_request import RoleRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of RoleRequest from a JSON string +role_request_instance = RoleRequest.from_json(json) +# print the JSON string representation of the object +print(RoleRequest.to_json()) + +# convert the object into a dict +role_request_dict = role_request_instance.to_dict() +# create an instance of RoleRequest from a dict +role_request_from_dict = RoleRequest.from_dict(role_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RootApi.md b/docs/RootApi.md new file mode 100644 index 000000000..9adfb6446 --- /dev/null +++ b/docs/RootApi.md @@ -0,0 +1,82 @@ +# authentik_client.RootApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**root_config_retrieve**](RootApi.md#root_config_retrieve) | **GET** /root/config/ | + + +# **root_config_retrieve** +> Config root_config_retrieve() + +Retrieve public configuration options + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.config import Config +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.RootApi(api_client) + + try: + api_response = api_instance.root_config_retrieve() + print("The response of RootApi->root_config_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling RootApi->root_config_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**Config**](Config.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/SAMLBindingsEnum.md b/docs/SAMLBindingsEnum.md new file mode 100644 index 000000000..0153c187a --- /dev/null +++ b/docs/SAMLBindingsEnum.md @@ -0,0 +1,12 @@ +# SAMLBindingsEnum + + +## Enum + +* `REDIRECT` (value: `'redirect'`) + +* `POST` (value: `'post'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLLogoutMethods.md b/docs/SAMLLogoutMethods.md new file mode 100644 index 000000000..383fb4542 --- /dev/null +++ b/docs/SAMLLogoutMethods.md @@ -0,0 +1,14 @@ +# SAMLLogoutMethods + + +## Enum + +* `FRONTCHANNEL_IFRAME` (value: `'frontchannel_iframe'`) + +* `FRONTCHANNEL_NATIVE` (value: `'frontchannel_native'`) + +* `BACKCHANNEL` (value: `'backchannel'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLMetadata.md b/docs/SAMLMetadata.md new file mode 100644 index 000000000..3c73e438b --- /dev/null +++ b/docs/SAMLMetadata.md @@ -0,0 +1,31 @@ +# SAMLMetadata + +SAML Provider Metadata serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**metadata** | **str** | | +**download_url** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.saml_metadata import SAMLMetadata + +# TODO update the JSON string below +json = "{}" +# create an instance of SAMLMetadata from a JSON string +saml_metadata_instance = SAMLMetadata.from_json(json) +# print the JSON string representation of the object +print(SAMLMetadata.to_json()) + +# convert the object into a dict +saml_metadata_dict = saml_metadata_instance.to_dict() +# create an instance of SAMLMetadata from a dict +saml_metadata_from_dict = SAMLMetadata.from_dict(saml_metadata_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLNameIDPolicyEnum.md b/docs/SAMLNameIDPolicyEnum.md new file mode 100644 index 000000000..a8e71ec2a --- /dev/null +++ b/docs/SAMLNameIDPolicyEnum.md @@ -0,0 +1,20 @@ +# SAMLNameIDPolicyEnum + + +## Enum + +* `URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_1_DOT_1_COLON_NAMEID_MINUS_FORMAT_COLON_EMAIL_ADDRESS` (value: `'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress'`) + +* `URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_NAMEID_MINUS_FORMAT_COLON_PERSISTENT` (value: `'urn:oasis:names:tc:SAML:2.0:nameid-format:persistent'`) + +* `URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_1_DOT_1_COLON_NAMEID_MINUS_FORMAT_COLON_X509_SUBJECT_NAME` (value: `'urn:oasis:names:tc:SAML:1.1:nameid-format:X509SubjectName'`) + +* `URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_NAMEID_MINUS_FORMAT_COLON_WINDOWS_DOMAIN_QUALIFIED_NAME` (value: `'urn:oasis:names:tc:SAML:2.0:nameid-format:WindowsDomainQualifiedName'`) + +* `URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_2_DOT_0_COLON_NAMEID_MINUS_FORMAT_COLON_TRANSIENT` (value: `'urn:oasis:names:tc:SAML:2.0:nameid-format:transient'`) + +* `URN_COLON_OASIS_COLON_NAMES_COLON_TC_COLON_SAML_COLON_1_DOT_1_COLON_NAMEID_MINUS_FORMAT_COLON_UNSPECIFIED` (value: `'urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLPropertyMapping.md b/docs/SAMLPropertyMapping.md new file mode 100644 index 000000000..8b55ad7c7 --- /dev/null +++ b/docs/SAMLPropertyMapping.md @@ -0,0 +1,39 @@ +# SAMLPropertyMapping + +SAMLPropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**saml_name** | **str** | | +**friendly_name** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of SAMLPropertyMapping from a JSON string +saml_property_mapping_instance = SAMLPropertyMapping.from_json(json) +# print the JSON string representation of the object +print(SAMLPropertyMapping.to_json()) + +# convert the object into a dict +saml_property_mapping_dict = saml_property_mapping_instance.to_dict() +# create an instance of SAMLPropertyMapping from a dict +saml_property_mapping_from_dict = SAMLPropertyMapping.from_dict(saml_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLPropertyMappingRequest.md b/docs/SAMLPropertyMappingRequest.md new file mode 100644 index 000000000..edb7e3f36 --- /dev/null +++ b/docs/SAMLPropertyMappingRequest.md @@ -0,0 +1,34 @@ +# SAMLPropertyMappingRequest + +SAMLPropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**saml_name** | **str** | | +**friendly_name** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.saml_property_mapping_request import SAMLPropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SAMLPropertyMappingRequest from a JSON string +saml_property_mapping_request_instance = SAMLPropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(SAMLPropertyMappingRequest.to_json()) + +# convert the object into a dict +saml_property_mapping_request_dict = saml_property_mapping_request_instance.to_dict() +# create an instance of SAMLPropertyMappingRequest from a dict +saml_property_mapping_request_from_dict = SAMLPropertyMappingRequest.from_dict(saml_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLProvider.md b/docs/SAMLProvider.md new file mode 100644 index 000000000..78cef643d --- /dev/null +++ b/docs/SAMLProvider.md @@ -0,0 +1,75 @@ +# SAMLProvider + +SAMLProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_application_name** | **str** | Application's display Name. | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**acs_url** | **str** | | +**sls_url** | **str** | Single Logout Service URL where the logout response should be sent. | [optional] +**audience** | **str** | Value of the audience restriction field of the assertion. When left empty, no audience restriction will be added. | [optional] +**issuer_override** | **str** | Also known as EntityID. Providing a value overrides the default issuer generated by authentik. | [optional] +**assertion_valid_not_before** | **str** | Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3). | [optional] +**assertion_valid_not_on_or_after** | **str** | Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**session_valid_not_on_or_after** | **str** | Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**name_id_mapping** | **UUID** | Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered | [optional] +**authn_context_class_ref_mapping** | **UUID** | Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Service Provider. | [optional] +**verification_kp** | **UUID** | When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default. | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**sign_assertion** | **bool** | | [optional] +**sign_response** | **bool** | | [optional] +**sign_logout_request** | **bool** | | [optional] +**sign_logout_response** | **bool** | | [optional] +**sp_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | This determines how authentik sends the response back to the Service Provider. | [optional] +**sls_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | This determines how authentik sends the logout response back to the Service Provider. | [optional] +**logout_method** | [**SAMLLogoutMethods**](SAMLLogoutMethods.md) | Method to use for logout. Front-channel iframe loads all logout URLs simultaneously in hidden iframes. Front-channel native uses your active browser tab to send post requests and redirect to providers. Back-channel sends logout requests directly from the server without user interaction (requires POST SLS binding). | [optional] +**default_relay_state** | **str** | Default relay_state value for IDP-initiated logins | [optional] +**default_name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | | [optional] +**url_download_metadata** | **str** | Get metadata download URL | [readonly] +**url_issuer** | **str** | Get Issuer/EntityID URL | [readonly] +**url_unified** | **str** | Get unified SAML endpoint URL (handles SSO and SLO) | [readonly] +**url_unified_init** | **str** | Get IdP-initiated SAML URL | [readonly] +**url_sso_post** | **str** | Get SSO Post URL | [readonly] +**url_sso_redirect** | **str** | Get SSO Redirect URL | [readonly] +**url_sso_init** | **str** | Get SSO IDP-Initiated URL | [readonly] +**url_slo_post** | **str** | Get SLO POST URL | [readonly] +**url_slo_redirect** | **str** | Get SLO redirect URL | [readonly] + +## Example + +```python +from authentik_client.models.saml_provider import SAMLProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of SAMLProvider from a JSON string +saml_provider_instance = SAMLProvider.from_json(json) +# print the JSON string representation of the object +print(SAMLProvider.to_json()) + +# convert the object into a dict +saml_provider_dict = saml_provider_instance.to_dict() +# create an instance of SAMLProvider from a dict +saml_provider_from_dict = SAMLProvider.from_dict(saml_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLProviderRequest.md b/docs/SAMLProviderRequest.md new file mode 100644 index 000000000..93dcbc9bd --- /dev/null +++ b/docs/SAMLProviderRequest.md @@ -0,0 +1,57 @@ +# SAMLProviderRequest + +SAMLProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**acs_url** | **str** | | +**sls_url** | **str** | Single Logout Service URL where the logout response should be sent. | [optional] +**audience** | **str** | Value of the audience restriction field of the assertion. When left empty, no audience restriction will be added. | [optional] +**issuer_override** | **str** | Also known as EntityID. Providing a value overrides the default issuer generated by authentik. | [optional] +**assertion_valid_not_before** | **str** | Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3). | [optional] +**assertion_valid_not_on_or_after** | **str** | Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**session_valid_not_on_or_after** | **str** | Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**name_id_mapping** | **UUID** | Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered | [optional] +**authn_context_class_ref_mapping** | **UUID** | Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Service Provider. | [optional] +**verification_kp** | **UUID** | When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default. | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**sign_assertion** | **bool** | | [optional] +**sign_response** | **bool** | | [optional] +**sign_logout_request** | **bool** | | [optional] +**sign_logout_response** | **bool** | | [optional] +**sp_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | This determines how authentik sends the response back to the Service Provider. | [optional] +**sls_binding** | [**SAMLBindingsEnum**](SAMLBindingsEnum.md) | This determines how authentik sends the logout response back to the Service Provider. | [optional] +**logout_method** | [**SAMLLogoutMethods**](SAMLLogoutMethods.md) | Method to use for logout. Front-channel iframe loads all logout URLs simultaneously in hidden iframes. Front-channel native uses your active browser tab to send post requests and redirect to providers. Back-channel sends logout requests directly from the server without user interaction (requires POST SLS binding). | [optional] +**default_relay_state** | **str** | Default relay_state value for IDP-initiated logins | [optional] +**default_name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.saml_provider_request import SAMLProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SAMLProviderRequest from a JSON string +saml_provider_request_instance = SAMLProviderRequest.from_json(json) +# print the JSON string representation of the object +print(SAMLProviderRequest.to_json()) + +# convert the object into a dict +saml_provider_request_dict = saml_provider_request_instance.to_dict() +# create an instance of SAMLProviderRequest from a dict +saml_provider_request_from_dict = SAMLProviderRequest.from_dict(saml_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLSource.md b/docs/SAMLSource.md new file mode 100644 index 000000000..5b15f2fa8 --- /dev/null +++ b/docs/SAMLSource.md @@ -0,0 +1,66 @@ +# SAMLSource + +SAMLSource Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [readonly] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**icon_url** | **str** | | [readonly] +**icon_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**pre_authentication_flow** | **UUID** | Flow used before authentication. | +**issuer** | **str** | Also known as Entity ID. Defaults the Metadata URL. | [optional] +**sso_url** | **str** | URL that the initial Login request is sent to. | +**slo_url** | **str** | Optional URL if your IDP supports Single-Logout. | [optional] +**allow_idp_initiated** | **bool** | Allows authentication flows initiated by the IdP. This can be a security risk, as no validation of the request ID is done. | [optional] +**force_authn** | **bool** | When enabled, the IdP will re-authenticate the user even if a session exists. | [optional] +**name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | NameID Policy sent to the IdP. Can be unset, in which case no Policy is sent. | [optional] +**binding_type** | [**BindingTypeEnum**](BindingTypeEnum.md) | | [optional] +**verification_kp** | **UUID** | When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default. | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Identity Provider. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**temporary_user_delete_after** | **str** | Time offset when temporary users should be deleted. This only applies if your IDP uses the NameID Format 'transient', and the user doesn't log out manually. (Format: hours=1;minutes=2;seconds=3). | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**signed_assertion** | **bool** | | [optional] +**signed_response** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.saml_source import SAMLSource + +# TODO update the JSON string below +json = "{}" +# create an instance of SAMLSource from a JSON string +saml_source_instance = SAMLSource.from_json(json) +# print the JSON string representation of the object +print(SAMLSource.to_json()) + +# convert the object into a dict +saml_source_dict = saml_source_instance.to_dict() +# create an instance of SAMLSource from a dict +saml_source_from_dict = SAMLSource.from_dict(saml_source_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLSourcePropertyMapping.md b/docs/SAMLSourcePropertyMapping.md new file mode 100644 index 000000000..86057d171 --- /dev/null +++ b/docs/SAMLSourcePropertyMapping.md @@ -0,0 +1,37 @@ +# SAMLSourcePropertyMapping + +SAMLSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of SAMLSourcePropertyMapping from a JSON string +saml_source_property_mapping_instance = SAMLSourcePropertyMapping.from_json(json) +# print the JSON string representation of the object +print(SAMLSourcePropertyMapping.to_json()) + +# convert the object into a dict +saml_source_property_mapping_dict = saml_source_property_mapping_instance.to_dict() +# create an instance of SAMLSourcePropertyMapping from a dict +saml_source_property_mapping_from_dict = SAMLSourcePropertyMapping.from_dict(saml_source_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLSourcePropertyMappingRequest.md b/docs/SAMLSourcePropertyMappingRequest.md new file mode 100644 index 000000000..31b0b6fec --- /dev/null +++ b/docs/SAMLSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# SAMLSourcePropertyMappingRequest + +SAMLSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.saml_source_property_mapping_request import SAMLSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SAMLSourcePropertyMappingRequest from a JSON string +saml_source_property_mapping_request_instance = SAMLSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(SAMLSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +saml_source_property_mapping_request_dict = saml_source_property_mapping_request_instance.to_dict() +# create an instance of SAMLSourcePropertyMappingRequest from a dict +saml_source_property_mapping_request_from_dict = SAMLSourcePropertyMappingRequest.from_dict(saml_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SAMLSourceRequest.md b/docs/SAMLSourceRequest.md new file mode 100644 index 000000000..0d90704b8 --- /dev/null +++ b/docs/SAMLSourceRequest.md @@ -0,0 +1,58 @@ +# SAMLSourceRequest + +SAMLSource Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**group_matching_mode** | [**GroupMatchingModeEnum**](GroupMatchingModeEnum.md) | How the source determines if an existing group should be used or a new group created. | [optional] +**pre_authentication_flow** | **UUID** | Flow used before authentication. | +**issuer** | **str** | Also known as Entity ID. Defaults the Metadata URL. | [optional] +**sso_url** | **str** | URL that the initial Login request is sent to. | +**slo_url** | **str** | Optional URL if your IDP supports Single-Logout. | [optional] +**allow_idp_initiated** | **bool** | Allows authentication flows initiated by the IdP. This can be a security risk, as no validation of the request ID is done. | [optional] +**force_authn** | **bool** | When enabled, the IdP will re-authenticate the user even if a session exists. | [optional] +**name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | NameID Policy sent to the IdP. Can be unset, in which case no Policy is sent. | [optional] +**binding_type** | [**BindingTypeEnum**](BindingTypeEnum.md) | | [optional] +**verification_kp** | **UUID** | When selected, incoming assertion's Signatures will be validated against this certificate. To allow unsigned Requests, leave on default. | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Identity Provider. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**temporary_user_delete_after** | **str** | Time offset when temporary users should be deleted. This only applies if your IDP uses the NameID Format 'transient', and the user doesn't log out manually. (Format: hours=1;minutes=2;seconds=3). | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**signed_assertion** | **bool** | | [optional] +**signed_response** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.saml_source_request import SAMLSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SAMLSourceRequest from a JSON string +saml_source_request_instance = SAMLSourceRequest.from_json(json) +# print the JSON string representation of the object +print(SAMLSourceRequest.to_json()) + +# convert the object into a dict +saml_source_request_dict = saml_source_request_instance.to_dict() +# create an instance of SAMLSourceRequest from a dict +saml_source_request_from_dict = SAMLSourceRequest.from_dict(saml_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMAuthenticationModeEnum.md b/docs/SCIMAuthenticationModeEnum.md new file mode 100644 index 000000000..5e0b1a8d6 --- /dev/null +++ b/docs/SCIMAuthenticationModeEnum.md @@ -0,0 +1,14 @@ +# SCIMAuthenticationModeEnum + + +## Enum + +* `TOKEN` (value: `'token'`) + +* `OAUTH` (value: `'oauth'`) + +* `OAUTH_INTERACTIVE` (value: `'oauth_interactive'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMMapping.md b/docs/SCIMMapping.md new file mode 100644 index 000000000..a8d077e47 --- /dev/null +++ b/docs/SCIMMapping.md @@ -0,0 +1,37 @@ +# SCIMMapping + +SCIMMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.scim_mapping import SCIMMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMMapping from a JSON string +scim_mapping_instance = SCIMMapping.from_json(json) +# print the JSON string representation of the object +print(SCIMMapping.to_json()) + +# convert the object into a dict +scim_mapping_dict = scim_mapping_instance.to_dict() +# create an instance of SCIMMapping from a dict +scim_mapping_from_dict = SCIMMapping.from_dict(scim_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMMappingRequest.md b/docs/SCIMMappingRequest.md new file mode 100644 index 000000000..243d9b11a --- /dev/null +++ b/docs/SCIMMappingRequest.md @@ -0,0 +1,32 @@ +# SCIMMappingRequest + +SCIMMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.scim_mapping_request import SCIMMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMMappingRequest from a JSON string +scim_mapping_request_instance = SCIMMappingRequest.from_json(json) +# print the JSON string representation of the object +print(SCIMMappingRequest.to_json()) + +# convert the object into a dict +scim_mapping_request_dict = scim_mapping_request_instance.to_dict() +# create an instance of SCIMMappingRequest from a dict +scim_mapping_request_from_dict = SCIMMappingRequest.from_dict(scim_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMProvider.md b/docs/SCIMProvider.md new file mode 100644 index 000000000..855923e25 --- /dev/null +++ b/docs/SCIMProvider.md @@ -0,0 +1,55 @@ +# SCIMProvider + +SCIMProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**url** | **str** | Base URL to SCIM requests, usually ends in /v2 | +**verify_certificates** | **bool** | | [optional] +**auth_mode** | [**SCIMAuthenticationModeEnum**](SCIMAuthenticationModeEnum.md) | | [optional] +**auth_oauth** | **UUID** | OAuth Source used for authentication | [optional] +**auth_oauth_params** | **Dict[str, object]** | Additional OAuth parameters, such as grant_type | [optional] +**auth_oauth_token_last_updated** | **datetime** | | [readonly] +**auth_oauth_token_expires** | **datetime** | | [readonly] +**auth_oauth_url_callback** | **str** | | [readonly] +**auth_oauth_url_start** | **str** | | [readonly] +**compatibility_mode** | [**CompatibilityModeEnum**](CompatibilityModeEnum.md) | Alter authentik behavior for vendor-specific SCIM implementations. | [optional] +**service_provider_config_cache_timeout** | **str** | Cache duration for ServiceProviderConfig responses. Set minutes=0 to disable. | [optional] +**exclude_users_service_account** | **bool** | | [optional] +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**group_filters** | **List[UUID]** | Group filters used to define sync-scope for groups. | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] + +## Example + +```python +from authentik_client.models.scim_provider import SCIMProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMProvider from a JSON string +scim_provider_instance = SCIMProvider.from_json(json) +# print the JSON string representation of the object +print(SCIMProvider.to_json()) + +# convert the object into a dict +scim_provider_dict = scim_provider_instance.to_dict() +# create an instance of SCIMProvider from a dict +scim_provider_from_dict = SCIMProvider.from_dict(scim_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMProviderGroup.md b/docs/SCIMProviderGroup.md new file mode 100644 index 000000000..6d3f9f80e --- /dev/null +++ b/docs/SCIMProviderGroup.md @@ -0,0 +1,35 @@ +# SCIMProviderGroup + +SCIMProviderGroup Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**scim_id** | **str** | | +**group** | **UUID** | | +**group_obj** | [**PartialGroup**](PartialGroup.md) | | [readonly] +**provider** | **int** | | +**attributes** | **Dict[str, object]** | | [readonly] + +## Example + +```python +from authentik_client.models.scim_provider_group import SCIMProviderGroup + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMProviderGroup from a JSON string +scim_provider_group_instance = SCIMProviderGroup.from_json(json) +# print the JSON string representation of the object +print(SCIMProviderGroup.to_json()) + +# convert the object into a dict +scim_provider_group_dict = scim_provider_group_instance.to_dict() +# create an instance of SCIMProviderGroup from a dict +scim_provider_group_from_dict = SCIMProviderGroup.from_dict(scim_provider_group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMProviderGroupRequest.md b/docs/SCIMProviderGroupRequest.md new file mode 100644 index 000000000..b8a9995a2 --- /dev/null +++ b/docs/SCIMProviderGroupRequest.md @@ -0,0 +1,32 @@ +# SCIMProviderGroupRequest + +SCIMProviderGroup Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**scim_id** | **str** | | +**group** | **UUID** | | +**provider** | **int** | | + +## Example + +```python +from authentik_client.models.scim_provider_group_request import SCIMProviderGroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMProviderGroupRequest from a JSON string +scim_provider_group_request_instance = SCIMProviderGroupRequest.from_json(json) +# print the JSON string representation of the object +print(SCIMProviderGroupRequest.to_json()) + +# convert the object into a dict +scim_provider_group_request_dict = scim_provider_group_request_instance.to_dict() +# create an instance of SCIMProviderGroupRequest from a dict +scim_provider_group_request_from_dict = SCIMProviderGroupRequest.from_dict(scim_provider_group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMProviderRequest.md b/docs/SCIMProviderRequest.md new file mode 100644 index 000000000..628f73ce8 --- /dev/null +++ b/docs/SCIMProviderRequest.md @@ -0,0 +1,45 @@ +# SCIMProviderRequest + +SCIMProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**property_mappings** | **List[UUID]** | | [optional] +**property_mappings_group** | **List[UUID]** | Property mappings used for group creation/updating. | [optional] +**url** | **str** | Base URL to SCIM requests, usually ends in /v2 | +**verify_certificates** | **bool** | | [optional] +**token** | **str** | Authentication token | [optional] +**auth_mode** | [**SCIMAuthenticationModeEnum**](SCIMAuthenticationModeEnum.md) | | [optional] +**auth_oauth** | **UUID** | OAuth Source used for authentication | [optional] +**auth_oauth_params** | **Dict[str, object]** | Additional OAuth parameters, such as grant_type | [optional] +**compatibility_mode** | [**CompatibilityModeEnum**](CompatibilityModeEnum.md) | Alter authentik behavior for vendor-specific SCIM implementations. | [optional] +**service_provider_config_cache_timeout** | **str** | Cache duration for ServiceProviderConfig responses. Set minutes=0 to disable. | [optional] +**exclude_users_service_account** | **bool** | | [optional] +**sync_page_size** | **int** | Controls the number of objects synced in a single task | [optional] +**sync_page_timeout** | **str** | Timeout for synchronization of a single page | [optional] +**group_filters** | **List[UUID]** | Group filters used to define sync-scope for groups. | [optional] +**dry_run** | **bool** | When enabled, provider will not modify or create objects in the remote system. | [optional] + +## Example + +```python +from authentik_client.models.scim_provider_request import SCIMProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMProviderRequest from a JSON string +scim_provider_request_instance = SCIMProviderRequest.from_json(json) +# print the JSON string representation of the object +print(SCIMProviderRequest.to_json()) + +# convert the object into a dict +scim_provider_request_dict = scim_provider_request_instance.to_dict() +# create an instance of SCIMProviderRequest from a dict +scim_provider_request_from_dict = SCIMProviderRequest.from_dict(scim_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMProviderUser.md b/docs/SCIMProviderUser.md new file mode 100644 index 000000000..48b26bab2 --- /dev/null +++ b/docs/SCIMProviderUser.md @@ -0,0 +1,35 @@ +# SCIMProviderUser + +SCIMProviderUser Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**scim_id** | **str** | | +**user** | **int** | | +**user_obj** | [**PartialUser**](PartialUser.md) | | [readonly] +**provider** | **int** | | +**attributes** | **Dict[str, object]** | | [readonly] + +## Example + +```python +from authentik_client.models.scim_provider_user import SCIMProviderUser + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMProviderUser from a JSON string +scim_provider_user_instance = SCIMProviderUser.from_json(json) +# print the JSON string representation of the object +print(SCIMProviderUser.to_json()) + +# convert the object into a dict +scim_provider_user_dict = scim_provider_user_instance.to_dict() +# create an instance of SCIMProviderUser from a dict +scim_provider_user_from_dict = SCIMProviderUser.from_dict(scim_provider_user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMProviderUserRequest.md b/docs/SCIMProviderUserRequest.md new file mode 100644 index 000000000..48662d793 --- /dev/null +++ b/docs/SCIMProviderUserRequest.md @@ -0,0 +1,32 @@ +# SCIMProviderUserRequest + +SCIMProviderUser Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**scim_id** | **str** | | +**user** | **int** | | +**provider** | **int** | | + +## Example + +```python +from authentik_client.models.scim_provider_user_request import SCIMProviderUserRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMProviderUserRequest from a JSON string +scim_provider_user_request_instance = SCIMProviderUserRequest.from_json(json) +# print the JSON string representation of the object +print(SCIMProviderUserRequest.to_json()) + +# convert the object into a dict +scim_provider_user_request_dict = scim_provider_user_request_instance.to_dict() +# create an instance of SCIMProviderUserRequest from a dict +scim_provider_user_request_from_dict = SCIMProviderUserRequest.from_dict(scim_provider_user_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMSource.md b/docs/SCIMSource.md new file mode 100644 index 000000000..57f586a20 --- /dev/null +++ b/docs/SCIMSource.md @@ -0,0 +1,43 @@ +# SCIMSource + +SCIMSource Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [readonly] +**user_path_template** | **str** | | [optional] +**root_url** | **str** | Get Root URL | [readonly] +**token_obj** | [**Token**](Token.md) | | [readonly] + +## Example + +```python +from authentik_client.models.scim_source import SCIMSource + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMSource from a JSON string +scim_source_instance = SCIMSource.from_json(json) +# print the JSON string representation of the object +print(SCIMSource.to_json()) + +# convert the object into a dict +scim_source_dict = scim_source_instance.to_dict() +# create an instance of SCIMSource from a dict +scim_source_from_dict = SCIMSource.from_dict(scim_source_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMSourceGroup.md b/docs/SCIMSourceGroup.md new file mode 100644 index 000000000..89ab25402 --- /dev/null +++ b/docs/SCIMSourceGroup.md @@ -0,0 +1,35 @@ +# SCIMSourceGroup + +SCIMSourceGroup Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | [optional] +**external_id** | **str** | | +**group** | **UUID** | | +**group_obj** | [**PartialGroup**](PartialGroup.md) | | [readonly] +**source** | **UUID** | | +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.scim_source_group import SCIMSourceGroup + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMSourceGroup from a JSON string +scim_source_group_instance = SCIMSourceGroup.from_json(json) +# print the JSON string representation of the object +print(SCIMSourceGroup.to_json()) + +# convert the object into a dict +scim_source_group_dict = scim_source_group_instance.to_dict() +# create an instance of SCIMSourceGroup from a dict +scim_source_group_from_dict = SCIMSourceGroup.from_dict(scim_source_group_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMSourceGroupRequest.md b/docs/SCIMSourceGroupRequest.md new file mode 100644 index 000000000..e84f2a186 --- /dev/null +++ b/docs/SCIMSourceGroupRequest.md @@ -0,0 +1,34 @@ +# SCIMSourceGroupRequest + +SCIMSourceGroup Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | [optional] +**external_id** | **str** | | +**group** | **UUID** | | +**source** | **UUID** | | +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.scim_source_group_request import SCIMSourceGroupRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMSourceGroupRequest from a JSON string +scim_source_group_request_instance = SCIMSourceGroupRequest.from_json(json) +# print the JSON string representation of the object +print(SCIMSourceGroupRequest.to_json()) + +# convert the object into a dict +scim_source_group_request_dict = scim_source_group_request_instance.to_dict() +# create an instance of SCIMSourceGroupRequest from a dict +scim_source_group_request_from_dict = SCIMSourceGroupRequest.from_dict(scim_source_group_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMSourcePropertyMapping.md b/docs/SCIMSourcePropertyMapping.md new file mode 100644 index 000000000..57e518576 --- /dev/null +++ b/docs/SCIMSourcePropertyMapping.md @@ -0,0 +1,37 @@ +# SCIMSourcePropertyMapping + +SCIMSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMSourcePropertyMapping from a JSON string +scim_source_property_mapping_instance = SCIMSourcePropertyMapping.from_json(json) +# print the JSON string representation of the object +print(SCIMSourcePropertyMapping.to_json()) + +# convert the object into a dict +scim_source_property_mapping_dict = scim_source_property_mapping_instance.to_dict() +# create an instance of SCIMSourcePropertyMapping from a dict +scim_source_property_mapping_from_dict = SCIMSourcePropertyMapping.from_dict(scim_source_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMSourcePropertyMappingRequest.md b/docs/SCIMSourcePropertyMappingRequest.md new file mode 100644 index 000000000..80e07b129 --- /dev/null +++ b/docs/SCIMSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# SCIMSourcePropertyMappingRequest + +SCIMSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.scim_source_property_mapping_request import SCIMSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMSourcePropertyMappingRequest from a JSON string +scim_source_property_mapping_request_instance = SCIMSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(SCIMSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +scim_source_property_mapping_request_dict = scim_source_property_mapping_request_instance.to_dict() +# create an instance of SCIMSourcePropertyMappingRequest from a dict +scim_source_property_mapping_request_from_dict = SCIMSourcePropertyMappingRequest.from_dict(scim_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMSourceRequest.md b/docs/SCIMSourceRequest.md new file mode 100644 index 000000000..f74e84c3e --- /dev/null +++ b/docs/SCIMSourceRequest.md @@ -0,0 +1,35 @@ +# SCIMSourceRequest + +SCIMSource Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**user_path_template** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.scim_source_request import SCIMSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMSourceRequest from a JSON string +scim_source_request_instance = SCIMSourceRequest.from_json(json) +# print the JSON string representation of the object +print(SCIMSourceRequest.to_json()) + +# convert the object into a dict +scim_source_request_dict = scim_source_request_instance.to_dict() +# create an instance of SCIMSourceRequest from a dict +scim_source_request_from_dict = SCIMSourceRequest.from_dict(scim_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMSourceUser.md b/docs/SCIMSourceUser.md new file mode 100644 index 000000000..ae5a690a7 --- /dev/null +++ b/docs/SCIMSourceUser.md @@ -0,0 +1,35 @@ +# SCIMSourceUser + +SCIMSourceUser Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | [optional] +**external_id** | **str** | | +**user** | **int** | | +**user_obj** | [**PartialUser**](PartialUser.md) | | [readonly] +**source** | **UUID** | | +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.scim_source_user import SCIMSourceUser + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMSourceUser from a JSON string +scim_source_user_instance = SCIMSourceUser.from_json(json) +# print the JSON string representation of the object +print(SCIMSourceUser.to_json()) + +# convert the object into a dict +scim_source_user_dict = scim_source_user_instance.to_dict() +# create an instance of SCIMSourceUser from a dict +scim_source_user_from_dict = SCIMSourceUser.from_dict(scim_source_user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SCIMSourceUserRequest.md b/docs/SCIMSourceUserRequest.md new file mode 100644 index 000000000..192940bd1 --- /dev/null +++ b/docs/SCIMSourceUserRequest.md @@ -0,0 +1,34 @@ +# SCIMSourceUserRequest + +SCIMSourceUser Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | | [optional] +**external_id** | **str** | | +**user** | **int** | | +**source** | **UUID** | | +**attributes** | **Dict[str, object]** | | [optional] + +## Example + +```python +from authentik_client.models.scim_source_user_request import SCIMSourceUserRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SCIMSourceUserRequest from a JSON string +scim_source_user_request_instance = SCIMSourceUserRequest.from_json(json) +# print the JSON string representation of the object +print(SCIMSourceUserRequest.to_json()) + +# convert the object into a dict +scim_source_user_request_dict = scim_source_user_request_instance.to_dict() +# create an instance of SCIMSourceUserRequest from a dict +scim_source_user_request_from_dict = SCIMSourceUserRequest.from_dict(scim_source_user_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SMSDevice.md b/docs/SMSDevice.md new file mode 100644 index 000000000..65e716927 --- /dev/null +++ b/docs/SMSDevice.md @@ -0,0 +1,33 @@ +# SMSDevice + +Serializer for sms authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | +**pk** | **int** | | [readonly] +**phone_number** | **str** | | [readonly] +**user** | [**PartialUser**](PartialUser.md) | | [readonly] + +## Example + +```python +from authentik_client.models.sms_device import SMSDevice + +# TODO update the JSON string below +json = "{}" +# create an instance of SMSDevice from a JSON string +sms_device_instance = SMSDevice.from_json(json) +# print the JSON string representation of the object +print(SMSDevice.to_json()) + +# convert the object into a dict +sms_device_dict = sms_device_instance.to_dict() +# create an instance of SMSDevice from a dict +sms_device_from_dict = SMSDevice.from_dict(sms_device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SMSDeviceRequest.md b/docs/SMSDeviceRequest.md new file mode 100644 index 000000000..f89dc273d --- /dev/null +++ b/docs/SMSDeviceRequest.md @@ -0,0 +1,30 @@ +# SMSDeviceRequest + +Serializer for sms authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | + +## Example + +```python +from authentik_client.models.sms_device_request import SMSDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SMSDeviceRequest from a JSON string +sms_device_request_instance = SMSDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(SMSDeviceRequest.to_json()) + +# convert the object into a dict +sms_device_request_dict = sms_device_request_instance.to_dict() +# create an instance of SMSDeviceRequest from a dict +sms_device_request_from_dict = SMSDeviceRequest.from_dict(sms_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SSFProvider.md b/docs/SSFProvider.md new file mode 100644 index 000000000..1af3f58e1 --- /dev/null +++ b/docs/SSFProvider.md @@ -0,0 +1,42 @@ +# SSFProvider + +SSFProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**signing_key** | **UUID** | Key used to sign the SSF Events. | +**token_obj** | [**Token**](Token.md) | | [readonly] +**oidc_auth_providers** | **List[int]** | | [optional] +**oidc_auth_providers_obj** | [**List[Provider]**](Provider.md) | | [readonly] +**ssf_url** | **str** | | [readonly] +**event_retention** | **str** | | [optional] +**push_verify_certificates** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.ssf_provider import SSFProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of SSFProvider from a JSON string +ssf_provider_instance = SSFProvider.from_json(json) +# print the JSON string representation of the object +print(SSFProvider.to_json()) + +# convert the object into a dict +ssf_provider_dict = ssf_provider_instance.to_dict() +# create an instance of SSFProvider from a dict +ssf_provider_from_dict = SSFProvider.from_dict(ssf_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SSFProviderRequest.md b/docs/SSFProviderRequest.md new file mode 100644 index 000000000..c7e19d284 --- /dev/null +++ b/docs/SSFProviderRequest.md @@ -0,0 +1,34 @@ +# SSFProviderRequest + +SSFProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**signing_key** | **UUID** | Key used to sign the SSF Events. | +**oidc_auth_providers** | **List[int]** | | [optional] +**event_retention** | **str** | | [optional] +**push_verify_certificates** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.ssf_provider_request import SSFProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SSFProviderRequest from a JSON string +ssf_provider_request_instance = SSFProviderRequest.from_json(json) +# print the JSON string representation of the object +print(SSFProviderRequest.to_json()) + +# convert the object into a dict +ssf_provider_request_dict = ssf_provider_request_instance.to_dict() +# create an instance of SSFProviderRequest from a dict +ssf_provider_request_from_dict = SSFProviderRequest.from_dict(ssf_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SSFStream.md b/docs/SSFStream.md new file mode 100644 index 000000000..70053f901 --- /dev/null +++ b/docs/SSFStream.md @@ -0,0 +1,39 @@ +# SSFStream + +SSFStream Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**status** | [**SSFStreamStatusEnum**](SSFStreamStatusEnum.md) | | [optional] +**provider** | **int** | | +**provider_obj** | [**SSFProvider**](SSFProvider.md) | | [readonly] +**delivery_method** | [**DeliveryMethodEnum**](DeliveryMethodEnum.md) | | +**endpoint_url** | **str** | | [optional] +**events_requested** | [**List[EventsRequestedEnum]**](EventsRequestedEnum.md) | | [optional] +**format** | **str** | | +**aud** | **List[str]** | | [optional] +**iss** | **str** | | + +## Example + +```python +from authentik_client.models.ssf_stream import SSFStream + +# TODO update the JSON string below +json = "{}" +# create an instance of SSFStream from a JSON string +ssf_stream_instance = SSFStream.from_json(json) +# print the JSON string representation of the object +print(SSFStream.to_json()) + +# convert the object into a dict +ssf_stream_dict = ssf_stream_instance.to_dict() +# create an instance of SSFStream from a dict +ssf_stream_from_dict = SSFStream.from_dict(ssf_stream_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SSFStreamStatusEnum.md b/docs/SSFStreamStatusEnum.md new file mode 100644 index 000000000..c10da66b0 --- /dev/null +++ b/docs/SSFStreamStatusEnum.md @@ -0,0 +1,16 @@ +# SSFStreamStatusEnum + + +## Enum + +* `ENABLED` (value: `'enabled'`) + +* `PAUSED` (value: `'paused'`) + +* `DISABLED` (value: `'disabled'`) + +* `DISABLED_DELETED` (value: `'disabled_deleted'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Schedule.md b/docs/Schedule.md new file mode 100644 index 000000000..8dd06de6e --- /dev/null +++ b/docs/Schedule.md @@ -0,0 +1,40 @@ +# Schedule + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **UUID** | | [readonly] +**identifier** | **str** | Unique schedule identifier | [readonly] +**uid** | **str** | | [readonly] +**actor_name** | **str** | Dramatiq actor to call | [readonly] +**rel_obj_app_label** | **str** | | [readonly] +**rel_obj_model** | **str** | | [readonly] +**rel_obj_id** | **str** | | [optional] +**crontab** | **str** | When to schedule tasks | +**paused** | **bool** | Pause this schedule | [optional] +**next_run** | **datetime** | | [readonly] +**description** | **str** | | [readonly] +**last_task_status** | [**LastTaskStatusEnum**](LastTaskStatusEnum.md) | | [readonly] + +## Example + +```python +from authentik_client.models.schedule import Schedule + +# TODO update the JSON string below +json = "{}" +# create an instance of Schedule from a JSON string +schedule_instance = Schedule.from_json(json) +# print the JSON string representation of the object +print(Schedule.to_json()) + +# convert the object into a dict +schedule_dict = schedule_instance.to_dict() +# create an instance of Schedule from a dict +schedule_from_dict = Schedule.from_dict(schedule_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ScheduleRequest.md b/docs/ScheduleRequest.md new file mode 100644 index 000000000..fa9b1ce78 --- /dev/null +++ b/docs/ScheduleRequest.md @@ -0,0 +1,31 @@ +# ScheduleRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**rel_obj_id** | **str** | | [optional] +**crontab** | **str** | When to schedule tasks | +**paused** | **bool** | Pause this schedule | [optional] + +## Example + +```python +from authentik_client.models.schedule_request import ScheduleRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ScheduleRequest from a JSON string +schedule_request_instance = ScheduleRequest.from_json(json) +# print the JSON string representation of the object +print(ScheduleRequest.to_json()) + +# convert the object into a dict +schedule_request_dict = schedule_request_instance.to_dict() +# create an instance of ScheduleRequest from a dict +schedule_request_from_dict = ScheduleRequest.from_dict(schedule_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SchemaApi.md b/docs/SchemaApi.md new file mode 100644 index 000000000..8950fc16c --- /dev/null +++ b/docs/SchemaApi.md @@ -0,0 +1,92 @@ +# authentik_client.SchemaApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**schema_retrieve**](SchemaApi.md#schema_retrieve) | **GET** /schema/ | + + +# **schema_retrieve** +> Dict[str, object] schema_retrieve(format=format, lang=lang) + +OpenApi3 schema for this API. Format can be selected via content negotiation. + +- YAML: application/vnd.oai.openapi +- JSON: application/vnd.oai.openapi+json + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.format_enum import FormatEnum +from authentik_client.models.lang_enum import LangEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SchemaApi(api_client) + format = authentik_client.FormatEnum() # FormatEnum | (optional) + lang = authentik_client.LangEnum() # LangEnum | (optional) + + try: + api_response = api_instance.schema_retrieve(format=format, lang=lang) + print("The response of SchemaApi->schema_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SchemaApi->schema_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **format** | [**FormatEnum**](.md)| | [optional] + **lang** | [**LangEnum**](.md)| | [optional] + +### Return type + +**Dict[str, object]** + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.oai.openapi, application/yaml, application/vnd.oai.openapi+json, application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/ScopeMapping.md b/docs/ScopeMapping.md new file mode 100644 index 000000000..0ef9b3dd9 --- /dev/null +++ b/docs/ScopeMapping.md @@ -0,0 +1,39 @@ +# ScopeMapping + +ScopeMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**scope_name** | **str** | Scope name requested by the client | +**description** | **str** | Description shown to the user when consenting. If left empty, the user won't be informed. | [optional] + +## Example + +```python +from authentik_client.models.scope_mapping import ScopeMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of ScopeMapping from a JSON string +scope_mapping_instance = ScopeMapping.from_json(json) +# print the JSON string representation of the object +print(ScopeMapping.to_json()) + +# convert the object into a dict +scope_mapping_dict = scope_mapping_instance.to_dict() +# create an instance of ScopeMapping from a dict +scope_mapping_from_dict = ScopeMapping.from_dict(scope_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ScopeMappingRequest.md b/docs/ScopeMappingRequest.md new file mode 100644 index 000000000..6c2501cee --- /dev/null +++ b/docs/ScopeMappingRequest.md @@ -0,0 +1,34 @@ +# ScopeMappingRequest + +ScopeMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**scope_name** | **str** | Scope name requested by the client | +**description** | **str** | Description shown to the user when consenting. If left empty, the user won't be informed. | [optional] + +## Example + +```python +from authentik_client.models.scope_mapping_request import ScopeMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of ScopeMappingRequest from a JSON string +scope_mapping_request_instance = ScopeMappingRequest.from_json(json) +# print the JSON string representation of the object +print(ScopeMappingRequest.to_json()) + +# convert the object into a dict +scope_mapping_request_dict = scope_mapping_request_instance.to_dict() +# create an instance of ScopeMappingRequest from a dict +scope_mapping_request_from_dict = ScopeMappingRequest.from_dict(scope_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SelectableStage.md b/docs/SelectableStage.md new file mode 100644 index 000000000..d4ad7a9de --- /dev/null +++ b/docs/SelectableStage.md @@ -0,0 +1,33 @@ +# SelectableStage + +Serializer for stages which can be selected by users + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | +**name** | **str** | | +**verbose_name** | **str** | | +**meta_model_name** | **str** | | + +## Example + +```python +from authentik_client.models.selectable_stage import SelectableStage + +# TODO update the JSON string below +json = "{}" +# create an instance of SelectableStage from a JSON string +selectable_stage_instance = SelectableStage.from_json(json) +# print the JSON string representation of the object +print(SelectableStage.to_json()) + +# convert the object into a dict +selectable_stage_dict = selectable_stage_instance.to_dict() +# create an instance of SelectableStage from a dict +selectable_stage_from_dict = SelectableStage.from_dict(selectable_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ServiceConnection.md b/docs/ServiceConnection.md new file mode 100644 index 000000000..9a90de1a8 --- /dev/null +++ b/docs/ServiceConnection.md @@ -0,0 +1,36 @@ +# ServiceConnection + +ServiceConnection Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**local** | **bool** | If enabled, use the local connection. Required Docker socket/Kubernetes Integration | [optional] +**component** | **str** | Return component used to edit this object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.service_connection import ServiceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of ServiceConnection from a JSON string +service_connection_instance = ServiceConnection.from_json(json) +# print the JSON string representation of the object +print(ServiceConnection.to_json()) + +# convert the object into a dict +service_connection_dict = service_connection_instance.to_dict() +# create an instance of ServiceConnection from a dict +service_connection_from_dict = ServiceConnection.from_dict(service_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ServiceConnectionState.md b/docs/ServiceConnectionState.md new file mode 100644 index 000000000..cb9ee2206 --- /dev/null +++ b/docs/ServiceConnectionState.md @@ -0,0 +1,31 @@ +# ServiceConnectionState + +Serializer for Service connection state + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**healthy** | **bool** | | [readonly] +**version** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.service_connection_state import ServiceConnectionState + +# TODO update the JSON string below +json = "{}" +# create an instance of ServiceConnectionState from a JSON string +service_connection_state_instance = ServiceConnectionState.from_json(json) +# print the JSON string representation of the object +print(ServiceConnectionState.to_json()) + +# convert the object into a dict +service_connection_state_dict = service_connection_state_instance.to_dict() +# create an instance of ServiceConnectionState from a dict +service_connection_state_from_dict = ServiceConnectionState.from_dict(service_connection_state_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SessionEndChallenge.md b/docs/SessionEndChallenge.md new file mode 100644 index 000000000..e7370f7c0 --- /dev/null +++ b/docs/SessionEndChallenge.md @@ -0,0 +1,39 @@ +# SessionEndChallenge + +Challenge for ending a session + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-session-end'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | +**application_name** | **str** | | [optional] +**application_launch_url** | **str** | | [optional] +**invalidation_flow_url** | **str** | | [optional] +**overview_url** | **str** | | [optional] +**brand_name** | **str** | | + +## Example + +```python +from authentik_client.models.session_end_challenge import SessionEndChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of SessionEndChallenge from a JSON string +session_end_challenge_instance = SessionEndChallenge.from_json(json) +# print the JSON string representation of the object +print(SessionEndChallenge.to_json()) + +# convert the object into a dict +session_end_challenge_dict = session_end_challenge_instance.to_dict() +# create an instance of SessionEndChallenge from a dict +session_end_challenge_from_dict = SessionEndChallenge.from_dict(session_end_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SessionUser.md b/docs/SessionUser.md new file mode 100644 index 000000000..7e6112733 --- /dev/null +++ b/docs/SessionUser.md @@ -0,0 +1,31 @@ +# SessionUser + +Response for the /user/me endpoint, returns the currently active user (as `user` property) and, if this user is being impersonated, the original user in the `original` property. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user** | [**UserSelf**](UserSelf.md) | | +**original** | [**UserSelf**](UserSelf.md) | | [optional] + +## Example + +```python +from authentik_client.models.session_user import SessionUser + +# TODO update the JSON string below +json = "{}" +# create an instance of SessionUser from a JSON string +session_user_instance = SessionUser.from_json(json) +# print the JSON string representation of the object +print(SessionUser.to_json()) + +# convert the object into a dict +session_user_dict = session_user_instance.to_dict() +# create an instance of SessionUser from a dict +session_user_from_dict = SessionUser.from_dict(session_user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Settings.md b/docs/Settings.md new file mode 100644 index 000000000..54b5d24b0 --- /dev/null +++ b/docs/Settings.md @@ -0,0 +1,45 @@ +# Settings + +Settings Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**avatars** | **str** | Configure how authentik should show avatars for users. | [optional] +**default_user_change_name** | **bool** | Enable the ability for users to change their name. | [optional] +**default_user_change_email** | **bool** | Enable the ability for users to change their email address. | [optional] +**default_user_change_username** | **bool** | Enable the ability for users to change their username. | [optional] +**event_retention** | **str** | Events will be deleted after this duration.(Format: weeks=3;days=2;hours=3,seconds=2). | [optional] +**reputation_lower_limit** | **int** | Reputation cannot decrease lower than this value. Zero or negative. | [optional] +**reputation_upper_limit** | **int** | Reputation cannot increase higher than this value. Zero or positive. | [optional] +**footer_links** | **object** | | [optional] +**gdpr_compliance** | **bool** | When enabled, all the events caused by a user will be deleted upon the user's deletion. | [optional] +**impersonation** | **bool** | Globally enable/disable impersonation. | [optional] +**impersonation_require_reason** | **bool** | Require administrators to provide a reason for impersonating a user. | [optional] +**default_token_duration** | **str** | Default token duration | [optional] +**default_token_length** | **int** | Default token length | [optional] +**pagination_default_page_size** | **int** | Default page size for API responses, if no size was requested. | [optional] +**pagination_max_page_size** | **int** | Maximum page size | [optional] +**flags** | [**PatchedSettingsRequestFlags**](PatchedSettingsRequestFlags.md) | | + +## Example + +```python +from authentik_client.models.settings import Settings + +# TODO update the JSON string below +json = "{}" +# create an instance of Settings from a JSON string +settings_instance = Settings.from_json(json) +# print the JSON string representation of the object +print(Settings.to_json()) + +# convert the object into a dict +settings_dict = settings_instance.to_dict() +# create an instance of Settings from a dict +settings_from_dict = Settings.from_dict(settings_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SettingsRequest.md b/docs/SettingsRequest.md new file mode 100644 index 000000000..65cb38743 --- /dev/null +++ b/docs/SettingsRequest.md @@ -0,0 +1,45 @@ +# SettingsRequest + +Settings Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**avatars** | **str** | Configure how authentik should show avatars for users. | [optional] +**default_user_change_name** | **bool** | Enable the ability for users to change their name. | [optional] +**default_user_change_email** | **bool** | Enable the ability for users to change their email address. | [optional] +**default_user_change_username** | **bool** | Enable the ability for users to change their username. | [optional] +**event_retention** | **str** | Events will be deleted after this duration.(Format: weeks=3;days=2;hours=3,seconds=2). | [optional] +**reputation_lower_limit** | **int** | Reputation cannot decrease lower than this value. Zero or negative. | [optional] +**reputation_upper_limit** | **int** | Reputation cannot increase higher than this value. Zero or positive. | [optional] +**footer_links** | **object** | | [optional] +**gdpr_compliance** | **bool** | When enabled, all the events caused by a user will be deleted upon the user's deletion. | [optional] +**impersonation** | **bool** | Globally enable/disable impersonation. | [optional] +**impersonation_require_reason** | **bool** | Require administrators to provide a reason for impersonating a user. | [optional] +**default_token_duration** | **str** | Default token duration | [optional] +**default_token_length** | **int** | Default token length | [optional] +**pagination_default_page_size** | **int** | Default page size for API responses, if no size was requested. | [optional] +**pagination_max_page_size** | **int** | Maximum page size | [optional] +**flags** | [**PatchedSettingsRequestFlags**](PatchedSettingsRequestFlags.md) | | + +## Example + +```python +from authentik_client.models.settings_request import SettingsRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SettingsRequest from a JSON string +settings_request_instance = SettingsRequest.from_json(json) +# print the JSON string representation of the object +print(SettingsRequest.to_json()) + +# convert the object into a dict +settings_request_dict = settings_request_instance.to_dict() +# create an instance of SettingsRequest from a dict +settings_request_from_dict = SettingsRequest.from_dict(settings_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SeverityEnum.md b/docs/SeverityEnum.md new file mode 100644 index 000000000..8b3ed825c --- /dev/null +++ b/docs/SeverityEnum.md @@ -0,0 +1,14 @@ +# SeverityEnum + + +## Enum + +* `NOTICE` (value: `'notice'`) + +* `WARNING` (value: `'warning'`) + +* `ALERT` (value: `'alert'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ShellChallenge.md b/docs/ShellChallenge.md new file mode 100644 index 000000000..37a9b58c2 --- /dev/null +++ b/docs/ShellChallenge.md @@ -0,0 +1,33 @@ +# ShellChallenge + +challenge type to render HTML as-is + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'xak-flow-shell'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**body** | **str** | | + +## Example + +```python +from authentik_client.models.shell_challenge import ShellChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of ShellChallenge from a JSON string +shell_challenge_instance = ShellChallenge.from_json(json) +# print the JSON string representation of the object +print(ShellChallenge.to_json()) + +# convert the object into a dict +shell_challenge_dict = shell_challenge_instance.to_dict() +# create an instance of ShellChallenge from a dict +shell_challenge_from_dict = ShellChallenge.from_dict(shell_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SignatureAlgorithmEnum.md b/docs/SignatureAlgorithmEnum.md new file mode 100644 index 000000000..028e8693c --- /dev/null +++ b/docs/SignatureAlgorithmEnum.md @@ -0,0 +1,26 @@ +# SignatureAlgorithmEnum + + +## Enum + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2000_SLASH_09_SLASH_XMLDSIG_HASH_RSA_MINUS_SHA1` (value: `'http://www.w3.org/2000/09/xmldsig#rsa-sha1'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_RSA_MINUS_SHA256` (value: `'http://www.w3.org/2001/04/xmldsig-more#rsa-sha256'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_RSA_MINUS_SHA384` (value: `'http://www.w3.org/2001/04/xmldsig-more#rsa-sha384'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_RSA_MINUS_SHA512` (value: `'http://www.w3.org/2001/04/xmldsig-more#rsa-sha512'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_ECDSA_MINUS_SHA1` (value: `'http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha1'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_ECDSA_MINUS_SHA256` (value: `'http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha256'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_ECDSA_MINUS_SHA384` (value: `'http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha384'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2001_SLASH_04_SLASH_XMLDSIG_MINUS_MORE_HASH_ECDSA_MINUS_SHA512` (value: `'http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha512'`) + +* `HTTP_COLON_SLASH_SLASH_WWW_DOT_W3_DOT_ORG_SLASH_2000_SLASH_09_SLASH_XMLDSIG_HASH_DSA_MINUS_SHA1` (value: `'http://www.w3.org/2000/09/xmldsig#dsa-sha1'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Software.md b/docs/Software.md new file mode 100644 index 000000000..32d020d5d --- /dev/null +++ b/docs/Software.md @@ -0,0 +1,32 @@ +# Software + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**version** | **str** | | [optional] +**source** | **str** | | +**path** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.software import Software + +# TODO update the JSON string below +json = "{}" +# create an instance of Software from a JSON string +software_instance = Software.from_json(json) +# print the JSON string representation of the object +print(Software.to_json()) + +# convert the object into a dict +software_dict = software_instance.to_dict() +# create an instance of Software from a dict +software_from_dict = Software.from_dict(software_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SoftwareRequest.md b/docs/SoftwareRequest.md new file mode 100644 index 000000000..4bd2e9db8 --- /dev/null +++ b/docs/SoftwareRequest.md @@ -0,0 +1,32 @@ +# SoftwareRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**version** | **str** | | [optional] +**source** | **str** | | +**path** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.software_request import SoftwareRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SoftwareRequest from a JSON string +software_request_instance = SoftwareRequest.from_json(json) +# print the JSON string representation of the object +print(SoftwareRequest.to_json()) + +# convert the object into a dict +software_request_dict = software_request_instance.to_dict() +# create an instance of SoftwareRequest from a dict +software_request_from_dict = SoftwareRequest.from_dict(software_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Source.md b/docs/Source.md new file mode 100644 index 000000000..606b64a12 --- /dev/null +++ b/docs/Source.md @@ -0,0 +1,49 @@ +# Source + +Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [readonly] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**icon_url** | **str** | Get the URL to the source icon | [readonly] +**icon_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] + +## Example + +```python +from authentik_client.models.source import Source + +# TODO update the JSON string below +json = "{}" +# create an instance of Source from a JSON string +source_instance = Source.from_json(json) +# print the JSON string representation of the object +print(Source.to_json()) + +# convert the object into a dict +source_dict = source_instance.to_dict() +# create an instance of Source from a dict +source_from_dict = Source.from_dict(source_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SourceStage.md b/docs/SourceStage.md new file mode 100644 index 000000000..c6b8dddc5 --- /dev/null +++ b/docs/SourceStage.md @@ -0,0 +1,38 @@ +# SourceStage + +SourceStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**source** | **UUID** | | +**resume_timeout** | **str** | Amount of time a user can take to return from the source to continue the flow (Format: hours=-1;minutes=-2;seconds=-3) | [optional] + +## Example + +```python +from authentik_client.models.source_stage import SourceStage + +# TODO update the JSON string below +json = "{}" +# create an instance of SourceStage from a JSON string +source_stage_instance = SourceStage.from_json(json) +# print the JSON string representation of the object +print(SourceStage.to_json()) + +# convert the object into a dict +source_stage_dict = source_stage_instance.to_dict() +# create an instance of SourceStage from a dict +source_stage_from_dict = SourceStage.from_dict(source_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SourceStageRequest.md b/docs/SourceStageRequest.md new file mode 100644 index 000000000..744163739 --- /dev/null +++ b/docs/SourceStageRequest.md @@ -0,0 +1,32 @@ +# SourceStageRequest + +SourceStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**source** | **UUID** | | +**resume_timeout** | **str** | Amount of time a user can take to return from the source to continue the flow (Format: hours=-1;minutes=-2;seconds=-3) | [optional] + +## Example + +```python +from authentik_client.models.source_stage_request import SourceStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SourceStageRequest from a JSON string +source_stage_request_instance = SourceStageRequest.from_json(json) +# print the JSON string representation of the object +print(SourceStageRequest.to_json()) + +# convert the object into a dict +source_stage_request_dict = source_stage_request_instance.to_dict() +# create an instance of SourceStageRequest from a dict +source_stage_request_from_dict = SourceStageRequest.from_dict(source_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SourceType.md b/docs/SourceType.md new file mode 100644 index 000000000..1c9eb296c --- /dev/null +++ b/docs/SourceType.md @@ -0,0 +1,38 @@ +# SourceType + +Serializer for SourceType + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**verbose_name** | **str** | | +**urls_customizable** | **bool** | | +**request_token_url** | **str** | | [readonly] +**authorization_url** | **str** | | [readonly] +**access_token_url** | **str** | | [readonly] +**profile_url** | **str** | | [readonly] +**oidc_well_known_url** | **str** | | [readonly] +**oidc_jwks_url** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.source_type import SourceType + +# TODO update the JSON string below +json = "{}" +# create an instance of SourceType from a JSON string +source_type_instance = SourceType.from_json(json) +# print the JSON string representation of the object +print(SourceType.to_json()) + +# convert the object into a dict +source_type_dict = source_type_instance.to_dict() +# create an instance of SourceType from a dict +source_type_from_dict = SourceType.from_dict(source_type_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SourcesApi.md b/docs/SourcesApi.md new file mode 100644 index 000000000..754ca519a --- /dev/null +++ b/docs/SourcesApi.md @@ -0,0 +1,14024 @@ +# authentik_client.SourcesApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**sources_all_destroy**](SourcesApi.md#sources_all_destroy) | **DELETE** /sources/all/{slug}/ | +[**sources_all_list**](SourcesApi.md#sources_all_list) | **GET** /sources/all/ | +[**sources_all_retrieve**](SourcesApi.md#sources_all_retrieve) | **GET** /sources/all/{slug}/ | +[**sources_all_types_list**](SourcesApi.md#sources_all_types_list) | **GET** /sources/all/types/ | +[**sources_all_used_by_list**](SourcesApi.md#sources_all_used_by_list) | **GET** /sources/all/{slug}/used_by/ | +[**sources_all_user_settings_list**](SourcesApi.md#sources_all_user_settings_list) | **GET** /sources/all/user_settings/ | +[**sources_group_connections_all_destroy**](SourcesApi.md#sources_group_connections_all_destroy) | **DELETE** /sources/group_connections/all/{id}/ | +[**sources_group_connections_all_list**](SourcesApi.md#sources_group_connections_all_list) | **GET** /sources/group_connections/all/ | +[**sources_group_connections_all_partial_update**](SourcesApi.md#sources_group_connections_all_partial_update) | **PATCH** /sources/group_connections/all/{id}/ | +[**sources_group_connections_all_retrieve**](SourcesApi.md#sources_group_connections_all_retrieve) | **GET** /sources/group_connections/all/{id}/ | +[**sources_group_connections_all_update**](SourcesApi.md#sources_group_connections_all_update) | **PUT** /sources/group_connections/all/{id}/ | +[**sources_group_connections_all_used_by_list**](SourcesApi.md#sources_group_connections_all_used_by_list) | **GET** /sources/group_connections/all/{id}/used_by/ | +[**sources_group_connections_kerberos_create**](SourcesApi.md#sources_group_connections_kerberos_create) | **POST** /sources/group_connections/kerberos/ | +[**sources_group_connections_kerberos_destroy**](SourcesApi.md#sources_group_connections_kerberos_destroy) | **DELETE** /sources/group_connections/kerberos/{id}/ | +[**sources_group_connections_kerberos_list**](SourcesApi.md#sources_group_connections_kerberos_list) | **GET** /sources/group_connections/kerberos/ | +[**sources_group_connections_kerberos_partial_update**](SourcesApi.md#sources_group_connections_kerberos_partial_update) | **PATCH** /sources/group_connections/kerberos/{id}/ | +[**sources_group_connections_kerberos_retrieve**](SourcesApi.md#sources_group_connections_kerberos_retrieve) | **GET** /sources/group_connections/kerberos/{id}/ | +[**sources_group_connections_kerberos_update**](SourcesApi.md#sources_group_connections_kerberos_update) | **PUT** /sources/group_connections/kerberos/{id}/ | +[**sources_group_connections_kerberos_used_by_list**](SourcesApi.md#sources_group_connections_kerberos_used_by_list) | **GET** /sources/group_connections/kerberos/{id}/used_by/ | +[**sources_group_connections_ldap_create**](SourcesApi.md#sources_group_connections_ldap_create) | **POST** /sources/group_connections/ldap/ | +[**sources_group_connections_ldap_destroy**](SourcesApi.md#sources_group_connections_ldap_destroy) | **DELETE** /sources/group_connections/ldap/{id}/ | +[**sources_group_connections_ldap_list**](SourcesApi.md#sources_group_connections_ldap_list) | **GET** /sources/group_connections/ldap/ | +[**sources_group_connections_ldap_partial_update**](SourcesApi.md#sources_group_connections_ldap_partial_update) | **PATCH** /sources/group_connections/ldap/{id}/ | +[**sources_group_connections_ldap_retrieve**](SourcesApi.md#sources_group_connections_ldap_retrieve) | **GET** /sources/group_connections/ldap/{id}/ | +[**sources_group_connections_ldap_update**](SourcesApi.md#sources_group_connections_ldap_update) | **PUT** /sources/group_connections/ldap/{id}/ | +[**sources_group_connections_ldap_used_by_list**](SourcesApi.md#sources_group_connections_ldap_used_by_list) | **GET** /sources/group_connections/ldap/{id}/used_by/ | +[**sources_group_connections_oauth_create**](SourcesApi.md#sources_group_connections_oauth_create) | **POST** /sources/group_connections/oauth/ | +[**sources_group_connections_oauth_destroy**](SourcesApi.md#sources_group_connections_oauth_destroy) | **DELETE** /sources/group_connections/oauth/{id}/ | +[**sources_group_connections_oauth_list**](SourcesApi.md#sources_group_connections_oauth_list) | **GET** /sources/group_connections/oauth/ | +[**sources_group_connections_oauth_partial_update**](SourcesApi.md#sources_group_connections_oauth_partial_update) | **PATCH** /sources/group_connections/oauth/{id}/ | +[**sources_group_connections_oauth_retrieve**](SourcesApi.md#sources_group_connections_oauth_retrieve) | **GET** /sources/group_connections/oauth/{id}/ | +[**sources_group_connections_oauth_update**](SourcesApi.md#sources_group_connections_oauth_update) | **PUT** /sources/group_connections/oauth/{id}/ | +[**sources_group_connections_oauth_used_by_list**](SourcesApi.md#sources_group_connections_oauth_used_by_list) | **GET** /sources/group_connections/oauth/{id}/used_by/ | +[**sources_group_connections_plex_create**](SourcesApi.md#sources_group_connections_plex_create) | **POST** /sources/group_connections/plex/ | +[**sources_group_connections_plex_destroy**](SourcesApi.md#sources_group_connections_plex_destroy) | **DELETE** /sources/group_connections/plex/{id}/ | +[**sources_group_connections_plex_list**](SourcesApi.md#sources_group_connections_plex_list) | **GET** /sources/group_connections/plex/ | +[**sources_group_connections_plex_partial_update**](SourcesApi.md#sources_group_connections_plex_partial_update) | **PATCH** /sources/group_connections/plex/{id}/ | +[**sources_group_connections_plex_retrieve**](SourcesApi.md#sources_group_connections_plex_retrieve) | **GET** /sources/group_connections/plex/{id}/ | +[**sources_group_connections_plex_update**](SourcesApi.md#sources_group_connections_plex_update) | **PUT** /sources/group_connections/plex/{id}/ | +[**sources_group_connections_plex_used_by_list**](SourcesApi.md#sources_group_connections_plex_used_by_list) | **GET** /sources/group_connections/plex/{id}/used_by/ | +[**sources_group_connections_saml_create**](SourcesApi.md#sources_group_connections_saml_create) | **POST** /sources/group_connections/saml/ | +[**sources_group_connections_saml_destroy**](SourcesApi.md#sources_group_connections_saml_destroy) | **DELETE** /sources/group_connections/saml/{id}/ | +[**sources_group_connections_saml_list**](SourcesApi.md#sources_group_connections_saml_list) | **GET** /sources/group_connections/saml/ | +[**sources_group_connections_saml_partial_update**](SourcesApi.md#sources_group_connections_saml_partial_update) | **PATCH** /sources/group_connections/saml/{id}/ | +[**sources_group_connections_saml_retrieve**](SourcesApi.md#sources_group_connections_saml_retrieve) | **GET** /sources/group_connections/saml/{id}/ | +[**sources_group_connections_saml_update**](SourcesApi.md#sources_group_connections_saml_update) | **PUT** /sources/group_connections/saml/{id}/ | +[**sources_group_connections_saml_used_by_list**](SourcesApi.md#sources_group_connections_saml_used_by_list) | **GET** /sources/group_connections/saml/{id}/used_by/ | +[**sources_group_connections_telegram_create**](SourcesApi.md#sources_group_connections_telegram_create) | **POST** /sources/group_connections/telegram/ | +[**sources_group_connections_telegram_destroy**](SourcesApi.md#sources_group_connections_telegram_destroy) | **DELETE** /sources/group_connections/telegram/{id}/ | +[**sources_group_connections_telegram_list**](SourcesApi.md#sources_group_connections_telegram_list) | **GET** /sources/group_connections/telegram/ | +[**sources_group_connections_telegram_partial_update**](SourcesApi.md#sources_group_connections_telegram_partial_update) | **PATCH** /sources/group_connections/telegram/{id}/ | +[**sources_group_connections_telegram_retrieve**](SourcesApi.md#sources_group_connections_telegram_retrieve) | **GET** /sources/group_connections/telegram/{id}/ | +[**sources_group_connections_telegram_update**](SourcesApi.md#sources_group_connections_telegram_update) | **PUT** /sources/group_connections/telegram/{id}/ | +[**sources_group_connections_telegram_used_by_list**](SourcesApi.md#sources_group_connections_telegram_used_by_list) | **GET** /sources/group_connections/telegram/{id}/used_by/ | +[**sources_kerberos_create**](SourcesApi.md#sources_kerberos_create) | **POST** /sources/kerberos/ | +[**sources_kerberos_destroy**](SourcesApi.md#sources_kerberos_destroy) | **DELETE** /sources/kerberos/{slug}/ | +[**sources_kerberos_list**](SourcesApi.md#sources_kerberos_list) | **GET** /sources/kerberos/ | +[**sources_kerberos_partial_update**](SourcesApi.md#sources_kerberos_partial_update) | **PATCH** /sources/kerberos/{slug}/ | +[**sources_kerberos_retrieve**](SourcesApi.md#sources_kerberos_retrieve) | **GET** /sources/kerberos/{slug}/ | +[**sources_kerberos_sync_status_retrieve**](SourcesApi.md#sources_kerberos_sync_status_retrieve) | **GET** /sources/kerberos/{slug}/sync/status/ | +[**sources_kerberos_update**](SourcesApi.md#sources_kerberos_update) | **PUT** /sources/kerberos/{slug}/ | +[**sources_kerberos_used_by_list**](SourcesApi.md#sources_kerberos_used_by_list) | **GET** /sources/kerberos/{slug}/used_by/ | +[**sources_ldap_create**](SourcesApi.md#sources_ldap_create) | **POST** /sources/ldap/ | +[**sources_ldap_debug_retrieve**](SourcesApi.md#sources_ldap_debug_retrieve) | **GET** /sources/ldap/{slug}/debug/ | +[**sources_ldap_destroy**](SourcesApi.md#sources_ldap_destroy) | **DELETE** /sources/ldap/{slug}/ | +[**sources_ldap_list**](SourcesApi.md#sources_ldap_list) | **GET** /sources/ldap/ | +[**sources_ldap_partial_update**](SourcesApi.md#sources_ldap_partial_update) | **PATCH** /sources/ldap/{slug}/ | +[**sources_ldap_retrieve**](SourcesApi.md#sources_ldap_retrieve) | **GET** /sources/ldap/{slug}/ | +[**sources_ldap_sync_status_retrieve**](SourcesApi.md#sources_ldap_sync_status_retrieve) | **GET** /sources/ldap/{slug}/sync/status/ | +[**sources_ldap_update**](SourcesApi.md#sources_ldap_update) | **PUT** /sources/ldap/{slug}/ | +[**sources_ldap_used_by_list**](SourcesApi.md#sources_ldap_used_by_list) | **GET** /sources/ldap/{slug}/used_by/ | +[**sources_oauth_create**](SourcesApi.md#sources_oauth_create) | **POST** /sources/oauth/ | +[**sources_oauth_destroy**](SourcesApi.md#sources_oauth_destroy) | **DELETE** /sources/oauth/{slug}/ | +[**sources_oauth_list**](SourcesApi.md#sources_oauth_list) | **GET** /sources/oauth/ | +[**sources_oauth_partial_update**](SourcesApi.md#sources_oauth_partial_update) | **PATCH** /sources/oauth/{slug}/ | +[**sources_oauth_retrieve**](SourcesApi.md#sources_oauth_retrieve) | **GET** /sources/oauth/{slug}/ | +[**sources_oauth_source_types_list**](SourcesApi.md#sources_oauth_source_types_list) | **GET** /sources/oauth/source_types/ | +[**sources_oauth_update**](SourcesApi.md#sources_oauth_update) | **PUT** /sources/oauth/{slug}/ | +[**sources_oauth_used_by_list**](SourcesApi.md#sources_oauth_used_by_list) | **GET** /sources/oauth/{slug}/used_by/ | +[**sources_plex_create**](SourcesApi.md#sources_plex_create) | **POST** /sources/plex/ | +[**sources_plex_destroy**](SourcesApi.md#sources_plex_destroy) | **DELETE** /sources/plex/{slug}/ | +[**sources_plex_list**](SourcesApi.md#sources_plex_list) | **GET** /sources/plex/ | +[**sources_plex_partial_update**](SourcesApi.md#sources_plex_partial_update) | **PATCH** /sources/plex/{slug}/ | +[**sources_plex_redeem_token_authenticated_create**](SourcesApi.md#sources_plex_redeem_token_authenticated_create) | **POST** /sources/plex/redeem_token_authenticated/ | +[**sources_plex_redeem_token_create**](SourcesApi.md#sources_plex_redeem_token_create) | **POST** /sources/plex/redeem_token/ | +[**sources_plex_retrieve**](SourcesApi.md#sources_plex_retrieve) | **GET** /sources/plex/{slug}/ | +[**sources_plex_update**](SourcesApi.md#sources_plex_update) | **PUT** /sources/plex/{slug}/ | +[**sources_plex_used_by_list**](SourcesApi.md#sources_plex_used_by_list) | **GET** /sources/plex/{slug}/used_by/ | +[**sources_saml_create**](SourcesApi.md#sources_saml_create) | **POST** /sources/saml/ | +[**sources_saml_destroy**](SourcesApi.md#sources_saml_destroy) | **DELETE** /sources/saml/{slug}/ | +[**sources_saml_list**](SourcesApi.md#sources_saml_list) | **GET** /sources/saml/ | +[**sources_saml_metadata_retrieve**](SourcesApi.md#sources_saml_metadata_retrieve) | **GET** /sources/saml/{slug}/metadata/ | +[**sources_saml_partial_update**](SourcesApi.md#sources_saml_partial_update) | **PATCH** /sources/saml/{slug}/ | +[**sources_saml_retrieve**](SourcesApi.md#sources_saml_retrieve) | **GET** /sources/saml/{slug}/ | +[**sources_saml_update**](SourcesApi.md#sources_saml_update) | **PUT** /sources/saml/{slug}/ | +[**sources_saml_used_by_list**](SourcesApi.md#sources_saml_used_by_list) | **GET** /sources/saml/{slug}/used_by/ | +[**sources_scim_create**](SourcesApi.md#sources_scim_create) | **POST** /sources/scim/ | +[**sources_scim_destroy**](SourcesApi.md#sources_scim_destroy) | **DELETE** /sources/scim/{slug}/ | +[**sources_scim_groups_create**](SourcesApi.md#sources_scim_groups_create) | **POST** /sources/scim_groups/ | +[**sources_scim_groups_destroy**](SourcesApi.md#sources_scim_groups_destroy) | **DELETE** /sources/scim_groups/{id}/ | +[**sources_scim_groups_list**](SourcesApi.md#sources_scim_groups_list) | **GET** /sources/scim_groups/ | +[**sources_scim_groups_partial_update**](SourcesApi.md#sources_scim_groups_partial_update) | **PATCH** /sources/scim_groups/{id}/ | +[**sources_scim_groups_retrieve**](SourcesApi.md#sources_scim_groups_retrieve) | **GET** /sources/scim_groups/{id}/ | +[**sources_scim_groups_update**](SourcesApi.md#sources_scim_groups_update) | **PUT** /sources/scim_groups/{id}/ | +[**sources_scim_groups_used_by_list**](SourcesApi.md#sources_scim_groups_used_by_list) | **GET** /sources/scim_groups/{id}/used_by/ | +[**sources_scim_list**](SourcesApi.md#sources_scim_list) | **GET** /sources/scim/ | +[**sources_scim_partial_update**](SourcesApi.md#sources_scim_partial_update) | **PATCH** /sources/scim/{slug}/ | +[**sources_scim_retrieve**](SourcesApi.md#sources_scim_retrieve) | **GET** /sources/scim/{slug}/ | +[**sources_scim_update**](SourcesApi.md#sources_scim_update) | **PUT** /sources/scim/{slug}/ | +[**sources_scim_used_by_list**](SourcesApi.md#sources_scim_used_by_list) | **GET** /sources/scim/{slug}/used_by/ | +[**sources_scim_users_create**](SourcesApi.md#sources_scim_users_create) | **POST** /sources/scim_users/ | +[**sources_scim_users_destroy**](SourcesApi.md#sources_scim_users_destroy) | **DELETE** /sources/scim_users/{id}/ | +[**sources_scim_users_list**](SourcesApi.md#sources_scim_users_list) | **GET** /sources/scim_users/ | +[**sources_scim_users_partial_update**](SourcesApi.md#sources_scim_users_partial_update) | **PATCH** /sources/scim_users/{id}/ | +[**sources_scim_users_retrieve**](SourcesApi.md#sources_scim_users_retrieve) | **GET** /sources/scim_users/{id}/ | +[**sources_scim_users_update**](SourcesApi.md#sources_scim_users_update) | **PUT** /sources/scim_users/{id}/ | +[**sources_scim_users_used_by_list**](SourcesApi.md#sources_scim_users_used_by_list) | **GET** /sources/scim_users/{id}/used_by/ | +[**sources_telegram_connect_user_create**](SourcesApi.md#sources_telegram_connect_user_create) | **POST** /sources/telegram/{slug}/connect_user/ | +[**sources_telegram_create**](SourcesApi.md#sources_telegram_create) | **POST** /sources/telegram/ | +[**sources_telegram_destroy**](SourcesApi.md#sources_telegram_destroy) | **DELETE** /sources/telegram/{slug}/ | +[**sources_telegram_list**](SourcesApi.md#sources_telegram_list) | **GET** /sources/telegram/ | +[**sources_telegram_partial_update**](SourcesApi.md#sources_telegram_partial_update) | **PATCH** /sources/telegram/{slug}/ | +[**sources_telegram_retrieve**](SourcesApi.md#sources_telegram_retrieve) | **GET** /sources/telegram/{slug}/ | +[**sources_telegram_update**](SourcesApi.md#sources_telegram_update) | **PUT** /sources/telegram/{slug}/ | +[**sources_telegram_used_by_list**](SourcesApi.md#sources_telegram_used_by_list) | **GET** /sources/telegram/{slug}/used_by/ | +[**sources_user_connections_all_destroy**](SourcesApi.md#sources_user_connections_all_destroy) | **DELETE** /sources/user_connections/all/{id}/ | +[**sources_user_connections_all_list**](SourcesApi.md#sources_user_connections_all_list) | **GET** /sources/user_connections/all/ | +[**sources_user_connections_all_partial_update**](SourcesApi.md#sources_user_connections_all_partial_update) | **PATCH** /sources/user_connections/all/{id}/ | +[**sources_user_connections_all_retrieve**](SourcesApi.md#sources_user_connections_all_retrieve) | **GET** /sources/user_connections/all/{id}/ | +[**sources_user_connections_all_update**](SourcesApi.md#sources_user_connections_all_update) | **PUT** /sources/user_connections/all/{id}/ | +[**sources_user_connections_all_used_by_list**](SourcesApi.md#sources_user_connections_all_used_by_list) | **GET** /sources/user_connections/all/{id}/used_by/ | +[**sources_user_connections_kerberos_create**](SourcesApi.md#sources_user_connections_kerberos_create) | **POST** /sources/user_connections/kerberos/ | +[**sources_user_connections_kerberos_destroy**](SourcesApi.md#sources_user_connections_kerberos_destroy) | **DELETE** /sources/user_connections/kerberos/{id}/ | +[**sources_user_connections_kerberos_list**](SourcesApi.md#sources_user_connections_kerberos_list) | **GET** /sources/user_connections/kerberos/ | +[**sources_user_connections_kerberos_partial_update**](SourcesApi.md#sources_user_connections_kerberos_partial_update) | **PATCH** /sources/user_connections/kerberos/{id}/ | +[**sources_user_connections_kerberos_retrieve**](SourcesApi.md#sources_user_connections_kerberos_retrieve) | **GET** /sources/user_connections/kerberos/{id}/ | +[**sources_user_connections_kerberos_update**](SourcesApi.md#sources_user_connections_kerberos_update) | **PUT** /sources/user_connections/kerberos/{id}/ | +[**sources_user_connections_kerberos_used_by_list**](SourcesApi.md#sources_user_connections_kerberos_used_by_list) | **GET** /sources/user_connections/kerberos/{id}/used_by/ | +[**sources_user_connections_ldap_create**](SourcesApi.md#sources_user_connections_ldap_create) | **POST** /sources/user_connections/ldap/ | +[**sources_user_connections_ldap_destroy**](SourcesApi.md#sources_user_connections_ldap_destroy) | **DELETE** /sources/user_connections/ldap/{id}/ | +[**sources_user_connections_ldap_list**](SourcesApi.md#sources_user_connections_ldap_list) | **GET** /sources/user_connections/ldap/ | +[**sources_user_connections_ldap_partial_update**](SourcesApi.md#sources_user_connections_ldap_partial_update) | **PATCH** /sources/user_connections/ldap/{id}/ | +[**sources_user_connections_ldap_retrieve**](SourcesApi.md#sources_user_connections_ldap_retrieve) | **GET** /sources/user_connections/ldap/{id}/ | +[**sources_user_connections_ldap_update**](SourcesApi.md#sources_user_connections_ldap_update) | **PUT** /sources/user_connections/ldap/{id}/ | +[**sources_user_connections_ldap_used_by_list**](SourcesApi.md#sources_user_connections_ldap_used_by_list) | **GET** /sources/user_connections/ldap/{id}/used_by/ | +[**sources_user_connections_oauth_create**](SourcesApi.md#sources_user_connections_oauth_create) | **POST** /sources/user_connections/oauth/ | +[**sources_user_connections_oauth_destroy**](SourcesApi.md#sources_user_connections_oauth_destroy) | **DELETE** /sources/user_connections/oauth/{id}/ | +[**sources_user_connections_oauth_list**](SourcesApi.md#sources_user_connections_oauth_list) | **GET** /sources/user_connections/oauth/ | +[**sources_user_connections_oauth_partial_update**](SourcesApi.md#sources_user_connections_oauth_partial_update) | **PATCH** /sources/user_connections/oauth/{id}/ | +[**sources_user_connections_oauth_retrieve**](SourcesApi.md#sources_user_connections_oauth_retrieve) | **GET** /sources/user_connections/oauth/{id}/ | +[**sources_user_connections_oauth_update**](SourcesApi.md#sources_user_connections_oauth_update) | **PUT** /sources/user_connections/oauth/{id}/ | +[**sources_user_connections_oauth_used_by_list**](SourcesApi.md#sources_user_connections_oauth_used_by_list) | **GET** /sources/user_connections/oauth/{id}/used_by/ | +[**sources_user_connections_plex_create**](SourcesApi.md#sources_user_connections_plex_create) | **POST** /sources/user_connections/plex/ | +[**sources_user_connections_plex_destroy**](SourcesApi.md#sources_user_connections_plex_destroy) | **DELETE** /sources/user_connections/plex/{id}/ | +[**sources_user_connections_plex_list**](SourcesApi.md#sources_user_connections_plex_list) | **GET** /sources/user_connections/plex/ | +[**sources_user_connections_plex_partial_update**](SourcesApi.md#sources_user_connections_plex_partial_update) | **PATCH** /sources/user_connections/plex/{id}/ | +[**sources_user_connections_plex_retrieve**](SourcesApi.md#sources_user_connections_plex_retrieve) | **GET** /sources/user_connections/plex/{id}/ | +[**sources_user_connections_plex_update**](SourcesApi.md#sources_user_connections_plex_update) | **PUT** /sources/user_connections/plex/{id}/ | +[**sources_user_connections_plex_used_by_list**](SourcesApi.md#sources_user_connections_plex_used_by_list) | **GET** /sources/user_connections/plex/{id}/used_by/ | +[**sources_user_connections_saml_create**](SourcesApi.md#sources_user_connections_saml_create) | **POST** /sources/user_connections/saml/ | +[**sources_user_connections_saml_destroy**](SourcesApi.md#sources_user_connections_saml_destroy) | **DELETE** /sources/user_connections/saml/{id}/ | +[**sources_user_connections_saml_list**](SourcesApi.md#sources_user_connections_saml_list) | **GET** /sources/user_connections/saml/ | +[**sources_user_connections_saml_partial_update**](SourcesApi.md#sources_user_connections_saml_partial_update) | **PATCH** /sources/user_connections/saml/{id}/ | +[**sources_user_connections_saml_retrieve**](SourcesApi.md#sources_user_connections_saml_retrieve) | **GET** /sources/user_connections/saml/{id}/ | +[**sources_user_connections_saml_update**](SourcesApi.md#sources_user_connections_saml_update) | **PUT** /sources/user_connections/saml/{id}/ | +[**sources_user_connections_saml_used_by_list**](SourcesApi.md#sources_user_connections_saml_used_by_list) | **GET** /sources/user_connections/saml/{id}/used_by/ | +[**sources_user_connections_telegram_create**](SourcesApi.md#sources_user_connections_telegram_create) | **POST** /sources/user_connections/telegram/ | +[**sources_user_connections_telegram_destroy**](SourcesApi.md#sources_user_connections_telegram_destroy) | **DELETE** /sources/user_connections/telegram/{id}/ | +[**sources_user_connections_telegram_list**](SourcesApi.md#sources_user_connections_telegram_list) | **GET** /sources/user_connections/telegram/ | +[**sources_user_connections_telegram_partial_update**](SourcesApi.md#sources_user_connections_telegram_partial_update) | **PATCH** /sources/user_connections/telegram/{id}/ | +[**sources_user_connections_telegram_retrieve**](SourcesApi.md#sources_user_connections_telegram_retrieve) | **GET** /sources/user_connections/telegram/{id}/ | +[**sources_user_connections_telegram_update**](SourcesApi.md#sources_user_connections_telegram_update) | **PUT** /sources/user_connections/telegram/{id}/ | +[**sources_user_connections_telegram_used_by_list**](SourcesApi.md#sources_user_connections_telegram_used_by_list) | **GET** /sources/user_connections/telegram/{id}/used_by/ | + + +# **sources_all_destroy** +> sources_all_destroy(slug) + +Prevent deletion of built-in sources + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.sources_all_destroy(slug) + except Exception as e: + print("Exception when calling SourcesApi->sources_all_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_all_list** +> PaginatedSourceList sources_all_list(managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, search=search, slug=slug) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_source_list import PaginatedSourceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + managed = 'managed_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + slug = 'slug_example' # str | (optional) + + try: + api_response = api_instance.sources_all_list(managed=managed, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, search=search, slug=slug) + print("The response of SourcesApi->sources_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_all_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **managed** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pbm_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + **slug** | **str**| | [optional] + +### Return type + +[**PaginatedSourceList**](PaginatedSourceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_all_retrieve** +> Source sources_all_retrieve(slug) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.source import Source +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_all_retrieve(slug) + print("The response of SourcesApi->sources_all_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_all_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**Source**](Source.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_all_types_list** +> List[TypeCreate] sources_all_types_list() + +Get all creatable types + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.type_create import TypeCreate +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + + try: + api_response = api_instance.sources_all_types_list() + print("The response of SourcesApi->sources_all_types_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_all_types_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[TypeCreate]**](TypeCreate.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_all_used_by_list** +> List[UsedBy] sources_all_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_all_used_by_list(slug) + print("The response of SourcesApi->sources_all_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_all_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_all_user_settings_list** +> List[UserSetting] sources_all_user_settings_list() + +Get all sources the user can configure + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_setting import UserSetting +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + + try: + api_response = api_instance.sources_all_user_settings_list() + print("The response of SourcesApi->sources_all_user_settings_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_all_user_settings_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[UserSetting]**](UserSetting.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_all_destroy** +> sources_group_connections_all_destroy(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this group source connection. + + try: + api_instance.sources_group_connections_all_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_all_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this group source connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_all_list** +> PaginatedGroupSourceConnectionList sources_group_connections_all_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_group_source_connection_list import PaginatedGroupSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + + try: + api_response = api_instance.sources_group_connections_all_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + print("The response of SourcesApi->sources_group_connections_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_all_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + +### Return type + +[**PaginatedGroupSourceConnectionList**](PaginatedGroupSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_all_partial_update** +> GroupSourceConnection sources_group_connections_all_partial_update(id, patched_group_source_connection_request=patched_group_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_source_connection import GroupSourceConnection +from authentik_client.models.patched_group_source_connection_request import PatchedGroupSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this group source connection. + patched_group_source_connection_request = authentik_client.PatchedGroupSourceConnectionRequest() # PatchedGroupSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_group_connections_all_partial_update(id, patched_group_source_connection_request=patched_group_source_connection_request) + print("The response of SourcesApi->sources_group_connections_all_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_all_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this group source connection. | + **patched_group_source_connection_request** | [**PatchedGroupSourceConnectionRequest**](PatchedGroupSourceConnectionRequest.md)| | [optional] + +### Return type + +[**GroupSourceConnection**](GroupSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_all_retrieve** +> GroupSourceConnection sources_group_connections_all_retrieve(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_source_connection import GroupSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this group source connection. + + try: + api_response = api_instance.sources_group_connections_all_retrieve(id) + print("The response of SourcesApi->sources_group_connections_all_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_all_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this group source connection. | + +### Return type + +[**GroupSourceConnection**](GroupSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_all_update** +> GroupSourceConnection sources_group_connections_all_update(id, group_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_source_connection import GroupSourceConnection +from authentik_client.models.group_source_connection_request import GroupSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this group source connection. + group_source_connection_request = authentik_client.GroupSourceConnectionRequest() # GroupSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_all_update(id, group_source_connection_request) + print("The response of SourcesApi->sources_group_connections_all_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_all_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this group source connection. | + **group_source_connection_request** | [**GroupSourceConnectionRequest**](GroupSourceConnectionRequest.md)| | + +### Return type + +[**GroupSourceConnection**](GroupSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_all_used_by_list** +> List[UsedBy] sources_group_connections_all_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this group source connection. + + try: + api_response = api_instance.sources_group_connections_all_used_by_list(id) + print("The response of SourcesApi->sources_group_connections_all_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_all_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this group source connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_kerberos_create** +> GroupKerberosSourceConnection sources_group_connections_kerberos_create(group_kerberos_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection +from authentik_client.models.group_kerberos_source_connection_request import GroupKerberosSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group_kerberos_source_connection_request = authentik_client.GroupKerberosSourceConnectionRequest() # GroupKerberosSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_kerberos_create(group_kerberos_source_connection_request) + print("The response of SourcesApi->sources_group_connections_kerberos_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_kerberos_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_kerberos_source_connection_request** | [**GroupKerberosSourceConnectionRequest**](GroupKerberosSourceConnectionRequest.md)| | + +### Return type + +[**GroupKerberosSourceConnection**](GroupKerberosSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_kerberos_destroy** +> sources_group_connections_kerberos_destroy(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Kerberos Source Connection. + + try: + api_instance.sources_group_connections_kerberos_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_kerberos_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Kerberos Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_kerberos_list** +> PaginatedGroupKerberosSourceConnectionList sources_group_connections_kerberos_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_group_kerberos_source_connection_list import PaginatedGroupKerberosSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + + try: + api_response = api_instance.sources_group_connections_kerberos_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + print("The response of SourcesApi->sources_group_connections_kerberos_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_kerberos_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + +### Return type + +[**PaginatedGroupKerberosSourceConnectionList**](PaginatedGroupKerberosSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_kerberos_partial_update** +> GroupKerberosSourceConnection sources_group_connections_kerberos_partial_update(id, patched_group_kerberos_source_connection_request=patched_group_kerberos_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection +from authentik_client.models.patched_group_kerberos_source_connection_request import PatchedGroupKerberosSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Kerberos Source Connection. + patched_group_kerberos_source_connection_request = authentik_client.PatchedGroupKerberosSourceConnectionRequest() # PatchedGroupKerberosSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_group_connections_kerberos_partial_update(id, patched_group_kerberos_source_connection_request=patched_group_kerberos_source_connection_request) + print("The response of SourcesApi->sources_group_connections_kerberos_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_kerberos_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Kerberos Source Connection. | + **patched_group_kerberos_source_connection_request** | [**PatchedGroupKerberosSourceConnectionRequest**](PatchedGroupKerberosSourceConnectionRequest.md)| | [optional] + +### Return type + +[**GroupKerberosSourceConnection**](GroupKerberosSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_kerberos_retrieve** +> GroupKerberosSourceConnection sources_group_connections_kerberos_retrieve(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Kerberos Source Connection. + + try: + api_response = api_instance.sources_group_connections_kerberos_retrieve(id) + print("The response of SourcesApi->sources_group_connections_kerberos_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_kerberos_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Kerberos Source Connection. | + +### Return type + +[**GroupKerberosSourceConnection**](GroupKerberosSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_kerberos_update** +> GroupKerberosSourceConnection sources_group_connections_kerberos_update(id, group_kerberos_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection +from authentik_client.models.group_kerberos_source_connection_request import GroupKerberosSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Kerberos Source Connection. + group_kerberos_source_connection_request = authentik_client.GroupKerberosSourceConnectionRequest() # GroupKerberosSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_kerberos_update(id, group_kerberos_source_connection_request) + print("The response of SourcesApi->sources_group_connections_kerberos_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_kerberos_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Kerberos Source Connection. | + **group_kerberos_source_connection_request** | [**GroupKerberosSourceConnectionRequest**](GroupKerberosSourceConnectionRequest.md)| | + +### Return type + +[**GroupKerberosSourceConnection**](GroupKerberosSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_kerberos_used_by_list** +> List[UsedBy] sources_group_connections_kerberos_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Kerberos Source Connection. + + try: + api_response = api_instance.sources_group_connections_kerberos_used_by_list(id) + print("The response of SourcesApi->sources_group_connections_kerberos_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_kerberos_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Kerberos Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_ldap_create** +> GroupLDAPSourceConnection sources_group_connections_ldap_create(group_ldap_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection +from authentik_client.models.group_ldap_source_connection_request import GroupLDAPSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group_ldap_source_connection_request = authentik_client.GroupLDAPSourceConnectionRequest() # GroupLDAPSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_ldap_create(group_ldap_source_connection_request) + print("The response of SourcesApi->sources_group_connections_ldap_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_ldap_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_ldap_source_connection_request** | [**GroupLDAPSourceConnectionRequest**](GroupLDAPSourceConnectionRequest.md)| | + +### Return type + +[**GroupLDAPSourceConnection**](GroupLDAPSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_ldap_destroy** +> sources_group_connections_ldap_destroy(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group LDAP Source Connection. + + try: + api_instance.sources_group_connections_ldap_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_ldap_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group LDAP Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_ldap_list** +> PaginatedGroupLDAPSourceConnectionList sources_group_connections_ldap_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_group_ldap_source_connection_list import PaginatedGroupLDAPSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + + try: + api_response = api_instance.sources_group_connections_ldap_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + print("The response of SourcesApi->sources_group_connections_ldap_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_ldap_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + +### Return type + +[**PaginatedGroupLDAPSourceConnectionList**](PaginatedGroupLDAPSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_ldap_partial_update** +> GroupLDAPSourceConnection sources_group_connections_ldap_partial_update(id, patched_group_ldap_source_connection_request=patched_group_ldap_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection +from authentik_client.models.patched_group_ldap_source_connection_request import PatchedGroupLDAPSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group LDAP Source Connection. + patched_group_ldap_source_connection_request = authentik_client.PatchedGroupLDAPSourceConnectionRequest() # PatchedGroupLDAPSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_group_connections_ldap_partial_update(id, patched_group_ldap_source_connection_request=patched_group_ldap_source_connection_request) + print("The response of SourcesApi->sources_group_connections_ldap_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_ldap_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group LDAP Source Connection. | + **patched_group_ldap_source_connection_request** | [**PatchedGroupLDAPSourceConnectionRequest**](PatchedGroupLDAPSourceConnectionRequest.md)| | [optional] + +### Return type + +[**GroupLDAPSourceConnection**](GroupLDAPSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_ldap_retrieve** +> GroupLDAPSourceConnection sources_group_connections_ldap_retrieve(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group LDAP Source Connection. + + try: + api_response = api_instance.sources_group_connections_ldap_retrieve(id) + print("The response of SourcesApi->sources_group_connections_ldap_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_ldap_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group LDAP Source Connection. | + +### Return type + +[**GroupLDAPSourceConnection**](GroupLDAPSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_ldap_update** +> GroupLDAPSourceConnection sources_group_connections_ldap_update(id, group_ldap_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection +from authentik_client.models.group_ldap_source_connection_request import GroupLDAPSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group LDAP Source Connection. + group_ldap_source_connection_request = authentik_client.GroupLDAPSourceConnectionRequest() # GroupLDAPSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_ldap_update(id, group_ldap_source_connection_request) + print("The response of SourcesApi->sources_group_connections_ldap_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_ldap_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group LDAP Source Connection. | + **group_ldap_source_connection_request** | [**GroupLDAPSourceConnectionRequest**](GroupLDAPSourceConnectionRequest.md)| | + +### Return type + +[**GroupLDAPSourceConnection**](GroupLDAPSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_ldap_used_by_list** +> List[UsedBy] sources_group_connections_ldap_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group LDAP Source Connection. + + try: + api_response = api_instance.sources_group_connections_ldap_used_by_list(id) + print("The response of SourcesApi->sources_group_connections_ldap_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_ldap_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group LDAP Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_oauth_create** +> GroupOAuthSourceConnection sources_group_connections_oauth_create(group_o_auth_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection +from authentik_client.models.group_o_auth_source_connection_request import GroupOAuthSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group_o_auth_source_connection_request = authentik_client.GroupOAuthSourceConnectionRequest() # GroupOAuthSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_oauth_create(group_o_auth_source_connection_request) + print("The response of SourcesApi->sources_group_connections_oauth_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_oauth_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_o_auth_source_connection_request** | [**GroupOAuthSourceConnectionRequest**](GroupOAuthSourceConnectionRequest.md)| | + +### Return type + +[**GroupOAuthSourceConnection**](GroupOAuthSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_oauth_destroy** +> sources_group_connections_oauth_destroy(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group OAuth Source Connection. + + try: + api_instance.sources_group_connections_oauth_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_oauth_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group OAuth Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_oauth_list** +> PaginatedGroupOAuthSourceConnectionList sources_group_connections_oauth_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_group_o_auth_source_connection_list import PaginatedGroupOAuthSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + + try: + api_response = api_instance.sources_group_connections_oauth_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + print("The response of SourcesApi->sources_group_connections_oauth_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_oauth_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + +### Return type + +[**PaginatedGroupOAuthSourceConnectionList**](PaginatedGroupOAuthSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_oauth_partial_update** +> GroupOAuthSourceConnection sources_group_connections_oauth_partial_update(id, patched_group_o_auth_source_connection_request=patched_group_o_auth_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection +from authentik_client.models.patched_group_o_auth_source_connection_request import PatchedGroupOAuthSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group OAuth Source Connection. + patched_group_o_auth_source_connection_request = authentik_client.PatchedGroupOAuthSourceConnectionRequest() # PatchedGroupOAuthSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_group_connections_oauth_partial_update(id, patched_group_o_auth_source_connection_request=patched_group_o_auth_source_connection_request) + print("The response of SourcesApi->sources_group_connections_oauth_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_oauth_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group OAuth Source Connection. | + **patched_group_o_auth_source_connection_request** | [**PatchedGroupOAuthSourceConnectionRequest**](PatchedGroupOAuthSourceConnectionRequest.md)| | [optional] + +### Return type + +[**GroupOAuthSourceConnection**](GroupOAuthSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_oauth_retrieve** +> GroupOAuthSourceConnection sources_group_connections_oauth_retrieve(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group OAuth Source Connection. + + try: + api_response = api_instance.sources_group_connections_oauth_retrieve(id) + print("The response of SourcesApi->sources_group_connections_oauth_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_oauth_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group OAuth Source Connection. | + +### Return type + +[**GroupOAuthSourceConnection**](GroupOAuthSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_oauth_update** +> GroupOAuthSourceConnection sources_group_connections_oauth_update(id, group_o_auth_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection +from authentik_client.models.group_o_auth_source_connection_request import GroupOAuthSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group OAuth Source Connection. + group_o_auth_source_connection_request = authentik_client.GroupOAuthSourceConnectionRequest() # GroupOAuthSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_oauth_update(id, group_o_auth_source_connection_request) + print("The response of SourcesApi->sources_group_connections_oauth_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_oauth_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group OAuth Source Connection. | + **group_o_auth_source_connection_request** | [**GroupOAuthSourceConnectionRequest**](GroupOAuthSourceConnectionRequest.md)| | + +### Return type + +[**GroupOAuthSourceConnection**](GroupOAuthSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_oauth_used_by_list** +> List[UsedBy] sources_group_connections_oauth_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group OAuth Source Connection. + + try: + api_response = api_instance.sources_group_connections_oauth_used_by_list(id) + print("The response of SourcesApi->sources_group_connections_oauth_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_oauth_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group OAuth Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_plex_create** +> GroupPlexSourceConnection sources_group_connections_plex_create(group_plex_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection +from authentik_client.models.group_plex_source_connection_request import GroupPlexSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group_plex_source_connection_request = authentik_client.GroupPlexSourceConnectionRequest() # GroupPlexSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_plex_create(group_plex_source_connection_request) + print("The response of SourcesApi->sources_group_connections_plex_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_plex_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_plex_source_connection_request** | [**GroupPlexSourceConnectionRequest**](GroupPlexSourceConnectionRequest.md)| | + +### Return type + +[**GroupPlexSourceConnection**](GroupPlexSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_plex_destroy** +> sources_group_connections_plex_destroy(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Plex Source Connection. + + try: + api_instance.sources_group_connections_plex_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_plex_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Plex Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_plex_list** +> PaginatedGroupPlexSourceConnectionList sources_group_connections_plex_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_group_plex_source_connection_list import PaginatedGroupPlexSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + + try: + api_response = api_instance.sources_group_connections_plex_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + print("The response of SourcesApi->sources_group_connections_plex_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_plex_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + +### Return type + +[**PaginatedGroupPlexSourceConnectionList**](PaginatedGroupPlexSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_plex_partial_update** +> GroupPlexSourceConnection sources_group_connections_plex_partial_update(id, patched_group_plex_source_connection_request=patched_group_plex_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection +from authentik_client.models.patched_group_plex_source_connection_request import PatchedGroupPlexSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Plex Source Connection. + patched_group_plex_source_connection_request = authentik_client.PatchedGroupPlexSourceConnectionRequest() # PatchedGroupPlexSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_group_connections_plex_partial_update(id, patched_group_plex_source_connection_request=patched_group_plex_source_connection_request) + print("The response of SourcesApi->sources_group_connections_plex_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_plex_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Plex Source Connection. | + **patched_group_plex_source_connection_request** | [**PatchedGroupPlexSourceConnectionRequest**](PatchedGroupPlexSourceConnectionRequest.md)| | [optional] + +### Return type + +[**GroupPlexSourceConnection**](GroupPlexSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_plex_retrieve** +> GroupPlexSourceConnection sources_group_connections_plex_retrieve(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Plex Source Connection. + + try: + api_response = api_instance.sources_group_connections_plex_retrieve(id) + print("The response of SourcesApi->sources_group_connections_plex_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_plex_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Plex Source Connection. | + +### Return type + +[**GroupPlexSourceConnection**](GroupPlexSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_plex_update** +> GroupPlexSourceConnection sources_group_connections_plex_update(id, group_plex_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection +from authentik_client.models.group_plex_source_connection_request import GroupPlexSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Plex Source Connection. + group_plex_source_connection_request = authentik_client.GroupPlexSourceConnectionRequest() # GroupPlexSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_plex_update(id, group_plex_source_connection_request) + print("The response of SourcesApi->sources_group_connections_plex_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_plex_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Plex Source Connection. | + **group_plex_source_connection_request** | [**GroupPlexSourceConnectionRequest**](GroupPlexSourceConnectionRequest.md)| | + +### Return type + +[**GroupPlexSourceConnection**](GroupPlexSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_plex_used_by_list** +> List[UsedBy] sources_group_connections_plex_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Plex Source Connection. + + try: + api_response = api_instance.sources_group_connections_plex_used_by_list(id) + print("The response of SourcesApi->sources_group_connections_plex_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_plex_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Plex Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_saml_create** +> GroupSAMLSourceConnection sources_group_connections_saml_create(group_saml_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection +from authentik_client.models.group_saml_source_connection_request import GroupSAMLSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group_saml_source_connection_request = authentik_client.GroupSAMLSourceConnectionRequest() # GroupSAMLSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_saml_create(group_saml_source_connection_request) + print("The response of SourcesApi->sources_group_connections_saml_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_saml_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_saml_source_connection_request** | [**GroupSAMLSourceConnectionRequest**](GroupSAMLSourceConnectionRequest.md)| | + +### Return type + +[**GroupSAMLSourceConnection**](GroupSAMLSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_saml_destroy** +> sources_group_connections_saml_destroy(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group SAML Source Connection. + + try: + api_instance.sources_group_connections_saml_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_saml_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group SAML Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_saml_list** +> PaginatedGroupSAMLSourceConnectionList sources_group_connections_saml_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_group_saml_source_connection_list import PaginatedGroupSAMLSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + + try: + api_response = api_instance.sources_group_connections_saml_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + print("The response of SourcesApi->sources_group_connections_saml_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_saml_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + +### Return type + +[**PaginatedGroupSAMLSourceConnectionList**](PaginatedGroupSAMLSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_saml_partial_update** +> GroupSAMLSourceConnection sources_group_connections_saml_partial_update(id, patched_group_saml_source_connection_request=patched_group_saml_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection +from authentik_client.models.patched_group_saml_source_connection_request import PatchedGroupSAMLSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group SAML Source Connection. + patched_group_saml_source_connection_request = authentik_client.PatchedGroupSAMLSourceConnectionRequest() # PatchedGroupSAMLSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_group_connections_saml_partial_update(id, patched_group_saml_source_connection_request=patched_group_saml_source_connection_request) + print("The response of SourcesApi->sources_group_connections_saml_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_saml_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group SAML Source Connection. | + **patched_group_saml_source_connection_request** | [**PatchedGroupSAMLSourceConnectionRequest**](PatchedGroupSAMLSourceConnectionRequest.md)| | [optional] + +### Return type + +[**GroupSAMLSourceConnection**](GroupSAMLSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_saml_retrieve** +> GroupSAMLSourceConnection sources_group_connections_saml_retrieve(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group SAML Source Connection. + + try: + api_response = api_instance.sources_group_connections_saml_retrieve(id) + print("The response of SourcesApi->sources_group_connections_saml_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_saml_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group SAML Source Connection. | + +### Return type + +[**GroupSAMLSourceConnection**](GroupSAMLSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_saml_update** +> GroupSAMLSourceConnection sources_group_connections_saml_update(id, group_saml_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection +from authentik_client.models.group_saml_source_connection_request import GroupSAMLSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group SAML Source Connection. + group_saml_source_connection_request = authentik_client.GroupSAMLSourceConnectionRequest() # GroupSAMLSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_saml_update(id, group_saml_source_connection_request) + print("The response of SourcesApi->sources_group_connections_saml_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_saml_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group SAML Source Connection. | + **group_saml_source_connection_request** | [**GroupSAMLSourceConnectionRequest**](GroupSAMLSourceConnectionRequest.md)| | + +### Return type + +[**GroupSAMLSourceConnection**](GroupSAMLSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_saml_used_by_list** +> List[UsedBy] sources_group_connections_saml_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group SAML Source Connection. + + try: + api_response = api_instance.sources_group_connections_saml_used_by_list(id) + print("The response of SourcesApi->sources_group_connections_saml_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_saml_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group SAML Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_telegram_create** +> GroupTelegramSourceConnection sources_group_connections_telegram_create(group_telegram_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection +from authentik_client.models.group_telegram_source_connection_request import GroupTelegramSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group_telegram_source_connection_request = authentik_client.GroupTelegramSourceConnectionRequest() # GroupTelegramSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_telegram_create(group_telegram_source_connection_request) + print("The response of SourcesApi->sources_group_connections_telegram_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_telegram_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group_telegram_source_connection_request** | [**GroupTelegramSourceConnectionRequest**](GroupTelegramSourceConnectionRequest.md)| | + +### Return type + +[**GroupTelegramSourceConnection**](GroupTelegramSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_telegram_destroy** +> sources_group_connections_telegram_destroy(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Telegram Source Connection. + + try: + api_instance.sources_group_connections_telegram_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_telegram_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Telegram Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_telegram_list** +> PaginatedGroupTelegramSourceConnectionList sources_group_connections_telegram_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_group_telegram_source_connection_list import PaginatedGroupTelegramSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + + try: + api_response = api_instance.sources_group_connections_telegram_list(group=group, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + print("The response of SourcesApi->sources_group_connections_telegram_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_telegram_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group** | **UUID**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + +### Return type + +[**PaginatedGroupTelegramSourceConnectionList**](PaginatedGroupTelegramSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_telegram_partial_update** +> GroupTelegramSourceConnection sources_group_connections_telegram_partial_update(id, patched_group_telegram_source_connection_request=patched_group_telegram_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection +from authentik_client.models.patched_group_telegram_source_connection_request import PatchedGroupTelegramSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Telegram Source Connection. + patched_group_telegram_source_connection_request = authentik_client.PatchedGroupTelegramSourceConnectionRequest() # PatchedGroupTelegramSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_group_connections_telegram_partial_update(id, patched_group_telegram_source_connection_request=patched_group_telegram_source_connection_request) + print("The response of SourcesApi->sources_group_connections_telegram_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_telegram_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Telegram Source Connection. | + **patched_group_telegram_source_connection_request** | [**PatchedGroupTelegramSourceConnectionRequest**](PatchedGroupTelegramSourceConnectionRequest.md)| | [optional] + +### Return type + +[**GroupTelegramSourceConnection**](GroupTelegramSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_telegram_retrieve** +> GroupTelegramSourceConnection sources_group_connections_telegram_retrieve(id) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Telegram Source Connection. + + try: + api_response = api_instance.sources_group_connections_telegram_retrieve(id) + print("The response of SourcesApi->sources_group_connections_telegram_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_telegram_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Telegram Source Connection. | + +### Return type + +[**GroupTelegramSourceConnection**](GroupTelegramSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_telegram_update** +> GroupTelegramSourceConnection sources_group_connections_telegram_update(id, group_telegram_source_connection_request) + +Group-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection +from authentik_client.models.group_telegram_source_connection_request import GroupTelegramSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Telegram Source Connection. + group_telegram_source_connection_request = authentik_client.GroupTelegramSourceConnectionRequest() # GroupTelegramSourceConnectionRequest | + + try: + api_response = api_instance.sources_group_connections_telegram_update(id, group_telegram_source_connection_request) + print("The response of SourcesApi->sources_group_connections_telegram_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_telegram_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Telegram Source Connection. | + **group_telegram_source_connection_request** | [**GroupTelegramSourceConnectionRequest**](GroupTelegramSourceConnectionRequest.md)| | + +### Return type + +[**GroupTelegramSourceConnection**](GroupTelegramSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_group_connections_telegram_used_by_list** +> List[UsedBy] sources_group_connections_telegram_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this Group Telegram Source Connection. + + try: + api_response = api_instance.sources_group_connections_telegram_used_by_list(id) + print("The response of SourcesApi->sources_group_connections_telegram_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_group_connections_telegram_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Group Telegram Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_kerberos_create** +> KerberosSource sources_kerberos_create(kerberos_source_request) + +Kerberos Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kerberos_source import KerberosSource +from authentik_client.models.kerberos_source_request import KerberosSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + kerberos_source_request = authentik_client.KerberosSourceRequest() # KerberosSourceRequest | + + try: + api_response = api_instance.sources_kerberos_create(kerberos_source_request) + print("The response of SourcesApi->sources_kerberos_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_kerberos_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **kerberos_source_request** | [**KerberosSourceRequest**](KerberosSourceRequest.md)| | + +### Return type + +[**KerberosSource**](KerberosSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_kerberos_destroy** +> sources_kerberos_destroy(slug) + +Kerberos Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.sources_kerberos_destroy(slug) + except Exception as e: + print("Exception when calling SourcesApi->sources_kerberos_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_kerberos_list** +> PaginatedKerberosSourceList sources_kerberos_list(enabled=enabled, kadmin_type=kadmin_type, name=name, ordering=ordering, page=page, page_size=page_size, password_login_update_internal_password=password_login_update_internal_password, pbm_uuid=pbm_uuid, realm=realm, search=search, slug=slug, spnego_server_name=spnego_server_name, sync_principal=sync_principal, sync_users=sync_users, sync_users_password=sync_users_password) + +Kerberos Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_kerberos_source_list import PaginatedKerberosSourceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + enabled = True # bool | (optional) + kadmin_type = authentik_client.KadminTypeEnum() # KadminTypeEnum | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + password_login_update_internal_password = True # bool | (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + realm = 'realm_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + slug = 'slug_example' # str | (optional) + spnego_server_name = 'spnego_server_name_example' # str | (optional) + sync_principal = 'sync_principal_example' # str | (optional) + sync_users = True # bool | (optional) + sync_users_password = True # bool | (optional) + + try: + api_response = api_instance.sources_kerberos_list(enabled=enabled, kadmin_type=kadmin_type, name=name, ordering=ordering, page=page, page_size=page_size, password_login_update_internal_password=password_login_update_internal_password, pbm_uuid=pbm_uuid, realm=realm, search=search, slug=slug, spnego_server_name=spnego_server_name, sync_principal=sync_principal, sync_users=sync_users, sync_users_password=sync_users_password) + print("The response of SourcesApi->sources_kerberos_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_kerberos_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **enabled** | **bool**| | [optional] + **kadmin_type** | [**KadminTypeEnum**](.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **password_login_update_internal_password** | **bool**| | [optional] + **pbm_uuid** | **UUID**| | [optional] + **realm** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + **slug** | **str**| | [optional] + **spnego_server_name** | **str**| | [optional] + **sync_principal** | **str**| | [optional] + **sync_users** | **bool**| | [optional] + **sync_users_password** | **bool**| | [optional] + +### Return type + +[**PaginatedKerberosSourceList**](PaginatedKerberosSourceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_kerberos_partial_update** +> KerberosSource sources_kerberos_partial_update(slug, patched_kerberos_source_request=patched_kerberos_source_request) + +Kerberos Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kerberos_source import KerberosSource +from authentik_client.models.patched_kerberos_source_request import PatchedKerberosSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + patched_kerberos_source_request = authentik_client.PatchedKerberosSourceRequest() # PatchedKerberosSourceRequest | (optional) + + try: + api_response = api_instance.sources_kerberos_partial_update(slug, patched_kerberos_source_request=patched_kerberos_source_request) + print("The response of SourcesApi->sources_kerberos_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_kerberos_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **patched_kerberos_source_request** | [**PatchedKerberosSourceRequest**](PatchedKerberosSourceRequest.md)| | [optional] + +### Return type + +[**KerberosSource**](KerberosSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_kerberos_retrieve** +> KerberosSource sources_kerberos_retrieve(slug) + +Kerberos Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kerberos_source import KerberosSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_kerberos_retrieve(slug) + print("The response of SourcesApi->sources_kerberos_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_kerberos_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**KerberosSource**](KerberosSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_kerberos_sync_status_retrieve** +> SyncStatus sources_kerberos_sync_status_retrieve(slug) + +Get provider's sync status + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sync_status import SyncStatus +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_kerberos_sync_status_retrieve(slug) + print("The response of SourcesApi->sources_kerberos_sync_status_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_kerberos_sync_status_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**SyncStatus**](SyncStatus.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_kerberos_update** +> KerberosSource sources_kerberos_update(slug, kerberos_source_request) + +Kerberos Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.kerberos_source import KerberosSource +from authentik_client.models.kerberos_source_request import KerberosSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + kerberos_source_request = authentik_client.KerberosSourceRequest() # KerberosSourceRequest | + + try: + api_response = api_instance.sources_kerberos_update(slug, kerberos_source_request) + print("The response of SourcesApi->sources_kerberos_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_kerberos_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **kerberos_source_request** | [**KerberosSourceRequest**](KerberosSourceRequest.md)| | + +### Return type + +[**KerberosSource**](KerberosSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_kerberos_used_by_list** +> List[UsedBy] sources_kerberos_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_kerberos_used_by_list(slug) + print("The response of SourcesApi->sources_kerberos_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_kerberos_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_ldap_create** +> LDAPSource sources_ldap_create(ldap_source_request) + +LDAP Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_source import LDAPSource +from authentik_client.models.ldap_source_request import LDAPSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + ldap_source_request = authentik_client.LDAPSourceRequest() # LDAPSourceRequest | + + try: + api_response = api_instance.sources_ldap_create(ldap_source_request) + print("The response of SourcesApi->sources_ldap_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_ldap_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ldap_source_request** | [**LDAPSourceRequest**](LDAPSourceRequest.md)| | + +### Return type + +[**LDAPSource**](LDAPSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_ldap_debug_retrieve** +> LDAPDebug sources_ldap_debug_retrieve(slug) + +Get raw LDAP data to debug + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_debug import LDAPDebug +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_ldap_debug_retrieve(slug) + print("The response of SourcesApi->sources_ldap_debug_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_ldap_debug_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**LDAPDebug**](LDAPDebug.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_ldap_destroy** +> sources_ldap_destroy(slug) + +LDAP Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.sources_ldap_destroy(slug) + except Exception as e: + print("Exception when calling SourcesApi->sources_ldap_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_ldap_list** +> PaginatedLDAPSourceList sources_ldap_list(additional_group_dn=additional_group_dn, additional_user_dn=additional_user_dn, base_dn=base_dn, bind_cn=bind_cn, client_certificate=client_certificate, delete_not_found_objects=delete_not_found_objects, enabled=enabled, group_membership_field=group_membership_field, group_object_filter=group_object_filter, group_property_mappings=group_property_mappings, lookup_groups_from_user=lookup_groups_from_user, name=name, object_uniqueness_field=object_uniqueness_field, ordering=ordering, page=page, page_size=page_size, password_login_update_internal_password=password_login_update_internal_password, pbm_uuid=pbm_uuid, peer_certificate=peer_certificate, search=search, server_uri=server_uri, slug=slug, sni=sni, start_tls=start_tls, sync_groups=sync_groups, sync_parent_group=sync_parent_group, sync_users=sync_users, sync_users_password=sync_users_password, user_membership_attribute=user_membership_attribute, user_object_filter=user_object_filter, user_property_mappings=user_property_mappings) + +LDAP Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_ldap_source_list import PaginatedLDAPSourceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + additional_group_dn = 'additional_group_dn_example' # str | (optional) + additional_user_dn = 'additional_user_dn_example' # str | (optional) + base_dn = 'base_dn_example' # str | (optional) + bind_cn = 'bind_cn_example' # str | (optional) + client_certificate = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + delete_not_found_objects = True # bool | (optional) + enabled = True # bool | (optional) + group_membership_field = 'group_membership_field_example' # str | (optional) + group_object_filter = 'group_object_filter_example' # str | (optional) + group_property_mappings = None # List[UUID] | (optional) + lookup_groups_from_user = True # bool | (optional) + name = 'name_example' # str | (optional) + object_uniqueness_field = 'object_uniqueness_field_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + password_login_update_internal_password = True # bool | (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + peer_certificate = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + server_uri = 'server_uri_example' # str | (optional) + slug = 'slug_example' # str | (optional) + sni = True # bool | (optional) + start_tls = True # bool | (optional) + sync_groups = True # bool | (optional) + sync_parent_group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + sync_users = True # bool | (optional) + sync_users_password = True # bool | (optional) + user_membership_attribute = 'user_membership_attribute_example' # str | (optional) + user_object_filter = 'user_object_filter_example' # str | (optional) + user_property_mappings = None # List[UUID] | (optional) + + try: + api_response = api_instance.sources_ldap_list(additional_group_dn=additional_group_dn, additional_user_dn=additional_user_dn, base_dn=base_dn, bind_cn=bind_cn, client_certificate=client_certificate, delete_not_found_objects=delete_not_found_objects, enabled=enabled, group_membership_field=group_membership_field, group_object_filter=group_object_filter, group_property_mappings=group_property_mappings, lookup_groups_from_user=lookup_groups_from_user, name=name, object_uniqueness_field=object_uniqueness_field, ordering=ordering, page=page, page_size=page_size, password_login_update_internal_password=password_login_update_internal_password, pbm_uuid=pbm_uuid, peer_certificate=peer_certificate, search=search, server_uri=server_uri, slug=slug, sni=sni, start_tls=start_tls, sync_groups=sync_groups, sync_parent_group=sync_parent_group, sync_users=sync_users, sync_users_password=sync_users_password, user_membership_attribute=user_membership_attribute, user_object_filter=user_object_filter, user_property_mappings=user_property_mappings) + print("The response of SourcesApi->sources_ldap_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_ldap_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **additional_group_dn** | **str**| | [optional] + **additional_user_dn** | **str**| | [optional] + **base_dn** | **str**| | [optional] + **bind_cn** | **str**| | [optional] + **client_certificate** | **UUID**| | [optional] + **delete_not_found_objects** | **bool**| | [optional] + **enabled** | **bool**| | [optional] + **group_membership_field** | **str**| | [optional] + **group_object_filter** | **str**| | [optional] + **group_property_mappings** | [**List[UUID]**](UUID.md)| | [optional] + **lookup_groups_from_user** | **bool**| | [optional] + **name** | **str**| | [optional] + **object_uniqueness_field** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **password_login_update_internal_password** | **bool**| | [optional] + **pbm_uuid** | **UUID**| | [optional] + **peer_certificate** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + **server_uri** | **str**| | [optional] + **slug** | **str**| | [optional] + **sni** | **bool**| | [optional] + **start_tls** | **bool**| | [optional] + **sync_groups** | **bool**| | [optional] + **sync_parent_group** | **UUID**| | [optional] + **sync_users** | **bool**| | [optional] + **sync_users_password** | **bool**| | [optional] + **user_membership_attribute** | **str**| | [optional] + **user_object_filter** | **str**| | [optional] + **user_property_mappings** | [**List[UUID]**](UUID.md)| | [optional] + +### Return type + +[**PaginatedLDAPSourceList**](PaginatedLDAPSourceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_ldap_partial_update** +> LDAPSource sources_ldap_partial_update(slug, patched_ldap_source_request=patched_ldap_source_request) + +LDAP Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_source import LDAPSource +from authentik_client.models.patched_ldap_source_request import PatchedLDAPSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + patched_ldap_source_request = authentik_client.PatchedLDAPSourceRequest() # PatchedLDAPSourceRequest | (optional) + + try: + api_response = api_instance.sources_ldap_partial_update(slug, patched_ldap_source_request=patched_ldap_source_request) + print("The response of SourcesApi->sources_ldap_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_ldap_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **patched_ldap_source_request** | [**PatchedLDAPSourceRequest**](PatchedLDAPSourceRequest.md)| | [optional] + +### Return type + +[**LDAPSource**](LDAPSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_ldap_retrieve** +> LDAPSource sources_ldap_retrieve(slug) + +LDAP Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_source import LDAPSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_ldap_retrieve(slug) + print("The response of SourcesApi->sources_ldap_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_ldap_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**LDAPSource**](LDAPSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_ldap_sync_status_retrieve** +> SyncStatus sources_ldap_sync_status_retrieve(slug) + +Get provider's sync status + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.sync_status import SyncStatus +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_ldap_sync_status_retrieve(slug) + print("The response of SourcesApi->sources_ldap_sync_status_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_ldap_sync_status_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**SyncStatus**](SyncStatus.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_ldap_update** +> LDAPSource sources_ldap_update(slug, ldap_source_request) + +LDAP Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ldap_source import LDAPSource +from authentik_client.models.ldap_source_request import LDAPSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + ldap_source_request = authentik_client.LDAPSourceRequest() # LDAPSourceRequest | + + try: + api_response = api_instance.sources_ldap_update(slug, ldap_source_request) + print("The response of SourcesApi->sources_ldap_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_ldap_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **ldap_source_request** | [**LDAPSourceRequest**](LDAPSourceRequest.md)| | + +### Return type + +[**LDAPSource**](LDAPSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_ldap_used_by_list** +> List[UsedBy] sources_ldap_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_ldap_used_by_list(slug) + print("The response of SourcesApi->sources_ldap_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_ldap_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_oauth_create** +> OAuthSource sources_oauth_create(o_auth_source_request) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth_source import OAuthSource +from authentik_client.models.o_auth_source_request import OAuthSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + o_auth_source_request = authentik_client.OAuthSourceRequest() # OAuthSourceRequest | + + try: + api_response = api_instance.sources_oauth_create(o_auth_source_request) + print("The response of SourcesApi->sources_oauth_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_oauth_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **o_auth_source_request** | [**OAuthSourceRequest**](OAuthSourceRequest.md)| | + +### Return type + +[**OAuthSource**](OAuthSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_oauth_destroy** +> sources_oauth_destroy(slug) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.sources_oauth_destroy(slug) + except Exception as e: + print("Exception when calling SourcesApi->sources_oauth_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_oauth_list** +> PaginatedOAuthSourceList sources_oauth_list(access_token_url=access_token_url, additional_scopes=additional_scopes, authentication_flow=authentication_flow, authorization_url=authorization_url, consumer_key=consumer_key, enabled=enabled, enrollment_flow=enrollment_flow, group_matching_mode=group_matching_mode, has_jwks=has_jwks, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policy_engine_mode=policy_engine_mode, profile_url=profile_url, provider_type=provider_type, request_token_url=request_token_url, search=search, slug=slug, user_matching_mode=user_matching_mode) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_o_auth_source_list import PaginatedOAuthSourceList +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + access_token_url = 'access_token_url_example' # str | (optional) + additional_scopes = 'additional_scopes_example' # str | (optional) + authentication_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + authorization_url = 'authorization_url_example' # str | (optional) + consumer_key = 'consumer_key_example' # str | (optional) + enabled = True # bool | (optional) + enrollment_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + group_matching_mode = authentik_client.GroupMatchingModeEnum() # GroupMatchingModeEnum | (optional) + has_jwks = True # bool | Only return sources with JWKS data (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + policy_engine_mode = authentik_client.PolicyEngineMode() # PolicyEngineMode | (optional) + profile_url = 'profile_url_example' # str | (optional) + provider_type = 'provider_type_example' # str | (optional) + request_token_url = 'request_token_url_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + slug = 'slug_example' # str | (optional) + user_matching_mode = authentik_client.UserMatchingModeEnum() # UserMatchingModeEnum | (optional) + + try: + api_response = api_instance.sources_oauth_list(access_token_url=access_token_url, additional_scopes=additional_scopes, authentication_flow=authentication_flow, authorization_url=authorization_url, consumer_key=consumer_key, enabled=enabled, enrollment_flow=enrollment_flow, group_matching_mode=group_matching_mode, has_jwks=has_jwks, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policy_engine_mode=policy_engine_mode, profile_url=profile_url, provider_type=provider_type, request_token_url=request_token_url, search=search, slug=slug, user_matching_mode=user_matching_mode) + print("The response of SourcesApi->sources_oauth_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_oauth_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **access_token_url** | **str**| | [optional] + **additional_scopes** | **str**| | [optional] + **authentication_flow** | **UUID**| | [optional] + **authorization_url** | **str**| | [optional] + **consumer_key** | **str**| | [optional] + **enabled** | **bool**| | [optional] + **enrollment_flow** | **UUID**| | [optional] + **group_matching_mode** | [**GroupMatchingModeEnum**](.md)| | [optional] + **has_jwks** | **bool**| Only return sources with JWKS data | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pbm_uuid** | **UUID**| | [optional] + **policy_engine_mode** | [**PolicyEngineMode**](.md)| | [optional] + **profile_url** | **str**| | [optional] + **provider_type** | **str**| | [optional] + **request_token_url** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + **slug** | **str**| | [optional] + **user_matching_mode** | [**UserMatchingModeEnum**](.md)| | [optional] + +### Return type + +[**PaginatedOAuthSourceList**](PaginatedOAuthSourceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_oauth_partial_update** +> OAuthSource sources_oauth_partial_update(slug, patched_o_auth_source_request=patched_o_auth_source_request) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth_source import OAuthSource +from authentik_client.models.patched_o_auth_source_request import PatchedOAuthSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + patched_o_auth_source_request = authentik_client.PatchedOAuthSourceRequest() # PatchedOAuthSourceRequest | (optional) + + try: + api_response = api_instance.sources_oauth_partial_update(slug, patched_o_auth_source_request=patched_o_auth_source_request) + print("The response of SourcesApi->sources_oauth_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_oauth_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **patched_o_auth_source_request** | [**PatchedOAuthSourceRequest**](PatchedOAuthSourceRequest.md)| | [optional] + +### Return type + +[**OAuthSource**](OAuthSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_oauth_retrieve** +> OAuthSource sources_oauth_retrieve(slug) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth_source import OAuthSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_oauth_retrieve(slug) + print("The response of SourcesApi->sources_oauth_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_oauth_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**OAuthSource**](OAuthSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_oauth_source_types_list** +> List[SourceType] sources_oauth_source_types_list(name=name) + +Get all creatable source types. If ?name is set, only returns the type for . +If isn't found, returns the default type. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.source_type import SourceType +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + name = 'name_example' # str | (optional) + + try: + api_response = api_instance.sources_oauth_source_types_list(name=name) + print("The response of SourcesApi->sources_oauth_source_types_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_oauth_source_types_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + +### Return type + +[**List[SourceType]**](SourceType.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_oauth_update** +> OAuthSource sources_oauth_update(slug, o_auth_source_request) + +Source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.o_auth_source import OAuthSource +from authentik_client.models.o_auth_source_request import OAuthSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + o_auth_source_request = authentik_client.OAuthSourceRequest() # OAuthSourceRequest | + + try: + api_response = api_instance.sources_oauth_update(slug, o_auth_source_request) + print("The response of SourcesApi->sources_oauth_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_oauth_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **o_auth_source_request** | [**OAuthSourceRequest**](OAuthSourceRequest.md)| | + +### Return type + +[**OAuthSource**](OAuthSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_oauth_used_by_list** +> List[UsedBy] sources_oauth_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_oauth_used_by_list(slug) + print("The response of SourcesApi->sources_oauth_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_oauth_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_plex_create** +> PlexSource sources_plex_create(plex_source_request) + +Plex source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.plex_source import PlexSource +from authentik_client.models.plex_source_request import PlexSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + plex_source_request = authentik_client.PlexSourceRequest() # PlexSourceRequest | + + try: + api_response = api_instance.sources_plex_create(plex_source_request) + print("The response of SourcesApi->sources_plex_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_plex_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **plex_source_request** | [**PlexSourceRequest**](PlexSourceRequest.md)| | + +### Return type + +[**PlexSource**](PlexSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_plex_destroy** +> sources_plex_destroy(slug) + +Plex source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.sources_plex_destroy(slug) + except Exception as e: + print("Exception when calling SourcesApi->sources_plex_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_plex_list** +> PaginatedPlexSourceList sources_plex_list(allow_friends=allow_friends, authentication_flow=authentication_flow, client_id=client_id, enabled=enabled, enrollment_flow=enrollment_flow, group_matching_mode=group_matching_mode, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policy_engine_mode=policy_engine_mode, search=search, slug=slug, user_matching_mode=user_matching_mode) + +Plex source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_plex_source_list import PaginatedPlexSourceList +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + allow_friends = True # bool | (optional) + authentication_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + client_id = 'client_id_example' # str | (optional) + enabled = True # bool | (optional) + enrollment_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + group_matching_mode = authentik_client.GroupMatchingModeEnum() # GroupMatchingModeEnum | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + policy_engine_mode = authentik_client.PolicyEngineMode() # PolicyEngineMode | (optional) + search = 'search_example' # str | A search term. (optional) + slug = 'slug_example' # str | (optional) + user_matching_mode = authentik_client.UserMatchingModeEnum() # UserMatchingModeEnum | (optional) + + try: + api_response = api_instance.sources_plex_list(allow_friends=allow_friends, authentication_flow=authentication_flow, client_id=client_id, enabled=enabled, enrollment_flow=enrollment_flow, group_matching_mode=group_matching_mode, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policy_engine_mode=policy_engine_mode, search=search, slug=slug, user_matching_mode=user_matching_mode) + print("The response of SourcesApi->sources_plex_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_plex_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **allow_friends** | **bool**| | [optional] + **authentication_flow** | **UUID**| | [optional] + **client_id** | **str**| | [optional] + **enabled** | **bool**| | [optional] + **enrollment_flow** | **UUID**| | [optional] + **group_matching_mode** | [**GroupMatchingModeEnum**](.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pbm_uuid** | **UUID**| | [optional] + **policy_engine_mode** | [**PolicyEngineMode**](.md)| | [optional] + **search** | **str**| A search term. | [optional] + **slug** | **str**| | [optional] + **user_matching_mode** | [**UserMatchingModeEnum**](.md)| | [optional] + +### Return type + +[**PaginatedPlexSourceList**](PaginatedPlexSourceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_plex_partial_update** +> PlexSource sources_plex_partial_update(slug, patched_plex_source_request=patched_plex_source_request) + +Plex source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_plex_source_request import PatchedPlexSourceRequest +from authentik_client.models.plex_source import PlexSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + patched_plex_source_request = authentik_client.PatchedPlexSourceRequest() # PatchedPlexSourceRequest | (optional) + + try: + api_response = api_instance.sources_plex_partial_update(slug, patched_plex_source_request=patched_plex_source_request) + print("The response of SourcesApi->sources_plex_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_plex_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **patched_plex_source_request** | [**PatchedPlexSourceRequest**](PatchedPlexSourceRequest.md)| | [optional] + +### Return type + +[**PlexSource**](PlexSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_plex_redeem_token_authenticated_create** +> sources_plex_redeem_token_authenticated_create(plex_token_redeem_request, slug=slug) + +Redeem a plex token for an authenticated user, creating a connection + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.plex_token_redeem_request import PlexTokenRedeemRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + plex_token_redeem_request = authentik_client.PlexTokenRedeemRequest() # PlexTokenRedeemRequest | + slug = 'slug_example' # str | (optional) + + try: + api_instance.sources_plex_redeem_token_authenticated_create(plex_token_redeem_request, slug=slug) + except Exception as e: + print("Exception when calling SourcesApi->sources_plex_redeem_token_authenticated_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **plex_token_redeem_request** | [**PlexTokenRedeemRequest**](PlexTokenRedeemRequest.md)| | + **slug** | **str**| | [optional] + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: Not defined + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | Token not found | - | +**403** | Access denied | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_plex_redeem_token_create** +> RedirectChallenge sources_plex_redeem_token_create(plex_token_redeem_request, slug=slug) + +Redeem a plex token, check it's access to resources against what's allowed +for the source, and redirect to an authentication/enrollment flow. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.plex_token_redeem_request import PlexTokenRedeemRequest +from authentik_client.models.redirect_challenge import RedirectChallenge +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + plex_token_redeem_request = authentik_client.PlexTokenRedeemRequest() # PlexTokenRedeemRequest | + slug = 'slug_example' # str | (optional) + + try: + api_response = api_instance.sources_plex_redeem_token_create(plex_token_redeem_request, slug=slug) + print("The response of SourcesApi->sources_plex_redeem_token_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_plex_redeem_token_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **plex_token_redeem_request** | [**PlexTokenRedeemRequest**](PlexTokenRedeemRequest.md)| | + **slug** | **str**| | [optional] + +### Return type + +[**RedirectChallenge**](RedirectChallenge.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Token not found | - | +**403** | Access denied | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_plex_retrieve** +> PlexSource sources_plex_retrieve(slug) + +Plex source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.plex_source import PlexSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_plex_retrieve(slug) + print("The response of SourcesApi->sources_plex_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_plex_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**PlexSource**](PlexSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_plex_update** +> PlexSource sources_plex_update(slug, plex_source_request) + +Plex source Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.plex_source import PlexSource +from authentik_client.models.plex_source_request import PlexSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + plex_source_request = authentik_client.PlexSourceRequest() # PlexSourceRequest | + + try: + api_response = api_instance.sources_plex_update(slug, plex_source_request) + print("The response of SourcesApi->sources_plex_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_plex_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **plex_source_request** | [**PlexSourceRequest**](PlexSourceRequest.md)| | + +### Return type + +[**PlexSource**](PlexSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_plex_used_by_list** +> List[UsedBy] sources_plex_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_plex_used_by_list(slug) + print("The response of SourcesApi->sources_plex_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_plex_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_saml_create** +> SAMLSource sources_saml_create(saml_source_request) + +SAMLSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_source import SAMLSource +from authentik_client.models.saml_source_request import SAMLSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + saml_source_request = authentik_client.SAMLSourceRequest() # SAMLSourceRequest | + + try: + api_response = api_instance.sources_saml_create(saml_source_request) + print("The response of SourcesApi->sources_saml_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_saml_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **saml_source_request** | [**SAMLSourceRequest**](SAMLSourceRequest.md)| | + +### Return type + +[**SAMLSource**](SAMLSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_saml_destroy** +> sources_saml_destroy(slug) + +SAMLSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.sources_saml_destroy(slug) + except Exception as e: + print("Exception when calling SourcesApi->sources_saml_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_saml_list** +> PaginatedSAMLSourceList sources_saml_list(allow_idp_initiated=allow_idp_initiated, authentication_flow=authentication_flow, binding_type=binding_type, digest_algorithm=digest_algorithm, enabled=enabled, enrollment_flow=enrollment_flow, force_authn=force_authn, issuer=issuer, managed=managed, name=name, name_id_policy=name_id_policy, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policy_engine_mode=policy_engine_mode, pre_authentication_flow=pre_authentication_flow, search=search, signature_algorithm=signature_algorithm, signed_assertion=signed_assertion, signed_response=signed_response, signing_kp=signing_kp, slo_url=slo_url, slug=slug, sso_url=sso_url, temporary_user_delete_after=temporary_user_delete_after, user_matching_mode=user_matching_mode, verification_kp=verification_kp) + +SAMLSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.binding_type_enum import BindingTypeEnum +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum +from authentik_client.models.paginated_saml_source_list import PaginatedSAMLSourceList +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + allow_idp_initiated = True # bool | (optional) + authentication_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + binding_type = authentik_client.BindingTypeEnum() # BindingTypeEnum | (optional) + digest_algorithm = authentik_client.DigestAlgorithmEnum() # DigestAlgorithmEnum | (optional) + enabled = True # bool | (optional) + enrollment_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + force_authn = True # bool | (optional) + issuer = 'issuer_example' # str | (optional) + managed = 'managed_example' # str | (optional) + name = 'name_example' # str | (optional) + name_id_policy = authentik_client.SAMLNameIDPolicyEnum() # SAMLNameIDPolicyEnum | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + policy_engine_mode = authentik_client.PolicyEngineMode() # PolicyEngineMode | (optional) + pre_authentication_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + signature_algorithm = authentik_client.SignatureAlgorithmEnum() # SignatureAlgorithmEnum | (optional) + signed_assertion = True # bool | (optional) + signed_response = True # bool | (optional) + signing_kp = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + slo_url = 'slo_url_example' # str | (optional) + slug = 'slug_example' # str | (optional) + sso_url = 'sso_url_example' # str | (optional) + temporary_user_delete_after = 'temporary_user_delete_after_example' # str | (optional) + user_matching_mode = authentik_client.UserMatchingModeEnum() # UserMatchingModeEnum | (optional) + verification_kp = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.sources_saml_list(allow_idp_initiated=allow_idp_initiated, authentication_flow=authentication_flow, binding_type=binding_type, digest_algorithm=digest_algorithm, enabled=enabled, enrollment_flow=enrollment_flow, force_authn=force_authn, issuer=issuer, managed=managed, name=name, name_id_policy=name_id_policy, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policy_engine_mode=policy_engine_mode, pre_authentication_flow=pre_authentication_flow, search=search, signature_algorithm=signature_algorithm, signed_assertion=signed_assertion, signed_response=signed_response, signing_kp=signing_kp, slo_url=slo_url, slug=slug, sso_url=sso_url, temporary_user_delete_after=temporary_user_delete_after, user_matching_mode=user_matching_mode, verification_kp=verification_kp) + print("The response of SourcesApi->sources_saml_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_saml_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **allow_idp_initiated** | **bool**| | [optional] + **authentication_flow** | **UUID**| | [optional] + **binding_type** | [**BindingTypeEnum**](.md)| | [optional] + **digest_algorithm** | [**DigestAlgorithmEnum**](.md)| | [optional] + **enabled** | **bool**| | [optional] + **enrollment_flow** | **UUID**| | [optional] + **force_authn** | **bool**| | [optional] + **issuer** | **str**| | [optional] + **managed** | **str**| | [optional] + **name** | **str**| | [optional] + **name_id_policy** | [**SAMLNameIDPolicyEnum**](.md)| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pbm_uuid** | **UUID**| | [optional] + **policy_engine_mode** | [**PolicyEngineMode**](.md)| | [optional] + **pre_authentication_flow** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + **signature_algorithm** | [**SignatureAlgorithmEnum**](.md)| | [optional] + **signed_assertion** | **bool**| | [optional] + **signed_response** | **bool**| | [optional] + **signing_kp** | **UUID**| | [optional] + **slo_url** | **str**| | [optional] + **slug** | **str**| | [optional] + **sso_url** | **str**| | [optional] + **temporary_user_delete_after** | **str**| | [optional] + **user_matching_mode** | [**UserMatchingModeEnum**](.md)| | [optional] + **verification_kp** | **UUID**| | [optional] + +### Return type + +[**PaginatedSAMLSourceList**](PaginatedSAMLSourceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_saml_metadata_retrieve** +> SAMLMetadata sources_saml_metadata_retrieve(slug) + +Return metadata as XML string + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_metadata import SAMLMetadata +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_saml_metadata_retrieve(slug) + print("The response of SourcesApi->sources_saml_metadata_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_saml_metadata_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**SAMLMetadata**](SAMLMetadata.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_saml_partial_update** +> SAMLSource sources_saml_partial_update(slug, patched_saml_source_request=patched_saml_source_request) + +SAMLSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_saml_source_request import PatchedSAMLSourceRequest +from authentik_client.models.saml_source import SAMLSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + patched_saml_source_request = authentik_client.PatchedSAMLSourceRequest() # PatchedSAMLSourceRequest | (optional) + + try: + api_response = api_instance.sources_saml_partial_update(slug, patched_saml_source_request=patched_saml_source_request) + print("The response of SourcesApi->sources_saml_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_saml_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **patched_saml_source_request** | [**PatchedSAMLSourceRequest**](PatchedSAMLSourceRequest.md)| | [optional] + +### Return type + +[**SAMLSource**](SAMLSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_saml_retrieve** +> SAMLSource sources_saml_retrieve(slug) + +SAMLSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_source import SAMLSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_saml_retrieve(slug) + print("The response of SourcesApi->sources_saml_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_saml_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**SAMLSource**](SAMLSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_saml_update** +> SAMLSource sources_saml_update(slug, saml_source_request) + +SAMLSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.saml_source import SAMLSource +from authentik_client.models.saml_source_request import SAMLSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + saml_source_request = authentik_client.SAMLSourceRequest() # SAMLSourceRequest | + + try: + api_response = api_instance.sources_saml_update(slug, saml_source_request) + print("The response of SourcesApi->sources_saml_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_saml_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **saml_source_request** | [**SAMLSourceRequest**](SAMLSourceRequest.md)| | + +### Return type + +[**SAMLSource**](SAMLSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_saml_used_by_list** +> List[UsedBy] sources_saml_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_saml_used_by_list(slug) + print("The response of SourcesApi->sources_saml_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_saml_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_create** +> SCIMSource sources_scim_create(scim_source_request) + +SCIMSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source import SCIMSource +from authentik_client.models.scim_source_request import SCIMSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + scim_source_request = authentik_client.SCIMSourceRequest() # SCIMSourceRequest | + + try: + api_response = api_instance.sources_scim_create(scim_source_request) + print("The response of SourcesApi->sources_scim_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scim_source_request** | [**SCIMSourceRequest**](SCIMSourceRequest.md)| | + +### Return type + +[**SCIMSource**](SCIMSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_destroy** +> sources_scim_destroy(slug) + +SCIMSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.sources_scim_destroy(slug) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_groups_create** +> SCIMSourceGroup sources_scim_groups_create(scim_source_group_request) + +SCIMSourceGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source_group import SCIMSourceGroup +from authentik_client.models.scim_source_group_request import SCIMSourceGroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + scim_source_group_request = authentik_client.SCIMSourceGroupRequest() # SCIMSourceGroupRequest | + + try: + api_response = api_instance.sources_scim_groups_create(scim_source_group_request) + print("The response of SourcesApi->sources_scim_groups_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_groups_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scim_source_group_request** | [**SCIMSourceGroupRequest**](SCIMSourceGroupRequest.md)| | + +### Return type + +[**SCIMSourceGroup**](SCIMSourceGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_groups_destroy** +> sources_scim_groups_destroy(id) + +SCIMSourceGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source group. + + try: + api_instance.sources_scim_groups_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_groups_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source group. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_groups_list** +> PaginatedSCIMSourceGroupList sources_scim_groups_list(group__group_uuid=group__group_uuid, group__name=group__name, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + +SCIMSourceGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_scim_source_group_list import PaginatedSCIMSourceGroupList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + group__group_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + group__name = 'group__name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + + try: + api_response = api_instance.sources_scim_groups_list(group__group_uuid=group__group_uuid, group__name=group__name, ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug) + print("The response of SourcesApi->sources_scim_groups_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_groups_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **group__group_uuid** | **UUID**| | [optional] + **group__name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + +### Return type + +[**PaginatedSCIMSourceGroupList**](PaginatedSCIMSourceGroupList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_groups_partial_update** +> SCIMSourceGroup sources_scim_groups_partial_update(id, patched_scim_source_group_request=patched_scim_source_group_request) + +SCIMSourceGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_scim_source_group_request import PatchedSCIMSourceGroupRequest +from authentik_client.models.scim_source_group import SCIMSourceGroup +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source group. + patched_scim_source_group_request = authentik_client.PatchedSCIMSourceGroupRequest() # PatchedSCIMSourceGroupRequest | (optional) + + try: + api_response = api_instance.sources_scim_groups_partial_update(id, patched_scim_source_group_request=patched_scim_source_group_request) + print("The response of SourcesApi->sources_scim_groups_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_groups_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source group. | + **patched_scim_source_group_request** | [**PatchedSCIMSourceGroupRequest**](PatchedSCIMSourceGroupRequest.md)| | [optional] + +### Return type + +[**SCIMSourceGroup**](SCIMSourceGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_groups_retrieve** +> SCIMSourceGroup sources_scim_groups_retrieve(id) + +SCIMSourceGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source_group import SCIMSourceGroup +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source group. + + try: + api_response = api_instance.sources_scim_groups_retrieve(id) + print("The response of SourcesApi->sources_scim_groups_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_groups_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source group. | + +### Return type + +[**SCIMSourceGroup**](SCIMSourceGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_groups_update** +> SCIMSourceGroup sources_scim_groups_update(id, scim_source_group_request) + +SCIMSourceGroup Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source_group import SCIMSourceGroup +from authentik_client.models.scim_source_group_request import SCIMSourceGroupRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source group. + scim_source_group_request = authentik_client.SCIMSourceGroupRequest() # SCIMSourceGroupRequest | + + try: + api_response = api_instance.sources_scim_groups_update(id, scim_source_group_request) + print("The response of SourcesApi->sources_scim_groups_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_groups_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source group. | + **scim_source_group_request** | [**SCIMSourceGroupRequest**](SCIMSourceGroupRequest.md)| | + +### Return type + +[**SCIMSourceGroup**](SCIMSourceGroup.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_groups_used_by_list** +> List[UsedBy] sources_scim_groups_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source group. + + try: + api_response = api_instance.sources_scim_groups_used_by_list(id) + print("The response of SourcesApi->sources_scim_groups_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_groups_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source group. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_list** +> PaginatedSCIMSourceList sources_scim_list(name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, search=search, slug=slug) + +SCIMSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_scim_source_list import PaginatedSCIMSourceList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + slug = 'slug_example' # str | (optional) + + try: + api_response = api_instance.sources_scim_list(name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, search=search, slug=slug) + print("The response of SourcesApi->sources_scim_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pbm_uuid** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + **slug** | **str**| | [optional] + +### Return type + +[**PaginatedSCIMSourceList**](PaginatedSCIMSourceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_partial_update** +> SCIMSource sources_scim_partial_update(slug, patched_scim_source_request=patched_scim_source_request) + +SCIMSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_scim_source_request import PatchedSCIMSourceRequest +from authentik_client.models.scim_source import SCIMSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + patched_scim_source_request = authentik_client.PatchedSCIMSourceRequest() # PatchedSCIMSourceRequest | (optional) + + try: + api_response = api_instance.sources_scim_partial_update(slug, patched_scim_source_request=patched_scim_source_request) + print("The response of SourcesApi->sources_scim_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **patched_scim_source_request** | [**PatchedSCIMSourceRequest**](PatchedSCIMSourceRequest.md)| | [optional] + +### Return type + +[**SCIMSource**](SCIMSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_retrieve** +> SCIMSource sources_scim_retrieve(slug) + +SCIMSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source import SCIMSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_scim_retrieve(slug) + print("The response of SourcesApi->sources_scim_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**SCIMSource**](SCIMSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_update** +> SCIMSource sources_scim_update(slug, scim_source_request) + +SCIMSource Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source import SCIMSource +from authentik_client.models.scim_source_request import SCIMSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + scim_source_request = authentik_client.SCIMSourceRequest() # SCIMSourceRequest | + + try: + api_response = api_instance.sources_scim_update(slug, scim_source_request) + print("The response of SourcesApi->sources_scim_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **scim_source_request** | [**SCIMSourceRequest**](SCIMSourceRequest.md)| | + +### Return type + +[**SCIMSource**](SCIMSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_used_by_list** +> List[UsedBy] sources_scim_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_scim_used_by_list(slug) + print("The response of SourcesApi->sources_scim_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_users_create** +> SCIMSourceUser sources_scim_users_create(scim_source_user_request) + +SCIMSourceUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source_user import SCIMSourceUser +from authentik_client.models.scim_source_user_request import SCIMSourceUserRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + scim_source_user_request = authentik_client.SCIMSourceUserRequest() # SCIMSourceUserRequest | + + try: + api_response = api_instance.sources_scim_users_create(scim_source_user_request) + print("The response of SourcesApi->sources_scim_users_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_users_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scim_source_user_request** | [**SCIMSourceUserRequest**](SCIMSourceUserRequest.md)| | + +### Return type + +[**SCIMSourceUser**](SCIMSourceUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_users_destroy** +> sources_scim_users_destroy(id) + +SCIMSourceUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source user. + + try: + api_instance.sources_scim_users_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_users_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source user. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_users_list** +> PaginatedSCIMSourceUserList sources_scim_users_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user__id=user__id, user__username=user__username) + +SCIMSourceUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_scim_source_user_list import PaginatedSCIMSourceUserList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + user__id = 56 # int | (optional) + user__username = 'user__username_example' # str | (optional) + + try: + api_response = api_instance.sources_scim_users_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user__id=user__id, user__username=user__username) + print("The response of SourcesApi->sources_scim_users_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_users_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + **user__id** | **int**| | [optional] + **user__username** | **str**| | [optional] + +### Return type + +[**PaginatedSCIMSourceUserList**](PaginatedSCIMSourceUserList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_users_partial_update** +> SCIMSourceUser sources_scim_users_partial_update(id, patched_scim_source_user_request=patched_scim_source_user_request) + +SCIMSourceUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_scim_source_user_request import PatchedSCIMSourceUserRequest +from authentik_client.models.scim_source_user import SCIMSourceUser +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source user. + patched_scim_source_user_request = authentik_client.PatchedSCIMSourceUserRequest() # PatchedSCIMSourceUserRequest | (optional) + + try: + api_response = api_instance.sources_scim_users_partial_update(id, patched_scim_source_user_request=patched_scim_source_user_request) + print("The response of SourcesApi->sources_scim_users_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_users_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source user. | + **patched_scim_source_user_request** | [**PatchedSCIMSourceUserRequest**](PatchedSCIMSourceUserRequest.md)| | [optional] + +### Return type + +[**SCIMSourceUser**](SCIMSourceUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_users_retrieve** +> SCIMSourceUser sources_scim_users_retrieve(id) + +SCIMSourceUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source_user import SCIMSourceUser +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source user. + + try: + api_response = api_instance.sources_scim_users_retrieve(id) + print("The response of SourcesApi->sources_scim_users_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_users_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source user. | + +### Return type + +[**SCIMSourceUser**](SCIMSourceUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_users_update** +> SCIMSourceUser sources_scim_users_update(id, scim_source_user_request) + +SCIMSourceUser Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.scim_source_user import SCIMSourceUser +from authentik_client.models.scim_source_user_request import SCIMSourceUserRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source user. + scim_source_user_request = authentik_client.SCIMSourceUserRequest() # SCIMSourceUserRequest | + + try: + api_response = api_instance.sources_scim_users_update(id, scim_source_user_request) + print("The response of SourcesApi->sources_scim_users_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_users_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source user. | + **scim_source_user_request** | [**SCIMSourceUserRequest**](SCIMSourceUserRequest.md)| | + +### Return type + +[**SCIMSourceUser**](SCIMSourceUser.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_scim_users_used_by_list** +> List[UsedBy] sources_scim_users_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 'id_example' # str | A unique value identifying this scim source user. + + try: + api_response = api_instance.sources_scim_users_used_by_list(id) + print("The response of SourcesApi->sources_scim_users_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_scim_users_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **str**| A unique value identifying this scim source user. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_telegram_connect_user_create** +> UserTelegramSourceConnection sources_telegram_connect_user_create(slug, telegram_auth_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.telegram_auth_request import TelegramAuthRequest +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + telegram_auth_request = authentik_client.TelegramAuthRequest() # TelegramAuthRequest | + + try: + api_response = api_instance.sources_telegram_connect_user_create(slug, telegram_auth_request) + print("The response of SourcesApi->sources_telegram_connect_user_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_telegram_connect_user_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **telegram_auth_request** | [**TelegramAuthRequest**](TelegramAuthRequest.md)| | + +### Return type + +[**UserTelegramSourceConnection**](UserTelegramSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**403** | Access denied | - | +**400** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_telegram_create** +> TelegramSource sources_telegram_create(telegram_source_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.telegram_source import TelegramSource +from authentik_client.models.telegram_source_request import TelegramSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + telegram_source_request = authentik_client.TelegramSourceRequest() # TelegramSourceRequest | + + try: + api_response = api_instance.sources_telegram_create(telegram_source_request) + print("The response of SourcesApi->sources_telegram_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_telegram_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **telegram_source_request** | [**TelegramSourceRequest**](TelegramSourceRequest.md)| | + +### Return type + +[**TelegramSource**](TelegramSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_telegram_destroy** +> sources_telegram_destroy(slug) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_instance.sources_telegram_destroy(slug) + except Exception as e: + print("Exception when calling SourcesApi->sources_telegram_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_telegram_list** +> PaginatedTelegramSourceList sources_telegram_list(authentication_flow=authentication_flow, bot_username=bot_username, enabled=enabled, enrollment_flow=enrollment_flow, group_matching_mode=group_matching_mode, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policy_engine_mode=policy_engine_mode, request_message_access=request_message_access, search=search, slug=slug, user_matching_mode=user_matching_mode) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_telegram_source_list import PaginatedTelegramSourceList +from authentik_client.models.policy_engine_mode import PolicyEngineMode +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + authentication_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + bot_username = 'bot_username_example' # str | (optional) + enabled = True # bool | (optional) + enrollment_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + group_matching_mode = authentik_client.GroupMatchingModeEnum() # GroupMatchingModeEnum | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + pbm_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + policy_engine_mode = authentik_client.PolicyEngineMode() # PolicyEngineMode | (optional) + request_message_access = True # bool | (optional) + search = 'search_example' # str | A search term. (optional) + slug = 'slug_example' # str | (optional) + user_matching_mode = authentik_client.UserMatchingModeEnum() # UserMatchingModeEnum | (optional) + + try: + api_response = api_instance.sources_telegram_list(authentication_flow=authentication_flow, bot_username=bot_username, enabled=enabled, enrollment_flow=enrollment_flow, group_matching_mode=group_matching_mode, name=name, ordering=ordering, page=page, page_size=page_size, pbm_uuid=pbm_uuid, policy_engine_mode=policy_engine_mode, request_message_access=request_message_access, search=search, slug=slug, user_matching_mode=user_matching_mode) + print("The response of SourcesApi->sources_telegram_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_telegram_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authentication_flow** | **UUID**| | [optional] + **bot_username** | **str**| | [optional] + **enabled** | **bool**| | [optional] + **enrollment_flow** | **UUID**| | [optional] + **group_matching_mode** | [**GroupMatchingModeEnum**](.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **pbm_uuid** | **UUID**| | [optional] + **policy_engine_mode** | [**PolicyEngineMode**](.md)| | [optional] + **request_message_access** | **bool**| | [optional] + **search** | **str**| A search term. | [optional] + **slug** | **str**| | [optional] + **user_matching_mode** | [**UserMatchingModeEnum**](.md)| | [optional] + +### Return type + +[**PaginatedTelegramSourceList**](PaginatedTelegramSourceList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_telegram_partial_update** +> TelegramSource sources_telegram_partial_update(slug, patched_telegram_source_request=patched_telegram_source_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_telegram_source_request import PatchedTelegramSourceRequest +from authentik_client.models.telegram_source import TelegramSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + patched_telegram_source_request = authentik_client.PatchedTelegramSourceRequest() # PatchedTelegramSourceRequest | (optional) + + try: + api_response = api_instance.sources_telegram_partial_update(slug, patched_telegram_source_request=patched_telegram_source_request) + print("The response of SourcesApi->sources_telegram_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_telegram_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **patched_telegram_source_request** | [**PatchedTelegramSourceRequest**](PatchedTelegramSourceRequest.md)| | [optional] + +### Return type + +[**TelegramSource**](TelegramSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_telegram_retrieve** +> TelegramSource sources_telegram_retrieve(slug) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.telegram_source import TelegramSource +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_telegram_retrieve(slug) + print("The response of SourcesApi->sources_telegram_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_telegram_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**TelegramSource**](TelegramSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_telegram_update** +> TelegramSource sources_telegram_update(slug, telegram_source_request) + +Mixin to add a used_by endpoint to return a list of all objects using this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.telegram_source import TelegramSource +from authentik_client.models.telegram_source_request import TelegramSourceRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + telegram_source_request = authentik_client.TelegramSourceRequest() # TelegramSourceRequest | + + try: + api_response = api_instance.sources_telegram_update(slug, telegram_source_request) + print("The response of SourcesApi->sources_telegram_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_telegram_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + **telegram_source_request** | [**TelegramSourceRequest**](TelegramSourceRequest.md)| | + +### Return type + +[**TelegramSource**](TelegramSource.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_telegram_used_by_list** +> List[UsedBy] sources_telegram_used_by_list(slug) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + slug = 'slug_example' # str | + + try: + api_response = api_instance.sources_telegram_used_by_list(slug) + print("The response of SourcesApi->sources_telegram_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_telegram_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **slug** | **str**| | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_all_destroy** +> sources_user_connections_all_destroy(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this user source connection. + + try: + api_instance.sources_user_connections_all_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_all_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this user source connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_all_list** +> PaginatedUserSourceConnectionList sources_user_connections_all_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_source_connection_list import PaginatedUserSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.sources_user_connections_all_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + print("The response of SourcesApi->sources_user_connections_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_all_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedUserSourceConnectionList**](PaginatedUserSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_all_partial_update** +> UserSourceConnection sources_user_connections_all_partial_update(id, patched_user_source_connection_request=patched_user_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_source_connection_request import PatchedUserSourceConnectionRequest +from authentik_client.models.user_source_connection import UserSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this user source connection. + patched_user_source_connection_request = authentik_client.PatchedUserSourceConnectionRequest() # PatchedUserSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_user_connections_all_partial_update(id, patched_user_source_connection_request=patched_user_source_connection_request) + print("The response of SourcesApi->sources_user_connections_all_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_all_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this user source connection. | + **patched_user_source_connection_request** | [**PatchedUserSourceConnectionRequest**](PatchedUserSourceConnectionRequest.md)| | [optional] + +### Return type + +[**UserSourceConnection**](UserSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_all_retrieve** +> UserSourceConnection sources_user_connections_all_retrieve(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_source_connection import UserSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this user source connection. + + try: + api_response = api_instance.sources_user_connections_all_retrieve(id) + print("The response of SourcesApi->sources_user_connections_all_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_all_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this user source connection. | + +### Return type + +[**UserSourceConnection**](UserSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_all_update** +> UserSourceConnection sources_user_connections_all_update(id, user_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_source_connection import UserSourceConnection +from authentik_client.models.user_source_connection_request import UserSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this user source connection. + user_source_connection_request = authentik_client.UserSourceConnectionRequest() # UserSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_all_update(id, user_source_connection_request) + print("The response of SourcesApi->sources_user_connections_all_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_all_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this user source connection. | + **user_source_connection_request** | [**UserSourceConnectionRequest**](UserSourceConnectionRequest.md)| | + +### Return type + +[**UserSourceConnection**](UserSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_all_used_by_list** +> List[UsedBy] sources_user_connections_all_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this user source connection. + + try: + api_response = api_instance.sources_user_connections_all_used_by_list(id) + print("The response of SourcesApi->sources_user_connections_all_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_all_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this user source connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_kerberos_create** +> UserKerberosSourceConnection sources_user_connections_kerberos_create(user_kerberos_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection +from authentik_client.models.user_kerberos_source_connection_request import UserKerberosSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + user_kerberos_source_connection_request = authentik_client.UserKerberosSourceConnectionRequest() # UserKerberosSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_kerberos_create(user_kerberos_source_connection_request) + print("The response of SourcesApi->sources_user_connections_kerberos_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_kerberos_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_kerberos_source_connection_request** | [**UserKerberosSourceConnectionRequest**](UserKerberosSourceConnectionRequest.md)| | + +### Return type + +[**UserKerberosSourceConnection**](UserKerberosSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_kerberos_destroy** +> sources_user_connections_kerberos_destroy(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Kerberos Source Connection. + + try: + api_instance.sources_user_connections_kerberos_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_kerberos_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Kerberos Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_kerberos_list** +> PaginatedUserKerberosSourceConnectionList sources_user_connections_kerberos_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_kerberos_source_connection_list import PaginatedUserKerberosSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.sources_user_connections_kerberos_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + print("The response of SourcesApi->sources_user_connections_kerberos_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_kerberos_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedUserKerberosSourceConnectionList**](PaginatedUserKerberosSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_kerberos_partial_update** +> UserKerberosSourceConnection sources_user_connections_kerberos_partial_update(id, patched_user_kerberos_source_connection_request=patched_user_kerberos_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_kerberos_source_connection_request import PatchedUserKerberosSourceConnectionRequest +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Kerberos Source Connection. + patched_user_kerberos_source_connection_request = authentik_client.PatchedUserKerberosSourceConnectionRequest() # PatchedUserKerberosSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_user_connections_kerberos_partial_update(id, patched_user_kerberos_source_connection_request=patched_user_kerberos_source_connection_request) + print("The response of SourcesApi->sources_user_connections_kerberos_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_kerberos_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Kerberos Source Connection. | + **patched_user_kerberos_source_connection_request** | [**PatchedUserKerberosSourceConnectionRequest**](PatchedUserKerberosSourceConnectionRequest.md)| | [optional] + +### Return type + +[**UserKerberosSourceConnection**](UserKerberosSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_kerberos_retrieve** +> UserKerberosSourceConnection sources_user_connections_kerberos_retrieve(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Kerberos Source Connection. + + try: + api_response = api_instance.sources_user_connections_kerberos_retrieve(id) + print("The response of SourcesApi->sources_user_connections_kerberos_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_kerberos_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Kerberos Source Connection. | + +### Return type + +[**UserKerberosSourceConnection**](UserKerberosSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_kerberos_update** +> UserKerberosSourceConnection sources_user_connections_kerberos_update(id, user_kerberos_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection +from authentik_client.models.user_kerberos_source_connection_request import UserKerberosSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Kerberos Source Connection. + user_kerberos_source_connection_request = authentik_client.UserKerberosSourceConnectionRequest() # UserKerberosSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_kerberos_update(id, user_kerberos_source_connection_request) + print("The response of SourcesApi->sources_user_connections_kerberos_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_kerberos_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Kerberos Source Connection. | + **user_kerberos_source_connection_request** | [**UserKerberosSourceConnectionRequest**](UserKerberosSourceConnectionRequest.md)| | + +### Return type + +[**UserKerberosSourceConnection**](UserKerberosSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_kerberos_used_by_list** +> List[UsedBy] sources_user_connections_kerberos_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Kerberos Source Connection. + + try: + api_response = api_instance.sources_user_connections_kerberos_used_by_list(id) + print("The response of SourcesApi->sources_user_connections_kerberos_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_kerberos_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Kerberos Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_ldap_create** +> UserLDAPSourceConnection sources_user_connections_ldap_create(user_ldap_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection +from authentik_client.models.user_ldap_source_connection_request import UserLDAPSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + user_ldap_source_connection_request = authentik_client.UserLDAPSourceConnectionRequest() # UserLDAPSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_ldap_create(user_ldap_source_connection_request) + print("The response of SourcesApi->sources_user_connections_ldap_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_ldap_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_ldap_source_connection_request** | [**UserLDAPSourceConnectionRequest**](UserLDAPSourceConnectionRequest.md)| | + +### Return type + +[**UserLDAPSourceConnection**](UserLDAPSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_ldap_destroy** +> sources_user_connections_ldap_destroy(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User LDAP Source Connection. + + try: + api_instance.sources_user_connections_ldap_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_ldap_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User LDAP Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_ldap_list** +> PaginatedUserLDAPSourceConnectionList sources_user_connections_ldap_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_ldap_source_connection_list import PaginatedUserLDAPSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.sources_user_connections_ldap_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + print("The response of SourcesApi->sources_user_connections_ldap_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_ldap_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedUserLDAPSourceConnectionList**](PaginatedUserLDAPSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_ldap_partial_update** +> UserLDAPSourceConnection sources_user_connections_ldap_partial_update(id, patched_user_ldap_source_connection_request=patched_user_ldap_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_ldap_source_connection_request import PatchedUserLDAPSourceConnectionRequest +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User LDAP Source Connection. + patched_user_ldap_source_connection_request = authentik_client.PatchedUserLDAPSourceConnectionRequest() # PatchedUserLDAPSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_user_connections_ldap_partial_update(id, patched_user_ldap_source_connection_request=patched_user_ldap_source_connection_request) + print("The response of SourcesApi->sources_user_connections_ldap_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_ldap_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User LDAP Source Connection. | + **patched_user_ldap_source_connection_request** | [**PatchedUserLDAPSourceConnectionRequest**](PatchedUserLDAPSourceConnectionRequest.md)| | [optional] + +### Return type + +[**UserLDAPSourceConnection**](UserLDAPSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_ldap_retrieve** +> UserLDAPSourceConnection sources_user_connections_ldap_retrieve(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User LDAP Source Connection. + + try: + api_response = api_instance.sources_user_connections_ldap_retrieve(id) + print("The response of SourcesApi->sources_user_connections_ldap_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_ldap_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User LDAP Source Connection. | + +### Return type + +[**UserLDAPSourceConnection**](UserLDAPSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_ldap_update** +> UserLDAPSourceConnection sources_user_connections_ldap_update(id, user_ldap_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection +from authentik_client.models.user_ldap_source_connection_request import UserLDAPSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User LDAP Source Connection. + user_ldap_source_connection_request = authentik_client.UserLDAPSourceConnectionRequest() # UserLDAPSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_ldap_update(id, user_ldap_source_connection_request) + print("The response of SourcesApi->sources_user_connections_ldap_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_ldap_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User LDAP Source Connection. | + **user_ldap_source_connection_request** | [**UserLDAPSourceConnectionRequest**](UserLDAPSourceConnectionRequest.md)| | + +### Return type + +[**UserLDAPSourceConnection**](UserLDAPSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_ldap_used_by_list** +> List[UsedBy] sources_user_connections_ldap_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User LDAP Source Connection. + + try: + api_response = api_instance.sources_user_connections_ldap_used_by_list(id) + print("The response of SourcesApi->sources_user_connections_ldap_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_ldap_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User LDAP Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_oauth_create** +> UserOAuthSourceConnection sources_user_connections_oauth_create(user_o_auth_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection +from authentik_client.models.user_o_auth_source_connection_request import UserOAuthSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + user_o_auth_source_connection_request = authentik_client.UserOAuthSourceConnectionRequest() # UserOAuthSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_oauth_create(user_o_auth_source_connection_request) + print("The response of SourcesApi->sources_user_connections_oauth_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_oauth_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_o_auth_source_connection_request** | [**UserOAuthSourceConnectionRequest**](UserOAuthSourceConnectionRequest.md)| | + +### Return type + +[**UserOAuthSourceConnection**](UserOAuthSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_oauth_destroy** +> sources_user_connections_oauth_destroy(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User OAuth Source Connection. + + try: + api_instance.sources_user_connections_oauth_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_oauth_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User OAuth Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_oauth_list** +> PaginatedUserOAuthSourceConnectionList sources_user_connections_oauth_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_o_auth_source_connection_list import PaginatedUserOAuthSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.sources_user_connections_oauth_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + print("The response of SourcesApi->sources_user_connections_oauth_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_oauth_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedUserOAuthSourceConnectionList**](PaginatedUserOAuthSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_oauth_partial_update** +> UserOAuthSourceConnection sources_user_connections_oauth_partial_update(id, patched_user_o_auth_source_connection_request=patched_user_o_auth_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_o_auth_source_connection_request import PatchedUserOAuthSourceConnectionRequest +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User OAuth Source Connection. + patched_user_o_auth_source_connection_request = authentik_client.PatchedUserOAuthSourceConnectionRequest() # PatchedUserOAuthSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_user_connections_oauth_partial_update(id, patched_user_o_auth_source_connection_request=patched_user_o_auth_source_connection_request) + print("The response of SourcesApi->sources_user_connections_oauth_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_oauth_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User OAuth Source Connection. | + **patched_user_o_auth_source_connection_request** | [**PatchedUserOAuthSourceConnectionRequest**](PatchedUserOAuthSourceConnectionRequest.md)| | [optional] + +### Return type + +[**UserOAuthSourceConnection**](UserOAuthSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_oauth_retrieve** +> UserOAuthSourceConnection sources_user_connections_oauth_retrieve(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User OAuth Source Connection. + + try: + api_response = api_instance.sources_user_connections_oauth_retrieve(id) + print("The response of SourcesApi->sources_user_connections_oauth_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_oauth_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User OAuth Source Connection. | + +### Return type + +[**UserOAuthSourceConnection**](UserOAuthSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_oauth_update** +> UserOAuthSourceConnection sources_user_connections_oauth_update(id, user_o_auth_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection +from authentik_client.models.user_o_auth_source_connection_request import UserOAuthSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User OAuth Source Connection. + user_o_auth_source_connection_request = authentik_client.UserOAuthSourceConnectionRequest() # UserOAuthSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_oauth_update(id, user_o_auth_source_connection_request) + print("The response of SourcesApi->sources_user_connections_oauth_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_oauth_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User OAuth Source Connection. | + **user_o_auth_source_connection_request** | [**UserOAuthSourceConnectionRequest**](UserOAuthSourceConnectionRequest.md)| | + +### Return type + +[**UserOAuthSourceConnection**](UserOAuthSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_oauth_used_by_list** +> List[UsedBy] sources_user_connections_oauth_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User OAuth Source Connection. + + try: + api_response = api_instance.sources_user_connections_oauth_used_by_list(id) + print("The response of SourcesApi->sources_user_connections_oauth_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_oauth_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User OAuth Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_plex_create** +> UserPlexSourceConnection sources_user_connections_plex_create(user_plex_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection +from authentik_client.models.user_plex_source_connection_request import UserPlexSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + user_plex_source_connection_request = authentik_client.UserPlexSourceConnectionRequest() # UserPlexSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_plex_create(user_plex_source_connection_request) + print("The response of SourcesApi->sources_user_connections_plex_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_plex_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_plex_source_connection_request** | [**UserPlexSourceConnectionRequest**](UserPlexSourceConnectionRequest.md)| | + +### Return type + +[**UserPlexSourceConnection**](UserPlexSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_plex_destroy** +> sources_user_connections_plex_destroy(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Plex Source Connection. + + try: + api_instance.sources_user_connections_plex_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_plex_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Plex Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_plex_list** +> PaginatedUserPlexSourceConnectionList sources_user_connections_plex_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_plex_source_connection_list import PaginatedUserPlexSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.sources_user_connections_plex_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + print("The response of SourcesApi->sources_user_connections_plex_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_plex_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedUserPlexSourceConnectionList**](PaginatedUserPlexSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_plex_partial_update** +> UserPlexSourceConnection sources_user_connections_plex_partial_update(id, patched_user_plex_source_connection_request=patched_user_plex_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_plex_source_connection_request import PatchedUserPlexSourceConnectionRequest +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Plex Source Connection. + patched_user_plex_source_connection_request = authentik_client.PatchedUserPlexSourceConnectionRequest() # PatchedUserPlexSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_user_connections_plex_partial_update(id, patched_user_plex_source_connection_request=patched_user_plex_source_connection_request) + print("The response of SourcesApi->sources_user_connections_plex_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_plex_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Plex Source Connection. | + **patched_user_plex_source_connection_request** | [**PatchedUserPlexSourceConnectionRequest**](PatchedUserPlexSourceConnectionRequest.md)| | [optional] + +### Return type + +[**UserPlexSourceConnection**](UserPlexSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_plex_retrieve** +> UserPlexSourceConnection sources_user_connections_plex_retrieve(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Plex Source Connection. + + try: + api_response = api_instance.sources_user_connections_plex_retrieve(id) + print("The response of SourcesApi->sources_user_connections_plex_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_plex_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Plex Source Connection. | + +### Return type + +[**UserPlexSourceConnection**](UserPlexSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_plex_update** +> UserPlexSourceConnection sources_user_connections_plex_update(id, user_plex_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection +from authentik_client.models.user_plex_source_connection_request import UserPlexSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Plex Source Connection. + user_plex_source_connection_request = authentik_client.UserPlexSourceConnectionRequest() # UserPlexSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_plex_update(id, user_plex_source_connection_request) + print("The response of SourcesApi->sources_user_connections_plex_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_plex_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Plex Source Connection. | + **user_plex_source_connection_request** | [**UserPlexSourceConnectionRequest**](UserPlexSourceConnectionRequest.md)| | + +### Return type + +[**UserPlexSourceConnection**](UserPlexSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_plex_used_by_list** +> List[UsedBy] sources_user_connections_plex_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Plex Source Connection. + + try: + api_response = api_instance.sources_user_connections_plex_used_by_list(id) + print("The response of SourcesApi->sources_user_connections_plex_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_plex_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Plex Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_saml_create** +> UserSAMLSourceConnection sources_user_connections_saml_create(user_saml_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection +from authentik_client.models.user_saml_source_connection_request import UserSAMLSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + user_saml_source_connection_request = authentik_client.UserSAMLSourceConnectionRequest() # UserSAMLSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_saml_create(user_saml_source_connection_request) + print("The response of SourcesApi->sources_user_connections_saml_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_saml_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_saml_source_connection_request** | [**UserSAMLSourceConnectionRequest**](UserSAMLSourceConnectionRequest.md)| | + +### Return type + +[**UserSAMLSourceConnection**](UserSAMLSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_saml_destroy** +> sources_user_connections_saml_destroy(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User SAML Source Connection. + + try: + api_instance.sources_user_connections_saml_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_saml_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User SAML Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_saml_list** +> PaginatedUserSAMLSourceConnectionList sources_user_connections_saml_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_saml_source_connection_list import PaginatedUserSAMLSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.sources_user_connections_saml_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + print("The response of SourcesApi->sources_user_connections_saml_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_saml_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedUserSAMLSourceConnectionList**](PaginatedUserSAMLSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_saml_partial_update** +> UserSAMLSourceConnection sources_user_connections_saml_partial_update(id, patched_user_saml_source_connection_request=patched_user_saml_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_saml_source_connection_request import PatchedUserSAMLSourceConnectionRequest +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User SAML Source Connection. + patched_user_saml_source_connection_request = authentik_client.PatchedUserSAMLSourceConnectionRequest() # PatchedUserSAMLSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_user_connections_saml_partial_update(id, patched_user_saml_source_connection_request=patched_user_saml_source_connection_request) + print("The response of SourcesApi->sources_user_connections_saml_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_saml_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User SAML Source Connection. | + **patched_user_saml_source_connection_request** | [**PatchedUserSAMLSourceConnectionRequest**](PatchedUserSAMLSourceConnectionRequest.md)| | [optional] + +### Return type + +[**UserSAMLSourceConnection**](UserSAMLSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_saml_retrieve** +> UserSAMLSourceConnection sources_user_connections_saml_retrieve(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User SAML Source Connection. + + try: + api_response = api_instance.sources_user_connections_saml_retrieve(id) + print("The response of SourcesApi->sources_user_connections_saml_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_saml_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User SAML Source Connection. | + +### Return type + +[**UserSAMLSourceConnection**](UserSAMLSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_saml_update** +> UserSAMLSourceConnection sources_user_connections_saml_update(id, user_saml_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection +from authentik_client.models.user_saml_source_connection_request import UserSAMLSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User SAML Source Connection. + user_saml_source_connection_request = authentik_client.UserSAMLSourceConnectionRequest() # UserSAMLSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_saml_update(id, user_saml_source_connection_request) + print("The response of SourcesApi->sources_user_connections_saml_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_saml_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User SAML Source Connection. | + **user_saml_source_connection_request** | [**UserSAMLSourceConnectionRequest**](UserSAMLSourceConnectionRequest.md)| | + +### Return type + +[**UserSAMLSourceConnection**](UserSAMLSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_saml_used_by_list** +> List[UsedBy] sources_user_connections_saml_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User SAML Source Connection. + + try: + api_response = api_instance.sources_user_connections_saml_used_by_list(id) + print("The response of SourcesApi->sources_user_connections_saml_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_saml_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User SAML Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_telegram_create** +> UserTelegramSourceConnection sources_user_connections_telegram_create(user_telegram_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection +from authentik_client.models.user_telegram_source_connection_request import UserTelegramSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + user_telegram_source_connection_request = authentik_client.UserTelegramSourceConnectionRequest() # UserTelegramSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_telegram_create(user_telegram_source_connection_request) + print("The response of SourcesApi->sources_user_connections_telegram_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_telegram_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_telegram_source_connection_request** | [**UserTelegramSourceConnectionRequest**](UserTelegramSourceConnectionRequest.md)| | + +### Return type + +[**UserTelegramSourceConnection**](UserTelegramSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_telegram_destroy** +> sources_user_connections_telegram_destroy(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Telegram Source Connection. + + try: + api_instance.sources_user_connections_telegram_destroy(id) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_telegram_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Telegram Source Connection. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_telegram_list** +> PaginatedUserTelegramSourceConnectionList sources_user_connections_telegram_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_telegram_source_connection_list import PaginatedUserTelegramSourceConnectionList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + source__slug = 'source__slug_example' # str | (optional) + user = 56 # int | (optional) + + try: + api_response = api_instance.sources_user_connections_telegram_list(ordering=ordering, page=page, page_size=page_size, search=search, source__slug=source__slug, user=user) + print("The response of SourcesApi->sources_user_connections_telegram_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_telegram_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **source__slug** | **str**| | [optional] + **user** | **int**| | [optional] + +### Return type + +[**PaginatedUserTelegramSourceConnectionList**](PaginatedUserTelegramSourceConnectionList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_telegram_partial_update** +> UserTelegramSourceConnection sources_user_connections_telegram_partial_update(id, patched_user_telegram_source_connection_request=patched_user_telegram_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_telegram_source_connection_request import PatchedUserTelegramSourceConnectionRequest +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Telegram Source Connection. + patched_user_telegram_source_connection_request = authentik_client.PatchedUserTelegramSourceConnectionRequest() # PatchedUserTelegramSourceConnectionRequest | (optional) + + try: + api_response = api_instance.sources_user_connections_telegram_partial_update(id, patched_user_telegram_source_connection_request=patched_user_telegram_source_connection_request) + print("The response of SourcesApi->sources_user_connections_telegram_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_telegram_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Telegram Source Connection. | + **patched_user_telegram_source_connection_request** | [**PatchedUserTelegramSourceConnectionRequest**](PatchedUserTelegramSourceConnectionRequest.md)| | [optional] + +### Return type + +[**UserTelegramSourceConnection**](UserTelegramSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_telegram_retrieve** +> UserTelegramSourceConnection sources_user_connections_telegram_retrieve(id) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Telegram Source Connection. + + try: + api_response = api_instance.sources_user_connections_telegram_retrieve(id) + print("The response of SourcesApi->sources_user_connections_telegram_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_telegram_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Telegram Source Connection. | + +### Return type + +[**UserTelegramSourceConnection**](UserTelegramSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_telegram_update** +> UserTelegramSourceConnection sources_user_connections_telegram_update(id, user_telegram_source_connection_request) + +User-source connection Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection +from authentik_client.models.user_telegram_source_connection_request import UserTelegramSourceConnectionRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Telegram Source Connection. + user_telegram_source_connection_request = authentik_client.UserTelegramSourceConnectionRequest() # UserTelegramSourceConnectionRequest | + + try: + api_response = api_instance.sources_user_connections_telegram_update(id, user_telegram_source_connection_request) + print("The response of SourcesApi->sources_user_connections_telegram_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_telegram_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Telegram Source Connection. | + **user_telegram_source_connection_request** | [**UserTelegramSourceConnectionRequest**](UserTelegramSourceConnectionRequest.md)| | + +### Return type + +[**UserTelegramSourceConnection**](UserTelegramSourceConnection.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **sources_user_connections_telegram_used_by_list** +> List[UsedBy] sources_user_connections_telegram_used_by_list(id) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SourcesApi(api_client) + id = 56 # int | A unique integer value identifying this User Telegram Source Connection. + + try: + api_response = api_instance.sources_user_connections_telegram_used_by_list(id) + print("The response of SourcesApi->sources_user_connections_telegram_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SourcesApi->sources_user_connections_telegram_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this User Telegram Source Connection. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/SsfApi.md b/docs/SsfApi.md new file mode 100644 index 000000000..01adfe3a7 --- /dev/null +++ b/docs/SsfApi.md @@ -0,0 +1,252 @@ +# authentik_client.SsfApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**ssf_streams_destroy**](SsfApi.md#ssf_streams_destroy) | **DELETE** /ssf/streams/{uuid}/ | +[**ssf_streams_list**](SsfApi.md#ssf_streams_list) | **GET** /ssf/streams/ | +[**ssf_streams_retrieve**](SsfApi.md#ssf_streams_retrieve) | **GET** /ssf/streams/{uuid}/ | + + +# **ssf_streams_destroy** +> ssf_streams_destroy(uuid) + +SSFStream Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SsfApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SSF Stream. + + try: + api_instance.ssf_streams_destroy(uuid) + except Exception as e: + print("Exception when calling SsfApi->ssf_streams_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this SSF Stream. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **ssf_streams_list** +> PaginatedSSFStreamList ssf_streams_list(delivery_method=delivery_method, endpoint_url=endpoint_url, ordering=ordering, page=page, page_size=page_size, provider=provider, search=search) + +SSFStream Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.delivery_method_enum import DeliveryMethodEnum +from authentik_client.models.paginated_ssf_stream_list import PaginatedSSFStreamList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SsfApi(api_client) + delivery_method = authentik_client.DeliveryMethodEnum() # DeliveryMethodEnum | (optional) + endpoint_url = 'endpoint_url_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.ssf_streams_list(delivery_method=delivery_method, endpoint_url=endpoint_url, ordering=ordering, page=page, page_size=page_size, provider=provider, search=search) + print("The response of SsfApi->ssf_streams_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SsfApi->ssf_streams_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **delivery_method** | [**DeliveryMethodEnum**](.md)| | [optional] + **endpoint_url** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedSSFStreamList**](PaginatedSSFStreamList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **ssf_streams_retrieve** +> SSFStream ssf_streams_retrieve(uuid) + +SSFStream Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.ssf_stream import SSFStream +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.SsfApi(api_client) + uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SSF Stream. + + try: + api_response = api_instance.ssf_streams_retrieve(uuid) + print("The response of SsfApi->ssf_streams_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling SsfApi->ssf_streams_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **uuid** | **UUID**| A UUID string identifying this SSF Stream. | + +### Return type + +[**SSFStream**](SSFStream.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/Stage.md b/docs/Stage.md new file mode 100644 index 000000000..ae79965f6 --- /dev/null +++ b/docs/Stage.md @@ -0,0 +1,36 @@ +# Stage + +Stage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] + +## Example + +```python +from authentik_client.models.stage import Stage + +# TODO update the JSON string below +json = "{}" +# create an instance of Stage from a JSON string +stage_instance = Stage.from_json(json) +# print the JSON string representation of the object +print(Stage.to_json()) + +# convert the object into a dict +stage_dict = stage_instance.to_dict() +# create an instance of Stage from a dict +stage_from_dict = Stage.from_dict(stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/StageModeEnum.md b/docs/StageModeEnum.md new file mode 100644 index 000000000..1152c3612 --- /dev/null +++ b/docs/StageModeEnum.md @@ -0,0 +1,12 @@ +# StageModeEnum + + +## Enum + +* `OPTIONAL` (value: `'optional'`) + +* `REQUIRED` (value: `'required'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/StagePrompt.md b/docs/StagePrompt.md new file mode 100644 index 000000000..25852c9bd --- /dev/null +++ b/docs/StagePrompt.md @@ -0,0 +1,38 @@ +# StagePrompt + +Serializer for a single Prompt field + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**field_key** | **str** | | +**label** | **str** | | +**type** | [**PromptTypeEnum**](PromptTypeEnum.md) | | +**required** | **bool** | | +**placeholder** | **str** | | +**initial_value** | **str** | | +**order** | **int** | | +**sub_text** | **str** | | +**choices** | [**List[PromptChoice]**](PromptChoice.md) | | + +## Example + +```python +from authentik_client.models.stage_prompt import StagePrompt + +# TODO update the JSON string below +json = "{}" +# create an instance of StagePrompt from a JSON string +stage_prompt_instance = StagePrompt.from_json(json) +# print the JSON string representation of the object +print(StagePrompt.to_json()) + +# convert the object into a dict +stage_prompt_dict = stage_prompt_instance.to_dict() +# create an instance of StagePrompt from a dict +stage_prompt_from_dict = StagePrompt.from_dict(stage_prompt_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/StagesApi.md b/docs/StagesApi.md new file mode 100644 index 000000000..7b52fd77f --- /dev/null +++ b/docs/StagesApi.md @@ -0,0 +1,16974 @@ +# authentik_client.StagesApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**stages_account_lockdown_create**](StagesApi.md#stages_account_lockdown_create) | **POST** /stages/account_lockdown/ | +[**stages_account_lockdown_destroy**](StagesApi.md#stages_account_lockdown_destroy) | **DELETE** /stages/account_lockdown/{stage_uuid}/ | +[**stages_account_lockdown_list**](StagesApi.md#stages_account_lockdown_list) | **GET** /stages/account_lockdown/ | +[**stages_account_lockdown_partial_update**](StagesApi.md#stages_account_lockdown_partial_update) | **PATCH** /stages/account_lockdown/{stage_uuid}/ | +[**stages_account_lockdown_retrieve**](StagesApi.md#stages_account_lockdown_retrieve) | **GET** /stages/account_lockdown/{stage_uuid}/ | +[**stages_account_lockdown_update**](StagesApi.md#stages_account_lockdown_update) | **PUT** /stages/account_lockdown/{stage_uuid}/ | +[**stages_account_lockdown_used_by_list**](StagesApi.md#stages_account_lockdown_used_by_list) | **GET** /stages/account_lockdown/{stage_uuid}/used_by/ | +[**stages_all_destroy**](StagesApi.md#stages_all_destroy) | **DELETE** /stages/all/{stage_uuid}/ | +[**stages_all_list**](StagesApi.md#stages_all_list) | **GET** /stages/all/ | +[**stages_all_retrieve**](StagesApi.md#stages_all_retrieve) | **GET** /stages/all/{stage_uuid}/ | +[**stages_all_types_list**](StagesApi.md#stages_all_types_list) | **GET** /stages/all/types/ | +[**stages_all_used_by_list**](StagesApi.md#stages_all_used_by_list) | **GET** /stages/all/{stage_uuid}/used_by/ | +[**stages_all_user_settings_list**](StagesApi.md#stages_all_user_settings_list) | **GET** /stages/all/user_settings/ | +[**stages_authenticator_duo_create**](StagesApi.md#stages_authenticator_duo_create) | **POST** /stages/authenticator/duo/ | +[**stages_authenticator_duo_destroy**](StagesApi.md#stages_authenticator_duo_destroy) | **DELETE** /stages/authenticator/duo/{stage_uuid}/ | +[**stages_authenticator_duo_enrollment_status_create**](StagesApi.md#stages_authenticator_duo_enrollment_status_create) | **POST** /stages/authenticator/duo/{stage_uuid}/enrollment_status/ | +[**stages_authenticator_duo_import_device_manual_create**](StagesApi.md#stages_authenticator_duo_import_device_manual_create) | **POST** /stages/authenticator/duo/{stage_uuid}/import_device_manual/ | +[**stages_authenticator_duo_import_devices_automatic_create**](StagesApi.md#stages_authenticator_duo_import_devices_automatic_create) | **POST** /stages/authenticator/duo/{stage_uuid}/import_devices_automatic/ | +[**stages_authenticator_duo_list**](StagesApi.md#stages_authenticator_duo_list) | **GET** /stages/authenticator/duo/ | +[**stages_authenticator_duo_partial_update**](StagesApi.md#stages_authenticator_duo_partial_update) | **PATCH** /stages/authenticator/duo/{stage_uuid}/ | +[**stages_authenticator_duo_retrieve**](StagesApi.md#stages_authenticator_duo_retrieve) | **GET** /stages/authenticator/duo/{stage_uuid}/ | +[**stages_authenticator_duo_update**](StagesApi.md#stages_authenticator_duo_update) | **PUT** /stages/authenticator/duo/{stage_uuid}/ | +[**stages_authenticator_duo_used_by_list**](StagesApi.md#stages_authenticator_duo_used_by_list) | **GET** /stages/authenticator/duo/{stage_uuid}/used_by/ | +[**stages_authenticator_email_create**](StagesApi.md#stages_authenticator_email_create) | **POST** /stages/authenticator/email/ | +[**stages_authenticator_email_destroy**](StagesApi.md#stages_authenticator_email_destroy) | **DELETE** /stages/authenticator/email/{stage_uuid}/ | +[**stages_authenticator_email_list**](StagesApi.md#stages_authenticator_email_list) | **GET** /stages/authenticator/email/ | +[**stages_authenticator_email_partial_update**](StagesApi.md#stages_authenticator_email_partial_update) | **PATCH** /stages/authenticator/email/{stage_uuid}/ | +[**stages_authenticator_email_retrieve**](StagesApi.md#stages_authenticator_email_retrieve) | **GET** /stages/authenticator/email/{stage_uuid}/ | +[**stages_authenticator_email_update**](StagesApi.md#stages_authenticator_email_update) | **PUT** /stages/authenticator/email/{stage_uuid}/ | +[**stages_authenticator_email_used_by_list**](StagesApi.md#stages_authenticator_email_used_by_list) | **GET** /stages/authenticator/email/{stage_uuid}/used_by/ | +[**stages_authenticator_endpoint_gdtc_create**](StagesApi.md#stages_authenticator_endpoint_gdtc_create) | **POST** /stages/authenticator/endpoint_gdtc/ | +[**stages_authenticator_endpoint_gdtc_destroy**](StagesApi.md#stages_authenticator_endpoint_gdtc_destroy) | **DELETE** /stages/authenticator/endpoint_gdtc/{stage_uuid}/ | +[**stages_authenticator_endpoint_gdtc_list**](StagesApi.md#stages_authenticator_endpoint_gdtc_list) | **GET** /stages/authenticator/endpoint_gdtc/ | +[**stages_authenticator_endpoint_gdtc_partial_update**](StagesApi.md#stages_authenticator_endpoint_gdtc_partial_update) | **PATCH** /stages/authenticator/endpoint_gdtc/{stage_uuid}/ | +[**stages_authenticator_endpoint_gdtc_retrieve**](StagesApi.md#stages_authenticator_endpoint_gdtc_retrieve) | **GET** /stages/authenticator/endpoint_gdtc/{stage_uuid}/ | +[**stages_authenticator_endpoint_gdtc_update**](StagesApi.md#stages_authenticator_endpoint_gdtc_update) | **PUT** /stages/authenticator/endpoint_gdtc/{stage_uuid}/ | +[**stages_authenticator_endpoint_gdtc_used_by_list**](StagesApi.md#stages_authenticator_endpoint_gdtc_used_by_list) | **GET** /stages/authenticator/endpoint_gdtc/{stage_uuid}/used_by/ | +[**stages_authenticator_sms_create**](StagesApi.md#stages_authenticator_sms_create) | **POST** /stages/authenticator/sms/ | +[**stages_authenticator_sms_destroy**](StagesApi.md#stages_authenticator_sms_destroy) | **DELETE** /stages/authenticator/sms/{stage_uuid}/ | +[**stages_authenticator_sms_list**](StagesApi.md#stages_authenticator_sms_list) | **GET** /stages/authenticator/sms/ | +[**stages_authenticator_sms_partial_update**](StagesApi.md#stages_authenticator_sms_partial_update) | **PATCH** /stages/authenticator/sms/{stage_uuid}/ | +[**stages_authenticator_sms_retrieve**](StagesApi.md#stages_authenticator_sms_retrieve) | **GET** /stages/authenticator/sms/{stage_uuid}/ | +[**stages_authenticator_sms_update**](StagesApi.md#stages_authenticator_sms_update) | **PUT** /stages/authenticator/sms/{stage_uuid}/ | +[**stages_authenticator_sms_used_by_list**](StagesApi.md#stages_authenticator_sms_used_by_list) | **GET** /stages/authenticator/sms/{stage_uuid}/used_by/ | +[**stages_authenticator_static_create**](StagesApi.md#stages_authenticator_static_create) | **POST** /stages/authenticator/static/ | +[**stages_authenticator_static_destroy**](StagesApi.md#stages_authenticator_static_destroy) | **DELETE** /stages/authenticator/static/{stage_uuid}/ | +[**stages_authenticator_static_list**](StagesApi.md#stages_authenticator_static_list) | **GET** /stages/authenticator/static/ | +[**stages_authenticator_static_partial_update**](StagesApi.md#stages_authenticator_static_partial_update) | **PATCH** /stages/authenticator/static/{stage_uuid}/ | +[**stages_authenticator_static_retrieve**](StagesApi.md#stages_authenticator_static_retrieve) | **GET** /stages/authenticator/static/{stage_uuid}/ | +[**stages_authenticator_static_update**](StagesApi.md#stages_authenticator_static_update) | **PUT** /stages/authenticator/static/{stage_uuid}/ | +[**stages_authenticator_static_used_by_list**](StagesApi.md#stages_authenticator_static_used_by_list) | **GET** /stages/authenticator/static/{stage_uuid}/used_by/ | +[**stages_authenticator_totp_create**](StagesApi.md#stages_authenticator_totp_create) | **POST** /stages/authenticator/totp/ | +[**stages_authenticator_totp_destroy**](StagesApi.md#stages_authenticator_totp_destroy) | **DELETE** /stages/authenticator/totp/{stage_uuid}/ | +[**stages_authenticator_totp_list**](StagesApi.md#stages_authenticator_totp_list) | **GET** /stages/authenticator/totp/ | +[**stages_authenticator_totp_partial_update**](StagesApi.md#stages_authenticator_totp_partial_update) | **PATCH** /stages/authenticator/totp/{stage_uuid}/ | +[**stages_authenticator_totp_retrieve**](StagesApi.md#stages_authenticator_totp_retrieve) | **GET** /stages/authenticator/totp/{stage_uuid}/ | +[**stages_authenticator_totp_update**](StagesApi.md#stages_authenticator_totp_update) | **PUT** /stages/authenticator/totp/{stage_uuid}/ | +[**stages_authenticator_totp_used_by_list**](StagesApi.md#stages_authenticator_totp_used_by_list) | **GET** /stages/authenticator/totp/{stage_uuid}/used_by/ | +[**stages_authenticator_validate_create**](StagesApi.md#stages_authenticator_validate_create) | **POST** /stages/authenticator/validate/ | +[**stages_authenticator_validate_destroy**](StagesApi.md#stages_authenticator_validate_destroy) | **DELETE** /stages/authenticator/validate/{stage_uuid}/ | +[**stages_authenticator_validate_list**](StagesApi.md#stages_authenticator_validate_list) | **GET** /stages/authenticator/validate/ | +[**stages_authenticator_validate_partial_update**](StagesApi.md#stages_authenticator_validate_partial_update) | **PATCH** /stages/authenticator/validate/{stage_uuid}/ | +[**stages_authenticator_validate_retrieve**](StagesApi.md#stages_authenticator_validate_retrieve) | **GET** /stages/authenticator/validate/{stage_uuid}/ | +[**stages_authenticator_validate_update**](StagesApi.md#stages_authenticator_validate_update) | **PUT** /stages/authenticator/validate/{stage_uuid}/ | +[**stages_authenticator_validate_used_by_list**](StagesApi.md#stages_authenticator_validate_used_by_list) | **GET** /stages/authenticator/validate/{stage_uuid}/used_by/ | +[**stages_authenticator_webauthn_create**](StagesApi.md#stages_authenticator_webauthn_create) | **POST** /stages/authenticator/webauthn/ | +[**stages_authenticator_webauthn_destroy**](StagesApi.md#stages_authenticator_webauthn_destroy) | **DELETE** /stages/authenticator/webauthn/{stage_uuid}/ | +[**stages_authenticator_webauthn_device_types_list**](StagesApi.md#stages_authenticator_webauthn_device_types_list) | **GET** /stages/authenticator/webauthn_device_types/ | +[**stages_authenticator_webauthn_device_types_retrieve**](StagesApi.md#stages_authenticator_webauthn_device_types_retrieve) | **GET** /stages/authenticator/webauthn_device_types/{aaguid}/ | +[**stages_authenticator_webauthn_list**](StagesApi.md#stages_authenticator_webauthn_list) | **GET** /stages/authenticator/webauthn/ | +[**stages_authenticator_webauthn_partial_update**](StagesApi.md#stages_authenticator_webauthn_partial_update) | **PATCH** /stages/authenticator/webauthn/{stage_uuid}/ | +[**stages_authenticator_webauthn_retrieve**](StagesApi.md#stages_authenticator_webauthn_retrieve) | **GET** /stages/authenticator/webauthn/{stage_uuid}/ | +[**stages_authenticator_webauthn_update**](StagesApi.md#stages_authenticator_webauthn_update) | **PUT** /stages/authenticator/webauthn/{stage_uuid}/ | +[**stages_authenticator_webauthn_used_by_list**](StagesApi.md#stages_authenticator_webauthn_used_by_list) | **GET** /stages/authenticator/webauthn/{stage_uuid}/used_by/ | +[**stages_captcha_create**](StagesApi.md#stages_captcha_create) | **POST** /stages/captcha/ | +[**stages_captcha_destroy**](StagesApi.md#stages_captcha_destroy) | **DELETE** /stages/captcha/{stage_uuid}/ | +[**stages_captcha_list**](StagesApi.md#stages_captcha_list) | **GET** /stages/captcha/ | +[**stages_captcha_partial_update**](StagesApi.md#stages_captcha_partial_update) | **PATCH** /stages/captcha/{stage_uuid}/ | +[**stages_captcha_retrieve**](StagesApi.md#stages_captcha_retrieve) | **GET** /stages/captcha/{stage_uuid}/ | +[**stages_captcha_update**](StagesApi.md#stages_captcha_update) | **PUT** /stages/captcha/{stage_uuid}/ | +[**stages_captcha_used_by_list**](StagesApi.md#stages_captcha_used_by_list) | **GET** /stages/captcha/{stage_uuid}/used_by/ | +[**stages_consent_create**](StagesApi.md#stages_consent_create) | **POST** /stages/consent/ | +[**stages_consent_destroy**](StagesApi.md#stages_consent_destroy) | **DELETE** /stages/consent/{stage_uuid}/ | +[**stages_consent_list**](StagesApi.md#stages_consent_list) | **GET** /stages/consent/ | +[**stages_consent_partial_update**](StagesApi.md#stages_consent_partial_update) | **PATCH** /stages/consent/{stage_uuid}/ | +[**stages_consent_retrieve**](StagesApi.md#stages_consent_retrieve) | **GET** /stages/consent/{stage_uuid}/ | +[**stages_consent_update**](StagesApi.md#stages_consent_update) | **PUT** /stages/consent/{stage_uuid}/ | +[**stages_consent_used_by_list**](StagesApi.md#stages_consent_used_by_list) | **GET** /stages/consent/{stage_uuid}/used_by/ | +[**stages_deny_create**](StagesApi.md#stages_deny_create) | **POST** /stages/deny/ | +[**stages_deny_destroy**](StagesApi.md#stages_deny_destroy) | **DELETE** /stages/deny/{stage_uuid}/ | +[**stages_deny_list**](StagesApi.md#stages_deny_list) | **GET** /stages/deny/ | +[**stages_deny_partial_update**](StagesApi.md#stages_deny_partial_update) | **PATCH** /stages/deny/{stage_uuid}/ | +[**stages_deny_retrieve**](StagesApi.md#stages_deny_retrieve) | **GET** /stages/deny/{stage_uuid}/ | +[**stages_deny_update**](StagesApi.md#stages_deny_update) | **PUT** /stages/deny/{stage_uuid}/ | +[**stages_deny_used_by_list**](StagesApi.md#stages_deny_used_by_list) | **GET** /stages/deny/{stage_uuid}/used_by/ | +[**stages_dummy_create**](StagesApi.md#stages_dummy_create) | **POST** /stages/dummy/ | +[**stages_dummy_destroy**](StagesApi.md#stages_dummy_destroy) | **DELETE** /stages/dummy/{stage_uuid}/ | +[**stages_dummy_list**](StagesApi.md#stages_dummy_list) | **GET** /stages/dummy/ | +[**stages_dummy_partial_update**](StagesApi.md#stages_dummy_partial_update) | **PATCH** /stages/dummy/{stage_uuid}/ | +[**stages_dummy_retrieve**](StagesApi.md#stages_dummy_retrieve) | **GET** /stages/dummy/{stage_uuid}/ | +[**stages_dummy_update**](StagesApi.md#stages_dummy_update) | **PUT** /stages/dummy/{stage_uuid}/ | +[**stages_dummy_used_by_list**](StagesApi.md#stages_dummy_used_by_list) | **GET** /stages/dummy/{stage_uuid}/used_by/ | +[**stages_email_create**](StagesApi.md#stages_email_create) | **POST** /stages/email/ | +[**stages_email_destroy**](StagesApi.md#stages_email_destroy) | **DELETE** /stages/email/{stage_uuid}/ | +[**stages_email_list**](StagesApi.md#stages_email_list) | **GET** /stages/email/ | +[**stages_email_partial_update**](StagesApi.md#stages_email_partial_update) | **PATCH** /stages/email/{stage_uuid}/ | +[**stages_email_retrieve**](StagesApi.md#stages_email_retrieve) | **GET** /stages/email/{stage_uuid}/ | +[**stages_email_templates_list**](StagesApi.md#stages_email_templates_list) | **GET** /stages/email/templates/ | +[**stages_email_update**](StagesApi.md#stages_email_update) | **PUT** /stages/email/{stage_uuid}/ | +[**stages_email_used_by_list**](StagesApi.md#stages_email_used_by_list) | **GET** /stages/email/{stage_uuid}/used_by/ | +[**stages_endpoints_create**](StagesApi.md#stages_endpoints_create) | **POST** /stages/endpoints/ | +[**stages_endpoints_destroy**](StagesApi.md#stages_endpoints_destroy) | **DELETE** /stages/endpoints/{stage_uuid}/ | +[**stages_endpoints_list**](StagesApi.md#stages_endpoints_list) | **GET** /stages/endpoints/ | +[**stages_endpoints_partial_update**](StagesApi.md#stages_endpoints_partial_update) | **PATCH** /stages/endpoints/{stage_uuid}/ | +[**stages_endpoints_retrieve**](StagesApi.md#stages_endpoints_retrieve) | **GET** /stages/endpoints/{stage_uuid}/ | +[**stages_endpoints_update**](StagesApi.md#stages_endpoints_update) | **PUT** /stages/endpoints/{stage_uuid}/ | +[**stages_endpoints_used_by_list**](StagesApi.md#stages_endpoints_used_by_list) | **GET** /stages/endpoints/{stage_uuid}/used_by/ | +[**stages_identification_create**](StagesApi.md#stages_identification_create) | **POST** /stages/identification/ | +[**stages_identification_destroy**](StagesApi.md#stages_identification_destroy) | **DELETE** /stages/identification/{stage_uuid}/ | +[**stages_identification_list**](StagesApi.md#stages_identification_list) | **GET** /stages/identification/ | +[**stages_identification_partial_update**](StagesApi.md#stages_identification_partial_update) | **PATCH** /stages/identification/{stage_uuid}/ | +[**stages_identification_retrieve**](StagesApi.md#stages_identification_retrieve) | **GET** /stages/identification/{stage_uuid}/ | +[**stages_identification_update**](StagesApi.md#stages_identification_update) | **PUT** /stages/identification/{stage_uuid}/ | +[**stages_identification_used_by_list**](StagesApi.md#stages_identification_used_by_list) | **GET** /stages/identification/{stage_uuid}/used_by/ | +[**stages_invitation_invitations_create**](StagesApi.md#stages_invitation_invitations_create) | **POST** /stages/invitation/invitations/ | +[**stages_invitation_invitations_destroy**](StagesApi.md#stages_invitation_invitations_destroy) | **DELETE** /stages/invitation/invitations/{invite_uuid}/ | +[**stages_invitation_invitations_list**](StagesApi.md#stages_invitation_invitations_list) | **GET** /stages/invitation/invitations/ | +[**stages_invitation_invitations_partial_update**](StagesApi.md#stages_invitation_invitations_partial_update) | **PATCH** /stages/invitation/invitations/{invite_uuid}/ | +[**stages_invitation_invitations_retrieve**](StagesApi.md#stages_invitation_invitations_retrieve) | **GET** /stages/invitation/invitations/{invite_uuid}/ | +[**stages_invitation_invitations_send_email_create**](StagesApi.md#stages_invitation_invitations_send_email_create) | **POST** /stages/invitation/invitations/{invite_uuid}/send_email/ | +[**stages_invitation_invitations_update**](StagesApi.md#stages_invitation_invitations_update) | **PUT** /stages/invitation/invitations/{invite_uuid}/ | +[**stages_invitation_invitations_used_by_list**](StagesApi.md#stages_invitation_invitations_used_by_list) | **GET** /stages/invitation/invitations/{invite_uuid}/used_by/ | +[**stages_invitation_stages_create**](StagesApi.md#stages_invitation_stages_create) | **POST** /stages/invitation/stages/ | +[**stages_invitation_stages_destroy**](StagesApi.md#stages_invitation_stages_destroy) | **DELETE** /stages/invitation/stages/{stage_uuid}/ | +[**stages_invitation_stages_list**](StagesApi.md#stages_invitation_stages_list) | **GET** /stages/invitation/stages/ | +[**stages_invitation_stages_partial_update**](StagesApi.md#stages_invitation_stages_partial_update) | **PATCH** /stages/invitation/stages/{stage_uuid}/ | +[**stages_invitation_stages_retrieve**](StagesApi.md#stages_invitation_stages_retrieve) | **GET** /stages/invitation/stages/{stage_uuid}/ | +[**stages_invitation_stages_update**](StagesApi.md#stages_invitation_stages_update) | **PUT** /stages/invitation/stages/{stage_uuid}/ | +[**stages_invitation_stages_used_by_list**](StagesApi.md#stages_invitation_stages_used_by_list) | **GET** /stages/invitation/stages/{stage_uuid}/used_by/ | +[**stages_mtls_create**](StagesApi.md#stages_mtls_create) | **POST** /stages/mtls/ | +[**stages_mtls_destroy**](StagesApi.md#stages_mtls_destroy) | **DELETE** /stages/mtls/{stage_uuid}/ | +[**stages_mtls_list**](StagesApi.md#stages_mtls_list) | **GET** /stages/mtls/ | +[**stages_mtls_partial_update**](StagesApi.md#stages_mtls_partial_update) | **PATCH** /stages/mtls/{stage_uuid}/ | +[**stages_mtls_retrieve**](StagesApi.md#stages_mtls_retrieve) | **GET** /stages/mtls/{stage_uuid}/ | +[**stages_mtls_update**](StagesApi.md#stages_mtls_update) | **PUT** /stages/mtls/{stage_uuid}/ | +[**stages_mtls_used_by_list**](StagesApi.md#stages_mtls_used_by_list) | **GET** /stages/mtls/{stage_uuid}/used_by/ | +[**stages_password_create**](StagesApi.md#stages_password_create) | **POST** /stages/password/ | +[**stages_password_destroy**](StagesApi.md#stages_password_destroy) | **DELETE** /stages/password/{stage_uuid}/ | +[**stages_password_list**](StagesApi.md#stages_password_list) | **GET** /stages/password/ | +[**stages_password_partial_update**](StagesApi.md#stages_password_partial_update) | **PATCH** /stages/password/{stage_uuid}/ | +[**stages_password_retrieve**](StagesApi.md#stages_password_retrieve) | **GET** /stages/password/{stage_uuid}/ | +[**stages_password_update**](StagesApi.md#stages_password_update) | **PUT** /stages/password/{stage_uuid}/ | +[**stages_password_used_by_list**](StagesApi.md#stages_password_used_by_list) | **GET** /stages/password/{stage_uuid}/used_by/ | +[**stages_prompt_prompts_create**](StagesApi.md#stages_prompt_prompts_create) | **POST** /stages/prompt/prompts/ | +[**stages_prompt_prompts_destroy**](StagesApi.md#stages_prompt_prompts_destroy) | **DELETE** /stages/prompt/prompts/{prompt_uuid}/ | +[**stages_prompt_prompts_list**](StagesApi.md#stages_prompt_prompts_list) | **GET** /stages/prompt/prompts/ | +[**stages_prompt_prompts_partial_update**](StagesApi.md#stages_prompt_prompts_partial_update) | **PATCH** /stages/prompt/prompts/{prompt_uuid}/ | +[**stages_prompt_prompts_preview_create**](StagesApi.md#stages_prompt_prompts_preview_create) | **POST** /stages/prompt/prompts/preview/ | +[**stages_prompt_prompts_retrieve**](StagesApi.md#stages_prompt_prompts_retrieve) | **GET** /stages/prompt/prompts/{prompt_uuid}/ | +[**stages_prompt_prompts_update**](StagesApi.md#stages_prompt_prompts_update) | **PUT** /stages/prompt/prompts/{prompt_uuid}/ | +[**stages_prompt_prompts_used_by_list**](StagesApi.md#stages_prompt_prompts_used_by_list) | **GET** /stages/prompt/prompts/{prompt_uuid}/used_by/ | +[**stages_prompt_stages_create**](StagesApi.md#stages_prompt_stages_create) | **POST** /stages/prompt/stages/ | +[**stages_prompt_stages_destroy**](StagesApi.md#stages_prompt_stages_destroy) | **DELETE** /stages/prompt/stages/{stage_uuid}/ | +[**stages_prompt_stages_list**](StagesApi.md#stages_prompt_stages_list) | **GET** /stages/prompt/stages/ | +[**stages_prompt_stages_partial_update**](StagesApi.md#stages_prompt_stages_partial_update) | **PATCH** /stages/prompt/stages/{stage_uuid}/ | +[**stages_prompt_stages_retrieve**](StagesApi.md#stages_prompt_stages_retrieve) | **GET** /stages/prompt/stages/{stage_uuid}/ | +[**stages_prompt_stages_update**](StagesApi.md#stages_prompt_stages_update) | **PUT** /stages/prompt/stages/{stage_uuid}/ | +[**stages_prompt_stages_used_by_list**](StagesApi.md#stages_prompt_stages_used_by_list) | **GET** /stages/prompt/stages/{stage_uuid}/used_by/ | +[**stages_redirect_create**](StagesApi.md#stages_redirect_create) | **POST** /stages/redirect/ | +[**stages_redirect_destroy**](StagesApi.md#stages_redirect_destroy) | **DELETE** /stages/redirect/{stage_uuid}/ | +[**stages_redirect_list**](StagesApi.md#stages_redirect_list) | **GET** /stages/redirect/ | +[**stages_redirect_partial_update**](StagesApi.md#stages_redirect_partial_update) | **PATCH** /stages/redirect/{stage_uuid}/ | +[**stages_redirect_retrieve**](StagesApi.md#stages_redirect_retrieve) | **GET** /stages/redirect/{stage_uuid}/ | +[**stages_redirect_update**](StagesApi.md#stages_redirect_update) | **PUT** /stages/redirect/{stage_uuid}/ | +[**stages_redirect_used_by_list**](StagesApi.md#stages_redirect_used_by_list) | **GET** /stages/redirect/{stage_uuid}/used_by/ | +[**stages_source_create**](StagesApi.md#stages_source_create) | **POST** /stages/source/ | +[**stages_source_destroy**](StagesApi.md#stages_source_destroy) | **DELETE** /stages/source/{stage_uuid}/ | +[**stages_source_list**](StagesApi.md#stages_source_list) | **GET** /stages/source/ | +[**stages_source_partial_update**](StagesApi.md#stages_source_partial_update) | **PATCH** /stages/source/{stage_uuid}/ | +[**stages_source_retrieve**](StagesApi.md#stages_source_retrieve) | **GET** /stages/source/{stage_uuid}/ | +[**stages_source_update**](StagesApi.md#stages_source_update) | **PUT** /stages/source/{stage_uuid}/ | +[**stages_source_used_by_list**](StagesApi.md#stages_source_used_by_list) | **GET** /stages/source/{stage_uuid}/used_by/ | +[**stages_user_delete_create**](StagesApi.md#stages_user_delete_create) | **POST** /stages/user_delete/ | +[**stages_user_delete_destroy**](StagesApi.md#stages_user_delete_destroy) | **DELETE** /stages/user_delete/{stage_uuid}/ | +[**stages_user_delete_list**](StagesApi.md#stages_user_delete_list) | **GET** /stages/user_delete/ | +[**stages_user_delete_partial_update**](StagesApi.md#stages_user_delete_partial_update) | **PATCH** /stages/user_delete/{stage_uuid}/ | +[**stages_user_delete_retrieve**](StagesApi.md#stages_user_delete_retrieve) | **GET** /stages/user_delete/{stage_uuid}/ | +[**stages_user_delete_update**](StagesApi.md#stages_user_delete_update) | **PUT** /stages/user_delete/{stage_uuid}/ | +[**stages_user_delete_used_by_list**](StagesApi.md#stages_user_delete_used_by_list) | **GET** /stages/user_delete/{stage_uuid}/used_by/ | +[**stages_user_login_create**](StagesApi.md#stages_user_login_create) | **POST** /stages/user_login/ | +[**stages_user_login_destroy**](StagesApi.md#stages_user_login_destroy) | **DELETE** /stages/user_login/{stage_uuid}/ | +[**stages_user_login_list**](StagesApi.md#stages_user_login_list) | **GET** /stages/user_login/ | +[**stages_user_login_partial_update**](StagesApi.md#stages_user_login_partial_update) | **PATCH** /stages/user_login/{stage_uuid}/ | +[**stages_user_login_retrieve**](StagesApi.md#stages_user_login_retrieve) | **GET** /stages/user_login/{stage_uuid}/ | +[**stages_user_login_update**](StagesApi.md#stages_user_login_update) | **PUT** /stages/user_login/{stage_uuid}/ | +[**stages_user_login_used_by_list**](StagesApi.md#stages_user_login_used_by_list) | **GET** /stages/user_login/{stage_uuid}/used_by/ | +[**stages_user_logout_create**](StagesApi.md#stages_user_logout_create) | **POST** /stages/user_logout/ | +[**stages_user_logout_destroy**](StagesApi.md#stages_user_logout_destroy) | **DELETE** /stages/user_logout/{stage_uuid}/ | +[**stages_user_logout_list**](StagesApi.md#stages_user_logout_list) | **GET** /stages/user_logout/ | +[**stages_user_logout_partial_update**](StagesApi.md#stages_user_logout_partial_update) | **PATCH** /stages/user_logout/{stage_uuid}/ | +[**stages_user_logout_retrieve**](StagesApi.md#stages_user_logout_retrieve) | **GET** /stages/user_logout/{stage_uuid}/ | +[**stages_user_logout_update**](StagesApi.md#stages_user_logout_update) | **PUT** /stages/user_logout/{stage_uuid}/ | +[**stages_user_logout_used_by_list**](StagesApi.md#stages_user_logout_used_by_list) | **GET** /stages/user_logout/{stage_uuid}/used_by/ | +[**stages_user_write_create**](StagesApi.md#stages_user_write_create) | **POST** /stages/user_write/ | +[**stages_user_write_destroy**](StagesApi.md#stages_user_write_destroy) | **DELETE** /stages/user_write/{stage_uuid}/ | +[**stages_user_write_list**](StagesApi.md#stages_user_write_list) | **GET** /stages/user_write/ | +[**stages_user_write_partial_update**](StagesApi.md#stages_user_write_partial_update) | **PATCH** /stages/user_write/{stage_uuid}/ | +[**stages_user_write_retrieve**](StagesApi.md#stages_user_write_retrieve) | **GET** /stages/user_write/{stage_uuid}/ | +[**stages_user_write_update**](StagesApi.md#stages_user_write_update) | **PUT** /stages/user_write/{stage_uuid}/ | +[**stages_user_write_used_by_list**](StagesApi.md#stages_user_write_used_by_list) | **GET** /stages/user_write/{stage_uuid}/used_by/ | + + +# **stages_account_lockdown_create** +> AccountLockdownStage stages_account_lockdown_create(account_lockdown_stage_request) + +AccountLockdownStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.account_lockdown_stage import AccountLockdownStage +from authentik_client.models.account_lockdown_stage_request import AccountLockdownStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + account_lockdown_stage_request = authentik_client.AccountLockdownStageRequest() # AccountLockdownStageRequest | + + try: + api_response = api_instance.stages_account_lockdown_create(account_lockdown_stage_request) + print("The response of StagesApi->stages_account_lockdown_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_account_lockdown_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **account_lockdown_stage_request** | [**AccountLockdownStageRequest**](AccountLockdownStageRequest.md)| | + +### Return type + +[**AccountLockdownStage**](AccountLockdownStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_account_lockdown_destroy** +> stages_account_lockdown_destroy(stage_uuid) + +AccountLockdownStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Account Lockdown Stage. + + try: + api_instance.stages_account_lockdown_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_account_lockdown_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Account Lockdown Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_account_lockdown_list** +> PaginatedAccountLockdownStageList stages_account_lockdown_list(deactivate_user=deactivate_user, delete_sessions=delete_sessions, name=name, ordering=ordering, page=page, page_size=page_size, revoke_tokens=revoke_tokens, search=search, self_service_completion_flow=self_service_completion_flow, set_unusable_password=set_unusable_password, stage_uuid=stage_uuid) + +AccountLockdownStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_account_lockdown_stage_list import PaginatedAccountLockdownStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + deactivate_user = True # bool | (optional) + delete_sessions = True # bool | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + revoke_tokens = True # bool | (optional) + search = 'search_example' # str | A search term. (optional) + self_service_completion_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + set_unusable_password = True # bool | (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.stages_account_lockdown_list(deactivate_user=deactivate_user, delete_sessions=delete_sessions, name=name, ordering=ordering, page=page, page_size=page_size, revoke_tokens=revoke_tokens, search=search, self_service_completion_flow=self_service_completion_flow, set_unusable_password=set_unusable_password, stage_uuid=stage_uuid) + print("The response of StagesApi->stages_account_lockdown_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_account_lockdown_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deactivate_user** | **bool**| | [optional] + **delete_sessions** | **bool**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **revoke_tokens** | **bool**| | [optional] + **search** | **str**| A search term. | [optional] + **self_service_completion_flow** | **UUID**| | [optional] + **set_unusable_password** | **bool**| | [optional] + **stage_uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedAccountLockdownStageList**](PaginatedAccountLockdownStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_account_lockdown_partial_update** +> AccountLockdownStage stages_account_lockdown_partial_update(stage_uuid, patched_account_lockdown_stage_request=patched_account_lockdown_stage_request) + +AccountLockdownStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.account_lockdown_stage import AccountLockdownStage +from authentik_client.models.patched_account_lockdown_stage_request import PatchedAccountLockdownStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Account Lockdown Stage. + patched_account_lockdown_stage_request = authentik_client.PatchedAccountLockdownStageRequest() # PatchedAccountLockdownStageRequest | (optional) + + try: + api_response = api_instance.stages_account_lockdown_partial_update(stage_uuid, patched_account_lockdown_stage_request=patched_account_lockdown_stage_request) + print("The response of StagesApi->stages_account_lockdown_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_account_lockdown_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Account Lockdown Stage. | + **patched_account_lockdown_stage_request** | [**PatchedAccountLockdownStageRequest**](PatchedAccountLockdownStageRequest.md)| | [optional] + +### Return type + +[**AccountLockdownStage**](AccountLockdownStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_account_lockdown_retrieve** +> AccountLockdownStage stages_account_lockdown_retrieve(stage_uuid) + +AccountLockdownStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.account_lockdown_stage import AccountLockdownStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Account Lockdown Stage. + + try: + api_response = api_instance.stages_account_lockdown_retrieve(stage_uuid) + print("The response of StagesApi->stages_account_lockdown_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_account_lockdown_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Account Lockdown Stage. | + +### Return type + +[**AccountLockdownStage**](AccountLockdownStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_account_lockdown_update** +> AccountLockdownStage stages_account_lockdown_update(stage_uuid, account_lockdown_stage_request) + +AccountLockdownStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.account_lockdown_stage import AccountLockdownStage +from authentik_client.models.account_lockdown_stage_request import AccountLockdownStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Account Lockdown Stage. + account_lockdown_stage_request = authentik_client.AccountLockdownStageRequest() # AccountLockdownStageRequest | + + try: + api_response = api_instance.stages_account_lockdown_update(stage_uuid, account_lockdown_stage_request) + print("The response of StagesApi->stages_account_lockdown_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_account_lockdown_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Account Lockdown Stage. | + **account_lockdown_stage_request** | [**AccountLockdownStageRequest**](AccountLockdownStageRequest.md)| | + +### Return type + +[**AccountLockdownStage**](AccountLockdownStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_account_lockdown_used_by_list** +> List[UsedBy] stages_account_lockdown_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Account Lockdown Stage. + + try: + api_response = api_instance.stages_account_lockdown_used_by_list(stage_uuid) + print("The response of StagesApi->stages_account_lockdown_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_account_lockdown_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Account Lockdown Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_all_destroy** +> stages_all_destroy(stage_uuid) + +Stage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this stage. + + try: + api_instance.stages_all_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_all_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_all_list** +> PaginatedStageList stages_all_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Stage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_stage_list import PaginatedStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_all_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of StagesApi->stages_all_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_all_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedStageList**](PaginatedStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_all_retrieve** +> Stage stages_all_retrieve(stage_uuid) + +Stage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.stage import Stage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this stage. + + try: + api_response = api_instance.stages_all_retrieve(stage_uuid) + print("The response of StagesApi->stages_all_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_all_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this stage. | + +### Return type + +[**Stage**](Stage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_all_types_list** +> List[TypeCreate] stages_all_types_list() + +Get all creatable types + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.type_create import TypeCreate +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + + try: + api_response = api_instance.stages_all_types_list() + print("The response of StagesApi->stages_all_types_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_all_types_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[TypeCreate]**](TypeCreate.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_all_used_by_list** +> List[UsedBy] stages_all_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this stage. + + try: + api_response = api_instance.stages_all_used_by_list(stage_uuid) + print("The response of StagesApi->stages_all_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_all_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_all_user_settings_list** +> List[UserSetting] stages_all_user_settings_list() + +Get all stages the user can configure + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_setting import UserSetting +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + + try: + api_response = api_instance.stages_all_user_settings_list() + print("The response of StagesApi->stages_all_user_settings_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_all_user_settings_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[UserSetting]**](UserSetting.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_create** +> AuthenticatorDuoStage stages_authenticator_duo_create(authenticator_duo_stage_request) + +AuthenticatorDuoStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage +from authentik_client.models.authenticator_duo_stage_request import AuthenticatorDuoStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + authenticator_duo_stage_request = authentik_client.AuthenticatorDuoStageRequest() # AuthenticatorDuoStageRequest | + + try: + api_response = api_instance.stages_authenticator_duo_create(authenticator_duo_stage_request) + print("The response of StagesApi->stages_authenticator_duo_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authenticator_duo_stage_request** | [**AuthenticatorDuoStageRequest**](AuthenticatorDuoStageRequest.md)| | + +### Return type + +[**AuthenticatorDuoStage**](AuthenticatorDuoStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_destroy** +> stages_authenticator_duo_destroy(stage_uuid) + +AuthenticatorDuoStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Duo Authenticator Setup Stage. + + try: + api_instance.stages_authenticator_duo_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Duo Authenticator Setup Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_enrollment_status_create** +> DuoDeviceEnrollmentStatus stages_authenticator_duo_enrollment_status_create(stage_uuid) + +Check enrollment status of user details in current session + +### Example + + +```python +import authentik_client +from authentik_client.models.duo_device_enrollment_status import DuoDeviceEnrollmentStatus +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Duo Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_duo_enrollment_status_create(stage_uuid) + print("The response of StagesApi->stages_authenticator_duo_enrollment_status_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_enrollment_status_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Duo Authenticator Setup Stage. | + +### Return type + +[**DuoDeviceEnrollmentStatus**](DuoDeviceEnrollmentStatus.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_import_device_manual_create** +> stages_authenticator_duo_import_device_manual_create(stage_uuid, authenticator_duo_stage_manual_device_import_request) + +Import duo devices into authentik + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_duo_stage_manual_device_import_request import AuthenticatorDuoStageManualDeviceImportRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Duo Authenticator Setup Stage. + authenticator_duo_stage_manual_device_import_request = authentik_client.AuthenticatorDuoStageManualDeviceImportRequest() # AuthenticatorDuoStageManualDeviceImportRequest | + + try: + api_instance.stages_authenticator_duo_import_device_manual_create(stage_uuid, authenticator_duo_stage_manual_device_import_request) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_import_device_manual_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Duo Authenticator Setup Stage. | + **authenticator_duo_stage_manual_device_import_request** | [**AuthenticatorDuoStageManualDeviceImportRequest**](AuthenticatorDuoStageManualDeviceImportRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Enrollment successful | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_import_devices_automatic_create** +> AuthenticatorDuoStageDeviceImportResponse stages_authenticator_duo_import_devices_automatic_create(stage_uuid) + +Import duo devices into authentik + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_duo_stage_device_import_response import AuthenticatorDuoStageDeviceImportResponse +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Duo Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_duo_import_devices_automatic_create(stage_uuid) + print("The response of StagesApi->stages_authenticator_duo_import_devices_automatic_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_import_devices_automatic_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Duo Authenticator Setup Stage. | + +### Return type + +[**AuthenticatorDuoStageDeviceImportResponse**](AuthenticatorDuoStageDeviceImportResponse.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_list** +> PaginatedAuthenticatorDuoStageList stages_authenticator_duo_list(api_hostname=api_hostname, client_id=client_id, configure_flow=configure_flow, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +AuthenticatorDuoStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_authenticator_duo_stage_list import PaginatedAuthenticatorDuoStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + api_hostname = 'api_hostname_example' # str | (optional) + client_id = 'client_id_example' # str | (optional) + configure_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_authenticator_duo_list(api_hostname=api_hostname, client_id=client_id, configure_flow=configure_flow, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of StagesApi->stages_authenticator_duo_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **api_hostname** | **str**| | [optional] + **client_id** | **str**| | [optional] + **configure_flow** | **UUID**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedAuthenticatorDuoStageList**](PaginatedAuthenticatorDuoStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_partial_update** +> AuthenticatorDuoStage stages_authenticator_duo_partial_update(stage_uuid, patched_authenticator_duo_stage_request=patched_authenticator_duo_stage_request) + +AuthenticatorDuoStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage +from authentik_client.models.patched_authenticator_duo_stage_request import PatchedAuthenticatorDuoStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Duo Authenticator Setup Stage. + patched_authenticator_duo_stage_request = authentik_client.PatchedAuthenticatorDuoStageRequest() # PatchedAuthenticatorDuoStageRequest | (optional) + + try: + api_response = api_instance.stages_authenticator_duo_partial_update(stage_uuid, patched_authenticator_duo_stage_request=patched_authenticator_duo_stage_request) + print("The response of StagesApi->stages_authenticator_duo_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Duo Authenticator Setup Stage. | + **patched_authenticator_duo_stage_request** | [**PatchedAuthenticatorDuoStageRequest**](PatchedAuthenticatorDuoStageRequest.md)| | [optional] + +### Return type + +[**AuthenticatorDuoStage**](AuthenticatorDuoStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_retrieve** +> AuthenticatorDuoStage stages_authenticator_duo_retrieve(stage_uuid) + +AuthenticatorDuoStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Duo Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_duo_retrieve(stage_uuid) + print("The response of StagesApi->stages_authenticator_duo_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Duo Authenticator Setup Stage. | + +### Return type + +[**AuthenticatorDuoStage**](AuthenticatorDuoStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_update** +> AuthenticatorDuoStage stages_authenticator_duo_update(stage_uuid, authenticator_duo_stage_request) + +AuthenticatorDuoStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage +from authentik_client.models.authenticator_duo_stage_request import AuthenticatorDuoStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Duo Authenticator Setup Stage. + authenticator_duo_stage_request = authentik_client.AuthenticatorDuoStageRequest() # AuthenticatorDuoStageRequest | + + try: + api_response = api_instance.stages_authenticator_duo_update(stage_uuid, authenticator_duo_stage_request) + print("The response of StagesApi->stages_authenticator_duo_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Duo Authenticator Setup Stage. | + **authenticator_duo_stage_request** | [**AuthenticatorDuoStageRequest**](AuthenticatorDuoStageRequest.md)| | + +### Return type + +[**AuthenticatorDuoStage**](AuthenticatorDuoStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_duo_used_by_list** +> List[UsedBy] stages_authenticator_duo_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Duo Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_duo_used_by_list(stage_uuid) + print("The response of StagesApi->stages_authenticator_duo_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_duo_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Duo Authenticator Setup Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_email_create** +> AuthenticatorEmailStage stages_authenticator_email_create(authenticator_email_stage_request) + +AuthenticatorEmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage +from authentik_client.models.authenticator_email_stage_request import AuthenticatorEmailStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + authenticator_email_stage_request = authentik_client.AuthenticatorEmailStageRequest() # AuthenticatorEmailStageRequest | + + try: + api_response = api_instance.stages_authenticator_email_create(authenticator_email_stage_request) + print("The response of StagesApi->stages_authenticator_email_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_email_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authenticator_email_stage_request** | [**AuthenticatorEmailStageRequest**](AuthenticatorEmailStageRequest.md)| | + +### Return type + +[**AuthenticatorEmailStage**](AuthenticatorEmailStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_email_destroy** +> stages_authenticator_email_destroy(stage_uuid) + +AuthenticatorEmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Authenticator Setup Stage. + + try: + api_instance.stages_authenticator_email_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_email_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Authenticator Setup Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_email_list** +> PaginatedAuthenticatorEmailStageList stages_authenticator_email_list(configure_flow=configure_flow, friendly_name=friendly_name, from_address=from_address, host=host, name=name, ordering=ordering, page=page, page_size=page_size, password=password, port=port, search=search, stage_uuid=stage_uuid, subject=subject, template=template, timeout=timeout, token_expiry=token_expiry, use_global_settings=use_global_settings, use_ssl=use_ssl, use_tls=use_tls, username=username) + +AuthenticatorEmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_authenticator_email_stage_list import PaginatedAuthenticatorEmailStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + configure_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + friendly_name = 'friendly_name_example' # str | (optional) + from_address = 'from_address_example' # str | (optional) + host = 'host_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + password = 'password_example' # str | (optional) + port = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + subject = 'subject_example' # str | (optional) + template = 'template_example' # str | (optional) + timeout = 56 # int | (optional) + token_expiry = 'token_expiry_example' # str | (optional) + use_global_settings = True # bool | (optional) + use_ssl = True # bool | (optional) + use_tls = True # bool | (optional) + username = 'username_example' # str | (optional) + + try: + api_response = api_instance.stages_authenticator_email_list(configure_flow=configure_flow, friendly_name=friendly_name, from_address=from_address, host=host, name=name, ordering=ordering, page=page, page_size=page_size, password=password, port=port, search=search, stage_uuid=stage_uuid, subject=subject, template=template, timeout=timeout, token_expiry=token_expiry, use_global_settings=use_global_settings, use_ssl=use_ssl, use_tls=use_tls, username=username) + print("The response of StagesApi->stages_authenticator_email_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_email_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **configure_flow** | **UUID**| | [optional] + **friendly_name** | **str**| | [optional] + **from_address** | **str**| | [optional] + **host** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **password** | **str**| | [optional] + **port** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + **subject** | **str**| | [optional] + **template** | **str**| | [optional] + **timeout** | **int**| | [optional] + **token_expiry** | **str**| | [optional] + **use_global_settings** | **bool**| | [optional] + **use_ssl** | **bool**| | [optional] + **use_tls** | **bool**| | [optional] + **username** | **str**| | [optional] + +### Return type + +[**PaginatedAuthenticatorEmailStageList**](PaginatedAuthenticatorEmailStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_email_partial_update** +> AuthenticatorEmailStage stages_authenticator_email_partial_update(stage_uuid, patched_authenticator_email_stage_request=patched_authenticator_email_stage_request) + +AuthenticatorEmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage +from authentik_client.models.patched_authenticator_email_stage_request import PatchedAuthenticatorEmailStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Authenticator Setup Stage. + patched_authenticator_email_stage_request = authentik_client.PatchedAuthenticatorEmailStageRequest() # PatchedAuthenticatorEmailStageRequest | (optional) + + try: + api_response = api_instance.stages_authenticator_email_partial_update(stage_uuid, patched_authenticator_email_stage_request=patched_authenticator_email_stage_request) + print("The response of StagesApi->stages_authenticator_email_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_email_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Authenticator Setup Stage. | + **patched_authenticator_email_stage_request** | [**PatchedAuthenticatorEmailStageRequest**](PatchedAuthenticatorEmailStageRequest.md)| | [optional] + +### Return type + +[**AuthenticatorEmailStage**](AuthenticatorEmailStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_email_retrieve** +> AuthenticatorEmailStage stages_authenticator_email_retrieve(stage_uuid) + +AuthenticatorEmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_email_retrieve(stage_uuid) + print("The response of StagesApi->stages_authenticator_email_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_email_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Authenticator Setup Stage. | + +### Return type + +[**AuthenticatorEmailStage**](AuthenticatorEmailStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_email_update** +> AuthenticatorEmailStage stages_authenticator_email_update(stage_uuid, authenticator_email_stage_request) + +AuthenticatorEmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage +from authentik_client.models.authenticator_email_stage_request import AuthenticatorEmailStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Authenticator Setup Stage. + authenticator_email_stage_request = authentik_client.AuthenticatorEmailStageRequest() # AuthenticatorEmailStageRequest | + + try: + api_response = api_instance.stages_authenticator_email_update(stage_uuid, authenticator_email_stage_request) + print("The response of StagesApi->stages_authenticator_email_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_email_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Authenticator Setup Stage. | + **authenticator_email_stage_request** | [**AuthenticatorEmailStageRequest**](AuthenticatorEmailStageRequest.md)| | + +### Return type + +[**AuthenticatorEmailStage**](AuthenticatorEmailStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_email_used_by_list** +> List[UsedBy] stages_authenticator_email_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_email_used_by_list(stage_uuid) + print("The response of StagesApi->stages_authenticator_email_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_email_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Authenticator Setup Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_endpoint_gdtc_create** +> AuthenticatorEndpointGDTCStage stages_authenticator_endpoint_gdtc_create(authenticator_endpoint_gdtc_stage_request) + +AuthenticatorEndpointGDTCStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage +from authentik_client.models.authenticator_endpoint_gdtc_stage_request import AuthenticatorEndpointGDTCStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + authenticator_endpoint_gdtc_stage_request = authentik_client.AuthenticatorEndpointGDTCStageRequest() # AuthenticatorEndpointGDTCStageRequest | + + try: + api_response = api_instance.stages_authenticator_endpoint_gdtc_create(authenticator_endpoint_gdtc_stage_request) + print("The response of StagesApi->stages_authenticator_endpoint_gdtc_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_endpoint_gdtc_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authenticator_endpoint_gdtc_stage_request** | [**AuthenticatorEndpointGDTCStageRequest**](AuthenticatorEndpointGDTCStageRequest.md)| | + +### Return type + +[**AuthenticatorEndpointGDTCStage**](AuthenticatorEndpointGDTCStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_endpoint_gdtc_destroy** +> stages_authenticator_endpoint_gdtc_destroy(stage_uuid) + +AuthenticatorEndpointGDTCStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. + + try: + api_instance.stages_authenticator_endpoint_gdtc_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_endpoint_gdtc_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_endpoint_gdtc_list** +> PaginatedAuthenticatorEndpointGDTCStageList stages_authenticator_endpoint_gdtc_list(configure_flow=configure_flow, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +AuthenticatorEndpointGDTCStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_authenticator_endpoint_gdtc_stage_list import PaginatedAuthenticatorEndpointGDTCStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + configure_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_authenticator_endpoint_gdtc_list(configure_flow=configure_flow, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of StagesApi->stages_authenticator_endpoint_gdtc_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_endpoint_gdtc_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **configure_flow** | **UUID**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedAuthenticatorEndpointGDTCStageList**](PaginatedAuthenticatorEndpointGDTCStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_endpoint_gdtc_partial_update** +> AuthenticatorEndpointGDTCStage stages_authenticator_endpoint_gdtc_partial_update(stage_uuid, patched_authenticator_endpoint_gdtc_stage_request=patched_authenticator_endpoint_gdtc_stage_request) + +AuthenticatorEndpointGDTCStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage +from authentik_client.models.patched_authenticator_endpoint_gdtc_stage_request import PatchedAuthenticatorEndpointGDTCStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. + patched_authenticator_endpoint_gdtc_stage_request = authentik_client.PatchedAuthenticatorEndpointGDTCStageRequest() # PatchedAuthenticatorEndpointGDTCStageRequest | (optional) + + try: + api_response = api_instance.stages_authenticator_endpoint_gdtc_partial_update(stage_uuid, patched_authenticator_endpoint_gdtc_stage_request=patched_authenticator_endpoint_gdtc_stage_request) + print("The response of StagesApi->stages_authenticator_endpoint_gdtc_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_endpoint_gdtc_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. | + **patched_authenticator_endpoint_gdtc_stage_request** | [**PatchedAuthenticatorEndpointGDTCStageRequest**](PatchedAuthenticatorEndpointGDTCStageRequest.md)| | [optional] + +### Return type + +[**AuthenticatorEndpointGDTCStage**](AuthenticatorEndpointGDTCStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_endpoint_gdtc_retrieve** +> AuthenticatorEndpointGDTCStage stages_authenticator_endpoint_gdtc_retrieve(stage_uuid) + +AuthenticatorEndpointGDTCStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. + + try: + api_response = api_instance.stages_authenticator_endpoint_gdtc_retrieve(stage_uuid) + print("The response of StagesApi->stages_authenticator_endpoint_gdtc_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_endpoint_gdtc_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. | + +### Return type + +[**AuthenticatorEndpointGDTCStage**](AuthenticatorEndpointGDTCStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_endpoint_gdtc_update** +> AuthenticatorEndpointGDTCStage stages_authenticator_endpoint_gdtc_update(stage_uuid, authenticator_endpoint_gdtc_stage_request) + +AuthenticatorEndpointGDTCStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage +from authentik_client.models.authenticator_endpoint_gdtc_stage_request import AuthenticatorEndpointGDTCStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. + authenticator_endpoint_gdtc_stage_request = authentik_client.AuthenticatorEndpointGDTCStageRequest() # AuthenticatorEndpointGDTCStageRequest | + + try: + api_response = api_instance.stages_authenticator_endpoint_gdtc_update(stage_uuid, authenticator_endpoint_gdtc_stage_request) + print("The response of StagesApi->stages_authenticator_endpoint_gdtc_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_endpoint_gdtc_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. | + **authenticator_endpoint_gdtc_stage_request** | [**AuthenticatorEndpointGDTCStageRequest**](AuthenticatorEndpointGDTCStageRequest.md)| | + +### Return type + +[**AuthenticatorEndpointGDTCStage**](AuthenticatorEndpointGDTCStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_endpoint_gdtc_used_by_list** +> List[UsedBy] stages_authenticator_endpoint_gdtc_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. + + try: + api_response = api_instance.stages_authenticator_endpoint_gdtc_used_by_list(stage_uuid) + print("The response of StagesApi->stages_authenticator_endpoint_gdtc_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_endpoint_gdtc_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Authenticator Google Device Trust Connector Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_sms_create** +> AuthenticatorSMSStage stages_authenticator_sms_create(authenticator_sms_stage_request) + +AuthenticatorSMSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage +from authentik_client.models.authenticator_sms_stage_request import AuthenticatorSMSStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + authenticator_sms_stage_request = authentik_client.AuthenticatorSMSStageRequest() # AuthenticatorSMSStageRequest | + + try: + api_response = api_instance.stages_authenticator_sms_create(authenticator_sms_stage_request) + print("The response of StagesApi->stages_authenticator_sms_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_sms_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authenticator_sms_stage_request** | [**AuthenticatorSMSStageRequest**](AuthenticatorSMSStageRequest.md)| | + +### Return type + +[**AuthenticatorSMSStage**](AuthenticatorSMSStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_sms_destroy** +> stages_authenticator_sms_destroy(stage_uuid) + +AuthenticatorSMSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SMS Authenticator Setup Stage. + + try: + api_instance.stages_authenticator_sms_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_sms_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this SMS Authenticator Setup Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_sms_list** +> PaginatedAuthenticatorSMSStageList stages_authenticator_sms_list(account_sid=account_sid, auth=auth, auth_password=auth_password, auth_type=auth_type, configure_flow=configure_flow, friendly_name=friendly_name, from_number=from_number, mapping=mapping, name=name, ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, stage_uuid=stage_uuid, verify_only=verify_only) + +AuthenticatorSMSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.auth_type_enum import AuthTypeEnum +from authentik_client.models.paginated_authenticator_sms_stage_list import PaginatedAuthenticatorSMSStageList +from authentik_client.models.provider_enum import ProviderEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + account_sid = 'account_sid_example' # str | (optional) + auth = 'auth_example' # str | (optional) + auth_password = 'auth_password_example' # str | (optional) + auth_type = authentik_client.AuthTypeEnum() # AuthTypeEnum | (optional) + configure_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + friendly_name = 'friendly_name_example' # str | (optional) + from_number = 'from_number_example' # str | (optional) + mapping = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + provider = authentik_client.ProviderEnum() # ProviderEnum | (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + verify_only = True # bool | (optional) + + try: + api_response = api_instance.stages_authenticator_sms_list(account_sid=account_sid, auth=auth, auth_password=auth_password, auth_type=auth_type, configure_flow=configure_flow, friendly_name=friendly_name, from_number=from_number, mapping=mapping, name=name, ordering=ordering, page=page, page_size=page_size, provider=provider, search=search, stage_uuid=stage_uuid, verify_only=verify_only) + print("The response of StagesApi->stages_authenticator_sms_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_sms_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **account_sid** | **str**| | [optional] + **auth** | **str**| | [optional] + **auth_password** | **str**| | [optional] + **auth_type** | [**AuthTypeEnum**](.md)| | [optional] + **configure_flow** | **UUID**| | [optional] + **friendly_name** | **str**| | [optional] + **from_number** | **str**| | [optional] + **mapping** | **UUID**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **provider** | [**ProviderEnum**](.md)| | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + **verify_only** | **bool**| | [optional] + +### Return type + +[**PaginatedAuthenticatorSMSStageList**](PaginatedAuthenticatorSMSStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_sms_partial_update** +> AuthenticatorSMSStage stages_authenticator_sms_partial_update(stage_uuid, patched_authenticator_sms_stage_request=patched_authenticator_sms_stage_request) + +AuthenticatorSMSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage +from authentik_client.models.patched_authenticator_sms_stage_request import PatchedAuthenticatorSMSStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SMS Authenticator Setup Stage. + patched_authenticator_sms_stage_request = authentik_client.PatchedAuthenticatorSMSStageRequest() # PatchedAuthenticatorSMSStageRequest | (optional) + + try: + api_response = api_instance.stages_authenticator_sms_partial_update(stage_uuid, patched_authenticator_sms_stage_request=patched_authenticator_sms_stage_request) + print("The response of StagesApi->stages_authenticator_sms_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_sms_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this SMS Authenticator Setup Stage. | + **patched_authenticator_sms_stage_request** | [**PatchedAuthenticatorSMSStageRequest**](PatchedAuthenticatorSMSStageRequest.md)| | [optional] + +### Return type + +[**AuthenticatorSMSStage**](AuthenticatorSMSStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_sms_retrieve** +> AuthenticatorSMSStage stages_authenticator_sms_retrieve(stage_uuid) + +AuthenticatorSMSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SMS Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_sms_retrieve(stage_uuid) + print("The response of StagesApi->stages_authenticator_sms_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_sms_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this SMS Authenticator Setup Stage. | + +### Return type + +[**AuthenticatorSMSStage**](AuthenticatorSMSStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_sms_update** +> AuthenticatorSMSStage stages_authenticator_sms_update(stage_uuid, authenticator_sms_stage_request) + +AuthenticatorSMSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage +from authentik_client.models.authenticator_sms_stage_request import AuthenticatorSMSStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SMS Authenticator Setup Stage. + authenticator_sms_stage_request = authentik_client.AuthenticatorSMSStageRequest() # AuthenticatorSMSStageRequest | + + try: + api_response = api_instance.stages_authenticator_sms_update(stage_uuid, authenticator_sms_stage_request) + print("The response of StagesApi->stages_authenticator_sms_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_sms_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this SMS Authenticator Setup Stage. | + **authenticator_sms_stage_request** | [**AuthenticatorSMSStageRequest**](AuthenticatorSMSStageRequest.md)| | + +### Return type + +[**AuthenticatorSMSStage**](AuthenticatorSMSStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_sms_used_by_list** +> List[UsedBy] stages_authenticator_sms_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this SMS Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_sms_used_by_list(stage_uuid) + print("The response of StagesApi->stages_authenticator_sms_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_sms_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this SMS Authenticator Setup Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_static_create** +> AuthenticatorStaticStage stages_authenticator_static_create(authenticator_static_stage_request) + +AuthenticatorStaticStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage +from authentik_client.models.authenticator_static_stage_request import AuthenticatorStaticStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + authenticator_static_stage_request = authentik_client.AuthenticatorStaticStageRequest() # AuthenticatorStaticStageRequest | + + try: + api_response = api_instance.stages_authenticator_static_create(authenticator_static_stage_request) + print("The response of StagesApi->stages_authenticator_static_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_static_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authenticator_static_stage_request** | [**AuthenticatorStaticStageRequest**](AuthenticatorStaticStageRequest.md)| | + +### Return type + +[**AuthenticatorStaticStage**](AuthenticatorStaticStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_static_destroy** +> stages_authenticator_static_destroy(stage_uuid) + +AuthenticatorStaticStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Static Authenticator Setup Stage. + + try: + api_instance.stages_authenticator_static_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_static_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Static Authenticator Setup Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_static_list** +> PaginatedAuthenticatorStaticStageList stages_authenticator_static_list(configure_flow=configure_flow, friendly_name=friendly_name, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, token_count=token_count, token_length=token_length) + +AuthenticatorStaticStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_authenticator_static_stage_list import PaginatedAuthenticatorStaticStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + configure_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + friendly_name = 'friendly_name_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + token_count = 56 # int | (optional) + token_length = 56 # int | (optional) + + try: + api_response = api_instance.stages_authenticator_static_list(configure_flow=configure_flow, friendly_name=friendly_name, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, token_count=token_count, token_length=token_length) + print("The response of StagesApi->stages_authenticator_static_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_static_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **configure_flow** | **UUID**| | [optional] + **friendly_name** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + **token_count** | **int**| | [optional] + **token_length** | **int**| | [optional] + +### Return type + +[**PaginatedAuthenticatorStaticStageList**](PaginatedAuthenticatorStaticStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_static_partial_update** +> AuthenticatorStaticStage stages_authenticator_static_partial_update(stage_uuid, patched_authenticator_static_stage_request=patched_authenticator_static_stage_request) + +AuthenticatorStaticStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage +from authentik_client.models.patched_authenticator_static_stage_request import PatchedAuthenticatorStaticStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Static Authenticator Setup Stage. + patched_authenticator_static_stage_request = authentik_client.PatchedAuthenticatorStaticStageRequest() # PatchedAuthenticatorStaticStageRequest | (optional) + + try: + api_response = api_instance.stages_authenticator_static_partial_update(stage_uuid, patched_authenticator_static_stage_request=patched_authenticator_static_stage_request) + print("The response of StagesApi->stages_authenticator_static_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_static_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Static Authenticator Setup Stage. | + **patched_authenticator_static_stage_request** | [**PatchedAuthenticatorStaticStageRequest**](PatchedAuthenticatorStaticStageRequest.md)| | [optional] + +### Return type + +[**AuthenticatorStaticStage**](AuthenticatorStaticStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_static_retrieve** +> AuthenticatorStaticStage stages_authenticator_static_retrieve(stage_uuid) + +AuthenticatorStaticStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Static Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_static_retrieve(stage_uuid) + print("The response of StagesApi->stages_authenticator_static_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_static_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Static Authenticator Setup Stage. | + +### Return type + +[**AuthenticatorStaticStage**](AuthenticatorStaticStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_static_update** +> AuthenticatorStaticStage stages_authenticator_static_update(stage_uuid, authenticator_static_stage_request) + +AuthenticatorStaticStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage +from authentik_client.models.authenticator_static_stage_request import AuthenticatorStaticStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Static Authenticator Setup Stage. + authenticator_static_stage_request = authentik_client.AuthenticatorStaticStageRequest() # AuthenticatorStaticStageRequest | + + try: + api_response = api_instance.stages_authenticator_static_update(stage_uuid, authenticator_static_stage_request) + print("The response of StagesApi->stages_authenticator_static_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_static_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Static Authenticator Setup Stage. | + **authenticator_static_stage_request** | [**AuthenticatorStaticStageRequest**](AuthenticatorStaticStageRequest.md)| | + +### Return type + +[**AuthenticatorStaticStage**](AuthenticatorStaticStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_static_used_by_list** +> List[UsedBy] stages_authenticator_static_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Static Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_static_used_by_list(stage_uuid) + print("The response of StagesApi->stages_authenticator_static_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_static_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Static Authenticator Setup Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_totp_create** +> AuthenticatorTOTPStage stages_authenticator_totp_create(authenticator_totp_stage_request) + +AuthenticatorTOTPStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage +from authentik_client.models.authenticator_totp_stage_request import AuthenticatorTOTPStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + authenticator_totp_stage_request = authentik_client.AuthenticatorTOTPStageRequest() # AuthenticatorTOTPStageRequest | + + try: + api_response = api_instance.stages_authenticator_totp_create(authenticator_totp_stage_request) + print("The response of StagesApi->stages_authenticator_totp_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_totp_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authenticator_totp_stage_request** | [**AuthenticatorTOTPStageRequest**](AuthenticatorTOTPStageRequest.md)| | + +### Return type + +[**AuthenticatorTOTPStage**](AuthenticatorTOTPStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_totp_destroy** +> stages_authenticator_totp_destroy(stage_uuid) + +AuthenticatorTOTPStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this TOTP Authenticator Setup Stage. + + try: + api_instance.stages_authenticator_totp_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_totp_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this TOTP Authenticator Setup Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_totp_list** +> PaginatedAuthenticatorTOTPStageList stages_authenticator_totp_list(configure_flow=configure_flow, digits=digits, friendly_name=friendly_name, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + +AuthenticatorTOTPStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.digits_enum import DigitsEnum +from authentik_client.models.paginated_authenticator_totp_stage_list import PaginatedAuthenticatorTOTPStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + configure_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + digits = authentik_client.DigitsEnum() # DigitsEnum | (optional) + friendly_name = 'friendly_name_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.stages_authenticator_totp_list(configure_flow=configure_flow, digits=digits, friendly_name=friendly_name, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + print("The response of StagesApi->stages_authenticator_totp_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_totp_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **configure_flow** | **UUID**| | [optional] + **digits** | [**DigitsEnum**](.md)| | [optional] + **friendly_name** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedAuthenticatorTOTPStageList**](PaginatedAuthenticatorTOTPStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_totp_partial_update** +> AuthenticatorTOTPStage stages_authenticator_totp_partial_update(stage_uuid, patched_authenticator_totp_stage_request=patched_authenticator_totp_stage_request) + +AuthenticatorTOTPStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage +from authentik_client.models.patched_authenticator_totp_stage_request import PatchedAuthenticatorTOTPStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this TOTP Authenticator Setup Stage. + patched_authenticator_totp_stage_request = authentik_client.PatchedAuthenticatorTOTPStageRequest() # PatchedAuthenticatorTOTPStageRequest | (optional) + + try: + api_response = api_instance.stages_authenticator_totp_partial_update(stage_uuid, patched_authenticator_totp_stage_request=patched_authenticator_totp_stage_request) + print("The response of StagesApi->stages_authenticator_totp_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_totp_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this TOTP Authenticator Setup Stage. | + **patched_authenticator_totp_stage_request** | [**PatchedAuthenticatorTOTPStageRequest**](PatchedAuthenticatorTOTPStageRequest.md)| | [optional] + +### Return type + +[**AuthenticatorTOTPStage**](AuthenticatorTOTPStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_totp_retrieve** +> AuthenticatorTOTPStage stages_authenticator_totp_retrieve(stage_uuid) + +AuthenticatorTOTPStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this TOTP Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_totp_retrieve(stage_uuid) + print("The response of StagesApi->stages_authenticator_totp_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_totp_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this TOTP Authenticator Setup Stage. | + +### Return type + +[**AuthenticatorTOTPStage**](AuthenticatorTOTPStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_totp_update** +> AuthenticatorTOTPStage stages_authenticator_totp_update(stage_uuid, authenticator_totp_stage_request) + +AuthenticatorTOTPStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage +from authentik_client.models.authenticator_totp_stage_request import AuthenticatorTOTPStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this TOTP Authenticator Setup Stage. + authenticator_totp_stage_request = authentik_client.AuthenticatorTOTPStageRequest() # AuthenticatorTOTPStageRequest | + + try: + api_response = api_instance.stages_authenticator_totp_update(stage_uuid, authenticator_totp_stage_request) + print("The response of StagesApi->stages_authenticator_totp_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_totp_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this TOTP Authenticator Setup Stage. | + **authenticator_totp_stage_request** | [**AuthenticatorTOTPStageRequest**](AuthenticatorTOTPStageRequest.md)| | + +### Return type + +[**AuthenticatorTOTPStage**](AuthenticatorTOTPStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_totp_used_by_list** +> List[UsedBy] stages_authenticator_totp_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this TOTP Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_totp_used_by_list(stage_uuid) + print("The response of StagesApi->stages_authenticator_totp_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_totp_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this TOTP Authenticator Setup Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_validate_create** +> AuthenticatorValidateStage stages_authenticator_validate_create(authenticator_validate_stage_request) + +AuthenticatorValidateStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage +from authentik_client.models.authenticator_validate_stage_request import AuthenticatorValidateStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + authenticator_validate_stage_request = authentik_client.AuthenticatorValidateStageRequest() # AuthenticatorValidateStageRequest | + + try: + api_response = api_instance.stages_authenticator_validate_create(authenticator_validate_stage_request) + print("The response of StagesApi->stages_authenticator_validate_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_validate_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authenticator_validate_stage_request** | [**AuthenticatorValidateStageRequest**](AuthenticatorValidateStageRequest.md)| | + +### Return type + +[**AuthenticatorValidateStage**](AuthenticatorValidateStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_validate_destroy** +> stages_authenticator_validate_destroy(stage_uuid) + +AuthenticatorValidateStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Authenticator Validation Stage. + + try: + api_instance.stages_authenticator_validate_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_validate_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Authenticator Validation Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_validate_list** +> PaginatedAuthenticatorValidateStageList stages_authenticator_validate_list(configuration_stages=configuration_stages, name=name, not_configured_action=not_configured_action, ordering=ordering, page=page, page_size=page_size, search=search) + +AuthenticatorValidateStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.not_configured_action_enum import NotConfiguredActionEnum +from authentik_client.models.paginated_authenticator_validate_stage_list import PaginatedAuthenticatorValidateStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + configuration_stages = None # List[UUID] | (optional) + name = 'name_example' # str | (optional) + not_configured_action = authentik_client.NotConfiguredActionEnum() # NotConfiguredActionEnum | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_authenticator_validate_list(configuration_stages=configuration_stages, name=name, not_configured_action=not_configured_action, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of StagesApi->stages_authenticator_validate_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_validate_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **configuration_stages** | [**List[UUID]**](UUID.md)| | [optional] + **name** | **str**| | [optional] + **not_configured_action** | [**NotConfiguredActionEnum**](.md)| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedAuthenticatorValidateStageList**](PaginatedAuthenticatorValidateStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_validate_partial_update** +> AuthenticatorValidateStage stages_authenticator_validate_partial_update(stage_uuid, patched_authenticator_validate_stage_request=patched_authenticator_validate_stage_request) + +AuthenticatorValidateStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage +from authentik_client.models.patched_authenticator_validate_stage_request import PatchedAuthenticatorValidateStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Authenticator Validation Stage. + patched_authenticator_validate_stage_request = authentik_client.PatchedAuthenticatorValidateStageRequest() # PatchedAuthenticatorValidateStageRequest | (optional) + + try: + api_response = api_instance.stages_authenticator_validate_partial_update(stage_uuid, patched_authenticator_validate_stage_request=patched_authenticator_validate_stage_request) + print("The response of StagesApi->stages_authenticator_validate_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_validate_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Authenticator Validation Stage. | + **patched_authenticator_validate_stage_request** | [**PatchedAuthenticatorValidateStageRequest**](PatchedAuthenticatorValidateStageRequest.md)| | [optional] + +### Return type + +[**AuthenticatorValidateStage**](AuthenticatorValidateStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_validate_retrieve** +> AuthenticatorValidateStage stages_authenticator_validate_retrieve(stage_uuid) + +AuthenticatorValidateStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Authenticator Validation Stage. + + try: + api_response = api_instance.stages_authenticator_validate_retrieve(stage_uuid) + print("The response of StagesApi->stages_authenticator_validate_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_validate_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Authenticator Validation Stage. | + +### Return type + +[**AuthenticatorValidateStage**](AuthenticatorValidateStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_validate_update** +> AuthenticatorValidateStage stages_authenticator_validate_update(stage_uuid, authenticator_validate_stage_request) + +AuthenticatorValidateStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage +from authentik_client.models.authenticator_validate_stage_request import AuthenticatorValidateStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Authenticator Validation Stage. + authenticator_validate_stage_request = authentik_client.AuthenticatorValidateStageRequest() # AuthenticatorValidateStageRequest | + + try: + api_response = api_instance.stages_authenticator_validate_update(stage_uuid, authenticator_validate_stage_request) + print("The response of StagesApi->stages_authenticator_validate_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_validate_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Authenticator Validation Stage. | + **authenticator_validate_stage_request** | [**AuthenticatorValidateStageRequest**](AuthenticatorValidateStageRequest.md)| | + +### Return type + +[**AuthenticatorValidateStage**](AuthenticatorValidateStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_validate_used_by_list** +> List[UsedBy] stages_authenticator_validate_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Authenticator Validation Stage. + + try: + api_response = api_instance.stages_authenticator_validate_used_by_list(stage_uuid) + print("The response of StagesApi->stages_authenticator_validate_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_validate_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Authenticator Validation Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_webauthn_create** +> AuthenticatorWebAuthnStage stages_authenticator_webauthn_create(authenticator_web_authn_stage_request) + +AuthenticatorWebAuthnStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage +from authentik_client.models.authenticator_web_authn_stage_request import AuthenticatorWebAuthnStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + authenticator_web_authn_stage_request = authentik_client.AuthenticatorWebAuthnStageRequest() # AuthenticatorWebAuthnStageRequest | + + try: + api_response = api_instance.stages_authenticator_webauthn_create(authenticator_web_authn_stage_request) + print("The response of StagesApi->stages_authenticator_webauthn_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_webauthn_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authenticator_web_authn_stage_request** | [**AuthenticatorWebAuthnStageRequest**](AuthenticatorWebAuthnStageRequest.md)| | + +### Return type + +[**AuthenticatorWebAuthnStage**](AuthenticatorWebAuthnStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_webauthn_destroy** +> stages_authenticator_webauthn_destroy(stage_uuid) + +AuthenticatorWebAuthnStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this WebAuthn Authenticator Setup Stage. + + try: + api_instance.stages_authenticator_webauthn_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_webauthn_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this WebAuthn Authenticator Setup Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_webauthn_device_types_list** +> PaginatedWebAuthnDeviceTypeList stages_authenticator_webauthn_device_types_list(aaguid=aaguid, description=description, icon=icon, ordering=ordering, page=page, page_size=page_size, search=search) + +WebAuthnDeviceType Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_web_authn_device_type_list import PaginatedWebAuthnDeviceTypeList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + aaguid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + description = 'description_example' # str | (optional) + icon = 'icon_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_authenticator_webauthn_device_types_list(aaguid=aaguid, description=description, icon=icon, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of StagesApi->stages_authenticator_webauthn_device_types_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_webauthn_device_types_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **aaguid** | **UUID**| | [optional] + **description** | **str**| | [optional] + **icon** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedWebAuthnDeviceTypeList**](PaginatedWebAuthnDeviceTypeList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_webauthn_device_types_retrieve** +> WebAuthnDeviceType stages_authenticator_webauthn_device_types_retrieve(aaguid) + +WebAuthnDeviceType Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + aaguid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this WebAuthn Device type. + + try: + api_response = api_instance.stages_authenticator_webauthn_device_types_retrieve(aaguid) + print("The response of StagesApi->stages_authenticator_webauthn_device_types_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_webauthn_device_types_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **aaguid** | **UUID**| A UUID string identifying this WebAuthn Device type. | + +### Return type + +[**WebAuthnDeviceType**](WebAuthnDeviceType.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_webauthn_list** +> PaginatedAuthenticatorWebAuthnStageList stages_authenticator_webauthn_list(authenticator_attachment=authenticator_attachment, configure_flow=configure_flow, device_type_restrictions=device_type_restrictions, max_attempts=max_attempts, name=name, ordering=ordering, page=page, page_size=page_size, resident_key_requirement=resident_key_requirement, search=search, user_verification=user_verification) + +AuthenticatorWebAuthnStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_authenticator_web_authn_stage_list import PaginatedAuthenticatorWebAuthnStageList +from authentik_client.models.user_verification_enum import UserVerificationEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + authenticator_attachment = authentik_client.AuthenticatorAttachmentEnum() # AuthenticatorAttachmentEnum | (optional) + configure_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + device_type_restrictions = None # List[UUID] | (optional) + max_attempts = 56 # int | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + resident_key_requirement = authentik_client.UserVerificationEnum() # UserVerificationEnum | (optional) + search = 'search_example' # str | A search term. (optional) + user_verification = authentik_client.UserVerificationEnum() # UserVerificationEnum | (optional) + + try: + api_response = api_instance.stages_authenticator_webauthn_list(authenticator_attachment=authenticator_attachment, configure_flow=configure_flow, device_type_restrictions=device_type_restrictions, max_attempts=max_attempts, name=name, ordering=ordering, page=page, page_size=page_size, resident_key_requirement=resident_key_requirement, search=search, user_verification=user_verification) + print("The response of StagesApi->stages_authenticator_webauthn_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_webauthn_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **authenticator_attachment** | [**AuthenticatorAttachmentEnum**](.md)| | [optional] + **configure_flow** | **UUID**| | [optional] + **device_type_restrictions** | [**List[UUID]**](UUID.md)| | [optional] + **max_attempts** | **int**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **resident_key_requirement** | [**UserVerificationEnum**](.md)| | [optional] + **search** | **str**| A search term. | [optional] + **user_verification** | [**UserVerificationEnum**](.md)| | [optional] + +### Return type + +[**PaginatedAuthenticatorWebAuthnStageList**](PaginatedAuthenticatorWebAuthnStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_webauthn_partial_update** +> AuthenticatorWebAuthnStage stages_authenticator_webauthn_partial_update(stage_uuid, patched_authenticator_web_authn_stage_request=patched_authenticator_web_authn_stage_request) + +AuthenticatorWebAuthnStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage +from authentik_client.models.patched_authenticator_web_authn_stage_request import PatchedAuthenticatorWebAuthnStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this WebAuthn Authenticator Setup Stage. + patched_authenticator_web_authn_stage_request = authentik_client.PatchedAuthenticatorWebAuthnStageRequest() # PatchedAuthenticatorWebAuthnStageRequest | (optional) + + try: + api_response = api_instance.stages_authenticator_webauthn_partial_update(stage_uuid, patched_authenticator_web_authn_stage_request=patched_authenticator_web_authn_stage_request) + print("The response of StagesApi->stages_authenticator_webauthn_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_webauthn_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this WebAuthn Authenticator Setup Stage. | + **patched_authenticator_web_authn_stage_request** | [**PatchedAuthenticatorWebAuthnStageRequest**](PatchedAuthenticatorWebAuthnStageRequest.md)| | [optional] + +### Return type + +[**AuthenticatorWebAuthnStage**](AuthenticatorWebAuthnStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_webauthn_retrieve** +> AuthenticatorWebAuthnStage stages_authenticator_webauthn_retrieve(stage_uuid) + +AuthenticatorWebAuthnStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this WebAuthn Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_webauthn_retrieve(stage_uuid) + print("The response of StagesApi->stages_authenticator_webauthn_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_webauthn_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this WebAuthn Authenticator Setup Stage. | + +### Return type + +[**AuthenticatorWebAuthnStage**](AuthenticatorWebAuthnStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_webauthn_update** +> AuthenticatorWebAuthnStage stages_authenticator_webauthn_update(stage_uuid, authenticator_web_authn_stage_request) + +AuthenticatorWebAuthnStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage +from authentik_client.models.authenticator_web_authn_stage_request import AuthenticatorWebAuthnStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this WebAuthn Authenticator Setup Stage. + authenticator_web_authn_stage_request = authentik_client.AuthenticatorWebAuthnStageRequest() # AuthenticatorWebAuthnStageRequest | + + try: + api_response = api_instance.stages_authenticator_webauthn_update(stage_uuid, authenticator_web_authn_stage_request) + print("The response of StagesApi->stages_authenticator_webauthn_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_webauthn_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this WebAuthn Authenticator Setup Stage. | + **authenticator_web_authn_stage_request** | [**AuthenticatorWebAuthnStageRequest**](AuthenticatorWebAuthnStageRequest.md)| | + +### Return type + +[**AuthenticatorWebAuthnStage**](AuthenticatorWebAuthnStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_authenticator_webauthn_used_by_list** +> List[UsedBy] stages_authenticator_webauthn_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this WebAuthn Authenticator Setup Stage. + + try: + api_response = api_instance.stages_authenticator_webauthn_used_by_list(stage_uuid) + print("The response of StagesApi->stages_authenticator_webauthn_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_authenticator_webauthn_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this WebAuthn Authenticator Setup Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_captcha_create** +> CaptchaStage stages_captcha_create(captcha_stage_request) + +CaptchaStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.captcha_stage import CaptchaStage +from authentik_client.models.captcha_stage_request import CaptchaStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + captcha_stage_request = authentik_client.CaptchaStageRequest() # CaptchaStageRequest | + + try: + api_response = api_instance.stages_captcha_create(captcha_stage_request) + print("The response of StagesApi->stages_captcha_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_captcha_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **captcha_stage_request** | [**CaptchaStageRequest**](CaptchaStageRequest.md)| | + +### Return type + +[**CaptchaStage**](CaptchaStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_captcha_destroy** +> stages_captcha_destroy(stage_uuid) + +CaptchaStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Captcha Stage. + + try: + api_instance.stages_captcha_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_captcha_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Captcha Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_captcha_list** +> PaginatedCaptchaStageList stages_captcha_list(name=name, ordering=ordering, page=page, page_size=page_size, public_key=public_key, search=search) + +CaptchaStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_captcha_stage_list import PaginatedCaptchaStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + public_key = 'public_key_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_captcha_list(name=name, ordering=ordering, page=page, page_size=page_size, public_key=public_key, search=search) + print("The response of StagesApi->stages_captcha_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_captcha_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **public_key** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedCaptchaStageList**](PaginatedCaptchaStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_captcha_partial_update** +> CaptchaStage stages_captcha_partial_update(stage_uuid, patched_captcha_stage_request=patched_captcha_stage_request) + +CaptchaStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.captcha_stage import CaptchaStage +from authentik_client.models.patched_captcha_stage_request import PatchedCaptchaStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Captcha Stage. + patched_captcha_stage_request = authentik_client.PatchedCaptchaStageRequest() # PatchedCaptchaStageRequest | (optional) + + try: + api_response = api_instance.stages_captcha_partial_update(stage_uuid, patched_captcha_stage_request=patched_captcha_stage_request) + print("The response of StagesApi->stages_captcha_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_captcha_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Captcha Stage. | + **patched_captcha_stage_request** | [**PatchedCaptchaStageRequest**](PatchedCaptchaStageRequest.md)| | [optional] + +### Return type + +[**CaptchaStage**](CaptchaStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_captcha_retrieve** +> CaptchaStage stages_captcha_retrieve(stage_uuid) + +CaptchaStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.captcha_stage import CaptchaStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Captcha Stage. + + try: + api_response = api_instance.stages_captcha_retrieve(stage_uuid) + print("The response of StagesApi->stages_captcha_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_captcha_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Captcha Stage. | + +### Return type + +[**CaptchaStage**](CaptchaStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_captcha_update** +> CaptchaStage stages_captcha_update(stage_uuid, captcha_stage_request) + +CaptchaStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.captcha_stage import CaptchaStage +from authentik_client.models.captcha_stage_request import CaptchaStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Captcha Stage. + captcha_stage_request = authentik_client.CaptchaStageRequest() # CaptchaStageRequest | + + try: + api_response = api_instance.stages_captcha_update(stage_uuid, captcha_stage_request) + print("The response of StagesApi->stages_captcha_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_captcha_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Captcha Stage. | + **captcha_stage_request** | [**CaptchaStageRequest**](CaptchaStageRequest.md)| | + +### Return type + +[**CaptchaStage**](CaptchaStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_captcha_used_by_list** +> List[UsedBy] stages_captcha_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Captcha Stage. + + try: + api_response = api_instance.stages_captcha_used_by_list(stage_uuid) + print("The response of StagesApi->stages_captcha_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_captcha_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Captcha Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_consent_create** +> ConsentStage stages_consent_create(consent_stage_request) + +ConsentStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.consent_stage import ConsentStage +from authentik_client.models.consent_stage_request import ConsentStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + consent_stage_request = authentik_client.ConsentStageRequest() # ConsentStageRequest | + + try: + api_response = api_instance.stages_consent_create(consent_stage_request) + print("The response of StagesApi->stages_consent_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_consent_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **consent_stage_request** | [**ConsentStageRequest**](ConsentStageRequest.md)| | + +### Return type + +[**ConsentStage**](ConsentStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_consent_destroy** +> stages_consent_destroy(stage_uuid) + +ConsentStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Consent Stage. + + try: + api_instance.stages_consent_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_consent_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Consent Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_consent_list** +> PaginatedConsentStageList stages_consent_list(consent_expire_in=consent_expire_in, mode=mode, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + +ConsentStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.consent_mode_enum import ConsentModeEnum +from authentik_client.models.paginated_consent_stage_list import PaginatedConsentStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + consent_expire_in = 'consent_expire_in_example' # str | (optional) + mode = authentik_client.ConsentModeEnum() # ConsentModeEnum | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.stages_consent_list(consent_expire_in=consent_expire_in, mode=mode, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + print("The response of StagesApi->stages_consent_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_consent_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **consent_expire_in** | **str**| | [optional] + **mode** | [**ConsentModeEnum**](.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedConsentStageList**](PaginatedConsentStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_consent_partial_update** +> ConsentStage stages_consent_partial_update(stage_uuid, patched_consent_stage_request=patched_consent_stage_request) + +ConsentStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.consent_stage import ConsentStage +from authentik_client.models.patched_consent_stage_request import PatchedConsentStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Consent Stage. + patched_consent_stage_request = authentik_client.PatchedConsentStageRequest() # PatchedConsentStageRequest | (optional) + + try: + api_response = api_instance.stages_consent_partial_update(stage_uuid, patched_consent_stage_request=patched_consent_stage_request) + print("The response of StagesApi->stages_consent_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_consent_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Consent Stage. | + **patched_consent_stage_request** | [**PatchedConsentStageRequest**](PatchedConsentStageRequest.md)| | [optional] + +### Return type + +[**ConsentStage**](ConsentStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_consent_retrieve** +> ConsentStage stages_consent_retrieve(stage_uuid) + +ConsentStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.consent_stage import ConsentStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Consent Stage. + + try: + api_response = api_instance.stages_consent_retrieve(stage_uuid) + print("The response of StagesApi->stages_consent_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_consent_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Consent Stage. | + +### Return type + +[**ConsentStage**](ConsentStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_consent_update** +> ConsentStage stages_consent_update(stage_uuid, consent_stage_request) + +ConsentStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.consent_stage import ConsentStage +from authentik_client.models.consent_stage_request import ConsentStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Consent Stage. + consent_stage_request = authentik_client.ConsentStageRequest() # ConsentStageRequest | + + try: + api_response = api_instance.stages_consent_update(stage_uuid, consent_stage_request) + print("The response of StagesApi->stages_consent_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_consent_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Consent Stage. | + **consent_stage_request** | [**ConsentStageRequest**](ConsentStageRequest.md)| | + +### Return type + +[**ConsentStage**](ConsentStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_consent_used_by_list** +> List[UsedBy] stages_consent_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Consent Stage. + + try: + api_response = api_instance.stages_consent_used_by_list(stage_uuid) + print("The response of StagesApi->stages_consent_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_consent_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Consent Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_deny_create** +> DenyStage stages_deny_create(deny_stage_request) + +DenyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.deny_stage import DenyStage +from authentik_client.models.deny_stage_request import DenyStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + deny_stage_request = authentik_client.DenyStageRequest() # DenyStageRequest | + + try: + api_response = api_instance.stages_deny_create(deny_stage_request) + print("The response of StagesApi->stages_deny_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_deny_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deny_stage_request** | [**DenyStageRequest**](DenyStageRequest.md)| | + +### Return type + +[**DenyStage**](DenyStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_deny_destroy** +> stages_deny_destroy(stage_uuid) + +DenyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Deny Stage. + + try: + api_instance.stages_deny_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_deny_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Deny Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_deny_list** +> PaginatedDenyStageList stages_deny_list(deny_message=deny_message, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + +DenyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_deny_stage_list import PaginatedDenyStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + deny_message = 'deny_message_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.stages_deny_list(deny_message=deny_message, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + print("The response of StagesApi->stages_deny_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_deny_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deny_message** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedDenyStageList**](PaginatedDenyStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_deny_partial_update** +> DenyStage stages_deny_partial_update(stage_uuid, patched_deny_stage_request=patched_deny_stage_request) + +DenyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.deny_stage import DenyStage +from authentik_client.models.patched_deny_stage_request import PatchedDenyStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Deny Stage. + patched_deny_stage_request = authentik_client.PatchedDenyStageRequest() # PatchedDenyStageRequest | (optional) + + try: + api_response = api_instance.stages_deny_partial_update(stage_uuid, patched_deny_stage_request=patched_deny_stage_request) + print("The response of StagesApi->stages_deny_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_deny_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Deny Stage. | + **patched_deny_stage_request** | [**PatchedDenyStageRequest**](PatchedDenyStageRequest.md)| | [optional] + +### Return type + +[**DenyStage**](DenyStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_deny_retrieve** +> DenyStage stages_deny_retrieve(stage_uuid) + +DenyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.deny_stage import DenyStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Deny Stage. + + try: + api_response = api_instance.stages_deny_retrieve(stage_uuid) + print("The response of StagesApi->stages_deny_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_deny_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Deny Stage. | + +### Return type + +[**DenyStage**](DenyStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_deny_update** +> DenyStage stages_deny_update(stage_uuid, deny_stage_request) + +DenyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.deny_stage import DenyStage +from authentik_client.models.deny_stage_request import DenyStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Deny Stage. + deny_stage_request = authentik_client.DenyStageRequest() # DenyStageRequest | + + try: + api_response = api_instance.stages_deny_update(stage_uuid, deny_stage_request) + print("The response of StagesApi->stages_deny_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_deny_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Deny Stage. | + **deny_stage_request** | [**DenyStageRequest**](DenyStageRequest.md)| | + +### Return type + +[**DenyStage**](DenyStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_deny_used_by_list** +> List[UsedBy] stages_deny_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Deny Stage. + + try: + api_response = api_instance.stages_deny_used_by_list(stage_uuid) + print("The response of StagesApi->stages_deny_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_deny_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Deny Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_dummy_create** +> DummyStage stages_dummy_create(dummy_stage_request) + +DummyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.dummy_stage import DummyStage +from authentik_client.models.dummy_stage_request import DummyStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + dummy_stage_request = authentik_client.DummyStageRequest() # DummyStageRequest | + + try: + api_response = api_instance.stages_dummy_create(dummy_stage_request) + print("The response of StagesApi->stages_dummy_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_dummy_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **dummy_stage_request** | [**DummyStageRequest**](DummyStageRequest.md)| | + +### Return type + +[**DummyStage**](DummyStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_dummy_destroy** +> stages_dummy_destroy(stage_uuid) + +DummyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Stage. + + try: + api_instance.stages_dummy_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_dummy_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Dummy Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_dummy_list** +> PaginatedDummyStageList stages_dummy_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, throw_error=throw_error) + +DummyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_dummy_stage_list import PaginatedDummyStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + throw_error = True # bool | (optional) + + try: + api_response = api_instance.stages_dummy_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, throw_error=throw_error) + print("The response of StagesApi->stages_dummy_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_dummy_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + **throw_error** | **bool**| | [optional] + +### Return type + +[**PaginatedDummyStageList**](PaginatedDummyStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_dummy_partial_update** +> DummyStage stages_dummy_partial_update(stage_uuid, patched_dummy_stage_request=patched_dummy_stage_request) + +DummyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.dummy_stage import DummyStage +from authentik_client.models.patched_dummy_stage_request import PatchedDummyStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Stage. + patched_dummy_stage_request = authentik_client.PatchedDummyStageRequest() # PatchedDummyStageRequest | (optional) + + try: + api_response = api_instance.stages_dummy_partial_update(stage_uuid, patched_dummy_stage_request=patched_dummy_stage_request) + print("The response of StagesApi->stages_dummy_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_dummy_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Dummy Stage. | + **patched_dummy_stage_request** | [**PatchedDummyStageRequest**](PatchedDummyStageRequest.md)| | [optional] + +### Return type + +[**DummyStage**](DummyStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_dummy_retrieve** +> DummyStage stages_dummy_retrieve(stage_uuid) + +DummyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.dummy_stage import DummyStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Stage. + + try: + api_response = api_instance.stages_dummy_retrieve(stage_uuid) + print("The response of StagesApi->stages_dummy_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_dummy_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Dummy Stage. | + +### Return type + +[**DummyStage**](DummyStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_dummy_update** +> DummyStage stages_dummy_update(stage_uuid, dummy_stage_request) + +DummyStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.dummy_stage import DummyStage +from authentik_client.models.dummy_stage_request import DummyStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Stage. + dummy_stage_request = authentik_client.DummyStageRequest() # DummyStageRequest | + + try: + api_response = api_instance.stages_dummy_update(stage_uuid, dummy_stage_request) + print("The response of StagesApi->stages_dummy_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_dummy_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Dummy Stage. | + **dummy_stage_request** | [**DummyStageRequest**](DummyStageRequest.md)| | + +### Return type + +[**DummyStage**](DummyStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_dummy_used_by_list** +> List[UsedBy] stages_dummy_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Dummy Stage. + + try: + api_response = api_instance.stages_dummy_used_by_list(stage_uuid) + print("The response of StagesApi->stages_dummy_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_dummy_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Dummy Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_email_create** +> EmailStage stages_email_create(email_stage_request) + +EmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_stage import EmailStage +from authentik_client.models.email_stage_request import EmailStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + email_stage_request = authentik_client.EmailStageRequest() # EmailStageRequest | + + try: + api_response = api_instance.stages_email_create(email_stage_request) + print("The response of StagesApi->stages_email_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_email_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **email_stage_request** | [**EmailStageRequest**](EmailStageRequest.md)| | + +### Return type + +[**EmailStage**](EmailStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_email_destroy** +> stages_email_destroy(stage_uuid) + +EmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Stage. + + try: + api_instance.stages_email_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_email_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_email_list** +> PaginatedEmailStageList stages_email_list(activate_user_on_success=activate_user_on_success, from_address=from_address, host=host, name=name, ordering=ordering, page=page, page_size=page_size, port=port, search=search, subject=subject, template=template, timeout=timeout, token_expiry=token_expiry, use_global_settings=use_global_settings, use_ssl=use_ssl, use_tls=use_tls, username=username) + +EmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_email_stage_list import PaginatedEmailStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + activate_user_on_success = True # bool | (optional) + from_address = 'from_address_example' # str | (optional) + host = 'host_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + port = 56 # int | (optional) + search = 'search_example' # str | A search term. (optional) + subject = 'subject_example' # str | (optional) + template = 'template_example' # str | (optional) + timeout = 56 # int | (optional) + token_expiry = 'token_expiry_example' # str | (optional) + use_global_settings = True # bool | (optional) + use_ssl = True # bool | (optional) + use_tls = True # bool | (optional) + username = 'username_example' # str | (optional) + + try: + api_response = api_instance.stages_email_list(activate_user_on_success=activate_user_on_success, from_address=from_address, host=host, name=name, ordering=ordering, page=page, page_size=page_size, port=port, search=search, subject=subject, template=template, timeout=timeout, token_expiry=token_expiry, use_global_settings=use_global_settings, use_ssl=use_ssl, use_tls=use_tls, username=username) + print("The response of StagesApi->stages_email_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_email_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **activate_user_on_success** | **bool**| | [optional] + **from_address** | **str**| | [optional] + **host** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **port** | **int**| | [optional] + **search** | **str**| A search term. | [optional] + **subject** | **str**| | [optional] + **template** | **str**| | [optional] + **timeout** | **int**| | [optional] + **token_expiry** | **str**| | [optional] + **use_global_settings** | **bool**| | [optional] + **use_ssl** | **bool**| | [optional] + **use_tls** | **bool**| | [optional] + **username** | **str**| | [optional] + +### Return type + +[**PaginatedEmailStageList**](PaginatedEmailStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_email_partial_update** +> EmailStage stages_email_partial_update(stage_uuid, patched_email_stage_request=patched_email_stage_request) + +EmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_stage import EmailStage +from authentik_client.models.patched_email_stage_request import PatchedEmailStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Stage. + patched_email_stage_request = authentik_client.PatchedEmailStageRequest() # PatchedEmailStageRequest | (optional) + + try: + api_response = api_instance.stages_email_partial_update(stage_uuid, patched_email_stage_request=patched_email_stage_request) + print("The response of StagesApi->stages_email_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_email_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Stage. | + **patched_email_stage_request** | [**PatchedEmailStageRequest**](PatchedEmailStageRequest.md)| | [optional] + +### Return type + +[**EmailStage**](EmailStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_email_retrieve** +> EmailStage stages_email_retrieve(stage_uuid) + +EmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_stage import EmailStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Stage. + + try: + api_response = api_instance.stages_email_retrieve(stage_uuid) + print("The response of StagesApi->stages_email_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_email_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Stage. | + +### Return type + +[**EmailStage**](EmailStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_email_templates_list** +> List[TypeCreate] stages_email_templates_list() + +Get all available templates, including custom templates + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.type_create import TypeCreate +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + + try: + api_response = api_instance.stages_email_templates_list() + print("The response of StagesApi->stages_email_templates_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_email_templates_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[TypeCreate]**](TypeCreate.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_email_update** +> EmailStage stages_email_update(stage_uuid, email_stage_request) + +EmailStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.email_stage import EmailStage +from authentik_client.models.email_stage_request import EmailStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Stage. + email_stage_request = authentik_client.EmailStageRequest() # EmailStageRequest | + + try: + api_response = api_instance.stages_email_update(stage_uuid, email_stage_request) + print("The response of StagesApi->stages_email_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_email_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Stage. | + **email_stage_request** | [**EmailStageRequest**](EmailStageRequest.md)| | + +### Return type + +[**EmailStage**](EmailStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_email_used_by_list** +> List[UsedBy] stages_email_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Email Stage. + + try: + api_response = api_instance.stages_email_used_by_list(stage_uuid) + print("The response of StagesApi->stages_email_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_email_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Email Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_endpoints_create** +> EndpointStage stages_endpoints_create(endpoint_stage_request) + +EndpointStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint_stage import EndpointStage +from authentik_client.models.endpoint_stage_request import EndpointStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + endpoint_stage_request = authentik_client.EndpointStageRequest() # EndpointStageRequest | + + try: + api_response = api_instance.stages_endpoints_create(endpoint_stage_request) + print("The response of StagesApi->stages_endpoints_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_endpoints_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **endpoint_stage_request** | [**EndpointStageRequest**](EndpointStageRequest.md)| | + +### Return type + +[**EndpointStage**](EndpointStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_endpoints_destroy** +> stages_endpoints_destroy(stage_uuid) + +EndpointStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Stage. + + try: + api_instance.stages_endpoints_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_endpoints_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_endpoints_list** +> PaginatedEndpointStageList stages_endpoints_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +EndpointStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_endpoint_stage_list import PaginatedEndpointStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_endpoints_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of StagesApi->stages_endpoints_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_endpoints_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedEndpointStageList**](PaginatedEndpointStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_endpoints_partial_update** +> EndpointStage stages_endpoints_partial_update(stage_uuid, patched_endpoint_stage_request=patched_endpoint_stage_request) + +EndpointStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint_stage import EndpointStage +from authentik_client.models.patched_endpoint_stage_request import PatchedEndpointStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Stage. + patched_endpoint_stage_request = authentik_client.PatchedEndpointStageRequest() # PatchedEndpointStageRequest | (optional) + + try: + api_response = api_instance.stages_endpoints_partial_update(stage_uuid, patched_endpoint_stage_request=patched_endpoint_stage_request) + print("The response of StagesApi->stages_endpoints_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_endpoints_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Stage. | + **patched_endpoint_stage_request** | [**PatchedEndpointStageRequest**](PatchedEndpointStageRequest.md)| | [optional] + +### Return type + +[**EndpointStage**](EndpointStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_endpoints_retrieve** +> EndpointStage stages_endpoints_retrieve(stage_uuid) + +EndpointStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint_stage import EndpointStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Stage. + + try: + api_response = api_instance.stages_endpoints_retrieve(stage_uuid) + print("The response of StagesApi->stages_endpoints_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_endpoints_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Stage. | + +### Return type + +[**EndpointStage**](EndpointStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_endpoints_update** +> EndpointStage stages_endpoints_update(stage_uuid, endpoint_stage_request) + +EndpointStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.endpoint_stage import EndpointStage +from authentik_client.models.endpoint_stage_request import EndpointStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Stage. + endpoint_stage_request = authentik_client.EndpointStageRequest() # EndpointStageRequest | + + try: + api_response = api_instance.stages_endpoints_update(stage_uuid, endpoint_stage_request) + print("The response of StagesApi->stages_endpoints_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_endpoints_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Stage. | + **endpoint_stage_request** | [**EndpointStageRequest**](EndpointStageRequest.md)| | + +### Return type + +[**EndpointStage**](EndpointStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_endpoints_used_by_list** +> List[UsedBy] stages_endpoints_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Endpoint Stage. + + try: + api_response = api_instance.stages_endpoints_used_by_list(stage_uuid) + print("The response of StagesApi->stages_endpoints_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_endpoints_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Endpoint Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_identification_create** +> IdentificationStage stages_identification_create(identification_stage_request) + +IdentificationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.identification_stage import IdentificationStage +from authentik_client.models.identification_stage_request import IdentificationStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + identification_stage_request = authentik_client.IdentificationStageRequest() # IdentificationStageRequest | + + try: + api_response = api_instance.stages_identification_create(identification_stage_request) + print("The response of StagesApi->stages_identification_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_identification_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **identification_stage_request** | [**IdentificationStageRequest**](IdentificationStageRequest.md)| | + +### Return type + +[**IdentificationStage**](IdentificationStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_identification_destroy** +> stages_identification_destroy(stage_uuid) + +IdentificationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Identification Stage. + + try: + api_instance.stages_identification_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_identification_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Identification Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_identification_list** +> PaginatedIdentificationStageList stages_identification_list(captcha_stage=captcha_stage, case_insensitive_matching=case_insensitive_matching, enrollment_flow=enrollment_flow, name=name, ordering=ordering, page=page, page_size=page_size, password_stage=password_stage, passwordless_flow=passwordless_flow, recovery_flow=recovery_flow, search=search, show_matched_user=show_matched_user, show_source_labels=show_source_labels, webauthn_stage=webauthn_stage) + +IdentificationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_identification_stage_list import PaginatedIdentificationStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + captcha_stage = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + case_insensitive_matching = True # bool | (optional) + enrollment_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + password_stage = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + passwordless_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + recovery_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + search = 'search_example' # str | A search term. (optional) + show_matched_user = True # bool | (optional) + show_source_labels = True # bool | (optional) + webauthn_stage = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.stages_identification_list(captcha_stage=captcha_stage, case_insensitive_matching=case_insensitive_matching, enrollment_flow=enrollment_flow, name=name, ordering=ordering, page=page, page_size=page_size, password_stage=password_stage, passwordless_flow=passwordless_flow, recovery_flow=recovery_flow, search=search, show_matched_user=show_matched_user, show_source_labels=show_source_labels, webauthn_stage=webauthn_stage) + print("The response of StagesApi->stages_identification_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_identification_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **captcha_stage** | **UUID**| | [optional] + **case_insensitive_matching** | **bool**| | [optional] + **enrollment_flow** | **UUID**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **password_stage** | **UUID**| | [optional] + **passwordless_flow** | **UUID**| | [optional] + **recovery_flow** | **UUID**| | [optional] + **search** | **str**| A search term. | [optional] + **show_matched_user** | **bool**| | [optional] + **show_source_labels** | **bool**| | [optional] + **webauthn_stage** | **UUID**| | [optional] + +### Return type + +[**PaginatedIdentificationStageList**](PaginatedIdentificationStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_identification_partial_update** +> IdentificationStage stages_identification_partial_update(stage_uuid, patched_identification_stage_request=patched_identification_stage_request) + +IdentificationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.identification_stage import IdentificationStage +from authentik_client.models.patched_identification_stage_request import PatchedIdentificationStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Identification Stage. + patched_identification_stage_request = authentik_client.PatchedIdentificationStageRequest() # PatchedIdentificationStageRequest | (optional) + + try: + api_response = api_instance.stages_identification_partial_update(stage_uuid, patched_identification_stage_request=patched_identification_stage_request) + print("The response of StagesApi->stages_identification_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_identification_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Identification Stage. | + **patched_identification_stage_request** | [**PatchedIdentificationStageRequest**](PatchedIdentificationStageRequest.md)| | [optional] + +### Return type + +[**IdentificationStage**](IdentificationStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_identification_retrieve** +> IdentificationStage stages_identification_retrieve(stage_uuid) + +IdentificationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.identification_stage import IdentificationStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Identification Stage. + + try: + api_response = api_instance.stages_identification_retrieve(stage_uuid) + print("The response of StagesApi->stages_identification_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_identification_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Identification Stage. | + +### Return type + +[**IdentificationStage**](IdentificationStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_identification_update** +> IdentificationStage stages_identification_update(stage_uuid, identification_stage_request) + +IdentificationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.identification_stage import IdentificationStage +from authentik_client.models.identification_stage_request import IdentificationStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Identification Stage. + identification_stage_request = authentik_client.IdentificationStageRequest() # IdentificationStageRequest | + + try: + api_response = api_instance.stages_identification_update(stage_uuid, identification_stage_request) + print("The response of StagesApi->stages_identification_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_identification_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Identification Stage. | + **identification_stage_request** | [**IdentificationStageRequest**](IdentificationStageRequest.md)| | + +### Return type + +[**IdentificationStage**](IdentificationStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_identification_used_by_list** +> List[UsedBy] stages_identification_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Identification Stage. + + try: + api_response = api_instance.stages_identification_used_by_list(stage_uuid) + print("The response of StagesApi->stages_identification_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_identification_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Identification Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_invitations_create** +> Invitation stages_invitation_invitations_create(invitation_request) + +Invitation Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.invitation import Invitation +from authentik_client.models.invitation_request import InvitationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + invitation_request = authentik_client.InvitationRequest() # InvitationRequest | + + try: + api_response = api_instance.stages_invitation_invitations_create(invitation_request) + print("The response of StagesApi->stages_invitation_invitations_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_invitations_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **invitation_request** | [**InvitationRequest**](InvitationRequest.md)| | + +### Return type + +[**Invitation**](Invitation.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_invitations_destroy** +> stages_invitation_invitations_destroy(invite_uuid) + +Invitation Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + invite_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation. + + try: + api_instance.stages_invitation_invitations_destroy(invite_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_invitations_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **invite_uuid** | **UUID**| A UUID string identifying this Invitation. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_invitations_list** +> PaginatedInvitationList stages_invitation_invitations_list(created_by__username=created_by__username, expires=expires, flow__slug=flow__slug, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +Invitation Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_invitation_list import PaginatedInvitationList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + created_by__username = 'created_by__username_example' # str | (optional) + expires = '2013-10-20T19:20:30+01:00' # datetime | (optional) + flow__slug = 'flow__slug_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_invitation_invitations_list(created_by__username=created_by__username, expires=expires, flow__slug=flow__slug, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of StagesApi->stages_invitation_invitations_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_invitations_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **created_by__username** | **str**| | [optional] + **expires** | **datetime**| | [optional] + **flow__slug** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedInvitationList**](PaginatedInvitationList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_invitations_partial_update** +> Invitation stages_invitation_invitations_partial_update(invite_uuid, patched_invitation_request=patched_invitation_request) + +Invitation Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.invitation import Invitation +from authentik_client.models.patched_invitation_request import PatchedInvitationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + invite_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation. + patched_invitation_request = authentik_client.PatchedInvitationRequest() # PatchedInvitationRequest | (optional) + + try: + api_response = api_instance.stages_invitation_invitations_partial_update(invite_uuid, patched_invitation_request=patched_invitation_request) + print("The response of StagesApi->stages_invitation_invitations_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_invitations_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **invite_uuid** | **UUID**| A UUID string identifying this Invitation. | + **patched_invitation_request** | [**PatchedInvitationRequest**](PatchedInvitationRequest.md)| | [optional] + +### Return type + +[**Invitation**](Invitation.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_invitations_retrieve** +> Invitation stages_invitation_invitations_retrieve(invite_uuid) + +Invitation Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.invitation import Invitation +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + invite_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation. + + try: + api_response = api_instance.stages_invitation_invitations_retrieve(invite_uuid) + print("The response of StagesApi->stages_invitation_invitations_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_invitations_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **invite_uuid** | **UUID**| A UUID string identifying this Invitation. | + +### Return type + +[**Invitation**](Invitation.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_invitations_send_email_create** +> stages_invitation_invitations_send_email_create(invite_uuid, invitation_send_email_request) + +Send invitation link via email to one or more addresses + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.invitation_send_email_request import InvitationSendEmailRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + invite_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation. + invitation_send_email_request = authentik_client.InvitationSendEmailRequest() # InvitationSendEmailRequest | + + try: + api_instance.stages_invitation_invitations_send_email_create(invite_uuid, invitation_send_email_request) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_invitations_send_email_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **invite_uuid** | **UUID**| A UUID string identifying this Invitation. | + **invitation_send_email_request** | [**InvitationSendEmailRequest**](InvitationSendEmailRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_invitations_update** +> Invitation stages_invitation_invitations_update(invite_uuid, invitation_request) + +Invitation Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.invitation import Invitation +from authentik_client.models.invitation_request import InvitationRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + invite_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation. + invitation_request = authentik_client.InvitationRequest() # InvitationRequest | + + try: + api_response = api_instance.stages_invitation_invitations_update(invite_uuid, invitation_request) + print("The response of StagesApi->stages_invitation_invitations_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_invitations_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **invite_uuid** | **UUID**| A UUID string identifying this Invitation. | + **invitation_request** | [**InvitationRequest**](InvitationRequest.md)| | + +### Return type + +[**Invitation**](Invitation.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_invitations_used_by_list** +> List[UsedBy] stages_invitation_invitations_used_by_list(invite_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + invite_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation. + + try: + api_response = api_instance.stages_invitation_invitations_used_by_list(invite_uuid) + print("The response of StagesApi->stages_invitation_invitations_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_invitations_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **invite_uuid** | **UUID**| A UUID string identifying this Invitation. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_stages_create** +> InvitationStage stages_invitation_stages_create(invitation_stage_request) + +InvitationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.invitation_stage import InvitationStage +from authentik_client.models.invitation_stage_request import InvitationStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + invitation_stage_request = authentik_client.InvitationStageRequest() # InvitationStageRequest | + + try: + api_response = api_instance.stages_invitation_stages_create(invitation_stage_request) + print("The response of StagesApi->stages_invitation_stages_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_stages_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **invitation_stage_request** | [**InvitationStageRequest**](InvitationStageRequest.md)| | + +### Return type + +[**InvitationStage**](InvitationStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_stages_destroy** +> stages_invitation_stages_destroy(stage_uuid) + +InvitationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation Stage. + + try: + api_instance.stages_invitation_stages_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_stages_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Invitation Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_stages_list** +> PaginatedInvitationStageList stages_invitation_stages_list(continue_flow_without_invitation=continue_flow_without_invitation, name=name, no_flows=no_flows, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + +InvitationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_invitation_stage_list import PaginatedInvitationStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + continue_flow_without_invitation = True # bool | (optional) + name = 'name_example' # str | (optional) + no_flows = True # bool | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.stages_invitation_stages_list(continue_flow_without_invitation=continue_flow_without_invitation, name=name, no_flows=no_flows, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + print("The response of StagesApi->stages_invitation_stages_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_stages_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **continue_flow_without_invitation** | **bool**| | [optional] + **name** | **str**| | [optional] + **no_flows** | **bool**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedInvitationStageList**](PaginatedInvitationStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_stages_partial_update** +> InvitationStage stages_invitation_stages_partial_update(stage_uuid, patched_invitation_stage_request=patched_invitation_stage_request) + +InvitationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.invitation_stage import InvitationStage +from authentik_client.models.patched_invitation_stage_request import PatchedInvitationStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation Stage. + patched_invitation_stage_request = authentik_client.PatchedInvitationStageRequest() # PatchedInvitationStageRequest | (optional) + + try: + api_response = api_instance.stages_invitation_stages_partial_update(stage_uuid, patched_invitation_stage_request=patched_invitation_stage_request) + print("The response of StagesApi->stages_invitation_stages_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_stages_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Invitation Stage. | + **patched_invitation_stage_request** | [**PatchedInvitationStageRequest**](PatchedInvitationStageRequest.md)| | [optional] + +### Return type + +[**InvitationStage**](InvitationStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_stages_retrieve** +> InvitationStage stages_invitation_stages_retrieve(stage_uuid) + +InvitationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.invitation_stage import InvitationStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation Stage. + + try: + api_response = api_instance.stages_invitation_stages_retrieve(stage_uuid) + print("The response of StagesApi->stages_invitation_stages_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_stages_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Invitation Stage. | + +### Return type + +[**InvitationStage**](InvitationStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_stages_update** +> InvitationStage stages_invitation_stages_update(stage_uuid, invitation_stage_request) + +InvitationStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.invitation_stage import InvitationStage +from authentik_client.models.invitation_stage_request import InvitationStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation Stage. + invitation_stage_request = authentik_client.InvitationStageRequest() # InvitationStageRequest | + + try: + api_response = api_instance.stages_invitation_stages_update(stage_uuid, invitation_stage_request) + print("The response of StagesApi->stages_invitation_stages_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_stages_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Invitation Stage. | + **invitation_stage_request** | [**InvitationStageRequest**](InvitationStageRequest.md)| | + +### Return type + +[**InvitationStage**](InvitationStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_invitation_stages_used_by_list** +> List[UsedBy] stages_invitation_stages_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Invitation Stage. + + try: + api_response = api_instance.stages_invitation_stages_used_by_list(stage_uuid) + print("The response of StagesApi->stages_invitation_stages_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_invitation_stages_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Invitation Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_mtls_create** +> MutualTLSStage stages_mtls_create(mutual_tls_stage_request) + +MutualTLSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.mutual_tls_stage import MutualTLSStage +from authentik_client.models.mutual_tls_stage_request import MutualTLSStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + mutual_tls_stage_request = authentik_client.MutualTLSStageRequest() # MutualTLSStageRequest | + + try: + api_response = api_instance.stages_mtls_create(mutual_tls_stage_request) + print("The response of StagesApi->stages_mtls_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_mtls_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **mutual_tls_stage_request** | [**MutualTLSStageRequest**](MutualTLSStageRequest.md)| | + +### Return type + +[**MutualTLSStage**](MutualTLSStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_mtls_destroy** +> stages_mtls_destroy(stage_uuid) + +MutualTLSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Mutual TLS Stage. + + try: + api_instance.stages_mtls_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_mtls_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Mutual TLS Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_mtls_list** +> PaginatedMutualTLSStageList stages_mtls_list(cert_attribute=cert_attribute, certificate_authorities=certificate_authorities, mode=mode, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, user_attribute=user_attribute) + +MutualTLSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.cert_attribute_enum import CertAttributeEnum +from authentik_client.models.paginated_mutual_tls_stage_list import PaginatedMutualTLSStageList +from authentik_client.models.stage_mode_enum import StageModeEnum +from authentik_client.models.user_attribute_enum import UserAttributeEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + cert_attribute = authentik_client.CertAttributeEnum() # CertAttributeEnum | (optional) + certificate_authorities = None # List[UUID] | (optional) + mode = authentik_client.StageModeEnum() # StageModeEnum | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + user_attribute = authentik_client.UserAttributeEnum() # UserAttributeEnum | (optional) + + try: + api_response = api_instance.stages_mtls_list(cert_attribute=cert_attribute, certificate_authorities=certificate_authorities, mode=mode, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, user_attribute=user_attribute) + print("The response of StagesApi->stages_mtls_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_mtls_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **cert_attribute** | [**CertAttributeEnum**](.md)| | [optional] + **certificate_authorities** | [**List[UUID]**](UUID.md)| | [optional] + **mode** | [**StageModeEnum**](.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + **user_attribute** | [**UserAttributeEnum**](.md)| | [optional] + +### Return type + +[**PaginatedMutualTLSStageList**](PaginatedMutualTLSStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_mtls_partial_update** +> MutualTLSStage stages_mtls_partial_update(stage_uuid, patched_mutual_tls_stage_request=patched_mutual_tls_stage_request) + +MutualTLSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.mutual_tls_stage import MutualTLSStage +from authentik_client.models.patched_mutual_tls_stage_request import PatchedMutualTLSStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Mutual TLS Stage. + patched_mutual_tls_stage_request = authentik_client.PatchedMutualTLSStageRequest() # PatchedMutualTLSStageRequest | (optional) + + try: + api_response = api_instance.stages_mtls_partial_update(stage_uuid, patched_mutual_tls_stage_request=patched_mutual_tls_stage_request) + print("The response of StagesApi->stages_mtls_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_mtls_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Mutual TLS Stage. | + **patched_mutual_tls_stage_request** | [**PatchedMutualTLSStageRequest**](PatchedMutualTLSStageRequest.md)| | [optional] + +### Return type + +[**MutualTLSStage**](MutualTLSStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_mtls_retrieve** +> MutualTLSStage stages_mtls_retrieve(stage_uuid) + +MutualTLSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.mutual_tls_stage import MutualTLSStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Mutual TLS Stage. + + try: + api_response = api_instance.stages_mtls_retrieve(stage_uuid) + print("The response of StagesApi->stages_mtls_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_mtls_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Mutual TLS Stage. | + +### Return type + +[**MutualTLSStage**](MutualTLSStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_mtls_update** +> MutualTLSStage stages_mtls_update(stage_uuid, mutual_tls_stage_request) + +MutualTLSStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.mutual_tls_stage import MutualTLSStage +from authentik_client.models.mutual_tls_stage_request import MutualTLSStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Mutual TLS Stage. + mutual_tls_stage_request = authentik_client.MutualTLSStageRequest() # MutualTLSStageRequest | + + try: + api_response = api_instance.stages_mtls_update(stage_uuid, mutual_tls_stage_request) + print("The response of StagesApi->stages_mtls_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_mtls_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Mutual TLS Stage. | + **mutual_tls_stage_request** | [**MutualTLSStageRequest**](MutualTLSStageRequest.md)| | + +### Return type + +[**MutualTLSStage**](MutualTLSStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_mtls_used_by_list** +> List[UsedBy] stages_mtls_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Mutual TLS Stage. + + try: + api_response = api_instance.stages_mtls_used_by_list(stage_uuid) + print("The response of StagesApi->stages_mtls_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_mtls_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Mutual TLS Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_password_create** +> PasswordStage stages_password_create(password_stage_request) + +PasswordStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_stage import PasswordStage +from authentik_client.models.password_stage_request import PasswordStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + password_stage_request = authentik_client.PasswordStageRequest() # PasswordStageRequest | + + try: + api_response = api_instance.stages_password_create(password_stage_request) + print("The response of StagesApi->stages_password_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_password_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **password_stage_request** | [**PasswordStageRequest**](PasswordStageRequest.md)| | + +### Return type + +[**PasswordStage**](PasswordStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_password_destroy** +> stages_password_destroy(stage_uuid) + +PasswordStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Stage. + + try: + api_instance.stages_password_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_password_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Password Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_password_list** +> PaginatedPasswordStageList stages_password_list(allow_show_password=allow_show_password, configure_flow=configure_flow, failed_attempts_before_cancel=failed_attempts_before_cancel, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +PasswordStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_password_stage_list import PaginatedPasswordStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + allow_show_password = True # bool | (optional) + configure_flow = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + failed_attempts_before_cancel = 56 # int | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_password_list(allow_show_password=allow_show_password, configure_flow=configure_flow, failed_attempts_before_cancel=failed_attempts_before_cancel, name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of StagesApi->stages_password_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_password_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **allow_show_password** | **bool**| | [optional] + **configure_flow** | **UUID**| | [optional] + **failed_attempts_before_cancel** | **int**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedPasswordStageList**](PaginatedPasswordStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_password_partial_update** +> PasswordStage stages_password_partial_update(stage_uuid, patched_password_stage_request=patched_password_stage_request) + +PasswordStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_stage import PasswordStage +from authentik_client.models.patched_password_stage_request import PatchedPasswordStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Stage. + patched_password_stage_request = authentik_client.PatchedPasswordStageRequest() # PatchedPasswordStageRequest | (optional) + + try: + api_response = api_instance.stages_password_partial_update(stage_uuid, patched_password_stage_request=patched_password_stage_request) + print("The response of StagesApi->stages_password_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_password_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Password Stage. | + **patched_password_stage_request** | [**PatchedPasswordStageRequest**](PatchedPasswordStageRequest.md)| | [optional] + +### Return type + +[**PasswordStage**](PasswordStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_password_retrieve** +> PasswordStage stages_password_retrieve(stage_uuid) + +PasswordStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_stage import PasswordStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Stage. + + try: + api_response = api_instance.stages_password_retrieve(stage_uuid) + print("The response of StagesApi->stages_password_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_password_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Password Stage. | + +### Return type + +[**PasswordStage**](PasswordStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_password_update** +> PasswordStage stages_password_update(stage_uuid, password_stage_request) + +PasswordStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.password_stage import PasswordStage +from authentik_client.models.password_stage_request import PasswordStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Stage. + password_stage_request = authentik_client.PasswordStageRequest() # PasswordStageRequest | + + try: + api_response = api_instance.stages_password_update(stage_uuid, password_stage_request) + print("The response of StagesApi->stages_password_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_password_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Password Stage. | + **password_stage_request** | [**PasswordStageRequest**](PasswordStageRequest.md)| | + +### Return type + +[**PasswordStage**](PasswordStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_password_used_by_list** +> List[UsedBy] stages_password_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Password Stage. + + try: + api_response = api_instance.stages_password_used_by_list(stage_uuid) + print("The response of StagesApi->stages_password_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_password_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Password Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_prompts_create** +> Prompt stages_prompt_prompts_create(prompt_request) + +Prompt Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.prompt import Prompt +from authentik_client.models.prompt_request import PromptRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + prompt_request = authentik_client.PromptRequest() # PromptRequest | + + try: + api_response = api_instance.stages_prompt_prompts_create(prompt_request) + print("The response of StagesApi->stages_prompt_prompts_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_prompts_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **prompt_request** | [**PromptRequest**](PromptRequest.md)| | + +### Return type + +[**Prompt**](Prompt.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_prompts_destroy** +> stages_prompt_prompts_destroy(prompt_uuid) + +Prompt Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + prompt_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt. + + try: + api_instance.stages_prompt_prompts_destroy(prompt_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_prompts_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **prompt_uuid** | **UUID**| A UUID string identifying this Prompt. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_prompts_list** +> PaginatedPromptList stages_prompt_prompts_list(field_key=field_key, label=label, name=name, ordering=ordering, page=page, page_size=page_size, placeholder=placeholder, search=search, type=type) + +Prompt Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_prompt_list import PaginatedPromptList +from authentik_client.models.prompt_type_enum import PromptTypeEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + field_key = 'field_key_example' # str | (optional) + label = 'label_example' # str | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + placeholder = 'placeholder_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + type = authentik_client.PromptTypeEnum() # PromptTypeEnum | (optional) + + try: + api_response = api_instance.stages_prompt_prompts_list(field_key=field_key, label=label, name=name, ordering=ordering, page=page, page_size=page_size, placeholder=placeholder, search=search, type=type) + print("The response of StagesApi->stages_prompt_prompts_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_prompts_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **field_key** | **str**| | [optional] + **label** | **str**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **placeholder** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + **type** | [**PromptTypeEnum**](.md)| | [optional] + +### Return type + +[**PaginatedPromptList**](PaginatedPromptList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_prompts_partial_update** +> Prompt stages_prompt_prompts_partial_update(prompt_uuid, patched_prompt_request=patched_prompt_request) + +Prompt Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_prompt_request import PatchedPromptRequest +from authentik_client.models.prompt import Prompt +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + prompt_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt. + patched_prompt_request = authentik_client.PatchedPromptRequest() # PatchedPromptRequest | (optional) + + try: + api_response = api_instance.stages_prompt_prompts_partial_update(prompt_uuid, patched_prompt_request=patched_prompt_request) + print("The response of StagesApi->stages_prompt_prompts_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_prompts_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **prompt_uuid** | **UUID**| A UUID string identifying this Prompt. | + **patched_prompt_request** | [**PatchedPromptRequest**](PatchedPromptRequest.md)| | [optional] + +### Return type + +[**Prompt**](Prompt.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_prompts_preview_create** +> PromptChallenge stages_prompt_prompts_preview_create(prompt_request) + +Preview a prompt as a challenge, just like a flow would receive + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.prompt_challenge import PromptChallenge +from authentik_client.models.prompt_request import PromptRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + prompt_request = authentik_client.PromptRequest() # PromptRequest | + + try: + api_response = api_instance.stages_prompt_prompts_preview_create(prompt_request) + print("The response of StagesApi->stages_prompt_prompts_preview_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_prompts_preview_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **prompt_request** | [**PromptRequest**](PromptRequest.md)| | + +### Return type + +[**PromptChallenge**](PromptChallenge.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_prompts_retrieve** +> Prompt stages_prompt_prompts_retrieve(prompt_uuid) + +Prompt Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.prompt import Prompt +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + prompt_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt. + + try: + api_response = api_instance.stages_prompt_prompts_retrieve(prompt_uuid) + print("The response of StagesApi->stages_prompt_prompts_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_prompts_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **prompt_uuid** | **UUID**| A UUID string identifying this Prompt. | + +### Return type + +[**Prompt**](Prompt.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_prompts_update** +> Prompt stages_prompt_prompts_update(prompt_uuid, prompt_request) + +Prompt Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.prompt import Prompt +from authentik_client.models.prompt_request import PromptRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + prompt_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt. + prompt_request = authentik_client.PromptRequest() # PromptRequest | + + try: + api_response = api_instance.stages_prompt_prompts_update(prompt_uuid, prompt_request) + print("The response of StagesApi->stages_prompt_prompts_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_prompts_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **prompt_uuid** | **UUID**| A UUID string identifying this Prompt. | + **prompt_request** | [**PromptRequest**](PromptRequest.md)| | + +### Return type + +[**Prompt**](Prompt.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_prompts_used_by_list** +> List[UsedBy] stages_prompt_prompts_used_by_list(prompt_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + prompt_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt. + + try: + api_response = api_instance.stages_prompt_prompts_used_by_list(prompt_uuid) + print("The response of StagesApi->stages_prompt_prompts_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_prompts_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **prompt_uuid** | **UUID**| A UUID string identifying this Prompt. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_stages_create** +> PromptStage stages_prompt_stages_create(prompt_stage_request) + +PromptStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.prompt_stage import PromptStage +from authentik_client.models.prompt_stage_request import PromptStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + prompt_stage_request = authentik_client.PromptStageRequest() # PromptStageRequest | + + try: + api_response = api_instance.stages_prompt_stages_create(prompt_stage_request) + print("The response of StagesApi->stages_prompt_stages_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_stages_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **prompt_stage_request** | [**PromptStageRequest**](PromptStageRequest.md)| | + +### Return type + +[**PromptStage**](PromptStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_stages_destroy** +> stages_prompt_stages_destroy(stage_uuid) + +PromptStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt Stage. + + try: + api_instance.stages_prompt_stages_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_stages_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Prompt Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_stages_list** +> PaginatedPromptStageList stages_prompt_stages_list(fields=fields, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, validation_policies=validation_policies) + +PromptStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_prompt_stage_list import PaginatedPromptStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + fields = None # List[UUID] | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + validation_policies = None # List[UUID] | (optional) + + try: + api_response = api_instance.stages_prompt_stages_list(fields=fields, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, validation_policies=validation_policies) + print("The response of StagesApi->stages_prompt_stages_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_stages_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **fields** | [**List[UUID]**](UUID.md)| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + **validation_policies** | [**List[UUID]**](UUID.md)| | [optional] + +### Return type + +[**PaginatedPromptStageList**](PaginatedPromptStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_stages_partial_update** +> PromptStage stages_prompt_stages_partial_update(stage_uuid, patched_prompt_stage_request=patched_prompt_stage_request) + +PromptStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_prompt_stage_request import PatchedPromptStageRequest +from authentik_client.models.prompt_stage import PromptStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt Stage. + patched_prompt_stage_request = authentik_client.PatchedPromptStageRequest() # PatchedPromptStageRequest | (optional) + + try: + api_response = api_instance.stages_prompt_stages_partial_update(stage_uuid, patched_prompt_stage_request=patched_prompt_stage_request) + print("The response of StagesApi->stages_prompt_stages_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_stages_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Prompt Stage. | + **patched_prompt_stage_request** | [**PatchedPromptStageRequest**](PatchedPromptStageRequest.md)| | [optional] + +### Return type + +[**PromptStage**](PromptStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_stages_retrieve** +> PromptStage stages_prompt_stages_retrieve(stage_uuid) + +PromptStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.prompt_stage import PromptStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt Stage. + + try: + api_response = api_instance.stages_prompt_stages_retrieve(stage_uuid) + print("The response of StagesApi->stages_prompt_stages_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_stages_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Prompt Stage. | + +### Return type + +[**PromptStage**](PromptStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_stages_update** +> PromptStage stages_prompt_stages_update(stage_uuid, prompt_stage_request) + +PromptStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.prompt_stage import PromptStage +from authentik_client.models.prompt_stage_request import PromptStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt Stage. + prompt_stage_request = authentik_client.PromptStageRequest() # PromptStageRequest | + + try: + api_response = api_instance.stages_prompt_stages_update(stage_uuid, prompt_stage_request) + print("The response of StagesApi->stages_prompt_stages_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_stages_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Prompt Stage. | + **prompt_stage_request** | [**PromptStageRequest**](PromptStageRequest.md)| | + +### Return type + +[**PromptStage**](PromptStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_prompt_stages_used_by_list** +> List[UsedBy] stages_prompt_stages_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Prompt Stage. + + try: + api_response = api_instance.stages_prompt_stages_used_by_list(stage_uuid) + print("The response of StagesApi->stages_prompt_stages_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_prompt_stages_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Prompt Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_redirect_create** +> RedirectStage stages_redirect_create(redirect_stage_request) + +RedirectStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.redirect_stage import RedirectStage +from authentik_client.models.redirect_stage_request import RedirectStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + redirect_stage_request = authentik_client.RedirectStageRequest() # RedirectStageRequest | + + try: + api_response = api_instance.stages_redirect_create(redirect_stage_request) + print("The response of StagesApi->stages_redirect_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_redirect_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **redirect_stage_request** | [**RedirectStageRequest**](RedirectStageRequest.md)| | + +### Return type + +[**RedirectStage**](RedirectStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_redirect_destroy** +> stages_redirect_destroy(stage_uuid) + +RedirectStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Redirect Stage. + + try: + api_instance.stages_redirect_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_redirect_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Redirect Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_redirect_list** +> PaginatedRedirectStageList stages_redirect_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + +RedirectStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_redirect_stage_list import PaginatedRedirectStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.stages_redirect_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of StagesApi->stages_redirect_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_redirect_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedRedirectStageList**](PaginatedRedirectStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_redirect_partial_update** +> RedirectStage stages_redirect_partial_update(stage_uuid, patched_redirect_stage_request=patched_redirect_stage_request) + +RedirectStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_redirect_stage_request import PatchedRedirectStageRequest +from authentik_client.models.redirect_stage import RedirectStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Redirect Stage. + patched_redirect_stage_request = authentik_client.PatchedRedirectStageRequest() # PatchedRedirectStageRequest | (optional) + + try: + api_response = api_instance.stages_redirect_partial_update(stage_uuid, patched_redirect_stage_request=patched_redirect_stage_request) + print("The response of StagesApi->stages_redirect_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_redirect_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Redirect Stage. | + **patched_redirect_stage_request** | [**PatchedRedirectStageRequest**](PatchedRedirectStageRequest.md)| | [optional] + +### Return type + +[**RedirectStage**](RedirectStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_redirect_retrieve** +> RedirectStage stages_redirect_retrieve(stage_uuid) + +RedirectStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.redirect_stage import RedirectStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Redirect Stage. + + try: + api_response = api_instance.stages_redirect_retrieve(stage_uuid) + print("The response of StagesApi->stages_redirect_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_redirect_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Redirect Stage. | + +### Return type + +[**RedirectStage**](RedirectStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_redirect_update** +> RedirectStage stages_redirect_update(stage_uuid, redirect_stage_request) + +RedirectStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.redirect_stage import RedirectStage +from authentik_client.models.redirect_stage_request import RedirectStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Redirect Stage. + redirect_stage_request = authentik_client.RedirectStageRequest() # RedirectStageRequest | + + try: + api_response = api_instance.stages_redirect_update(stage_uuid, redirect_stage_request) + print("The response of StagesApi->stages_redirect_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_redirect_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Redirect Stage. | + **redirect_stage_request** | [**RedirectStageRequest**](RedirectStageRequest.md)| | + +### Return type + +[**RedirectStage**](RedirectStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_redirect_used_by_list** +> List[UsedBy] stages_redirect_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Redirect Stage. + + try: + api_response = api_instance.stages_redirect_used_by_list(stage_uuid) + print("The response of StagesApi->stages_redirect_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_redirect_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Redirect Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_source_create** +> SourceStage stages_source_create(source_stage_request) + +SourceStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.source_stage import SourceStage +from authentik_client.models.source_stage_request import SourceStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + source_stage_request = authentik_client.SourceStageRequest() # SourceStageRequest | + + try: + api_response = api_instance.stages_source_create(source_stage_request) + print("The response of StagesApi->stages_source_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_source_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **source_stage_request** | [**SourceStageRequest**](SourceStageRequest.md)| | + +### Return type + +[**SourceStage**](SourceStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_source_destroy** +> stages_source_destroy(stage_uuid) + +SourceStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Source Stage. + + try: + api_instance.stages_source_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_source_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Source Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_source_list** +> PaginatedSourceStageList stages_source_list(name=name, ordering=ordering, page=page, page_size=page_size, resume_timeout=resume_timeout, search=search, source=source, stage_uuid=stage_uuid) + +SourceStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_source_stage_list import PaginatedSourceStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + resume_timeout = 'resume_timeout_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + source = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.stages_source_list(name=name, ordering=ordering, page=page, page_size=page_size, resume_timeout=resume_timeout, search=search, source=source, stage_uuid=stage_uuid) + print("The response of StagesApi->stages_source_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_source_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **resume_timeout** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + **source** | **UUID**| | [optional] + **stage_uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedSourceStageList**](PaginatedSourceStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_source_partial_update** +> SourceStage stages_source_partial_update(stage_uuid, patched_source_stage_request=patched_source_stage_request) + +SourceStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_source_stage_request import PatchedSourceStageRequest +from authentik_client.models.source_stage import SourceStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Source Stage. + patched_source_stage_request = authentik_client.PatchedSourceStageRequest() # PatchedSourceStageRequest | (optional) + + try: + api_response = api_instance.stages_source_partial_update(stage_uuid, patched_source_stage_request=patched_source_stage_request) + print("The response of StagesApi->stages_source_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_source_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Source Stage. | + **patched_source_stage_request** | [**PatchedSourceStageRequest**](PatchedSourceStageRequest.md)| | [optional] + +### Return type + +[**SourceStage**](SourceStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_source_retrieve** +> SourceStage stages_source_retrieve(stage_uuid) + +SourceStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.source_stage import SourceStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Source Stage. + + try: + api_response = api_instance.stages_source_retrieve(stage_uuid) + print("The response of StagesApi->stages_source_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_source_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Source Stage. | + +### Return type + +[**SourceStage**](SourceStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_source_update** +> SourceStage stages_source_update(stage_uuid, source_stage_request) + +SourceStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.source_stage import SourceStage +from authentik_client.models.source_stage_request import SourceStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Source Stage. + source_stage_request = authentik_client.SourceStageRequest() # SourceStageRequest | + + try: + api_response = api_instance.stages_source_update(stage_uuid, source_stage_request) + print("The response of StagesApi->stages_source_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_source_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Source Stage. | + **source_stage_request** | [**SourceStageRequest**](SourceStageRequest.md)| | + +### Return type + +[**SourceStage**](SourceStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_source_used_by_list** +> List[UsedBy] stages_source_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Source Stage. + + try: + api_response = api_instance.stages_source_used_by_list(stage_uuid) + print("The response of StagesApi->stages_source_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_source_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this Source Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_delete_create** +> UserDeleteStage stages_user_delete_create(user_delete_stage_request) + +UserDeleteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_delete_stage import UserDeleteStage +from authentik_client.models.user_delete_stage_request import UserDeleteStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + user_delete_stage_request = authentik_client.UserDeleteStageRequest() # UserDeleteStageRequest | + + try: + api_response = api_instance.stages_user_delete_create(user_delete_stage_request) + print("The response of StagesApi->stages_user_delete_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_delete_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_delete_stage_request** | [**UserDeleteStageRequest**](UserDeleteStageRequest.md)| | + +### Return type + +[**UserDeleteStage**](UserDeleteStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_delete_destroy** +> stages_user_delete_destroy(stage_uuid) + +UserDeleteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Delete Stage. + + try: + api_instance.stages_user_delete_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_user_delete_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Delete Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_delete_list** +> PaginatedUserDeleteStageList stages_user_delete_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + +UserDeleteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_delete_stage_list import PaginatedUserDeleteStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.stages_user_delete_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + print("The response of StagesApi->stages_user_delete_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_delete_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedUserDeleteStageList**](PaginatedUserDeleteStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_delete_partial_update** +> UserDeleteStage stages_user_delete_partial_update(stage_uuid, patched_user_delete_stage_request=patched_user_delete_stage_request) + +UserDeleteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_delete_stage_request import PatchedUserDeleteStageRequest +from authentik_client.models.user_delete_stage import UserDeleteStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Delete Stage. + patched_user_delete_stage_request = authentik_client.PatchedUserDeleteStageRequest() # PatchedUserDeleteStageRequest | (optional) + + try: + api_response = api_instance.stages_user_delete_partial_update(stage_uuid, patched_user_delete_stage_request=patched_user_delete_stage_request) + print("The response of StagesApi->stages_user_delete_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_delete_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Delete Stage. | + **patched_user_delete_stage_request** | [**PatchedUserDeleteStageRequest**](PatchedUserDeleteStageRequest.md)| | [optional] + +### Return type + +[**UserDeleteStage**](UserDeleteStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_delete_retrieve** +> UserDeleteStage stages_user_delete_retrieve(stage_uuid) + +UserDeleteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_delete_stage import UserDeleteStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Delete Stage. + + try: + api_response = api_instance.stages_user_delete_retrieve(stage_uuid) + print("The response of StagesApi->stages_user_delete_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_delete_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Delete Stage. | + +### Return type + +[**UserDeleteStage**](UserDeleteStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_delete_update** +> UserDeleteStage stages_user_delete_update(stage_uuid, user_delete_stage_request) + +UserDeleteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_delete_stage import UserDeleteStage +from authentik_client.models.user_delete_stage_request import UserDeleteStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Delete Stage. + user_delete_stage_request = authentik_client.UserDeleteStageRequest() # UserDeleteStageRequest | + + try: + api_response = api_instance.stages_user_delete_update(stage_uuid, user_delete_stage_request) + print("The response of StagesApi->stages_user_delete_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_delete_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Delete Stage. | + **user_delete_stage_request** | [**UserDeleteStageRequest**](UserDeleteStageRequest.md)| | + +### Return type + +[**UserDeleteStage**](UserDeleteStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_delete_used_by_list** +> List[UsedBy] stages_user_delete_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Delete Stage. + + try: + api_response = api_instance.stages_user_delete_used_by_list(stage_uuid) + print("The response of StagesApi->stages_user_delete_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_delete_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Delete Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_login_create** +> UserLoginStage stages_user_login_create(user_login_stage_request) + +UserLoginStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_login_stage import UserLoginStage +from authentik_client.models.user_login_stage_request import UserLoginStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + user_login_stage_request = authentik_client.UserLoginStageRequest() # UserLoginStageRequest | + + try: + api_response = api_instance.stages_user_login_create(user_login_stage_request) + print("The response of StagesApi->stages_user_login_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_login_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_login_stage_request** | [**UserLoginStageRequest**](UserLoginStageRequest.md)| | + +### Return type + +[**UserLoginStage**](UserLoginStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_login_destroy** +> stages_user_login_destroy(stage_uuid) + +UserLoginStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Login Stage. + + try: + api_instance.stages_user_login_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_user_login_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Login Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_login_list** +> PaginatedUserLoginStageList stages_user_login_list(geoip_binding=geoip_binding, name=name, network_binding=network_binding, ordering=ordering, page=page, page_size=page_size, remember_device=remember_device, remember_me_offset=remember_me_offset, search=search, session_duration=session_duration, stage_uuid=stage_uuid, terminate_other_sessions=terminate_other_sessions) + +UserLoginStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_login_stage_list import PaginatedUserLoginStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + geoip_binding = authentik_client.GeoipBindingEnum() # GeoipBindingEnum | (optional) + name = 'name_example' # str | (optional) + network_binding = authentik_client.NetworkBindingEnum() # NetworkBindingEnum | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + remember_device = 'remember_device_example' # str | (optional) + remember_me_offset = 'remember_me_offset_example' # str | (optional) + search = 'search_example' # str | A search term. (optional) + session_duration = 'session_duration_example' # str | (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + terminate_other_sessions = True # bool | (optional) + + try: + api_response = api_instance.stages_user_login_list(geoip_binding=geoip_binding, name=name, network_binding=network_binding, ordering=ordering, page=page, page_size=page_size, remember_device=remember_device, remember_me_offset=remember_me_offset, search=search, session_duration=session_duration, stage_uuid=stage_uuid, terminate_other_sessions=terminate_other_sessions) + print("The response of StagesApi->stages_user_login_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_login_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **geoip_binding** | [**GeoipBindingEnum**](.md)| | [optional] + **name** | **str**| | [optional] + **network_binding** | [**NetworkBindingEnum**](.md)| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **remember_device** | **str**| | [optional] + **remember_me_offset** | **str**| | [optional] + **search** | **str**| A search term. | [optional] + **session_duration** | **str**| | [optional] + **stage_uuid** | **UUID**| | [optional] + **terminate_other_sessions** | **bool**| | [optional] + +### Return type + +[**PaginatedUserLoginStageList**](PaginatedUserLoginStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_login_partial_update** +> UserLoginStage stages_user_login_partial_update(stage_uuid, patched_user_login_stage_request=patched_user_login_stage_request) + +UserLoginStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_login_stage_request import PatchedUserLoginStageRequest +from authentik_client.models.user_login_stage import UserLoginStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Login Stage. + patched_user_login_stage_request = authentik_client.PatchedUserLoginStageRequest() # PatchedUserLoginStageRequest | (optional) + + try: + api_response = api_instance.stages_user_login_partial_update(stage_uuid, patched_user_login_stage_request=patched_user_login_stage_request) + print("The response of StagesApi->stages_user_login_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_login_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Login Stage. | + **patched_user_login_stage_request** | [**PatchedUserLoginStageRequest**](PatchedUserLoginStageRequest.md)| | [optional] + +### Return type + +[**UserLoginStage**](UserLoginStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_login_retrieve** +> UserLoginStage stages_user_login_retrieve(stage_uuid) + +UserLoginStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_login_stage import UserLoginStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Login Stage. + + try: + api_response = api_instance.stages_user_login_retrieve(stage_uuid) + print("The response of StagesApi->stages_user_login_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_login_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Login Stage. | + +### Return type + +[**UserLoginStage**](UserLoginStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_login_update** +> UserLoginStage stages_user_login_update(stage_uuid, user_login_stage_request) + +UserLoginStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_login_stage import UserLoginStage +from authentik_client.models.user_login_stage_request import UserLoginStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Login Stage. + user_login_stage_request = authentik_client.UserLoginStageRequest() # UserLoginStageRequest | + + try: + api_response = api_instance.stages_user_login_update(stage_uuid, user_login_stage_request) + print("The response of StagesApi->stages_user_login_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_login_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Login Stage. | + **user_login_stage_request** | [**UserLoginStageRequest**](UserLoginStageRequest.md)| | + +### Return type + +[**UserLoginStage**](UserLoginStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_login_used_by_list** +> List[UsedBy] stages_user_login_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Login Stage. + + try: + api_response = api_instance.stages_user_login_used_by_list(stage_uuid) + print("The response of StagesApi->stages_user_login_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_login_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Login Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_logout_create** +> UserLogoutStage stages_user_logout_create(user_logout_stage_request) + +UserLogoutStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_logout_stage import UserLogoutStage +from authentik_client.models.user_logout_stage_request import UserLogoutStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + user_logout_stage_request = authentik_client.UserLogoutStageRequest() # UserLogoutStageRequest | + + try: + api_response = api_instance.stages_user_logout_create(user_logout_stage_request) + print("The response of StagesApi->stages_user_logout_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_logout_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_logout_stage_request** | [**UserLogoutStageRequest**](UserLogoutStageRequest.md)| | + +### Return type + +[**UserLogoutStage**](UserLogoutStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_logout_destroy** +> stages_user_logout_destroy(stage_uuid) + +UserLogoutStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Logout Stage. + + try: + api_instance.stages_user_logout_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_user_logout_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Logout Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_logout_list** +> PaginatedUserLogoutStageList stages_user_logout_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + +UserLogoutStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_logout_stage_list import PaginatedUserLogoutStageList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + + try: + api_response = api_instance.stages_user_logout_list(name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid) + print("The response of StagesApi->stages_user_logout_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_logout_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + +### Return type + +[**PaginatedUserLogoutStageList**](PaginatedUserLogoutStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_logout_partial_update** +> UserLogoutStage stages_user_logout_partial_update(stage_uuid, patched_user_logout_stage_request=patched_user_logout_stage_request) + +UserLogoutStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_logout_stage_request import PatchedUserLogoutStageRequest +from authentik_client.models.user_logout_stage import UserLogoutStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Logout Stage. + patched_user_logout_stage_request = authentik_client.PatchedUserLogoutStageRequest() # PatchedUserLogoutStageRequest | (optional) + + try: + api_response = api_instance.stages_user_logout_partial_update(stage_uuid, patched_user_logout_stage_request=patched_user_logout_stage_request) + print("The response of StagesApi->stages_user_logout_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_logout_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Logout Stage. | + **patched_user_logout_stage_request** | [**PatchedUserLogoutStageRequest**](PatchedUserLogoutStageRequest.md)| | [optional] + +### Return type + +[**UserLogoutStage**](UserLogoutStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_logout_retrieve** +> UserLogoutStage stages_user_logout_retrieve(stage_uuid) + +UserLogoutStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_logout_stage import UserLogoutStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Logout Stage. + + try: + api_response = api_instance.stages_user_logout_retrieve(stage_uuid) + print("The response of StagesApi->stages_user_logout_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_logout_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Logout Stage. | + +### Return type + +[**UserLogoutStage**](UserLogoutStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_logout_update** +> UserLogoutStage stages_user_logout_update(stage_uuid, user_logout_stage_request) + +UserLogoutStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_logout_stage import UserLogoutStage +from authentik_client.models.user_logout_stage_request import UserLogoutStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Logout Stage. + user_logout_stage_request = authentik_client.UserLogoutStageRequest() # UserLogoutStageRequest | + + try: + api_response = api_instance.stages_user_logout_update(stage_uuid, user_logout_stage_request) + print("The response of StagesApi->stages_user_logout_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_logout_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Logout Stage. | + **user_logout_stage_request** | [**UserLogoutStageRequest**](UserLogoutStageRequest.md)| | + +### Return type + +[**UserLogoutStage**](UserLogoutStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_logout_used_by_list** +> List[UsedBy] stages_user_logout_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Logout Stage. + + try: + api_response = api_instance.stages_user_logout_used_by_list(stage_uuid) + print("The response of StagesApi->stages_user_logout_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_logout_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Logout Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_write_create** +> UserWriteStage stages_user_write_create(user_write_stage_request) + +UserWriteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_write_stage import UserWriteStage +from authentik_client.models.user_write_stage_request import UserWriteStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + user_write_stage_request = authentik_client.UserWriteStageRequest() # UserWriteStageRequest | + + try: + api_response = api_instance.stages_user_write_create(user_write_stage_request) + print("The response of StagesApi->stages_user_write_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_write_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **user_write_stage_request** | [**UserWriteStageRequest**](UserWriteStageRequest.md)| | + +### Return type + +[**UserWriteStage**](UserWriteStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_write_destroy** +> stages_user_write_destroy(stage_uuid) + +UserWriteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Write Stage. + + try: + api_instance.stages_user_write_destroy(stage_uuid) + except Exception as e: + print("Exception when calling StagesApi->stages_user_write_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Write Stage. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_write_list** +> PaginatedUserWriteStageList stages_user_write_list(create_users_as_inactive=create_users_as_inactive, create_users_group=create_users_group, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, user_creation_mode=user_creation_mode, user_path_template=user_path_template, user_type=user_type) + +UserWriteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_user_write_stage_list import PaginatedUserWriteStageList +from authentik_client.models.user_creation_mode_enum import UserCreationModeEnum +from authentik_client.models.user_type_enum import UserTypeEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + create_users_as_inactive = True # bool | (optional) + create_users_group = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + name = 'name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | (optional) + user_creation_mode = authentik_client.UserCreationModeEnum() # UserCreationModeEnum | (optional) + user_path_template = 'user_path_template_example' # str | (optional) + user_type = authentik_client.UserTypeEnum() # UserTypeEnum | (optional) + + try: + api_response = api_instance.stages_user_write_list(create_users_as_inactive=create_users_as_inactive, create_users_group=create_users_group, name=name, ordering=ordering, page=page, page_size=page_size, search=search, stage_uuid=stage_uuid, user_creation_mode=user_creation_mode, user_path_template=user_path_template, user_type=user_type) + print("The response of StagesApi->stages_user_write_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_write_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **create_users_as_inactive** | **bool**| | [optional] + **create_users_group** | **UUID**| | [optional] + **name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + **stage_uuid** | **UUID**| | [optional] + **user_creation_mode** | [**UserCreationModeEnum**](.md)| | [optional] + **user_path_template** | **str**| | [optional] + **user_type** | [**UserTypeEnum**](.md)| | [optional] + +### Return type + +[**PaginatedUserWriteStageList**](PaginatedUserWriteStageList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_write_partial_update** +> UserWriteStage stages_user_write_partial_update(stage_uuid, patched_user_write_stage_request=patched_user_write_stage_request) + +UserWriteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_user_write_stage_request import PatchedUserWriteStageRequest +from authentik_client.models.user_write_stage import UserWriteStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Write Stage. + patched_user_write_stage_request = authentik_client.PatchedUserWriteStageRequest() # PatchedUserWriteStageRequest | (optional) + + try: + api_response = api_instance.stages_user_write_partial_update(stage_uuid, patched_user_write_stage_request=patched_user_write_stage_request) + print("The response of StagesApi->stages_user_write_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_write_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Write Stage. | + **patched_user_write_stage_request** | [**PatchedUserWriteStageRequest**](PatchedUserWriteStageRequest.md)| | [optional] + +### Return type + +[**UserWriteStage**](UserWriteStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_write_retrieve** +> UserWriteStage stages_user_write_retrieve(stage_uuid) + +UserWriteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_write_stage import UserWriteStage +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Write Stage. + + try: + api_response = api_instance.stages_user_write_retrieve(stage_uuid) + print("The response of StagesApi->stages_user_write_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_write_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Write Stage. | + +### Return type + +[**UserWriteStage**](UserWriteStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_write_update** +> UserWriteStage stages_user_write_update(stage_uuid, user_write_stage_request) + +UserWriteStage Viewset + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.user_write_stage import UserWriteStage +from authentik_client.models.user_write_stage_request import UserWriteStageRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Write Stage. + user_write_stage_request = authentik_client.UserWriteStageRequest() # UserWriteStageRequest | + + try: + api_response = api_instance.stages_user_write_update(stage_uuid, user_write_stage_request) + print("The response of StagesApi->stages_user_write_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_write_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Write Stage. | + **user_write_stage_request** | [**UserWriteStageRequest**](UserWriteStageRequest.md)| | + +### Return type + +[**UserWriteStage**](UserWriteStage.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **stages_user_write_used_by_list** +> List[UsedBy] stages_user_write_used_by_list(stage_uuid) + +Get a list of all objects that use this object + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.used_by import UsedBy +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.StagesApi(api_client) + stage_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this User Write Stage. + + try: + api_response = api_instance.stages_user_write_used_by_list(stage_uuid) + print("The response of StagesApi->stages_user_write_used_by_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling StagesApi->stages_user_write_used_by_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **stage_uuid** | **UUID**| A UUID string identifying this User Write Stage. | + +### Return type + +[**List[UsedBy]**](UsedBy.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/StaticDevice.md b/docs/StaticDevice.md new file mode 100644 index 000000000..79f6ec4c1 --- /dev/null +++ b/docs/StaticDevice.md @@ -0,0 +1,33 @@ +# StaticDevice + +Serializer for static authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | +**token_set** | [**List[StaticDeviceToken]**](StaticDeviceToken.md) | | [readonly] +**pk** | **int** | | [readonly] +**user** | [**PartialUser**](PartialUser.md) | | [readonly] + +## Example + +```python +from authentik_client.models.static_device import StaticDevice + +# TODO update the JSON string below +json = "{}" +# create an instance of StaticDevice from a JSON string +static_device_instance = StaticDevice.from_json(json) +# print the JSON string representation of the object +print(StaticDevice.to_json()) + +# convert the object into a dict +static_device_dict = static_device_instance.to_dict() +# create an instance of StaticDevice from a dict +static_device_from_dict = StaticDevice.from_dict(static_device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/StaticDeviceRequest.md b/docs/StaticDeviceRequest.md new file mode 100644 index 000000000..38a99b0d8 --- /dev/null +++ b/docs/StaticDeviceRequest.md @@ -0,0 +1,30 @@ +# StaticDeviceRequest + +Serializer for static authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | + +## Example + +```python +from authentik_client.models.static_device_request import StaticDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of StaticDeviceRequest from a JSON string +static_device_request_instance = StaticDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(StaticDeviceRequest.to_json()) + +# convert the object into a dict +static_device_request_dict = static_device_request_instance.to_dict() +# create an instance of StaticDeviceRequest from a dict +static_device_request_from_dict = StaticDeviceRequest.from_dict(static_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/StaticDeviceToken.md b/docs/StaticDeviceToken.md new file mode 100644 index 000000000..dbbf304e9 --- /dev/null +++ b/docs/StaticDeviceToken.md @@ -0,0 +1,30 @@ +# StaticDeviceToken + +Serializer for static device's tokens + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**token** | **str** | | + +## Example + +```python +from authentik_client.models.static_device_token import StaticDeviceToken + +# TODO update the JSON string below +json = "{}" +# create an instance of StaticDeviceToken from a JSON string +static_device_token_instance = StaticDeviceToken.from_json(json) +# print the JSON string representation of the object +print(StaticDeviceToken.to_json()) + +# convert the object into a dict +static_device_token_dict = static_device_token_instance.to_dict() +# create an instance of StaticDeviceToken from a dict +static_device_token_from_dict = StaticDeviceToken.from_dict(static_device_token_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SubModeEnum.md b/docs/SubModeEnum.md new file mode 100644 index 000000000..b4b3c9716 --- /dev/null +++ b/docs/SubModeEnum.md @@ -0,0 +1,20 @@ +# SubModeEnum + + +## Enum + +* `HASHED_USER_ID` (value: `'hashed_user_id'`) + +* `USER_ID` (value: `'user_id'`) + +* `USER_UUID` (value: `'user_uuid'`) + +* `USER_USERNAME` (value: `'user_username'`) + +* `USER_EMAIL` (value: `'user_email'`) + +* `USER_UPN` (value: `'user_upn'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SyncObjectModelEnum.md b/docs/SyncObjectModelEnum.md new file mode 100644 index 000000000..b15255541 --- /dev/null +++ b/docs/SyncObjectModelEnum.md @@ -0,0 +1,12 @@ +# SyncObjectModelEnum + + +## Enum + +* `AUTHENTIK_DOT_CORE_DOT_MODELS_DOT_USER` (value: `'authentik.core.models.User'`) + +* `AUTHENTIK_DOT_CORE_DOT_MODELS_DOT_GROUP` (value: `'authentik.core.models.Group'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SyncObjectRequest.md b/docs/SyncObjectRequest.md new file mode 100644 index 000000000..74fd70fdd --- /dev/null +++ b/docs/SyncObjectRequest.md @@ -0,0 +1,32 @@ +# SyncObjectRequest + +Sync object serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**sync_object_model** | [**SyncObjectModelEnum**](SyncObjectModelEnum.md) | | +**sync_object_id** | **str** | | +**override_dry_run** | **bool** | | [optional] [default to False] + +## Example + +```python +from authentik_client.models.sync_object_request import SyncObjectRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of SyncObjectRequest from a JSON string +sync_object_request_instance = SyncObjectRequest.from_json(json) +# print the JSON string representation of the object +print(SyncObjectRequest.to_json()) + +# convert the object into a dict +sync_object_request_dict = sync_object_request_instance.to_dict() +# create an instance of SyncObjectRequest from a dict +sync_object_request_from_dict = SyncObjectRequest.from_dict(sync_object_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SyncObjectResult.md b/docs/SyncObjectResult.md new file mode 100644 index 000000000..c4e8ea58a --- /dev/null +++ b/docs/SyncObjectResult.md @@ -0,0 +1,30 @@ +# SyncObjectResult + +Result of a single object sync + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**messages** | [**List[LogEvent]**](LogEvent.md) | | [readonly] + +## Example + +```python +from authentik_client.models.sync_object_result import SyncObjectResult + +# TODO update the JSON string below +json = "{}" +# create an instance of SyncObjectResult from a JSON string +sync_object_result_instance = SyncObjectResult.from_json(json) +# print the JSON string representation of the object +print(SyncObjectResult.to_json()) + +# convert the object into a dict +sync_object_result_dict = sync_object_result_instance.to_dict() +# create an instance of SyncObjectResult from a dict +sync_object_result_from_dict = SyncObjectResult.from_dict(sync_object_result_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SyncOutgoingTriggerModeEnum.md b/docs/SyncOutgoingTriggerModeEnum.md new file mode 100644 index 000000000..6f39f7662 --- /dev/null +++ b/docs/SyncOutgoingTriggerModeEnum.md @@ -0,0 +1,14 @@ +# SyncOutgoingTriggerModeEnum + + +## Enum + +* `NONE` (value: `'none'`) + +* `IMMEDIATE` (value: `'immediate'`) + +* `DEFERRED_END` (value: `'deferred_end'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SyncStatus.md b/docs/SyncStatus.md new file mode 100644 index 000000000..8685884c1 --- /dev/null +++ b/docs/SyncStatus.md @@ -0,0 +1,32 @@ +# SyncStatus + +Provider/source sync status + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**is_running** | **bool** | | +**last_successful_sync** | **datetime** | | [optional] +**last_sync_status** | [**TaskAggregatedStatusEnum**](TaskAggregatedStatusEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.sync_status import SyncStatus + +# TODO update the JSON string below +json = "{}" +# create an instance of SyncStatus from a JSON string +sync_status_instance = SyncStatus.from_json(json) +# print the JSON string representation of the object +print(SyncStatus.to_json()) + +# convert the object into a dict +sync_status_dict = sync_status_instance.to_dict() +# create an instance of SyncStatus from a dict +sync_status_from_dict = SyncStatus.from_dict(sync_status_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SystemInfo.md b/docs/SystemInfo.md new file mode 100644 index 000000000..c5de2d8f2 --- /dev/null +++ b/docs/SystemInfo.md @@ -0,0 +1,37 @@ +# SystemInfo + +Get system information. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**http_headers** | **Dict[str, str]** | Get HTTP Request headers | [readonly] +**http_host** | **str** | Get HTTP host | [readonly] +**http_is_secure** | **bool** | Get HTTP Secure flag | [readonly] +**runtime** | [**SystemInfoRuntime**](SystemInfoRuntime.md) | | +**brand** | **str** | Currently active brand | [readonly] +**server_time** | **datetime** | Current server time | [readonly] +**embedded_outpost_disabled** | **bool** | Whether the embedded outpost is disabled | [readonly] +**embedded_outpost_host** | **str** | Get the FQDN configured on the embedded outpost | [readonly] + +## Example + +```python +from authentik_client.models.system_info import SystemInfo + +# TODO update the JSON string below +json = "{}" +# create an instance of SystemInfo from a JSON string +system_info_instance = SystemInfo.from_json(json) +# print the JSON string representation of the object +print(SystemInfo.to_json()) + +# convert the object into a dict +system_info_dict = system_info_instance.to_dict() +# create an instance of SystemInfo from a dict +system_info_from_dict = SystemInfo.from_dict(system_info_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/SystemInfoRuntime.md b/docs/SystemInfoRuntime.md new file mode 100644 index 000000000..123a8aea2 --- /dev/null +++ b/docs/SystemInfoRuntime.md @@ -0,0 +1,37 @@ +# SystemInfoRuntime + +Get versions + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**python_version** | **str** | | +**environment** | **str** | | +**architecture** | **str** | | +**platform** | **str** | | +**uname** | **str** | | +**openssl_version** | **str** | | +**openssl_fips_enabled** | **bool** | | +**authentik_version** | **str** | | + +## Example + +```python +from authentik_client.models.system_info_runtime import SystemInfoRuntime + +# TODO update the JSON string below +json = "{}" +# create an instance of SystemInfoRuntime from a JSON string +system_info_runtime_instance = SystemInfoRuntime.from_json(json) +# print the JSON string representation of the object +print(SystemInfoRuntime.to_json()) + +# convert the object into a dict +system_info_runtime_dict = system_info_runtime_instance.to_dict() +# create an instance of SystemInfoRuntime from a dict +system_info_runtime_from_dict = SystemInfoRuntime.from_dict(system_info_runtime_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TOTPDevice.md b/docs/TOTPDevice.md new file mode 100644 index 000000000..e650ebe3e --- /dev/null +++ b/docs/TOTPDevice.md @@ -0,0 +1,32 @@ +# TOTPDevice + +Serializer for totp authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | +**pk** | **int** | | [readonly] +**user** | [**PartialUser**](PartialUser.md) | | [readonly] + +## Example + +```python +from authentik_client.models.totp_device import TOTPDevice + +# TODO update the JSON string below +json = "{}" +# create an instance of TOTPDevice from a JSON string +totp_device_instance = TOTPDevice.from_json(json) +# print the JSON string representation of the object +print(TOTPDevice.to_json()) + +# convert the object into a dict +totp_device_dict = totp_device_instance.to_dict() +# create an instance of TOTPDevice from a dict +totp_device_from_dict = TOTPDevice.from_dict(totp_device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TOTPDeviceRequest.md b/docs/TOTPDeviceRequest.md new file mode 100644 index 000000000..72f1b9b7c --- /dev/null +++ b/docs/TOTPDeviceRequest.md @@ -0,0 +1,30 @@ +# TOTPDeviceRequest + +Serializer for totp authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | The human-readable name of this device. | + +## Example + +```python +from authentik_client.models.totp_device_request import TOTPDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TOTPDeviceRequest from a JSON string +totp_device_request_instance = TOTPDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(TOTPDeviceRequest.to_json()) + +# convert the object into a dict +totp_device_request_dict = totp_device_request_instance.to_dict() +# create an instance of TOTPDeviceRequest from a dict +totp_device_request_from_dict = TOTPDeviceRequest.from_dict(totp_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Task.md b/docs/Task.md new file mode 100644 index 000000000..b2e04ecbf --- /dev/null +++ b/docs/Task.md @@ -0,0 +1,43 @@ +# Task + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**message_id** | **UUID** | | [optional] +**queue_name** | **str** | Queue name | [optional] +**actor_name** | **str** | Dramatiq actor name | +**state** | [**TaskStatusEnum**](TaskStatusEnum.md) | Task status | [optional] +**mtime** | **datetime** | Task last modified time | [optional] +**retries** | **int** | Number of retries | [optional] +**eta** | **datetime** | Planned execution time | [optional] +**rel_obj_app_label** | **str** | | [readonly] +**rel_obj_model** | **str** | | [readonly] +**rel_obj_id** | **str** | | [optional] +**uid** | **str** | | [readonly] +**logs** | [**List[LogEvent]**](LogEvent.md) | | [readonly] +**previous_logs** | [**List[LogEvent]**](LogEvent.md) | | [readonly] +**aggregated_status** | [**TaskAggregatedStatusEnum**](TaskAggregatedStatusEnum.md) | | +**description** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.task import Task + +# TODO update the JSON string below +json = "{}" +# create an instance of Task from a JSON string +task_instance = Task.from_json(json) +# print the JSON string representation of the object +print(Task.to_json()) + +# convert the object into a dict +task_dict = task_instance.to_dict() +# create an instance of Task from a dict +task_from_dict = Task.from_dict(task_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TaskAggregatedStatusEnum.md b/docs/TaskAggregatedStatusEnum.md new file mode 100644 index 000000000..3fc431ad1 --- /dev/null +++ b/docs/TaskAggregatedStatusEnum.md @@ -0,0 +1,28 @@ +# TaskAggregatedStatusEnum + + +## Enum + +* `QUEUED` (value: `'queued'`) + +* `CONSUMED` (value: `'consumed'`) + +* `PREPROCESS` (value: `'preprocess'`) + +* `RUNNING` (value: `'running'`) + +* `POSTPROCESS` (value: `'postprocess'`) + +* `REJECTED` (value: `'rejected'`) + +* `DONE` (value: `'done'`) + +* `INFO` (value: `'info'`) + +* `WARNING` (value: `'warning'`) + +* `ERROR` (value: `'error'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TaskStatusEnum.md b/docs/TaskStatusEnum.md new file mode 100644 index 000000000..4a57c1f1f --- /dev/null +++ b/docs/TaskStatusEnum.md @@ -0,0 +1,22 @@ +# TaskStatusEnum + + +## Enum + +* `QUEUED` (value: `'queued'`) + +* `CONSUMED` (value: `'consumed'`) + +* `PREPROCESS` (value: `'preprocess'`) + +* `RUNNING` (value: `'running'`) + +* `POSTPROCESS` (value: `'postprocess'`) + +* `REJECTED` (value: `'rejected'`) + +* `DONE` (value: `'done'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TasksApi.md b/docs/TasksApi.md new file mode 100644 index 000000000..c1e55f3d6 --- /dev/null +++ b/docs/TasksApi.md @@ -0,0 +1,812 @@ +# authentik_client.TasksApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**tasks_schedules_list**](TasksApi.md#tasks_schedules_list) | **GET** /tasks/schedules/ | +[**tasks_schedules_partial_update**](TasksApi.md#tasks_schedules_partial_update) | **PATCH** /tasks/schedules/{id}/ | +[**tasks_schedules_retrieve**](TasksApi.md#tasks_schedules_retrieve) | **GET** /tasks/schedules/{id}/ | +[**tasks_schedules_send_create**](TasksApi.md#tasks_schedules_send_create) | **POST** /tasks/schedules/{id}/send/ | +[**tasks_schedules_update**](TasksApi.md#tasks_schedules_update) | **PUT** /tasks/schedules/{id}/ | +[**tasks_tasks_list**](TasksApi.md#tasks_tasks_list) | **GET** /tasks/tasks/ | +[**tasks_tasks_retrieve**](TasksApi.md#tasks_tasks_retrieve) | **GET** /tasks/tasks/{message_id}/ | +[**tasks_tasks_retry_create**](TasksApi.md#tasks_tasks_retry_create) | **POST** /tasks/tasks/{message_id}/retry/ | +[**tasks_tasks_status_retrieve**](TasksApi.md#tasks_tasks_status_retrieve) | **GET** /tasks/tasks/status/ | +[**tasks_workers_list**](TasksApi.md#tasks_workers_list) | **GET** /tasks/workers/ | + + +# **tasks_schedules_list** +> PaginatedScheduleList tasks_schedules_list(actor_name=actor_name, ordering=ordering, page=page, page_size=page_size, paused=paused, rel_obj_content_type__app_label=rel_obj_content_type__app_label, rel_obj_content_type__model=rel_obj_content_type__model, rel_obj_id=rel_obj_id, rel_obj_id__isnull=rel_obj_id__isnull, search=search) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_schedule_list import PaginatedScheduleList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + actor_name = 'actor_name_example' # str | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + paused = True # bool | (optional) + rel_obj_content_type__app_label = 'rel_obj_content_type__app_label_example' # str | (optional) + rel_obj_content_type__model = 'rel_obj_content_type__model_example' # str | (optional) + rel_obj_id = 'rel_obj_id_example' # str | (optional) + rel_obj_id__isnull = True # bool | (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.tasks_schedules_list(actor_name=actor_name, ordering=ordering, page=page, page_size=page_size, paused=paused, rel_obj_content_type__app_label=rel_obj_content_type__app_label, rel_obj_content_type__model=rel_obj_content_type__model, rel_obj_id=rel_obj_id, rel_obj_id__isnull=rel_obj_id__isnull, search=search) + print("The response of TasksApi->tasks_schedules_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TasksApi->tasks_schedules_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **actor_name** | **str**| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **paused** | **bool**| | [optional] + **rel_obj_content_type__app_label** | **str**| | [optional] + **rel_obj_content_type__model** | **str**| | [optional] + **rel_obj_id** | **str**| | [optional] + **rel_obj_id__isnull** | **bool**| | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedScheduleList**](PaginatedScheduleList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tasks_schedules_partial_update** +> Schedule tasks_schedules_partial_update(id, patched_schedule_request=patched_schedule_request) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.patched_schedule_request import PatchedScheduleRequest +from authentik_client.models.schedule import Schedule +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Schedule. + patched_schedule_request = authentik_client.PatchedScheduleRequest() # PatchedScheduleRequest | (optional) + + try: + api_response = api_instance.tasks_schedules_partial_update(id, patched_schedule_request=patched_schedule_request) + print("The response of TasksApi->tasks_schedules_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TasksApi->tasks_schedules_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Schedule. | + **patched_schedule_request** | [**PatchedScheduleRequest**](PatchedScheduleRequest.md)| | [optional] + +### Return type + +[**Schedule**](Schedule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tasks_schedules_retrieve** +> Schedule tasks_schedules_retrieve(id) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.schedule import Schedule +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Schedule. + + try: + api_response = api_instance.tasks_schedules_retrieve(id) + print("The response of TasksApi->tasks_schedules_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TasksApi->tasks_schedules_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Schedule. | + +### Return type + +[**Schedule**](Schedule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tasks_schedules_send_create** +> tasks_schedules_send_create(id) + +Trigger this schedule now + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Schedule. + + try: + api_instance.tasks_schedules_send_create(id) + except Exception as e: + print("Exception when calling TasksApi->tasks_schedules_send_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Schedule. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Schedule sent successfully | - | +**404** | Schedule not found | - | +**500** | Failed to send schedule | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tasks_schedules_update** +> Schedule tasks_schedules_update(id, schedule_request) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.schedule import Schedule +from authentik_client.models.schedule_request import ScheduleRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Schedule. + schedule_request = authentik_client.ScheduleRequest() # ScheduleRequest | + + try: + api_response = api_instance.tasks_schedules_update(id, schedule_request) + print("The response of TasksApi->tasks_schedules_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TasksApi->tasks_schedules_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **UUID**| A UUID string identifying this Schedule. | + **schedule_request** | [**ScheduleRequest**](ScheduleRequest.md)| | + +### Return type + +[**Schedule**](Schedule.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tasks_tasks_list** +> PaginatedTaskList tasks_tasks_list(actor_name=actor_name, aggregated_status=aggregated_status, ordering=ordering, page=page, page_size=page_size, queue_name=queue_name, rel_obj_content_type__app_label=rel_obj_content_type__app_label, rel_obj_content_type__model=rel_obj_content_type__model, rel_obj_id=rel_obj_id, rel_obj_id__isnull=rel_obj_id__isnull, search=search, state=state) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.paginated_task_list import PaginatedTaskList +from authentik_client.models.task_aggregated_status_enum import TaskAggregatedStatusEnum +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + actor_name = 'actor_name_example' # str | (optional) + aggregated_status = [authentik_client.TaskAggregatedStatusEnum()] # List[TaskAggregatedStatusEnum] | (optional) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + queue_name = 'queue_name_example' # str | (optional) + rel_obj_content_type__app_label = 'rel_obj_content_type__app_label_example' # str | (optional) + rel_obj_content_type__model = 'rel_obj_content_type__model_example' # str | (optional) + rel_obj_id = 'rel_obj_id_example' # str | (optional) + rel_obj_id__isnull = True # bool | (optional) + search = 'search_example' # str | A search term. (optional) + state = authentik_client.TaskStatusEnum() # TaskStatusEnum | (optional) + + try: + api_response = api_instance.tasks_tasks_list(actor_name=actor_name, aggregated_status=aggregated_status, ordering=ordering, page=page, page_size=page_size, queue_name=queue_name, rel_obj_content_type__app_label=rel_obj_content_type__app_label, rel_obj_content_type__model=rel_obj_content_type__model, rel_obj_id=rel_obj_id, rel_obj_id__isnull=rel_obj_id__isnull, search=search, state=state) + print("The response of TasksApi->tasks_tasks_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TasksApi->tasks_tasks_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **actor_name** | **str**| | [optional] + **aggregated_status** | [**List[TaskAggregatedStatusEnum]**](TaskAggregatedStatusEnum.md)| | [optional] + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **queue_name** | **str**| | [optional] + **rel_obj_content_type__app_label** | **str**| | [optional] + **rel_obj_content_type__model** | **str**| | [optional] + **rel_obj_id** | **str**| | [optional] + **rel_obj_id__isnull** | **bool**| | [optional] + **search** | **str**| A search term. | [optional] + **state** | [**TaskStatusEnum**](.md)| | [optional] + +### Return type + +[**PaginatedTaskList**](PaginatedTaskList.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tasks_tasks_retrieve** +> Task tasks_tasks_retrieve(message_id) + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.task import Task +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + message_id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Task. + + try: + api_response = api_instance.tasks_tasks_retrieve(message_id) + print("The response of TasksApi->tasks_tasks_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TasksApi->tasks_tasks_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **message_id** | **UUID**| A UUID string identifying this Task. | + +### Return type + +[**Task**](Task.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tasks_tasks_retry_create** +> tasks_tasks_retry_create(message_id) + +Retry task + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + message_id = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Task. + + try: + api_instance.tasks_tasks_retry_create(message_id) + except Exception as e: + print("Exception when calling TasksApi->tasks_tasks_retry_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **message_id** | **UUID**| A UUID string identifying this Task. | + +### Return type + +void (empty response body) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Task retried successfully | - | +**400** | Task is not in a retryable state | - | +**404** | Task not found | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tasks_tasks_status_retrieve** +> GlobalTaskStatus tasks_tasks_status_retrieve() + +Global status summary for all tasks + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.global_task_status import GlobalTaskStatus +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + + try: + api_response = api_instance.tasks_tasks_status_retrieve() + print("The response of TasksApi->tasks_tasks_status_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TasksApi->tasks_tasks_status_retrieve: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**GlobalTaskStatus**](GlobalTaskStatus.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tasks_workers_list** +> List[Worker] tasks_workers_list() + +Get currently connected worker count. + +### Example + +* Bearer Authentication (authentik): + +```python +import authentik_client +from authentik_client.models.worker import Worker +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: authentik +configuration = authentik_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TasksApi(api_client) + + try: + api_response = api_instance.tasks_workers_list() + print("The response of TasksApi->tasks_workers_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TasksApi->tasks_workers_list: %s\n" % e) +``` + + + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**List[Worker]**](Worker.md) + +### Authorization + +[authentik](../README.md#authentik) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/TelegramAuthRequest.md b/docs/TelegramAuthRequest.md new file mode 100644 index 000000000..31af9573d --- /dev/null +++ b/docs/TelegramAuthRequest.md @@ -0,0 +1,35 @@ +# TelegramAuthRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | +**first_name** | **str** | | [optional] +**last_name** | **str** | | [optional] +**username** | **str** | | [optional] +**photo_url** | **str** | | [optional] +**auth_date** | **int** | | +**hash** | **str** | | + +## Example + +```python +from authentik_client.models.telegram_auth_request import TelegramAuthRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TelegramAuthRequest from a JSON string +telegram_auth_request_instance = TelegramAuthRequest.from_json(json) +# print the JSON string representation of the object +print(TelegramAuthRequest.to_json()) + +# convert the object into a dict +telegram_auth_request_dict = telegram_auth_request_instance.to_dict() +# create an instance of TelegramAuthRequest from a dict +telegram_auth_request_from_dict = TelegramAuthRequest.from_dict(telegram_auth_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TelegramChallengeResponseRequest.md b/docs/TelegramChallengeResponseRequest.md new file mode 100644 index 000000000..5a1bd9688 --- /dev/null +++ b/docs/TelegramChallengeResponseRequest.md @@ -0,0 +1,37 @@ +# TelegramChallengeResponseRequest + +Base class for all challenge responses + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | +**first_name** | **str** | | [optional] +**last_name** | **str** | | [optional] +**username** | **str** | | [optional] +**photo_url** | **str** | | [optional] +**auth_date** | **int** | | +**hash** | **str** | | +**component** | **str** | | [optional] [default to 'ak-source-telegram'] + +## Example + +```python +from authentik_client.models.telegram_challenge_response_request import TelegramChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TelegramChallengeResponseRequest from a JSON string +telegram_challenge_response_request_instance = TelegramChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(TelegramChallengeResponseRequest.to_json()) + +# convert the object into a dict +telegram_challenge_response_request_dict = telegram_challenge_response_request_instance.to_dict() +# create an instance of TelegramChallengeResponseRequest from a dict +telegram_challenge_response_request_from_dict = TelegramChallengeResponseRequest.from_dict(telegram_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TelegramLoginChallenge.md b/docs/TelegramLoginChallenge.md new file mode 100644 index 000000000..dac61fddf --- /dev/null +++ b/docs/TelegramLoginChallenge.md @@ -0,0 +1,34 @@ +# TelegramLoginChallenge + +Base login challenge for Identification stage + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-source-telegram'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**bot_username** | **str** | Telegram bot username | +**request_message_access** | **bool** | | + +## Example + +```python +from authentik_client.models.telegram_login_challenge import TelegramLoginChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of TelegramLoginChallenge from a JSON string +telegram_login_challenge_instance = TelegramLoginChallenge.from_json(json) +# print the JSON string representation of the object +print(TelegramLoginChallenge.to_json()) + +# convert the object into a dict +telegram_login_challenge_dict = telegram_login_challenge_instance.to_dict() +# create an instance of TelegramLoginChallenge from a dict +telegram_login_challenge_from_dict = TelegramLoginChallenge.from_dict(telegram_login_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TelegramSource.md b/docs/TelegramSource.md new file mode 100644 index 000000000..2478e99e4 --- /dev/null +++ b/docs/TelegramSource.md @@ -0,0 +1,52 @@ +# TelegramSource + +Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [readonly] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**icon_url** | **str** | | [readonly] +**icon_themed_urls** | [**ThemedUrls**](ThemedUrls.md) | | [readonly] +**bot_username** | **str** | Telegram bot username | +**request_message_access** | **bool** | Request access to send messages from your bot. | [optional] +**pre_authentication_flow** | **UUID** | Flow used before authentication. | + +## Example + +```python +from authentik_client.models.telegram_source import TelegramSource + +# TODO update the JSON string below +json = "{}" +# create an instance of TelegramSource from a JSON string +telegram_source_instance = TelegramSource.from_json(json) +# print the JSON string representation of the object +print(TelegramSource.to_json()) + +# convert the object into a dict +telegram_source_dict = telegram_source_instance.to_dict() +# create an instance of TelegramSource from a dict +telegram_source_from_dict = TelegramSource.from_dict(telegram_source_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TelegramSourcePropertyMapping.md b/docs/TelegramSourcePropertyMapping.md new file mode 100644 index 000000000..fae6140d0 --- /dev/null +++ b/docs/TelegramSourcePropertyMapping.md @@ -0,0 +1,37 @@ +# TelegramSourcePropertyMapping + +TelegramSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | +**component** | **str** | Get object's component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] + +## Example + +```python +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping + +# TODO update the JSON string below +json = "{}" +# create an instance of TelegramSourcePropertyMapping from a JSON string +telegram_source_property_mapping_instance = TelegramSourcePropertyMapping.from_json(json) +# print the JSON string representation of the object +print(TelegramSourcePropertyMapping.to_json()) + +# convert the object into a dict +telegram_source_property_mapping_dict = telegram_source_property_mapping_instance.to_dict() +# create an instance of TelegramSourcePropertyMapping from a dict +telegram_source_property_mapping_from_dict = TelegramSourcePropertyMapping.from_dict(telegram_source_property_mapping_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TelegramSourcePropertyMappingRequest.md b/docs/TelegramSourcePropertyMappingRequest.md new file mode 100644 index 000000000..13bacc495 --- /dev/null +++ b/docs/TelegramSourcePropertyMappingRequest.md @@ -0,0 +1,32 @@ +# TelegramSourcePropertyMappingRequest + +TelegramSourcePropertyMapping Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**name** | **str** | | +**expression** | **str** | | + +## Example + +```python +from authentik_client.models.telegram_source_property_mapping_request import TelegramSourcePropertyMappingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TelegramSourcePropertyMappingRequest from a JSON string +telegram_source_property_mapping_request_instance = TelegramSourcePropertyMappingRequest.from_json(json) +# print the JSON string representation of the object +print(TelegramSourcePropertyMappingRequest.to_json()) + +# convert the object into a dict +telegram_source_property_mapping_request_dict = telegram_source_property_mapping_request_instance.to_dict() +# create an instance of TelegramSourcePropertyMappingRequest from a dict +telegram_source_property_mapping_request_from_dict = TelegramSourcePropertyMappingRequest.from_dict(telegram_source_property_mapping_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TelegramSourceRequest.md b/docs/TelegramSourceRequest.md new file mode 100644 index 000000000..5984892f9 --- /dev/null +++ b/docs/TelegramSourceRequest.md @@ -0,0 +1,45 @@ +# TelegramSourceRequest + +Source Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | Source's display Name. | +**slug** | **str** | Internal source name, used in URLs. | +**enabled** | **bool** | | [optional] +**promoted** | **bool** | When enabled, this source will be displayed as a prominent button on the login page, instead of a small icon. | [optional] +**authentication_flow** | **UUID** | Flow to use when authenticating existing users. | [optional] +**enrollment_flow** | **UUID** | Flow to use when enrolling new users. | [optional] +**user_property_mappings** | **List[UUID]** | | [optional] +**group_property_mappings** | **List[UUID]** | | [optional] +**policy_engine_mode** | [**PolicyEngineMode**](PolicyEngineMode.md) | | [optional] +**user_matching_mode** | [**UserMatchingModeEnum**](UserMatchingModeEnum.md) | How the source determines if an existing user should be authenticated or a new user enrolled. | [optional] +**user_path_template** | **str** | | [optional] +**icon** | **str** | | [optional] +**bot_username** | **str** | Telegram bot username | +**bot_token** | **str** | Telegram bot token | +**request_message_access** | **bool** | Request access to send messages from your bot. | [optional] +**pre_authentication_flow** | **UUID** | Flow used before authentication. | + +## Example + +```python +from authentik_client.models.telegram_source_request import TelegramSourceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TelegramSourceRequest from a JSON string +telegram_source_request_instance = TelegramSourceRequest.from_json(json) +# print the JSON string representation of the object +print(TelegramSourceRequest.to_json()) + +# convert the object into a dict +telegram_source_request_dict = telegram_source_request_instance.to_dict() +# create an instance of TelegramSourceRequest from a dict +telegram_source_request_from_dict = TelegramSourceRequest.from_dict(telegram_source_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Tenant.md b/docs/Tenant.md new file mode 100644 index 000000000..a6466d227 --- /dev/null +++ b/docs/Tenant.md @@ -0,0 +1,33 @@ +# Tenant + +Tenant Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**tenant_uuid** | **UUID** | | [readonly] +**schema_name** | **str** | | +**name** | **str** | | +**ready** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.tenant import Tenant + +# TODO update the JSON string below +json = "{}" +# create an instance of Tenant from a JSON string +tenant_instance = Tenant.from_json(json) +# print the JSON string representation of the object +print(Tenant.to_json()) + +# convert the object into a dict +tenant_dict = tenant_instance.to_dict() +# create an instance of Tenant from a dict +tenant_from_dict = Tenant.from_dict(tenant_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TenantAdminGroupRequestRequest.md b/docs/TenantAdminGroupRequestRequest.md new file mode 100644 index 000000000..c21dcc3ef --- /dev/null +++ b/docs/TenantAdminGroupRequestRequest.md @@ -0,0 +1,30 @@ +# TenantAdminGroupRequestRequest + +Tenant admin group creation request serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user** | **str** | | + +## Example + +```python +from authentik_client.models.tenant_admin_group_request_request import TenantAdminGroupRequestRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TenantAdminGroupRequestRequest from a JSON string +tenant_admin_group_request_request_instance = TenantAdminGroupRequestRequest.from_json(json) +# print the JSON string representation of the object +print(TenantAdminGroupRequestRequest.to_json()) + +# convert the object into a dict +tenant_admin_group_request_request_dict = tenant_admin_group_request_request_instance.to_dict() +# create an instance of TenantAdminGroupRequestRequest from a dict +tenant_admin_group_request_request_from_dict = TenantAdminGroupRequestRequest.from_dict(tenant_admin_group_request_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TenantRecoveryKeyRequestRequest.md b/docs/TenantRecoveryKeyRequestRequest.md new file mode 100644 index 000000000..fbdb48450 --- /dev/null +++ b/docs/TenantRecoveryKeyRequestRequest.md @@ -0,0 +1,31 @@ +# TenantRecoveryKeyRequestRequest + +Tenant recovery key creation request serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user** | **str** | | +**duration_days** | **int** | | + +## Example + +```python +from authentik_client.models.tenant_recovery_key_request_request import TenantRecoveryKeyRequestRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TenantRecoveryKeyRequestRequest from a JSON string +tenant_recovery_key_request_request_instance = TenantRecoveryKeyRequestRequest.from_json(json) +# print the JSON string representation of the object +print(TenantRecoveryKeyRequestRequest.to_json()) + +# convert the object into a dict +tenant_recovery_key_request_request_dict = tenant_recovery_key_request_request_instance.to_dict() +# create an instance of TenantRecoveryKeyRequestRequest from a dict +tenant_recovery_key_request_request_from_dict = TenantRecoveryKeyRequestRequest.from_dict(tenant_recovery_key_request_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TenantRecoveryKeyResponse.md b/docs/TenantRecoveryKeyResponse.md new file mode 100644 index 000000000..07950f772 --- /dev/null +++ b/docs/TenantRecoveryKeyResponse.md @@ -0,0 +1,31 @@ +# TenantRecoveryKeyResponse + +Tenant recovery key creation response serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**expiry** | **datetime** | | +**url** | **str** | | + +## Example + +```python +from authentik_client.models.tenant_recovery_key_response import TenantRecoveryKeyResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of TenantRecoveryKeyResponse from a JSON string +tenant_recovery_key_response_instance = TenantRecoveryKeyResponse.from_json(json) +# print the JSON string representation of the object +print(TenantRecoveryKeyResponse.to_json()) + +# convert the object into a dict +tenant_recovery_key_response_dict = tenant_recovery_key_response_instance.to_dict() +# create an instance of TenantRecoveryKeyResponse from a dict +tenant_recovery_key_response_from_dict = TenantRecoveryKeyResponse.from_dict(tenant_recovery_key_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TenantRequest.md b/docs/TenantRequest.md new file mode 100644 index 000000000..2707bf2a9 --- /dev/null +++ b/docs/TenantRequest.md @@ -0,0 +1,32 @@ +# TenantRequest + +Tenant Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**schema_name** | **str** | | +**name** | **str** | | +**ready** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.tenant_request import TenantRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TenantRequest from a JSON string +tenant_request_instance = TenantRequest.from_json(json) +# print the JSON string representation of the object +print(TenantRequest.to_json()) + +# convert the object into a dict +tenant_request_dict = tenant_request_instance.to_dict() +# create an instance of TenantRequest from a dict +tenant_request_from_dict = TenantRequest.from_dict(tenant_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TenantsApi.md b/docs/TenantsApi.md new file mode 100644 index 000000000..2a519f56d --- /dev/null +++ b/docs/TenantsApi.md @@ -0,0 +1,985 @@ +# authentik_client.TenantsApi + +All URIs are relative to */api/v3* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**tenants_domains_create**](TenantsApi.md#tenants_domains_create) | **POST** /tenants/domains/ | +[**tenants_domains_destroy**](TenantsApi.md#tenants_domains_destroy) | **DELETE** /tenants/domains/{id}/ | +[**tenants_domains_list**](TenantsApi.md#tenants_domains_list) | **GET** /tenants/domains/ | +[**tenants_domains_partial_update**](TenantsApi.md#tenants_domains_partial_update) | **PATCH** /tenants/domains/{id}/ | +[**tenants_domains_retrieve**](TenantsApi.md#tenants_domains_retrieve) | **GET** /tenants/domains/{id}/ | +[**tenants_domains_update**](TenantsApi.md#tenants_domains_update) | **PUT** /tenants/domains/{id}/ | +[**tenants_tenants_create**](TenantsApi.md#tenants_tenants_create) | **POST** /tenants/tenants/ | +[**tenants_tenants_create_admin_group_create**](TenantsApi.md#tenants_tenants_create_admin_group_create) | **POST** /tenants/tenants/{tenant_uuid}/create_admin_group/ | +[**tenants_tenants_create_recovery_key_create**](TenantsApi.md#tenants_tenants_create_recovery_key_create) | **POST** /tenants/tenants/{tenant_uuid}/create_recovery_key/ | +[**tenants_tenants_destroy**](TenantsApi.md#tenants_tenants_destroy) | **DELETE** /tenants/tenants/{tenant_uuid}/ | +[**tenants_tenants_list**](TenantsApi.md#tenants_tenants_list) | **GET** /tenants/tenants/ | +[**tenants_tenants_partial_update**](TenantsApi.md#tenants_tenants_partial_update) | **PATCH** /tenants/tenants/{tenant_uuid}/ | +[**tenants_tenants_retrieve**](TenantsApi.md#tenants_tenants_retrieve) | **GET** /tenants/tenants/{tenant_uuid}/ | +[**tenants_tenants_update**](TenantsApi.md#tenants_tenants_update) | **PUT** /tenants/tenants/{tenant_uuid}/ | + + +# **tenants_domains_create** +> Domain tenants_domains_create(domain_request) + +Domain ViewSet + +### Example + + +```python +import authentik_client +from authentik_client.models.domain import Domain +from authentik_client.models.domain_request import DomainRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + domain_request = authentik_client.DomainRequest() # DomainRequest | + + try: + api_response = api_instance.tenants_domains_create(domain_request) + print("The response of TenantsApi->tenants_domains_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_domains_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **domain_request** | [**DomainRequest**](DomainRequest.md)| | + +### Return type + +[**Domain**](Domain.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_domains_destroy** +> tenants_domains_destroy(id) + +Domain ViewSet + +### Example + + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + id = 56 # int | A unique integer value identifying this Domain. + + try: + api_instance.tenants_domains_destroy(id) + except Exception as e: + print("Exception when calling TenantsApi->tenants_domains_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Domain. | + +### Return type + +void (empty response body) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_domains_list** +> PaginatedDomainList tenants_domains_list(ordering=ordering, page=page, page_size=page_size, search=search) + +Domain ViewSet + +### Example + + +```python +import authentik_client +from authentik_client.models.paginated_domain_list import PaginatedDomainList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.tenants_domains_list(ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of TenantsApi->tenants_domains_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_domains_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedDomainList**](PaginatedDomainList.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_domains_partial_update** +> Domain tenants_domains_partial_update(id, patched_domain_request=patched_domain_request) + +Domain ViewSet + +### Example + + +```python +import authentik_client +from authentik_client.models.domain import Domain +from authentik_client.models.patched_domain_request import PatchedDomainRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + id = 56 # int | A unique integer value identifying this Domain. + patched_domain_request = authentik_client.PatchedDomainRequest() # PatchedDomainRequest | (optional) + + try: + api_response = api_instance.tenants_domains_partial_update(id, patched_domain_request=patched_domain_request) + print("The response of TenantsApi->tenants_domains_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_domains_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Domain. | + **patched_domain_request** | [**PatchedDomainRequest**](PatchedDomainRequest.md)| | [optional] + +### Return type + +[**Domain**](Domain.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_domains_retrieve** +> Domain tenants_domains_retrieve(id) + +Domain ViewSet + +### Example + + +```python +import authentik_client +from authentik_client.models.domain import Domain +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + id = 56 # int | A unique integer value identifying this Domain. + + try: + api_response = api_instance.tenants_domains_retrieve(id) + print("The response of TenantsApi->tenants_domains_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_domains_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Domain. | + +### Return type + +[**Domain**](Domain.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_domains_update** +> Domain tenants_domains_update(id, domain_request) + +Domain ViewSet + +### Example + + +```python +import authentik_client +from authentik_client.models.domain import Domain +from authentik_client.models.domain_request import DomainRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + id = 56 # int | A unique integer value identifying this Domain. + domain_request = authentik_client.DomainRequest() # DomainRequest | + + try: + api_response = api_instance.tenants_domains_update(id, domain_request) + print("The response of TenantsApi->tenants_domains_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_domains_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **int**| A unique integer value identifying this Domain. | + **domain_request** | [**DomainRequest**](DomainRequest.md)| | + +### Return type + +[**Domain**](Domain.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_tenants_create** +> Tenant tenants_tenants_create(tenant_request) + +Tenant Viewset + +### Example + + +```python +import authentik_client +from authentik_client.models.tenant import Tenant +from authentik_client.models.tenant_request import TenantRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + tenant_request = authentik_client.TenantRequest() # TenantRequest | + + try: + api_response = api_instance.tenants_tenants_create(tenant_request) + print("The response of TenantsApi->tenants_tenants_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_tenants_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tenant_request** | [**TenantRequest**](TenantRequest.md)| | + +### Return type + +[**Tenant**](Tenant.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**201** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_tenants_create_admin_group_create** +> tenants_tenants_create_admin_group_create(tenant_uuid, tenant_admin_group_request_request) + +Create admin group and add user to it. + +### Example + + +```python +import authentik_client +from authentik_client.models.tenant_admin_group_request_request import TenantAdminGroupRequestRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + tenant_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Tenant. + tenant_admin_group_request_request = authentik_client.TenantAdminGroupRequestRequest() # TenantAdminGroupRequestRequest | + + try: + api_instance.tenants_tenants_create_admin_group_create(tenant_uuid, tenant_admin_group_request_request) + except Exception as e: + print("Exception when calling TenantsApi->tenants_tenants_create_admin_group_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tenant_uuid** | **UUID**| A UUID string identifying this Tenant. | + **tenant_admin_group_request_request** | [**TenantAdminGroupRequestRequest**](TenantAdminGroupRequestRequest.md)| | + +### Return type + +void (empty response body) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | Group created successfully. | - | +**400** | Bad request | - | +**404** | User not found | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_tenants_create_recovery_key_create** +> TenantRecoveryKeyResponse tenants_tenants_create_recovery_key_create(tenant_uuid, tenant_recovery_key_request_request) + +Create recovery key for user. + +### Example + + +```python +import authentik_client +from authentik_client.models.tenant_recovery_key_request_request import TenantRecoveryKeyRequestRequest +from authentik_client.models.tenant_recovery_key_response import TenantRecoveryKeyResponse +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + tenant_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Tenant. + tenant_recovery_key_request_request = authentik_client.TenantRecoveryKeyRequestRequest() # TenantRecoveryKeyRequestRequest | + + try: + api_response = api_instance.tenants_tenants_create_recovery_key_create(tenant_uuid, tenant_recovery_key_request_request) + print("The response of TenantsApi->tenants_tenants_create_recovery_key_create:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_tenants_create_recovery_key_create: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tenant_uuid** | **UUID**| A UUID string identifying this Tenant. | + **tenant_recovery_key_request_request** | [**TenantRecoveryKeyRequestRequest**](TenantRecoveryKeyRequestRequest.md)| | + +### Return type + +[**TenantRecoveryKeyResponse**](TenantRecoveryKeyResponse.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**404** | User not found | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_tenants_destroy** +> tenants_tenants_destroy(tenant_uuid) + +Tenant Viewset + +### Example + + +```python +import authentik_client +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + tenant_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Tenant. + + try: + api_instance.tenants_tenants_destroy(tenant_uuid) + except Exception as e: + print("Exception when calling TenantsApi->tenants_tenants_destroy: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tenant_uuid** | **UUID**| A UUID string identifying this Tenant. | + +### Return type + +void (empty response body) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**204** | No response body | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_tenants_list** +> PaginatedTenantList tenants_tenants_list(ordering=ordering, page=page, page_size=page_size, search=search) + +Tenant Viewset + +### Example + + +```python +import authentik_client +from authentik_client.models.paginated_tenant_list import PaginatedTenantList +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + ordering = 'ordering_example' # str | Which field to use when ordering the results. (optional) + page = 56 # int | A page number within the paginated result set. (optional) + page_size = 56 # int | Number of results to return per page. (optional) + search = 'search_example' # str | A search term. (optional) + + try: + api_response = api_instance.tenants_tenants_list(ordering=ordering, page=page, page_size=page_size, search=search) + print("The response of TenantsApi->tenants_tenants_list:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_tenants_list: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ordering** | **str**| Which field to use when ordering the results. | [optional] + **page** | **int**| A page number within the paginated result set. | [optional] + **page_size** | **int**| Number of results to return per page. | [optional] + **search** | **str**| A search term. | [optional] + +### Return type + +[**PaginatedTenantList**](PaginatedTenantList.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_tenants_partial_update** +> Tenant tenants_tenants_partial_update(tenant_uuid, patched_tenant_request=patched_tenant_request) + +Tenant Viewset + +### Example + + +```python +import authentik_client +from authentik_client.models.patched_tenant_request import PatchedTenantRequest +from authentik_client.models.tenant import Tenant +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + tenant_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Tenant. + patched_tenant_request = authentik_client.PatchedTenantRequest() # PatchedTenantRequest | (optional) + + try: + api_response = api_instance.tenants_tenants_partial_update(tenant_uuid, patched_tenant_request=patched_tenant_request) + print("The response of TenantsApi->tenants_tenants_partial_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_tenants_partial_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tenant_uuid** | **UUID**| A UUID string identifying this Tenant. | + **patched_tenant_request** | [**PatchedTenantRequest**](PatchedTenantRequest.md)| | [optional] + +### Return type + +[**Tenant**](Tenant.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_tenants_retrieve** +> Tenant tenants_tenants_retrieve(tenant_uuid) + +Tenant Viewset + +### Example + + +```python +import authentik_client +from authentik_client.models.tenant import Tenant +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + tenant_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Tenant. + + try: + api_response = api_instance.tenants_tenants_retrieve(tenant_uuid) + print("The response of TenantsApi->tenants_tenants_retrieve:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_tenants_retrieve: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tenant_uuid** | **UUID**| A UUID string identifying this Tenant. | + +### Return type + +[**Tenant**](Tenant.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **tenants_tenants_update** +> Tenant tenants_tenants_update(tenant_uuid, tenant_request) + +Tenant Viewset + +### Example + + +```python +import authentik_client +from authentik_client.models.tenant import Tenant +from authentik_client.models.tenant_request import TenantRequest +from authentik_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to /api/v3 +# See configuration.py for a list of all supported configuration parameters. +configuration = authentik_client.Configuration( + host = "/api/v3" +) + + +# Enter a context with an instance of the API client +with authentik_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = authentik_client.TenantsApi(api_client) + tenant_uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | A UUID string identifying this Tenant. + tenant_request = authentik_client.TenantRequest() # TenantRequest | + + try: + api_response = api_instance.tenants_tenants_update(tenant_uuid, tenant_request) + print("The response of TenantsApi->tenants_tenants_update:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling TenantsApi->tenants_tenants_update: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tenant_uuid** | **UUID**| A UUID string identifying this Tenant. | + **tenant_request** | [**TenantRequest**](TenantRequest.md)| | + +### Return type + +[**Tenant**](Tenant.md) + +### Authorization + +No authorization required + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | | - | +**403** | | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/docs/ThemedUrls.md b/docs/ThemedUrls.md new file mode 100644 index 000000000..6b70aeaea --- /dev/null +++ b/docs/ThemedUrls.md @@ -0,0 +1,31 @@ +# ThemedUrls + +Themed URLs - maps theme names to URLs for light and dark themes + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**light** | **str** | | [optional] +**dark** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.themed_urls import ThemedUrls + +# TODO update the JSON string below +json = "{}" +# create an instance of ThemedUrls from a JSON string +themed_urls_instance = ThemedUrls.from_json(json) +# print the JSON string representation of the object +print(ThemedUrls.to_json()) + +# convert the object into a dict +themed_urls_dict = themed_urls_instance.to_dict() +# create an instance of ThemedUrls from a dict +themed_urls_from_dict = ThemedUrls.from_dict(themed_urls_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Token.md b/docs/Token.md new file mode 100644 index 000000000..abbc28989 --- /dev/null +++ b/docs/Token.md @@ -0,0 +1,38 @@ +# Token + +Token Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**identifier** | **str** | | +**intent** | [**IntentEnum**](IntentEnum.md) | | [optional] +**user** | **int** | | [optional] +**user_obj** | [**User**](User.md) | | [readonly] +**description** | **str** | | [optional] +**expires** | **datetime** | | [optional] +**expiring** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.token import Token + +# TODO update the JSON string below +json = "{}" +# create an instance of Token from a JSON string +token_instance = Token.from_json(json) +# print the JSON string representation of the object +print(Token.to_json()) + +# convert the object into a dict +token_dict = token_instance.to_dict() +# create an instance of Token from a dict +token_from_dict = Token.from_dict(token_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TokenModel.md b/docs/TokenModel.md new file mode 100644 index 000000000..9024cbf04 --- /dev/null +++ b/docs/TokenModel.md @@ -0,0 +1,37 @@ +# TokenModel + +Serializer for BaseGrantModel and RefreshToken + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**provider** | [**Provider**](Provider.md) | | +**user** | [**User**](User.md) | | +**is_expired** | **bool** | Check if token is expired yet. | [readonly] +**expires** | **datetime** | | [optional] +**scope** | **List[str]** | | +**id_token** | **str** | Get the token's id_token as JSON String | [readonly] +**revoked** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.token_model import TokenModel + +# TODO update the JSON string below +json = "{}" +# create an instance of TokenModel from a JSON string +token_model_instance = TokenModel.from_json(json) +# print the JSON string representation of the object +print(TokenModel.to_json()) + +# convert the object into a dict +token_model_dict = token_model_instance.to_dict() +# create an instance of TokenModel from a dict +token_model_from_dict = TokenModel.from_dict(token_model_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TokenRequest.md b/docs/TokenRequest.md new file mode 100644 index 000000000..1b7eb89fb --- /dev/null +++ b/docs/TokenRequest.md @@ -0,0 +1,36 @@ +# TokenRequest + +Token Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**managed** | **str** | Objects that are managed by authentik. These objects are created and updated automatically. This flag only indicates that an object can be overwritten by migrations. You can still modify the objects via the API, but expect changes to be overwritten in a later update. | [optional] +**identifier** | **str** | | +**intent** | [**IntentEnum**](IntentEnum.md) | | [optional] +**user** | **int** | | [optional] +**description** | **str** | | [optional] +**expires** | **datetime** | | [optional] +**expiring** | **bool** | | [optional] + +## Example + +```python +from authentik_client.models.token_request import TokenRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TokenRequest from a JSON string +token_request_instance = TokenRequest.from_json(json) +# print the JSON string representation of the object +print(TokenRequest.to_json()) + +# convert the object into a dict +token_request_dict = token_request_instance.to_dict() +# create an instance of TokenRequest from a dict +token_request_from_dict = TokenRequest.from_dict(token_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TokenSetKeyRequest.md b/docs/TokenSetKeyRequest.md new file mode 100644 index 000000000..1c5847db4 --- /dev/null +++ b/docs/TokenSetKeyRequest.md @@ -0,0 +1,30 @@ +# TokenSetKeyRequest + +Set token's key + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**key** | **str** | | + +## Example + +```python +from authentik_client.models.token_set_key_request import TokenSetKeyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TokenSetKeyRequest from a JSON string +token_set_key_request_instance = TokenSetKeyRequest.from_json(json) +# print the JSON string representation of the object +print(TokenSetKeyRequest.to_json()) + +# convert the object into a dict +token_set_key_request_dict = token_set_key_request_instance.to_dict() +# create an instance of TokenSetKeyRequest from a dict +token_set_key_request_from_dict = TokenSetKeyRequest.from_dict(token_set_key_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TokenView.md b/docs/TokenView.md new file mode 100644 index 000000000..0634a368b --- /dev/null +++ b/docs/TokenView.md @@ -0,0 +1,30 @@ +# TokenView + +Show token's current key + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**key** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.token_view import TokenView + +# TODO update the JSON string below +json = "{}" +# create an instance of TokenView from a JSON string +token_view_instance = TokenView.from_json(json) +# print the JSON string representation of the object +print(TokenView.to_json()) + +# convert the object into a dict +token_view_dict = token_view_instance.to_dict() +# create an instance of TokenView from a dict +token_view_from_dict = TokenView.from_dict(token_view_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TransactionApplicationRequest.md b/docs/TransactionApplicationRequest.md new file mode 100644 index 000000000..579043ed8 --- /dev/null +++ b/docs/TransactionApplicationRequest.md @@ -0,0 +1,33 @@ +# TransactionApplicationRequest + +Serializer for creating a provider and an application in one transaction + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**app** | [**ApplicationRequest**](ApplicationRequest.md) | | +**provider_model** | [**ProviderModelEnum**](ProviderModelEnum.md) | | +**provider** | [**ModelRequest**](ModelRequest.md) | | +**policy_bindings** | [**List[TransactionPolicyBindingRequest]**](TransactionPolicyBindingRequest.md) | | [optional] + +## Example + +```python +from authentik_client.models.transaction_application_request import TransactionApplicationRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TransactionApplicationRequest from a JSON string +transaction_application_request_instance = TransactionApplicationRequest.from_json(json) +# print the JSON string representation of the object +print(TransactionApplicationRequest.to_json()) + +# convert the object into a dict +transaction_application_request_dict = transaction_application_request_instance.to_dict() +# create an instance of TransactionApplicationRequest from a dict +transaction_application_request_from_dict = TransactionApplicationRequest.from_dict(transaction_application_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TransactionApplicationResponse.md b/docs/TransactionApplicationResponse.md new file mode 100644 index 000000000..57fcc9f7f --- /dev/null +++ b/docs/TransactionApplicationResponse.md @@ -0,0 +1,31 @@ +# TransactionApplicationResponse + +Transactional creation response + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**applied** | **bool** | | +**logs** | **List[str]** | | + +## Example + +```python +from authentik_client.models.transaction_application_response import TransactionApplicationResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of TransactionApplicationResponse from a JSON string +transaction_application_response_instance = TransactionApplicationResponse.from_json(json) +# print the JSON string representation of the object +print(TransactionApplicationResponse.to_json()) + +# convert the object into a dict +transaction_application_response_dict = transaction_application_response_instance.to_dict() +# create an instance of TransactionApplicationResponse from a dict +transaction_application_response_from_dict = TransactionApplicationResponse.from_dict(transaction_application_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TransactionPolicyBindingRequest.md b/docs/TransactionPolicyBindingRequest.md new file mode 100644 index 000000000..2a18b6bb3 --- /dev/null +++ b/docs/TransactionPolicyBindingRequest.md @@ -0,0 +1,37 @@ +# TransactionPolicyBindingRequest + +PolicyBindingSerializer which does not require target as target is set implicitly + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**policy** | **UUID** | | [optional] +**group** | **UUID** | | [optional] +**user** | **int** | | [optional] +**negate** | **bool** | Negates the outcome of the policy. Messages are unaffected. | [optional] +**enabled** | **bool** | | [optional] +**order** | **int** | | +**timeout** | **int** | Timeout after which Policy execution is terminated. | [optional] +**failure_result** | **bool** | Result if the Policy execution fails. | [optional] + +## Example + +```python +from authentik_client.models.transaction_policy_binding_request import TransactionPolicyBindingRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of TransactionPolicyBindingRequest from a JSON string +transaction_policy_binding_request_instance = TransactionPolicyBindingRequest.from_json(json) +# print the JSON string representation of the object +print(TransactionPolicyBindingRequest.to_json()) + +# convert the object into a dict +transaction_policy_binding_request_dict = transaction_policy_binding_request_instance.to_dict() +# create an instance of TransactionPolicyBindingRequest from a dict +transaction_policy_binding_request_from_dict = TransactionPolicyBindingRequest.from_dict(transaction_policy_binding_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TransportModeEnum.md b/docs/TransportModeEnum.md new file mode 100644 index 000000000..437f4e313 --- /dev/null +++ b/docs/TransportModeEnum.md @@ -0,0 +1,16 @@ +# TransportModeEnum + + +## Enum + +* `LOCAL` (value: `'local'`) + +* `WEBHOOK` (value: `'webhook'`) + +* `WEBHOOK_SLACK` (value: `'webhook_slack'`) + +* `EMAIL` (value: `'email'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/TypeCreate.md b/docs/TypeCreate.md new file mode 100644 index 000000000..6fc088043 --- /dev/null +++ b/docs/TypeCreate.md @@ -0,0 +1,36 @@ +# TypeCreate + +Types of an object that can be created + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**description** | **str** | | +**component** | **str** | | +**model_name** | **str** | | +**icon_url** | **str** | | [optional] +**requires_enterprise** | **bool** | | [optional] [default to False] +**deprecated** | **bool** | | [optional] [default to False] + +## Example + +```python +from authentik_client.models.type_create import TypeCreate + +# TODO update the JSON string below +json = "{}" +# create an instance of TypeCreate from a JSON string +type_create_instance = TypeCreate.from_json(json) +# print the JSON string representation of the object +print(TypeCreate.to_json()) + +# convert the object into a dict +type_create_dict = type_create_instance.to_dict() +# create an instance of TypeCreate from a dict +type_create_from_dict = TypeCreate.from_dict(type_create_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UiThemeEnum.md b/docs/UiThemeEnum.md new file mode 100644 index 000000000..c9166d4a0 --- /dev/null +++ b/docs/UiThemeEnum.md @@ -0,0 +1,14 @@ +# UiThemeEnum + + +## Enum + +* `AUTOMATIC` (value: `'automatic'`) + +* `LIGHT` (value: `'light'`) + +* `DARK` (value: `'dark'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UniquePasswordPolicy.md b/docs/UniquePasswordPolicy.md new file mode 100644 index 000000000..0c35b9974 --- /dev/null +++ b/docs/UniquePasswordPolicy.md @@ -0,0 +1,39 @@ +# UniquePasswordPolicy + +Password Uniqueness Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**bound_to** | **int** | Return objects policy is bound to | [readonly] +**password_field** | **str** | Field key to check, field keys defined in Prompt stages are available. | [optional] +**num_historical_passwords** | **int** | Number of passwords to check against. | [optional] + +## Example + +```python +from authentik_client.models.unique_password_policy import UniquePasswordPolicy + +# TODO update the JSON string below +json = "{}" +# create an instance of UniquePasswordPolicy from a JSON string +unique_password_policy_instance = UniquePasswordPolicy.from_json(json) +# print the JSON string representation of the object +print(UniquePasswordPolicy.to_json()) + +# convert the object into a dict +unique_password_policy_dict = unique_password_policy_instance.to_dict() +# create an instance of UniquePasswordPolicy from a dict +unique_password_policy_from_dict = UniquePasswordPolicy.from_dict(unique_password_policy_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UniquePasswordPolicyRequest.md b/docs/UniquePasswordPolicyRequest.md new file mode 100644 index 000000000..0b83b4d72 --- /dev/null +++ b/docs/UniquePasswordPolicyRequest.md @@ -0,0 +1,33 @@ +# UniquePasswordPolicyRequest + +Password Uniqueness Policy Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**execution_logging** | **bool** | When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged. | [optional] +**password_field** | **str** | Field key to check, field keys defined in Prompt stages are available. | [optional] +**num_historical_passwords** | **int** | Number of passwords to check against. | [optional] + +## Example + +```python +from authentik_client.models.unique_password_policy_request import UniquePasswordPolicyRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UniquePasswordPolicyRequest from a JSON string +unique_password_policy_request_instance = UniquePasswordPolicyRequest.from_json(json) +# print the JSON string representation of the object +print(UniquePasswordPolicyRequest.to_json()) + +# convert the object into a dict +unique_password_policy_request_dict = unique_password_policy_request_instance.to_dict() +# create an instance of UniquePasswordPolicyRequest from a dict +unique_password_policy_request_from_dict = UniquePasswordPolicyRequest.from_dict(unique_password_policy_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UsageEnum.md b/docs/UsageEnum.md new file mode 100644 index 000000000..323631120 --- /dev/null +++ b/docs/UsageEnum.md @@ -0,0 +1,10 @@ +# UsageEnum + + +## Enum + +* `MEDIA` (value: `'media'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UsedBy.md b/docs/UsedBy.md new file mode 100644 index 000000000..3b83a6373 --- /dev/null +++ b/docs/UsedBy.md @@ -0,0 +1,34 @@ +# UsedBy + +A list of all objects referencing the queried object + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**app** | **str** | | +**model_name** | **str** | | +**pk** | **str** | | +**name** | **str** | | +**action** | [**UsedByActionEnum**](UsedByActionEnum.md) | | + +## Example + +```python +from authentik_client.models.used_by import UsedBy + +# TODO update the JSON string below +json = "{}" +# create an instance of UsedBy from a JSON string +used_by_instance = UsedBy.from_json(json) +# print the JSON string representation of the object +print(UsedBy.to_json()) + +# convert the object into a dict +used_by_dict = used_by_instance.to_dict() +# create an instance of UsedBy from a dict +used_by_from_dict = UsedBy.from_dict(used_by_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UsedByActionEnum.md b/docs/UsedByActionEnum.md new file mode 100644 index 000000000..c0025e66b --- /dev/null +++ b/docs/UsedByActionEnum.md @@ -0,0 +1,18 @@ +# UsedByActionEnum + + +## Enum + +* `CASCADE` (value: `'cascade'`) + +* `CASCADE_MANY` (value: `'cascade_many'`) + +* `SET_NULL` (value: `'set_null'`) + +* `SET_DEFAULT` (value: `'set_default'`) + +* `LEFT_DANGLING` (value: `'left_dangling'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/User.md b/docs/User.md new file mode 100644 index 000000000..a835c9b36 --- /dev/null +++ b/docs/User.md @@ -0,0 +1,49 @@ +# User + +User Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**username** | **str** | | +**name** | **str** | User's display name. | +**is_active** | **bool** | Designates whether this user should be treated as active. Unselect this instead of deleting accounts. | [optional] +**last_login** | **datetime** | | [optional] +**date_joined** | **datetime** | | [readonly] +**is_superuser** | **bool** | | [readonly] +**groups** | **List[UUID]** | | [optional] +**groups_obj** | [**List[PartialGroup]**](PartialGroup.md) | | [readonly] +**roles** | **List[UUID]** | | [optional] +**roles_obj** | [**List[Role]**](Role.md) | | [readonly] +**email** | **str** | | [optional] +**avatar** | **str** | User's avatar, either a http/https URL or a data URI | [readonly] +**attributes** | **Dict[str, object]** | | [optional] +**uid** | **str** | | [readonly] +**path** | **str** | | [optional] +**type** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional] +**uuid** | **UUID** | | [readonly] +**password_change_date** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.user import User + +# TODO update the JSON string below +json = "{}" +# create an instance of User from a JSON string +user_instance = User.from_json(json) +# print the JSON string representation of the object +print(User.to_json()) + +# convert the object into a dict +user_dict = user_instance.to_dict() +# create an instance of User from a dict +user_from_dict = User.from_dict(user_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserAccountLockdownRequest.md b/docs/UserAccountLockdownRequest.md new file mode 100644 index 000000000..34ef3d08c --- /dev/null +++ b/docs/UserAccountLockdownRequest.md @@ -0,0 +1,30 @@ +# UserAccountLockdownRequest + +Choose the target account before starting the lockdown flow. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**user** | **int** | User to lock. If omitted, locks the current user (self-service). | [optional] + +## Example + +```python +from authentik_client.models.user_account_lockdown_request import UserAccountLockdownRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserAccountLockdownRequest from a JSON string +user_account_lockdown_request_instance = UserAccountLockdownRequest.from_json(json) +# print the JSON string representation of the object +print(UserAccountLockdownRequest.to_json()) + +# convert the object into a dict +user_account_lockdown_request_dict = user_account_lockdown_request_instance.to_dict() +# create an instance of UserAccountLockdownRequest from a dict +user_account_lockdown_request_from_dict = UserAccountLockdownRequest.from_dict(user_account_lockdown_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserAccountRequest.md b/docs/UserAccountRequest.md new file mode 100644 index 000000000..ac6e2d3e4 --- /dev/null +++ b/docs/UserAccountRequest.md @@ -0,0 +1,30 @@ +# UserAccountRequest + +Account adding/removing operations + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | + +## Example + +```python +from authentik_client.models.user_account_request import UserAccountRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserAccountRequest from a JSON string +user_account_request_instance = UserAccountRequest.from_json(json) +# print the JSON string representation of the object +print(UserAccountRequest.to_json()) + +# convert the object into a dict +user_account_request_dict = user_account_request_instance.to_dict() +# create an instance of UserAccountRequest from a dict +user_account_request_from_dict = UserAccountRequest.from_dict(user_account_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserAccountSerializerForRoleRequest.md b/docs/UserAccountSerializerForRoleRequest.md new file mode 100644 index 000000000..fae89a75c --- /dev/null +++ b/docs/UserAccountSerializerForRoleRequest.md @@ -0,0 +1,30 @@ +# UserAccountSerializerForRoleRequest + +Account adding/removing operations + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | + +## Example + +```python +from authentik_client.models.user_account_serializer_for_role_request import UserAccountSerializerForRoleRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserAccountSerializerForRoleRequest from a JSON string +user_account_serializer_for_role_request_instance = UserAccountSerializerForRoleRequest.from_json(json) +# print the JSON string representation of the object +print(UserAccountSerializerForRoleRequest.to_json()) + +# convert the object into a dict +user_account_serializer_for_role_request_dict = user_account_serializer_for_role_request_instance.to_dict() +# create an instance of UserAccountSerializerForRoleRequest from a dict +user_account_serializer_for_role_request_from_dict = UserAccountSerializerForRoleRequest.from_dict(user_account_serializer_for_role_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserAttributeEnum.md b/docs/UserAttributeEnum.md new file mode 100644 index 000000000..2c38bce7e --- /dev/null +++ b/docs/UserAttributeEnum.md @@ -0,0 +1,12 @@ +# UserAttributeEnum + + +## Enum + +* `USERNAME` (value: `'username'`) + +* `EMAIL` (value: `'email'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserConsent.md b/docs/UserConsent.md new file mode 100644 index 000000000..3872e0e23 --- /dev/null +++ b/docs/UserConsent.md @@ -0,0 +1,35 @@ +# UserConsent + +UserConsent Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**expires** | **datetime** | | [optional] +**expiring** | **bool** | | [optional] +**user** | [**User**](User.md) | | +**application** | [**Application**](Application.md) | | +**permissions** | **str** | | [optional] [default to ''] + +## Example + +```python +from authentik_client.models.user_consent import UserConsent + +# TODO update the JSON string below +json = "{}" +# create an instance of UserConsent from a JSON string +user_consent_instance = UserConsent.from_json(json) +# print the JSON string representation of the object +print(UserConsent.to_json()) + +# convert the object into a dict +user_consent_dict = user_consent_instance.to_dict() +# create an instance of UserConsent from a dict +user_consent_from_dict = UserConsent.from_dict(user_consent_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserCreationModeEnum.md b/docs/UserCreationModeEnum.md new file mode 100644 index 000000000..1bf7d85c3 --- /dev/null +++ b/docs/UserCreationModeEnum.md @@ -0,0 +1,14 @@ +# UserCreationModeEnum + + +## Enum + +* `NEVER_CREATE` (value: `'never_create'`) + +* `CREATE_WHEN_REQUIRED` (value: `'create_when_required'`) + +* `ALWAYS_CREATE` (value: `'always_create'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserDeleteStage.md b/docs/UserDeleteStage.md new file mode 100644 index 000000000..d3c477f1e --- /dev/null +++ b/docs/UserDeleteStage.md @@ -0,0 +1,36 @@ +# UserDeleteStage + +UserDeleteStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] + +## Example + +```python +from authentik_client.models.user_delete_stage import UserDeleteStage + +# TODO update the JSON string below +json = "{}" +# create an instance of UserDeleteStage from a JSON string +user_delete_stage_instance = UserDeleteStage.from_json(json) +# print the JSON string representation of the object +print(UserDeleteStage.to_json()) + +# convert the object into a dict +user_delete_stage_dict = user_delete_stage_instance.to_dict() +# create an instance of UserDeleteStage from a dict +user_delete_stage_from_dict = UserDeleteStage.from_dict(user_delete_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserDeleteStageRequest.md b/docs/UserDeleteStageRequest.md new file mode 100644 index 000000000..e5cc39514 --- /dev/null +++ b/docs/UserDeleteStageRequest.md @@ -0,0 +1,30 @@ +# UserDeleteStageRequest + +UserDeleteStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | + +## Example + +```python +from authentik_client.models.user_delete_stage_request import UserDeleteStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserDeleteStageRequest from a JSON string +user_delete_stage_request_instance = UserDeleteStageRequest.from_json(json) +# print the JSON string representation of the object +print(UserDeleteStageRequest.to_json()) + +# convert the object into a dict +user_delete_stage_request_dict = user_delete_stage_request_instance.to_dict() +# create an instance of UserDeleteStageRequest from a dict +user_delete_stage_request_from_dict = UserDeleteStageRequest.from_dict(user_delete_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserFieldsEnum.md b/docs/UserFieldsEnum.md new file mode 100644 index 000000000..a7fdd8a2f --- /dev/null +++ b/docs/UserFieldsEnum.md @@ -0,0 +1,14 @@ +# UserFieldsEnum + + +## Enum + +* `EMAIL` (value: `'email'`) + +* `USERNAME` (value: `'username'`) + +* `UPN` (value: `'upn'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserKerberosSourceConnection.md b/docs/UserKerberosSourceConnection.md new file mode 100644 index 000000000..8b4150354 --- /dev/null +++ b/docs/UserKerberosSourceConnection.md @@ -0,0 +1,36 @@ +# UserKerberosSourceConnection + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**user** | **int** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of UserKerberosSourceConnection from a JSON string +user_kerberos_source_connection_instance = UserKerberosSourceConnection.from_json(json) +# print the JSON string representation of the object +print(UserKerberosSourceConnection.to_json()) + +# convert the object into a dict +user_kerberos_source_connection_dict = user_kerberos_source_connection_instance.to_dict() +# create an instance of UserKerberosSourceConnection from a dict +user_kerberos_source_connection_from_dict = UserKerberosSourceConnection.from_dict(user_kerberos_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserKerberosSourceConnectionRequest.md b/docs/UserKerberosSourceConnectionRequest.md new file mode 100644 index 000000000..196ac92e6 --- /dev/null +++ b/docs/UserKerberosSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# UserKerberosSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.user_kerberos_source_connection_request import UserKerberosSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserKerberosSourceConnectionRequest from a JSON string +user_kerberos_source_connection_request_instance = UserKerberosSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(UserKerberosSourceConnectionRequest.to_json()) + +# convert the object into a dict +user_kerberos_source_connection_request_dict = user_kerberos_source_connection_request_instance.to_dict() +# create an instance of UserKerberosSourceConnectionRequest from a dict +user_kerberos_source_connection_request_from_dict = UserKerberosSourceConnectionRequest.from_dict(user_kerberos_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserLDAPSourceConnection.md b/docs/UserLDAPSourceConnection.md new file mode 100644 index 000000000..19ef43fb9 --- /dev/null +++ b/docs/UserLDAPSourceConnection.md @@ -0,0 +1,37 @@ +# UserLDAPSourceConnection + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**user** | **int** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] +**user_obj** | [**PartialUser**](PartialUser.md) | | [readonly] + +## Example + +```python +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of UserLDAPSourceConnection from a JSON string +user_ldap_source_connection_instance = UserLDAPSourceConnection.from_json(json) +# print the JSON string representation of the object +print(UserLDAPSourceConnection.to_json()) + +# convert the object into a dict +user_ldap_source_connection_dict = user_ldap_source_connection_instance.to_dict() +# create an instance of UserLDAPSourceConnection from a dict +user_ldap_source_connection_from_dict = UserLDAPSourceConnection.from_dict(user_ldap_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserLDAPSourceConnectionRequest.md b/docs/UserLDAPSourceConnectionRequest.md new file mode 100644 index 000000000..7d73ac184 --- /dev/null +++ b/docs/UserLDAPSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# UserLDAPSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.user_ldap_source_connection_request import UserLDAPSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserLDAPSourceConnectionRequest from a JSON string +user_ldap_source_connection_request_instance = UserLDAPSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(UserLDAPSourceConnectionRequest.to_json()) + +# convert the object into a dict +user_ldap_source_connection_request_dict = user_ldap_source_connection_request_instance.to_dict() +# create an instance of UserLDAPSourceConnectionRequest from a dict +user_ldap_source_connection_request_from_dict = UserLDAPSourceConnectionRequest.from_dict(user_ldap_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserLoginChallenge.md b/docs/UserLoginChallenge.md new file mode 100644 index 000000000..0887f648e --- /dev/null +++ b/docs/UserLoginChallenge.md @@ -0,0 +1,34 @@ +# UserLoginChallenge + +Empty challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**flow_info** | [**ContextualFlowInfo**](ContextualFlowInfo.md) | | [optional] +**component** | **str** | | [optional] [default to 'ak-stage-user-login'] +**response_errors** | **Dict[str, List[ErrorDetail]]** | | [optional] +**pending_user** | **str** | | +**pending_user_avatar** | **str** | | + +## Example + +```python +from authentik_client.models.user_login_challenge import UserLoginChallenge + +# TODO update the JSON string below +json = "{}" +# create an instance of UserLoginChallenge from a JSON string +user_login_challenge_instance = UserLoginChallenge.from_json(json) +# print the JSON string representation of the object +print(UserLoginChallenge.to_json()) + +# convert the object into a dict +user_login_challenge_dict = user_login_challenge_instance.to_dict() +# create an instance of UserLoginChallenge from a dict +user_login_challenge_from_dict = UserLoginChallenge.from_dict(user_login_challenge_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserLoginChallengeResponseRequest.md b/docs/UserLoginChallengeResponseRequest.md new file mode 100644 index 000000000..405c715da --- /dev/null +++ b/docs/UserLoginChallengeResponseRequest.md @@ -0,0 +1,31 @@ +# UserLoginChallengeResponseRequest + +User login challenge + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**component** | **str** | | [optional] [default to 'ak-stage-user-login'] +**remember_me** | **bool** | | + +## Example + +```python +from authentik_client.models.user_login_challenge_response_request import UserLoginChallengeResponseRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserLoginChallengeResponseRequest from a JSON string +user_login_challenge_response_request_instance = UserLoginChallengeResponseRequest.from_json(json) +# print the JSON string representation of the object +print(UserLoginChallengeResponseRequest.to_json()) + +# convert the object into a dict +user_login_challenge_response_request_dict = user_login_challenge_response_request_instance.to_dict() +# create an instance of UserLoginChallengeResponseRequest from a dict +user_login_challenge_response_request_from_dict = UserLoginChallengeResponseRequest.from_dict(user_login_challenge_response_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserLoginStage.md b/docs/UserLoginStage.md new file mode 100644 index 000000000..aba7f3ce7 --- /dev/null +++ b/docs/UserLoginStage.md @@ -0,0 +1,42 @@ +# UserLoginStage + +UserLoginStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**session_duration** | **str** | Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**terminate_other_sessions** | **bool** | Terminate all other sessions of the user logging in. | [optional] +**remember_me_offset** | **str** | Offset the session will be extended by when the user picks the remember me option. Default of 0 means that the remember me option will not be shown. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**network_binding** | [**NetworkBindingEnum**](NetworkBindingEnum.md) | Bind sessions created by this stage to the configured network | [optional] +**geoip_binding** | [**GeoipBindingEnum**](GeoipBindingEnum.md) | Bind sessions created by this stage to the configured GeoIP location | [optional] +**remember_device** | **str** | When set to a non-zero value, authentik will save a cookie with a longer expiry,to remember the device the user is logging in from. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] + +## Example + +```python +from authentik_client.models.user_login_stage import UserLoginStage + +# TODO update the JSON string below +json = "{}" +# create an instance of UserLoginStage from a JSON string +user_login_stage_instance = UserLoginStage.from_json(json) +# print the JSON string representation of the object +print(UserLoginStage.to_json()) + +# convert the object into a dict +user_login_stage_dict = user_login_stage_instance.to_dict() +# create an instance of UserLoginStage from a dict +user_login_stage_from_dict = UserLoginStage.from_dict(user_login_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserLoginStageRequest.md b/docs/UserLoginStageRequest.md new file mode 100644 index 000000000..7c6732e4c --- /dev/null +++ b/docs/UserLoginStageRequest.md @@ -0,0 +1,36 @@ +# UserLoginStageRequest + +UserLoginStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**session_duration** | **str** | Determines how long a session lasts. Default of 0 means that the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**terminate_other_sessions** | **bool** | Terminate all other sessions of the user logging in. | [optional] +**remember_me_offset** | **str** | Offset the session will be extended by when the user picks the remember me option. Default of 0 means that the remember me option will not be shown. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] +**network_binding** | [**NetworkBindingEnum**](NetworkBindingEnum.md) | Bind sessions created by this stage to the configured network | [optional] +**geoip_binding** | [**GeoipBindingEnum**](GeoipBindingEnum.md) | Bind sessions created by this stage to the configured GeoIP location | [optional] +**remember_device** | **str** | When set to a non-zero value, authentik will save a cookie with a longer expiry,to remember the device the user is logging in from. (Format: hours=-1;minutes=-2;seconds=-3) | [optional] + +## Example + +```python +from authentik_client.models.user_login_stage_request import UserLoginStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserLoginStageRequest from a JSON string +user_login_stage_request_instance = UserLoginStageRequest.from_json(json) +# print the JSON string representation of the object +print(UserLoginStageRequest.to_json()) + +# convert the object into a dict +user_login_stage_request_dict = user_login_stage_request_instance.to_dict() +# create an instance of UserLoginStageRequest from a dict +user_login_stage_request_from_dict = UserLoginStageRequest.from_dict(user_login_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserLogoutStage.md b/docs/UserLogoutStage.md new file mode 100644 index 000000000..52dbc4c38 --- /dev/null +++ b/docs/UserLogoutStage.md @@ -0,0 +1,36 @@ +# UserLogoutStage + +UserLogoutStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] + +## Example + +```python +from authentik_client.models.user_logout_stage import UserLogoutStage + +# TODO update the JSON string below +json = "{}" +# create an instance of UserLogoutStage from a JSON string +user_logout_stage_instance = UserLogoutStage.from_json(json) +# print the JSON string representation of the object +print(UserLogoutStage.to_json()) + +# convert the object into a dict +user_logout_stage_dict = user_logout_stage_instance.to_dict() +# create an instance of UserLogoutStage from a dict +user_logout_stage_from_dict = UserLogoutStage.from_dict(user_logout_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserLogoutStageRequest.md b/docs/UserLogoutStageRequest.md new file mode 100644 index 000000000..c0f53274d --- /dev/null +++ b/docs/UserLogoutStageRequest.md @@ -0,0 +1,30 @@ +# UserLogoutStageRequest + +UserLogoutStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | + +## Example + +```python +from authentik_client.models.user_logout_stage_request import UserLogoutStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserLogoutStageRequest from a JSON string +user_logout_stage_request_instance = UserLogoutStageRequest.from_json(json) +# print the JSON string representation of the object +print(UserLogoutStageRequest.to_json()) + +# convert the object into a dict +user_logout_stage_request_dict = user_logout_stage_request_instance.to_dict() +# create an instance of UserLogoutStageRequest from a dict +user_logout_stage_request_from_dict = UserLogoutStageRequest.from_dict(user_logout_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserMatchingModeEnum.md b/docs/UserMatchingModeEnum.md new file mode 100644 index 000000000..e6d25913f --- /dev/null +++ b/docs/UserMatchingModeEnum.md @@ -0,0 +1,18 @@ +# UserMatchingModeEnum + + +## Enum + +* `IDENTIFIER` (value: `'identifier'`) + +* `EMAIL_LINK` (value: `'email_link'`) + +* `EMAIL_DENY` (value: `'email_deny'`) + +* `USERNAME_LINK` (value: `'username_link'`) + +* `USERNAME_DENY` (value: `'username_deny'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserOAuthSourceConnection.md b/docs/UserOAuthSourceConnection.md new file mode 100644 index 000000000..a713f2f32 --- /dev/null +++ b/docs/UserOAuthSourceConnection.md @@ -0,0 +1,37 @@ +# UserOAuthSourceConnection + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**user** | **int** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] +**expires** | **datetime** | | [optional] + +## Example + +```python +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of UserOAuthSourceConnection from a JSON string +user_o_auth_source_connection_instance = UserOAuthSourceConnection.from_json(json) +# print the JSON string representation of the object +print(UserOAuthSourceConnection.to_json()) + +# convert the object into a dict +user_o_auth_source_connection_dict = user_o_auth_source_connection_instance.to_dict() +# create an instance of UserOAuthSourceConnection from a dict +user_o_auth_source_connection_from_dict = UserOAuthSourceConnection.from_dict(user_o_auth_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserOAuthSourceConnectionRequest.md b/docs/UserOAuthSourceConnectionRequest.md new file mode 100644 index 000000000..9ef4b037d --- /dev/null +++ b/docs/UserOAuthSourceConnectionRequest.md @@ -0,0 +1,33 @@ +# UserOAuthSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | +**access_token** | **str** | | [optional] +**expires** | **datetime** | | [optional] + +## Example + +```python +from authentik_client.models.user_o_auth_source_connection_request import UserOAuthSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserOAuthSourceConnectionRequest from a JSON string +user_o_auth_source_connection_request_instance = UserOAuthSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(UserOAuthSourceConnectionRequest.to_json()) + +# convert the object into a dict +user_o_auth_source_connection_request_dict = user_o_auth_source_connection_request_instance.to_dict() +# create an instance of UserOAuthSourceConnectionRequest from a dict +user_o_auth_source_connection_request_from_dict = UserOAuthSourceConnectionRequest.from_dict(user_o_auth_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserPasswordHashSetRequest.md b/docs/UserPasswordHashSetRequest.md new file mode 100644 index 000000000..01adc628d --- /dev/null +++ b/docs/UserPasswordHashSetRequest.md @@ -0,0 +1,30 @@ +# UserPasswordHashSetRequest + +Payload to set a users' password hash directly + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**password** | **str** | | + +## Example + +```python +from authentik_client.models.user_password_hash_set_request import UserPasswordHashSetRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserPasswordHashSetRequest from a JSON string +user_password_hash_set_request_instance = UserPasswordHashSetRequest.from_json(json) +# print the JSON string representation of the object +print(UserPasswordHashSetRequest.to_json()) + +# convert the object into a dict +user_password_hash_set_request_dict = user_password_hash_set_request_instance.to_dict() +# create an instance of UserPasswordHashSetRequest from a dict +user_password_hash_set_request_from_dict = UserPasswordHashSetRequest.from_dict(user_password_hash_set_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserPasswordSetRequest.md b/docs/UserPasswordSetRequest.md new file mode 100644 index 000000000..90af90900 --- /dev/null +++ b/docs/UserPasswordSetRequest.md @@ -0,0 +1,30 @@ +# UserPasswordSetRequest + +Payload to set a users' password directly + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**password** | **str** | | + +## Example + +```python +from authentik_client.models.user_password_set_request import UserPasswordSetRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserPasswordSetRequest from a JSON string +user_password_set_request_instance = UserPasswordSetRequest.from_json(json) +# print the JSON string representation of the object +print(UserPasswordSetRequest.to_json()) + +# convert the object into a dict +user_password_set_request_dict = user_password_set_request_instance.to_dict() +# create an instance of UserPasswordSetRequest from a dict +user_password_set_request_from_dict = UserPasswordSetRequest.from_dict(user_password_set_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserPath.md b/docs/UserPath.md new file mode 100644 index 000000000..8ecad977c --- /dev/null +++ b/docs/UserPath.md @@ -0,0 +1,29 @@ +# UserPath + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**paths** | **List[str]** | | [readonly] + +## Example + +```python +from authentik_client.models.user_path import UserPath + +# TODO update the JSON string below +json = "{}" +# create an instance of UserPath from a JSON string +user_path_instance = UserPath.from_json(json) +# print the JSON string representation of the object +print(UserPath.to_json()) + +# convert the object into a dict +user_path_dict = user_path_instance.to_dict() +# create an instance of UserPath from a dict +user_path_from_dict = UserPath.from_dict(user_path_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserPlexSourceConnection.md b/docs/UserPlexSourceConnection.md new file mode 100644 index 000000000..a2df83e95 --- /dev/null +++ b/docs/UserPlexSourceConnection.md @@ -0,0 +1,36 @@ +# UserPlexSourceConnection + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**user** | **int** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of UserPlexSourceConnection from a JSON string +user_plex_source_connection_instance = UserPlexSourceConnection.from_json(json) +# print the JSON string representation of the object +print(UserPlexSourceConnection.to_json()) + +# convert the object into a dict +user_plex_source_connection_dict = user_plex_source_connection_instance.to_dict() +# create an instance of UserPlexSourceConnection from a dict +user_plex_source_connection_from_dict = UserPlexSourceConnection.from_dict(user_plex_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserPlexSourceConnectionRequest.md b/docs/UserPlexSourceConnectionRequest.md new file mode 100644 index 000000000..f52ca69ec --- /dev/null +++ b/docs/UserPlexSourceConnectionRequest.md @@ -0,0 +1,32 @@ +# UserPlexSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | +**plex_token** | **str** | | + +## Example + +```python +from authentik_client.models.user_plex_source_connection_request import UserPlexSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserPlexSourceConnectionRequest from a JSON string +user_plex_source_connection_request_instance = UserPlexSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(UserPlexSourceConnectionRequest.to_json()) + +# convert the object into a dict +user_plex_source_connection_request_dict = user_plex_source_connection_request_instance.to_dict() +# create an instance of UserPlexSourceConnectionRequest from a dict +user_plex_source_connection_request_from_dict = UserPlexSourceConnectionRequest.from_dict(user_plex_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserRecoveryEmailRequest.md b/docs/UserRecoveryEmailRequest.md new file mode 100644 index 000000000..7201a52e1 --- /dev/null +++ b/docs/UserRecoveryEmailRequest.md @@ -0,0 +1,31 @@ +# UserRecoveryEmailRequest + +Payload to create and email a recovery link + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**token_duration** | **str** | | [optional] +**email_stage** | **UUID** | | + +## Example + +```python +from authentik_client.models.user_recovery_email_request import UserRecoveryEmailRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserRecoveryEmailRequest from a JSON string +user_recovery_email_request_instance = UserRecoveryEmailRequest.from_json(json) +# print the JSON string representation of the object +print(UserRecoveryEmailRequest.to_json()) + +# convert the object into a dict +user_recovery_email_request_dict = user_recovery_email_request_instance.to_dict() +# create an instance of UserRecoveryEmailRequest from a dict +user_recovery_email_request_from_dict = UserRecoveryEmailRequest.from_dict(user_recovery_email_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserRecoveryLinkRequest.md b/docs/UserRecoveryLinkRequest.md new file mode 100644 index 000000000..e8c0fcd20 --- /dev/null +++ b/docs/UserRecoveryLinkRequest.md @@ -0,0 +1,30 @@ +# UserRecoveryLinkRequest + +Payload to create a recovery link + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**token_duration** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.user_recovery_link_request import UserRecoveryLinkRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserRecoveryLinkRequest from a JSON string +user_recovery_link_request_instance = UserRecoveryLinkRequest.from_json(json) +# print the JSON string representation of the object +print(UserRecoveryLinkRequest.to_json()) + +# convert the object into a dict +user_recovery_link_request_dict = user_recovery_link_request_instance.to_dict() +# create an instance of UserRecoveryLinkRequest from a dict +user_recovery_link_request_from_dict = UserRecoveryLinkRequest.from_dict(user_recovery_link_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserRequest.md b/docs/UserRequest.md new file mode 100644 index 000000000..bdd249b2c --- /dev/null +++ b/docs/UserRequest.md @@ -0,0 +1,39 @@ +# UserRequest + +User Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**username** | **str** | | +**name** | **str** | User's display name. | +**is_active** | **bool** | Designates whether this user should be treated as active. Unselect this instead of deleting accounts. | [optional] +**last_login** | **datetime** | | [optional] +**groups** | **List[UUID]** | | [optional] +**roles** | **List[UUID]** | | [optional] +**email** | **str** | | [optional] +**attributes** | **Dict[str, object]** | | [optional] +**path** | **str** | | [optional] +**type** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.user_request import UserRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserRequest from a JSON string +user_request_instance = UserRequest.from_json(json) +# print the JSON string representation of the object +print(UserRequest.to_json()) + +# convert the object into a dict +user_request_dict = user_request_instance.to_dict() +# create an instance of UserRequest from a dict +user_request_from_dict = UserRequest.from_dict(user_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserSAMLSourceConnection.md b/docs/UserSAMLSourceConnection.md new file mode 100644 index 000000000..9293adf71 --- /dev/null +++ b/docs/UserSAMLSourceConnection.md @@ -0,0 +1,36 @@ +# UserSAMLSourceConnection + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**user** | **int** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of UserSAMLSourceConnection from a JSON string +user_saml_source_connection_instance = UserSAMLSourceConnection.from_json(json) +# print the JSON string representation of the object +print(UserSAMLSourceConnection.to_json()) + +# convert the object into a dict +user_saml_source_connection_dict = user_saml_source_connection_instance.to_dict() +# create an instance of UserSAMLSourceConnection from a dict +user_saml_source_connection_from_dict = UserSAMLSourceConnection.from_dict(user_saml_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserSAMLSourceConnectionRequest.md b/docs/UserSAMLSourceConnectionRequest.md new file mode 100644 index 000000000..7f24e7ac3 --- /dev/null +++ b/docs/UserSAMLSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# UserSAMLSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.user_saml_source_connection_request import UserSAMLSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserSAMLSourceConnectionRequest from a JSON string +user_saml_source_connection_request_instance = UserSAMLSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(UserSAMLSourceConnectionRequest.to_json()) + +# convert the object into a dict +user_saml_source_connection_request_dict = user_saml_source_connection_request_instance.to_dict() +# create an instance of UserSAMLSourceConnectionRequest from a dict +user_saml_source_connection_request_from_dict = UserSAMLSourceConnectionRequest.from_dict(user_saml_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserSelf.md b/docs/UserSelf.md new file mode 100644 index 000000000..42758f10d --- /dev/null +++ b/docs/UserSelf.md @@ -0,0 +1,42 @@ +# UserSelf + +User Serializer for information a user can retrieve about themselves + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**username** | **str** | Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only. | +**name** | **str** | User's display name. | +**is_active** | **bool** | Designates whether this user should be treated as active. Unselect this instead of deleting accounts. | [readonly] +**is_superuser** | **bool** | | [readonly] +**groups** | [**List[UserSelfGroups]**](UserSelfGroups.md) | | [readonly] +**roles** | [**List[UserSelfRoles]**](UserSelfRoles.md) | | [readonly] +**email** | **str** | | [optional] +**avatar** | **str** | User's avatar, either a http/https URL or a data URI | [readonly] +**uid** | **str** | | [readonly] +**settings** | **Dict[str, object]** | Get user settings with brand and group settings applied | [readonly] +**type** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional] +**system_permissions** | **List[str]** | Get all system permissions assigned to the user | [readonly] + +## Example + +```python +from authentik_client.models.user_self import UserSelf + +# TODO update the JSON string below +json = "{}" +# create an instance of UserSelf from a JSON string +user_self_instance = UserSelf.from_json(json) +# print the JSON string representation of the object +print(UserSelf.to_json()) + +# convert the object into a dict +user_self_dict = user_self_instance.to_dict() +# create an instance of UserSelf from a dict +user_self_from_dict = UserSelf.from_dict(user_self_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserSelfGroups.md b/docs/UserSelfGroups.md new file mode 100644 index 000000000..45a96a193 --- /dev/null +++ b/docs/UserSelfGroups.md @@ -0,0 +1,30 @@ +# UserSelfGroups + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [readonly] +**pk** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.user_self_groups import UserSelfGroups + +# TODO update the JSON string below +json = "{}" +# create an instance of UserSelfGroups from a JSON string +user_self_groups_instance = UserSelfGroups.from_json(json) +# print the JSON string representation of the object +print(UserSelfGroups.to_json()) + +# convert the object into a dict +user_self_groups_dict = user_self_groups_instance.to_dict() +# create an instance of UserSelfGroups from a dict +user_self_groups_from_dict = UserSelfGroups.from_dict(user_self_groups_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserSelfRoles.md b/docs/UserSelfRoles.md new file mode 100644 index 000000000..bdb76e86f --- /dev/null +++ b/docs/UserSelfRoles.md @@ -0,0 +1,30 @@ +# UserSelfRoles + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | [readonly] +**pk** | **str** | | [readonly] + +## Example + +```python +from authentik_client.models.user_self_roles import UserSelfRoles + +# TODO update the JSON string below +json = "{}" +# create an instance of UserSelfRoles from a JSON string +user_self_roles_instance = UserSelfRoles.from_json(json) +# print the JSON string representation of the object +print(UserSelfRoles.to_json()) + +# convert the object into a dict +user_self_roles_dict = user_self_roles_instance.to_dict() +# create an instance of UserSelfRoles from a dict +user_self_roles_from_dict = UserSelfRoles.from_dict(user_self_roles_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserServiceAccountRequest.md b/docs/UserServiceAccountRequest.md new file mode 100644 index 000000000..1a379cf44 --- /dev/null +++ b/docs/UserServiceAccountRequest.md @@ -0,0 +1,33 @@ +# UserServiceAccountRequest + +Payload to create a service account + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**create_group** | **bool** | | [optional] [default to False] +**expiring** | **bool** | | [optional] [default to True] +**expires** | **datetime** | If not provided, valid for 360 days | [optional] + +## Example + +```python +from authentik_client.models.user_service_account_request import UserServiceAccountRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserServiceAccountRequest from a JSON string +user_service_account_request_instance = UserServiceAccountRequest.from_json(json) +# print the JSON string representation of the object +print(UserServiceAccountRequest.to_json()) + +# convert the object into a dict +user_service_account_request_dict = user_service_account_request_instance.to_dict() +# create an instance of UserServiceAccountRequest from a dict +user_service_account_request_from_dict = UserServiceAccountRequest.from_dict(user_service_account_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserServiceAccountResponse.md b/docs/UserServiceAccountResponse.md new file mode 100644 index 000000000..2722f8c1b --- /dev/null +++ b/docs/UserServiceAccountResponse.md @@ -0,0 +1,33 @@ +# UserServiceAccountResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**username** | **str** | | +**token** | **str** | | +**user_uid** | **str** | | +**user_pk** | **int** | | +**group_pk** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.user_service_account_response import UserServiceAccountResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of UserServiceAccountResponse from a JSON string +user_service_account_response_instance = UserServiceAccountResponse.from_json(json) +# print the JSON string representation of the object +print(UserServiceAccountResponse.to_json()) + +# convert the object into a dict +user_service_account_response_dict = user_service_account_response_instance.to_dict() +# create an instance of UserServiceAccountResponse from a dict +user_service_account_response_from_dict = UserServiceAccountResponse.from_dict(user_service_account_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserSetting.md b/docs/UserSetting.md new file mode 100644 index 000000000..4b42935ce --- /dev/null +++ b/docs/UserSetting.md @@ -0,0 +1,34 @@ +# UserSetting + +Serializer for User settings for stages and sources + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**object_uid** | **str** | | +**component** | **str** | | +**title** | **str** | | +**configure_url** | **str** | | [optional] +**icon_url** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.user_setting import UserSetting + +# TODO update the JSON string below +json = "{}" +# create an instance of UserSetting from a JSON string +user_setting_instance = UserSetting.from_json(json) +# print the JSON string representation of the object +print(UserSetting.to_json()) + +# convert the object into a dict +user_setting_dict = user_setting_instance.to_dict() +# create an instance of UserSetting from a dict +user_setting_from_dict = UserSetting.from_dict(user_setting_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserSourceConnection.md b/docs/UserSourceConnection.md new file mode 100644 index 000000000..aaa5690f4 --- /dev/null +++ b/docs/UserSourceConnection.md @@ -0,0 +1,36 @@ +# UserSourceConnection + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**user** | **int** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.user_source_connection import UserSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of UserSourceConnection from a JSON string +user_source_connection_instance = UserSourceConnection.from_json(json) +# print the JSON string representation of the object +print(UserSourceConnection.to_json()) + +# convert the object into a dict +user_source_connection_dict = user_source_connection_instance.to_dict() +# create an instance of UserSourceConnection from a dict +user_source_connection_from_dict = UserSourceConnection.from_dict(user_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserSourceConnectionRequest.md b/docs/UserSourceConnectionRequest.md new file mode 100644 index 000000000..9543b1ef3 --- /dev/null +++ b/docs/UserSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# UserSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.user_source_connection_request import UserSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserSourceConnectionRequest from a JSON string +user_source_connection_request_instance = UserSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(UserSourceConnectionRequest.to_json()) + +# convert the object into a dict +user_source_connection_request_dict = user_source_connection_request_instance.to_dict() +# create an instance of UserSourceConnectionRequest from a dict +user_source_connection_request_from_dict = UserSourceConnectionRequest.from_dict(user_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserTelegramSourceConnection.md b/docs/UserTelegramSourceConnection.md new file mode 100644 index 000000000..c38d527ca --- /dev/null +++ b/docs/UserTelegramSourceConnection.md @@ -0,0 +1,36 @@ +# UserTelegramSourceConnection + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**user** | **int** | | [readonly] +**source** | **UUID** | | +**source_obj** | [**Source**](Source.md) | | [readonly] +**identifier** | **str** | | +**created** | **datetime** | | [readonly] +**last_updated** | **datetime** | | [readonly] + +## Example + +```python +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection + +# TODO update the JSON string below +json = "{}" +# create an instance of UserTelegramSourceConnection from a JSON string +user_telegram_source_connection_instance = UserTelegramSourceConnection.from_json(json) +# print the JSON string representation of the object +print(UserTelegramSourceConnection.to_json()) + +# convert the object into a dict +user_telegram_source_connection_dict = user_telegram_source_connection_instance.to_dict() +# create an instance of UserTelegramSourceConnection from a dict +user_telegram_source_connection_from_dict = UserTelegramSourceConnection.from_dict(user_telegram_source_connection_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserTelegramSourceConnectionRequest.md b/docs/UserTelegramSourceConnectionRequest.md new file mode 100644 index 000000000..8dd2fe917 --- /dev/null +++ b/docs/UserTelegramSourceConnectionRequest.md @@ -0,0 +1,31 @@ +# UserTelegramSourceConnectionRequest + +User source connection + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**source** | **UUID** | | +**identifier** | **str** | | + +## Example + +```python +from authentik_client.models.user_telegram_source_connection_request import UserTelegramSourceConnectionRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserTelegramSourceConnectionRequest from a JSON string +user_telegram_source_connection_request_instance = UserTelegramSourceConnectionRequest.from_json(json) +# print the JSON string representation of the object +print(UserTelegramSourceConnectionRequest.to_json()) + +# convert the object into a dict +user_telegram_source_connection_request_dict = user_telegram_source_connection_request_instance.to_dict() +# create an instance of UserTelegramSourceConnectionRequest from a dict +user_telegram_source_connection_request_from_dict = UserTelegramSourceConnectionRequest.from_dict(user_telegram_source_connection_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserTypeEnum.md b/docs/UserTypeEnum.md new file mode 100644 index 000000000..ce8b2259b --- /dev/null +++ b/docs/UserTypeEnum.md @@ -0,0 +1,16 @@ +# UserTypeEnum + + +## Enum + +* `INTERNAL` (value: `'internal'`) + +* `EXTERNAL` (value: `'external'`) + +* `SERVICE_ACCOUNT` (value: `'service_account'`) + +* `INTERNAL_SERVICE_ACCOUNT` (value: `'internal_service_account'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserVerificationEnum.md b/docs/UserVerificationEnum.md new file mode 100644 index 000000000..b4814b93a --- /dev/null +++ b/docs/UserVerificationEnum.md @@ -0,0 +1,14 @@ +# UserVerificationEnum + + +## Enum + +* `REQUIRED` (value: `'required'`) + +* `PREFERRED` (value: `'preferred'`) + +* `DISCOURAGED` (value: `'discouraged'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserWriteStage.md b/docs/UserWriteStage.md new file mode 100644 index 000000000..f9844206d --- /dev/null +++ b/docs/UserWriteStage.md @@ -0,0 +1,41 @@ +# UserWriteStage + +UserWriteStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **UUID** | | [readonly] +**name** | **str** | | +**component** | **str** | Get object type so that we know how to edit the object | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**flow_set** | [**List[FlowSet]**](FlowSet.md) | | [readonly] +**user_creation_mode** | [**UserCreationModeEnum**](UserCreationModeEnum.md) | | [optional] +**create_users_as_inactive** | **bool** | When set, newly created users are inactive and cannot login. | [optional] +**create_users_group** | **UUID** | Optionally add newly created users to this group. | [optional] +**user_type** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional] +**user_path_template** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.user_write_stage import UserWriteStage + +# TODO update the JSON string below +json = "{}" +# create an instance of UserWriteStage from a JSON string +user_write_stage_instance = UserWriteStage.from_json(json) +# print the JSON string representation of the object +print(UserWriteStage.to_json()) + +# convert the object into a dict +user_write_stage_dict = user_write_stage_instance.to_dict() +# create an instance of UserWriteStage from a dict +user_write_stage_from_dict = UserWriteStage.from_dict(user_write_stage_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserWriteStageRequest.md b/docs/UserWriteStageRequest.md new file mode 100644 index 000000000..3225571c1 --- /dev/null +++ b/docs/UserWriteStageRequest.md @@ -0,0 +1,35 @@ +# UserWriteStageRequest + +UserWriteStage Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**user_creation_mode** | [**UserCreationModeEnum**](UserCreationModeEnum.md) | | [optional] +**create_users_as_inactive** | **bool** | When set, newly created users are inactive and cannot login. | [optional] +**create_users_group** | **UUID** | Optionally add newly created users to this group. | [optional] +**user_type** | [**UserTypeEnum**](UserTypeEnum.md) | | [optional] +**user_path_template** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.user_write_stage_request import UserWriteStageRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UserWriteStageRequest from a JSON string +user_write_stage_request_instance = UserWriteStageRequest.from_json(json) +# print the JSON string representation of the object +print(UserWriteStageRequest.to_json()) + +# convert the object into a dict +user_write_stage_request_dict = user_write_stage_request_instance.to_dict() +# create an instance of UserWriteStageRequest from a dict +user_write_stage_request_from_dict = UserWriteStageRequest.from_dict(user_write_stage_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/ValidationError.md b/docs/ValidationError.md new file mode 100644 index 000000000..534c7abc8 --- /dev/null +++ b/docs/ValidationError.md @@ -0,0 +1,31 @@ +# ValidationError + +Validation Error + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**non_field_errors** | **List[str]** | | [optional] +**code** | **str** | | [optional] + +## Example + +```python +from authentik_client.models.validation_error import ValidationError + +# TODO update the JSON string below +json = "{}" +# create an instance of ValidationError from a JSON string +validation_error_instance = ValidationError.from_json(json) +# print the JSON string representation of the object +print(ValidationError.to_json()) + +# convert the object into a dict +validation_error_dict = validation_error_instance.to_dict() +# create an instance of ValidationError from a dict +validation_error_from_dict = ValidationError.from_dict(validation_error_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/VendorEnum.md b/docs/VendorEnum.md new file mode 100644 index 000000000..b7e814be9 --- /dev/null +++ b/docs/VendorEnum.md @@ -0,0 +1,16 @@ +# VendorEnum + + +## Enum + +* `GOAUTHENTIK_DOT_IO_SLASH_AT_MERGED` (value: `'goauthentik.io/@merged'`) + +* `GOAUTHENTIK_DOT_IO_SLASH_PLATFORM` (value: `'goauthentik.io/platform'`) + +* `FLEETDM_DOT_COM` (value: `'fleetdm.com'`) + +* `CHROME_DOT_GOOGLE_DOT_COM` (value: `'chrome.google.com'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Version.md b/docs/Version.md new file mode 100644 index 000000000..ac3f04ff5 --- /dev/null +++ b/docs/Version.md @@ -0,0 +1,35 @@ +# Version + +Get running and latest version. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**version_current** | **str** | Get current version | [readonly] +**version_latest** | **str** | Get latest version from cache | [readonly] +**version_latest_valid** | **bool** | Check if latest version is valid | [readonly] +**build_hash** | **str** | Get build hash, if version is not latest or released | [readonly] +**outdated** | **bool** | Check if we're running the latest version | [readonly] +**outpost_outdated** | **bool** | Check if any outpost is outdated/has a version mismatch | [readonly] + +## Example + +```python +from authentik_client.models.version import Version + +# TODO update the JSON string below +json = "{}" +# create an instance of Version from a JSON string +version_instance = Version.from_json(json) +# print the JSON string representation of the object +print(Version.to_json()) + +# convert the object into a dict +version_dict = version_instance.to_dict() +# create an instance of Version from a dict +version_from_dict = Version.from_dict(version_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/VersionHistory.md b/docs/VersionHistory.md new file mode 100644 index 000000000..37a0bc88f --- /dev/null +++ b/docs/VersionHistory.md @@ -0,0 +1,33 @@ +# VersionHistory + +VersionHistory Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | [readonly] +**timestamp** | **datetime** | | +**version** | **str** | | +**build** | **str** | | + +## Example + +```python +from authentik_client.models.version_history import VersionHistory + +# TODO update the JSON string below +json = "{}" +# create an instance of VersionHistory from a JSON string +version_history_instance = VersionHistory.from_json(json) +# print the JSON string representation of the object +print(VersionHistory.to_json()) + +# convert the object into a dict +version_history_dict = version_history_instance.to_dict() +# create an instance of VersionHistory from a dict +version_history_from_dict = VersionHistory.from_dict(version_history_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/WSFederationProvider.md b/docs/WSFederationProvider.md new file mode 100644 index 000000000..4ab904ada --- /dev/null +++ b/docs/WSFederationProvider.md @@ -0,0 +1,59 @@ +# WSFederationProvider + +WSFederationProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**component** | **str** | Get object component so that we know how to edit the object | [readonly] +**assigned_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_application_name** | **str** | Application's display Name. | [readonly] +**assigned_backchannel_application_slug** | **str** | Internal application name, used in URLs. | [readonly] +**assigned_backchannel_application_name** | **str** | Application's display Name. | [readonly] +**verbose_name** | **str** | Return object's verbose_name | [readonly] +**verbose_name_plural** | **str** | Return object's plural verbose_name | [readonly] +**meta_model_name** | **str** | Return internal model name | [readonly] +**reply_url** | **str** | | +**wtrealm** | **str** | | +**assertion_valid_not_before** | **str** | Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3). | [optional] +**assertion_valid_not_on_or_after** | **str** | Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**session_valid_not_on_or_after** | **str** | Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**name_id_mapping** | **UUID** | Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered | [optional] +**authn_context_class_ref_mapping** | **UUID** | Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Service Provider. | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**sign_assertion** | **bool** | | [optional] +**sign_logout_request** | **bool** | | [optional] +**default_name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | | [optional] +**url_download_metadata** | **str** | Get metadata download URL | [readonly] +**url_wsfed** | **str** | Get WS-Fed url | [readonly] + +## Example + +```python +from authentik_client.models.ws_federation_provider import WSFederationProvider + +# TODO update the JSON string below +json = "{}" +# create an instance of WSFederationProvider from a JSON string +ws_federation_provider_instance = WSFederationProvider.from_json(json) +# print the JSON string representation of the object +print(WSFederationProvider.to_json()) + +# convert the object into a dict +ws_federation_provider_dict = ws_federation_provider_instance.to_dict() +# create an instance of WSFederationProvider from a dict +ws_federation_provider_from_dict = WSFederationProvider.from_dict(ws_federation_provider_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/WSFederationProviderRequest.md b/docs/WSFederationProviderRequest.md new file mode 100644 index 000000000..729490b96 --- /dev/null +++ b/docs/WSFederationProviderRequest.md @@ -0,0 +1,48 @@ +# WSFederationProviderRequest + +WSFederationProvider Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**authentication_flow** | **UUID** | Flow used for authentication when the associated application is accessed by an un-authenticated user. | [optional] +**authorization_flow** | **UUID** | Flow used when authorizing this provider. | +**invalidation_flow** | **UUID** | Flow used ending the session from a provider. | +**property_mappings** | **List[UUID]** | | [optional] +**reply_url** | **str** | | +**wtrealm** | **str** | | +**assertion_valid_not_before** | **str** | Assertion valid not before current time + this value (Format: hours=-1;minutes=-2;seconds=-3). | [optional] +**assertion_valid_not_on_or_after** | **str** | Assertion not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**session_valid_not_on_or_after** | **str** | Session not valid on or after current time + this value (Format: hours=1;minutes=2;seconds=3). | [optional] +**name_id_mapping** | **UUID** | Configure how the NameID value will be created. When left empty, the NameIDPolicy of the incoming request will be considered | [optional] +**authn_context_class_ref_mapping** | **UUID** | Configure how the AuthnContextClassRef value will be created. When left empty, the AuthnContextClassRef will be set based on which authentication methods the user used to authenticate. | [optional] +**digest_algorithm** | [**DigestAlgorithmEnum**](DigestAlgorithmEnum.md) | | [optional] +**signature_algorithm** | [**SignatureAlgorithmEnum**](SignatureAlgorithmEnum.md) | | [optional] +**signing_kp** | **UUID** | Keypair used to sign outgoing Responses going to the Service Provider. | [optional] +**encryption_kp** | **UUID** | When selected, incoming assertions are encrypted by the IdP using the public key of the encryption keypair. The assertion is decrypted by the SP using the the private key. | [optional] +**sign_assertion** | **bool** | | [optional] +**sign_logout_request** | **bool** | | [optional] +**default_name_id_policy** | [**SAMLNameIDPolicyEnum**](SAMLNameIDPolicyEnum.md) | | [optional] + +## Example + +```python +from authentik_client.models.ws_federation_provider_request import WSFederationProviderRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of WSFederationProviderRequest from a JSON string +ws_federation_provider_request_instance = WSFederationProviderRequest.from_json(json) +# print the JSON string representation of the object +print(WSFederationProviderRequest.to_json()) + +# convert the object into a dict +ws_federation_provider_request_dict = ws_federation_provider_request_instance.to_dict() +# create an instance of WSFederationProviderRequest from a dict +ws_federation_provider_request_from_dict = WSFederationProviderRequest.from_dict(ws_federation_provider_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/WebAuthnDevice.md b/docs/WebAuthnDevice.md new file mode 100644 index 000000000..c63adf2ee --- /dev/null +++ b/docs/WebAuthnDevice.md @@ -0,0 +1,35 @@ +# WebAuthnDevice + +Serializer for WebAuthn authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pk** | **int** | | [readonly] +**name** | **str** | | +**created_on** | **datetime** | | [readonly] +**device_type** | [**WebAuthnDeviceType**](WebAuthnDeviceType.md) | | [readonly] +**aaguid** | **str** | | [readonly] +**user** | [**PartialUser**](PartialUser.md) | | [readonly] + +## Example + +```python +from authentik_client.models.web_authn_device import WebAuthnDevice + +# TODO update the JSON string below +json = "{}" +# create an instance of WebAuthnDevice from a JSON string +web_authn_device_instance = WebAuthnDevice.from_json(json) +# print the JSON string representation of the object +print(WebAuthnDevice.to_json()) + +# convert the object into a dict +web_authn_device_dict = web_authn_device_instance.to_dict() +# create an instance of WebAuthnDevice from a dict +web_authn_device_from_dict = WebAuthnDevice.from_dict(web_authn_device_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/WebAuthnDeviceRequest.md b/docs/WebAuthnDeviceRequest.md new file mode 100644 index 000000000..7a8ba0896 --- /dev/null +++ b/docs/WebAuthnDeviceRequest.md @@ -0,0 +1,30 @@ +# WebAuthnDeviceRequest + +Serializer for WebAuthn authenticator devices + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | + +## Example + +```python +from authentik_client.models.web_authn_device_request import WebAuthnDeviceRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of WebAuthnDeviceRequest from a JSON string +web_authn_device_request_instance = WebAuthnDeviceRequest.from_json(json) +# print the JSON string representation of the object +print(WebAuthnDeviceRequest.to_json()) + +# convert the object into a dict +web_authn_device_request_dict = web_authn_device_request_instance.to_dict() +# create an instance of WebAuthnDeviceRequest from a dict +web_authn_device_request_from_dict = WebAuthnDeviceRequest.from_dict(web_authn_device_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/WebAuthnDeviceType.md b/docs/WebAuthnDeviceType.md new file mode 100644 index 000000000..0c8c20c05 --- /dev/null +++ b/docs/WebAuthnDeviceType.md @@ -0,0 +1,31 @@ +# WebAuthnDeviceType + +WebAuthnDeviceType Serializer + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**aaguid** | **UUID** | | +**description** | **str** | | + +## Example + +```python +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType + +# TODO update the JSON string below +json = "{}" +# create an instance of WebAuthnDeviceType from a JSON string +web_authn_device_type_instance = WebAuthnDeviceType.from_json(json) +# print the JSON string representation of the object +print(WebAuthnDeviceType.to_json()) + +# convert the object into a dict +web_authn_device_type_dict = web_authn_device_type_instance.to_dict() +# create an instance of WebAuthnDeviceType from a dict +web_authn_device_type_from_dict = WebAuthnDeviceType.from_dict(web_authn_device_type_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/WebAuthnHintEnum.md b/docs/WebAuthnHintEnum.md new file mode 100644 index 000000000..756a4297d --- /dev/null +++ b/docs/WebAuthnHintEnum.md @@ -0,0 +1,14 @@ +# WebAuthnHintEnum + + +## Enum + +* `SECURITY_MINUS_KEY` (value: `'security-key'`) + +* `CLIENT_MINUS_DEVICE` (value: `'client-device'`) + +* `HYBRID` (value: `'hybrid'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/Worker.md b/docs/Worker.md new file mode 100644 index 000000000..8d7efd0f8 --- /dev/null +++ b/docs/Worker.md @@ -0,0 +1,31 @@ +# Worker + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**worker_id** | **str** | | +**version** | **str** | | +**version_matching** | **bool** | | + +## Example + +```python +from authentik_client.models.worker import Worker + +# TODO update the JSON string below +json = "{}" +# create an instance of Worker from a JSON string +worker_instance = Worker.from_json(json) +# print the JSON string representation of the object +print(Worker.to_json()) + +# convert the object into a dict +worker_dict = worker_instance.to_dict() +# create an instance of Worker from a dict +worker_from_dict = Worker.from_dict(worker_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 000000000..08bd73636 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,95 @@ +[project] +name = "authentik_client" +version = "2026.5.7" +description = "authentik" +authors = [ + {name = "authentik Team",email = "hello@goauthentik.io"}, +] +license = { text = "MIT" } +readme = "README.md" +keywords = ["OpenAPI", "OpenAPI-Generator", "authentik"] +requires-python = ">=3.9" + +dependencies = [ + "urllib3 (>=2.1.0,<3.0.0)", + "python-dateutil (>=2.8.2)", + "pydantic (>=2.11)", + "typing-extensions (>=4.7.1)", +] + +[project.urls] +Repository = "https://github.com/GIT_USER_ID/GIT_REPO_ID" + +[tool.poetry] +requires-poetry = ">=2.0" + +[tool.poetry.group.dev.dependencies] +pytest = ">= 7.2.1" +pytest-cov = ">= 2.8.1" +tox = ">= 3.9.0" +flake8 = ">= 4.0.0" +types-python-dateutil = ">= 2.8.19.14" +mypy = ">= 1.5" + + +[build-system] +requires = ["setuptools"] +build-backend = "setuptools.build_meta" + +[tool.pylint.'MESSAGES CONTROL'] +extension-pkg-whitelist = "pydantic" + +[tool.mypy] +files = [ + "authentik_client", + #"test", # auto-generated tests + "tests", # hand-written tests +] +# TODO: enable "strict" once all these individual checks are passing +# strict = true + +# List from: https://mypy.readthedocs.io/en/stable/existing_code.html#introduce-stricter-options +warn_unused_configs = true +warn_redundant_casts = true +warn_unused_ignores = true + +## Getting these passing should be easy +strict_equality = true +extra_checks = true + +## Strongly recommend enabling this one as soon as you can +check_untyped_defs = true + +## These shouldn't be too much additional work, but may be tricky to +## get passing if you use a lot of untyped libraries +disallow_subclassing_any = true +disallow_untyped_decorators = true +disallow_any_generics = true + +### These next few are various gradations of forcing use of type annotations +#disallow_untyped_calls = true +#disallow_incomplete_defs = true +#disallow_untyped_defs = true +# +### This one isn't too hard to get passing, but return on investment is lower +#no_implicit_reexport = true +# +### This one can be tricky to get passing if you use a lot of untyped libraries +#warn_return_any = true + +[[tool.mypy.overrides]] +module = [ + "authentik_client.configuration", +] +warn_unused_ignores = true +strict_equality = true +extra_checks = true +check_untyped_defs = true +disallow_subclassing_any = true +disallow_untyped_decorators = true +disallow_any_generics = true +disallow_untyped_calls = true +disallow_incomplete_defs = true +disallow_untyped_defs = true +no_implicit_reexport = true +warn_return_any = true diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 000000000..9e2d67a53 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,4 @@ +urllib3 >= 2.1.0, < 3.0.0 +python_dateutil >= 2.8.2 +pydantic >= 2.11 +typing-extensions >= 4.7.1 diff --git a/schema.yml b/schema.yml new file mode 100644 index 000000000..3bbd9bfa0 --- /dev/null +++ b/schema.yml @@ -0,0 +1,59077 @@ +openapi: 3.0.3 +info: + title: authentik + version: 2026.5.7 + description: Making authentication simple. + contact: + email: hello@goauthentik.io + license: + name: MIT + url: https://github.com/goauthentik/authentik/blob/main/LICENSE +paths: + /admin/apps/: + get: + operationId: admin_apps_list + description: Read-only view list all installed apps + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/App' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /admin/file/: + get: + operationId: admin_file_list + description: List files from storage backend. + parameters: + - in: query + name: manageable_only + schema: + type: boolean + default: false + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: usage + schema: + allOf: + - $ref: '#/components/schemas/UsageEnum' + default: media + minLength: 1 + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/FileList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: admin_file_create + description: Upload file to storage backend. + tags: + - admin + requestBody: + content: + multipart/form-data: + schema: + $ref: '#/components/schemas/FileUploadRequest' + required: true + security: + - authentik: [] + responses: + '200': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: admin_file_destroy + description: Delete file from storage backend. + parameters: + - $ref: '#/components/parameters/QueryName' + - in: query + name: usage + schema: + allOf: + - $ref: '#/components/schemas/UsageEnum' + default: media + minLength: 1 + tags: + - admin + security: + - authentik: [] + responses: + '200': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /admin/file/used_by/: + get: + operationId: admin_file_used_by_list + parameters: + - $ref: '#/components/parameters/QueryName' + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /admin/models/: + get: + operationId: admin_models_list + description: Read-only view list all installed models + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/App' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /admin/settings/: + get: + operationId: admin_settings_retrieve + description: Settings view + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Settings' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: admin_settings_update + description: Settings view + tags: + - admin + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SettingsRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Settings' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: admin_settings_partial_update + description: Settings view + tags: + - admin + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSettingsRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Settings' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /admin/system/: + get: + operationId: admin_system_retrieve + description: Get system information. + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SystemInfo' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: admin_system_create + description: Get system information. + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SystemInfo' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /admin/version/: + get: + operationId: admin_version_retrieve + description: Get running and latest version. + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Version' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /admin/version/history/: + get: + operationId: admin_version_history_list + description: VersionHistory Viewset + parameters: + - in: query + name: build + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: version + schema: + type: string + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/VersionHistory' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /admin/version/history/{id}/: + get: + operationId: admin_version_history_retrieve + description: VersionHistory Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Version history. + required: true + tags: + - admin + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/VersionHistory' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/all/: + get: + operationId: authenticators_admin_all_list + description: Get all devices for current user + parameters: + - in: query + name: user + schema: + type: integer + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/Device' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/duo/: + get: + operationId: authenticators_admin_duo_list + description: Viewset for Duo authenticator devices (for admins) + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDuoDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: authenticators_admin_duo_create + description: Viewset for Duo authenticator devices (for admins) + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDeviceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/duo/{id}/: + get: + operationId: authenticators_admin_duo_retrieve + description: Viewset for Duo authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Duo Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_admin_duo_update + description: Viewset for Duo authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Duo Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_admin_duo_partial_update + description: Viewset for Duo authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Duo Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedDuoDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_admin_duo_destroy + description: Viewset for Duo authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Duo Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/email/: + get: + operationId: authenticators_admin_email_list + description: Viewset for email authenticator devices (for admins) + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedEmailDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: authenticators_admin_email_create + description: Viewset for email authenticator devices (for admins) + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDeviceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/email/{id}/: + get: + operationId: authenticators_admin_email_retrieve + description: Viewset for email authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Email Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_admin_email_update + description: Viewset for email authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Email Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_admin_email_partial_update + description: Viewset for email authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Email Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedEmailDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_admin_email_destroy + description: Viewset for email authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Email Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/endpoint/: + get: + operationId: authenticators_admin_endpoint_list + description: Viewset for Endpoint authenticator devices (for admins) + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGoogleEndpointDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: authenticators_admin_endpoint_create + description: Viewset for Endpoint authenticator devices (for admins) + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleEndpointDeviceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleEndpointDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/endpoint/{uuid}/: + get: + operationId: authenticators_admin_endpoint_retrieve + description: Viewset for Endpoint authenticator devices (for admins) + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleEndpointDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_admin_endpoint_update + description: Viewset for Endpoint authenticator devices (for admins) + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleEndpointDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleEndpointDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_admin_endpoint_partial_update + description: Viewset for Endpoint authenticator devices (for admins) + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGoogleEndpointDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleEndpointDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_admin_endpoint_destroy + description: Viewset for Endpoint authenticator devices (for admins) + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/sms/: + get: + operationId: authenticators_admin_sms_list + description: Viewset for sms authenticator devices (for admins) + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSMSDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: authenticators_admin_sms_create + description: Viewset for sms authenticator devices (for admins) + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDeviceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/sms/{id}/: + get: + operationId: authenticators_admin_sms_retrieve + description: Viewset for sms authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SMS Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_admin_sms_update + description: Viewset for sms authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SMS Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_admin_sms_partial_update + description: Viewset for sms authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SMS Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSMSDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_admin_sms_destroy + description: Viewset for sms authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SMS Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/static/: + get: + operationId: authenticators_admin_static_list + description: Viewset for static authenticator devices (for admins) + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedStaticDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: authenticators_admin_static_create + description: Viewset for static authenticator devices (for admins) + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDeviceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/static/{id}/: + get: + operationId: authenticators_admin_static_retrieve + description: Viewset for static authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Static Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_admin_static_update + description: Viewset for static authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Static Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_admin_static_partial_update + description: Viewset for static authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Static Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedStaticDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_admin_static_destroy + description: Viewset for static authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Static Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/totp/: + get: + operationId: authenticators_admin_totp_list + description: Viewset for totp authenticator devices (for admins) + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedTOTPDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: authenticators_admin_totp_create + description: Viewset for totp authenticator devices (for admins) + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDeviceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/totp/{id}/: + get: + operationId: authenticators_admin_totp_retrieve + description: Viewset for totp authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this TOTP Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_admin_totp_update + description: Viewset for totp authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this TOTP Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_admin_totp_partial_update + description: Viewset for totp authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this TOTP Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedTOTPDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_admin_totp_destroy + description: Viewset for totp authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this TOTP Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/webauthn/: + get: + operationId: authenticators_admin_webauthn_list + description: Viewset for WebAuthn authenticator devices (for admins) + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedWebAuthnDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: authenticators_admin_webauthn_create + description: Viewset for WebAuthn authenticator devices (for admins) + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDeviceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/admin/webauthn/{id}/: + get: + operationId: authenticators_admin_webauthn_retrieve + description: Viewset for WebAuthn authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WebAuthn Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_admin_webauthn_update + description: Viewset for WebAuthn authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WebAuthn Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_admin_webauthn_partial_update + description: Viewset for WebAuthn authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WebAuthn Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedWebAuthnDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_admin_webauthn_destroy + description: Viewset for WebAuthn authenticator devices (for admins) + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WebAuthn Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/all/: + get: + operationId: authenticators_all_list + description: Get all devices for current user + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/Device' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/duo/: + get: + operationId: authenticators_duo_list + description: Viewset for Duo authenticator devices + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDuoDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/duo/{id}/: + get: + operationId: authenticators_duo_retrieve + description: Viewset for Duo authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Duo Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_duo_update + description: Viewset for Duo authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Duo Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_duo_partial_update + description: Viewset for Duo authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Duo Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedDuoDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_duo_destroy + description: Viewset for Duo authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Duo Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/duo/{id}/used_by/: + get: + operationId: authenticators_duo_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Duo Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/email/: + get: + operationId: authenticators_email_list + description: Viewset for email authenticator devices + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedEmailDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/email/{id}/: + get: + operationId: authenticators_email_retrieve + description: Viewset for email authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Email Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_email_update + description: Viewset for email authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Email Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_email_partial_update + description: Viewset for email authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Email Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedEmailDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_email_destroy + description: Viewset for email authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Email Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/email/{id}/used_by/: + get: + operationId: authenticators_email_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Email Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/endpoint/: + get: + operationId: authenticators_endpoint_list + description: Viewset for Endpoint authenticator devices + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGoogleEndpointDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/endpoint/{uuid}/: + get: + operationId: authenticators_endpoint_retrieve + description: Viewset for Endpoint authenticator devices + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleEndpointDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/endpoint/{uuid}/used_by/: + get: + operationId: authenticators_endpoint_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/sms/: + get: + operationId: authenticators_sms_list + description: Viewset for sms authenticator devices + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSMSDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/sms/{id}/: + get: + operationId: authenticators_sms_retrieve + description: Viewset for sms authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SMS Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_sms_update + description: Viewset for sms authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SMS Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_sms_partial_update + description: Viewset for sms authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SMS Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSMSDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SMSDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_sms_destroy + description: Viewset for sms authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SMS Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/sms/{id}/used_by/: + get: + operationId: authenticators_sms_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SMS Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/static/: + get: + operationId: authenticators_static_list + description: Viewset for static authenticator devices + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedStaticDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/static/{id}/: + get: + operationId: authenticators_static_retrieve + description: Viewset for static authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Static Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_static_update + description: Viewset for static authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Static Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_static_partial_update + description: Viewset for static authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Static Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedStaticDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/StaticDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_static_destroy + description: Viewset for static authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Static Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/static/{id}/used_by/: + get: + operationId: authenticators_static_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Static Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/totp/: + get: + operationId: authenticators_totp_list + description: Viewset for totp authenticator devices + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedTOTPDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/totp/{id}/: + get: + operationId: authenticators_totp_retrieve + description: Viewset for totp authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this TOTP Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_totp_update + description: Viewset for totp authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this TOTP Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_totp_partial_update + description: Viewset for totp authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this TOTP Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedTOTPDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TOTPDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_totp_destroy + description: Viewset for totp authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this TOTP Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/totp/{id}/used_by/: + get: + operationId: authenticators_totp_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this TOTP Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/webauthn/: + get: + operationId: authenticators_webauthn_list + description: Viewset for WebAuthn authenticator devices + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedWebAuthnDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/webauthn/{id}/: + get: + operationId: authenticators_webauthn_retrieve + description: Viewset for WebAuthn authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WebAuthn Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: authenticators_webauthn_update + description: Viewset for WebAuthn authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WebAuthn Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: authenticators_webauthn_partial_update + description: Viewset for WebAuthn authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WebAuthn Device. + required: true + tags: + - authenticators + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedWebAuthnDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: authenticators_webauthn_destroy + description: Viewset for WebAuthn authenticator devices + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WebAuthn Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /authenticators/webauthn/{id}/used_by/: + get: + operationId: authenticators_webauthn_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WebAuthn Device. + required: true + tags: + - authenticators + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/application_entitlements/: + get: + operationId: core_application_entitlements_list + description: ApplicationEntitlement Viewset + parameters: + - in: query + name: app + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedApplicationEntitlementList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: core_application_entitlements_create + description: ApplicationEntitlement Viewset + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ApplicationEntitlementRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/ApplicationEntitlement' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/application_entitlements/{pbm_uuid}/: + get: + operationId: core_application_entitlements_retrieve + description: ApplicationEntitlement Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Application Entitlement. + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ApplicationEntitlement' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: core_application_entitlements_update + description: ApplicationEntitlement Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Application Entitlement. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ApplicationEntitlementRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ApplicationEntitlement' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: core_application_entitlements_partial_update + description: ApplicationEntitlement Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Application Entitlement. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedApplicationEntitlementRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ApplicationEntitlement' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: core_application_entitlements_destroy + description: ApplicationEntitlement Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Application Entitlement. + required: true + tags: + - core + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/application_entitlements/{pbm_uuid}/used_by/: + get: + operationId: core_application_entitlements_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Application Entitlement. + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/applications/: + get: + operationId: core_applications_list + description: Custom list method that checks Policy based access instead of guardian + parameters: + - in: query + name: for_user + schema: + type: integer + - in: query + name: group + schema: + type: string + - in: query + name: meta_description + schema: + type: string + - in: query + name: meta_launch_url + schema: + type: string + - in: query + name: meta_publisher + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - in: query + name: only_with_launch_url + schema: + type: boolean + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: slug + schema: + type: string + - in: query + name: superuser_full_list + schema: + type: boolean + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedApplicationList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: core_applications_create + description: Application Viewset + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ApplicationRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Application' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/applications/{slug}/: + get: + operationId: core_applications_retrieve + description: Application Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal application name, used in URLs. + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Application' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: core_applications_update + description: Application Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal application name, used in URLs. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ApplicationRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Application' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: core_applications_partial_update + description: Application Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal application name, used in URLs. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedApplicationRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Application' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: core_applications_destroy + description: Application Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal application name, used in URLs. + required: true + tags: + - core + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/applications/{slug}/check_access/: + get: + operationId: core_applications_check_access_retrieve + description: Check access to a single application by slug + parameters: + - in: query + name: for_user + schema: + type: integer + - in: path + name: slug + schema: + type: string + description: Internal application name, used in URLs. + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PolicyTestResult' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/applications/{slug}/used_by/: + get: + operationId: core_applications_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal application name, used in URLs. + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/authenticated_sessions/: + get: + operationId: core_authenticated_sessions_list + description: AuthenticatedSession Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: session__last_ip + schema: + type: string + - in: query + name: session__last_user_agent + schema: + type: string + - in: query + name: user__username + schema: + type: string + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAuthenticatedSessionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/authenticated_sessions/{uuid}/: + get: + operationId: core_authenticated_sessions_retrieve + description: AuthenticatedSession Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatedSession' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: core_authenticated_sessions_destroy + description: AuthenticatedSession Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + required: true + tags: + - core + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/authenticated_sessions/{uuid}/used_by/: + get: + operationId: core_authenticated_sessions_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/authenticated_sessions/bulk_delete/: + delete: + operationId: core_authenticated_sessions_bulk_delete_destroy + description: Bulk revoke all sessions for multiple users + parameters: + - in: query + name: user_pks + schema: + type: array + items: + type: integer + description: List of user IDs to revoke all sessions for + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/BulkDeleteSessionResponse' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/brands/: + get: + operationId: core_brands_list + description: Brand Viewset + parameters: + - in: query + name: brand_uuid + schema: + type: string + format: uuid + - in: query + name: branding_default_flow_background + schema: + type: string + - in: query + name: branding_favicon + schema: + type: string + - in: query + name: branding_logo + schema: + type: string + - in: query + name: branding_title + schema: + type: string + - in: query + name: client_certificates + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: default + schema: + type: boolean + - in: query + name: domain + schema: + type: string + - in: query + name: flow_authentication + schema: + type: string + format: uuid + - in: query + name: flow_device_code + schema: + type: string + format: uuid + - in: query + name: flow_invalidation + schema: + type: string + format: uuid + - in: query + name: flow_lockdown + schema: + type: string + format: uuid + - in: query + name: flow_recovery + schema: + type: string + format: uuid + - in: query + name: flow_unenrollment + schema: + type: string + format: uuid + - in: query + name: flow_user_settings + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: web_certificate + schema: + type: string + format: uuid + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedBrandList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: core_brands_create + description: Brand Viewset + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/BrandRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Brand' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/brands/{brand_uuid}/: + get: + operationId: core_brands_retrieve + description: Brand Viewset + parameters: + - in: path + name: brand_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Brand. + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Brand' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: core_brands_update + description: Brand Viewset + parameters: + - in: path + name: brand_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Brand. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/BrandRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Brand' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: core_brands_partial_update + description: Brand Viewset + parameters: + - in: path + name: brand_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Brand. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedBrandRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Brand' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: core_brands_destroy + description: Brand Viewset + parameters: + - in: path + name: brand_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Brand. + required: true + tags: + - core + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/brands/{brand_uuid}/used_by/: + get: + operationId: core_brands_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: brand_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Brand. + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/brands/current/: + get: + operationId: core_brands_current_retrieve + description: Get current brand + tags: + - core + security: + - authentik: [] + - {} + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CurrentBrand' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/groups/: + get: + operationId: core_groups_list + description: Group Viewset + parameters: + - in: query + name: attributes + schema: + type: string + description: Attributes + - in: query + name: include_children + schema: + type: boolean + default: false + - in: query + name: include_inherited_roles + schema: + type: boolean + default: false + - in: query + name: include_parents + schema: + type: boolean + default: false + - in: query + name: include_users + schema: + type: boolean + default: true + - in: query + name: is_superuser + schema: + type: boolean + - in: query + name: members_by_pk + schema: + type: array + items: + type: integer + explode: true + style: form + - in: query + name: members_by_username + schema: + type: array + items: + type: string + description: Required. 150 characters or fewer. Letters, digits and @/./+/-/_ + only. + explode: true + style: form + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGroupList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: core_groups_create + description: Group Viewset + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Group' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/groups/{group_uuid}/: + get: + operationId: core_groups_retrieve + description: Group Viewset + parameters: + - in: path + name: group_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Group. + required: true + - in: query + name: include_children + schema: + type: boolean + default: false + - in: query + name: include_inherited_roles + schema: + type: boolean + default: false + - in: query + name: include_parents + schema: + type: boolean + default: false + - in: query + name: include_users + schema: + type: boolean + default: true + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Group' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: core_groups_update + description: Group Viewset + parameters: + - in: path + name: group_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Group. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Group' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: core_groups_partial_update + description: Group Viewset + parameters: + - in: path + name: group_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Group. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGroupRequest' + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Group' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: core_groups_destroy + description: Group Viewset + parameters: + - in: path + name: group_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Group. + required: true + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/groups/{group_uuid}/add_user/: + post: + operationId: core_groups_add_user_create + description: Add user to group + parameters: + - in: path + name: group_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Group. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserAccountRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '204': + description: User added + '404': + description: User not found + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/groups/{group_uuid}/remove_user/: + post: + operationId: core_groups_remove_user_create + description: Remove user from group + parameters: + - in: path + name: group_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Group. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserAccountRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '204': + description: User removed + '404': + description: User not found + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/groups/{group_uuid}/used_by/: + get: + operationId: core_groups_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: group_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Group. + required: true + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/tokens/: + get: + operationId: core_tokens_list + description: Token Viewset + parameters: + - in: query + name: description + schema: + type: string + - in: query + name: expires + schema: + type: string + format: date-time + - in: query + name: expiring + schema: + type: boolean + - in: query + name: identifier + schema: + type: string + - in: query + name: intent + schema: + $ref: '#/components/schemas/IntentEnum' + - in: query + name: managed + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user__username + schema: + type: string + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedTokenList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: core_tokens_create + description: Token Viewset + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TokenRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Token' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/tokens/{identifier}/: + get: + operationId: core_tokens_retrieve + description: Token Viewset + parameters: + - in: path + name: identifier + schema: + type: string + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Token' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: core_tokens_update + description: Token Viewset + parameters: + - in: path + name: identifier + schema: + type: string + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TokenRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Token' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: core_tokens_partial_update + description: Token Viewset + parameters: + - in: path + name: identifier + schema: + type: string + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedTokenRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Token' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: core_tokens_destroy + description: Token Viewset + parameters: + - in: path + name: identifier + schema: + type: string + required: true + tags: + - core + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/tokens/{identifier}/set_key/: + post: + operationId: core_tokens_set_key_create + description: |- + Set token key. Action is logged as event. `authentik_core.set_token_key` permission + is required. + parameters: + - in: path + name: identifier + schema: + type: string + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TokenSetKeyRequest' + required: true + security: + - authentik: [] + responses: + '204': + description: Successfully changed key + '400': + description: Missing key + '404': + description: Token not found or expired + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/tokens/{identifier}/used_by/: + get: + operationId: core_tokens_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: identifier + schema: + type: string + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/tokens/{identifier}/view_key/: + get: + operationId: core_tokens_view_key_retrieve + description: Return token key and log access + parameters: + - in: path + name: identifier + schema: + type: string + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TokenView' + description: '' + '404': + description: Token not found or expired + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/transactional/applications/: + put: + operationId: core_transactional_applications_update + description: Convert data into a blueprint, validate it and apply it + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TransactionApplicationRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TransactionApplicationResponse' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/user_consent/: + get: + operationId: core_user_consent_list + description: UserConsent Viewset + parameters: + - in: query + name: application + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user + schema: + type: integer + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserConsentList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/user_consent/{id}/: + get: + operationId: core_user_consent_retrieve + description: UserConsent Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Consent. + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserConsent' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: core_user_consent_destroy + description: UserConsent Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Consent. + required: true + tags: + - core + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/user_consent/{id}/used_by/: + get: + operationId: core_user_consent_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Consent. + required: true + tags: + - core + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/: + get: + operationId: core_users_list + description: User Viewset + parameters: + - in: query + name: attributes + schema: + type: string + description: Attributes + - in: query + name: date_joined + schema: + type: string + format: date-time + - in: query + name: date_joined__gt + schema: + type: string + format: date-time + - in: query + name: date_joined__lt + schema: + type: string + format: date-time + - in: query + name: email + schema: + type: string + - in: query + name: groups_by_name + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: groups_by_pk + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: include_groups + schema: + type: boolean + default: true + - in: query + name: include_roles + schema: + type: boolean + default: true + - in: query + name: is_active + schema: + type: boolean + - in: query + name: is_superuser + schema: + type: boolean + - in: query + name: last_login + schema: + type: string + format: date-time + - in: query + name: last_login__gt + schema: + type: string + format: date-time + - in: query + name: last_login__isnull + schema: + type: boolean + - in: query + name: last_login__lt + schema: + type: string + format: date-time + - in: query + name: last_updated + schema: + type: string + format: date-time + - in: query + name: last_updated__gt + schema: + type: string + format: date-time + - in: query + name: last_updated__lt + schema: + type: string + format: date-time + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: path + schema: + type: string + - in: query + name: path_startswith + schema: + type: string + - in: query + name: roles_by_name + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: roles_by_pk + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: type + schema: + type: array + items: + $ref: '#/components/schemas/UserTypeEnum' + explode: true + style: form + - in: query + name: username + schema: + type: string + - in: query + name: uuid + schema: + type: string + format: uuid + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: core_users_create + description: User Viewset + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/User' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/{id}/: + get: + operationId: core_users_retrieve + description: User Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/User' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: core_users_update + description: User Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/User' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: core_users_partial_update + description: User Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserRequest' + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/User' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: core_users_destroy + description: User Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/{id}/impersonate/: + post: + operationId: core_users_impersonate_create + description: Impersonate a user + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ImpersonationRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '204': + description: Successfully started impersonation + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/{id}/recovery/: + post: + operationId: core_users_recovery_create + description: Create a temporary link that a user can use to recover their account + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserRecoveryLinkRequest' + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Link' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/{id}/recovery_email/: + post: + operationId: core_users_recovery_email_create + description: Send an email with a temporary link that a user can use to recover + their account + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserRecoveryEmailRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '204': + description: Successfully sent recover email + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/{id}/set_password/: + post: + operationId: core_users_set_password_create + description: Set password for user + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserPasswordSetRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '204': + description: Successfully changed password + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/{id}/set_password_hash/: + post: + operationId: core_users_set_password_hash_create + description: |- + Set a user's password from a pre-hashed Django password value. + + Submit the Django password hash in the shared ``password`` request field. + + This updates authentik's local password verifier only. It does not attempt + to propagate the password change to LDAP or Kerberos because no raw password + is available from the request payload. + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserPasswordHashSetRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '204': + description: Successfully changed password + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/{id}/used_by/: + get: + operationId: core_users_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User. + required: true + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/account_lockdown/: + post: + operationId: core_users_account_lockdown_create + description: Choose the target account, then return a flow link. + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserAccountLockdownRequest' + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Link' + examples: + LockdownFlowURL: + value: + link: https://example.invalid/if/flow/default-account-lockdown/ + summary: Lockdown flow URL + description: '' + '400': + description: No lockdown flow configured or the flow is not applicable + '403': + description: Permission denied (when targeting another user) + /core/users/export/: + post: + operationId: core_users_export_create + description: |- + Create a data export for this data type. Note that the export is generated asynchronously: + this method returns a `DataExport` object that will initially have `completed=false` as well + as the permanent URL to that object in the `Location` header. + You can poll that URL until `completed=true`, at which point the `file_url` property will + contain a URL to download + parameters: + - in: query + name: attributes + schema: + type: string + description: Attributes + - in: query + name: date_joined + schema: + type: string + format: date-time + - in: query + name: date_joined__gt + schema: + type: string + format: date-time + - in: query + name: date_joined__lt + schema: + type: string + format: date-time + - in: query + name: email + schema: + type: string + - in: query + name: groups_by_name + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: groups_by_pk + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: is_active + schema: + type: boolean + - in: query + name: is_superuser + schema: + type: boolean + - in: query + name: last_login + schema: + type: string + format: date-time + - in: query + name: last_login__gt + schema: + type: string + format: date-time + - in: query + name: last_login__isnull + schema: + type: boolean + - in: query + name: last_login__lt + schema: + type: string + format: date-time + - in: query + name: last_updated + schema: + type: string + format: date-time + - in: query + name: last_updated__gt + schema: + type: string + format: date-time + - in: query + name: last_updated__lt + schema: + type: string + format: date-time + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - in: query + name: path + schema: + type: string + - in: query + name: path_startswith + schema: + type: string + - in: query + name: roles_by_name + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: roles_by_pk + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: type + schema: + type: array + items: + $ref: '#/components/schemas/UserTypeEnum' + explode: true + style: form + - in: query + name: username + schema: + type: string + - in: query + name: uuid + schema: + type: string + format: uuid + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/DataExport' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/impersonate_end/: + get: + operationId: core_users_impersonate_end_retrieve + description: End Impersonation a user + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '204': + description: Successfully ended impersonation + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/me/: + get: + operationId: core_users_me_retrieve + description: Get information about current user + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SessionUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/paths/: + get: + operationId: core_users_paths_retrieve + description: Get all user paths + parameters: + - $ref: '#/components/parameters/QuerySearch' + tags: + - core + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserPath' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /core/users/service_account/: + post: + operationId: core_users_service_account_create + description: Create a new user account that is marked as a service account + tags: + - core + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserServiceAccountRequest' + required: true + security: + - authentik: [] + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserServiceAccountResponse' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /crypto/certificatekeypairs/: + get: + operationId: crypto_certificatekeypairs_list + description: CertificateKeyPair Viewset + parameters: + - in: query + name: has_key + schema: + type: boolean + description: Only return certificate-key pairs with keys + - in: query + name: key_type + schema: + type: array + items: + $ref: '#/components/schemas/KeyTypeEnum' + description: Filter by key algorithm type (RSA, EC, DSA, etc). Can be specified + multiple times (e.g. '?key_type=rsa&key_type=ec') + - in: query + name: managed + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - crypto + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedCertificateKeyPairList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: crypto_certificatekeypairs_create + description: CertificateKeyPair Viewset + tags: + - crypto + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateKeyPairRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateKeyPair' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /crypto/certificatekeypairs/{kp_uuid}/: + get: + operationId: crypto_certificatekeypairs_retrieve + description: CertificateKeyPair Viewset + parameters: + - in: path + name: kp_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Certificate-Key Pair. + required: true + tags: + - crypto + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateKeyPair' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: crypto_certificatekeypairs_update + description: CertificateKeyPair Viewset + parameters: + - in: path + name: kp_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Certificate-Key Pair. + required: true + tags: + - crypto + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateKeyPairRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateKeyPair' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: crypto_certificatekeypairs_partial_update + description: CertificateKeyPair Viewset + parameters: + - in: path + name: kp_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Certificate-Key Pair. + required: true + tags: + - crypto + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedCertificateKeyPairRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateKeyPair' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: crypto_certificatekeypairs_destroy + description: CertificateKeyPair Viewset + parameters: + - in: path + name: kp_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Certificate-Key Pair. + required: true + tags: + - crypto + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /crypto/certificatekeypairs/{kp_uuid}/used_by/: + get: + operationId: crypto_certificatekeypairs_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: kp_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Certificate-Key Pair. + required: true + tags: + - crypto + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /crypto/certificatekeypairs/{kp_uuid}/view_certificate/: + get: + operationId: crypto_certificatekeypairs_view_certificate_retrieve + description: Return certificate-key pairs certificate and log access + parameters: + - in: query + name: download + schema: + type: boolean + - in: path + name: kp_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Certificate-Key Pair. + required: true + tags: + - crypto + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateData' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /crypto/certificatekeypairs/{kp_uuid}/view_private_key/: + get: + operationId: crypto_certificatekeypairs_view_private_key_retrieve + description: Return certificate-key pairs private key and log access + parameters: + - in: query + name: download + schema: + type: boolean + - in: path + name: kp_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Certificate-Key Pair. + required: true + tags: + - crypto + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateData' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /crypto/certificatekeypairs/generate/: + post: + operationId: crypto_certificatekeypairs_generate_create + description: Generate a new, self-signed certificate-key pair + tags: + - crypto + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateGenerationRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateKeyPair' + description: '' + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/connectors/: + get: + operationId: endpoints_agents_connectors_list + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: query + name: enabled + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAgentConnectorList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: endpoints_agents_connectors_create + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AgentConnectorRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AgentConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/connectors/{connector_uuid}/: + get: + operationId: endpoints_agents_connectors_retrieve + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Agent Connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AgentConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: endpoints_agents_connectors_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Agent Connector. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AgentConnectorRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AgentConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: endpoints_agents_connectors_partial_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Agent Connector. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAgentConnectorRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AgentConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: endpoints_agents_connectors_destroy + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Agent Connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/connectors/{connector_uuid}/mdm_config/: + post: + operationId: endpoints_agents_connectors_mdm_config_create + description: Generate configuration for MDM systems to deploy authentik Agent + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Agent Connector. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/MDMConfigRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MDMConfigResponse' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/connectors/{connector_uuid}/used_by/: + get: + operationId: endpoints_agents_connectors_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Agent Connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/connectors/agent_config/: + get: + operationId: endpoints_agents_connectors_agent_config_retrieve + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + tags: + - endpoints + security: + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AgentConfig' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/connectors/auth_fed/: + post: + operationId: endpoints_agents_connectors_auth_fed_create + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: query + name: device + schema: + type: string + required: true + tags: + - endpoints + security: + - authentik_device_federation: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AgentTokenResponse' + description: '' + '404': + description: Device not found + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/connectors/auth_ia/: + post: + operationId: endpoints_agents_connectors_auth_ia_create + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + tags: + - endpoints + security: + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AgentAuthenticationResponse' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/connectors/check_in/: + post: + operationId: endpoints_agents_connectors_check_in_create + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceFactsRequest' + security: + - authentik_device_auth: [] + responses: + '204': + description: Successfully checked in + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/connectors/enroll/: + post: + operationId: endpoints_agents_connectors_enroll_create + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EnrollRequest' + required: true + security: + - authentik_device_enroll: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AgentTokenResponse' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/enrollment_tokens/: + get: + operationId: endpoints_agents_enrollment_tokens_list + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: query + name: connector + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: token_uuid + schema: + type: string + format: uuid + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedEnrollmentTokenList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: endpoints_agents_enrollment_tokens_create + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EnrollmentTokenRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/EnrollmentToken' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/enrollment_tokens/{token_uuid}/: + get: + operationId: endpoints_agents_enrollment_tokens_retrieve + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Enrollment Token. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EnrollmentToken' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: endpoints_agents_enrollment_tokens_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Enrollment Token. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EnrollmentTokenRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EnrollmentToken' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: endpoints_agents_enrollment_tokens_partial_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Enrollment Token. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedEnrollmentTokenRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EnrollmentToken' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: endpoints_agents_enrollment_tokens_destroy + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Enrollment Token. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/enrollment_tokens/{token_uuid}/used_by/: + get: + operationId: endpoints_agents_enrollment_tokens_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Enrollment Token. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/enrollment_tokens/{token_uuid}/view_key/: + get: + operationId: endpoints_agents_enrollment_tokens_view_key_retrieve + description: Return token key and log access + parameters: + - in: path + name: token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Enrollment Token. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TokenView' + description: '' + '404': + description: Token not found or expired + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/psso/ise/: + get: + operationId: endpoints_agents_psso_ise_list + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: query + name: apple_enclave_key_id + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user + schema: + type: integer + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAppleIndependentSecureEnclaveList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: endpoints_agents_psso_ise_create + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AppleIndependentSecureEnclaveRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AppleIndependentSecureEnclave' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/psso/ise/{uuid}/: + get: + operationId: endpoints_agents_psso_ise_retrieve + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Apple Independent Secure Enclave. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AppleIndependentSecureEnclave' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: endpoints_agents_psso_ise_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Apple Independent Secure Enclave. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AppleIndependentSecureEnclaveRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AppleIndependentSecureEnclave' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: endpoints_agents_psso_ise_partial_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Apple Independent Secure Enclave. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAppleIndependentSecureEnclaveRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AppleIndependentSecureEnclave' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: endpoints_agents_psso_ise_destroy + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Apple Independent Secure Enclave. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/psso/ise/{uuid}/used_by/: + get: + operationId: endpoints_agents_psso_ise_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Apple Independent Secure Enclave. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/psso/register/device/: + post: + operationId: endpoints_agents_psso_register_device_create + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AgentPSSODeviceRegistrationRequest' + required: true + security: + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AgentPSSODeviceRegistrationResponse' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/agents/psso/register/user/: + post: + operationId: endpoints_agents_psso_register_user_create + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AgentPSSOUserRegistrationRequest' + required: true + security: + - authentik_device_auth: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserSelf' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/connectors/: + get: + operationId: endpoints_connectors_list + description: Connector Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedConnectorList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/connectors/{connector_uuid}/: + get: + operationId: endpoints_connectors_retrieve + description: Connector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Connector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: endpoints_connectors_destroy + description: Connector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/connectors/{connector_uuid}/used_by/: + get: + operationId: endpoints_connectors_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/connectors/types/: + get: + operationId: endpoints_connectors_types_list + description: Get all creatable types + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/TypeCreate' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/device_access_groups/: + get: + operationId: endpoints_device_access_groups_list + description: DeviceAccessGroup Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDeviceAccessGroupList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: endpoints_device_access_groups_create + description: DeviceAccessGroup Viewset + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceAccessGroupRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceAccessGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/device_access_groups/{pbm_uuid}/: + get: + operationId: endpoints_device_access_groups_retrieve + description: DeviceAccessGroup Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device access group. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceAccessGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: endpoints_device_access_groups_update + description: DeviceAccessGroup Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device access group. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceAccessGroupRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceAccessGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: endpoints_device_access_groups_partial_update + description: DeviceAccessGroup Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device access group. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedDeviceAccessGroupRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceAccessGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: endpoints_device_access_groups_destroy + description: DeviceAccessGroup Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device access group. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/device_access_groups/{pbm_uuid}/used_by/: + get: + operationId: endpoints_device_access_groups_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device access group. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/device_bindings/: + get: + operationId: endpoints_device_bindings_list + description: PolicyBinding Viewset + parameters: + - in: query + name: enabled + schema: + type: boolean + - in: query + name: order + schema: + type: integer + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: policy + schema: + type: string + format: uuid + - in: query + name: policy__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: target + schema: + type: string + format: uuid + - in: query + name: target_in + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: timeout + schema: + type: integer + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDeviceUserBindingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: endpoints_device_bindings_create + description: PolicyBinding Viewset + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceUserBindingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceUserBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/device_bindings/{policy_binding_uuid}/: + get: + operationId: endpoints_device_bindings_retrieve + description: PolicyBinding Viewset + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device User binding. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceUserBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: endpoints_device_bindings_update + description: PolicyBinding Viewset + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device User binding. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceUserBindingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceUserBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: endpoints_device_bindings_partial_update + description: PolicyBinding Viewset + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device User binding. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedDeviceUserBindingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceUserBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: endpoints_device_bindings_destroy + description: PolicyBinding Viewset + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device User binding. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/device_bindings/{policy_binding_uuid}/used_by/: + get: + operationId: endpoints_device_bindings_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device User binding. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/devices/: + get: + operationId: endpoints_devices_list + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: query + name: identifier + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedEndpointDeviceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/devices/{device_uuid}/: + get: + operationId: endpoints_devices_retrieve + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: device_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointDeviceDetails' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: endpoints_devices_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: device_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointDeviceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: endpoints_devices_partial_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: device_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedEndpointDeviceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointDevice' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: endpoints_devices_destroy + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: device_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/devices/{device_uuid}/used_by/: + get: + operationId: endpoints_devices_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: device_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Device. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/devices/summary/: + get: + operationId: endpoints_devices_summary_retrieve + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DeviceSummary' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/fleet/connectors/: + get: + operationId: endpoints_fleet_connectors_list + description: FleetConnector Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedFleetConnectorList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: endpoints_fleet_connectors_create + description: FleetConnector Viewset + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/FleetConnectorRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/FleetConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/fleet/connectors/{connector_uuid}/: + get: + operationId: endpoints_fleet_connectors_retrieve + description: FleetConnector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Fleet Connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FleetConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: endpoints_fleet_connectors_update + description: FleetConnector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Fleet Connector. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/FleetConnectorRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FleetConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: endpoints_fleet_connectors_partial_update + description: FleetConnector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Fleet Connector. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedFleetConnectorRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FleetConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: endpoints_fleet_connectors_destroy + description: FleetConnector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Fleet Connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/fleet/connectors/{connector_uuid}/used_by/: + get: + operationId: endpoints_fleet_connectors_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Fleet Connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/google_chrome/connectors/: + get: + operationId: endpoints_google_chrome_connectors_list + description: GoogleChromeConnector Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGoogleChromeConnectorList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: endpoints_google_chrome_connectors_create + description: GoogleChromeConnector Viewset + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleChromeConnectorRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleChromeConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/google_chrome/connectors/{connector_uuid}/: + get: + operationId: endpoints_google_chrome_connectors_retrieve + description: GoogleChromeConnector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Device Trust Connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleChromeConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: endpoints_google_chrome_connectors_update + description: GoogleChromeConnector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Device Trust Connector. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleChromeConnectorRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleChromeConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: endpoints_google_chrome_connectors_partial_update + description: GoogleChromeConnector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Device Trust Connector. + required: true + tags: + - endpoints + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGoogleChromeConnectorRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleChromeConnector' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: endpoints_google_chrome_connectors_destroy + description: GoogleChromeConnector Viewset + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Device Trust Connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /endpoints/google_chrome/connectors/{connector_uuid}/used_by/: + get: + operationId: endpoints_google_chrome_connectors_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: connector_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Device Trust Connector. + required: true + tags: + - endpoints + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /enterprise/license/: + get: + operationId: enterprise_license_list + description: License Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - enterprise + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedLicenseList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: enterprise_license_create + description: License Viewset + tags: + - enterprise + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LicenseRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/License' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /enterprise/license/{license_uuid}/: + get: + operationId: enterprise_license_retrieve + description: License Viewset + parameters: + - in: path + name: license_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this License. + required: true + tags: + - enterprise + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/License' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: enterprise_license_update + description: License Viewset + parameters: + - in: path + name: license_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this License. + required: true + tags: + - enterprise + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LicenseRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/License' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: enterprise_license_partial_update + description: License Viewset + parameters: + - in: path + name: license_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this License. + required: true + tags: + - enterprise + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedLicenseRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/License' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: enterprise_license_destroy + description: License Viewset + parameters: + - in: path + name: license_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this License. + required: true + tags: + - enterprise + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /enterprise/license/{license_uuid}/used_by/: + get: + operationId: enterprise_license_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: license_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this License. + required: true + tags: + - enterprise + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /enterprise/license/forecast/: + get: + operationId: enterprise_license_forecast_retrieve + description: Forecast how many users will be required in a year + tags: + - enterprise + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LicenseForecast' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /enterprise/license/install_id/: + get: + operationId: enterprise_license_install_id_retrieve + description: Get install_id + tags: + - enterprise + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/InstallID' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /enterprise/license/summary/: + get: + operationId: enterprise_license_summary_retrieve + description: Get the total license status + parameters: + - in: query + name: cached + schema: + type: boolean + default: true + tags: + - enterprise + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LicenseSummary' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/events/: + get: + operationId: events_events_list + description: Event Read-Only Viewset + parameters: + - in: query + name: action + schema: + type: string + - in: query + name: actions + schema: + type: array + items: + $ref: '#/components/schemas/EventActions' + explode: true + style: form + - in: query + name: brand_name + schema: + type: string + description: Brand name + - in: query + name: client_ip + schema: + type: string + - in: query + name: context_authorized_app + schema: + type: string + description: Context Authorized application + - in: query + name: context_device + schema: + type: string + description: Context Device Primary Key + - in: query + name: context_model_app + schema: + type: string + description: Context Model App + - in: query + name: context_model_name + schema: + type: string + description: Context Model Name + - in: query + name: context_model_pk + schema: + type: string + description: Context Model Primary Key + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: username + schema: + type: string + description: Username + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedEventList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: events_events_create + description: Event Read-Only Viewset + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EventRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Event' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/events/{event_uuid}/: + get: + operationId: events_events_retrieve + description: Event Read-Only Viewset + parameters: + - in: path + name: event_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Event. + required: true + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Event' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: events_events_update + description: Event Read-Only Viewset + parameters: + - in: path + name: event_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Event. + required: true + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EventRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Event' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: events_events_partial_update + description: Event Read-Only Viewset + parameters: + - in: path + name: event_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Event. + required: true + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedEventRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Event' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: events_events_destroy + description: Event Read-Only Viewset + parameters: + - in: path + name: event_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Event. + required: true + tags: + - events + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/events/actions/: + get: + operationId: events_events_actions_list + description: Get all actions + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/TypeCreate' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/events/export/: + post: + operationId: events_events_export_create + description: |- + Create a data export for this data type. Note that the export is generated asynchronously: + this method returns a `DataExport` object that will initially have `completed=false` as well + as the permanent URL to that object in the `Location` header. + You can poll that URL until `completed=true`, at which point the `file_url` property will + contain a URL to download + parameters: + - in: query + name: action + schema: + type: string + - in: query + name: actions + schema: + type: array + items: + $ref: '#/components/schemas/EventActions' + explode: true + style: form + - in: query + name: brand_name + schema: + type: string + description: Brand name + - in: query + name: client_ip + schema: + type: string + - in: query + name: context_authorized_app + schema: + type: string + description: Context Authorized application + - in: query + name: context_device + schema: + type: string + description: Context Device Primary Key + - in: query + name: context_model_app + schema: + type: string + description: Context Model App + - in: query + name: context_model_name + schema: + type: string + description: Context Model Name + - in: query + name: context_model_pk + schema: + type: string + description: Context Model Primary Key + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: username + schema: + type: string + description: Username + tags: + - events + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/DataExport' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/events/stats/: + get: + operationId: events_events_stats_retrieve + description: Get event stats for specified filters and count steps + parameters: + - in: query + name: action + schema: + type: string + - in: query + name: actions + schema: + type: array + items: + $ref: '#/components/schemas/EventActions' + explode: true + style: form + - in: query + name: brand_name + schema: + type: string + description: Brand name + - in: query + name: client_ip + schema: + type: string + - in: query + name: context_authorized_app + schema: + type: string + description: Context Authorized application + - in: query + name: context_device + schema: + type: string + description: Context Device Primary Key + - in: query + name: context_model_app + schema: + type: string + description: Context Model App + - in: query + name: context_model_name + schema: + type: string + description: Context Model Name + - in: query + name: context_model_pk + schema: + type: string + description: Context Model Primary Key + - in: query + name: count_steps + schema: + type: array + items: + type: string + minLength: 1 + description: Timedelta, format of 'weeks=3;days=2;hours=3,seconds=2' + required: true + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: username + schema: + type: string + description: Username + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EventStats' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/events/top_per_user/: + get: + operationId: events_events_top_per_user_list + description: Get the top_n events grouped by user count + parameters: + - in: query + name: action + schema: + type: string + - in: query + name: top_n + schema: + type: integer + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/EventTopPerUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/events/volume/: + get: + operationId: events_events_volume_list + description: Get event volume for specified filters and timeframe + parameters: + - in: query + name: action + schema: + type: string + - in: query + name: actions + schema: + type: array + items: + $ref: '#/components/schemas/EventActions' + explode: true + style: form + - in: query + name: brand_name + schema: + type: string + description: Brand name + - in: query + name: client_ip + schema: + type: string + - in: query + name: context_authorized_app + schema: + type: string + description: Context Authorized application + - in: query + name: context_device + schema: + type: string + description: Context Device Primary Key + - in: query + name: context_model_app + schema: + type: string + description: Context Model App + - in: query + name: context_model_name + schema: + type: string + description: Context Model Name + - in: query + name: context_model_pk + schema: + type: string + description: Context Model Primary Key + - in: query + name: history_days + schema: + type: integer + default: 7 + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: username + schema: + type: string + description: Username + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/EventVolume' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/notifications/: + get: + operationId: events_notifications_list + description: Notification Viewset + parameters: + - in: query + name: body + schema: + type: string + - in: query + name: created + schema: + type: string + format: date-time + - in: query + name: event + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: seen + schema: + type: boolean + - in: query + name: severity + schema: + $ref: '#/components/schemas/SeverityEnum' + - in: query + name: user + schema: + type: integer + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedNotificationList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/notifications/{uuid}/: + get: + operationId: events_notifications_retrieve + description: Notification Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification. + required: true + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Notification' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: events_notifications_update + description: Notification Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification. + required: true + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Notification' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: events_notifications_partial_update + description: Notification Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification. + required: true + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedNotificationRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Notification' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: events_notifications_destroy + description: Notification Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification. + required: true + tags: + - events + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/notifications/{uuid}/used_by/: + get: + operationId: events_notifications_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification. + required: true + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/notifications/mark_all_seen/: + post: + operationId: events_notifications_mark_all_seen_create + description: Mark all the user's notifications as seen + tags: + - events + security: + - authentik: [] + responses: + '204': + description: Marked tasks as read successfully. + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/rules/: + get: + operationId: events_rules_list + description: NotificationRule Viewset + parameters: + - in: query + name: destination_group__name + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: severity + schema: + allOf: + - $ref: '#/components/schemas/SeverityEnum' + description: |+ + Controls which severity level the created notifications will have. + + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedNotificationRuleList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: events_rules_create + description: NotificationRule Viewset + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationRuleRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationRule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/rules/{pbm_uuid}/: + get: + operationId: events_rules_retrieve + description: NotificationRule Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Rule. + required: true + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationRule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: events_rules_update + description: NotificationRule Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Rule. + required: true + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationRuleRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationRule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: events_rules_partial_update + description: NotificationRule Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Rule. + required: true + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedNotificationRuleRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationRule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: events_rules_destroy + description: NotificationRule Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Rule. + required: true + tags: + - events + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/rules/{pbm_uuid}/used_by/: + get: + operationId: events_rules_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Rule. + required: true + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/transports/: + get: + operationId: events_transports_list + description: NotificationTransport Viewset + parameters: + - in: query + name: mode + schema: + $ref: '#/components/schemas/TransportModeEnum' + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: send_once + schema: + type: boolean + - in: query + name: webhook_url + schema: + type: string + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedNotificationTransportList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: events_transports_create + description: NotificationTransport Viewset + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationTransportRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationTransport' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/transports/{uuid}/: + get: + operationId: events_transports_retrieve + description: NotificationTransport Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Transport. + required: true + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationTransport' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: events_transports_update + description: NotificationTransport Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Transport. + required: true + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationTransportRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationTransport' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: events_transports_partial_update + description: NotificationTransport Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Transport. + required: true + tags: + - events + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedNotificationTransportRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationTransport' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: events_transports_destroy + description: NotificationTransport Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Transport. + required: true + tags: + - events + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/transports/{uuid}/test/: + post: + operationId: events_transports_test_create + description: |- + Send example notification using selected transport. Requires + Modify permissions. + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Transport. + required: true + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationTransportTest' + description: '' + '500': + description: Failed to test transport + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /events/transports/{uuid}/used_by/: + get: + operationId: events_transports_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Notification Transport. + required: true + tags: + - events + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/bindings/: + get: + operationId: flows_bindings_list + description: FlowStageBinding Viewset + parameters: + - in: query + name: evaluate_on_plan + schema: + type: boolean + - in: query + name: fsb_uuid + schema: + type: string + format: uuid + - in: query + name: invalid_response_action + schema: + allOf: + - $ref: '#/components/schemas/InvalidResponseActionEnum' + description: |+ + Configure how the flow executor should handle an invalid response to a challenge. RETRY returns the error message and a similar challenge to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT restarts the flow while keeping the current context. + + - in: query + name: order + schema: + type: integer + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - in: query + name: policies + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: policy_engine_mode + schema: + $ref: '#/components/schemas/PolicyEngineMode' + - in: query + name: re_evaluate_policies + schema: + type: boolean + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage + schema: + type: string + format: uuid + - in: query + name: target + schema: + type: string + format: uuid + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedFlowStageBindingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: flows_bindings_create + description: FlowStageBinding Viewset + tags: + - flows + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/FlowStageBindingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/FlowStageBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/bindings/{fsb_uuid}/: + get: + operationId: flows_bindings_retrieve + description: FlowStageBinding Viewset + parameters: + - in: path + name: fsb_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Flow Stage Binding. + required: true + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FlowStageBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: flows_bindings_update + description: FlowStageBinding Viewset + parameters: + - in: path + name: fsb_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Flow Stage Binding. + required: true + tags: + - flows + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/FlowStageBindingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FlowStageBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: flows_bindings_partial_update + description: FlowStageBinding Viewset + parameters: + - in: path + name: fsb_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Flow Stage Binding. + required: true + tags: + - flows + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedFlowStageBindingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FlowStageBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: flows_bindings_destroy + description: FlowStageBinding Viewset + parameters: + - in: path + name: fsb_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Flow Stage Binding. + required: true + tags: + - flows + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/bindings/{fsb_uuid}/used_by/: + get: + operationId: flows_bindings_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: fsb_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Flow Stage Binding. + required: true + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/executor/{flow_slug}/: + get: + operationId: flows_executor_get + description: Get the next pending challenge from the currently active flow. + parameters: + - in: path + name: flow_slug + schema: + type: string + required: true + - in: query + name: query + schema: + type: string + description: Querystring as received + required: true + tags: + - flows + security: + - authentik: [] + - {} + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ChallengeTypes' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: flows_executor_solve + description: Solve the previously retrieved challenge and advanced to the next + stage. + parameters: + - in: path + name: flow_slug + schema: + type: string + required: true + - in: query + name: query + schema: + type: string + description: Querystring as received + required: true + tags: + - flows + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/FlowChallengeResponseRequest' + security: + - authentik: [] + - {} + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ChallengeTypes' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/inspector/{flow_slug}/: + get: + operationId: flows_inspector_get + description: Get current flow state and record it + parameters: + - in: path + name: flow_slug + schema: + type: string + required: true + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FlowInspection' + description: '' + '400': + description: No flow plan in session. + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/instances/: + get: + operationId: flows_instances_list + description: Flow Viewset + parameters: + - in: query + name: denied_action + schema: + allOf: + - $ref: '#/components/schemas/DeniedActionEnum' + description: |+ + Configure what should happen when a flow denies access to a user. + + - in: query + name: designation + schema: + allOf: + - $ref: '#/components/schemas/FlowDesignationEnum' + description: |+ + Decides what this Flow is used for. For example, the Authentication flow is redirect to when an un-authenticated user visits authentik. + + - in: query + name: flow_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: slug + schema: + type: string + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedFlowList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: flows_instances_create + description: Flow Viewset + tags: + - flows + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/FlowRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Flow' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/instances/{slug}/: + get: + operationId: flows_instances_retrieve + description: Flow Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Visible in the URL. + required: true + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Flow' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: flows_instances_update + description: Flow Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Visible in the URL. + required: true + tags: + - flows + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/FlowRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Flow' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: flows_instances_partial_update + description: Flow Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Visible in the URL. + required: true + tags: + - flows + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedFlowRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Flow' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: flows_instances_destroy + description: Flow Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Visible in the URL. + required: true + tags: + - flows + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/instances/{slug}/diagram/: + get: + operationId: flows_instances_diagram_retrieve + description: Return diagram for flow with slug `slug`, in the format used by + flowchart.js + parameters: + - in: path + name: slug + schema: + type: string + description: Visible in the URL. + required: true + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/FlowDiagram' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/instances/{slug}/execute/: + get: + operationId: flows_instances_execute_retrieve + description: Execute flow for current user + parameters: + - in: path + name: slug + schema: + type: string + description: Visible in the URL. + required: true + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Link' + description: '' + '400': + description: Flow not applicable + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/instances/{slug}/export/: + get: + operationId: flows_instances_export_retrieve + description: Export flow to .yaml file + parameters: + - in: path + name: slug + schema: + type: string + description: Visible in the URL. + required: true + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: string + format: binary + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/instances/{slug}/used_by/: + get: + operationId: flows_instances_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Visible in the URL. + required: true + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/instances/cache_clear/: + post: + operationId: flows_instances_cache_clear_create + description: Clear flow cache + tags: + - flows + security: + - authentik: [] + responses: + '204': + description: Successfully cleared cache + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /flows/instances/cache_info/: + get: + operationId: flows_instances_cache_info_retrieve + description: Info about cached flows + tags: + - flows + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Cache' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /lifecycle/iterations/: + post: + operationId: lifecycle_iterations_create + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + tags: + - lifecycle + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LifecycleIterationRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/LifecycleIteration' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /lifecycle/iterations/latest/{content_type}/{object_id}/: + get: + operationId: lifecycle_iterations_list_latest + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + parameters: + - in: path + name: content_type + schema: + type: string + pattern: ^[^/]+$ + required: true + - in: path + name: object_id + schema: + type: string + pattern: ^[^/]+$ + required: true + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user_is_reviewer + schema: + type: boolean + tags: + - lifecycle + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/LifecycleIteration' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /lifecycle/iterations/open/: + get: + operationId: lifecycle_iterations_list_open + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user_is_reviewer + schema: + type: boolean + tags: + - lifecycle + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedLifecycleIterationList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /lifecycle/reviews/: + post: + operationId: lifecycle_reviews_create + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + tags: + - lifecycle + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ReviewRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Review' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /lifecycle/rules/: + get: + operationId: lifecycle_rules_list + parameters: + - in: query + name: content_type__model + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - lifecycle + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedLifecycleRuleList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: lifecycle_rules_create + tags: + - lifecycle + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LifecycleRuleRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/LifecycleRule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /lifecycle/rules/{id}/: + get: + operationId: lifecycle_rules_retrieve + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this lifecycle rule. + required: true + tags: + - lifecycle + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LifecycleRule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: lifecycle_rules_update + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this lifecycle rule. + required: true + tags: + - lifecycle + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LifecycleRuleRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LifecycleRule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: lifecycle_rules_partial_update + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this lifecycle rule. + required: true + tags: + - lifecycle + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedLifecycleRuleRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LifecycleRule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: lifecycle_rules_destroy + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this lifecycle rule. + required: true + tags: + - lifecycle + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /managed/blueprints/: + get: + operationId: managed_blueprints_list + description: Blueprint instances + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: path + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + tags: + - managed + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedBlueprintInstanceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: managed_blueprints_create + description: Blueprint instances + tags: + - managed + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/BlueprintInstanceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/BlueprintInstance' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /managed/blueprints/{instance_uuid}/: + get: + operationId: managed_blueprints_retrieve + description: Blueprint instances + parameters: + - in: path + name: instance_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Blueprint Instance. + required: true + tags: + - managed + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/BlueprintInstance' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: managed_blueprints_update + description: Blueprint instances + parameters: + - in: path + name: instance_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Blueprint Instance. + required: true + tags: + - managed + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/BlueprintInstanceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/BlueprintInstance' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: managed_blueprints_partial_update + description: Blueprint instances + parameters: + - in: path + name: instance_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Blueprint Instance. + required: true + tags: + - managed + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedBlueprintInstanceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/BlueprintInstance' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: managed_blueprints_destroy + description: Blueprint instances + parameters: + - in: path + name: instance_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Blueprint Instance. + required: true + tags: + - managed + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /managed/blueprints/{instance_uuid}/apply/: + post: + operationId: managed_blueprints_apply_create + description: Apply a blueprint + parameters: + - in: path + name: instance_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Blueprint Instance. + required: true + tags: + - managed + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/BlueprintInstance' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /managed/blueprints/{instance_uuid}/used_by/: + get: + operationId: managed_blueprints_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: instance_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Blueprint Instance. + required: true + tags: + - managed + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /managed/blueprints/available/: + get: + operationId: managed_blueprints_available_list + description: Get blueprints + tags: + - managed + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/BlueprintFile' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /managed/blueprints/import/: + post: + operationId: managed_blueprints_import_create + description: Import blueprint from .yaml file and apply it once, without creating + an instance + tags: + - managed + requestBody: + content: + multipart/form-data: + schema: + $ref: '#/components/schemas/BlueprintUploadRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/BlueprintImportResult' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /oauth2/access_tokens/: + get: + operationId: oauth2_access_tokens_list + description: AccessToken Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user + schema: + type: integer + tags: + - oauth2 + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedTokenModelList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /oauth2/access_tokens/{id}/: + get: + operationId: oauth2_access_tokens_retrieve + description: AccessToken Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2 Access Token. + required: true + tags: + - oauth2 + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TokenModel' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: oauth2_access_tokens_destroy + description: AccessToken Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2 Access Token. + required: true + tags: + - oauth2 + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /oauth2/access_tokens/{id}/used_by/: + get: + operationId: oauth2_access_tokens_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2 Access Token. + required: true + tags: + - oauth2 + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /oauth2/authorization_codes/: + get: + operationId: oauth2_authorization_codes_list + description: AuthorizationCode Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user + schema: + type: integer + tags: + - oauth2 + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedExpiringBaseGrantModelList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /oauth2/authorization_codes/{id}/: + get: + operationId: oauth2_authorization_codes_retrieve + description: AuthorizationCode Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Authorization Code. + required: true + tags: + - oauth2 + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ExpiringBaseGrantModel' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: oauth2_authorization_codes_destroy + description: AuthorizationCode Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Authorization Code. + required: true + tags: + - oauth2 + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /oauth2/authorization_codes/{id}/used_by/: + get: + operationId: oauth2_authorization_codes_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Authorization Code. + required: true + tags: + - oauth2 + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /oauth2/refresh_tokens/: + get: + operationId: oauth2_refresh_tokens_list + description: RefreshToken Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user + schema: + type: integer + tags: + - oauth2 + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedTokenModelList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /oauth2/refresh_tokens/{id}/: + get: + operationId: oauth2_refresh_tokens_retrieve + description: RefreshToken Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2 Refresh Token. + required: true + tags: + - oauth2 + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TokenModel' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: oauth2_refresh_tokens_destroy + description: RefreshToken Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2 Refresh Token. + required: true + tags: + - oauth2 + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /oauth2/refresh_tokens/{id}/used_by/: + get: + operationId: oauth2_refresh_tokens_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2 Refresh Token. + required: true + tags: + - oauth2 + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/instances/: + get: + operationId: outposts_instances_list + description: Outpost Viewset + parameters: + - in: query + name: managed__icontains + schema: + type: string + - in: query + name: managed__iexact + schema: + type: string + - in: query + name: name__icontains + schema: + type: string + - in: query + name: name__iexact + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: providers__isnull + schema: + type: boolean + - in: query + name: providers_by_pk + schema: + type: array + items: + type: integer + explode: true + style: form + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: service_connection__name__icontains + schema: + type: string + - in: query + name: service_connection__name__iexact + schema: + type: string + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedOutpostList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: outposts_instances_create + description: Outpost Viewset + tags: + - outposts + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/OutpostRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Outpost' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/instances/{uuid}/: + get: + operationId: outposts_instances_retrieve + description: Outpost Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Outpost' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: outposts_instances_update + description: Outpost Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost. + required: true + tags: + - outposts + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/OutpostRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Outpost' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: outposts_instances_partial_update + description: Outpost Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost. + required: true + tags: + - outposts + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedOutpostRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Outpost' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: outposts_instances_destroy + description: Outpost Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/instances/{uuid}/health/: + get: + operationId: outposts_instances_health_list + description: Get outposts current health + parameters: + - in: query + name: managed__icontains + schema: + type: string + - in: query + name: managed__iexact + schema: + type: string + - in: query + name: name__icontains + schema: + type: string + - in: query + name: name__iexact + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - in: query + name: providers__isnull + schema: + type: boolean + - in: query + name: providers_by_pk + schema: + type: array + items: + type: integer + explode: true + style: form + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: service_connection__name__icontains + schema: + type: string + - in: query + name: service_connection__name__iexact + schema: + type: string + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/OutpostHealth' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/instances/{uuid}/used_by/: + get: + operationId: outposts_instances_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/instances/default_settings/: + get: + operationId: outposts_instances_default_settings_retrieve + description: Global default outpost config + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OutpostDefaultConfig' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/ldap/: + get: + operationId: outposts_ldap_list + description: LDAPProvider Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedLDAPOutpostConfigList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/ldap/{id}/check_access/: + get: + operationId: outposts_ldap_access_check + description: Check access to a single application by slug + parameters: + - in: query + name: app_slug + schema: + type: string + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this LDAP Provider. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPCheckAccess' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/proxy/: + get: + operationId: outposts_proxy_list + description: ProxyProvider Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedProxyOutpostConfigList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/radius/: + get: + operationId: outposts_radius_list + description: RadiusProvider Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedRadiusOutpostConfigList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/radius/{id}/check_access/: + get: + operationId: outposts_radius_access_check + description: Check access to a single application by slug + parameters: + - in: query + name: app_slug + schema: + type: string + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Radius Provider. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusCheckAccess' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/all/: + get: + operationId: outposts_service_connections_all_list + description: ServiceConnection Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedServiceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/all/{uuid}/: + get: + operationId: outposts_service_connections_all_retrieve + description: ServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ServiceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: outposts_service_connections_all_destroy + description: ServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/all/{uuid}/state/: + get: + operationId: outposts_service_connections_all_state_retrieve + description: Get the service connection's state + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ServiceConnectionState' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/all/{uuid}/used_by/: + get: + operationId: outposts_service_connections_all_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Outpost Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/all/types/: + get: + operationId: outposts_service_connections_all_types_list + description: Get all creatable types + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/TypeCreate' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/docker/: + get: + operationId: outposts_service_connections_docker_list + description: DockerServiceConnection Viewset + parameters: + - in: query + name: local + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: tls_authentication + schema: + type: string + format: uuid + - in: query + name: tls_verification + schema: + type: string + format: uuid + - in: query + name: url + schema: + type: string + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDockerServiceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: outposts_service_connections_docker_create + description: DockerServiceConnection Viewset + tags: + - outposts + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DockerServiceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/DockerServiceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/docker/{uuid}/: + get: + operationId: outposts_service_connections_docker_retrieve + description: DockerServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Docker Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DockerServiceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: outposts_service_connections_docker_update + description: DockerServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Docker Service-Connection. + required: true + tags: + - outposts + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DockerServiceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DockerServiceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: outposts_service_connections_docker_partial_update + description: DockerServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Docker Service-Connection. + required: true + tags: + - outposts + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedDockerServiceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DockerServiceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: outposts_service_connections_docker_destroy + description: DockerServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Docker Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/docker/{uuid}/used_by/: + get: + operationId: outposts_service_connections_docker_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Docker Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/kubernetes/: + get: + operationId: outposts_service_connections_kubernetes_list + description: KubernetesServiceConnection Viewset + parameters: + - in: query + name: local + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedKubernetesServiceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: outposts_service_connections_kubernetes_create + description: KubernetesServiceConnection Viewset + tags: + - outposts + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/KubernetesServiceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/KubernetesServiceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/kubernetes/{uuid}/: + get: + operationId: outposts_service_connections_kubernetes_retrieve + description: KubernetesServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kubernetes Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/KubernetesServiceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: outposts_service_connections_kubernetes_update + description: KubernetesServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kubernetes Service-Connection. + required: true + tags: + - outposts + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/KubernetesServiceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/KubernetesServiceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: outposts_service_connections_kubernetes_partial_update + description: KubernetesServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kubernetes Service-Connection. + required: true + tags: + - outposts + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedKubernetesServiceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/KubernetesServiceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: outposts_service_connections_kubernetes_destroy + description: KubernetesServiceConnection Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kubernetes Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /outposts/service_connections/kubernetes/{uuid}/used_by/: + get: + operationId: outposts_service_connections_kubernetes_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kubernetes Service-Connection. + required: true + tags: + - outposts + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/all/: + get: + operationId: policies_all_list + description: Policy Viewset + parameters: + - in: query + name: bindings__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: promptstage__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QuerySearch' + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPolicyList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/all/{policy_uuid}/: + get: + operationId: policies_all_retrieve + description: Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Policy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_all_destroy + description: Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/all/{policy_uuid}/test/: + post: + operationId: policies_all_test_create + description: Test policy + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PolicyTestRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PolicyTestResult' + description: '' + '400': + description: Invalid parameters + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/all/{policy_uuid}/used_by/: + get: + operationId: policies_all_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/all/cache_clear/: + post: + operationId: policies_all_cache_clear_create + description: Clear policy cache + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: Successfully cleared cache + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/all/cache_info/: + get: + operationId: policies_all_cache_info_retrieve + description: Info about cached policies + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Cache' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/all/types/: + get: + operationId: policies_all_types_list + description: Get all creatable types + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/TypeCreate' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/bindings/: + get: + operationId: policies_bindings_list + description: PolicyBinding Viewset + parameters: + - in: query + name: enabled + schema: + type: boolean + - in: query + name: order + schema: + type: integer + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: policy + schema: + type: string + format: uuid + - in: query + name: policy__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: target + schema: + type: string + format: uuid + - in: query + name: target_in + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: timeout + schema: + type: integer + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPolicyBindingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: policies_bindings_create + description: PolicyBinding Viewset + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PolicyBindingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/PolicyBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/bindings/{policy_binding_uuid}/: + get: + operationId: policies_bindings_retrieve + description: PolicyBinding Viewset + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Policy Binding. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PolicyBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: policies_bindings_update + description: PolicyBinding Viewset + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Policy Binding. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PolicyBindingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PolicyBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: policies_bindings_partial_update + description: PolicyBinding Viewset + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Policy Binding. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedPolicyBindingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PolicyBinding' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_bindings_destroy + description: PolicyBinding Viewset + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Policy Binding. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/bindings/{policy_binding_uuid}/used_by/: + get: + operationId: policies_bindings_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_binding_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Policy Binding. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/dummy/: + get: + operationId: policies_dummy_list + description: Dummy Viewset + parameters: + - in: query + name: created + schema: + type: string + format: date-time + - in: query + name: execution_logging + schema: + type: boolean + - in: query + name: last_updated + schema: + type: string + format: date-time + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: policy_uuid + schema: + type: string + format: uuid + - in: query + name: result + schema: + type: boolean + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: wait_max + schema: + type: integer + - in: query + name: wait_min + schema: + type: integer + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDummyPolicyList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: policies_dummy_create + description: Dummy Viewset + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DummyPolicyRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/DummyPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/dummy/{policy_uuid}/: + get: + operationId: policies_dummy_retrieve + description: Dummy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DummyPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: policies_dummy_update + description: Dummy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DummyPolicyRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DummyPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: policies_dummy_partial_update + description: Dummy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedDummyPolicyRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DummyPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_dummy_destroy + description: Dummy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/dummy/{policy_uuid}/used_by/: + get: + operationId: policies_dummy_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/event_matcher/: + get: + operationId: policies_event_matcher_list + description: Event Matcher Policy Viewset + parameters: + - in: query + name: action + schema: + allOf: + - $ref: '#/components/schemas/EventActions' + nullable: true + description: |+ + Match created events with this action type. When left empty, all action types will be matched. + + - in: query + name: app + schema: + type: string + - in: query + name: client_ip + schema: + type: string + - in: query + name: created + schema: + type: string + format: date-time + - in: query + name: execution_logging + schema: + type: boolean + - in: query + name: last_updated + schema: + type: string + format: date-time + - in: query + name: model + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: policy_uuid + schema: + type: string + format: uuid + - in: query + name: query + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedEventMatcherPolicyList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: policies_event_matcher_create + description: Event Matcher Policy Viewset + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EventMatcherPolicyRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/EventMatcherPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/event_matcher/{policy_uuid}/: + get: + operationId: policies_event_matcher_retrieve + description: Event Matcher Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Event Matcher Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EventMatcherPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: policies_event_matcher_update + description: Event Matcher Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Event Matcher Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EventMatcherPolicyRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EventMatcherPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: policies_event_matcher_partial_update + description: Event Matcher Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Event Matcher Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedEventMatcherPolicyRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EventMatcherPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_event_matcher_destroy + description: Event Matcher Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Event Matcher Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/event_matcher/{policy_uuid}/used_by/: + get: + operationId: policies_event_matcher_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Event Matcher Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/expression/: + get: + operationId: policies_expression_list + description: Source Viewset + parameters: + - in: query + name: created + schema: + type: string + format: date-time + - in: query + name: execution_logging + schema: + type: boolean + - in: query + name: expression + schema: + type: string + - in: query + name: last_updated + schema: + type: string + format: date-time + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: policy_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedExpressionPolicyList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: policies_expression_create + description: Source Viewset + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ExpressionPolicyRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/ExpressionPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/expression/{policy_uuid}/: + get: + operationId: policies_expression_retrieve + description: Source Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Expression Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ExpressionPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: policies_expression_update + description: Source Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Expression Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ExpressionPolicyRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ExpressionPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: policies_expression_partial_update + description: Source Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Expression Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedExpressionPolicyRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ExpressionPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_expression_destroy + description: Source Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Expression Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/expression/{policy_uuid}/used_by/: + get: + operationId: policies_expression_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Expression Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/geoip/: + get: + operationId: policies_geoip_list + description: GeoIP Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGeoIPPolicyList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: policies_geoip_create + description: GeoIP Viewset + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GeoIPPolicyRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GeoIPPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/geoip/{policy_uuid}/: + get: + operationId: policies_geoip_retrieve + description: GeoIP Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this GeoIP Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GeoIPPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: policies_geoip_update + description: GeoIP Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this GeoIP Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GeoIPPolicyRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GeoIPPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: policies_geoip_partial_update + description: GeoIP Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this GeoIP Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGeoIPPolicyRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GeoIPPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_geoip_destroy + description: GeoIP Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this GeoIP Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/geoip/{policy_uuid}/used_by/: + get: + operationId: policies_geoip_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this GeoIP Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/geoip_iso3166/: + get: + operationId: policies_geoip_iso3166_list + description: Get all countries in ISO-3166-1 + tags: + - policies + security: + - authentik: [] + - {} + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/DetailedCountry' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/password/: + get: + operationId: policies_password_list + description: Password Policy Viewset + parameters: + - in: query + name: amount_digits + schema: + type: integer + - in: query + name: amount_lowercase + schema: + type: integer + - in: query + name: amount_symbols + schema: + type: integer + - in: query + name: amount_uppercase + schema: + type: integer + - in: query + name: check_have_i_been_pwned + schema: + type: boolean + - in: query + name: check_static_rules + schema: + type: boolean + - in: query + name: check_zxcvbn + schema: + type: boolean + - in: query + name: created + schema: + type: string + format: date-time + - in: query + name: error_message + schema: + type: string + - in: query + name: execution_logging + schema: + type: boolean + - in: query + name: hibp_allowed_count + schema: + type: integer + - in: query + name: last_updated + schema: + type: string + format: date-time + - in: query + name: length_min + schema: + type: integer + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: password_field + schema: + type: string + - in: query + name: policy_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: symbol_charset + schema: + type: string + - in: query + name: zxcvbn_score_threshold + schema: + type: integer + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPasswordPolicyList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: policies_password_create + description: Password Policy Viewset + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordPolicyRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/password/{policy_uuid}/: + get: + operationId: policies_password_retrieve + description: Password Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: policies_password_update + description: Password Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordPolicyRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: policies_password_partial_update + description: Password Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedPasswordPolicyRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_password_destroy + description: Password Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/password/{policy_uuid}/used_by/: + get: + operationId: policies_password_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/password_expiry/: + get: + operationId: policies_password_expiry_list + description: Password Expiry Viewset + parameters: + - in: query + name: created + schema: + type: string + format: date-time + - in: query + name: days + schema: + type: integer + - in: query + name: deny_only + schema: + type: boolean + - in: query + name: execution_logging + schema: + type: boolean + - in: query + name: last_updated + schema: + type: string + format: date-time + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: policy_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPasswordExpiryPolicyList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: policies_password_expiry_create + description: Password Expiry Viewset + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordExpiryPolicyRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordExpiryPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/password_expiry/{policy_uuid}/: + get: + operationId: policies_password_expiry_retrieve + description: Password Expiry Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Expiry Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordExpiryPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: policies_password_expiry_update + description: Password Expiry Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Expiry Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordExpiryPolicyRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordExpiryPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: policies_password_expiry_partial_update + description: Password Expiry Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Expiry Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedPasswordExpiryPolicyRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordExpiryPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_password_expiry_destroy + description: Password Expiry Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Expiry Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/password_expiry/{policy_uuid}/used_by/: + get: + operationId: policies_password_expiry_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Expiry Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/reputation/: + get: + operationId: policies_reputation_list + description: Reputation Policy Viewset + parameters: + - in: query + name: check_ip + schema: + type: boolean + - in: query + name: check_username + schema: + type: boolean + - in: query + name: created + schema: + type: string + format: date-time + - in: query + name: execution_logging + schema: + type: boolean + - in: query + name: last_updated + schema: + type: string + format: date-time + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: policy_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: threshold + schema: + type: integer + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedReputationPolicyList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: policies_reputation_create + description: Reputation Policy Viewset + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ReputationPolicyRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/ReputationPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/reputation/{policy_uuid}/: + get: + operationId: policies_reputation_retrieve + description: Reputation Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Reputation Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ReputationPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: policies_reputation_update + description: Reputation Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Reputation Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ReputationPolicyRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ReputationPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: policies_reputation_partial_update + description: Reputation Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Reputation Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedReputationPolicyRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ReputationPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_reputation_destroy + description: Reputation Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Reputation Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/reputation/{policy_uuid}/used_by/: + get: + operationId: policies_reputation_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Reputation Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/reputation/scores/: + get: + operationId: policies_reputation_scores_list + description: Reputation Viewset + parameters: + - in: query + name: identifier + schema: + type: string + - in: query + name: identifier_in + schema: + type: array + items: + type: string + description: Multiple values may be separated by commas. + explode: false + style: form + - in: query + name: ip + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: score + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedReputationList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/reputation/scores/{reputation_uuid}/: + get: + operationId: policies_reputation_scores_retrieve + description: Reputation Viewset + parameters: + - in: path + name: reputation_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Reputation Score. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Reputation' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_reputation_scores_destroy + description: Reputation Viewset + parameters: + - in: path + name: reputation_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Reputation Score. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/reputation/scores/{reputation_uuid}/used_by/: + get: + operationId: policies_reputation_scores_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: reputation_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Reputation Score. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/unique_password/: + get: + operationId: policies_unique_password_list + description: Password Uniqueness Policy Viewset + parameters: + - in: query + name: created + schema: + type: string + format: date-time + - in: query + name: execution_logging + schema: + type: boolean + - in: query + name: last_updated + schema: + type: string + format: date-time + - $ref: '#/components/parameters/QueryName' + - in: query + name: num_historical_passwords + schema: + type: integer + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: password_field + schema: + type: string + - in: query + name: policy_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUniquePasswordPolicyList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: policies_unique_password_create + description: Password Uniqueness Policy Viewset + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UniquePasswordPolicyRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UniquePasswordPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/unique_password/{policy_uuid}/: + get: + operationId: policies_unique_password_retrieve + description: Password Uniqueness Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Uniqueness Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UniquePasswordPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: policies_unique_password_update + description: Password Uniqueness Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Uniqueness Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UniquePasswordPolicyRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UniquePasswordPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: policies_unique_password_partial_update + description: Password Uniqueness Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Uniqueness Policy. + required: true + tags: + - policies + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUniquePasswordPolicyRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UniquePasswordPolicy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: policies_unique_password_destroy + description: Password Uniqueness Policy Viewset + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Uniqueness Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /policies/unique_password/{policy_uuid}/used_by/: + get: + operationId: policies_unique_password_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: policy_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Uniqueness Policy. + required: true + tags: + - policies + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/all/: + get: + operationId: propertymappings_all_list + description: PropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/all/{pm_uuid}/: + get: + operationId: propertymappings_all_retrieve + description: PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_all_destroy + description: PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/all/{pm_uuid}/test/: + post: + operationId: propertymappings_all_test_create + description: Test Property Mapping + parameters: + - in: query + name: format_result + schema: + type: boolean + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PropertyMappingTestRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PropertyMappingTestResult' + description: '' + '400': + description: Invalid parameters + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/all/{pm_uuid}/used_by/: + get: + operationId: propertymappings_all_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/all/types/: + get: + operationId: propertymappings_all_types_list + description: Get all creatable types + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/TypeCreate' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/notification/: + get: + operationId: propertymappings_notification_list + description: NotificationWebhookMapping Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedNotificationWebhookMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_notification_create + description: NotificationWebhookMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationWebhookMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationWebhookMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/notification/{pm_uuid}/: + get: + operationId: propertymappings_notification_retrieve + description: NotificationWebhookMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Webhook Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationWebhookMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_notification_update + description: NotificationWebhookMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Webhook Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationWebhookMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationWebhookMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_notification_partial_update + description: NotificationWebhookMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Webhook Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedNotificationWebhookMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/NotificationWebhookMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_notification_destroy + description: NotificationWebhookMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Webhook Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/notification/{pm_uuid}/used_by/: + get: + operationId: propertymappings_notification_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Webhook Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/google_workspace/: + get: + operationId: propertymappings_provider_google_workspace_list + description: GoogleWorkspaceProviderMapping Viewset + parameters: + - in: query + name: expression + schema: + type: string + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pm_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGoogleWorkspaceProviderMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_provider_google_workspace_create + description: GoogleWorkspaceProviderMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/google_workspace/{pm_uuid}/: + get: + operationId: propertymappings_provider_google_workspace_retrieve + description: GoogleWorkspaceProviderMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_provider_google_workspace_update + description: GoogleWorkspaceProviderMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_provider_google_workspace_partial_update + description: GoogleWorkspaceProviderMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGoogleWorkspaceProviderMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_provider_google_workspace_destroy + description: GoogleWorkspaceProviderMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/google_workspace/{pm_uuid}/used_by/: + get: + operationId: propertymappings_provider_google_workspace_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/microsoft_entra/: + get: + operationId: propertymappings_provider_microsoft_entra_list + description: MicrosoftEntraProviderMapping Viewset + parameters: + - in: query + name: expression + schema: + type: string + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pm_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedMicrosoftEntraProviderMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_provider_microsoft_entra_create + description: MicrosoftEntraProviderMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/microsoft_entra/{pm_uuid}/: + get: + operationId: propertymappings_provider_microsoft_entra_retrieve + description: MicrosoftEntraProviderMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_provider_microsoft_entra_update + description: MicrosoftEntraProviderMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_provider_microsoft_entra_partial_update + description: MicrosoftEntraProviderMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedMicrosoftEntraProviderMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_provider_microsoft_entra_destroy + description: MicrosoftEntraProviderMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/microsoft_entra/{pm_uuid}/used_by/: + get: + operationId: propertymappings_provider_microsoft_entra_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/rac/: + get: + operationId: propertymappings_provider_rac_list + description: RACPropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedRACPropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_provider_rac_create + description: RACPropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RACPropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/RACPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/rac/{pm_uuid}/: + get: + operationId: propertymappings_provider_rac_retrieve + description: RACPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Provider Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RACPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_provider_rac_update + description: RACPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Provider Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RACPropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RACPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_provider_rac_partial_update + description: RACPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Provider Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedRACPropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RACPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_provider_rac_destroy + description: RACPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Provider Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/rac/{pm_uuid}/used_by/: + get: + operationId: propertymappings_provider_rac_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Provider Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/radius/: + get: + operationId: propertymappings_provider_radius_list + description: RadiusProviderPropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedRadiusProviderPropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_provider_radius_create + description: RadiusProviderPropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProviderPropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProviderPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/radius/{pm_uuid}/: + get: + operationId: propertymappings_provider_radius_retrieve + description: RadiusProviderPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Radius Provider Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProviderPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_provider_radius_update + description: RadiusProviderPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Radius Provider Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProviderPropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProviderPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_provider_radius_partial_update + description: RadiusProviderPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Radius Provider Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedRadiusProviderPropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProviderPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_provider_radius_destroy + description: RadiusProviderPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Radius Provider Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/radius/{pm_uuid}/used_by/: + get: + operationId: propertymappings_provider_radius_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Radius Provider Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/saml/: + get: + operationId: propertymappings_provider_saml_list + description: SAMLPropertyMapping Viewset + parameters: + - in: query + name: friendly_name + schema: + type: string + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: saml_name + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSAMLPropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_provider_saml_create + description: SAMLPropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLPropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/saml/{pm_uuid}/: + get: + operationId: propertymappings_provider_saml_retrieve + description: SAMLPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Provider Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_provider_saml_update + description: SAMLPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Provider Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLPropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_provider_saml_partial_update + description: SAMLPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Provider Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSAMLPropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLPropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_provider_saml_destroy + description: SAMLPropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Provider Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/saml/{pm_uuid}/used_by/: + get: + operationId: propertymappings_provider_saml_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Provider Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/scim/: + get: + operationId: propertymappings_provider_scim_list + description: SCIMMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSCIMMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_provider_scim_create + description: SCIMMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/scim/{pm_uuid}/: + get: + operationId: propertymappings_provider_scim_retrieve + description: SCIMMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Provider Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_provider_scim_update + description: SCIMMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Provider Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_provider_scim_partial_update + description: SCIMMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Provider Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSCIMMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_provider_scim_destroy + description: SCIMMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Provider Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/scim/{pm_uuid}/used_by/: + get: + operationId: propertymappings_provider_scim_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Provider Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/scope/: + get: + operationId: propertymappings_provider_scope_list + description: ScopeMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: scope_name + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedScopeMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_provider_scope_create + description: ScopeMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ScopeMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/ScopeMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/scope/{pm_uuid}/: + get: + operationId: propertymappings_provider_scope_retrieve + description: ScopeMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Scope Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ScopeMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_provider_scope_update + description: ScopeMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Scope Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ScopeMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ScopeMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_provider_scope_partial_update + description: ScopeMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Scope Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedScopeMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ScopeMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_provider_scope_destroy + description: ScopeMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Scope Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/provider/scope/{pm_uuid}/used_by/: + get: + operationId: propertymappings_provider_scope_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Scope Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/kerberos/: + get: + operationId: propertymappings_source_kerberos_list + description: KerberosSource PropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedKerberosSourcePropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_source_kerberos_create + description: KerberosSource PropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/kerberos/{pm_uuid}/: + get: + operationId: propertymappings_source_kerberos_retrieve + description: KerberosSource PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kerberos Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_source_kerberos_update + description: KerberosSource PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kerberos Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_source_kerberos_partial_update + description: KerberosSource PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kerberos Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedKerberosSourcePropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_source_kerberos_destroy + description: KerberosSource PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kerberos Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/kerberos/{pm_uuid}/used_by/: + get: + operationId: propertymappings_source_kerberos_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Kerberos Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/ldap/: + get: + operationId: propertymappings_source_ldap_list + description: LDAP PropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedLDAPSourcePropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_source_ldap_create + description: LDAP PropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/ldap/{pm_uuid}/: + get: + operationId: propertymappings_source_ldap_retrieve + description: LDAP PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this LDAP Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_source_ldap_update + description: LDAP PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this LDAP Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_source_ldap_partial_update + description: LDAP PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this LDAP Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedLDAPSourcePropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_source_ldap_destroy + description: LDAP PropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this LDAP Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/ldap/{pm_uuid}/used_by/: + get: + operationId: propertymappings_source_ldap_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this LDAP Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/oauth/: + get: + operationId: propertymappings_source_oauth_list + description: OAuthSourcePropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedOAuthSourcePropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_source_oauth_create + description: OAuthSourcePropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/oauth/{pm_uuid}/: + get: + operationId: propertymappings_source_oauth_retrieve + description: OAuthSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this OAuth Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_source_oauth_update + description: OAuthSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this OAuth Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_source_oauth_partial_update + description: OAuthSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this OAuth Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedOAuthSourcePropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_source_oauth_destroy + description: OAuthSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this OAuth Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/oauth/{pm_uuid}/used_by/: + get: + operationId: propertymappings_source_oauth_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this OAuth Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/plex/: + get: + operationId: propertymappings_source_plex_list + description: PlexSourcePropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPlexSourcePropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_source_plex_create + description: PlexSourcePropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/plex/{pm_uuid}/: + get: + operationId: propertymappings_source_plex_retrieve + description: PlexSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Plex Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_source_plex_update + description: PlexSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Plex Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_source_plex_partial_update + description: PlexSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Plex Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedPlexSourcePropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_source_plex_destroy + description: PlexSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Plex Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/plex/{pm_uuid}/used_by/: + get: + operationId: propertymappings_source_plex_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Plex Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/saml/: + get: + operationId: propertymappings_source_saml_list + description: SAMLSourcePropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSAMLSourcePropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_source_saml_create + description: SAMLSourcePropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/saml/{pm_uuid}/: + get: + operationId: propertymappings_source_saml_retrieve + description: SAMLSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_source_saml_update + description: SAMLSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_source_saml_partial_update + description: SAMLSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSAMLSourcePropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_source_saml_destroy + description: SAMLSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/saml/{pm_uuid}/used_by/: + get: + operationId: propertymappings_source_saml_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SAML Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/scim/: + get: + operationId: propertymappings_source_scim_list + description: SCIMSourcePropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSCIMSourcePropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_source_scim_create + description: SCIMSourcePropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/scim/{pm_uuid}/: + get: + operationId: propertymappings_source_scim_retrieve + description: SCIMSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_source_scim_update + description: SCIMSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_source_scim_partial_update + description: SCIMSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSCIMSourcePropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_source_scim_destroy + description: SCIMSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/scim/{pm_uuid}/used_by/: + get: + operationId: propertymappings_source_scim_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SCIM Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/telegram/: + get: + operationId: propertymappings_source_telegram_list + description: TelegramSourcePropertyMapping Viewset + parameters: + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedTelegramSourcePropertyMappingList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: propertymappings_source_telegram_create + description: TelegramSourcePropertyMapping Viewset + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/telegram/{pm_uuid}/: + get: + operationId: propertymappings_source_telegram_retrieve + description: TelegramSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Telegram Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: propertymappings_source_telegram_update + description: TelegramSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Telegram Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSourcePropertyMappingRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: propertymappings_source_telegram_partial_update + description: TelegramSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Telegram Source Property Mapping. + required: true + tags: + - propertymappings + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedTelegramSourcePropertyMappingRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSourcePropertyMapping' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: propertymappings_source_telegram_destroy + description: TelegramSourcePropertyMapping Viewset + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Telegram Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /propertymappings/source/telegram/{pm_uuid}/used_by/: + get: + operationId: propertymappings_source_telegram_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Telegram Source Property Mapping. + required: true + tags: + - propertymappings + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/all/: + get: + operationId: providers_all_list + description: Provider Viewset + parameters: + - in: query + name: application__isnull + schema: + type: boolean + - in: query + name: backchannel + schema: + type: boolean + description: When not set all providers are returned. When set to true, only + backchannel providers are returned. When set to false, backchannel providers + are excluded + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/all/{id}/: + get: + operationId: providers_all_retrieve + description: Provider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Provider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_all_destroy + description: Provider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/all/{id}/used_by/: + get: + operationId: providers_all_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/all/types/: + get: + operationId: providers_all_types_list + description: Get all creatable types + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/TypeCreate' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace/: + get: + operationId: providers_google_workspace_list + description: GoogleWorkspaceProvider Viewset + parameters: + - in: query + name: delegated_subject + schema: + type: string + - in: query + name: exclude_users_service_account + schema: + type: boolean + - in: query + name: filter_group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGoogleWorkspaceProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_google_workspace_create + description: GoogleWorkspaceProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace/{id}/: + get: + operationId: providers_google_workspace_retrieve + description: GoogleWorkspaceProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Google Workspace Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_google_workspace_update + description: GoogleWorkspaceProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Google Workspace Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_google_workspace_partial_update + description: GoogleWorkspaceProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Google Workspace Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGoogleWorkspaceProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_google_workspace_destroy + description: GoogleWorkspaceProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Google Workspace Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace/{id}/sync/object/: + post: + operationId: providers_google_workspace_sync_object_create + description: Sync/Re-sync a single user/group object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Google Workspace Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SyncObjectRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SyncObjectResult' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace/{id}/sync/status/: + get: + operationId: providers_google_workspace_sync_status_retrieve + description: Get provider's sync status + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Google Workspace Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SyncStatus' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace/{id}/used_by/: + get: + operationId: providers_google_workspace_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Google Workspace Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace_groups/: + get: + operationId: providers_google_workspace_groups_list + description: GoogleWorkspaceProviderGroup Viewset + parameters: + - in: query + name: group__group_uuid + schema: + type: string + format: uuid + - in: query + name: group__name + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider__id + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGoogleWorkspaceProviderGroupList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_google_workspace_groups_create + description: GoogleWorkspaceProviderGroup Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderGroupRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace_groups/{id}/: + get: + operationId: providers_google_workspace_groups_retrieve + description: GoogleWorkspaceProviderGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider Group. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_google_workspace_groups_destroy + description: GoogleWorkspaceProviderGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider Group. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace_groups/{id}/used_by/: + get: + operationId: providers_google_workspace_groups_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider Group. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace_users/: + get: + operationId: providers_google_workspace_users_list + description: GoogleWorkspaceProviderUser Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider__id + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user__id + schema: + type: integer + - in: query + name: user__username + schema: + type: string + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGoogleWorkspaceProviderUserList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_google_workspace_users_create + description: GoogleWorkspaceProviderUser Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderUserRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace_users/{id}/: + get: + operationId: providers_google_workspace_users_retrieve + description: GoogleWorkspaceProviderUser Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider User. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GoogleWorkspaceProviderUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_google_workspace_users_destroy + description: GoogleWorkspaceProviderUser Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider User. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/google_workspace_users/{id}/used_by/: + get: + operationId: providers_google_workspace_users_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Google Workspace Provider User. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/ldap/: + get: + operationId: providers_ldap_list + description: LDAPProvider Viewset + parameters: + - in: query + name: application__isnull + schema: + type: boolean + - in: query + name: authorization_flow__slug__iexact + schema: + type: string + - in: query + name: base_dn__iexact + schema: + type: string + - in: query + name: certificate__kp_uuid__iexact + schema: + type: string + format: uuid + - in: query + name: certificate__name__iexact + schema: + type: string + - in: query + name: gid_start_number__iexact + schema: + type: integer + - in: query + name: name__iexact + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: tls_server_name__iexact + schema: + type: string + - in: query + name: uid_start_number__iexact + schema: + type: integer + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedLDAPProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_ldap_create + description: LDAPProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/ldap/{id}/: + get: + operationId: providers_ldap_retrieve + description: LDAPProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this LDAP Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_ldap_update + description: LDAPProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this LDAP Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_ldap_partial_update + description: LDAPProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this LDAP Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedLDAPProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_ldap_destroy + description: LDAPProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this LDAP Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/ldap/{id}/used_by/: + get: + operationId: providers_ldap_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this LDAP Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra/: + get: + operationId: providers_microsoft_entra_list + description: MicrosoftEntraProvider Viewset + parameters: + - in: query + name: exclude_users_service_account + schema: + type: boolean + - in: query + name: filter_group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedMicrosoftEntraProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_microsoft_entra_create + description: MicrosoftEntraProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra/{id}/: + get: + operationId: providers_microsoft_entra_retrieve + description: MicrosoftEntraProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Microsoft Entra Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_microsoft_entra_update + description: MicrosoftEntraProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Microsoft Entra Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_microsoft_entra_partial_update + description: MicrosoftEntraProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Microsoft Entra Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedMicrosoftEntraProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_microsoft_entra_destroy + description: MicrosoftEntraProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Microsoft Entra Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra/{id}/sync/object/: + post: + operationId: providers_microsoft_entra_sync_object_create + description: Sync/Re-sync a single user/group object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Microsoft Entra Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SyncObjectRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SyncObjectResult' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra/{id}/sync/status/: + get: + operationId: providers_microsoft_entra_sync_status_retrieve + description: Get provider's sync status + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Microsoft Entra Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SyncStatus' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra/{id}/used_by/: + get: + operationId: providers_microsoft_entra_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Microsoft Entra Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra_groups/: + get: + operationId: providers_microsoft_entra_groups_list + description: MicrosoftEntraProviderGroup Viewset + parameters: + - in: query + name: group__group_uuid + schema: + type: string + format: uuid + - in: query + name: group__name + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider__id + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedMicrosoftEntraProviderGroupList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_microsoft_entra_groups_create + description: MicrosoftEntraProviderGroup Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderGroupRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra_groups/{id}/: + get: + operationId: providers_microsoft_entra_groups_retrieve + description: MicrosoftEntraProviderGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider Group. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_microsoft_entra_groups_destroy + description: MicrosoftEntraProviderGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider Group. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra_groups/{id}/used_by/: + get: + operationId: providers_microsoft_entra_groups_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider Group. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra_users/: + get: + operationId: providers_microsoft_entra_users_list + description: MicrosoftEntraProviderUser Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider__id + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user__id + schema: + type: integer + - in: query + name: user__username + schema: + type: string + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedMicrosoftEntraProviderUserList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_microsoft_entra_users_create + description: MicrosoftEntraProviderUser Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderUserRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra_users/{id}/: + get: + operationId: providers_microsoft_entra_users_retrieve + description: MicrosoftEntraProviderUser Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider User. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MicrosoftEntraProviderUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_microsoft_entra_users_destroy + description: MicrosoftEntraProviderUser Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider User. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/microsoft_entra_users/{id}/used_by/: + get: + operationId: providers_microsoft_entra_users_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Microsoft Entra Provider User. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/oauth2/: + get: + operationId: providers_oauth2_list + description: OAuth2Provider Viewset + parameters: + - in: query + name: access_code_validity + schema: + type: string + - in: query + name: access_token_validity + schema: + type: string + - in: query + name: application + schema: + type: string + format: uuid + - in: query + name: authorization_flow + schema: + type: string + format: uuid + - in: query + name: client_id + schema: + type: string + - in: query + name: client_type + schema: + allOf: + - $ref: '#/components/schemas/ClientTypeEnum' + description: |+ + Confidential clients are capable of maintaining the confidentiality of their credentials. Public clients are incapable + + - in: query + name: include_claims_in_id_token + schema: + type: boolean + - in: query + name: issuer_mode + schema: + allOf: + - $ref: '#/components/schemas/IssuerModeEnum' + description: |+ + Configure how the issuer field of the ID Token should be filled. + + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: property_mappings + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: refresh_token_validity + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: signing_key + schema: + type: string + format: uuid + - in: query + name: sub_mode + schema: + allOf: + - $ref: '#/components/schemas/SubModeEnum' + description: |+ + Configure what data should be used as unique User Identifier. For most cases, the default should be fine. + + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedOAuth2ProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_oauth2_create + description: OAuth2Provider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/OAuth2ProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuth2Provider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/oauth2/{id}/: + get: + operationId: providers_oauth2_retrieve + description: OAuth2Provider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2/OpenID Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuth2Provider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_oauth2_update + description: OAuth2Provider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2/OpenID Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/OAuth2ProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuth2Provider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_oauth2_partial_update + description: OAuth2Provider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2/OpenID Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedOAuth2ProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuth2Provider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_oauth2_destroy + description: OAuth2Provider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2/OpenID Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/oauth2/{id}/preview_user/: + get: + operationId: providers_oauth2_preview_user_retrieve + description: Preview user data for provider + parameters: + - in: query + name: for_user + schema: + type: integer + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2/OpenID Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PropertyMappingPreview' + description: '' + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/oauth2/{id}/setup_urls/: + get: + operationId: providers_oauth2_setup_urls_retrieve + description: Get Providers setup URLs + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2/OpenID Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuth2ProviderSetupURLs' + description: '' + '404': + description: Provider has no application assigned + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/oauth2/{id}/used_by/: + get: + operationId: providers_oauth2_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this OAuth2/OpenID Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/proxy/: + get: + operationId: providers_proxy_list + description: ProxyProvider Viewset + parameters: + - in: query + name: application__isnull + schema: + type: boolean + - in: query + name: authorization_flow__slug__iexact + schema: + type: string + - in: query + name: basic_auth_enabled__iexact + schema: + type: boolean + - in: query + name: basic_auth_password_attribute__iexact + schema: + type: string + - in: query + name: basic_auth_user_attribute__iexact + schema: + type: string + - in: query + name: certificate__kp_uuid__iexact + schema: + type: string + format: uuid + - in: query + name: certificate__name__iexact + schema: + type: string + - in: query + name: cookie_domain__iexact + schema: + type: string + - in: query + name: external_host__iexact + schema: + type: string + - in: query + name: internal_host__iexact + schema: + type: string + - in: query + name: internal_host_ssl_validation__iexact + schema: + type: boolean + - in: query + name: mode__iexact + schema: + type: string + - in: query + name: name__iexact + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: property_mappings__iexact + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: skip_path_regex__iexact + schema: + type: string + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedProxyProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_proxy_create + description: ProxyProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ProxyProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/ProxyProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/proxy/{id}/: + get: + operationId: providers_proxy_retrieve + description: ProxyProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Proxy Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ProxyProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_proxy_update + description: ProxyProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Proxy Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ProxyProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ProxyProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_proxy_partial_update + description: ProxyProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Proxy Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedProxyProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ProxyProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_proxy_destroy + description: ProxyProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Proxy Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/proxy/{id}/used_by/: + get: + operationId: providers_proxy_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Proxy Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/rac/: + get: + operationId: providers_rac_list + description: RACProvider Viewset + parameters: + - in: query + name: application__isnull + schema: + type: boolean + - in: query + name: name__iexact + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedRACProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_rac_create + description: RACProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RACProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/RACProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/rac/{id}/: + get: + operationId: providers_rac_retrieve + description: RACProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this RAC Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RACProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_rac_update + description: RACProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this RAC Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RACProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RACProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_rac_partial_update + description: RACProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this RAC Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedRACProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RACProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_rac_destroy + description: RACProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this RAC Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/rac/{id}/used_by/: + get: + operationId: providers_rac_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this RAC Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/radius/: + get: + operationId: providers_radius_list + description: RadiusProvider Viewset + parameters: + - in: query + name: application__isnull + schema: + type: boolean + - in: query + name: authorization_flow__slug__iexact + schema: + type: string + - in: query + name: client_networks__iexact + schema: + type: string + - in: query + name: name__iexact + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedRadiusProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_radius_create + description: RadiusProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/radius/{id}/: + get: + operationId: providers_radius_retrieve + description: RadiusProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Radius Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_radius_update + description: RadiusProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Radius Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_radius_partial_update + description: RadiusProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Radius Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedRadiusProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RadiusProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_radius_destroy + description: RadiusProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Radius Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/radius/{id}/used_by/: + get: + operationId: providers_radius_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Radius Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/saml/: + get: + operationId: providers_saml_list + description: SAMLProvider Viewset + parameters: + - in: query + name: acs_url + schema: + type: string + - in: query + name: assertion_valid_not_before + schema: + type: string + - in: query + name: assertion_valid_not_on_or_after + schema: + type: string + - in: query + name: audience + schema: + type: string + - in: query + name: authentication_flow + schema: + type: string + format: uuid + - in: query + name: authn_context_class_ref_mapping + schema: + type: string + format: uuid + - in: query + name: authorization_flow + schema: + type: string + format: uuid + - in: query + name: backchannel_application + schema: + type: string + format: uuid + - in: query + name: default_name_id_policy + schema: + $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + - in: query + name: default_relay_state + schema: + type: string + - in: query + name: digest_algorithm + schema: + $ref: '#/components/schemas/DigestAlgorithmEnum' + - in: query + name: encryption_kp + schema: + type: string + format: uuid + - in: query + name: invalidation_flow + schema: + type: string + format: uuid + - in: query + name: is_backchannel + schema: + type: boolean + - in: query + name: issuer_override + schema: + type: string + - in: query + name: logout_method + schema: + allOf: + - $ref: '#/components/schemas/SAMLLogoutMethods' + description: |+ + Method to use for logout. Front-channel iframe loads all logout URLs simultaneously in hidden iframes. Front-channel native uses your active browser tab to send post requests and redirect to providers. Back-channel sends logout requests directly from the server without user interaction (requires POST SLS binding). + + - $ref: '#/components/parameters/QueryName' + - in: query + name: name_id_mapping + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: property_mappings + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: session_valid_not_on_or_after + schema: + type: string + - in: query + name: sign_assertion + schema: + type: boolean + - in: query + name: sign_logout_request + schema: + type: boolean + - in: query + name: sign_logout_response + schema: + type: boolean + - in: query + name: sign_response + schema: + type: boolean + - in: query + name: signature_algorithm + schema: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + - in: query + name: signing_kp + schema: + type: string + format: uuid + - in: query + name: sls_binding + schema: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + description: |+ + This determines how authentik sends the logout response back to the Service Provider. + + - in: query + name: sls_url + schema: + type: string + - in: query + name: sp_binding + schema: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + title: Service Provider Binding + description: |+ + This determines how authentik sends the response back to the Service Provider. + + - in: query + name: verification_kp + schema: + type: string + format: uuid + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSAMLProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_saml_create + description: SAMLProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/saml/{id}/: + get: + operationId: providers_saml_retrieve + description: SAMLProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SAML Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_saml_update + description: SAMLProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SAML Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_saml_partial_update + description: SAMLProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SAML Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSAMLProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_saml_destroy + description: SAMLProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SAML Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/saml/{id}/metadata/: + get: + operationId: providers_saml_metadata_retrieve + description: Return metadata as XML string + parameters: + - in: query + name: download + schema: + type: boolean + - in: query + name: force_binding + schema: + allOf: + - $ref: '#/components/schemas/ForceBindingEnum' + description: Optionally force the metadata to only include one binding. + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SAML Provider. + required: true + tags: + - providers + security: + - authentik: [] + - {} + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLMetadata' + application/xml: + schema: + $ref: '#/components/schemas/SAMLMetadata' + description: '' + '404': + description: Provider has no application assigned + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/saml/{id}/preview_user/: + get: + operationId: providers_saml_preview_user_retrieve + description: Preview user data for provider + parameters: + - in: query + name: for_user + schema: + type: integer + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SAML Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PropertyMappingPreview' + description: '' + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/saml/{id}/used_by/: + get: + operationId: providers_saml_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SAML Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/saml/import_metadata/: + post: + operationId: providers_saml_import_metadata_create + description: Create provider from SAML Metadata + tags: + - providers + requestBody: + content: + multipart/form-data: + schema: + $ref: '#/components/schemas/SAMLProviderImportRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLProvider' + description: '' + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim/: + get: + operationId: providers_scim_list + description: SCIMProvider Viewset + parameters: + - in: query + name: exclude_users_service_account + schema: + type: boolean + - in: query + name: group_filters + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: url + schema: + type: string + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSCIMProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_scim_create + description: SCIMProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim/{id}/: + get: + operationId: providers_scim_retrieve + description: SCIMProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SCIM Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_scim_update + description: SCIMProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SCIM Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_scim_partial_update + description: SCIMProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SCIM Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSCIMProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_scim_destroy + description: SCIMProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SCIM Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim/{id}/sync/object/: + post: + operationId: providers_scim_sync_object_create + description: Sync/Re-sync a single user/group object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SCIM Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SyncObjectRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SyncObjectResult' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim/{id}/sync/status/: + get: + operationId: providers_scim_sync_status_retrieve + description: Get provider's sync status + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SCIM Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SyncStatus' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim/{id}/used_by/: + get: + operationId: providers_scim_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this SCIM Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim_groups/: + get: + operationId: providers_scim_groups_list + description: SCIMProviderGroup Viewset + parameters: + - in: query + name: group__group_uuid + schema: + type: string + format: uuid + - in: query + name: group__name + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider__id + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSCIMProviderGroupList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_scim_groups_create + description: SCIMProviderGroup Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProviderGroupRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProviderGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim_groups/{id}/: + get: + operationId: providers_scim_groups_retrieve + description: SCIMProviderGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this scim provider group. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProviderGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_scim_groups_destroy + description: SCIMProviderGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this scim provider group. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim_groups/{id}/used_by/: + get: + operationId: providers_scim_groups_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this scim provider group. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim_users/: + get: + operationId: providers_scim_users_list + description: SCIMProviderUser Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider__id + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user__id + schema: + type: integer + - in: query + name: user__username + schema: + type: string + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSCIMProviderUserList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_scim_users_create + description: SCIMProviderUser Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProviderUserRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProviderUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim_users/{id}/: + get: + operationId: providers_scim_users_retrieve + description: SCIMProviderUser Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this scim provider user. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMProviderUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_scim_users_destroy + description: SCIMProviderUser Viewset + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this scim provider user. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/scim_users/{id}/used_by/: + get: + operationId: providers_scim_users_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this scim provider user. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/ssf/: + get: + operationId: providers_ssf_list + description: SSFProvider Viewset + parameters: + - in: query + name: application__isnull + schema: + type: boolean + - in: query + name: name__iexact + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSSFProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_ssf_create + description: SSFProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SSFProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SSFProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/ssf/{id}/: + get: + operationId: providers_ssf_retrieve + description: SSFProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Shared Signals Framework + Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SSFProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_ssf_update + description: SSFProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Shared Signals Framework + Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SSFProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SSFProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_ssf_partial_update + description: SSFProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Shared Signals Framework + Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSSFProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SSFProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_ssf_destroy + description: SSFProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Shared Signals Framework + Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/ssf/{id}/used_by/: + get: + operationId: providers_ssf_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Shared Signals Framework + Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/wsfed/: + get: + operationId: providers_wsfed_list + description: WSFederationProvider Viewset + parameters: + - in: query + name: acs_url + schema: + type: string + - in: query + name: assertion_valid_not_before + schema: + type: string + - in: query + name: assertion_valid_not_on_or_after + schema: + type: string + - in: query + name: audience + schema: + type: string + - in: query + name: authentication_flow + schema: + type: string + format: uuid + - in: query + name: authn_context_class_ref_mapping + schema: + type: string + format: uuid + - in: query + name: authorization_flow + schema: + type: string + format: uuid + - in: query + name: backchannel_application + schema: + type: string + format: uuid + - in: query + name: default_name_id_policy + schema: + $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + - in: query + name: default_relay_state + schema: + type: string + - in: query + name: digest_algorithm + schema: + $ref: '#/components/schemas/DigestAlgorithmEnum' + - in: query + name: encryption_kp + schema: + type: string + format: uuid + - in: query + name: invalidation_flow + schema: + type: string + format: uuid + - in: query + name: is_backchannel + schema: + type: boolean + - in: query + name: issuer_override + schema: + type: string + - in: query + name: logout_method + schema: + allOf: + - $ref: '#/components/schemas/SAMLLogoutMethods' + description: |+ + Method to use for logout. Front-channel iframe loads all logout URLs simultaneously in hidden iframes. Front-channel native uses your active browser tab to send post requests and redirect to providers. Back-channel sends logout requests directly from the server without user interaction (requires POST SLS binding). + + - $ref: '#/components/parameters/QueryName' + - in: query + name: name_id_mapping + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: property_mappings + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: session_valid_not_on_or_after + schema: + type: string + - in: query + name: sign_assertion + schema: + type: boolean + - in: query + name: sign_logout_request + schema: + type: boolean + - in: query + name: sign_logout_response + schema: + type: boolean + - in: query + name: sign_response + schema: + type: boolean + - in: query + name: signature_algorithm + schema: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + - in: query + name: signing_kp + schema: + type: string + format: uuid + - in: query + name: sls_binding + schema: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + description: |+ + This determines how authentik sends the logout response back to the Service Provider. + + - in: query + name: sls_url + schema: + type: string + - in: query + name: sp_binding + schema: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + title: Service Provider Binding + description: |+ + This determines how authentik sends the response back to the Service Provider. + + - in: query + name: verification_kp + schema: + type: string + format: uuid + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedWSFederationProviderList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: providers_wsfed_create + description: WSFederationProvider Viewset + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/WSFederationProviderRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/WSFederationProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/wsfed/{id}/: + get: + operationId: providers_wsfed_retrieve + description: WSFederationProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WS-Federation Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WSFederationProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: providers_wsfed_update + description: WSFederationProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WS-Federation Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/WSFederationProviderRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WSFederationProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: providers_wsfed_partial_update + description: WSFederationProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WS-Federation Provider. + required: true + tags: + - providers + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedWSFederationProviderRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WSFederationProvider' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: providers_wsfed_destroy + description: WSFederationProvider Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WS-Federation Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/wsfed/{id}/metadata/: + get: + operationId: providers_wsfed_metadata_retrieve + description: Return metadata as XML string + parameters: + - in: query + name: download + schema: + type: boolean + - in: query + name: force_binding + schema: + allOf: + - $ref: '#/components/schemas/ForceBindingEnum' + description: Optionally force the metadata to only include one binding. + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WS-Federation Provider. + required: true + tags: + - providers + security: + - authentik: [] + - {} + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLMetadata' + application/xml: + schema: + $ref: '#/components/schemas/SAMLMetadata' + description: '' + '404': + description: Provider has no application assigned + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/wsfed/{id}/preview_user/: + get: + operationId: providers_wsfed_preview_user_retrieve + description: Preview user data for provider + parameters: + - in: query + name: for_user + schema: + type: integer + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WS-Federation Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PropertyMappingPreview' + description: '' + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /providers/wsfed/{id}/used_by/: + get: + operationId: providers_wsfed_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this WS-Federation Provider. + required: true + tags: + - providers + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rac/connection_tokens/: + get: + operationId: rac_connection_tokens_list + description: ConnectionToken Viewset + parameters: + - in: query + name: endpoint + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: session__user + schema: + type: integer + tags: + - rac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedConnectionTokenList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rac/connection_tokens/{connection_token_uuid}/: + get: + operationId: rac_connection_tokens_retrieve + description: ConnectionToken Viewset + parameters: + - in: path + name: connection_token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Connection token. + required: true + tags: + - rac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ConnectionToken' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: rac_connection_tokens_update + description: ConnectionToken Viewset + parameters: + - in: path + name: connection_token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Connection token. + required: true + tags: + - rac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ConnectionTokenRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ConnectionToken' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: rac_connection_tokens_partial_update + description: ConnectionToken Viewset + parameters: + - in: path + name: connection_token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Connection token. + required: true + tags: + - rac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedConnectionTokenRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ConnectionToken' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: rac_connection_tokens_destroy + description: ConnectionToken Viewset + parameters: + - in: path + name: connection_token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Connection token. + required: true + tags: + - rac + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rac/connection_tokens/{connection_token_uuid}/used_by/: + get: + operationId: rac_connection_tokens_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: connection_token_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Connection token. + required: true + tags: + - rac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rac/endpoints/: + get: + operationId: rac_endpoints_list + description: List accessible endpoints + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: superuser_full_list + schema: + type: boolean + tags: + - rac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedEndpointList' + description: '' + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: rac_endpoints_create + description: Endpoint Viewset + tags: + - rac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Endpoint' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rac/endpoints/{pbm_uuid}/: + get: + operationId: rac_endpoints_retrieve + description: Endpoint Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Endpoint. + required: true + tags: + - rac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Endpoint' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: rac_endpoints_update + description: Endpoint Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Endpoint. + required: true + tags: + - rac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Endpoint' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: rac_endpoints_partial_update + description: Endpoint Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Endpoint. + required: true + tags: + - rac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedEndpointRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Endpoint' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: rac_endpoints_destroy + description: Endpoint Viewset + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Endpoint. + required: true + tags: + - rac + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rac/endpoints/{pbm_uuid}/used_by/: + get: + operationId: rac_endpoints_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: pbm_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this RAC Endpoint. + required: true + tags: + - rac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/initial_permissions/: + get: + operationId: rbac_initial_permissions_list + description: InitialPermissions viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedInitialPermissionsList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: rbac_initial_permissions_create + description: InitialPermissions viewset + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/InitialPermissionsRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/InitialPermissions' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/initial_permissions/{id}/: + get: + operationId: rbac_initial_permissions_retrieve + description: InitialPermissions viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Initial Permissions. + required: true + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/InitialPermissions' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: rbac_initial_permissions_update + description: InitialPermissions viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Initial Permissions. + required: true + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/InitialPermissionsRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/InitialPermissions' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: rbac_initial_permissions_partial_update + description: InitialPermissions viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Initial Permissions. + required: true + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedInitialPermissionsRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/InitialPermissions' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: rbac_initial_permissions_destroy + description: InitialPermissions viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Initial Permissions. + required: true + tags: + - rbac + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/initial_permissions/{id}/used_by/: + get: + operationId: rbac_initial_permissions_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Initial Permissions. + required: true + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/permissions/: + get: + operationId: rbac_permissions_list + description: Read-only list of all permissions, filterable by model and app + parameters: + - in: query + name: codename + schema: + type: string + - in: query + name: content_type__app_label + schema: + type: string + - in: query + name: content_type__model + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: role + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPermissionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/permissions/{id}/: + get: + operationId: rbac_permissions_retrieve + description: Read-only list of all permissions, filterable by model and app + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this permission. + required: true + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Permission' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/permissions/assigned_by_roles/: + get: + operationId: rbac_permissions_assigned_by_roles_list + description: Get assigned object permissions for a single object + parameters: + - in: query + name: model + schema: + type: string + required: true + - in: query + name: object_pk + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedRoleAssignedObjectPermissionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/permissions/assigned_by_roles/{uuid}/assign/: + post: + operationId: rbac_permissions_assigned_by_roles_assign + description: |- + Assign permission(s) to role. When `object_pk` is set, the permissions + are only assigned to the specific object, otherwise they are assigned globally. + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Role. + required: true + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PermissionAssignRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/PermissionAssignResult' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/permissions/assigned_by_roles/{uuid}/unassign/: + patch: + operationId: rbac_permissions_assigned_by_roles_unassign_partial_update + description: |- + Unassign permission(s) to role. When `object_pk` is set, the permissions + are only assigned to the specific object, otherwise they are assigned globally. + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Role. + required: true + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedPermissionAssignRequest' + security: + - authentik: [] + responses: + '204': + description: Successfully unassigned + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/permissions/roles/: + get: + operationId: rbac_permissions_roles_list + description: Get a role's assigned object permissions + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: uuid + schema: + type: string + format: uuid + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedExtraRoleObjectPermissionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/roles/: + get: + operationId: rbac_roles_list + description: Role viewset + parameters: + - in: query + name: groups + schema: + type: string + format: uuid + - in: query + name: inherited + schema: + type: boolean + description: Include inherited roles (requires users or groups filter) + - in: query + name: managed + schema: + type: array + items: + type: string + explode: true + style: form + - in: query + name: managed__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: users + schema: + type: integer + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedRoleList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: rbac_roles_create + description: Role viewset + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Role' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/roles/{uuid}/: + get: + operationId: rbac_roles_retrieve + description: Role viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Role. + required: true + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Role' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: rbac_roles_update + description: Role viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Role. + required: true + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Role' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: rbac_roles_partial_update + description: Role viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Role. + required: true + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedRoleRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Role' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: rbac_roles_destroy + description: Role viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Role. + required: true + tags: + - rbac + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/roles/{uuid}/add_user/: + post: + operationId: rbac_roles_add_user_create + description: Add user to role + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Role. + required: true + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserAccountSerializerForRoleRequest' + required: true + security: + - authentik: [] + responses: + '204': + description: User added + '404': + description: User not found + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/roles/{uuid}/remove_user/: + post: + operationId: rbac_roles_remove_user_create + description: Remove user from role + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Role. + required: true + tags: + - rbac + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserAccountSerializerForRoleRequest' + required: true + security: + - authentik: [] + responses: + '204': + description: User removed + '404': + description: User not found + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /rbac/roles/{uuid}/used_by/: + get: + operationId: rbac_roles_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Role. + required: true + tags: + - rbac + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /reports/exports/: + get: + operationId: reports_exports_list + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - reports + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDataExportList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /reports/exports/{id}/: + get: + operationId: reports_exports_retrieve + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Data Export. + required: true + tags: + - reports + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DataExport' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: reports_exports_destroy + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Data Export. + required: true + tags: + - reports + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /root/config/: + get: + operationId: root_config_retrieve + description: Retrieve public configuration options + tags: + - root + security: + - authentik: [] + - {} + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Config' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /schema/: + get: + operationId: schema_retrieve + description: |- + OpenApi3 schema for this API. Format can be selected via content negotiation. + + - YAML: application/vnd.oai.openapi + - JSON: application/vnd.oai.openapi+json + parameters: + - in: query + name: format + schema: + $ref: '#/components/schemas/FormatEnum' + - in: query + name: lang + schema: + $ref: '#/components/schemas/LangEnum' + tags: + - schema + security: + - authentik: [] + - {} + responses: + '200': + content: + application/vnd.oai.openapi: + schema: + type: object + additionalProperties: {} + application/yaml: + schema: + type: object + additionalProperties: {} + application/vnd.oai.openapi+json: + schema: + type: object + additionalProperties: {} + application/json: + schema: + type: object + additionalProperties: {} + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/all/: + get: + operationId: sources_all_list + description: Source Viewset + parameters: + - in: query + name: managed + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSourceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/all/{slug}/: + get: + operationId: sources_all_retrieve + description: Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Source' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_all_destroy + description: Prevent deletion of built-in sources + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/all/{slug}/used_by/: + get: + operationId: sources_all_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/all/types/: + get: + operationId: sources_all_types_list + description: Get all creatable types + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/TypeCreate' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/all/user_settings/: + get: + operationId: sources_all_user_settings_list + description: Get all sources the user can configure + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UserSetting' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/all/: + get: + operationId: sources_group_connections_all_list + description: Group-source connection Viewset + parameters: + - in: query + name: group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGroupSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/all/{id}/: + get: + operationId: sources_group_connections_all_retrieve + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this group source connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_group_connections_all_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this group source connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_group_connections_all_partial_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this group source connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGroupSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_group_connections_all_destroy + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this group source connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/all/{id}/used_by/: + get: + operationId: sources_group_connections_all_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this group source connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/kerberos/: + get: + operationId: sources_group_connections_kerberos_list + description: Group-source connection Viewset + parameters: + - in: query + name: group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGroupKerberosSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_group_connections_kerberos_create + description: Group-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupKerberosSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupKerberosSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/kerberos/{id}/: + get: + operationId: sources_group_connections_kerberos_retrieve + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Kerberos Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupKerberosSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_group_connections_kerberos_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Kerberos Source + Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupKerberosSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupKerberosSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_group_connections_kerberos_partial_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Kerberos Source + Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGroupKerberosSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupKerberosSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_group_connections_kerberos_destroy + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Kerberos Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/kerberos/{id}/used_by/: + get: + operationId: sources_group_connections_kerberos_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Kerberos Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/ldap/: + get: + operationId: sources_group_connections_ldap_list + description: Group-source connection Viewset + parameters: + - in: query + name: group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGroupLDAPSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_group_connections_ldap_create + description: Group-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupLDAPSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupLDAPSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/ldap/{id}/: + get: + operationId: sources_group_connections_ldap_retrieve + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group LDAP Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupLDAPSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_group_connections_ldap_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group LDAP Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupLDAPSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupLDAPSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_group_connections_ldap_partial_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group LDAP Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGroupLDAPSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupLDAPSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_group_connections_ldap_destroy + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group LDAP Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/ldap/{id}/used_by/: + get: + operationId: sources_group_connections_ldap_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group LDAP Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/oauth/: + get: + operationId: sources_group_connections_oauth_list + description: Group-source connection Viewset + parameters: + - in: query + name: group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGroupOAuthSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_group_connections_oauth_create + description: Group-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupOAuthSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupOAuthSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/oauth/{id}/: + get: + operationId: sources_group_connections_oauth_retrieve + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group OAuth Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupOAuthSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_group_connections_oauth_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group OAuth Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupOAuthSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupOAuthSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_group_connections_oauth_partial_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group OAuth Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGroupOAuthSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupOAuthSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_group_connections_oauth_destroy + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group OAuth Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/oauth/{id}/used_by/: + get: + operationId: sources_group_connections_oauth_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group OAuth Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/plex/: + get: + operationId: sources_group_connections_plex_list + description: Group-source connection Viewset + parameters: + - in: query + name: group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGroupPlexSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_group_connections_plex_create + description: Group-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupPlexSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupPlexSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/plex/{id}/: + get: + operationId: sources_group_connections_plex_retrieve + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Plex Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupPlexSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_group_connections_plex_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Plex Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupPlexSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupPlexSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_group_connections_plex_partial_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Plex Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGroupPlexSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupPlexSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_group_connections_plex_destroy + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Plex Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/plex/{id}/used_by/: + get: + operationId: sources_group_connections_plex_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Plex Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/saml/: + get: + operationId: sources_group_connections_saml_list + description: Group-source connection Viewset + parameters: + - in: query + name: group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGroupSAMLSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_group_connections_saml_create + description: Group-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSAMLSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSAMLSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/saml/{id}/: + get: + operationId: sources_group_connections_saml_retrieve + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group SAML Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSAMLSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_group_connections_saml_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group SAML Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSAMLSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSAMLSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_group_connections_saml_partial_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group SAML Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGroupSAMLSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupSAMLSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_group_connections_saml_destroy + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group SAML Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/saml/{id}/used_by/: + get: + operationId: sources_group_connections_saml_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group SAML Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/telegram/: + get: + operationId: sources_group_connections_telegram_list + description: Group-source connection Viewset + parameters: + - in: query + name: group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedGroupTelegramSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_group_connections_telegram_create + description: Group-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupTelegramSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupTelegramSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/telegram/{id}/: + get: + operationId: sources_group_connections_telegram_retrieve + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Telegram Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupTelegramSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_group_connections_telegram_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Telegram Source + Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupTelegramSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupTelegramSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_group_connections_telegram_partial_update + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Telegram Source + Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedGroupTelegramSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GroupTelegramSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_group_connections_telegram_destroy + description: Group-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Telegram Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/group_connections/telegram/{id}/used_by/: + get: + operationId: sources_group_connections_telegram_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Group Telegram Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/kerberos/: + get: + operationId: sources_kerberos_list + description: Kerberos Source Viewset + parameters: + - in: query + name: enabled + schema: + type: boolean + - in: query + name: kadmin_type + schema: + allOf: + - $ref: '#/components/schemas/KadminTypeEnum' + description: |+ + KAdmin server type + + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: password_login_update_internal_password + schema: + type: boolean + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - in: query + name: realm + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: slug + schema: + type: string + - in: query + name: spnego_server_name + schema: + type: string + - in: query + name: sync_principal + schema: + type: string + - in: query + name: sync_users + schema: + type: boolean + - in: query + name: sync_users_password + schema: + type: boolean + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedKerberosSourceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_kerberos_create + description: Kerberos Source Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSourceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/kerberos/{slug}/: + get: + operationId: sources_kerberos_retrieve + description: Kerberos Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_kerberos_update + description: Kerberos Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSourceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_kerberos_partial_update + description: Kerberos Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedKerberosSourceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/KerberosSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_kerberos_destroy + description: Kerberos Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/kerberos/{slug}/sync/status/: + get: + operationId: sources_kerberos_sync_status_retrieve + description: Get provider's sync status + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SyncStatus' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/kerberos/{slug}/used_by/: + get: + operationId: sources_kerberos_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/ldap/: + get: + operationId: sources_ldap_list + description: LDAP Source Viewset + parameters: + - in: query + name: additional_group_dn + schema: + type: string + - in: query + name: additional_user_dn + schema: + type: string + - in: query + name: base_dn + schema: + type: string + - in: query + name: bind_cn + schema: + type: string + - in: query + name: client_certificate + schema: + type: string + format: uuid + - in: query + name: delete_not_found_objects + schema: + type: boolean + - in: query + name: enabled + schema: + type: boolean + - in: query + name: group_membership_field + schema: + type: string + - in: query + name: group_object_filter + schema: + type: string + - in: query + name: group_property_mappings + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: lookup_groups_from_user + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - in: query + name: object_uniqueness_field + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: password_login_update_internal_password + schema: + type: boolean + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - in: query + name: peer_certificate + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: server_uri + schema: + type: string + - in: query + name: slug + schema: + type: string + - in: query + name: sni + schema: + type: boolean + - in: query + name: start_tls + schema: + type: boolean + - in: query + name: sync_groups + schema: + type: boolean + - in: query + name: sync_parent_group + schema: + type: string + format: uuid + - in: query + name: sync_users + schema: + type: boolean + - in: query + name: sync_users_password + schema: + type: boolean + - in: query + name: user_membership_attribute + schema: + type: string + - in: query + name: user_object_filter + schema: + type: string + - in: query + name: user_property_mappings + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedLDAPSourceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_ldap_create + description: LDAP Source Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSourceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/ldap/{slug}/: + get: + operationId: sources_ldap_retrieve + description: LDAP Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_ldap_update + description: LDAP Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSourceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_ldap_partial_update + description: LDAP Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedLDAPSourceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_ldap_destroy + description: LDAP Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/ldap/{slug}/debug/: + get: + operationId: sources_ldap_debug_retrieve + description: Get raw LDAP data to debug + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/LDAPDebug' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/ldap/{slug}/sync/status/: + get: + operationId: sources_ldap_sync_status_retrieve + description: Get provider's sync status + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SyncStatus' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/ldap/{slug}/used_by/: + get: + operationId: sources_ldap_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/oauth/: + get: + operationId: sources_oauth_list + description: Source Viewset + parameters: + - in: query + name: access_token_url + schema: + type: string + - in: query + name: additional_scopes + schema: + type: string + - in: query + name: authentication_flow + schema: + type: string + format: uuid + - in: query + name: authorization_url + schema: + type: string + - in: query + name: consumer_key + schema: + type: string + - in: query + name: enabled + schema: + type: boolean + - in: query + name: enrollment_flow + schema: + type: string + format: uuid + - in: query + name: group_matching_mode + schema: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: |+ + How the source determines if an existing group should be used or a new group created. + + - in: query + name: has_jwks + schema: + type: boolean + description: Only return sources with JWKS data + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - in: query + name: policy_engine_mode + schema: + $ref: '#/components/schemas/PolicyEngineMode' + - in: query + name: profile_url + schema: + type: string + - in: query + name: provider_type + schema: + type: string + - in: query + name: request_token_url + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: slug + schema: + type: string + - in: query + name: user_matching_mode + schema: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: |+ + How the source determines if an existing user should be authenticated or a new user enrolled. + + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedOAuthSourceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_oauth_create + description: Source Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSourceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/oauth/{slug}/: + get: + operationId: sources_oauth_retrieve + description: Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_oauth_update + description: Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSourceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_oauth_partial_update + description: Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedOAuthSourceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/OAuthSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_oauth_destroy + description: Source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/oauth/{slug}/used_by/: + get: + operationId: sources_oauth_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/oauth/source_types/: + get: + operationId: sources_oauth_source_types_list + description: |- + Get all creatable source types. If ?name is set, only returns the type for . + If isn't found, returns the default type. + parameters: + - $ref: '#/components/parameters/QueryName' + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/SourceType' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/plex/: + get: + operationId: sources_plex_list + description: Plex source Viewset + parameters: + - in: query + name: allow_friends + schema: + type: boolean + - in: query + name: authentication_flow + schema: + type: string + format: uuid + - in: query + name: client_id + schema: + type: string + - in: query + name: enabled + schema: + type: boolean + - in: query + name: enrollment_flow + schema: + type: string + format: uuid + - in: query + name: group_matching_mode + schema: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: |+ + How the source determines if an existing group should be used or a new group created. + + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - in: query + name: policy_engine_mode + schema: + $ref: '#/components/schemas/PolicyEngineMode' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: slug + schema: + type: string + - in: query + name: user_matching_mode + schema: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: |+ + How the source determines if an existing user should be authenticated or a new user enrolled. + + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPlexSourceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_plex_create + description: Plex source Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSourceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/plex/{slug}/: + get: + operationId: sources_plex_retrieve + description: Plex source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_plex_update + description: Plex source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSourceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_plex_partial_update + description: Plex source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedPlexSourceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PlexSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_plex_destroy + description: Plex source Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/plex/{slug}/used_by/: + get: + operationId: sources_plex_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/plex/redeem_token/: + post: + operationId: sources_plex_redeem_token_create + description: |- + Redeem a plex token, check it's access to resources against what's allowed + for the source, and redirect to an authentication/enrollment flow. + parameters: + - in: query + name: slug + schema: + type: string + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PlexTokenRedeemRequest' + required: true + security: + - authentik: [] + - {} + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RedirectChallenge' + description: '' + '400': + description: Token not found + '403': + description: Access denied + /sources/plex/redeem_token_authenticated/: + post: + operationId: sources_plex_redeem_token_authenticated_create + description: Redeem a plex token for an authenticated user, creating a connection + parameters: + - in: query + name: slug + schema: + type: string + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PlexTokenRedeemRequest' + required: true + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + description: Token not found + '403': + description: Access denied + /sources/saml/: + get: + operationId: sources_saml_list + description: SAMLSource Viewset + parameters: + - in: query + name: allow_idp_initiated + schema: + type: boolean + - in: query + name: authentication_flow + schema: + type: string + format: uuid + - in: query + name: binding_type + schema: + $ref: '#/components/schemas/BindingTypeEnum' + - in: query + name: digest_algorithm + schema: + $ref: '#/components/schemas/DigestAlgorithmEnum' + - in: query + name: enabled + schema: + type: boolean + - in: query + name: enrollment_flow + schema: + type: string + format: uuid + - in: query + name: force_authn + schema: + type: boolean + - in: query + name: issuer + schema: + type: string + - in: query + name: managed + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - in: query + name: name_id_policy + schema: + allOf: + - $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + description: |+ + NameID Policy sent to the IdP. Can be unset, in which case no Policy is sent. + + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - in: query + name: policy_engine_mode + schema: + $ref: '#/components/schemas/PolicyEngineMode' + - in: query + name: pre_authentication_flow + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: signature_algorithm + schema: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + - in: query + name: signed_assertion + schema: + type: boolean + - in: query + name: signed_response + schema: + type: boolean + - in: query + name: signing_kp + schema: + type: string + format: uuid + - in: query + name: slo_url + schema: + type: string + - in: query + name: slug + schema: + type: string + - in: query + name: sso_url + schema: + type: string + - in: query + name: temporary_user_delete_after + schema: + type: string + - in: query + name: user_matching_mode + schema: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: |+ + How the source determines if an existing user should be authenticated or a new user enrolled. + + - in: query + name: verification_kp + schema: + type: string + format: uuid + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSAMLSourceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_saml_create + description: SAMLSource Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSourceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/saml/{slug}/: + get: + operationId: sources_saml_retrieve + description: SAMLSource Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_saml_update + description: SAMLSource Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSourceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_saml_partial_update + description: SAMLSource Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSAMLSourceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_saml_destroy + description: SAMLSource Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/saml/{slug}/metadata/: + get: + operationId: sources_saml_metadata_retrieve + description: Return metadata as XML string + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SAMLMetadata' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/saml/{slug}/used_by/: + get: + operationId: sources_saml_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/scim/: + get: + operationId: sources_scim_list + description: SCIMSource Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSCIMSourceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_scim_create + description: SCIMSource Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/scim/{slug}/: + get: + operationId: sources_scim_retrieve + description: SCIMSource Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_scim_update + description: SCIMSource Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_scim_partial_update + description: SCIMSource Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSCIMSourceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_scim_destroy + description: SCIMSource Viewset + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/scim/{slug}/used_by/: + get: + operationId: sources_scim_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/scim_groups/: + get: + operationId: sources_scim_groups_list + description: SCIMSourceGroup Viewset + parameters: + - in: query + name: group__group_uuid + schema: + type: string + format: uuid + - in: query + name: group__name + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSCIMSourceGroupList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_scim_groups_create + description: SCIMSourceGroup Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceGroupRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/scim_groups/{id}/: + get: + operationId: sources_scim_groups_retrieve + description: SCIMSourceGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source group. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_scim_groups_update + description: SCIMSourceGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source group. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceGroupRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_scim_groups_partial_update + description: SCIMSourceGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source group. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSCIMSourceGroupRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceGroup' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_scim_groups_destroy + description: SCIMSourceGroup Viewset + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source group. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/scim_groups/{id}/used_by/: + get: + operationId: sources_scim_groups_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source group. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/scim_users/: + get: + operationId: sources_scim_users_list + description: SCIMSourceUser Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + - in: query + name: user__id + schema: + type: integer + - in: query + name: user__username + schema: + type: string + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSCIMSourceUserList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_scim_users_create + description: SCIMSourceUser Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceUserRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/scim_users/{id}/: + get: + operationId: sources_scim_users_retrieve + description: SCIMSourceUser Viewset + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source user. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_scim_users_update + description: SCIMSourceUser Viewset + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source user. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceUserRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_scim_users_partial_update + description: SCIMSourceUser Viewset + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source user. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSCIMSourceUserRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SCIMSourceUser' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_scim_users_destroy + description: SCIMSourceUser Viewset + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source user. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/scim_users/{id}/used_by/: + get: + operationId: sources_scim_users_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: string + description: A unique value identifying this scim source user. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/telegram/: + get: + operationId: sources_telegram_list + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: query + name: authentication_flow + schema: + type: string + format: uuid + - in: query + name: bot_username + schema: + type: string + - in: query + name: enabled + schema: + type: boolean + - in: query + name: enrollment_flow + schema: + type: string + format: uuid + - in: query + name: group_matching_mode + schema: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: |+ + How the source determines if an existing group should be used or a new group created. + + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: pbm_uuid + schema: + type: string + format: uuid + - in: query + name: policy_engine_mode + schema: + $ref: '#/components/schemas/PolicyEngineMode' + - in: query + name: request_message_access + schema: + type: boolean + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: slug + schema: + type: string + - in: query + name: user_matching_mode + schema: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: |+ + How the source determines if an existing user should be authenticated or a new user enrolled. + + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedTelegramSourceList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_telegram_create + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSourceRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/telegram/{slug}/: + get: + operationId: sources_telegram_retrieve + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_telegram_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSourceRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_telegram_partial_update + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedTelegramSourceRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramSource' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_telegram_destroy + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/telegram/{slug}/connect_user/: + post: + operationId: sources_telegram_connect_user_create + description: Mixin to add a used_by endpoint to return a list of all objects + using this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TelegramAuthRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserTelegramSourceConnection' + description: '' + '403': + description: Access denied + '400': + $ref: '#/components/responses/ValidationErrorResponse' + /sources/telegram/{slug}/used_by/: + get: + operationId: sources_telegram_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: slug + schema: + type: string + description: Internal source name, used in URLs. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/all/: + get: + operationId: sources_user_connections_all_list + description: User-source connection Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + - in: query + name: user + schema: + type: integer + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/all/{id}/: + get: + operationId: sources_user_connections_all_retrieve + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this user source connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_user_connections_all_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this user source connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_user_connections_all_partial_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this user source connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_user_connections_all_destroy + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this user source connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/all/{id}/used_by/: + get: + operationId: sources_user_connections_all_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this user source connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/kerberos/: + get: + operationId: sources_user_connections_kerberos_list + description: User-source connection Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + - in: query + name: user + schema: + type: integer + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserKerberosSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_user_connections_kerberos_create + description: User-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserKerberosSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserKerberosSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/kerberos/{id}/: + get: + operationId: sources_user_connections_kerberos_retrieve + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Kerberos Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserKerberosSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_user_connections_kerberos_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Kerberos Source + Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserKerberosSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserKerberosSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_user_connections_kerberos_partial_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Kerberos Source + Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserKerberosSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserKerberosSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_user_connections_kerberos_destroy + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Kerberos Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/kerberos/{id}/used_by/: + get: + operationId: sources_user_connections_kerberos_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Kerberos Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/ldap/: + get: + operationId: sources_user_connections_ldap_list + description: User-source connection Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + - in: query + name: user + schema: + type: integer + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserLDAPSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_user_connections_ldap_create + description: User-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserLDAPSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLDAPSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/ldap/{id}/: + get: + operationId: sources_user_connections_ldap_retrieve + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User LDAP Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLDAPSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_user_connections_ldap_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User LDAP Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserLDAPSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLDAPSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_user_connections_ldap_partial_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User LDAP Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserLDAPSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLDAPSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_user_connections_ldap_destroy + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User LDAP Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/ldap/{id}/used_by/: + get: + operationId: sources_user_connections_ldap_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User LDAP Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/oauth/: + get: + operationId: sources_user_connections_oauth_list + description: User-source connection Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + - in: query + name: user + schema: + type: integer + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserOAuthSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_user_connections_oauth_create + description: User-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserOAuthSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserOAuthSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/oauth/{id}/: + get: + operationId: sources_user_connections_oauth_retrieve + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User OAuth Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserOAuthSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_user_connections_oauth_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User OAuth Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserOAuthSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserOAuthSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_user_connections_oauth_partial_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User OAuth Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserOAuthSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserOAuthSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_user_connections_oauth_destroy + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User OAuth Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/oauth/{id}/used_by/: + get: + operationId: sources_user_connections_oauth_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User OAuth Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/plex/: + get: + operationId: sources_user_connections_plex_list + description: User-source connection Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + - in: query + name: user + schema: + type: integer + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserPlexSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_user_connections_plex_create + description: User-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserPlexSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserPlexSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/plex/{id}/: + get: + operationId: sources_user_connections_plex_retrieve + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Plex Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserPlexSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_user_connections_plex_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Plex Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserPlexSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserPlexSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_user_connections_plex_partial_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Plex Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserPlexSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserPlexSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_user_connections_plex_destroy + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Plex Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/plex/{id}/used_by/: + get: + operationId: sources_user_connections_plex_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Plex Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/saml/: + get: + operationId: sources_user_connections_saml_list + description: User-source connection Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + - in: query + name: user + schema: + type: integer + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserSAMLSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_user_connections_saml_create + description: User-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserSAMLSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserSAMLSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/saml/{id}/: + get: + operationId: sources_user_connections_saml_retrieve + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User SAML Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserSAMLSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_user_connections_saml_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User SAML Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserSAMLSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserSAMLSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_user_connections_saml_partial_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User SAML Source Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserSAMLSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserSAMLSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_user_connections_saml_destroy + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User SAML Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/saml/{id}/used_by/: + get: + operationId: sources_user_connections_saml_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User SAML Source Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/telegram/: + get: + operationId: sources_user_connections_telegram_list + description: User-source connection Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source__slug + schema: + type: string + - in: query + name: user + schema: + type: integer + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserTelegramSourceConnectionList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: sources_user_connections_telegram_create + description: User-source connection Viewset + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserTelegramSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserTelegramSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/telegram/{id}/: + get: + operationId: sources_user_connections_telegram_retrieve + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Telegram Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserTelegramSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: sources_user_connections_telegram_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Telegram Source + Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserTelegramSourceConnectionRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserTelegramSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: sources_user_connections_telegram_partial_update + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Telegram Source + Connection. + required: true + tags: + - sources + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserTelegramSourceConnectionRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserTelegramSourceConnection' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: sources_user_connections_telegram_destroy + description: User-source connection Viewset + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Telegram Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /sources/user_connections/telegram/{id}/used_by/: + get: + operationId: sources_user_connections_telegram_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this User Telegram Source + Connection. + required: true + tags: + - sources + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /ssf/streams/: + get: + operationId: ssf_streams_list + description: SSFStream Viewset + parameters: + - in: query + name: delivery_method + schema: + $ref: '#/components/schemas/DeliveryMethodEnum' + - in: query + name: endpoint_url + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + tags: + - ssf + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSSFStreamList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /ssf/streams/{uuid}/: + get: + operationId: ssf_streams_retrieve + description: SSFStream Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SSF Stream. + required: true + tags: + - ssf + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SSFStream' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: ssf_streams_destroy + description: SSFStream Viewset + parameters: + - in: path + name: uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SSF Stream. + required: true + tags: + - ssf + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/account_lockdown/: + get: + operationId: stages_account_lockdown_list + description: AccountLockdownStage Viewset + parameters: + - in: query + name: deactivate_user + schema: + type: boolean + - in: query + name: delete_sessions + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: revoke_tokens + schema: + type: boolean + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: self_service_completion_flow + schema: + type: string + format: uuid + - in: query + name: set_unusable_password + schema: + type: boolean + - in: query + name: stage_uuid + schema: + type: string + format: uuid + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAccountLockdownStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_account_lockdown_create + description: AccountLockdownStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AccountLockdownStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AccountLockdownStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/account_lockdown/{stage_uuid}/: + get: + operationId: stages_account_lockdown_retrieve + description: AccountLockdownStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Account Lockdown Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AccountLockdownStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_account_lockdown_update + description: AccountLockdownStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Account Lockdown Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AccountLockdownStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AccountLockdownStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_account_lockdown_partial_update + description: AccountLockdownStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Account Lockdown Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAccountLockdownStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AccountLockdownStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_account_lockdown_destroy + description: AccountLockdownStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Account Lockdown Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/account_lockdown/{stage_uuid}/used_by/: + get: + operationId: stages_account_lockdown_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Account Lockdown Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/all/: + get: + operationId: stages_all_list + description: Stage Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/all/{stage_uuid}/: + get: + operationId: stages_all_retrieve + description: Stage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Stage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_all_destroy + description: Stage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/all/{stage_uuid}/used_by/: + get: + operationId: stages_all_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/all/types/: + get: + operationId: stages_all_types_list + description: Get all creatable types + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/TypeCreate' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/all/user_settings/: + get: + operationId: stages_all_user_settings_list + description: Get all stages the user can configure + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UserSetting' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/duo/: + get: + operationId: stages_authenticator_duo_list + description: AuthenticatorDuoStage Viewset + parameters: + - in: query + name: api_hostname + schema: + type: string + - in: query + name: client_id + schema: + type: string + - in: query + name: configure_flow + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAuthenticatorDuoStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_authenticator_duo_create + description: AuthenticatorDuoStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorDuoStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorDuoStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/duo/{stage_uuid}/: + get: + operationId: stages_authenticator_duo_retrieve + description: AuthenticatorDuoStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Duo Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorDuoStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_authenticator_duo_update + description: AuthenticatorDuoStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Duo Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorDuoStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorDuoStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_authenticator_duo_partial_update + description: AuthenticatorDuoStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Duo Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAuthenticatorDuoStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorDuoStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_authenticator_duo_destroy + description: AuthenticatorDuoStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Duo Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/duo/{stage_uuid}/enrollment_status/: + post: + operationId: stages_authenticator_duo_enrollment_status_create + description: Check enrollment status of user details in current session + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Duo Authenticator Setup Stage. + required: true + tags: + - stages + security: + - {} + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DuoDeviceEnrollmentStatus' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/duo/{stage_uuid}/import_device_manual/: + post: + operationId: stages_authenticator_duo_import_device_manual_create + description: Import duo devices into authentik + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Duo Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorDuoStageManualDeviceImportRequest' + required: true + security: + - authentik: [] + responses: + '204': + description: Enrollment successful + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/duo/{stage_uuid}/import_devices_automatic/: + post: + operationId: stages_authenticator_duo_import_devices_automatic_create + description: Import duo devices into authentik + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Duo Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorDuoStageDeviceImportResponse' + description: '' + '400': + description: Bad request + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/duo/{stage_uuid}/used_by/: + get: + operationId: stages_authenticator_duo_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Duo Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/email/: + get: + operationId: stages_authenticator_email_list + description: AuthenticatorEmailStage Viewset + parameters: + - in: query + name: configure_flow + schema: + type: string + format: uuid + - in: query + name: friendly_name + schema: + type: string + - in: query + name: from_address + schema: + type: string + - in: query + name: host + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: password + schema: + type: string + - in: query + name: port + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + - in: query + name: subject + schema: + type: string + - in: query + name: template + schema: + type: string + - in: query + name: timeout + schema: + type: integer + - in: query + name: token_expiry + schema: + type: string + - in: query + name: use_global_settings + schema: + type: boolean + - in: query + name: use_ssl + schema: + type: boolean + - in: query + name: use_tls + schema: + type: boolean + - in: query + name: username + schema: + type: string + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAuthenticatorEmailStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_authenticator_email_create + description: AuthenticatorEmailStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEmailStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEmailStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/email/{stage_uuid}/: + get: + operationId: stages_authenticator_email_retrieve + description: AuthenticatorEmailStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEmailStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_authenticator_email_update + description: AuthenticatorEmailStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEmailStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEmailStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_authenticator_email_partial_update + description: AuthenticatorEmailStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAuthenticatorEmailStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEmailStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_authenticator_email_destroy + description: AuthenticatorEmailStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/email/{stage_uuid}/used_by/: + get: + operationId: stages_authenticator_email_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/endpoint_gdtc/: + get: + operationId: stages_authenticator_endpoint_gdtc_list + description: AuthenticatorEndpointGDTCStage Viewset + parameters: + - in: query + name: configure_flow + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAuthenticatorEndpointGDTCStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_authenticator_endpoint_gdtc_create + description: AuthenticatorEndpointGDTCStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEndpointGDTCStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEndpointGDTCStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/endpoint_gdtc/{stage_uuid}/: + get: + operationId: stages_authenticator_endpoint_gdtc_retrieve + description: AuthenticatorEndpointGDTCStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Authenticator Google + Device Trust Connector Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEndpointGDTCStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_authenticator_endpoint_gdtc_update + description: AuthenticatorEndpointGDTCStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Authenticator Google + Device Trust Connector Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEndpointGDTCStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEndpointGDTCStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_authenticator_endpoint_gdtc_partial_update + description: AuthenticatorEndpointGDTCStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Authenticator Google + Device Trust Connector Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAuthenticatorEndpointGDTCStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorEndpointGDTCStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_authenticator_endpoint_gdtc_destroy + description: AuthenticatorEndpointGDTCStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Authenticator Google + Device Trust Connector Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/endpoint_gdtc/{stage_uuid}/used_by/: + get: + operationId: stages_authenticator_endpoint_gdtc_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Authenticator Google + Device Trust Connector Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/sms/: + get: + operationId: stages_authenticator_sms_list + description: AuthenticatorSMSStage Viewset + parameters: + - in: query + name: account_sid + schema: + type: string + - in: query + name: auth + schema: + type: string + - in: query + name: auth_password + schema: + type: string + - in: query + name: auth_type + schema: + $ref: '#/components/schemas/AuthTypeEnum' + - in: query + name: configure_flow + schema: + type: string + format: uuid + - in: query + name: friendly_name + schema: + type: string + - in: query + name: from_number + schema: + type: string + - in: query + name: mapping + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: provider + schema: + $ref: '#/components/schemas/ProviderEnum' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + - in: query + name: verify_only + schema: + type: boolean + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAuthenticatorSMSStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_authenticator_sms_create + description: AuthenticatorSMSStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorSMSStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorSMSStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/sms/{stage_uuid}/: + get: + operationId: stages_authenticator_sms_retrieve + description: AuthenticatorSMSStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SMS Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorSMSStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_authenticator_sms_update + description: AuthenticatorSMSStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SMS Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorSMSStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorSMSStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_authenticator_sms_partial_update + description: AuthenticatorSMSStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SMS Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAuthenticatorSMSStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorSMSStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_authenticator_sms_destroy + description: AuthenticatorSMSStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SMS Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/sms/{stage_uuid}/used_by/: + get: + operationId: stages_authenticator_sms_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this SMS Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/static/: + get: + operationId: stages_authenticator_static_list + description: AuthenticatorStaticStage Viewset + parameters: + - in: query + name: configure_flow + schema: + type: string + format: uuid + - in: query + name: friendly_name + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + - in: query + name: token_count + schema: + type: integer + - in: query + name: token_length + schema: + type: integer + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAuthenticatorStaticStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_authenticator_static_create + description: AuthenticatorStaticStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorStaticStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorStaticStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/static/{stage_uuid}/: + get: + operationId: stages_authenticator_static_retrieve + description: AuthenticatorStaticStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Static Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorStaticStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_authenticator_static_update + description: AuthenticatorStaticStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Static Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorStaticStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorStaticStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_authenticator_static_partial_update + description: AuthenticatorStaticStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Static Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAuthenticatorStaticStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorStaticStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_authenticator_static_destroy + description: AuthenticatorStaticStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Static Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/static/{stage_uuid}/used_by/: + get: + operationId: stages_authenticator_static_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Static Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/totp/: + get: + operationId: stages_authenticator_totp_list + description: AuthenticatorTOTPStage Viewset + parameters: + - in: query + name: configure_flow + schema: + type: string + format: uuid + - in: query + name: digits + schema: + $ref: '#/components/schemas/DigitsEnum' + - in: query + name: friendly_name + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAuthenticatorTOTPStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_authenticator_totp_create + description: AuthenticatorTOTPStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorTOTPStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorTOTPStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/totp/{stage_uuid}/: + get: + operationId: stages_authenticator_totp_retrieve + description: AuthenticatorTOTPStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this TOTP Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorTOTPStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_authenticator_totp_update + description: AuthenticatorTOTPStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this TOTP Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorTOTPStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorTOTPStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_authenticator_totp_partial_update + description: AuthenticatorTOTPStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this TOTP Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAuthenticatorTOTPStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorTOTPStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_authenticator_totp_destroy + description: AuthenticatorTOTPStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this TOTP Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/totp/{stage_uuid}/used_by/: + get: + operationId: stages_authenticator_totp_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this TOTP Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/validate/: + get: + operationId: stages_authenticator_validate_list + description: AuthenticatorValidateStage Viewset + parameters: + - in: query + name: configuration_stages + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - $ref: '#/components/parameters/QueryName' + - in: query + name: not_configured_action + schema: + $ref: '#/components/schemas/NotConfiguredActionEnum' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAuthenticatorValidateStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_authenticator_validate_create + description: AuthenticatorValidateStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorValidateStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorValidateStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/validate/{stage_uuid}/: + get: + operationId: stages_authenticator_validate_retrieve + description: AuthenticatorValidateStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Authenticator Validation Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorValidateStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_authenticator_validate_update + description: AuthenticatorValidateStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Authenticator Validation Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorValidateStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorValidateStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_authenticator_validate_partial_update + description: AuthenticatorValidateStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Authenticator Validation Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAuthenticatorValidateStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorValidateStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_authenticator_validate_destroy + description: AuthenticatorValidateStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Authenticator Validation Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/validate/{stage_uuid}/used_by/: + get: + operationId: stages_authenticator_validate_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Authenticator Validation Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/webauthn/: + get: + operationId: stages_authenticator_webauthn_list + description: AuthenticatorWebAuthnStage Viewset + parameters: + - in: query + name: authenticator_attachment + schema: + allOf: + - $ref: '#/components/schemas/AuthenticatorAttachmentEnum' + nullable: true + - in: query + name: configure_flow + schema: + type: string + format: uuid + - in: query + name: device_type_restrictions + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: max_attempts + schema: + type: integer + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: resident_key_requirement + schema: + $ref: '#/components/schemas/UserVerificationEnum' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: user_verification + schema: + $ref: '#/components/schemas/UserVerificationEnum' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedAuthenticatorWebAuthnStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_authenticator_webauthn_create + description: AuthenticatorWebAuthnStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorWebAuthnStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorWebAuthnStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/webauthn/{stage_uuid}/: + get: + operationId: stages_authenticator_webauthn_retrieve + description: AuthenticatorWebAuthnStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this WebAuthn Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorWebAuthnStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_authenticator_webauthn_update + description: AuthenticatorWebAuthnStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this WebAuthn Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorWebAuthnStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorWebAuthnStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_authenticator_webauthn_partial_update + description: AuthenticatorWebAuthnStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this WebAuthn Authenticator Setup Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedAuthenticatorWebAuthnStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorWebAuthnStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_authenticator_webauthn_destroy + description: AuthenticatorWebAuthnStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this WebAuthn Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/webauthn/{stage_uuid}/used_by/: + get: + operationId: stages_authenticator_webauthn_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this WebAuthn Authenticator Setup Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/webauthn_device_types/: + get: + operationId: stages_authenticator_webauthn_device_types_list + description: WebAuthnDeviceType Viewset + parameters: + - in: query + name: aaguid + schema: + type: string + format: uuid + - in: query + name: description + schema: + type: string + - in: query + name: icon + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedWebAuthnDeviceTypeList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/authenticator/webauthn_device_types/{aaguid}/: + get: + operationId: stages_authenticator_webauthn_device_types_retrieve + description: WebAuthnDeviceType Viewset + parameters: + - in: path + name: aaguid + schema: + type: string + format: uuid + description: A UUID string identifying this WebAuthn Device type. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/WebAuthnDeviceType' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/captcha/: + get: + operationId: stages_captcha_list + description: CaptchaStage Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: public_key + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedCaptchaStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_captcha_create + description: CaptchaStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CaptchaStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/CaptchaStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/captcha/{stage_uuid}/: + get: + operationId: stages_captcha_retrieve + description: CaptchaStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Captcha Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CaptchaStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_captcha_update + description: CaptchaStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Captcha Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CaptchaStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CaptchaStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_captcha_partial_update + description: CaptchaStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Captcha Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedCaptchaStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/CaptchaStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_captcha_destroy + description: CaptchaStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Captcha Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/captcha/{stage_uuid}/used_by/: + get: + operationId: stages_captcha_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Captcha Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/consent/: + get: + operationId: stages_consent_list + description: ConsentStage Viewset + parameters: + - in: query + name: consent_expire_in + schema: + type: string + - in: query + name: mode + schema: + $ref: '#/components/schemas/ConsentModeEnum' + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedConsentStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_consent_create + description: ConsentStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ConsentStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/ConsentStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/consent/{stage_uuid}/: + get: + operationId: stages_consent_retrieve + description: ConsentStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Consent Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ConsentStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_consent_update + description: ConsentStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Consent Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ConsentStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ConsentStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_consent_partial_update + description: ConsentStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Consent Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedConsentStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/ConsentStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_consent_destroy + description: ConsentStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Consent Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/consent/{stage_uuid}/used_by/: + get: + operationId: stages_consent_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Consent Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/deny/: + get: + operationId: stages_deny_list + description: DenyStage Viewset + parameters: + - in: query + name: deny_message + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDenyStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_deny_create + description: DenyStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DenyStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/DenyStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/deny/{stage_uuid}/: + get: + operationId: stages_deny_retrieve + description: DenyStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Deny Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DenyStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_deny_update + description: DenyStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Deny Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DenyStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DenyStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_deny_partial_update + description: DenyStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Deny Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedDenyStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DenyStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_deny_destroy + description: DenyStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Deny Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/deny/{stage_uuid}/used_by/: + get: + operationId: stages_deny_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Deny Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/dummy/: + get: + operationId: stages_dummy_list + description: DummyStage Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + - in: query + name: throw_error + schema: + type: boolean + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDummyStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_dummy_create + description: DummyStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DummyStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/DummyStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/dummy/{stage_uuid}/: + get: + operationId: stages_dummy_retrieve + description: DummyStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DummyStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_dummy_update + description: DummyStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DummyStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DummyStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_dummy_partial_update + description: DummyStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedDummyStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/DummyStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_dummy_destroy + description: DummyStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/dummy/{stage_uuid}/used_by/: + get: + operationId: stages_dummy_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Dummy Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/email/: + get: + operationId: stages_email_list + description: EmailStage Viewset + parameters: + - in: query + name: activate_user_on_success + schema: + type: boolean + - in: query + name: from_address + schema: + type: string + - in: query + name: host + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: port + schema: + type: integer + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: subject + schema: + type: string + - in: query + name: template + schema: + type: string + - in: query + name: timeout + schema: + type: integer + - in: query + name: token_expiry + schema: + type: string + - in: query + name: use_global_settings + schema: + type: boolean + - in: query + name: use_ssl + schema: + type: boolean + - in: query + name: use_tls + schema: + type: boolean + - in: query + name: username + schema: + type: string + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedEmailStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_email_create + description: EmailStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EmailStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/email/{stage_uuid}/: + get: + operationId: stages_email_retrieve + description: EmailStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_email_update + description: EmailStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EmailStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_email_partial_update + description: EmailStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedEmailStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EmailStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_email_destroy + description: EmailStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/email/{stage_uuid}/used_by/: + get: + operationId: stages_email_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Email Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/email/templates/: + get: + operationId: stages_email_templates_list + description: Get all available templates, including custom templates + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/TypeCreate' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/endpoints/: + get: + operationId: stages_endpoints_list + description: EndpointStage Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedEndpointStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_endpoints_create + description: EndpointStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/endpoints/{stage_uuid}/: + get: + operationId: stages_endpoints_retrieve + description: EndpointStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_endpoints_update + description: EndpointStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_endpoints_partial_update + description: EndpointStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedEndpointStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/EndpointStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_endpoints_destroy + description: EndpointStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/endpoints/{stage_uuid}/used_by/: + get: + operationId: stages_endpoints_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Endpoint Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/identification/: + get: + operationId: stages_identification_list + description: IdentificationStage Viewset + parameters: + - in: query + name: captcha_stage + schema: + type: string + format: uuid + - in: query + name: case_insensitive_matching + schema: + type: boolean + - in: query + name: enrollment_flow + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: password_stage + schema: + type: string + format: uuid + - in: query + name: passwordless_flow + schema: + type: string + format: uuid + - in: query + name: recovery_flow + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: show_matched_user + schema: + type: boolean + - in: query + name: show_source_labels + schema: + type: boolean + - in: query + name: webauthn_stage + schema: + type: string + format: uuid + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedIdentificationStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_identification_create + description: IdentificationStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/IdentificationStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/IdentificationStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/identification/{stage_uuid}/: + get: + operationId: stages_identification_retrieve + description: IdentificationStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Identification Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/IdentificationStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_identification_update + description: IdentificationStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Identification Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/IdentificationStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/IdentificationStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_identification_partial_update + description: IdentificationStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Identification Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedIdentificationStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/IdentificationStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_identification_destroy + description: IdentificationStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Identification Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/identification/{stage_uuid}/used_by/: + get: + operationId: stages_identification_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Identification Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/invitation/invitations/: + get: + operationId: stages_invitation_invitations_list + description: Invitation Viewset + parameters: + - in: query + name: created_by__username + schema: + type: string + - in: query + name: expires + schema: + type: string + format: date-time + - in: query + name: flow__slug + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedInvitationList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_invitation_invitations_create + description: Invitation Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/InvitationRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Invitation' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/invitation/invitations/{invite_uuid}/: + get: + operationId: stages_invitation_invitations_retrieve + description: Invitation Viewset + parameters: + - in: path + name: invite_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Invitation' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_invitation_invitations_update + description: Invitation Viewset + parameters: + - in: path + name: invite_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/InvitationRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Invitation' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_invitation_invitations_partial_update + description: Invitation Viewset + parameters: + - in: path + name: invite_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedInvitationRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Invitation' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_invitation_invitations_destroy + description: Invitation Viewset + parameters: + - in: path + name: invite_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/invitation/invitations/{invite_uuid}/send_email/: + post: + operationId: stages_invitation_invitations_send_email_create + description: Send invitation link via email to one or more addresses + parameters: + - in: path + name: invite_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/InvitationSendEmailRequest' + required: true + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/invitation/invitations/{invite_uuid}/used_by/: + get: + operationId: stages_invitation_invitations_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: invite_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/invitation/stages/: + get: + operationId: stages_invitation_stages_list + description: InvitationStage Viewset + parameters: + - in: query + name: continue_flow_without_invitation + schema: + type: boolean + - $ref: '#/components/parameters/QueryName' + - in: query + name: no_flows + schema: + type: boolean + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedInvitationStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_invitation_stages_create + description: InvitationStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/InvitationStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/InvitationStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/invitation/stages/{stage_uuid}/: + get: + operationId: stages_invitation_stages_retrieve + description: InvitationStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/InvitationStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_invitation_stages_update + description: InvitationStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/InvitationStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/InvitationStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_invitation_stages_partial_update + description: InvitationStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedInvitationStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/InvitationStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_invitation_stages_destroy + description: InvitationStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/invitation/stages/{stage_uuid}/used_by/: + get: + operationId: stages_invitation_stages_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Invitation Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/mtls/: + get: + operationId: stages_mtls_list + description: MutualTLSStage Viewset + parameters: + - in: query + name: cert_attribute + schema: + $ref: '#/components/schemas/CertAttributeEnum' + - in: query + name: certificate_authorities + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - in: query + name: mode + schema: + $ref: '#/components/schemas/StageModeEnum' + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + - in: query + name: user_attribute + schema: + $ref: '#/components/schemas/UserAttributeEnum' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedMutualTLSStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_mtls_create + description: MutualTLSStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/MutualTLSStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/MutualTLSStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/mtls/{stage_uuid}/: + get: + operationId: stages_mtls_retrieve + description: MutualTLSStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Mutual TLS Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MutualTLSStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_mtls_update + description: MutualTLSStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Mutual TLS Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/MutualTLSStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MutualTLSStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_mtls_partial_update + description: MutualTLSStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Mutual TLS Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedMutualTLSStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/MutualTLSStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_mtls_destroy + description: MutualTLSStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Mutual TLS Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/mtls/{stage_uuid}/used_by/: + get: + operationId: stages_mtls_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Mutual TLS Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/password/: + get: + operationId: stages_password_list + description: PasswordStage Viewset + parameters: + - in: query + name: allow_show_password + schema: + type: boolean + - in: query + name: configure_flow + schema: + type: string + format: uuid + - in: query + name: failed_attempts_before_cancel + schema: + type: integer + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPasswordStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_password_create + description: PasswordStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/password/{stage_uuid}/: + get: + operationId: stages_password_retrieve + description: PasswordStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_password_update + description: PasswordStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_password_partial_update + description: PasswordStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedPasswordStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PasswordStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_password_destroy + description: PasswordStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/password/{stage_uuid}/used_by/: + get: + operationId: stages_password_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Password Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/prompt/prompts/: + get: + operationId: stages_prompt_prompts_list + description: Prompt Viewset + parameters: + - in: query + name: field_key + schema: + type: string + - in: query + name: label + schema: + type: string + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: placeholder + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: type + schema: + $ref: '#/components/schemas/PromptTypeEnum' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPromptList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_prompt_prompts_create + description: Prompt Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PromptRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Prompt' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/prompt/prompts/{prompt_uuid}/: + get: + operationId: stages_prompt_prompts_retrieve + description: Prompt Viewset + parameters: + - in: path + name: prompt_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Prompt' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_prompt_prompts_update + description: Prompt Viewset + parameters: + - in: path + name: prompt_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PromptRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Prompt' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_prompt_prompts_partial_update + description: Prompt Viewset + parameters: + - in: path + name: prompt_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedPromptRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Prompt' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_prompt_prompts_destroy + description: Prompt Viewset + parameters: + - in: path + name: prompt_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/prompt/prompts/{prompt_uuid}/used_by/: + get: + operationId: stages_prompt_prompts_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: prompt_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/prompt/prompts/preview/: + post: + operationId: stages_prompt_prompts_preview_create + description: Preview a prompt as a challenge, just like a flow would receive + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PromptRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PromptChallenge' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/prompt/stages/: + get: + operationId: stages_prompt_stages_list + description: PromptStage Viewset + parameters: + - in: query + name: fields + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + - in: query + name: validation_policies + schema: + type: array + items: + type: string + format: uuid + explode: true + style: form + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedPromptStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_prompt_stages_create + description: PromptStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PromptStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/PromptStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/prompt/stages/{stage_uuid}/: + get: + operationId: stages_prompt_stages_retrieve + description: PromptStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PromptStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_prompt_stages_update + description: PromptStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PromptStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PromptStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_prompt_stages_partial_update + description: PromptStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedPromptStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PromptStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_prompt_stages_destroy + description: PromptStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/prompt/stages/{stage_uuid}/used_by/: + get: + operationId: stages_prompt_stages_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Prompt Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/redirect/: + get: + operationId: stages_redirect_list + description: RedirectStage Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedRedirectStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_redirect_create + description: RedirectStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RedirectStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/RedirectStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/redirect/{stage_uuid}/: + get: + operationId: stages_redirect_retrieve + description: RedirectStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Redirect Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RedirectStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_redirect_update + description: RedirectStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Redirect Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RedirectStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RedirectStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_redirect_partial_update + description: RedirectStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Redirect Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedRedirectStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/RedirectStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_redirect_destroy + description: RedirectStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Redirect Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/redirect/{stage_uuid}/used_by/: + get: + operationId: stages_redirect_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Redirect Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/source/: + get: + operationId: stages_source_list + description: SourceStage Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: resume_timeout + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: source + schema: + type: string + format: uuid + - in: query + name: stage_uuid + schema: + type: string + format: uuid + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedSourceStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_source_create + description: SourceStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SourceStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/SourceStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/source/{stage_uuid}/: + get: + operationId: stages_source_retrieve + description: SourceStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Source Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SourceStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_source_update + description: SourceStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Source Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SourceStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SourceStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_source_partial_update + description: SourceStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Source Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedSourceStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/SourceStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_source_destroy + description: SourceStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Source Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/source/{stage_uuid}/used_by/: + get: + operationId: stages_source_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Source Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_delete/: + get: + operationId: stages_user_delete_list + description: UserDeleteStage Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserDeleteStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_user_delete_create + description: UserDeleteStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserDeleteStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserDeleteStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_delete/{stage_uuid}/: + get: + operationId: stages_user_delete_retrieve + description: UserDeleteStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Delete Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserDeleteStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_user_delete_update + description: UserDeleteStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Delete Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserDeleteStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserDeleteStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_user_delete_partial_update + description: UserDeleteStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Delete Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserDeleteStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserDeleteStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_user_delete_destroy + description: UserDeleteStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Delete Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_delete/{stage_uuid}/used_by/: + get: + operationId: stages_user_delete_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Delete Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_login/: + get: + operationId: stages_user_login_list + description: UserLoginStage Viewset + parameters: + - in: query + name: geoip_binding + schema: + allOf: + - $ref: '#/components/schemas/GeoipBindingEnum' + description: |+ + Bind sessions created by this stage to the configured GeoIP location + + - $ref: '#/components/parameters/QueryName' + - in: query + name: network_binding + schema: + allOf: + - $ref: '#/components/schemas/NetworkBindingEnum' + description: |+ + Bind sessions created by this stage to the configured network + + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: remember_device + schema: + type: string + - in: query + name: remember_me_offset + schema: + type: string + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: session_duration + schema: + type: string + - in: query + name: stage_uuid + schema: + type: string + format: uuid + - in: query + name: terminate_other_sessions + schema: + type: boolean + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserLoginStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_user_login_create + description: UserLoginStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserLoginStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLoginStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_login/{stage_uuid}/: + get: + operationId: stages_user_login_retrieve + description: UserLoginStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Login Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLoginStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_user_login_update + description: UserLoginStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Login Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserLoginStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLoginStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_user_login_partial_update + description: UserLoginStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Login Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserLoginStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLoginStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_user_login_destroy + description: UserLoginStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Login Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_login/{stage_uuid}/used_by/: + get: + operationId: stages_user_login_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Login Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_logout/: + get: + operationId: stages_user_logout_list + description: UserLogoutStage Viewset + parameters: + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserLogoutStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_user_logout_create + description: UserLogoutStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserLogoutStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLogoutStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_logout/{stage_uuid}/: + get: + operationId: stages_user_logout_retrieve + description: UserLogoutStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Logout Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLogoutStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_user_logout_update + description: UserLogoutStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Logout Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserLogoutStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLogoutStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_user_logout_partial_update + description: UserLogoutStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Logout Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserLogoutStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserLogoutStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_user_logout_destroy + description: UserLogoutStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Logout Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_logout/{stage_uuid}/used_by/: + get: + operationId: stages_user_logout_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Logout Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_write/: + get: + operationId: stages_user_write_list + description: UserWriteStage Viewset + parameters: + - in: query + name: create_users_as_inactive + schema: + type: boolean + - in: query + name: create_users_group + schema: + type: string + format: uuid + - $ref: '#/components/parameters/QueryName' + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: stage_uuid + schema: + type: string + format: uuid + - in: query + name: user_creation_mode + schema: + $ref: '#/components/schemas/UserCreationModeEnum' + - in: query + name: user_path_template + schema: + type: string + - in: query + name: user_type + schema: + $ref: '#/components/schemas/UserTypeEnum' + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedUserWriteStageList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: stages_user_write_create + description: UserWriteStage Viewset + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserWriteStageRequest' + required: true + security: + - authentik: [] + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/UserWriteStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_write/{stage_uuid}/: + get: + operationId: stages_user_write_retrieve + description: UserWriteStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Write Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserWriteStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: stages_user_write_update + description: UserWriteStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Write Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserWriteStageRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserWriteStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: stages_user_write_partial_update + description: UserWriteStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Write Stage. + required: true + tags: + - stages + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedUserWriteStageRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/UserWriteStage' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: stages_user_write_destroy + description: UserWriteStage Viewset + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Write Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /stages/user_write/{stage_uuid}/used_by/: + get: + operationId: stages_user_write_used_by_list + description: Get a list of all objects that use this object + parameters: + - in: path + name: stage_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this User Write Stage. + required: true + tags: + - stages + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/UsedBy' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tasks/schedules/: + get: + operationId: tasks_schedules_list + parameters: + - in: query + name: actor_name + schema: + type: string + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: paused + schema: + type: boolean + - in: query + name: rel_obj_content_type__app_label + schema: + type: string + - in: query + name: rel_obj_content_type__model + schema: + type: string + - in: query + name: rel_obj_id + schema: + type: string + - in: query + name: rel_obj_id__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QuerySearch' + tags: + - tasks + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedScheduleList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tasks/schedules/{id}/: + get: + operationId: tasks_schedules_retrieve + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Schedule. + required: true + tags: + - tasks + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Schedule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: tasks_schedules_update + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Schedule. + required: true + tags: + - tasks + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ScheduleRequest' + required: true + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Schedule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: tasks_schedules_partial_update + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Schedule. + required: true + tags: + - tasks + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedScheduleRequest' + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Schedule' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tasks/schedules/{id}/send/: + post: + operationId: tasks_schedules_send_create + description: Trigger this schedule now + parameters: + - in: path + name: id + schema: + type: string + format: uuid + description: A UUID string identifying this Schedule. + required: true + tags: + - tasks + security: + - authentik: [] + responses: + '204': + description: Schedule sent successfully + '404': + description: Schedule not found + '500': + description: Failed to send schedule + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tasks/tasks/: + get: + operationId: tasks_tasks_list + parameters: + - in: query + name: actor_name + schema: + type: string + - in: query + name: aggregated_status + schema: + type: array + items: + $ref: '#/components/schemas/TaskAggregatedStatusEnum' + explode: true + style: form + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - in: query + name: queue_name + schema: + type: string + - in: query + name: rel_obj_content_type__app_label + schema: + type: string + - in: query + name: rel_obj_content_type__model + schema: + type: string + - in: query + name: rel_obj_id + schema: + type: string + - in: query + name: rel_obj_id__isnull + schema: + type: boolean + - $ref: '#/components/parameters/QuerySearch' + - in: query + name: state + schema: + allOf: + - $ref: '#/components/schemas/TaskStatusEnum' + description: |+ + Task status + + tags: + - tasks + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedTaskList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tasks/tasks/{message_id}/: + get: + operationId: tasks_tasks_retrieve + parameters: + - in: path + name: message_id + schema: + type: string + format: uuid + description: A UUID string identifying this Task. + required: true + tags: + - tasks + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Task' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tasks/tasks/{message_id}/retry/: + post: + operationId: tasks_tasks_retry_create + description: Retry task + parameters: + - in: path + name: message_id + schema: + type: string + format: uuid + description: A UUID string identifying this Task. + required: true + tags: + - tasks + security: + - authentik: [] + responses: + '204': + description: Task retried successfully + '400': + description: Task is not in a retryable state + '404': + description: Task not found + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tasks/tasks/status/: + get: + operationId: tasks_tasks_status_retrieve + description: Global status summary for all tasks + tags: + - tasks + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/GlobalTaskStatus' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tasks/workers/: + get: + operationId: tasks_workers_list + description: Get currently connected worker count. + tags: + - tasks + security: + - authentik: [] + responses: + '200': + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/Worker' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tenants/domains/: + get: + operationId: tenants_domains_list + description: Domain ViewSet + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - tenants + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedDomainList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: tenants_domains_create + description: Domain ViewSet + tags: + - tenants + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DomainRequest' + required: true + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Domain' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tenants/domains/{id}/: + get: + operationId: tenants_domains_retrieve + description: Domain ViewSet + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Domain. + required: true + tags: + - tenants + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Domain' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: tenants_domains_update + description: Domain ViewSet + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Domain. + required: true + tags: + - tenants + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/DomainRequest' + required: true + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Domain' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: tenants_domains_partial_update + description: Domain ViewSet + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Domain. + required: true + tags: + - tenants + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedDomainRequest' + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Domain' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: tenants_domains_destroy + description: Domain ViewSet + parameters: + - in: path + name: id + schema: + type: integer + description: A unique integer value identifying this Domain. + required: true + tags: + - tenants + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tenants/tenants/: + get: + operationId: tenants_tenants_list + description: Tenant Viewset + parameters: + - $ref: '#/components/parameters/QueryPaginationOrdering' + - $ref: '#/components/parameters/QueryPaginationPage' + - $ref: '#/components/parameters/QueryPaginationPageSize' + - $ref: '#/components/parameters/QuerySearch' + tags: + - tenants + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/PaginatedTenantList' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + post: + operationId: tenants_tenants_create + description: Tenant Viewset + tags: + - tenants + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TenantRequest' + required: true + responses: + '201': + content: + application/json: + schema: + $ref: '#/components/schemas/Tenant' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tenants/tenants/{tenant_uuid}/: + get: + operationId: tenants_tenants_retrieve + description: Tenant Viewset + parameters: + - in: path + name: tenant_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Tenant. + required: true + tags: + - tenants + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Tenant' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + put: + operationId: tenants_tenants_update + description: Tenant Viewset + parameters: + - in: path + name: tenant_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Tenant. + required: true + tags: + - tenants + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TenantRequest' + required: true + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Tenant' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + patch: + operationId: tenants_tenants_partial_update + description: Tenant Viewset + parameters: + - in: path + name: tenant_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Tenant. + required: true + tags: + - tenants + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PatchedTenantRequest' + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/Tenant' + description: '' + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + delete: + operationId: tenants_tenants_destroy + description: Tenant Viewset + parameters: + - in: path + name: tenant_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Tenant. + required: true + tags: + - tenants + responses: + '204': + description: No response body + '400': + $ref: '#/components/responses/ValidationErrorResponse' + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tenants/tenants/{tenant_uuid}/create_admin_group/: + post: + operationId: tenants_tenants_create_admin_group_create + description: Create admin group and add user to it. + parameters: + - in: path + name: tenant_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Tenant. + required: true + tags: + - tenants + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TenantAdminGroupRequestRequest' + required: true + responses: + '204': + description: Group created successfully. + '400': + description: Bad request + '404': + description: User not found + '403': + $ref: '#/components/responses/GenericErrorResponse' + /tenants/tenants/{tenant_uuid}/create_recovery_key/: + post: + operationId: tenants_tenants_create_recovery_key_create + description: Create recovery key for user. + parameters: + - in: path + name: tenant_uuid + schema: + type: string + format: uuid + description: A UUID string identifying this Tenant. + required: true + tags: + - tenants + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TenantRecoveryKeyRequestRequest' + required: true + responses: + '200': + content: + application/json: + schema: + $ref: '#/components/schemas/TenantRecoveryKeyResponse' + description: '' + '400': + description: Bad request + '404': + description: User not found + '403': + $ref: '#/components/responses/GenericErrorResponse' +components: + parameters: + QueryName: + in: query + name: name + schema: + type: string + QueryPaginationOrdering: + in: query + name: ordering + schema: + type: string + description: Which field to use when ordering the results. + QueryPaginationPage: + in: query + name: page + schema: + type: integer + description: A page number within the paginated result set. + QueryPaginationPageSize: + in: query + name: page_size + schema: + type: integer + description: Number of results to return per page. + QuerySearch: + in: query + name: search + schema: + type: string + description: A search term. + responses: + GenericErrorResponse: + content: + application/json: + schema: + $ref: '#/components/schemas/GenericError' + description: '' + ValidationErrorResponse: + content: + application/json: + schema: + $ref: '#/components/schemas/ValidationError' + description: '' + schemas: + AccessDeniedChallenge: + type: object + description: Challenge when a flow's active stage calls `stage_invalid()`. + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-access-denied + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + error_message: + type: string + required: + - pending_user + - pending_user_avatar + AccountLockdownStage: + type: object + description: AccountLockdownStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + deactivate_user: + type: boolean + description: Deactivate the user account (set is_active to False) + set_unusable_password: + type: boolean + description: Set an unusable password for the user + delete_sessions: + type: boolean + description: Delete all active sessions for the user + revoke_tokens: + type: boolean + description: Revoke all tokens for the user (API, app password, recovery, + verification, OAuth) + self_service_completion_flow: + type: string + format: uuid + nullable: true + description: Flow to redirect users to after self-service lockdown. This + flow should not require authentication since the user's session is deleted. + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + AccountLockdownStageRequest: + type: object + description: AccountLockdownStage Serializer + properties: + name: + type: string + minLength: 1 + deactivate_user: + type: boolean + description: Deactivate the user account (set is_active to False) + set_unusable_password: + type: boolean + description: Set an unusable password for the user + delete_sessions: + type: boolean + description: Delete all active sessions for the user + revoke_tokens: + type: boolean + description: Revoke all tokens for the user (API, app password, recovery, + verification, OAuth) + self_service_completion_flow: + type: string + format: uuid + nullable: true + description: Flow to redirect users to after self-service lockdown. This + flow should not require authentication since the user's session is deleted. + required: + - name + AgentAuthenticationResponse: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + url: + type: string + required: + - url + AgentConfig: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + device_id: + type: string + readOnly: true + refresh_interval: + type: integer + readOnly: true + authorization_flow: + type: string + nullable: true + readOnly: true + jwks_auth: + type: object + additionalProperties: {} + readOnly: true + jwks_challenge: + type: object + additionalProperties: {} + nullable: true + readOnly: true + nss_uid_offset: + type: integer + nss_gid_offset: + type: integer + auth_terminate_session_on_expiry: + type: boolean + system_config: + allOf: + - $ref: '#/components/schemas/Config' + readOnly: true + license_status: + allOf: + - $ref: '#/components/schemas/LicenseStatusEnum' + readOnly: true + nullable: true + required: + - auth_terminate_session_on_expiry + - authorization_flow + - device_id + - jwks_auth + - jwks_challenge + - license_status + - nss_gid_offset + - nss_uid_offset + - refresh_interval + - system_config + AgentConnector: + type: object + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + enabled: + type: boolean + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + snapshot_expiry: + type: string + auth_session_duration: + type: string + auth_terminate_session_on_expiry: + type: boolean + refresh_interval: + type: string + authorization_flow: + type: string + format: uuid + nullable: true + nss_uid_offset: + type: integer + maximum: 2147483647 + minimum: 0 + nss_gid_offset: + type: integer + maximum: 2147483647 + minimum: 0 + challenge_key: + type: string + format: uuid + nullable: true + challenge_idle_timeout: + type: string + challenge_trigger_check_in: + type: boolean + jwt_federation_providers: + type: array + items: + type: integer + required: + - component + - meta_model_name + - name + - verbose_name + - verbose_name_plural + AgentConnectorRequest: + type: object + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + minLength: 1 + enabled: + type: boolean + snapshot_expiry: + type: string + minLength: 1 + auth_session_duration: + type: string + minLength: 1 + auth_terminate_session_on_expiry: + type: boolean + refresh_interval: + type: string + minLength: 1 + authorization_flow: + type: string + format: uuid + nullable: true + nss_uid_offset: + type: integer + maximum: 2147483647 + minimum: 0 + nss_gid_offset: + type: integer + maximum: 2147483647 + minimum: 0 + challenge_key: + type: string + format: uuid + nullable: true + challenge_idle_timeout: + type: string + minLength: 1 + challenge_trigger_check_in: + type: boolean + jwt_federation_providers: + type: array + items: + type: integer + required: + - name + AgentPSSODeviceRegistrationRequest: + type: object + description: Register Apple device via Platform SSO + properties: + device_signing_key: + type: string + minLength: 1 + device_encryption_key: + type: string + minLength: 1 + sign_key_id: + type: string + minLength: 1 + enc_key_id: + type: string + minLength: 1 + required: + - device_encryption_key + - device_signing_key + - enc_key_id + - sign_key_id + AgentPSSODeviceRegistrationResponse: + type: object + description: authentik settings for Platform SSO tokens + properties: + client_id: + type: string + issuer: + type: string + token_endpoint: + type: string + jwks_endpoint: + type: string + audience: + type: string + nonce_endpoint: + type: string + required: + - audience + - client_id + - issuer + - jwks_endpoint + - nonce_endpoint + - token_endpoint + AgentPSSOUserRegistrationRequest: + type: object + description: Register Apple device user via Platform SSO + properties: + user_auth: + type: string + minLength: 1 + user_secure_enclave_key: + type: string + minLength: 1 + enclave_key_id: + type: string + minLength: 1 + required: + - enclave_key_id + - user_auth + - user_secure_enclave_key + AgentTokenResponse: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + token: + type: string + expires_in: + type: integer + required: + - token + AlgEnum: + enum: + - rsa + - ecdsa + - ed25519 + - ed448 + type: string + App: + type: object + description: Serialize Application info + properties: + name: + type: string + label: + type: string + required: + - label + - name + AppEnum: + enum: + - authentik.commands + - authentik.tenants + - authentik.tasks + - authentik.admin + - authentik.api + - authentik.core + - authentik.crypto + - authentik.endpoints + - authentik.endpoints.connectors.agent + - authentik.enterprise + - authentik.events + - authentik.admin.files + - authentik.flows + - authentik.outposts + - authentik.policies.dummy + - authentik.policies.event_matcher + - authentik.policies.expiry + - authentik.policies.expression + - authentik.policies.geoip + - authentik.policies.password + - authentik.policies.reputation + - authentik.policies + - authentik.providers.ldap + - authentik.providers.oauth2 + - authentik.providers.proxy + - authentik.providers.rac + - authentik.providers.radius + - authentik.providers.saml + - authentik.providers.scim + - authentik.rbac + - authentik.recovery + - authentik.sources.kerberos + - authentik.sources.ldap + - authentik.sources.oauth + - authentik.sources.plex + - authentik.sources.saml + - authentik.sources.scim + - authentik.sources.telegram + - authentik.stages.authenticator + - authentik.stages.authenticator_duo + - authentik.stages.authenticator_email + - authentik.stages.authenticator_sms + - authentik.stages.authenticator_static + - authentik.stages.authenticator_totp + - authentik.stages.authenticator_validate + - authentik.stages.authenticator_webauthn + - authentik.stages.captcha + - authentik.stages.consent + - authentik.stages.deny + - authentik.stages.dummy + - authentik.stages.email + - authentik.stages.identification + - authentik.stages.invitation + - authentik.stages.password + - authentik.stages.prompt + - authentik.stages.redirect + - authentik.stages.user_delete + - authentik.stages.user_login + - authentik.stages.user_logout + - authentik.stages.user_write + - authentik.tasks.schedules + - authentik.brands + - authentik.blueprints + - authentik.enterprise.audit + - authentik.enterprise.endpoints.connectors.agent + - authentik.enterprise.endpoints.connectors.fleet + - authentik.enterprise.endpoints.connectors.google_chrome + - authentik.enterprise.lifecycle + - authentik.enterprise.policies.unique_password + - authentik.enterprise.providers.google_workspace + - authentik.enterprise.providers.microsoft_entra + - authentik.enterprise.providers.radius + - authentik.enterprise.providers.scim + - authentik.enterprise.providers.ssf + - authentik.enterprise.providers.ws_federation + - authentik.enterprise.reports + - authentik.enterprise.stages.account_lockdown + - authentik.enterprise.stages.authenticator_endpoint_gdtc + - authentik.enterprise.stages.mtls + - authentik.enterprise.stages.source + type: string + AppleChallengeResponseRequest: + type: object + description: Pseudo class for apple response + properties: + component: + type: string + minLength: 1 + default: ak-source-oauth-apple + AppleIndependentSecureEnclave: + type: object + properties: + uuid: + type: string + format: uuid + user: + type: integer + description: The user that this device belongs to. + apple_secure_enclave_key: + type: string + apple_enclave_key_id: + type: string + device_type: + type: string + required: + - apple_enclave_key_id + - apple_secure_enclave_key + - device_type + - user + AppleIndependentSecureEnclaveRequest: + type: object + properties: + uuid: + type: string + format: uuid + user: + type: integer + description: The user that this device belongs to. + apple_secure_enclave_key: + type: string + minLength: 1 + apple_enclave_key_id: + type: string + minLength: 1 + device_type: + type: string + minLength: 1 + required: + - apple_enclave_key_id + - apple_secure_enclave_key + - device_type + - user + AppleLoginChallenge: + type: object + description: Special challenge for apple-native authentication flow, which happens + on the client. + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-source-oauth-apple + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + client_id: + type: string + scope: + type: string + redirect_uri: + type: string + state: + type: string + required: + - client_id + - redirect_uri + - scope + - state + Application: + type: object + description: Application Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + description: Application's display Name. + slug: + type: string + description: Internal application name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + provider: + type: integer + nullable: true + provider_obj: + allOf: + - $ref: '#/components/schemas/Provider' + readOnly: true + nullable: true + backchannel_providers: + type: array + items: + type: integer + backchannel_providers_obj: + type: array + items: + $ref: '#/components/schemas/Provider' + readOnly: true + launch_url: + type: string + nullable: true + description: Allow formatting of launch URL + readOnly: true + open_in_new_tab: + type: boolean + description: Open launch URL in a new browser tab or window. + meta_launch_url: + type: string + format: uri + meta_icon: + type: string + meta_icon_url: + type: string + nullable: true + description: Get the URL to the App Icon image + readOnly: true + meta_icon_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + meta_description: + type: string + meta_publisher: + type: string + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + group: + type: string + meta_hide: + type: boolean + description: Hide this application from the user's My applications page. + required: + - backchannel_providers_obj + - launch_url + - meta_icon_themed_urls + - meta_icon_url + - name + - pk + - provider_obj + - slug + ApplicationEntitlement: + type: object + description: ApplicationEntitlement Serializer + properties: + pbm_uuid: + type: string + format: uuid + readOnly: true + name: + type: string + app: + type: string + format: uuid + attributes: + type: object + additionalProperties: {} + required: + - app + - name + - pbm_uuid + ApplicationEntitlementRequest: + type: object + description: ApplicationEntitlement Serializer + properties: + name: + type: string + minLength: 1 + app: + type: string + format: uuid + attributes: + type: object + additionalProperties: {} + required: + - app + - name + ApplicationRequest: + type: object + description: Application Serializer + properties: + name: + type: string + minLength: 1 + description: Application's display Name. + slug: + type: string + minLength: 1 + description: Internal application name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + provider: + type: integer + nullable: true + backchannel_providers: + type: array + items: + type: integer + open_in_new_tab: + type: boolean + description: Open launch URL in a new browser tab or window. + meta_launch_url: + type: string + format: uri + meta_icon: + type: string + meta_description: + type: string + meta_publisher: + type: string + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + group: + type: string + meta_hide: + type: boolean + description: Hide this application from the user's My applications page. + required: + - name + - slug + AuthTypeEnum: + enum: + - basic + - bearer + type: string + AuthenticatedSession: + type: object + description: AuthenticatedSession Serializer + properties: + uuid: + type: string + format: uuid + current: + type: boolean + description: Check if session is currently active session + readOnly: true + user_agent: + type: object + description: Get parsed user agent + properties: + device: + type: object + description: User agent device + properties: + brand: + type: string + nullable: true + family: + type: string + model: + type: string + nullable: true + required: + - brand + - family + - model + os: + type: object + description: User agent os + properties: + family: + type: string + major: + type: string + nullable: true + minor: + type: string + nullable: true + patch: + type: string + nullable: true + patch_minor: + type: string + nullable: true + required: + - family + - major + - minor + - patch + - patch_minor + user_agent: + type: object + description: User agent browser + properties: + family: + type: string + major: + type: string + minor: + type: string + patch: + type: string + required: + - family + - major + - minor + - patch + string: + type: string + required: + - device + - os + - string + - user_agent + readOnly: true + geo_ip: + type: object + description: Get GeoIP Data + properties: + continent: + type: string + nullable: true + country: + type: string + nullable: true + lat: + type: number + format: double + nullable: true + long: + type: number + format: double + nullable: true + city: + type: string + required: + - city + - continent + - country + - lat + - long + nullable: true + readOnly: true + asn: + type: object + description: Get ASN Data + properties: + asn: + type: integer + nullable: true + as_org: + type: string + nullable: true + network: + type: string + nullable: true + required: + - as_org + - asn + - network + nullable: true + readOnly: true + user: + type: integer + last_ip: + type: string + readOnly: true + last_user_agent: + type: string + readOnly: true + last_used: + type: string + format: date-time + readOnly: true + expires: + type: string + format: date-time + readOnly: true + required: + - asn + - current + - expires + - geo_ip + - last_ip + - last_used + - last_user_agent + - user + - user_agent + AuthenticationEnum: + enum: + - none + - require_authenticated + - require_unauthenticated + - require_superuser + - require_redirect + - require_outpost + - require_token + type: string + AuthenticatorAttachmentEnum: + enum: + - platform + - cross-platform + type: string + AuthenticatorDuoChallenge: + type: object + description: Duo Challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-authenticator-duo + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + activation_barcode: + type: string + activation_code: + type: string + stage_uuid: + type: string + required: + - activation_barcode + - activation_code + - pending_user + - pending_user_avatar + - stage_uuid + AuthenticatorDuoChallengeResponseRequest: + type: object + description: Pseudo class for duo response + properties: + component: + type: string + minLength: 1 + default: ak-stage-authenticator-duo + AuthenticatorDuoStage: + type: object + description: AuthenticatorDuoStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + client_id: + type: string + api_hostname: + type: string + admin_integration_key: + type: string + required: + - api_hostname + - client_id + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + AuthenticatorDuoStageDeviceImportResponse: + type: object + properties: + count: + type: integer + readOnly: true + error: + type: string + readOnly: true + required: + - count + - error + AuthenticatorDuoStageManualDeviceImportRequest: + type: object + properties: + duo_user_id: + type: string + minLength: 1 + username: + type: string + minLength: 1 + required: + - duo_user_id + - username + AuthenticatorDuoStageRequest: + type: object + description: AuthenticatorDuoStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + client_id: + type: string + minLength: 1 + client_secret: + type: string + writeOnly: true + minLength: 1 + api_hostname: + type: string + minLength: 1 + admin_integration_key: + type: string + admin_secret_key: + type: string + writeOnly: true + required: + - api_hostname + - client_id + - client_secret + - name + AuthenticatorEmailChallenge: + type: object + description: Authenticator Email Setup challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-authenticator-email + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + email: + type: string + nullable: true + email_required: + type: boolean + default: true + required: + - pending_user + - pending_user_avatar + AuthenticatorEmailChallengeResponseRequest: + type: object + description: Authenticator Email Challenge response, device is set by get_response_instance + properties: + component: + type: string + minLength: 1 + default: ak-stage-authenticator-email + code: + type: string + minLength: 1 + email: + type: string + minLength: 1 + AuthenticatorEmailStage: + type: object + description: AuthenticatorEmailStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + use_global_settings: + type: boolean + description: When enabled, global Email connection settings will be used + and connection settings below will be ignored. + host: + type: string + port: + type: integer + maximum: 2147483647 + minimum: -2147483648 + username: + type: string + use_tls: + type: boolean + use_ssl: + type: boolean + timeout: + type: integer + maximum: 2147483647 + minimum: -2147483648 + from_address: + type: string + format: email + maxLength: 254 + subject: + type: string + token_expiry: + type: string + description: 'Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).' + template: + type: string + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + AuthenticatorEmailStageRequest: + type: object + description: AuthenticatorEmailStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + use_global_settings: + type: boolean + description: When enabled, global Email connection settings will be used + and connection settings below will be ignored. + host: + type: string + minLength: 1 + port: + type: integer + maximum: 2147483647 + minimum: -2147483648 + username: + type: string + password: + type: string + writeOnly: true + use_tls: + type: boolean + use_ssl: + type: boolean + timeout: + type: integer + maximum: 2147483647 + minimum: -2147483648 + from_address: + type: string + format: email + minLength: 1 + maxLength: 254 + subject: + type: string + minLength: 1 + token_expiry: + type: string + minLength: 1 + description: 'Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).' + template: + type: string + minLength: 1 + required: + - name + AuthenticatorEndpointGDTCStage: + type: object + description: AuthenticatorEndpointGDTCStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + credentials: + type: object + additionalProperties: {} + required: + - component + - credentials + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + AuthenticatorEndpointGDTCStageRequest: + type: object + description: AuthenticatorEndpointGDTCStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + credentials: + type: object + additionalProperties: {} + required: + - credentials + - name + AuthenticatorSMSChallenge: + type: object + description: SMS Setup challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-authenticator-sms + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + phone_number_required: + type: boolean + default: true + required: + - pending_user + - pending_user_avatar + AuthenticatorSMSChallengeResponseRequest: + type: object + description: SMS Challenge response, device is set by get_response_instance + properties: + component: + type: string + minLength: 1 + default: ak-stage-authenticator-sms + code: + type: string + minLength: 1 + phone_number: + type: string + minLength: 1 + AuthenticatorSMSStage: + type: object + description: AuthenticatorSMSStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + provider: + $ref: '#/components/schemas/ProviderEnum' + from_number: + type: string + account_sid: + type: string + auth_type: + $ref: '#/components/schemas/AuthTypeEnum' + verify_only: + type: boolean + description: When enabled, the Phone number is only used during enrollment + to verify the users authenticity. Only a hash of the phone number is saved + to ensure it is not reused in the future. + mapping: + type: string + format: uuid + nullable: true + description: Optionally modify the payload being sent to custom providers. + required: + - account_sid + - component + - flow_set + - from_number + - meta_model_name + - name + - pk + - provider + - verbose_name + - verbose_name_plural + AuthenticatorSMSStageRequest: + type: object + description: AuthenticatorSMSStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + provider: + $ref: '#/components/schemas/ProviderEnum' + from_number: + type: string + minLength: 1 + account_sid: + type: string + minLength: 1 + auth: + type: string + writeOnly: true + minLength: 1 + auth_password: + type: string + writeOnly: true + auth_type: + $ref: '#/components/schemas/AuthTypeEnum' + verify_only: + type: boolean + description: When enabled, the Phone number is only used during enrollment + to verify the users authenticity. Only a hash of the phone number is saved + to ensure it is not reused in the future. + mapping: + type: string + format: uuid + nullable: true + description: Optionally modify the payload being sent to custom providers. + required: + - account_sid + - auth + - from_number + - name + - provider + AuthenticatorStaticChallenge: + type: object + description: Static authenticator challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-authenticator-static + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + codes: + type: array + items: + type: string + required: + - codes + - pending_user + - pending_user_avatar + AuthenticatorStaticChallengeResponseRequest: + type: object + description: Pseudo class for static response + properties: + component: + type: string + minLength: 1 + default: ak-stage-authenticator-static + AuthenticatorStaticStage: + type: object + description: AuthenticatorStaticStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + token_count: + type: integer + maximum: 2147483647 + minimum: 0 + token_length: + type: integer + maximum: 100 + minimum: 0 + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + AuthenticatorStaticStageRequest: + type: object + description: AuthenticatorStaticStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + token_count: + type: integer + maximum: 2147483647 + minimum: 0 + token_length: + type: integer + maximum: 100 + minimum: 0 + required: + - name + AuthenticatorTOTPChallenge: + type: object + description: TOTP Setup challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-authenticator-totp + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + config_url: + type: string + required: + - config_url + - pending_user + - pending_user_avatar + AuthenticatorTOTPChallengeResponseRequest: + type: object + description: TOTP Challenge response, device is set by get_response_instance + properties: + component: + type: string + minLength: 1 + default: ak-stage-authenticator-totp + code: + type: string + minLength: 1 + required: + - code + AuthenticatorTOTPStage: + type: object + description: AuthenticatorTOTPStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + digits: + $ref: '#/components/schemas/DigitsEnum' + required: + - component + - digits + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + AuthenticatorTOTPStageRequest: + type: object + description: AuthenticatorTOTPStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + digits: + $ref: '#/components/schemas/DigitsEnum' + required: + - digits + - name + AuthenticatorValidateStage: + type: object + description: AuthenticatorValidateStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + not_configured_action: + $ref: '#/components/schemas/NotConfiguredActionEnum' + device_classes: + type: array + items: + $ref: '#/components/schemas/DeviceClassesEnum' + description: Device classes which can be used to authenticate + configuration_stages: + type: array + items: + type: string + format: uuid + description: Stages used to configure Authenticator when user doesn't have + any compatible devices. After this configuration Stage passes, the user + is not prompted again. + last_auth_threshold: + type: string + description: If any of the user's device has been used within this threshold, + this stage will be skipped + webauthn_user_verification: + allOf: + - $ref: '#/components/schemas/UserVerificationEnum' + description: Enforce user verification for WebAuthn devices. + webauthn_hints: + type: array + items: + $ref: '#/components/schemas/WebAuthnHintEnum' + webauthn_allowed_device_types: + type: array + items: + type: string + format: uuid + webauthn_allowed_device_types_obj: + type: array + items: + $ref: '#/components/schemas/WebAuthnDeviceType' + readOnly: true + email_otp_throttling_factor: + type: number + format: double + sms_otp_throttling_factor: + type: number + format: double + totp_otp_throttling_factor: + type: number + format: double + static_otp_throttling_factor: + type: number + format: double + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + - webauthn_allowed_device_types_obj + AuthenticatorValidateStageRequest: + type: object + description: AuthenticatorValidateStage Serializer + properties: + name: + type: string + minLength: 1 + not_configured_action: + $ref: '#/components/schemas/NotConfiguredActionEnum' + device_classes: + type: array + items: + $ref: '#/components/schemas/DeviceClassesEnum' + description: Device classes which can be used to authenticate + configuration_stages: + type: array + items: + type: string + format: uuid + description: Stages used to configure Authenticator when user doesn't have + any compatible devices. After this configuration Stage passes, the user + is not prompted again. + last_auth_threshold: + type: string + minLength: 1 + description: If any of the user's device has been used within this threshold, + this stage will be skipped + webauthn_user_verification: + allOf: + - $ref: '#/components/schemas/UserVerificationEnum' + description: Enforce user verification for WebAuthn devices. + webauthn_hints: + type: array + items: + $ref: '#/components/schemas/WebAuthnHintEnum' + webauthn_allowed_device_types: + type: array + items: + type: string + format: uuid + email_otp_throttling_factor: + type: number + format: double + sms_otp_throttling_factor: + type: number + format: double + totp_otp_throttling_factor: + type: number + format: double + static_otp_throttling_factor: + type: number + format: double + required: + - name + AuthenticatorValidationChallenge: + type: object + description: Authenticator challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-authenticator-validate + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + device_challenges: + type: array + items: + $ref: '#/components/schemas/DeviceChallenge' + configuration_stages: + type: array + items: + $ref: '#/components/schemas/SelectableStage' + required: + - configuration_stages + - device_challenges + - pending_user + - pending_user_avatar + AuthenticatorValidationChallengeResponseRequest: + type: object + description: Challenge used for Code-based and WebAuthn authenticators + properties: + component: + type: string + minLength: 1 + default: ak-stage-authenticator-validate + selected_challenge: + $ref: '#/components/schemas/DeviceChallengeRequest' + selected_stage: + type: string + minLength: 1 + code: + type: string + minLength: 1 + webauthn: + type: object + additionalProperties: {} + duo: + type: integer + AuthenticatorWebAuthnChallenge: + type: object + description: WebAuthn Challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-authenticator-webauthn + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + registration: + type: object + additionalProperties: {} + required: + - pending_user + - pending_user_avatar + - registration + AuthenticatorWebAuthnChallengeResponseRequest: + type: object + description: WebAuthn Challenge response + properties: + component: + type: string + minLength: 1 + default: ak-stage-authenticator-webauthn + response: + type: object + additionalProperties: {} + required: + - response + AuthenticatorWebAuthnStage: + type: object + description: AuthenticatorWebAuthnStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + user_verification: + $ref: '#/components/schemas/UserVerificationEnum' + authenticator_attachment: + allOf: + - $ref: '#/components/schemas/AuthenticatorAttachmentEnum' + nullable: true + resident_key_requirement: + $ref: '#/components/schemas/UserVerificationEnum' + hints: + type: array + items: + $ref: '#/components/schemas/WebAuthnHintEnum' + device_type_restrictions: + type: array + items: + type: string + format: uuid + device_type_restrictions_obj: + type: array + items: + $ref: '#/components/schemas/WebAuthnDeviceType' + readOnly: true + prevent_duplicate_devices: + type: boolean + description: When enabled, a given device can only be registered once. + max_attempts: + type: integer + maximum: 2147483647 + minimum: 0 + required: + - component + - device_type_restrictions_obj + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + AuthenticatorWebAuthnStageRequest: + type: object + description: AuthenticatorWebAuthnStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + user_verification: + $ref: '#/components/schemas/UserVerificationEnum' + authenticator_attachment: + allOf: + - $ref: '#/components/schemas/AuthenticatorAttachmentEnum' + nullable: true + resident_key_requirement: + $ref: '#/components/schemas/UserVerificationEnum' + hints: + type: array + items: + $ref: '#/components/schemas/WebAuthnHintEnum' + device_type_restrictions: + type: array + items: + type: string + format: uuid + prevent_duplicate_devices: + type: boolean + description: When enabled, a given device can only be registered once. + max_attempts: + type: integer + maximum: 2147483647 + minimum: 0 + required: + - name + AuthorizationCodeAuthMethodEnum: + enum: + - basic_auth + - post_body + type: string + AutoSubmitChallengeResponseRequest: + type: object + description: Pseudo class for autosubmit response + properties: + component: + type: string + minLength: 1 + default: ak-stage-autosubmit + Autocomplete: + type: object + additionalProperties: {} + AutosubmitChallenge: + type: object + description: Autosubmit challenge used to send and navigate a POST request + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-autosubmit + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + url: + type: string + attrs: + type: object + additionalProperties: + type: string + title: + type: string + required: + - attrs + - url + BackendsEnum: + enum: + - authentik.core.auth.InbuiltBackend + - authentik.core.auth.TokenBackend + - authentik.sources.ldap.auth.LDAPBackend + - authentik.sources.kerberos.auth.KerberosBackend + type: string + BindingTypeEnum: + enum: + - REDIRECT + - POST + - POST_AUTO + type: string + BlueprintFile: + type: object + properties: + path: + type: string + last_m: + type: string + format: date-time + hash: + type: string + meta: + allOf: + - $ref: '#/components/schemas/Metadata' + readOnly: true + required: + - hash + - last_m + - meta + - path + BlueprintImportResult: + type: object + description: Logs of an attempted blueprint import + properties: + logs: + type: array + items: + $ref: '#/components/schemas/LogEvent' + readOnly: true + success: + type: boolean + readOnly: true + required: + - logs + - success + BlueprintInstance: + type: object + description: Info about a single blueprint instance file + properties: + pk: + type: string + format: uuid + readOnly: true + title: Instance uuid + name: + type: string + path: + type: string + default: '' + context: + type: object + additionalProperties: {} + last_applied: + type: string + format: date-time + readOnly: true + last_applied_hash: + type: string + readOnly: true + status: + allOf: + - $ref: '#/components/schemas/BlueprintInstanceStatusEnum' + readOnly: true + enabled: + type: boolean + managed_models: + type: array + items: + type: string + readOnly: true + metadata: + type: object + additionalProperties: {} + readOnly: true + content: + type: string + required: + - last_applied + - last_applied_hash + - managed_models + - metadata + - name + - pk + - status + BlueprintInstanceRequest: + type: object + description: Info about a single blueprint instance file + properties: + name: + type: string + minLength: 1 + path: + type: string + default: '' + context: + type: object + additionalProperties: {} + enabled: + type: boolean + content: + type: string + required: + - name + BlueprintInstanceStatusEnum: + enum: + - successful + - warning + - error + - orphaned + - unknown + type: string + BlueprintUploadRequest: + type: object + description: Serializer to upload file + properties: + file: + type: string + format: binary + path: + type: string + minLength: 1 + context: + type: string + Brand: + type: object + description: Brand Serializer + properties: + brand_uuid: + type: string + format: uuid + readOnly: true + domain: + type: string + description: Domain that activates this brand. Can be a superset, i.e. `a.b` + for `aa.b` and `ba.b` + default: + type: boolean + branding_title: + type: string + branding_logo: + type: string + branding_favicon: + type: string + branding_custom_css: + type: string + branding_default_flow_background: + type: string + flow_authentication: + type: string + format: uuid + nullable: true + flow_invalidation: + type: string + format: uuid + nullable: true + flow_recovery: + type: string + format: uuid + nullable: true + flow_unenrollment: + type: string + format: uuid + nullable: true + flow_user_settings: + type: string + format: uuid + nullable: true + flow_device_code: + type: string + format: uuid + nullable: true + flow_lockdown: + type: string + format: uuid + nullable: true + default_application: + type: string + format: uuid + nullable: true + description: When set, external users will be redirected to this application + after authenticating. + web_certificate: + type: string + format: uuid + nullable: true + description: Web Certificate used by the authentik Core webserver. + client_certificates: + type: array + items: + type: string + format: uuid + description: Certificates used for client authentication. + attributes: + type: object + additionalProperties: {} + required: + - brand_uuid + - domain + BrandRequest: + type: object + description: Brand Serializer + properties: + domain: + type: string + minLength: 1 + description: Domain that activates this brand. Can be a superset, i.e. `a.b` + for `aa.b` and `ba.b` + default: + type: boolean + branding_title: + type: string + minLength: 1 + branding_logo: + type: string + minLength: 1 + branding_favicon: + type: string + minLength: 1 + branding_custom_css: + type: string + branding_default_flow_background: + type: string + minLength: 1 + flow_authentication: + type: string + format: uuid + nullable: true + flow_invalidation: + type: string + format: uuid + nullable: true + flow_recovery: + type: string + format: uuid + nullable: true + flow_unenrollment: + type: string + format: uuid + nullable: true + flow_user_settings: + type: string + format: uuid + nullable: true + flow_device_code: + type: string + format: uuid + nullable: true + flow_lockdown: + type: string + format: uuid + nullable: true + default_application: + type: string + format: uuid + nullable: true + description: When set, external users will be redirected to this application + after authenticating. + web_certificate: + type: string + format: uuid + nullable: true + description: Web Certificate used by the authentik Core webserver. + client_certificates: + type: array + items: + type: string + format: uuid + description: Certificates used for client authentication. + attributes: + type: object + additionalProperties: {} + required: + - domain + BulkDeleteSessionResponse: + type: object + properties: + deleted: + type: integer + required: + - deleted + Cache: + type: object + description: Generic cache stats for an object + properties: + count: + type: integer + readOnly: true + required: + - count + CapabilitiesEnum: + enum: + - can_save_media + - can_save_reports + - can_geo_ip + - can_asn + - can_impersonate + - can_debug + - is_enterprise + type: string + CaptchaChallenge: + type: object + description: Site public key + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-captcha + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + site_key: + type: string + js_url: + type: string + interactive: + type: boolean + required: + - interactive + - js_url + - pending_user + - pending_user_avatar + - site_key + CaptchaChallengeResponseRequest: + type: object + description: Validate captcha token + properties: + component: + type: string + minLength: 1 + default: ak-stage-captcha + token: + type: string + minLength: 1 + required: + - token + CaptchaStage: + type: object + description: CaptchaStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + public_key: + type: string + description: Public key, acquired your captcha Provider. + js_url: + type: string + api_url: + type: string + interactive: + type: boolean + score_min_threshold: + type: number + format: double + score_max_threshold: + type: number + format: double + error_on_invalid_score: + type: boolean + description: When enabled and the received captcha score is outside of the + given threshold, the stage will show an error message. When not enabled, + the flow will continue, but the data from the captcha will be available + in the context for policy decisions + required: + - component + - flow_set + - meta_model_name + - name + - pk + - public_key + - verbose_name + - verbose_name_plural + CaptchaStageRequest: + type: object + description: CaptchaStage Serializer + properties: + name: + type: string + minLength: 1 + public_key: + type: string + minLength: 1 + description: Public key, acquired your captcha Provider. + private_key: + type: string + writeOnly: true + minLength: 1 + description: Private key, acquired your captcha Provider. + js_url: + type: string + minLength: 1 + api_url: + type: string + minLength: 1 + interactive: + type: boolean + score_min_threshold: + type: number + format: double + score_max_threshold: + type: number + format: double + error_on_invalid_score: + type: boolean + description: When enabled and the received captcha score is outside of the + given threshold, the stage will show an error message. When not enabled, + the flow will continue, but the data from the captcha will be available + in the context for policy decisions + required: + - name + - private_key + - public_key + CertAttributeEnum: + enum: + - subject + - common_name + - email + type: string + CertificateData: + type: object + description: Get CertificateKeyPair's data + properties: + data: + type: string + readOnly: true + required: + - data + CertificateGenerationRequest: + type: object + description: Certificate generation parameters + properties: + common_name: + type: string + minLength: 1 + subject_alt_name: + type: string + validity_days: + type: integer + alg: + allOf: + - $ref: '#/components/schemas/AlgEnum' + default: rsa + required: + - common_name + - validity_days + CertificateKeyPair: + type: object + description: CertificateKeyPair Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Kp uuid + name: + type: string + fingerprint_sha256: + type: string + readOnly: true + nullable: true + description: SHA256 fingerprint of the certificate + fingerprint_sha1: + type: string + readOnly: true + nullable: true + description: SHA1 fingerprint of the certificate + cert_expiry: + type: string + format: date-time + readOnly: true + nullable: true + description: Certificate expiry date + cert_subject: + type: string + readOnly: true + nullable: true + description: Certificate subject as RFC4514 string + private_key_available: + type: boolean + description: Show if this keypair has a private key configured or not + readOnly: true + key_type: + allOf: + - $ref: '#/components/schemas/CertificateKeyPairKeyTypeEnum' + readOnly: true + nullable: true + description: Key algorithm type detected from the certificate's public key + certificate_download_url: + type: string + description: Get URL to download certificate + readOnly: true + private_key_download_url: + type: string + description: Get URL to download private key + readOnly: true + managed: + type: string + readOnly: true + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + required: + - cert_expiry + - cert_subject + - certificate_download_url + - fingerprint_sha1 + - fingerprint_sha256 + - key_type + - managed + - name + - pk + - private_key_available + - private_key_download_url + CertificateKeyPairKeyTypeEnum: + enum: + - rsa + - ec + - dsa + - ed25519 + - ed448 + type: string + CertificateKeyPairRequest: + type: object + description: CertificateKeyPair Serializer + properties: + name: + type: string + minLength: 1 + certificate_data: + type: string + writeOnly: true + minLength: 1 + description: PEM-encoded Certificate data + key_data: + type: string + writeOnly: true + description: Optional Private Key. If this is set, you can use this keypair + for encryption. + required: + - certificate_data + - name + ChallengeTypes: + oneOf: + - $ref: '#/components/schemas/AccessDeniedChallenge' + - $ref: '#/components/schemas/AppleLoginChallenge' + - $ref: '#/components/schemas/AuthenticatorDuoChallenge' + - $ref: '#/components/schemas/AuthenticatorEmailChallenge' + - $ref: '#/components/schemas/AuthenticatorSMSChallenge' + - $ref: '#/components/schemas/AuthenticatorStaticChallenge' + - $ref: '#/components/schemas/AuthenticatorTOTPChallenge' + - $ref: '#/components/schemas/AuthenticatorValidationChallenge' + - $ref: '#/components/schemas/AuthenticatorWebAuthnChallenge' + - $ref: '#/components/schemas/AutosubmitChallenge' + - $ref: '#/components/schemas/CaptchaChallenge' + - $ref: '#/components/schemas/ConsentChallenge' + - $ref: '#/components/schemas/DummyChallenge' + - $ref: '#/components/schemas/EmailChallenge' + - $ref: '#/components/schemas/EndpointAgentChallenge' + - $ref: '#/components/schemas/FlowErrorChallenge' + - $ref: '#/components/schemas/FrameChallenge' + - $ref: '#/components/schemas/IdentificationChallenge' + - $ref: '#/components/schemas/IframeLogoutChallenge' + - $ref: '#/components/schemas/NativeLogoutChallenge' + - $ref: '#/components/schemas/OAuthDeviceCodeChallenge' + - $ref: '#/components/schemas/OAuthDeviceCodeFinishChallenge' + - $ref: '#/components/schemas/PasswordChallenge' + - $ref: '#/components/schemas/PlexAuthenticationChallenge' + - $ref: '#/components/schemas/PromptChallenge' + - $ref: '#/components/schemas/RedirectChallenge' + - $ref: '#/components/schemas/SessionEndChallenge' + - $ref: '#/components/schemas/ShellChallenge' + - $ref: '#/components/schemas/TelegramLoginChallenge' + - $ref: '#/components/schemas/UserLoginChallenge' + discriminator: + propertyName: component + mapping: + ak-stage-access-denied: '#/components/schemas/AccessDeniedChallenge' + ak-source-oauth-apple: '#/components/schemas/AppleLoginChallenge' + ak-stage-authenticator-duo: '#/components/schemas/AuthenticatorDuoChallenge' + ak-stage-authenticator-email: '#/components/schemas/AuthenticatorEmailChallenge' + ak-stage-authenticator-sms: '#/components/schemas/AuthenticatorSMSChallenge' + ak-stage-authenticator-static: '#/components/schemas/AuthenticatorStaticChallenge' + ak-stage-authenticator-totp: '#/components/schemas/AuthenticatorTOTPChallenge' + ak-stage-authenticator-validate: '#/components/schemas/AuthenticatorValidationChallenge' + ak-stage-authenticator-webauthn: '#/components/schemas/AuthenticatorWebAuthnChallenge' + ak-stage-autosubmit: '#/components/schemas/AutosubmitChallenge' + ak-stage-captcha: '#/components/schemas/CaptchaChallenge' + ak-stage-consent: '#/components/schemas/ConsentChallenge' + ak-stage-dummy: '#/components/schemas/DummyChallenge' + ak-stage-email: '#/components/schemas/EmailChallenge' + ak-stage-endpoint-agent: '#/components/schemas/EndpointAgentChallenge' + ak-stage-flow-error: '#/components/schemas/FlowErrorChallenge' + xak-flow-frame: '#/components/schemas/FrameChallenge' + ak-stage-identification: '#/components/schemas/IdentificationChallenge' + ak-provider-iframe-logout: '#/components/schemas/IframeLogoutChallenge' + ak-provider-saml-native-logout: '#/components/schemas/NativeLogoutChallenge' + ak-provider-oauth2-device-code: '#/components/schemas/OAuthDeviceCodeChallenge' + ak-provider-oauth2-device-code-finish: '#/components/schemas/OAuthDeviceCodeFinishChallenge' + ak-stage-password: '#/components/schemas/PasswordChallenge' + ak-source-plex: '#/components/schemas/PlexAuthenticationChallenge' + ak-stage-prompt: '#/components/schemas/PromptChallenge' + xak-flow-redirect: '#/components/schemas/RedirectChallenge' + ak-stage-session-end: '#/components/schemas/SessionEndChallenge' + xak-flow-shell: '#/components/schemas/ShellChallenge' + ak-source-telegram: '#/components/schemas/TelegramLoginChallenge' + ak-stage-user-login: '#/components/schemas/UserLoginChallenge' + ClientTypeEnum: + enum: + - confidential + - public + type: string + CompatibilityModeEnum: + enum: + - default + - aws + - slack + - sfdc + - webex + - vcenter + type: string + Config: + type: object + description: Serialize authentik Config into DRF Object + properties: + error_reporting: + $ref: '#/components/schemas/ErrorReportingConfig' + capabilities: + type: array + items: + $ref: '#/components/schemas/CapabilitiesEnum' + cache_timeout: + type: integer + cache_timeout_flows: + type: integer + cache_timeout_policies: + type: integer + required: + - cache_timeout + - cache_timeout_flows + - cache_timeout_policies + - capabilities + - error_reporting + ConnectionToken: + type: object + description: ConnectionToken Serializer + properties: + pk: + type: string + format: uuid + title: Connection token uuid + provider: + type: integer + provider_obj: + allOf: + - $ref: '#/components/schemas/RACProvider' + readOnly: true + endpoint: + type: string + format: uuid + endpoint_obj: + allOf: + - $ref: '#/components/schemas/Endpoint' + readOnly: true + user: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + required: + - endpoint + - endpoint_obj + - provider + - provider_obj + - user + ConnectionTokenRequest: + type: object + description: ConnectionToken Serializer + properties: + pk: + type: string + format: uuid + title: Connection token uuid + provider: + type: integer + endpoint: + type: string + format: uuid + required: + - endpoint + - provider + Connector: + type: object + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + enabled: + type: boolean + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - meta_model_name + - name + - verbose_name + - verbose_name_plural + ConsentChallenge: + type: object + description: Challenge info for consent screens + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-consent + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + header_text: + type: string + permissions: + type: array + items: + $ref: '#/components/schemas/ConsentPermission' + additional_permissions: + type: array + items: + $ref: '#/components/schemas/ConsentPermission' + token: + type: string + required: + - additional_permissions + - pending_user + - pending_user_avatar + - permissions + - token + ConsentChallengeResponseRequest: + type: object + description: Consent challenge response, any valid response request is valid + properties: + component: + type: string + minLength: 1 + default: ak-stage-consent + token: + type: string + minLength: 1 + required: + - token + ConsentModeEnum: + enum: + - always_require + - permanent + - expiring + type: string + ConsentPermission: + type: object + description: Permission used for consent + properties: + name: + type: string + id: + type: string + required: + - id + - name + ConsentStage: + type: object + description: ConsentStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + mode: + $ref: '#/components/schemas/ConsentModeEnum' + consent_expire_in: + type: string + title: Consent expires in + description: 'Offset after which consent expires. (Format: hours=1;minutes=2;seconds=3).' + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + ConsentStageRequest: + type: object + description: ConsentStage Serializer + properties: + name: + type: string + minLength: 1 + mode: + $ref: '#/components/schemas/ConsentModeEnum' + consent_expire_in: + type: string + minLength: 1 + title: Consent expires in + description: 'Offset after which consent expires. (Format: hours=1;minutes=2;seconds=3).' + required: + - name + ContentType: + type: object + properties: + id: + type: integer + readOnly: true + app_label: + type: string + readOnly: true + model: + type: string + readOnly: true + verbose_name_plural: + type: string + readOnly: true + required: + - app_label + - id + - model + - verbose_name_plural + ContentTypeEnum: + enum: + - authentik_core.application + - authentik_core.group + - authentik_rbac.role + type: string + ContextualFlowInfo: + type: object + description: Contextual flow information for a challenge + properties: + title: + type: string + background: + type: string + background_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + nullable: true + cancel_url: + type: string + layout: + $ref: '#/components/schemas/ContextualFlowInfoLayoutEnum' + required: + - cancel_url + - layout + ContextualFlowInfoLayoutEnum: + enum: + - stacked + - content_left + - content_right + - sidebar_left + - sidebar_right + - sidebar_left_frame_background + - sidebar_right_frame_background + type: string + CountryCodeEnum: + enum: + - AF + - AX + - AL + - DZ + - AS + - AD + - AO + - AI + - AQ + - AG + - AR + - AM + - AW + - AU + - AT + - AZ + - BS + - BH + - BD + - BB + - BY + - BE + - BZ + - BJ + - BM + - BT + - BO + - BQ + - BA + - BW + - BV + - BR + - IO + - BN + - BG + - BF + - BI + - CV + - KH + - CM + - CA + - KY + - CF + - TD + - CL + - CN + - CX + - CC + - CO + - KM + - CG + - CK + - CR + - CI + - HR + - CU + - CW + - CY + - CZ + - CD + - DK + - DJ + - DM + - DO + - EC + - EG + - SV + - GQ + - ER + - EE + - SZ + - ET + - FK + - FO + - FJ + - FI + - FR + - GF + - PF + - TF + - GA + - GM + - GE + - DE + - GH + - GI + - GR + - GL + - GD + - GP + - GU + - GT + - GG + - GN + - GW + - GY + - HT + - HM + - HN + - HK + - HU + - IS + - IN + - ID + - IR + - IQ + - IE + - IM + - IL + - IT + - JM + - JP + - JE + - JO + - KZ + - KE + - KI + - KW + - KG + - LA + - LV + - LB + - LS + - LR + - LY + - LI + - LT + - LU + - MO + - MG + - MW + - MY + - MV + - ML + - MT + - MH + - MQ + - MR + - MU + - YT + - MX + - FM + - MD + - MC + - MN + - ME + - MS + - MA + - MZ + - MM + - NA + - NR + - NP + - NL + - NC + - NZ + - NI + - NE + - NG + - NU + - NF + - KP + - MK + - MP + - 'NO' + - OM + - PK + - PW + - PS + - PA + - PG + - PY + - PE + - PH + - PN + - PL + - PT + - PR + - QA + - RE + - RO + - RU + - RW + - BL + - SH + - KN + - LC + - MF + - PM + - VC + - WS + - SM + - ST + - SA + - SN + - RS + - SC + - SL + - SG + - SX + - SK + - SI + - SB + - SO + - ZA + - GS + - KR + - SS + - ES + - LK + - SD + - SR + - SJ + - SE + - CH + - SY + - TW + - TJ + - TZ + - TH + - TL + - TG + - TK + - TO + - TT + - TN + - TR + - TM + - TC + - TV + - UG + - UA + - AE + - GB + - UM + - US + - UY + - UZ + - VU + - VA + - VE + - VN + - VG + - VI + - WF + - EH + - YE + - ZM + - ZW + type: string + CurrentBrand: + type: object + description: Partial brand information for styling + properties: + matched_domain: + type: string + branding_title: + type: string + branding_logo: + type: string + branding_logo_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + branding_favicon: + type: string + branding_favicon_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + branding_custom_css: + type: string + ui_footer_links: + type: array + items: + $ref: '#/components/schemas/FooterLink' + readOnly: true + ui_theme: + allOf: + - $ref: '#/components/schemas/UiThemeEnum' + readOnly: true + default: automatic + flow_authentication: + type: string + flow_invalidation: + type: string + flow_recovery: + type: string + flow_unenrollment: + type: string + flow_user_settings: + type: string + flow_device_code: + type: string + flow_lockdown: + type: string + default_locale: + type: string + readOnly: true + flags: + type: object + properties: + flows_continuous_login: + type: boolean + description: Upon successful authentication, re-start authentication + in other open tabs. + flows_refresh_others: + type: boolean + description: Refresh other tabs after successful authentication. + deprecated: true + required: + - flows_continuous_login + - flows_refresh_others + readOnly: true + required: + - branding_custom_css + - branding_favicon + - branding_favicon_themed_urls + - branding_logo + - branding_logo_themed_urls + - branding_title + - default_locale + - flags + - matched_domain + - ui_footer_links + - ui_theme + DataExport: + type: object + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + properties: + id: + type: string + format: uuid + readOnly: true + requested_by: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + requested_on: + type: string + format: date-time + readOnly: true + content_type: + allOf: + - $ref: '#/components/schemas/ContentType' + readOnly: true + query_params: + type: object + additionalProperties: {} + file_url: + type: string + readOnly: true + completed: + type: boolean + readOnly: true + required: + - completed + - content_type + - file_url + - id + - query_params + - requested_by + - requested_on + DeliveryMethodEnum: + enum: + - https://schemas.openid.net/secevent/risc/delivery-method/push + - https://schemas.openid.net/secevent/risc/delivery-method/poll + - urn:ietf:rfc:8935 + - urn:ietf:rfc:8936 + type: string + DeniedActionEnum: + enum: + - message_continue + - message + - continue + type: string + DenyStage: + type: object + description: DenyStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + deny_message: + type: string + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + DenyStageRequest: + type: object + description: DenyStage Serializer + properties: + name: + type: string + minLength: 1 + deny_message: + type: string + required: + - name + DetailedCountry: + type: object + properties: + code: + $ref: '#/components/schemas/CountryCodeEnum' + name: + type: string + required: + - code + - name + Device: + type: object + description: Serializer for authenticator devices + properties: + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + pk: + type: string + name: + type: string + type: + type: string + description: Get type of device + readOnly: true + confirmed: + type: boolean + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + last_used: + type: string + format: date-time + readOnly: true + nullable: true + extra_description: + type: string + nullable: true + description: Get extra description + readOnly: true + external_id: + type: string + nullable: true + description: Get external Device ID + readOnly: true + required: + - confirmed + - created + - external_id + - extra_description + - last_updated + - last_used + - meta_model_name + - name + - pk + - type + - verbose_name + - verbose_name_plural + DeviceAccessGroup: + type: object + properties: + pbm_uuid: + type: string + format: uuid + readOnly: true + name: + type: string + attributes: + type: object + additionalProperties: {} + required: + - name + - pbm_uuid + DeviceAccessGroupRequest: + type: object + properties: + name: + type: string + minLength: 1 + attributes: + type: object + additionalProperties: {} + required: + - name + DeviceChallenge: + type: object + description: Single device challenge + properties: + device_class: + $ref: '#/components/schemas/DeviceClassesEnum' + device_uid: + type: string + challenge: + type: object + additionalProperties: {} + last_used: + type: string + format: date-time + nullable: true + required: + - challenge + - device_class + - device_uid + - last_used + DeviceChallengeRequest: + type: object + description: Single device challenge + properties: + device_class: + $ref: '#/components/schemas/DeviceClassesEnum' + device_uid: + type: string + minLength: 1 + challenge: + type: object + additionalProperties: {} + last_used: + type: string + format: date-time + nullable: true + required: + - challenge + - device_class + - device_uid + - last_used + DeviceClassesEnum: + enum: + - static + - totp + - webauthn + - duo + - sms + - email + type: string + DeviceConnection: + type: object + properties: + device: + type: string + format: uuid + connector: + type: string + format: uuid + connector_obj: + allOf: + - $ref: '#/components/schemas/Connector' + readOnly: true + latest_snapshot: + allOf: + - $ref: '#/components/schemas/DeviceFactSnapshot' + readOnly: true + nullable: true + required: + - connector + - connector_obj + - device + - latest_snapshot + DeviceFactSnapshot: + type: object + properties: + data: + $ref: '#/components/schemas/DeviceFacts' + connection: + type: string + format: uuid + created: + type: string + format: date-time + readOnly: true + expires: + type: string + format: date-time + readOnly: true + nullable: true + vendor: + allOf: + - $ref: '#/components/schemas/VendorEnum' + readOnly: true + required: + - connection + - created + - data + - expires + - vendor + DeviceFacts: + type: object + properties: + os: + allOf: + - $ref: '#/components/schemas/OperatingSystem' + nullable: true + disks: + type: array + items: + $ref: '#/components/schemas/Disk' + nullable: true + network: + allOf: + - $ref: '#/components/schemas/Network' + nullable: true + hardware: + allOf: + - $ref: '#/components/schemas/Hardware' + nullable: true + software: + type: array + items: + $ref: '#/components/schemas/Software' + nullable: true + processes: + type: array + items: + $ref: '#/components/schemas/Process' + nullable: true + users: + type: array + items: + $ref: '#/components/schemas/DeviceUser' + nullable: true + groups: + type: array + items: + $ref: '#/components/schemas/DeviceGroup' + nullable: true + vendor: + type: object + additionalProperties: {} + DeviceFactsOSFamily: + enum: + - linux + - unix + - bsd + - windows + - mac_os + - android + - i_os + - other + type: string + DeviceFactsRequest: + type: object + properties: + os: + allOf: + - $ref: '#/components/schemas/OperatingSystemRequest' + nullable: true + disks: + type: array + items: + $ref: '#/components/schemas/DiskRequest' + nullable: true + network: + allOf: + - $ref: '#/components/schemas/NetworkRequest' + nullable: true + hardware: + allOf: + - $ref: '#/components/schemas/HardwareRequest' + nullable: true + software: + type: array + items: + $ref: '#/components/schemas/SoftwareRequest' + nullable: true + processes: + type: array + items: + $ref: '#/components/schemas/ProcessRequest' + nullable: true + users: + type: array + items: + $ref: '#/components/schemas/DeviceUserRequest' + nullable: true + groups: + type: array + items: + $ref: '#/components/schemas/DeviceGroupRequest' + nullable: true + vendor: + type: object + additionalProperties: {} + DeviceGroup: + type: object + properties: + id: + type: string + name: + type: string + required: + - id + DeviceGroupRequest: + type: object + properties: + id: + type: string + minLength: 1 + name: + type: string + minLength: 1 + required: + - id + DeviceSummary: + type: object + description: Summary of registered devices + properties: + total_count: + type: integer + unreachable_count: + type: integer + outdated_agent_count: + type: integer + required: + - outdated_agent_count + - total_count + - unreachable_count + DeviceUser: + type: object + properties: + id: + type: string + username: + type: string + name: + type: string + home: + type: string + required: + - id + DeviceUserBinding: + type: object + description: PolicyBinding Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy binding uuid + policy: + type: string + format: uuid + nullable: true + group: + type: string + format: uuid + nullable: true + user: + type: integer + nullable: true + policy_obj: + allOf: + - $ref: '#/components/schemas/Policy' + readOnly: true + nullable: true + group_obj: + allOf: + - $ref: '#/components/schemas/PartialGroup' + readOnly: true + nullable: true + user_obj: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + nullable: true + target: + type: string + format: uuid + negate: + type: boolean + description: Negates the outcome of the policy. Messages are unaffected. + enabled: + type: boolean + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + timeout: + type: integer + maximum: 2147483647 + minimum: 0 + description: Timeout after which Policy execution is terminated. + failure_result: + type: boolean + description: Result if the Policy execution fails. + is_primary: + type: boolean + connector: + type: string + format: uuid + readOnly: true + nullable: true + connector_obj: + allOf: + - $ref: '#/components/schemas/Connector' + readOnly: true + required: + - connector + - connector_obj + - group_obj + - order + - pk + - policy_obj + - target + - user_obj + DeviceUserBindingRequest: + type: object + description: PolicyBinding Serializer + properties: + policy: + type: string + format: uuid + nullable: true + group: + type: string + format: uuid + nullable: true + user: + type: integer + nullable: true + target: + type: string + format: uuid + negate: + type: boolean + description: Negates the outcome of the policy. Messages are unaffected. + enabled: + type: boolean + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + timeout: + type: integer + maximum: 2147483647 + minimum: 0 + description: Timeout after which Policy execution is terminated. + failure_result: + type: boolean + description: Result if the Policy execution fails. + is_primary: + type: boolean + required: + - order + - target + DeviceUserRequest: + type: object + properties: + id: + type: string + minLength: 1 + username: + type: string + minLength: 1 + name: + type: string + minLength: 1 + home: + type: string + minLength: 1 + required: + - id + DigestAlgorithmEnum: + enum: + - http://www.w3.org/2000/09/xmldsig#sha1 + - http://www.w3.org/2001/04/xmlenc#sha256 + - http://www.w3.org/2001/04/xmldsig-more#sha384 + - http://www.w3.org/2001/04/xmlenc#sha512 + type: string + DigitsEnum: + enum: + - '6' + - '8' + type: string + Disk: + type: object + properties: + name: + type: string + mountpoint: + type: string + label: + type: string + capacity_total_bytes: + type: integer + format: int64 + capacity_used_bytes: + type: integer + format: int64 + encryption_enabled: + type: boolean + default: false + required: + - mountpoint + - name + DiskRequest: + type: object + properties: + name: + type: string + minLength: 1 + mountpoint: + type: string + minLength: 1 + label: + type: string + capacity_total_bytes: + type: integer + format: int64 + capacity_used_bytes: + type: integer + format: int64 + encryption_enabled: + type: boolean + default: false + required: + - mountpoint + - name + DockerServiceConnection: + type: object + description: DockerServiceConnection Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Uuid + name: + type: string + local: + type: boolean + description: If enabled, use the local connection. Required Docker socket/Kubernetes + Integration + component: + type: string + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + url: + type: string + description: Can be in the format of 'unix://' when connecting to + a local docker daemon, or 'https://:2376' when connecting to + a remote system. + tls_verification: + type: string + format: uuid + nullable: true + description: CA which the endpoint's Certificate is verified against. Can + be left empty for no validation. + tls_authentication: + type: string + format: uuid + nullable: true + description: Certificate/Key used for authentication. Can be left empty + for no authentication. + required: + - component + - meta_model_name + - name + - pk + - url + - verbose_name + - verbose_name_plural + DockerServiceConnectionRequest: + type: object + description: DockerServiceConnection Serializer + properties: + name: + type: string + minLength: 1 + local: + type: boolean + description: If enabled, use the local connection. Required Docker socket/Kubernetes + Integration + url: + type: string + minLength: 1 + description: Can be in the format of 'unix://' when connecting to + a local docker daemon, or 'https://:2376' when connecting to + a remote system. + tls_verification: + type: string + format: uuid + nullable: true + description: CA which the endpoint's Certificate is verified against. Can + be left empty for no validation. + tls_authentication: + type: string + format: uuid + nullable: true + description: Certificate/Key used for authentication. Can be left empty + for no authentication. + required: + - name + - url + Domain: + type: object + description: Domain Serializer + properties: + id: + type: integer + readOnly: true + domain: + type: string + maxLength: 253 + is_primary: + type: boolean + tenant: + type: string + format: uuid + required: + - domain + - id + - tenant + DomainRequest: + type: object + description: Domain Serializer + properties: + domain: + type: string + minLength: 1 + maxLength: 253 + is_primary: + type: boolean + tenant: + type: string + format: uuid + required: + - domain + - tenant + DummyChallenge: + type: object + description: Dummy challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-dummy + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + name: + type: string + required: + - name + DummyChallengeResponseRequest: + type: object + description: Dummy challenge response + properties: + component: + type: string + minLength: 1 + default: ak-stage-dummy + DummyPolicy: + type: object + description: Dummy Policy Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy uuid + name: + type: string + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + bound_to: + type: integer + description: Return objects policy is bound to + readOnly: true + result: + type: boolean + wait_min: + type: integer + maximum: 2147483647 + minimum: -2147483648 + wait_max: + type: integer + maximum: 2147483647 + minimum: -2147483648 + required: + - bound_to + - component + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + DummyPolicyRequest: + type: object + description: Dummy Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + result: + type: boolean + wait_min: + type: integer + maximum: 2147483647 + minimum: -2147483648 + wait_max: + type: integer + maximum: 2147483647 + minimum: -2147483648 + required: + - name + DummyStage: + type: object + description: DummyStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + throw_error: + type: boolean + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + DummyStageRequest: + type: object + description: DummyStage Serializer + properties: + name: + type: string + minLength: 1 + throw_error: + type: boolean + required: + - name + DuoDevice: + type: object + description: Serializer for Duo authenticator devices + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + description: The human-readable name of this device. + maxLength: 64 + user: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + required: + - name + - pk + - user + DuoDeviceEnrollmentStatus: + type: object + properties: + duo_response: + $ref: '#/components/schemas/DuoResponseEnum' + required: + - duo_response + DuoDeviceRequest: + type: object + description: Serializer for Duo authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + required: + - name + DuoResponseEnum: + enum: + - success + - waiting + - invalid + type: string + EmailChallenge: + type: object + description: Email challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-email + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + EmailChallengeResponseRequest: + type: object + description: |- + Email challenge resposen. No fields. This challenge is + always declared invalid to give the user a chance to retry + properties: + component: + type: string + minLength: 1 + default: ak-stage-email + EmailDevice: + type: object + description: Serializer for email authenticator devices + properties: + name: + type: string + description: The human-readable name of this device. + maxLength: 64 + pk: + type: integer + readOnly: true + title: ID + email: + type: string + format: email + readOnly: true + user: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + required: + - email + - name + - pk + - user + EmailDeviceRequest: + type: object + description: Serializer for email authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + required: + - name + EmailStage: + type: object + description: EmailStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + use_global_settings: + type: boolean + description: When enabled, global Email connection settings will be used + and connection settings below will be ignored. + host: + type: string + port: + type: integer + maximum: 2147483647 + minimum: -2147483648 + username: + type: string + use_tls: + type: boolean + use_ssl: + type: boolean + timeout: + type: integer + maximum: 2147483647 + minimum: -2147483648 + from_address: + type: string + format: email + maxLength: 254 + token_expiry: + type: string + description: 'Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).' + subject: + type: string + template: + type: string + activate_user_on_success: + type: boolean + description: Activate users upon completion of stage. + recovery_max_attempts: + type: integer + maximum: 2147483647 + minimum: 0 + recovery_cache_timeout: + type: string + description: 'The time window used to count recent account recovery attempts. + If the number of attempts exceed recovery_max_attempts within this period, + further attempts will be rate-limited. (Format: hours=1;minutes=2;seconds=3).' + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + EmailStageRequest: + type: object + description: EmailStage Serializer + properties: + name: + type: string + minLength: 1 + use_global_settings: + type: boolean + description: When enabled, global Email connection settings will be used + and connection settings below will be ignored. + host: + type: string + minLength: 1 + port: + type: integer + maximum: 2147483647 + minimum: -2147483648 + username: + type: string + password: + type: string + writeOnly: true + use_tls: + type: boolean + use_ssl: + type: boolean + timeout: + type: integer + maximum: 2147483647 + minimum: -2147483648 + from_address: + type: string + format: email + minLength: 1 + maxLength: 254 + token_expiry: + type: string + minLength: 1 + description: 'Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).' + subject: + type: string + minLength: 1 + template: + type: string + minLength: 1 + activate_user_on_success: + type: boolean + description: Activate users upon completion of stage. + recovery_max_attempts: + type: integer + maximum: 2147483647 + minimum: 0 + recovery_cache_timeout: + type: string + minLength: 1 + description: 'The time window used to count recent account recovery attempts. + If the number of attempts exceed recovery_max_attempts within this period, + further attempts will be rate-limited. (Format: hours=1;minutes=2;seconds=3).' + required: + - name + Endpoint: + type: object + description: Endpoint Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + provider: + type: integer + provider_obj: + allOf: + - $ref: '#/components/schemas/RACProvider' + readOnly: true + protocol: + $ref: '#/components/schemas/ProtocolEnum' + host: + type: string + settings: + type: object + additionalProperties: {} + property_mappings: + type: array + items: + type: string + format: uuid + auth_mode: + $ref: '#/components/schemas/EndpointAuthModeEnum' + launch_url: + type: string + nullable: true + description: |- + Build actual launch URL (the provider itself does not have one, just + individual endpoints) + readOnly: true + maximum_connections: + type: integer + maximum: 2147483647 + minimum: -2147483648 + required: + - auth_mode + - host + - launch_url + - name + - pk + - protocol + - provider + - provider_obj + EndpointAgentChallenge: + type: object + description: Signed challenge for authentik agent to respond to + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-endpoint-agent + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + challenge: + type: string + challenge_idle_timeout: + type: integer + required: + - challenge + - challenge_idle_timeout + EndpointAgentChallengeResponseRequest: + type: object + description: Response to signed challenge + properties: + component: + type: string + minLength: 1 + default: ak-stage-endpoint-agent + response: + type: string + nullable: true + minLength: 1 + EndpointAuthModeEnum: + enum: + - static + - prompt + type: string + EndpointDevice: + type: object + properties: + device_uuid: + type: string + format: uuid + pbm_uuid: + type: string + format: uuid + readOnly: true + name: + type: string + access_group: + type: string + format: uuid + nullable: true + access_group_obj: + $ref: '#/components/schemas/DeviceAccessGroup' + expiring: + type: boolean + expires: + type: string + format: date-time + nullable: true + facts: + allOf: + - $ref: '#/components/schemas/DeviceFactSnapshot' + readOnly: true + nullable: true + attributes: + type: object + additionalProperties: {} + required: + - facts + - name + - pbm_uuid + EndpointDeviceDetails: + type: object + properties: + device_uuid: + type: string + format: uuid + pbm_uuid: + type: string + format: uuid + readOnly: true + name: + type: string + access_group: + type: string + format: uuid + nullable: true + access_group_obj: + $ref: '#/components/schemas/DeviceAccessGroup' + expiring: + type: boolean + expires: + type: string + format: date-time + nullable: true + facts: + allOf: + - $ref: '#/components/schemas/DeviceFactSnapshot' + readOnly: true + nullable: true + attributes: + type: object + additionalProperties: {} + connections_obj: + type: array + items: + $ref: '#/components/schemas/DeviceConnection' + policies: + type: array + items: + type: string + format: uuid + readOnly: true + connections: + type: array + items: + type: string + format: uuid + readOnly: true + required: + - connections + - connections_obj + - facts + - name + - pbm_uuid + - policies + EndpointDeviceRequest: + type: object + properties: + device_uuid: + type: string + format: uuid + name: + type: string + minLength: 1 + access_group: + type: string + format: uuid + nullable: true + access_group_obj: + $ref: '#/components/schemas/DeviceAccessGroupRequest' + expiring: + type: boolean + expires: + type: string + format: date-time + nullable: true + attributes: + type: object + additionalProperties: {} + required: + - name + EndpointRequest: + type: object + description: Endpoint Serializer + properties: + name: + type: string + minLength: 1 + provider: + type: integer + protocol: + $ref: '#/components/schemas/ProtocolEnum' + host: + type: string + minLength: 1 + settings: + type: object + additionalProperties: {} + property_mappings: + type: array + items: + type: string + format: uuid + auth_mode: + $ref: '#/components/schemas/EndpointAuthModeEnum' + maximum_connections: + type: integer + maximum: 2147483647 + minimum: -2147483648 + required: + - auth_mode + - host + - name + - protocol + - provider + EndpointStage: + type: object + description: EndpointStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + connector: + type: string + format: uuid + connector_obj: + allOf: + - $ref: '#/components/schemas/Connector' + readOnly: true + mode: + $ref: '#/components/schemas/StageModeEnum' + required: + - component + - connector + - connector_obj + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + EndpointStageRequest: + type: object + description: EndpointStage Serializer + properties: + name: + type: string + minLength: 1 + connector: + type: string + format: uuid + mode: + $ref: '#/components/schemas/StageModeEnum' + required: + - connector + - name + EnrollRequest: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + device_serial: + type: string + minLength: 1 + device_name: + type: string + minLength: 1 + required: + - device_name + - device_serial + EnrollmentToken: + type: object + properties: + token_uuid: + type: string + format: uuid + readOnly: true + device_group: + type: string + format: uuid + nullable: true + device_group_obj: + allOf: + - $ref: '#/components/schemas/DeviceAccessGroup' + readOnly: true + nullable: true + connector: + type: string + format: uuid + name: + type: string + expiring: + type: boolean + expires: + type: string + format: date-time + nullable: true + required: + - connector + - device_group_obj + - name + - token_uuid + EnrollmentTokenRequest: + type: object + properties: + device_group: + type: string + format: uuid + nullable: true + connector: + type: string + format: uuid + name: + type: string + minLength: 1 + expiring: + type: boolean + expires: + type: string + format: date-time + nullable: true + required: + - connector + - name + ErrorDetail: + type: object + description: Serializer for rest_framework's error messages + properties: + string: + type: string + code: + type: string + required: + - code + - string + ErrorReportingConfig: + type: object + description: Config for error reporting + properties: + enabled: + type: boolean + readOnly: true + sentry_dsn: + type: string + readOnly: true + environment: + type: string + readOnly: true + send_pii: + type: boolean + readOnly: true + traces_sample_rate: + type: number + format: double + readOnly: true + required: + - enabled + - environment + - send_pii + - sentry_dsn + - traces_sample_rate + Event: + type: object + description: Event Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Event uuid + user: + type: object + additionalProperties: {} + action: + $ref: '#/components/schemas/EventActions' + app: + type: string + context: + type: object + additionalProperties: {} + client_ip: + type: string + nullable: true + created: + type: string + format: date-time + readOnly: true + expires: + type: string + format: date-time + brand: + type: object + additionalProperties: {} + required: + - action + - app + - created + - pk + EventActions: + enum: + - login + - login_failed + - logout + - user_write + - suspicious_request + - password_set + - secret_view + - secret_rotate + - invitation_used + - authorize_application + - source_linked + - impersonation_started + - impersonation_ended + - flow_execution + - policy_execution + - policy_exception + - property_mapping_exception + - system_task_execution + - system_task_exception + - system_exception + - configuration_error + - configuration_warning + - model_created + - model_updated + - model_deleted + - email_sent + - update_available + - export_ready + - review_initiated + - review_overdue + - review_attested + - review_completed + - custom_ + type: string + EventMatcherPolicy: + type: object + description: Event Matcher Policy Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy uuid + name: + type: string + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + bound_to: + type: integer + description: Return objects policy is bound to + readOnly: true + action: + allOf: + - $ref: '#/components/schemas/EventActions' + nullable: true + description: Match created events with this action type. When left empty, + all action types will be matched. + client_ip: + type: string + nullable: true + description: Matches Event's Client IP (strict matching, for network matching + use an Expression Policy) + app: + allOf: + - $ref: '#/components/schemas/AppEnum' + nullable: true + description: Match events created by selected application. When left empty, + all applications are matched. + model: + allOf: + - $ref: '#/components/schemas/ModelEnum' + nullable: true + description: Match events created by selected model. When left empty, all + models are matched. When an app is selected, all the application's models + are matched. + query: + type: string + nullable: true + required: + - bound_to + - component + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + EventMatcherPolicyRequest: + type: object + description: Event Matcher Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + action: + allOf: + - $ref: '#/components/schemas/EventActions' + nullable: true + description: Match created events with this action type. When left empty, + all action types will be matched. + client_ip: + type: string + nullable: true + minLength: 1 + description: Matches Event's Client IP (strict matching, for network matching + use an Expression Policy) + app: + allOf: + - $ref: '#/components/schemas/AppEnum' + nullable: true + description: Match events created by selected application. When left empty, + all applications are matched. + model: + allOf: + - $ref: '#/components/schemas/ModelEnum' + nullable: true + description: Match events created by selected model. When left empty, all + models are matched. When an app is selected, all the application's models + are matched. + query: + type: string + nullable: true + minLength: 1 + required: + - name + EventRequest: + type: object + description: Event Serializer + properties: + user: + type: object + additionalProperties: {} + action: + $ref: '#/components/schemas/EventActions' + app: + type: string + minLength: 1 + context: + type: object + additionalProperties: {} + client_ip: + type: string + nullable: true + minLength: 1 + expires: + type: string + format: date-time + brand: + type: object + additionalProperties: {} + required: + - action + - app + EventStats: + type: object + description: Count of unique users in events and aggregated counts per specified + deltas + properties: + unique_users: + type: integer + count_step: + type: object + additionalProperties: {} + required: + - count_step + - unique_users + EventTopPerUser: + type: object + description: Response object of Event's top_per_user + properties: + application: + type: object + additionalProperties: {} + counted_events: + type: integer + unique_users: + type: integer + required: + - application + - counted_events + - unique_users + EventVolume: + type: object + description: Count of events of action created on day for a single event action + properties: + action: + $ref: '#/components/schemas/EventActions' + time: + type: string + format: date-time + count: + type: integer + required: + - action + - count + - time + EventsRequestedEnum: + enum: + - https://schemas.openid.net/secevent/caep/event-type/session-revoked + - https://schemas.openid.net/secevent/caep/event-type/token-claims-change + - https://schemas.openid.net/secevent/caep/event-type/credential-change + - https://schemas.openid.net/secevent/caep/event-type/assurance-level-change + - https://schemas.openid.net/secevent/caep/event-type/device-compliance-change + - https://schemas.openid.net/secevent/caep/event-type/session-established + - https://schemas.openid.net/secevent/caep/event-type/session-presented + - https://schemas.openid.net/secevent/caep/event-type/risk-level-change + - https://schemas.openid.net/secevent/ssf/event-type/verification + type: string + ExpiringBaseGrantModel: + type: object + description: Serializer for BaseGrantModel and ExpiringBaseGrant + properties: + pk: + type: integer + readOnly: true + title: ID + provider: + $ref: '#/components/schemas/Provider' + user: + $ref: '#/components/schemas/User' + is_expired: + type: boolean + description: Check if token is expired yet. + readOnly: true + expires: + type: string + format: date-time + nullable: true + scope: + type: array + items: + type: string + required: + - is_expired + - pk + - provider + - scope + - user + ExpressionPolicy: + type: object + description: Group Membership Policy Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy uuid + name: + type: string + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + bound_to: + type: integer + description: Return objects policy is bound to + readOnly: true + expression: + type: string + required: + - bound_to + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + ExpressionPolicyRequest: + type: object + description: Group Membership Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + expression: + type: string + minLength: 1 + required: + - expression + - name + ExtraRoleObjectPermission: + type: object + description: Role permission with additional object-related data + properties: + id: + type: integer + readOnly: true + codename: + type: string + readOnly: true + model: + type: string + title: Python model class name + readOnly: true + app_label: + type: string + readOnly: true + object_pk: + type: string + name: + type: string + readOnly: true + app_label_verbose: + type: string + description: Get app label from permission's model + readOnly: true + model_verbose: + type: string + description: Get model label from permission's model + readOnly: true + object_description: + type: string + nullable: true + description: |- + Get model description from attached model. This operation takes at least + one additional query, and the description is only shown if the role has the + view_ permission on the object + readOnly: true + required: + - app_label + - app_label_verbose + - codename + - id + - model + - model_verbose + - name + - object_description + - object_pk + FileList: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + name: + type: string + mime_type: + type: string + url: + type: string + themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + nullable: true + required: + - mime_type + - name + - url + FileUploadRequest: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + file: + type: string + format: binary + name: + type: string + usage: + type: string + minLength: 1 + default: media + required: + - file + FleetConnector: + type: object + description: FleetConnector Serializer + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + enabled: + type: boolean + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + url: + type: string + format: uri + maxLength: 200 + headers_mapping: + type: string + format: uuid + nullable: true + description: Configure additional headers to be sent. Mapping should return + a dictionary of key-value pairs + map_users: + type: boolean + map_teams_access_group: + type: boolean + required: + - component + - meta_model_name + - name + - url + - verbose_name + - verbose_name_plural + FleetConnectorRequest: + type: object + description: FleetConnector Serializer + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + minLength: 1 + enabled: + type: boolean + url: + type: string + format: uri + minLength: 1 + maxLength: 200 + token: + type: string + writeOnly: true + minLength: 1 + headers_mapping: + type: string + format: uuid + nullable: true + description: Configure additional headers to be sent. Mapping should return + a dictionary of key-value pairs + map_users: + type: boolean + map_teams_access_group: + type: boolean + required: + - name + - token + - url + Flow: + type: object + description: Flow Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Flow uuid + policybindingmodel_ptr_id: + type: string + format: uuid + readOnly: true + name: + type: string + slug: + type: string + description: Visible in the URL. + pattern: ^[-a-zA-Z0-9_]+$ + title: + type: string + description: Shown as the Title in Flow pages. + designation: + allOf: + - $ref: '#/components/schemas/FlowDesignationEnum' + description: Decides what this Flow is used for. For example, the Authentication + flow is redirect to when an un-authenticated user visits authentik. + background: + type: string + description: Background shown during execution + background_url: + type: string + description: Get the URL to the background image + readOnly: true + background_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + stages: + type: array + items: + type: string + format: uuid + readOnly: true + policies: + type: array + items: + type: string + format: uuid + readOnly: true + cache_count: + type: integer + description: Get count of cached flows + readOnly: true + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + compatibility_mode: + type: boolean + description: Enable compatibility mode, increases compatibility with password + managers on mobile devices. + export_url: + type: string + description: Get export URL for flow + readOnly: true + layout: + $ref: '#/components/schemas/FlowLayoutEnum' + denied_action: + allOf: + - $ref: '#/components/schemas/DeniedActionEnum' + description: Configure what should happen when a flow denies access to a + user. + authentication: + allOf: + - $ref: '#/components/schemas/AuthenticationEnum' + description: Required level of authentication and authorization to access + a flow. + required: + - background_themed_urls + - background_url + - cache_count + - designation + - export_url + - name + - pk + - policies + - policybindingmodel_ptr_id + - slug + - stages + - title + FlowChallengeResponseRequest: + oneOf: + - $ref: '#/components/schemas/AppleChallengeResponseRequest' + - $ref: '#/components/schemas/AuthenticatorDuoChallengeResponseRequest' + - $ref: '#/components/schemas/AuthenticatorEmailChallengeResponseRequest' + - $ref: '#/components/schemas/AuthenticatorSMSChallengeResponseRequest' + - $ref: '#/components/schemas/AuthenticatorStaticChallengeResponseRequest' + - $ref: '#/components/schemas/AuthenticatorTOTPChallengeResponseRequest' + - $ref: '#/components/schemas/AuthenticatorValidationChallengeResponseRequest' + - $ref: '#/components/schemas/AuthenticatorWebAuthnChallengeResponseRequest' + - $ref: '#/components/schemas/AutoSubmitChallengeResponseRequest' + - $ref: '#/components/schemas/CaptchaChallengeResponseRequest' + - $ref: '#/components/schemas/ConsentChallengeResponseRequest' + - $ref: '#/components/schemas/DummyChallengeResponseRequest' + - $ref: '#/components/schemas/EmailChallengeResponseRequest' + - $ref: '#/components/schemas/EndpointAgentChallengeResponseRequest' + - $ref: '#/components/schemas/FrameChallengeResponseRequest' + - $ref: '#/components/schemas/IdentificationChallengeResponseRequest' + - $ref: '#/components/schemas/IframeLogoutChallengeResponseRequest' + - $ref: '#/components/schemas/NativeLogoutChallengeResponseRequest' + - $ref: '#/components/schemas/OAuthDeviceCodeChallengeResponseRequest' + - $ref: '#/components/schemas/OAuthDeviceCodeFinishChallengeResponseRequest' + - $ref: '#/components/schemas/PasswordChallengeResponseRequest' + - $ref: '#/components/schemas/PlexAuthenticationChallengeResponseRequest' + - $ref: '#/components/schemas/PromptChallengeResponseRequest' + - $ref: '#/components/schemas/RedirectChallengeResponseRequest' + - $ref: '#/components/schemas/TelegramChallengeResponseRequest' + - $ref: '#/components/schemas/UserLoginChallengeResponseRequest' + discriminator: + propertyName: component + mapping: + ak-source-oauth-apple: '#/components/schemas/AppleChallengeResponseRequest' + ak-stage-authenticator-duo: '#/components/schemas/AuthenticatorDuoChallengeResponseRequest' + ak-stage-authenticator-email: '#/components/schemas/AuthenticatorEmailChallengeResponseRequest' + ak-stage-authenticator-sms: '#/components/schemas/AuthenticatorSMSChallengeResponseRequest' + ak-stage-authenticator-static: '#/components/schemas/AuthenticatorStaticChallengeResponseRequest' + ak-stage-authenticator-totp: '#/components/schemas/AuthenticatorTOTPChallengeResponseRequest' + ak-stage-authenticator-validate: '#/components/schemas/AuthenticatorValidationChallengeResponseRequest' + ak-stage-authenticator-webauthn: '#/components/schemas/AuthenticatorWebAuthnChallengeResponseRequest' + ak-stage-autosubmit: '#/components/schemas/AutoSubmitChallengeResponseRequest' + ak-stage-captcha: '#/components/schemas/CaptchaChallengeResponseRequest' + ak-stage-consent: '#/components/schemas/ConsentChallengeResponseRequest' + ak-stage-dummy: '#/components/schemas/DummyChallengeResponseRequest' + ak-stage-email: '#/components/schemas/EmailChallengeResponseRequest' + ak-stage-endpoint-agent: '#/components/schemas/EndpointAgentChallengeResponseRequest' + xak-flow-frame: '#/components/schemas/FrameChallengeResponseRequest' + ak-stage-identification: '#/components/schemas/IdentificationChallengeResponseRequest' + ak-provider-iframe-logout: '#/components/schemas/IframeLogoutChallengeResponseRequest' + ak-provider-saml-native-logout: '#/components/schemas/NativeLogoutChallengeResponseRequest' + ak-provider-oauth2-device-code: '#/components/schemas/OAuthDeviceCodeChallengeResponseRequest' + ak-provider-oauth2-device-code-finish: '#/components/schemas/OAuthDeviceCodeFinishChallengeResponseRequest' + ak-stage-password: '#/components/schemas/PasswordChallengeResponseRequest' + ak-source-plex: '#/components/schemas/PlexAuthenticationChallengeResponseRequest' + ak-stage-prompt: '#/components/schemas/PromptChallengeResponseRequest' + xak-flow-redirect: '#/components/schemas/RedirectChallengeResponseRequest' + ak-source-telegram: '#/components/schemas/TelegramChallengeResponseRequest' + ak-stage-user-login: '#/components/schemas/UserLoginChallengeResponseRequest' + FlowDesignationEnum: + enum: + - authentication + - authorization + - invalidation + - enrollment + - unenrollment + - recovery + - stage_configuration + type: string + FlowDiagram: + type: object + description: response of the flow's diagram action + properties: + diagram: + type: string + readOnly: true + required: + - diagram + FlowErrorChallenge: + type: object + description: |- + Challenge class when an unhandled error occurs during a stage. Normal users + are shown an error message, superusers are shown a full stacktrace. + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-flow-error + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + request_id: + type: string + error: + type: string + traceback: + type: string + required: + - request_id + FlowInspection: + type: object + description: Serializer for inspect endpoint + properties: + plans: + type: array + items: + $ref: '#/components/schemas/FlowInspectorPlan' + current_plan: + $ref: '#/components/schemas/FlowInspectorPlan' + is_completed: + type: boolean + required: + - is_completed + - plans + FlowInspectorPlan: + type: object + description: Serializer for an active FlowPlan + properties: + current_stage: + allOf: + - $ref: '#/components/schemas/FlowStageBinding' + readOnly: true + next_planned_stage: + allOf: + - $ref: '#/components/schemas/FlowStageBinding' + readOnly: true + plan_context: + type: object + additionalProperties: {} + description: Get the plan's context, sanitized + readOnly: true + session_id: + type: string + description: Get a unique session ID + readOnly: true + required: + - current_stage + - next_planned_stage + - plan_context + - session_id + FlowLayoutEnum: + enum: + - stacked + - content_left + - content_right + - sidebar_left + - sidebar_right + - sidebar_left_frame_background + - sidebar_right_frame_background + type: string + FlowRequest: + type: object + description: Flow Serializer + properties: + name: + type: string + minLength: 1 + slug: + type: string + minLength: 1 + description: Visible in the URL. + pattern: ^[-a-zA-Z0-9_]+$ + title: + type: string + minLength: 1 + description: Shown as the Title in Flow pages. + designation: + allOf: + - $ref: '#/components/schemas/FlowDesignationEnum' + description: Decides what this Flow is used for. For example, the Authentication + flow is redirect to when an un-authenticated user visits authentik. + background: + type: string + description: Background shown during execution + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + compatibility_mode: + type: boolean + description: Enable compatibility mode, increases compatibility with password + managers on mobile devices. + layout: + $ref: '#/components/schemas/FlowLayoutEnum' + denied_action: + allOf: + - $ref: '#/components/schemas/DeniedActionEnum' + description: Configure what should happen when a flow denies access to a + user. + authentication: + allOf: + - $ref: '#/components/schemas/AuthenticationEnum' + description: Required level of authentication and authorization to access + a flow. + required: + - designation + - name + - slug + - title + FlowSet: + type: object + description: Stripped down flow serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Flow uuid + policybindingmodel_ptr_id: + type: string + format: uuid + readOnly: true + name: + type: string + slug: + type: string + description: Visible in the URL. + pattern: ^[-a-zA-Z0-9_]+$ + title: + type: string + description: Shown as the Title in Flow pages. + designation: + allOf: + - $ref: '#/components/schemas/FlowDesignationEnum' + description: Decides what this Flow is used for. For example, the Authentication + flow is redirect to when an un-authenticated user visits authentik. + background_url: + type: string + description: Get the URL to the background image + readOnly: true + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + compatibility_mode: + type: boolean + description: Enable compatibility mode, increases compatibility with password + managers on mobile devices. + export_url: + type: string + description: Get export URL for flow + readOnly: true + layout: + $ref: '#/components/schemas/FlowLayoutEnum' + denied_action: + allOf: + - $ref: '#/components/schemas/DeniedActionEnum' + description: Configure what should happen when a flow denies access to a + user. + required: + - background_url + - designation + - export_url + - name + - pk + - policybindingmodel_ptr_id + - slug + - title + FlowStageBinding: + type: object + description: FlowStageBinding Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Fsb uuid + policybindingmodel_ptr_id: + type: string + format: uuid + readOnly: true + target: + type: string + format: uuid + stage: + type: string + format: uuid + stage_obj: + allOf: + - $ref: '#/components/schemas/Stage' + readOnly: true + evaluate_on_plan: + type: boolean + description: Evaluate policies during the Flow planning process. + re_evaluate_policies: + type: boolean + description: Evaluate policies when the Stage is presented to the user. + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + invalid_response_action: + allOf: + - $ref: '#/components/schemas/InvalidResponseActionEnum' + description: Configure how the flow executor should handle an invalid response + to a challenge. RETRY returns the error message and a similar challenge + to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT + restarts the flow while keeping the current context. + required: + - order + - pk + - policybindingmodel_ptr_id + - stage + - stage_obj + - target + FlowStageBindingRequest: + type: object + description: FlowStageBinding Serializer + properties: + target: + type: string + format: uuid + stage: + type: string + format: uuid + evaluate_on_plan: + type: boolean + description: Evaluate policies during the Flow planning process. + re_evaluate_policies: + type: boolean + description: Evaluate policies when the Stage is presented to the user. + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + invalid_response_action: + allOf: + - $ref: '#/components/schemas/InvalidResponseActionEnum' + description: Configure how the flow executor should handle an invalid response + to a challenge. RETRY returns the error message and a similar challenge + to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT + restarts the flow while keeping the current context. + required: + - order + - stage + - target + FooterLink: + type: object + description: Links returned in Config API + properties: + href: + type: string + readOnly: true + nullable: true + name: + type: string + readOnly: true + required: + - href + - name + ForceBindingEnum: + type: string + enum: + - urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST + - urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect + FormatEnum: + type: string + enum: + - json + - yaml + FrameChallenge: + type: object + description: Challenge type to render a frame + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: xak-flow-frame + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + url: + type: string + loading_overlay: + type: boolean + default: false + loading_text: + type: string + required: + - loading_text + - url + FrameChallengeResponseRequest: + type: object + description: Base class for all challenge responses + properties: + component: + type: string + minLength: 1 + default: xak-flow-frame + GenericError: + type: object + description: Generic API Error + properties: + detail: + type: string + code: + type: string + required: + - detail + GeoIPPolicy: + type: object + description: GeoIP Policy Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy uuid + name: + type: string + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + bound_to: + type: integer + description: Return objects policy is bound to + readOnly: true + asns: + type: array + items: + type: integer + maximum: 2147483647 + minimum: -2147483648 + countries: + type: array + items: + $ref: '#/components/schemas/CountryCodeEnum' + maxItems: 249 + countries_obj: + type: array + items: + type: object + properties: + code: + type: string + minLength: 2 + maxLength: 2 + name: + type: string + required: + - code + - name + readOnly: true + check_history_distance: + type: boolean + history_max_distance_km: + type: integer + maximum: 9223372036854775807 + minimum: 0 + format: int64 + distance_tolerance_km: + type: integer + maximum: 2147483647 + minimum: 0 + history_login_count: + type: integer + maximum: 2147483647 + minimum: 0 + check_impossible_travel: + type: boolean + impossible_tolerance_km: + type: integer + maximum: 2147483647 + minimum: 0 + required: + - bound_to + - component + - countries + - countries_obj + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + GeoIPPolicyRequest: + type: object + description: GeoIP Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + asns: + type: array + items: + type: integer + maximum: 2147483647 + minimum: -2147483648 + countries: + type: array + items: + $ref: '#/components/schemas/CountryCodeEnum' + maxItems: 249 + check_history_distance: + type: boolean + history_max_distance_km: + type: integer + maximum: 9223372036854775807 + minimum: 0 + format: int64 + distance_tolerance_km: + type: integer + maximum: 2147483647 + minimum: 0 + history_login_count: + type: integer + maximum: 2147483647 + minimum: 0 + check_impossible_travel: + type: boolean + impossible_tolerance_km: + type: integer + maximum: 2147483647 + minimum: 0 + required: + - countries + - name + GeoipBindingEnum: + enum: + - no_binding + - bind_continent + - bind_continent_country + - bind_continent_country_city + type: string + GlobalTaskStatus: + type: object + properties: + queued: + type: integer + readOnly: true + consumed: + type: integer + readOnly: true + preprocess: + type: integer + readOnly: true + running: + type: integer + readOnly: true + postprocess: + type: integer + readOnly: true + rejected: + type: integer + readOnly: true + done: + type: integer + readOnly: true + info: + type: integer + readOnly: true + warning: + type: integer + readOnly: true + error: + type: integer + readOnly: true + required: + - consumed + - done + - error + - info + - postprocess + - preprocess + - queued + - rejected + - running + - warning + GoogleChromeConnector: + type: object + description: GoogleChromeConnector Serializer + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + enabled: + type: boolean + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + credentials: + type: object + additionalProperties: {} + chrome_url: + type: string + nullable: true + description: Full URL to be used in Google Workspace configuration + readOnly: true + required: + - chrome_url + - component + - credentials + - meta_model_name + - name + - verbose_name + - verbose_name_plural + GoogleChromeConnectorRequest: + type: object + description: GoogleChromeConnector Serializer + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + minLength: 1 + enabled: + type: boolean + credentials: + type: object + additionalProperties: {} + required: + - credentials + - name + GoogleEndpointDevice: + type: object + description: Serializer for Endpoint authenticator devices + properties: + pk: + type: string + format: uuid + title: Uuid + name: + type: string + description: The human-readable name of this device. + maxLength: 64 + required: + - name + GoogleEndpointDeviceRequest: + type: object + description: Serializer for Endpoint authenticator devices + properties: + pk: + type: string + format: uuid + title: Uuid + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + required: + - name + GoogleWorkspaceProvider: + type: object + description: GoogleWorkspaceProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + property_mappings: + type: array + items: + type: string + format: uuid + property_mappings_group: + type: array + items: + type: string + format: uuid + description: Property mappings used for group creation/updating. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + delegated_subject: + type: string + format: email + maxLength: 254 + credentials: + type: object + additionalProperties: {} + scopes: + type: string + exclude_users_service_account: + type: boolean + filter_group: + type: string + format: uuid + nullable: true + user_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + group_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + default_group_email_domain: + type: string + sync_page_size: + type: integer + maximum: 2147483647 + minimum: 1 + description: Controls the number of objects synced in a single task + sync_page_timeout: + type: string + description: Timeout for synchronization of a single page + dry_run: + type: boolean + description: When enabled, provider will not modify or create objects in + the remote system. + required: + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - component + - credentials + - default_group_email_domain + - delegated_subject + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + GoogleWorkspaceProviderGroup: + type: object + description: GoogleWorkspaceProviderGroup Serializer + properties: + id: + type: string + format: uuid + readOnly: true + google_id: + type: string + group: + type: string + format: uuid + group_obj: + allOf: + - $ref: '#/components/schemas/PartialGroup' + readOnly: true + provider: + type: integer + attributes: + type: object + additionalProperties: {} + readOnly: true + required: + - attributes + - google_id + - group + - group_obj + - id + - provider + GoogleWorkspaceProviderGroupRequest: + type: object + description: GoogleWorkspaceProviderGroup Serializer + properties: + google_id: + type: string + minLength: 1 + group: + type: string + format: uuid + provider: + type: integer + required: + - google_id + - group + - provider + GoogleWorkspaceProviderMapping: + type: object + description: GoogleWorkspaceProviderMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + GoogleWorkspaceProviderMappingRequest: + type: object + description: GoogleWorkspaceProviderMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + GoogleWorkspaceProviderRequest: + type: object + description: GoogleWorkspaceProvider Serializer + properties: + name: + type: string + minLength: 1 + property_mappings: + type: array + items: + type: string + format: uuid + property_mappings_group: + type: array + items: + type: string + format: uuid + description: Property mappings used for group creation/updating. + delegated_subject: + type: string + format: email + minLength: 1 + maxLength: 254 + credentials: + type: object + additionalProperties: {} + scopes: + type: string + minLength: 1 + exclude_users_service_account: + type: boolean + filter_group: + type: string + format: uuid + nullable: true + user_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + group_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + default_group_email_domain: + type: string + minLength: 1 + sync_page_size: + type: integer + maximum: 2147483647 + minimum: 1 + description: Controls the number of objects synced in a single task + sync_page_timeout: + type: string + minLength: 1 + description: Timeout for synchronization of a single page + dry_run: + type: boolean + description: When enabled, provider will not modify or create objects in + the remote system. + required: + - credentials + - default_group_email_domain + - delegated_subject + - name + GoogleWorkspaceProviderUser: + type: object + description: GoogleWorkspaceProviderUser Serializer + properties: + id: + type: string + format: uuid + readOnly: true + google_id: + type: string + user: + type: integer + user_obj: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + provider: + type: integer + attributes: + type: object + additionalProperties: {} + readOnly: true + required: + - attributes + - google_id + - id + - provider + - user + - user_obj + GoogleWorkspaceProviderUserRequest: + type: object + description: GoogleWorkspaceProviderUser Serializer + properties: + google_id: + type: string + minLength: 1 + user: + type: integer + provider: + type: integer + required: + - google_id + - provider + - user + GrantTypesEnum: + enum: + - authorization_code + - implicit + - hybrid + - refresh_token + - client_credentials + - password + - urn:ietf:params:oauth:grant-type:device_code + type: string + Group: + type: object + description: Group Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Group uuid + num_pk: + type: integer + readOnly: true + name: + type: string + is_superuser: + type: boolean + description: Users added to this group will be superusers. + parents: + type: array + items: + type: string + format: uuid + parents_obj: + type: array + items: + $ref: '#/components/schemas/RelatedGroup' + readOnly: true + nullable: true + users: + type: array + items: + type: integer + users_obj: + type: array + items: + $ref: '#/components/schemas/PartialUser' + readOnly: true + nullable: true + attributes: + type: object + additionalProperties: {} + roles: + type: array + items: + type: string + format: uuid + roles_obj: + type: array + items: + $ref: '#/components/schemas/Role' + readOnly: true + inherited_roles_obj: + type: array + items: + $ref: '#/components/schemas/Role' + readOnly: true + nullable: true + children: + type: array + items: + type: string + format: uuid + readOnly: true + children_obj: + type: array + items: + $ref: '#/components/schemas/RelatedGroup' + readOnly: true + nullable: true + required: + - children + - children_obj + - inherited_roles_obj + - name + - num_pk + - parents_obj + - pk + - roles_obj + - users_obj + GroupKerberosSourceConnection: + type: object + description: Group Source Connection + properties: + pk: + type: integer + readOnly: true + title: ID + group: + type: string + format: uuid + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - group + - identifier + - last_updated + - pk + - source + - source_obj + GroupKerberosSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + GroupLDAPSourceConnection: + type: object + description: Group Source Connection + properties: + pk: + type: integer + readOnly: true + title: ID + group: + type: string + format: uuid + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + group_obj: + allOf: + - $ref: '#/components/schemas/PartialGroup' + readOnly: true + required: + - created + - group + - group_obj + - identifier + - last_updated + - pk + - source + - source_obj + GroupLDAPSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + GroupMatchingModeEnum: + enum: + - identifier + - name_link + - name_deny + type: string + GroupOAuthSourceConnection: + type: object + description: Group Source Connection + properties: + pk: + type: integer + readOnly: true + title: ID + group: + type: string + format: uuid + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - group + - identifier + - last_updated + - pk + - source + - source_obj + GroupOAuthSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + GroupPlexSourceConnection: + type: object + description: Group Source Connection + properties: + pk: + type: integer + readOnly: true + title: ID + group: + type: string + format: uuid + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - group + - identifier + - last_updated + - pk + - source + - source_obj + GroupPlexSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + GroupRequest: + type: object + description: Group Serializer + properties: + name: + type: string + minLength: 1 + is_superuser: + type: boolean + description: Users added to this group will be superusers. + parents: + type: array + items: + type: string + format: uuid + users: + type: array + items: + type: integer + attributes: + type: object + additionalProperties: {} + roles: + type: array + items: + type: string + format: uuid + required: + - name + GroupSAMLSourceConnection: + type: object + description: Group Source Connection + properties: + pk: + type: integer + readOnly: true + title: ID + group: + type: string + format: uuid + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - group + - identifier + - last_updated + - pk + - source + - source_obj + GroupSAMLSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + GroupSourceConnection: + type: object + description: Group Source Connection + properties: + pk: + type: integer + readOnly: true + title: ID + group: + type: string + format: uuid + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - group + - identifier + - last_updated + - pk + - source + - source_obj + GroupSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + GroupTelegramSourceConnection: + type: object + description: Group Source Connection + properties: + pk: + type: integer + readOnly: true + title: ID + group: + type: string + format: uuid + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - group + - identifier + - last_updated + - pk + - source + - source_obj + GroupTelegramSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + Hardware: + type: object + properties: + model: + type: string + manufacturer: + type: string + serial: + type: string + cpu_name: + type: string + cpu_count: + type: integer + memory_bytes: + type: integer + format: int64 + required: + - serial + HardwareRequest: + type: object + properties: + model: + type: string + minLength: 1 + manufacturer: + type: string + minLength: 1 + serial: + type: string + minLength: 1 + cpu_name: + type: string + minLength: 1 + cpu_count: + type: integer + memory_bytes: + type: integer + format: int64 + required: + - serial + IdentificationChallenge: + type: object + description: Identification challenges with all UI elements + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-identification + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + user_fields: + type: array + items: + type: string + nullable: true + pending_user_identifier: + type: string + nullable: true + password_fields: + type: boolean + allow_show_password: + type: boolean + default: false + application_pre: + type: string + application_pre_launch: + type: string + flow_designation: + $ref: '#/components/schemas/FlowDesignationEnum' + captcha_stage: + allOf: + - $ref: '#/components/schemas/CaptchaChallenge' + nullable: true + enroll_url: + type: string + recovery_url: + type: string + passwordless_url: + type: string + primary_action: + type: string + sources: + type: array + items: + $ref: '#/components/schemas/LoginSource' + show_source_labels: + type: boolean + enable_remember_me: + type: boolean + default: true + passkey_challenge: + type: object + additionalProperties: {} + nullable: true + required: + - flow_designation + - password_fields + - primary_action + - show_source_labels + - user_fields + IdentificationChallengeResponseRequest: + type: object + description: Identification challenge + properties: + component: + type: string + minLength: 1 + default: ak-stage-identification + uid_field: + type: string + nullable: true + password: + type: string + nullable: true + captcha_token: + type: string + nullable: true + passkey: + type: object + additionalProperties: {} + nullable: true + IdentificationStage: + type: object + description: IdentificationStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + user_fields: + type: array + items: + $ref: '#/components/schemas/UserFieldsEnum' + description: Fields of the user object to match against. (Hold shift to + select multiple options) + password_stage: + type: string + format: uuid + nullable: true + description: When set, shows a password field, instead of showing the password + field as separate step. + captcha_stage: + type: string + format: uuid + nullable: true + description: When set, adds functionality exactly like a Captcha stage, + but baked into the Identification stage. + case_insensitive_matching: + type: boolean + description: When enabled, user fields are matched regardless of their casing. + show_matched_user: + type: boolean + description: When a valid username/email has been entered, and this option + is enabled, the user's username and avatar will be shown. Otherwise, the + text that the user entered will be shown + enrollment_flow: + type: string + format: uuid + nullable: true + description: Optional enrollment flow, which is linked at the bottom of + the page. + recovery_flow: + type: string + format: uuid + nullable: true + description: Optional recovery flow, which is linked at the bottom of the + page. + passwordless_flow: + type: string + format: uuid + nullable: true + description: Optional passwordless flow, which is linked at the bottom of + the page. + sources: + type: array + items: + type: string + format: uuid + description: Specify which sources should be shown. + show_source_labels: + type: boolean + pretend_user_exists: + type: boolean + description: When enabled, the stage will succeed and continue even when + incorrect user info is entered. + enable_remember_me: + type: boolean + description: Show the user the 'Remember me on this device' toggle, allowing + repeat users to skip straight to entering their password. + webauthn_stage: + type: string + format: uuid + nullable: true + description: When set, and conditional WebAuthn is available, allow the + user to use their passkey as a first factor. + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + IdentificationStageRequest: + type: object + description: IdentificationStage Serializer + properties: + name: + type: string + minLength: 1 + user_fields: + type: array + items: + $ref: '#/components/schemas/UserFieldsEnum' + description: Fields of the user object to match against. (Hold shift to + select multiple options) + password_stage: + type: string + format: uuid + nullable: true + description: When set, shows a password field, instead of showing the password + field as separate step. + captcha_stage: + type: string + format: uuid + nullable: true + description: When set, adds functionality exactly like a Captcha stage, + but baked into the Identification stage. + case_insensitive_matching: + type: boolean + description: When enabled, user fields are matched regardless of their casing. + show_matched_user: + type: boolean + description: When a valid username/email has been entered, and this option + is enabled, the user's username and avatar will be shown. Otherwise, the + text that the user entered will be shown + enrollment_flow: + type: string + format: uuid + nullable: true + description: Optional enrollment flow, which is linked at the bottom of + the page. + recovery_flow: + type: string + format: uuid + nullable: true + description: Optional recovery flow, which is linked at the bottom of the + page. + passwordless_flow: + type: string + format: uuid + nullable: true + description: Optional passwordless flow, which is linked at the bottom of + the page. + sources: + type: array + items: + type: string + format: uuid + description: Specify which sources should be shown. + show_source_labels: + type: boolean + pretend_user_exists: + type: boolean + description: When enabled, the stage will succeed and continue even when + incorrect user info is entered. + enable_remember_me: + type: boolean + description: Show the user the 'Remember me on this device' toggle, allowing + repeat users to skip straight to entering their password. + webauthn_stage: + type: string + format: uuid + nullable: true + description: When set, and conditional WebAuthn is available, allow the + user to use their passkey as a first factor. + required: + - name + IframeLogoutChallenge: + type: object + description: Challenge for iframe logout + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-provider-iframe-logout + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + logout_urls: + type: array + items: + $ref: '#/components/schemas/LogoutURL' + IframeLogoutChallengeResponseRequest: + type: object + description: Response for iframe logout + properties: + component: + type: string + minLength: 1 + default: ak-provider-iframe-logout + ImpersonationRequest: + type: object + properties: + reason: + type: string + minLength: 1 + required: + - reason + InitialPermissions: + type: object + description: InitialPermissions serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + maxLength: 150 + role: + type: string + format: uuid + permissions: + type: array + items: + type: integer + permissions_obj: + type: array + items: + $ref: '#/components/schemas/Permission' + readOnly: true + required: + - name + - permissions_obj + - pk + - role + InitialPermissionsRequest: + type: object + description: InitialPermissions serializer + properties: + name: + type: string + minLength: 1 + maxLength: 150 + role: + type: string + format: uuid + permissions: + type: array + items: + type: integer + required: + - name + - role + InstallID: + type: object + properties: + install_id: + type: string + required: + - install_id + IntentEnum: + enum: + - verification + - api + - recovery + - app_password + type: string + InvalidResponseActionEnum: + enum: + - retry + - restart + - restart_with_context + type: string + Invitation: + type: object + description: Invitation Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Invite uuid + name: + type: string + pattern: ^[-a-zA-Z0-9_]+$ + expires: + type: string + format: date-time + nullable: true + fixed_data: + type: object + additionalProperties: {} + created_by: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + single_use: + type: boolean + description: When enabled, the invitation will be deleted after usage. + flow: + type: string + format: uuid + nullable: true + description: When set, only the configured flow can use this invitation. + flow_obj: + allOf: + - $ref: '#/components/schemas/Flow' + readOnly: true + required: + - created_by + - flow_obj + - name + - pk + InvitationRequest: + type: object + description: Invitation Serializer + properties: + name: + type: string + minLength: 1 + pattern: ^[-a-zA-Z0-9_]+$ + expires: + type: string + format: date-time + nullable: true + fixed_data: + type: object + additionalProperties: {} + single_use: + type: boolean + description: When enabled, the invitation will be deleted after usage. + flow: + type: string + format: uuid + nullable: true + description: When set, only the configured flow can use this invitation. + required: + - name + InvitationSendEmailRequest: + type: object + description: Serializer for sending invitation emails + properties: + email_addresses: + type: array + items: {} + cc_addresses: + type: array + items: {} + bcc_addresses: + type: array + items: {} + template: + type: string + minLength: 1 + default: invitation + required: + - email_addresses + InvitationStage: + type: object + description: InvitationStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + continue_flow_without_invitation: + type: boolean + description: If this flag is set, this Stage will jump to the next Stage + when no Invitation is given. By default this Stage will cancel the Flow + when no invitation is given. + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + InvitationStageRequest: + type: object + description: InvitationStage Serializer + properties: + name: + type: string + minLength: 1 + continue_flow_without_invitation: + type: boolean + description: If this flag is set, this Stage will jump to the next Stage + when no Invitation is given. By default this Stage will cancel the Flow + when no invitation is given. + required: + - name + IssuerModeEnum: + enum: + - global + - per_provider + type: string + KadminTypeEnum: + enum: + - MIT + - Heimdal + type: string + KerberosSource: + type: object + description: Kerberos Source Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + description: Source's display Name. + slug: + type: string + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + readOnly: true + user_path_template: + type: string + icon: + type: string + icon_url: + type: string + readOnly: true + icon_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + realm: + type: string + description: Kerberos realm + krb5_conf: + type: string + description: Custom krb5.conf to use. Uses the system one by default + kadmin_type: + allOf: + - $ref: '#/components/schemas/KadminTypeEnum' + description: KAdmin server type + sync_users: + type: boolean + description: Sync users from Kerberos into authentik + sync_users_password: + type: boolean + description: When a user changes their password, sync it back to Kerberos + sync_principal: + type: string + description: Principal to authenticate to kadmin for sync. + connectivity: + type: object + additionalProperties: + type: string + nullable: true + description: Get cached source connectivity + readOnly: true + spnego_server_name: + type: string + description: Force the use of a specific server name for SPNEGO. Must be + in the form HTTP@hostname + password_login_update_internal_password: + type: boolean + description: If enabled, the authentik-stored password will be updated upon + login with the Kerberos password backend + sync_outgoing_trigger_mode: + allOf: + - $ref: '#/components/schemas/SyncOutgoingTriggerModeEnum' + description: When to trigger sync for outgoing providers + required: + - component + - connectivity + - icon_themed_urls + - icon_url + - managed + - meta_model_name + - name + - pk + - realm + - slug + - verbose_name + - verbose_name_plural + KerberosSourcePropertyMapping: + type: object + description: Kerberos PropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + KerberosSourcePropertyMappingRequest: + type: object + description: Kerberos PropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + KerberosSourceRequest: + type: object + description: Kerberos Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + realm: + type: string + minLength: 1 + description: Kerberos realm + krb5_conf: + type: string + description: Custom krb5.conf to use. Uses the system one by default + kadmin_type: + allOf: + - $ref: '#/components/schemas/KadminTypeEnum' + description: KAdmin server type + sync_users: + type: boolean + description: Sync users from Kerberos into authentik + sync_users_password: + type: boolean + description: When a user changes their password, sync it back to Kerberos + sync_principal: + type: string + description: Principal to authenticate to kadmin for sync. + sync_password: + type: string + writeOnly: true + description: Password to authenticate to kadmin for sync + sync_keytab: + type: string + writeOnly: true + description: Keytab to authenticate to kadmin for sync. Must be base64-encoded + or in the form TYPE:residual + sync_ccache: + type: string + writeOnly: true + description: Credentials cache to authenticate to kadmin for sync. Must + be in the form TYPE:residual + spnego_server_name: + type: string + description: Force the use of a specific server name for SPNEGO. Must be + in the form HTTP@hostname + spnego_keytab: + type: string + writeOnly: true + description: SPNEGO keytab base64-encoded or path to keytab in the form + FILE:path + spnego_ccache: + type: string + writeOnly: true + description: Credential cache to use for SPNEGO in form type:residual + password_login_update_internal_password: + type: boolean + description: If enabled, the authentik-stored password will be updated upon + login with the Kerberos password backend + sync_outgoing_trigger_mode: + allOf: + - $ref: '#/components/schemas/SyncOutgoingTriggerModeEnum' + description: When to trigger sync for outgoing providers + required: + - name + - realm + - slug + KeyTypeEnum: + type: string + enum: + - dsa + - ec + - ed25519 + - ed448 + - rsa + KubernetesServiceConnection: + type: object + description: KubernetesServiceConnection Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Uuid + name: + type: string + local: + type: boolean + description: If enabled, use the local connection. Required Docker socket/Kubernetes + Integration + component: + type: string + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + kubeconfig: + type: object + additionalProperties: {} + description: Paste your kubeconfig here. authentik will automatically use + the currently selected context. + verify_ssl: + type: boolean + description: Verify SSL Certificates of the Kubernetes API endpoint + required: + - component + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + KubernetesServiceConnectionRequest: + type: object + description: KubernetesServiceConnection Serializer + properties: + name: + type: string + minLength: 1 + local: + type: boolean + description: If enabled, use the local connection. Required Docker socket/Kubernetes + Integration + kubeconfig: + type: object + additionalProperties: {} + description: Paste your kubeconfig here. authentik will automatically use + the currently selected context. + verify_ssl: + type: boolean + description: Verify SSL Certificates of the Kubernetes API endpoint + required: + - name + LDAPAPIAccessMode: + enum: + - direct + - cached + type: string + LDAPCheckAccess: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + has_search_permission: + type: boolean + access: + $ref: '#/components/schemas/PolicyTestResult' + required: + - access + LDAPDebug: + type: object + properties: + user: + type: array + items: + type: object + additionalProperties: {} + readOnly: true + group: + type: array + items: + type: object + additionalProperties: {} + readOnly: true + membership: + type: array + items: + type: object + additionalProperties: {} + readOnly: true + required: + - group + - membership + - user + LDAPOutpostConfig: + type: object + description: LDAPProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + base_dn: + type: string + description: DN under which objects are accessible. + bind_flow_slug: + type: string + unbind_flow_slug: + type: string + nullable: true + description: Get slug for unbind flow, defaulting to brand's default flow. + readOnly: true + application_slug: + type: string + description: Prioritise backchannel slug over direct application slug + readOnly: true + certificate: + type: string + format: uuid + nullable: true + tls_server_name: + type: string + uid_start_number: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: The start for uidNumbers, this number is added to the user.pk + to make sure that the numbers aren't too low for POSIX users. Default + is 2000 to ensure that we don't collide with local users uidNumber + gid_start_number: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: The start for gidNumbers, this number is added to a number + generated from the group.pk to make sure that the numbers aren't too low + for POSIX groups. Default is 4000 to ensure that we don't collide with + local groups or users primary groups gidNumber + search_mode: + $ref: '#/components/schemas/LDAPAPIAccessMode' + bind_mode: + $ref: '#/components/schemas/LDAPAPIAccessMode' + mfa_support: + type: boolean + description: When enabled, code-based multi-factor authentication can be + used by appending a semicolon and the TOTP code to the password. This + should only be enabled if all users that will bind to this provider have + a TOTP device configured, as otherwise a password may incorrectly be rejected + if it contains a semicolon. + required: + - application_slug + - bind_flow_slug + - name + - pk + - unbind_flow_slug + LDAPProvider: + type: object + description: LDAPProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + base_dn: + type: string + description: DN under which objects are accessible. + certificate: + type: string + format: uuid + nullable: true + tls_server_name: + type: string + uid_start_number: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: The start for uidNumbers, this number is added to the user.pk + to make sure that the numbers aren't too low for POSIX users. Default + is 2000 to ensure that we don't collide with local users uidNumber + gid_start_number: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: The start for gidNumbers, this number is added to a number + generated from the group.pk to make sure that the numbers aren't too low + for POSIX groups. Default is 4000 to ensure that we don't collide with + local groups or users primary groups gidNumber + outpost_set: + type: array + items: + type: string + readOnly: true + search_mode: + $ref: '#/components/schemas/LDAPAPIAccessMode' + bind_mode: + $ref: '#/components/schemas/LDAPAPIAccessMode' + mfa_support: + type: boolean + description: When enabled, code-based multi-factor authentication can be + used by appending a semicolon and the TOTP code to the password. This + should only be enabled if all users that will bind to this provider have + a TOTP device configured, as otherwise a password may incorrectly be rejected + if it contains a semicolon. + required: + - assigned_application_name + - assigned_application_slug + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - authorization_flow + - component + - invalidation_flow + - meta_model_name + - name + - outpost_set + - pk + - verbose_name + - verbose_name_plural + LDAPProviderRequest: + type: object + description: LDAPProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + base_dn: + type: string + minLength: 1 + description: DN under which objects are accessible. + certificate: + type: string + format: uuid + nullable: true + tls_server_name: + type: string + uid_start_number: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: The start for uidNumbers, this number is added to the user.pk + to make sure that the numbers aren't too low for POSIX users. Default + is 2000 to ensure that we don't collide with local users uidNumber + gid_start_number: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: The start for gidNumbers, this number is added to a number + generated from the group.pk to make sure that the numbers aren't too low + for POSIX groups. Default is 4000 to ensure that we don't collide with + local groups or users primary groups gidNumber + search_mode: + $ref: '#/components/schemas/LDAPAPIAccessMode' + bind_mode: + $ref: '#/components/schemas/LDAPAPIAccessMode' + mfa_support: + type: boolean + description: When enabled, code-based multi-factor authentication can be + used by appending a semicolon and the TOTP code to the password. This + should only be enabled if all users that will bind to this provider have + a TOTP device configured, as otherwise a password may incorrectly be rejected + if it contains a semicolon. + required: + - authorization_flow + - invalidation_flow + - name + LDAPSource: + type: object + description: LDAP Source Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + description: Source's display Name. + slug: + type: string + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + readOnly: true + user_path_template: + type: string + icon: + type: string + icon_url: + type: string + readOnly: true + icon_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + server_uri: + type: string + format: uri + peer_certificate: + type: string + format: uuid + nullable: true + description: Optionally verify the LDAP Server's Certificate against the + CA Chain in this keypair. + client_certificate: + type: string + format: uuid + nullable: true + description: Client certificate to authenticate against the LDAP Server's + Certificate. + bind_cn: + type: string + start_tls: + type: boolean + title: Enable Start TLS + sni: + type: boolean + title: Use Server URI for SNI verification + base_dn: + type: string + additional_user_dn: + type: string + title: Addition User DN + description: Prepended to Base DN for User-queries. + additional_group_dn: + type: string + title: Addition Group DN + description: Prepended to Base DN for Group-queries. + user_object_filter: + type: string + description: Consider Objects matching this filter to be Users. + group_object_filter: + type: string + description: Consider Objects matching this filter to be Groups. + group_membership_field: + type: string + description: Field which contains members of a group. + user_membership_attribute: + type: string + description: Attribute which matches the value of `group_membership_field`. + object_uniqueness_field: + type: string + description: Field which contains a unique Identifier. + password_login_update_internal_password: + type: boolean + description: Update internal authentik password when login succeeds with + LDAP + sync_users: + type: boolean + sync_users_password: + type: boolean + description: When a user changes their password, sync it back to LDAP. This + can only be enabled on a single LDAP source. + sync_groups: + type: boolean + sync_parent_group: + type: string + format: uuid + nullable: true + connectivity: + type: object + additionalProperties: + type: object + additionalProperties: + type: string + nullable: true + description: Get cached source connectivity + readOnly: true + lookup_groups_from_user: + type: boolean + description: Lookup group membership based on a user attribute instead of + a group attribute. This allows nested group resolution on systems like + FreeIPA and Active Directory + delete_not_found_objects: + type: boolean + description: Delete authentik users and groups which were previously supplied + by this source, but are now missing from it. + sync_outgoing_trigger_mode: + allOf: + - $ref: '#/components/schemas/SyncOutgoingTriggerModeEnum' + description: When to trigger sync for outgoing providers + required: + - base_dn + - component + - connectivity + - icon_themed_urls + - icon_url + - managed + - meta_model_name + - name + - pk + - server_uri + - slug + - verbose_name + - verbose_name_plural + LDAPSourcePropertyMapping: + type: object + description: LDAP PropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + LDAPSourcePropertyMappingRequest: + type: object + description: LDAP PropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + LDAPSourceRequest: + type: object + description: LDAP Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + server_uri: + type: string + minLength: 1 + format: uri + peer_certificate: + type: string + format: uuid + nullable: true + description: Optionally verify the LDAP Server's Certificate against the + CA Chain in this keypair. + client_certificate: + type: string + format: uuid + nullable: true + description: Client certificate to authenticate against the LDAP Server's + Certificate. + bind_cn: + type: string + bind_password: + type: string + writeOnly: true + start_tls: + type: boolean + title: Enable Start TLS + sni: + type: boolean + title: Use Server URI for SNI verification + base_dn: + type: string + minLength: 1 + additional_user_dn: + type: string + title: Addition User DN + description: Prepended to Base DN for User-queries. + additional_group_dn: + type: string + title: Addition Group DN + description: Prepended to Base DN for Group-queries. + user_object_filter: + type: string + minLength: 1 + description: Consider Objects matching this filter to be Users. + group_object_filter: + type: string + minLength: 1 + description: Consider Objects matching this filter to be Groups. + group_membership_field: + type: string + minLength: 1 + description: Field which contains members of a group. + user_membership_attribute: + type: string + minLength: 1 + description: Attribute which matches the value of `group_membership_field`. + object_uniqueness_field: + type: string + minLength: 1 + description: Field which contains a unique Identifier. + password_login_update_internal_password: + type: boolean + description: Update internal authentik password when login succeeds with + LDAP + sync_users: + type: boolean + sync_users_password: + type: boolean + description: When a user changes their password, sync it back to LDAP. This + can only be enabled on a single LDAP source. + sync_groups: + type: boolean + sync_parent_group: + type: string + format: uuid + nullable: true + lookup_groups_from_user: + type: boolean + description: Lookup group membership based on a user attribute instead of + a group attribute. This allows nested group resolution on systems like + FreeIPA and Active Directory + delete_not_found_objects: + type: boolean + description: Delete authentik users and groups which were previously supplied + by this source, but are now missing from it. + sync_outgoing_trigger_mode: + allOf: + - $ref: '#/components/schemas/SyncOutgoingTriggerModeEnum' + description: When to trigger sync for outgoing providers + required: + - base_dn + - name + - server_uri + - slug + LangEnum: + type: string + enum: + - af + - ar + - ar-dz + - ast + - az + - be + - bg + - bn + - br + - bs + - ca + - ckb + - cs + - cy + - da + - de + - dsb + - el + - en + - en-au + - en-gb + - eo + - es + - es-ar + - es-co + - es-mx + - es-ni + - es-ve + - et + - eu + - fa + - fi + - fr + - fy + - ga + - gd + - gl + - he + - hi + - hr + - hsb + - hu + - hy + - ia + - id + - ig + - io + - is + - it + - ja + - ka + - kab + - kk + - km + - kn + - ko + - ky + - lb + - lt + - lv + - mk + - ml + - mn + - mr + - ms + - my + - nb + - ne + - nl + - nn + - os + - pa + - pl + - pt + - pt-br + - ro + - ru + - sk + - sl + - sq + - sr + - sr-latn + - sv + - sw + - ta + - te + - tg + - th + - tk + - tr + - tt + - udm + - ug + - uk + - ur + - uz + - vi + - zh-hans + - zh-hant + LastTaskStatusEnum: + enum: + - queued + - consumed + - preprocess + - running + - postprocess + - rejected + - done + - info + - warning + - error + type: string + License: + type: object + description: License Serializer + properties: + license_uuid: + type: string + format: uuid + readOnly: true + name: + type: string + readOnly: true + key: + type: string + expiry: + type: string + format: date-time + readOnly: true + internal_users: + type: integer + readOnly: true + external_users: + type: integer + readOnly: true + required: + - expiry + - external_users + - internal_users + - key + - license_uuid + - name + LicenseFlagsEnum: + enum: + - trial + - non_production + type: string + LicenseForecast: + type: object + description: Serializer for license forecast + properties: + internal_users: + type: integer + external_users: + type: integer + forecasted_internal_users: + type: integer + forecasted_external_users: + type: integer + required: + - external_users + - forecasted_external_users + - forecasted_internal_users + - internal_users + LicenseRequest: + type: object + description: License Serializer + properties: + key: + type: string + minLength: 1 + required: + - key + LicenseStatusEnum: + enum: + - unlicensed + - valid + - expired + - expiry_soon + - limit_exceeded_admin + - limit_exceeded_user + - read_only + type: string + LicenseSummary: + type: object + description: Serializer for license status + properties: + internal_users: + type: integer + external_users: + type: integer + status: + $ref: '#/components/schemas/LicenseSummaryStatusEnum' + latest_valid: + type: string + format: date-time + license_flags: + type: array + items: + $ref: '#/components/schemas/LicenseFlagsEnum' + required: + - external_users + - internal_users + - latest_valid + - license_flags + - status + LicenseSummaryStatusEnum: + enum: + - unlicensed + - valid + - expired + - expiry_soon + - limit_exceeded_admin + - limit_exceeded_user + - read_only + type: string + LifecycleIteration: + type: object + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + properties: + id: + type: string + format: uuid + readOnly: true + content_type: + $ref: '#/components/schemas/ContentTypeEnum' + object_id: + type: string + readOnly: true + object_verbose: + type: string + readOnly: true + object_admin_url: + type: string + readOnly: true + state: + allOf: + - $ref: '#/components/schemas/LifecycleIterationStateEnum' + readOnly: true + opened_on: + type: string + format: date-time + readOnly: true + grace_period_end: + type: string + format: date-time + readOnly: true + next_review_date: + type: string + format: date-time + readOnly: true + reviews: + type: array + items: + $ref: '#/components/schemas/Review' + readOnly: true + rule: + allOf: + - $ref: '#/components/schemas/RelatedRule' + readOnly: true + user_can_review: + type: boolean + readOnly: true + required: + - content_type + - grace_period_end + - id + - next_review_date + - object_admin_url + - object_id + - object_verbose + - opened_on + - reviews + - rule + - state + - user_can_review + LifecycleIterationRequest: + type: object + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + properties: + content_type: + $ref: '#/components/schemas/ContentTypeEnum' + required: + - content_type + LifecycleIterationStateEnum: + enum: + - REVIEWED + - PENDING + - OVERDUE + - CANCELED + type: string + LifecycleRule: + type: object + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + properties: + id: + type: string + format: uuid + readOnly: true + name: + type: string + content_type: + $ref: '#/components/schemas/ContentTypeEnum' + object_id: + type: string + nullable: true + interval: + type: string + grace_period: + type: string + reviewer_groups: + type: array + items: + type: string + format: uuid + reviewer_groups_obj: + type: array + items: + $ref: '#/components/schemas/ReviewerGroup' + readOnly: true + min_reviewers: + type: integer + maximum: 32767 + minimum: 0 + min_reviewers_is_per_group: + type: boolean + reviewers: + type: array + items: + type: string + format: uuid + reviewers_obj: + type: array + items: + $ref: '#/components/schemas/ReviewerUser' + readOnly: true + notification_transports: + type: array + items: + type: string + format: uuid + description: Select which transports should be used to notify the reviewers. + If none are selected, the notification will only be shown in the authentik + UI. + target_verbose: + type: string + readOnly: true + required: + - content_type + - id + - name + - reviewer_groups_obj + - reviewers + - reviewers_obj + - target_verbose + LifecycleRuleRequest: + type: object + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + properties: + name: + type: string + minLength: 1 + content_type: + $ref: '#/components/schemas/ContentTypeEnum' + object_id: + type: string + nullable: true + minLength: 1 + interval: + type: string + minLength: 1 + grace_period: + type: string + minLength: 1 + reviewer_groups: + type: array + items: + type: string + format: uuid + min_reviewers: + type: integer + maximum: 32767 + minimum: 0 + min_reviewers_is_per_group: + type: boolean + reviewers: + type: array + items: + type: string + format: uuid + notification_transports: + type: array + items: + type: string + format: uuid + description: Select which transports should be used to notify the reviewers. + If none are selected, the notification will only be shown in the authentik + UI. + required: + - content_type + - name + - reviewers + Link: + type: object + description: Returns a single link + properties: + link: + type: string + required: + - link + LogEvent: + type: object + description: Single log message with all context logged. + properties: + timestamp: + type: string + format: date-time + log_level: + $ref: '#/components/schemas/LogLevelEnum' + logger: + type: string + event: + type: string + attributes: + type: object + additionalProperties: {} + required: + - attributes + - event + - log_level + - logger + - timestamp + LogLevelEnum: + enum: + - critical + - exception + - error + - warn + - warning + - info + - debug + - notset + type: string + LoginChallengeTypes: + oneOf: + - $ref: '#/components/schemas/RedirectChallenge' + - $ref: '#/components/schemas/AppleLoginChallenge' + - $ref: '#/components/schemas/PlexAuthenticationChallenge' + - $ref: '#/components/schemas/TelegramLoginChallenge' + discriminator: + propertyName: component + mapping: + xak-flow-redirect: '#/components/schemas/RedirectChallenge' + ak-source-oauth-apple: '#/components/schemas/AppleLoginChallenge' + ak-source-plex: '#/components/schemas/PlexAuthenticationChallenge' + ak-source-telegram: '#/components/schemas/TelegramLoginChallenge' + LoginSource: + type: object + description: Serializer for Login buttons of sources + properties: + name: + type: string + icon_url: + type: string + nullable: true + promoted: + type: boolean + default: false + challenge: + $ref: '#/components/schemas/LoginChallengeTypes' + required: + - challenge + - name + LogoutURL: + type: object + description: Data for a single logout URL + properties: + url: + type: string + provider_name: + type: string + nullable: true + binding: + type: string + nullable: true + saml_request: + type: string + nullable: true + saml_response: + type: string + nullable: true + saml_relay_state: + type: string + nullable: true + required: + - url + MDMConfigRequest: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + platform: + $ref: '#/components/schemas/DeviceFactsOSFamily' + enrollment_token: + type: string + format: uuid + required: + - enrollment_token + - platform + MDMConfigResponse: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + config: + type: string + mime_type: + type: string + filename: + type: string + required: + - config + - filename + - mime_type + MatchingModeEnum: + enum: + - strict + - regex + type: string + Metadata: + type: object + description: Serializer for blueprint metadata + properties: + name: + type: string + labels: + type: object + additionalProperties: {} + required: + - labels + - name + MicrosoftEntraProvider: + type: object + description: MicrosoftEntraProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + property_mappings: + type: array + items: + type: string + format: uuid + property_mappings_group: + type: array + items: + type: string + format: uuid + description: Property mappings used for group creation/updating. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + client_id: + type: string + tenant_id: + type: string + exclude_users_service_account: + type: boolean + filter_group: + type: string + format: uuid + nullable: true + user_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + group_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + sync_page_size: + type: integer + maximum: 2147483647 + minimum: 1 + description: Controls the number of objects synced in a single task + sync_page_timeout: + type: string + description: Timeout for synchronization of a single page + dry_run: + type: boolean + description: When enabled, provider will not modify or create objects in + the remote system. + required: + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - client_id + - component + - meta_model_name + - name + - pk + - tenant_id + - verbose_name + - verbose_name_plural + MicrosoftEntraProviderGroup: + type: object + description: MicrosoftEntraProviderGroup Serializer + properties: + id: + type: string + format: uuid + readOnly: true + microsoft_id: + type: string + group: + type: string + format: uuid + group_obj: + allOf: + - $ref: '#/components/schemas/PartialGroup' + readOnly: true + provider: + type: integer + attributes: + type: object + additionalProperties: {} + readOnly: true + required: + - attributes + - group + - group_obj + - id + - microsoft_id + - provider + MicrosoftEntraProviderGroupRequest: + type: object + description: MicrosoftEntraProviderGroup Serializer + properties: + microsoft_id: + type: string + minLength: 1 + group: + type: string + format: uuid + provider: + type: integer + required: + - group + - microsoft_id + - provider + MicrosoftEntraProviderMapping: + type: object + description: MicrosoftEntraProviderMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + MicrosoftEntraProviderMappingRequest: + type: object + description: MicrosoftEntraProviderMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + MicrosoftEntraProviderRequest: + type: object + description: MicrosoftEntraProvider Serializer + properties: + name: + type: string + minLength: 1 + property_mappings: + type: array + items: + type: string + format: uuid + property_mappings_group: + type: array + items: + type: string + format: uuid + description: Property mappings used for group creation/updating. + client_id: + type: string + minLength: 1 + client_secret: + type: string + writeOnly: true + minLength: 1 + tenant_id: + type: string + minLength: 1 + exclude_users_service_account: + type: boolean + filter_group: + type: string + format: uuid + nullable: true + user_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + group_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + sync_page_size: + type: integer + maximum: 2147483647 + minimum: 1 + description: Controls the number of objects synced in a single task + sync_page_timeout: + type: string + minLength: 1 + description: Timeout for synchronization of a single page + dry_run: + type: boolean + description: When enabled, provider will not modify or create objects in + the remote system. + required: + - client_id + - client_secret + - name + - tenant_id + MicrosoftEntraProviderUser: + type: object + description: MicrosoftEntraProviderUser Serializer + properties: + id: + type: string + format: uuid + readOnly: true + microsoft_id: + type: string + user: + type: integer + user_obj: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + provider: + type: integer + attributes: + type: object + additionalProperties: {} + readOnly: true + required: + - attributes + - id + - microsoft_id + - provider + - user + - user_obj + MicrosoftEntraProviderUserRequest: + type: object + description: MicrosoftEntraProviderUser Serializer + properties: + microsoft_id: + type: string + minLength: 1 + user: + type: integer + provider: + type: integer + required: + - microsoft_id + - provider + - user + ModelEnum: + enum: + - authentik_tenants.domain + - authentik_core.group + - authentik_core.user + - authentik_core.application + - authentik_core.applicationentitlement + - authentik_core.token + - authentik_crypto.certificatekeypair + - authentik_endpoints.deviceuserbinding + - authentik_endpoints.deviceaccessgroup + - authentik_endpoints.endpointstage + - authentik_endpoints_connectors_agent.agentconnector + - authentik_endpoints_connectors_agent.agentdeviceuserbinding + - authentik_endpoints_connectors_agent.enrollmenttoken + - authentik_enterprise.license + - authentik_events.event + - authentik_events.notificationtransport + - authentik_events.notification + - authentik_events.notificationrule + - authentik_events.notificationwebhookmapping + - authentik_flows.flow + - authentik_flows.flowstagebinding + - authentik_outposts.dockerserviceconnection + - authentik_outposts.kubernetesserviceconnection + - authentik_outposts.outpost + - authentik_policies_dummy.dummypolicy + - authentik_policies_event_matcher.eventmatcherpolicy + - authentik_policies_expiry.passwordexpirypolicy + - authentik_policies_expression.expressionpolicy + - authentik_policies_geoip.geoippolicy + - authentik_policies_password.passwordpolicy + - authentik_policies_reputation.reputationpolicy + - authentik_policies.policybinding + - authentik_providers_ldap.ldapprovider + - authentik_providers_oauth2.scopemapping + - authentik_providers_oauth2.oauth2provider + - authentik_providers_proxy.proxyprovider + - authentik_providers_rac.racprovider + - authentik_providers_rac.endpoint + - authentik_providers_rac.racpropertymapping + - authentik_providers_radius.radiusprovider + - authentik_providers_radius.radiusproviderpropertymapping + - authentik_providers_saml.samlprovider + - authentik_providers_saml.samlpropertymapping + - authentik_providers_scim.scimprovider + - authentik_providers_scim.scimmapping + - authentik_rbac.role + - authentik_rbac.initialpermissions + - authentik_sources_kerberos.kerberossource + - authentik_sources_kerberos.kerberossourcepropertymapping + - authentik_sources_kerberos.userkerberossourceconnection + - authentik_sources_kerberos.groupkerberossourceconnection + - authentik_sources_ldap.ldapsource + - authentik_sources_ldap.ldapsourcepropertymapping + - authentik_sources_ldap.userldapsourceconnection + - authentik_sources_ldap.groupldapsourceconnection + - authentik_sources_oauth.oauthsource + - authentik_sources_oauth.oauthsourcepropertymapping + - authentik_sources_oauth.useroauthsourceconnection + - authentik_sources_oauth.groupoauthsourceconnection + - authentik_sources_plex.plexsource + - authentik_sources_plex.plexsourcepropertymapping + - authentik_sources_plex.userplexsourceconnection + - authentik_sources_plex.groupplexsourceconnection + - authentik_sources_saml.samlsource + - authentik_sources_saml.samlsourcepropertymapping + - authentik_sources_saml.usersamlsourceconnection + - authentik_sources_saml.groupsamlsourceconnection + - authentik_sources_scim.scimsource + - authentik_sources_scim.scimsourcepropertymapping + - authentik_sources_telegram.telegramsource + - authentik_sources_telegram.telegramsourcepropertymapping + - authentik_sources_telegram.usertelegramsourceconnection + - authentik_sources_telegram.grouptelegramsourceconnection + - authentik_stages_authenticator_duo.authenticatorduostage + - authentik_stages_authenticator_duo.duodevice + - authentik_stages_authenticator_email.authenticatoremailstage + - authentik_stages_authenticator_email.emaildevice + - authentik_stages_authenticator_sms.authenticatorsmsstage + - authentik_stages_authenticator_sms.smsdevice + - authentik_stages_authenticator_static.authenticatorstaticstage + - authentik_stages_authenticator_static.staticdevice + - authentik_stages_authenticator_totp.authenticatortotpstage + - authentik_stages_authenticator_totp.totpdevice + - authentik_stages_authenticator_validate.authenticatorvalidatestage + - authentik_stages_authenticator_webauthn.authenticatorwebauthnstage + - authentik_stages_authenticator_webauthn.webauthndevice + - authentik_stages_captcha.captchastage + - authentik_stages_consent.consentstage + - authentik_stages_deny.denystage + - authentik_stages_dummy.dummystage + - authentik_stages_email.emailstage + - authentik_stages_identification.identificationstage + - authentik_stages_invitation.invitationstage + - authentik_stages_invitation.invitation + - authentik_stages_password.passwordstage + - authentik_stages_prompt.prompt + - authentik_stages_prompt.promptstage + - authentik_stages_redirect.redirectstage + - authentik_stages_user_delete.userdeletestage + - authentik_stages_user_login.userloginstage + - authentik_stages_user_logout.userlogoutstage + - authentik_stages_user_write.userwritestage + - authentik_tasks_schedules.schedule + - authentik_brands.brand + - authentik_blueprints.blueprintinstance + - authentik_endpoints_connectors_fleet.fleetconnector + - authentik_endpoints_connectors_google_chrome.googlechromeconnector + - authentik_lifecycle.lifecyclerule + - authentik_lifecycle.lifecycleiteration + - authentik_lifecycle.review + - authentik_policies_unique_password.uniquepasswordpolicy + - authentik_providers_google_workspace.googleworkspaceprovider + - authentik_providers_google_workspace.googleworkspaceprovidermapping + - authentik_providers_microsoft_entra.microsoftentraprovider + - authentik_providers_microsoft_entra.microsoftentraprovidermapping + - authentik_providers_ssf.ssfprovider + - authentik_providers_ws_federation.wsfederationprovider + - authentik_reports.dataexport + - authentik_stages_account_lockdown.accountlockdownstage + - authentik_stages_authenticator_endpoint_gdtc.authenticatorendpointgdtcstage + - authentik_stages_mtls.mutualtlsstage + - authentik_stages_source.sourcestage + type: string + MutualTLSStage: + type: object + description: MutualTLSStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + mode: + $ref: '#/components/schemas/StageModeEnum' + certificate_authorities: + type: array + items: + type: string + format: uuid + description: Configure certificate authorities to validate the certificate + against. This option has a higher priority than the `client_certificate` + option on `Brand`. + cert_attribute: + $ref: '#/components/schemas/CertAttributeEnum' + user_attribute: + $ref: '#/components/schemas/UserAttributeEnum' + required: + - cert_attribute + - component + - flow_set + - meta_model_name + - mode + - name + - pk + - user_attribute + - verbose_name + - verbose_name_plural + MutualTLSStageRequest: + type: object + description: MutualTLSStage Serializer + properties: + name: + type: string + minLength: 1 + mode: + $ref: '#/components/schemas/StageModeEnum' + certificate_authorities: + type: array + items: + type: string + format: uuid + description: Configure certificate authorities to validate the certificate + against. This option has a higher priority than the `client_certificate` + option on `Brand`. + cert_attribute: + $ref: '#/components/schemas/CertAttributeEnum' + user_attribute: + $ref: '#/components/schemas/UserAttributeEnum' + required: + - cert_attribute + - mode + - name + - user_attribute + NativeLogoutChallenge: + type: object + description: Challenge for native browser logout + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-provider-saml-native-logout + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + provider_name: + type: string + is_complete: + type: boolean + default: false + post_url: + type: string + redirect_url: + type: string + saml_binding: + $ref: '#/components/schemas/SAMLBindingsEnum' + saml_request: + type: string + saml_response: + type: string + saml_relay_state: + type: string + NativeLogoutChallengeResponseRequest: + type: object + description: Response for native browser logout + properties: + component: + type: string + minLength: 1 + default: ak-provider-saml-native-logout + Network: + type: object + properties: + hostname: + type: string + firewall_enabled: + type: boolean + interfaces: + type: array + items: + $ref: '#/components/schemas/NetworkInterface' + gateway: + type: string + required: + - hostname + - interfaces + NetworkBindingEnum: + enum: + - no_binding + - bind_asn + - bind_asn_network + - bind_asn_network_ip + type: string + NetworkInterface: + type: object + properties: + name: + type: string + hardware_address: + type: string + ip_addresses: + type: array + items: + type: string + dns_servers: + type: array + items: + type: string + required: + - hardware_address + - name + NetworkInterfaceRequest: + type: object + properties: + name: + type: string + minLength: 1 + hardware_address: + type: string + minLength: 1 + ip_addresses: + type: array + items: + type: string + minLength: 1 + dns_servers: + type: array + items: + type: string + minLength: 1 + required: + - hardware_address + - name + NetworkRequest: + type: object + properties: + hostname: + type: string + minLength: 1 + firewall_enabled: + type: boolean + interfaces: + type: array + items: + $ref: '#/components/schemas/NetworkInterfaceRequest' + gateway: + type: string + minLength: 1 + required: + - hostname + - interfaces + NotConfiguredActionEnum: + enum: + - skip + - deny + - configure + type: string + Notification: + type: object + description: Notification Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Uuid + severity: + allOf: + - $ref: '#/components/schemas/SeverityEnum' + readOnly: true + body: + type: string + readOnly: true + hyperlink: + type: string + nullable: true + maxLength: 4096 + hyperlink_label: + type: string + nullable: true + created: + type: string + format: date-time + readOnly: true + event: + $ref: '#/components/schemas/Event' + seen: + type: boolean + required: + - body + - created + - pk + - severity + NotificationRequest: + type: object + description: Notification Serializer + properties: + hyperlink: + type: string + nullable: true + maxLength: 4096 + hyperlink_label: + type: string + nullable: true + event: + $ref: '#/components/schemas/EventRequest' + seen: + type: boolean + NotificationRule: + type: object + description: NotificationRule Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + transports: + type: array + items: + type: string + format: uuid + description: Select which transports should be used to notify the user. + If none are selected, the notification will only be shown in the authentik + UI. + severity: + allOf: + - $ref: '#/components/schemas/SeverityEnum' + description: Controls which severity level the created notifications will + have. + destination_group: + type: string + format: uuid + nullable: true + description: Define which group of users this notification should be sent + and shown to. If left empty, Notification won't ben sent. + destination_group_obj: + allOf: + - $ref: '#/components/schemas/Group' + readOnly: true + nullable: true + destination_event_user: + type: boolean + description: When enabled, notification will be sent to user the user that + triggered the event.When destination_group is configured, notification + is sent to both. + required: + - destination_group_obj + - name + - pk + NotificationRuleRequest: + type: object + description: NotificationRule Serializer + properties: + name: + type: string + minLength: 1 + transports: + type: array + items: + type: string + format: uuid + description: Select which transports should be used to notify the user. + If none are selected, the notification will only be shown in the authentik + UI. + severity: + allOf: + - $ref: '#/components/schemas/SeverityEnum' + description: Controls which severity level the created notifications will + have. + destination_group: + type: string + format: uuid + nullable: true + description: Define which group of users this notification should be sent + and shown to. If left empty, Notification won't ben sent. + destination_event_user: + type: boolean + description: When enabled, notification will be sent to user the user that + triggered the event.When destination_group is configured, notification + is sent to both. + required: + - name + NotificationTransport: + type: object + description: NotificationTransport Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Uuid + name: + type: string + mode: + $ref: '#/components/schemas/TransportModeEnum' + mode_verbose: + type: string + description: Return selected mode with a UI Label + readOnly: true + webhook_url: + type: string + format: uri + webhook_ca: + type: string + format: uuid + nullable: true + description: When set, the selected certificate is used to validate the + certificate of the webhook server. + webhook_mapping_body: + type: string + format: uuid + nullable: true + description: Customize the body of the request. Mapping should return data + that is JSON-serializable. + webhook_mapping_headers: + type: string + format: uuid + nullable: true + description: Configure additional headers to be sent. Mapping should return + a dictionary of key-value pairs + email_subject_prefix: + type: string + email_template: + type: string + send_once: + type: boolean + description: Only send notification once, for example when sending a webhook + into a chat channel. + required: + - mode_verbose + - name + - pk + NotificationTransportRequest: + type: object + description: NotificationTransport Serializer + properties: + name: + type: string + minLength: 1 + mode: + $ref: '#/components/schemas/TransportModeEnum' + webhook_url: + type: string + format: uri + webhook_ca: + type: string + format: uuid + nullable: true + description: When set, the selected certificate is used to validate the + certificate of the webhook server. + webhook_mapping_body: + type: string + format: uuid + nullable: true + description: Customize the body of the request. Mapping should return data + that is JSON-serializable. + webhook_mapping_headers: + type: string + format: uuid + nullable: true + description: Configure additional headers to be sent. Mapping should return + a dictionary of key-value pairs + email_subject_prefix: + type: string + email_template: + type: string + minLength: 1 + send_once: + type: boolean + description: Only send notification once, for example when sending a webhook + into a chat channel. + required: + - name + NotificationTransportTest: + type: object + description: Notification test serializer + properties: + messages: + type: array + items: + type: string + required: + - messages + NotificationWebhookMapping: + type: object + description: NotificationWebhookMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + name: + type: string + expression: + type: string + required: + - expression + - name + - pk + NotificationWebhookMappingRequest: + type: object + description: NotificationWebhookMapping Serializer + properties: + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + OAuth2Provider: + type: object + description: OAuth2Provider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + client_type: + allOf: + - $ref: '#/components/schemas/ClientTypeEnum' + description: Confidential clients are capable of maintaining the confidentiality + of their credentials. Public clients are incapable + grant_types: + type: array + items: + $ref: '#/components/schemas/GrantTypesEnum' + client_id: + type: string + maxLength: 255 + client_secret: + type: string + maxLength: 255 + access_code_validity: + type: string + description: 'Access codes not valid on or after current time + this value + (Format: hours=1;minutes=2;seconds=3).' + access_token_validity: + type: string + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + refresh_token_validity: + type: string + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + refresh_token_threshold: + type: string + description: 'When refreshing a token, if the refresh token is valid for + less than this duration, it will be renewed. When set to seconds=0, token + will always be renewed. (Format: hours=1;minutes=2;seconds=3).' + include_claims_in_id_token: + type: boolean + description: Include User claims from scopes in the id_token, for applications + that don't access the userinfo endpoint. + signing_key: + type: string + format: uuid + nullable: true + description: Key used to sign the tokens. + encryption_key: + type: string + format: uuid + nullable: true + description: Key used to encrypt the tokens. When set, tokens will be encrypted + and returned as JWEs. + redirect_uris: + type: array + items: + $ref: '#/components/schemas/RedirectURI' + logout_uri: + type: string + format: uri + logout_method: + allOf: + - $ref: '#/components/schemas/OAuth2ProviderLogoutMethodEnum' + description: Backchannel logs out with server to server calls. Frontchannel + uses iframes in your browser + sub_mode: + allOf: + - $ref: '#/components/schemas/SubModeEnum' + description: Configure what data should be used as unique User Identifier. + For most cases, the default should be fine. + issuer_mode: + allOf: + - $ref: '#/components/schemas/IssuerModeEnum' + description: Configure how the issuer field of the ID Token should be filled. + jwt_federation_sources: + type: array + items: + type: string + format: uuid + title: Any JWT signed by the JWK of the selected source can be used to + authenticate. + title: Any JWT signed by the JWK of the selected source can be used to authenticate. + jwt_federation_providers: + type: array + items: + type: integer + required: + - assigned_application_name + - assigned_application_slug + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - authorization_flow + - component + - invalidation_flow + - meta_model_name + - name + - pk + - redirect_uris + - verbose_name + - verbose_name_plural + OAuth2ProviderLogoutMethodEnum: + enum: + - backchannel + - frontchannel + type: string + OAuth2ProviderRequest: + type: object + description: OAuth2Provider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + client_type: + allOf: + - $ref: '#/components/schemas/ClientTypeEnum' + description: Confidential clients are capable of maintaining the confidentiality + of their credentials. Public clients are incapable + grant_types: + type: array + items: + $ref: '#/components/schemas/GrantTypesEnum' + client_id: + type: string + minLength: 1 + maxLength: 255 + client_secret: + type: string + maxLength: 255 + access_code_validity: + type: string + minLength: 1 + description: 'Access codes not valid on or after current time + this value + (Format: hours=1;minutes=2;seconds=3).' + access_token_validity: + type: string + minLength: 1 + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + refresh_token_validity: + type: string + minLength: 1 + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + refresh_token_threshold: + type: string + minLength: 1 + description: 'When refreshing a token, if the refresh token is valid for + less than this duration, it will be renewed. When set to seconds=0, token + will always be renewed. (Format: hours=1;minutes=2;seconds=3).' + include_claims_in_id_token: + type: boolean + description: Include User claims from scopes in the id_token, for applications + that don't access the userinfo endpoint. + signing_key: + type: string + format: uuid + nullable: true + description: Key used to sign the tokens. + encryption_key: + type: string + format: uuid + nullable: true + description: Key used to encrypt the tokens. When set, tokens will be encrypted + and returned as JWEs. + redirect_uris: + type: array + items: + $ref: '#/components/schemas/RedirectURIRequest' + logout_uri: + type: string + format: uri + logout_method: + allOf: + - $ref: '#/components/schemas/OAuth2ProviderLogoutMethodEnum' + description: Backchannel logs out with server to server calls. Frontchannel + uses iframes in your browser + sub_mode: + allOf: + - $ref: '#/components/schemas/SubModeEnum' + description: Configure what data should be used as unique User Identifier. + For most cases, the default should be fine. + issuer_mode: + allOf: + - $ref: '#/components/schemas/IssuerModeEnum' + description: Configure how the issuer field of the ID Token should be filled. + jwt_federation_sources: + type: array + items: + type: string + format: uuid + title: Any JWT signed by the JWK of the selected source can be used to + authenticate. + title: Any JWT signed by the JWK of the selected source can be used to authenticate. + jwt_federation_providers: + type: array + items: + type: integer + required: + - authorization_flow + - invalidation_flow + - name + - redirect_uris + OAuth2ProviderSetupURLs: + type: object + description: OAuth2 Provider Metadata serializer + properties: + issuer: + type: string + readOnly: true + authorize: + type: string + readOnly: true + token: + type: string + readOnly: true + user_info: + type: string + readOnly: true + provider_info: + type: string + readOnly: true + logout: + type: string + readOnly: true + jwks: + type: string + readOnly: true + required: + - authorize + - issuer + - jwks + - logout + - provider_info + - token + - user_info + OAuthDeviceCodeChallenge: + type: object + description: OAuth Device code challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-provider-oauth2-device-code + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + OAuthDeviceCodeChallengeResponseRequest: + type: object + description: Response that includes the user-entered device code + properties: + component: + type: string + minLength: 1 + default: ak-provider-oauth2-device-code + code: + type: string + minLength: 1 + required: + - code + OAuthDeviceCodeFinishChallenge: + type: object + description: Final challenge after user enters their code + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-provider-oauth2-device-code-finish + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + OAuthDeviceCodeFinishChallengeResponseRequest: + type: object + description: Response that device has been authenticated and tab can be closed + properties: + component: + type: string + minLength: 1 + default: ak-provider-oauth2-device-code-finish + OAuthSource: + type: object + description: OAuth Source Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + description: Source's display Name. + slug: + type: string + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + readOnly: true + user_path_template: + type: string + icon: + type: string + icon_url: + type: string + nullable: true + readOnly: true + icon_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + provider_type: + $ref: '#/components/schemas/ProviderTypeEnum' + request_token_url: + type: string + nullable: true + description: URL used to request the initial token. This URL is only required + for OAuth 1. + maxLength: 255 + authorization_url: + type: string + nullable: true + description: URL the user is redirect to to conest the flow. + maxLength: 255 + access_token_url: + type: string + nullable: true + description: URL used by authentik to retrieve tokens. + maxLength: 255 + profile_url: + type: string + nullable: true + description: URL used by authentik to get user information. + maxLength: 255 + pkce: + $ref: '#/components/schemas/PKCEMethodEnum' + consumer_key: + type: string + callback_url: + type: string + description: Get OAuth Callback URL + readOnly: true + additional_scopes: + type: string + type: + allOf: + - $ref: '#/components/schemas/SourceType' + readOnly: true + oidc_well_known_url: + type: string + oidc_jwks_url: + type: string + oidc_jwks: + type: object + additionalProperties: {} + authorization_code_auth_method: + allOf: + - $ref: '#/components/schemas/AuthorizationCodeAuthMethodEnum' + description: How to perform authentication during an authorization_code + token request flow + required: + - callback_url + - component + - consumer_key + - icon_themed_urls + - icon_url + - managed + - meta_model_name + - name + - pk + - provider_type + - slug + - type + - verbose_name + - verbose_name_plural + OAuthSourcePropertyMapping: + type: object + description: OAuthSourcePropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + OAuthSourcePropertyMappingRequest: + type: object + description: OAuthSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + OAuthSourceRequest: + type: object + description: OAuth Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + provider_type: + $ref: '#/components/schemas/ProviderTypeEnum' + request_token_url: + type: string + nullable: true + description: URL used to request the initial token. This URL is only required + for OAuth 1. + maxLength: 255 + authorization_url: + type: string + nullable: true + description: URL the user is redirect to to conest the flow. + maxLength: 255 + access_token_url: + type: string + nullable: true + description: URL used by authentik to retrieve tokens. + maxLength: 255 + profile_url: + type: string + nullable: true + description: URL used by authentik to get user information. + maxLength: 255 + pkce: + $ref: '#/components/schemas/PKCEMethodEnum' + consumer_key: + type: string + minLength: 1 + consumer_secret: + type: string + writeOnly: true + minLength: 1 + additional_scopes: + type: string + oidc_well_known_url: + type: string + oidc_jwks_url: + type: string + oidc_jwks: + type: object + additionalProperties: {} + authorization_code_auth_method: + allOf: + - $ref: '#/components/schemas/AuthorizationCodeAuthMethodEnum' + description: How to perform authentication during an authorization_code + token request flow + required: + - consumer_key + - consumer_secret + - name + - provider_type + - slug + OpenIDConnectConfiguration: + type: object + description: rest_framework Serializer for OIDC Configuration + properties: + issuer: + type: string + authorization_endpoint: + type: string + token_endpoint: + type: string + userinfo_endpoint: + type: string + end_session_endpoint: + type: string + introspection_endpoint: + type: string + jwks_uri: + type: string + response_types_supported: + type: array + items: + type: string + id_token_signing_alg_values_supported: + type: array + items: + type: string + subject_types_supported: + type: array + items: + type: string + token_endpoint_auth_methods_supported: + type: array + items: + type: string + required: + - authorization_endpoint + - end_session_endpoint + - id_token_signing_alg_values_supported + - introspection_endpoint + - issuer + - jwks_uri + - response_types_supported + - subject_types_supported + - token_endpoint + - token_endpoint_auth_methods_supported + - userinfo_endpoint + OperatingSystem: + type: object + description: |- + For example: + {"family":"linux","name":"Ubuntu","version":"24.04.3 LTS (Noble Numbat)","arch":"amd64"} + {"family": "windows","name":"Server 2022 Datacenter","version":"10.0.20348.4405","arch":"amd64"} + {"family": "windows","name":"Server 2022 Datacenter","version":"10.0.20348.4405","arch":"amd64"} + {"family": "mac_os", "name": "", "version": "26.2", "arch": "arm64"} + properties: + family: + $ref: '#/components/schemas/DeviceFactsOSFamily' + name: + type: string + description: Operating System name, such as 'Server 2022' or 'Ubuntu' + version: + type: string + description: Operating System version, must always be the version number + but may contain build name + arch: + type: string + required: + - family + OperatingSystemRequest: + type: object + description: |- + For example: + {"family":"linux","name":"Ubuntu","version":"24.04.3 LTS (Noble Numbat)","arch":"amd64"} + {"family": "windows","name":"Server 2022 Datacenter","version":"10.0.20348.4405","arch":"amd64"} + {"family": "windows","name":"Server 2022 Datacenter","version":"10.0.20348.4405","arch":"amd64"} + {"family": "mac_os", "name": "", "version": "26.2", "arch": "arm64"} + properties: + family: + $ref: '#/components/schemas/DeviceFactsOSFamily' + name: + type: string + minLength: 1 + description: Operating System name, such as 'Server 2022' or 'Ubuntu' + version: + type: string + minLength: 1 + description: Operating System version, must always be the version number + but may contain build name + arch: + type: string + minLength: 1 + required: + - family + OutgoingSyncDeleteAction: + enum: + - do_nothing + - delete + - suspend + type: string + Outpost: + type: object + description: Outpost Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Uuid + name: + type: string + type: + $ref: '#/components/schemas/OutpostTypeEnum' + providers: + type: array + items: + type: integer + providers_obj: + type: array + items: + $ref: '#/components/schemas/Provider' + readOnly: true + service_connection: + type: string + format: uuid + nullable: true + description: Select Service-Connection authentik should use to manage this + outpost. Leave empty if authentik should not handle the deployment. + service_connection_obj: + allOf: + - $ref: '#/components/schemas/ServiceConnection' + readOnly: true + nullable: true + refresh_interval_s: + type: integer + readOnly: true + token_identifier: + type: string + description: Get Token identifier + readOnly: true + config: + type: object + additionalProperties: {} + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + required: + - config + - name + - pk + - providers + - providers_obj + - refresh_interval_s + - service_connection_obj + - token_identifier + - type + OutpostDefaultConfig: + type: object + description: Global default outpost config + properties: + config: + type: object + additionalProperties: {} + readOnly: true + required: + - config + OutpostHealth: + type: object + description: Outpost health status + properties: + uid: + type: string + readOnly: true + last_seen: + type: string + format: date-time + readOnly: true + version: + type: string + readOnly: true + golang_version: + type: string + readOnly: true + openssl_enabled: + type: boolean + readOnly: true + openssl_version: + type: string + readOnly: true + fips_enabled: + type: boolean + nullable: true + description: Get FIPS enabled + readOnly: true + version_should: + type: string + readOnly: true + version_outdated: + type: boolean + readOnly: true + build_hash: + type: string + readOnly: true + build_hash_should: + type: string + readOnly: true + hostname: + type: string + readOnly: true + required: + - build_hash + - build_hash_should + - fips_enabled + - golang_version + - hostname + - last_seen + - openssl_enabled + - openssl_version + - uid + - version + - version_outdated + - version_should + OutpostRequest: + type: object + description: Outpost Serializer + properties: + name: + type: string + minLength: 1 + type: + $ref: '#/components/schemas/OutpostTypeEnum' + providers: + type: array + items: + type: integer + service_connection: + type: string + format: uuid + nullable: true + description: Select Service-Connection authentik should use to manage this + outpost. Leave empty if authentik should not handle the deployment. + config: + type: object + additionalProperties: {} + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + required: + - config + - name + - providers + - type + OutpostTypeEnum: + enum: + - proxy + - ldap + - radius + - rac + type: string + PKCEMethodEnum: + enum: + - none + - plain + - S256 + type: string + PaginatedAccountLockdownStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AccountLockdownStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAgentConnectorList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AgentConnector' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAppleIndependentSecureEnclaveList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AppleIndependentSecureEnclave' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedApplicationEntitlementList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ApplicationEntitlement' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedApplicationList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Application' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAuthenticatedSessionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AuthenticatedSession' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAuthenticatorDuoStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AuthenticatorDuoStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAuthenticatorEmailStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AuthenticatorEmailStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAuthenticatorEndpointGDTCStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AuthenticatorEndpointGDTCStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAuthenticatorSMSStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AuthenticatorSMSStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAuthenticatorStaticStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AuthenticatorStaticStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAuthenticatorTOTPStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AuthenticatorTOTPStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAuthenticatorValidateStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AuthenticatorValidateStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedAuthenticatorWebAuthnStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/AuthenticatorWebAuthnStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedBlueprintInstanceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/BlueprintInstance' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedBrandList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Brand' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedCaptchaStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/CaptchaStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedCertificateKeyPairList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/CertificateKeyPair' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedConnectionTokenList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ConnectionToken' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedConnectorList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Connector' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedConsentStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ConsentStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedDataExportList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/DataExport' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedDenyStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/DenyStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedDeviceAccessGroupList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/DeviceAccessGroup' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedDeviceUserBindingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/DeviceUserBinding' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedDockerServiceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/DockerServiceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedDomainList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Domain' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedDummyPolicyList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/DummyPolicy' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedDummyStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/DummyStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedDuoDeviceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/DuoDevice' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedEmailDeviceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/EmailDevice' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedEmailStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/EmailStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedEndpointDeviceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/EndpointDevice' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedEndpointList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Endpoint' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedEndpointStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/EndpointStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedEnrollmentTokenList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/EnrollmentToken' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedEventList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Event' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedEventMatcherPolicyList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/EventMatcherPolicy' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedExpiringBaseGrantModelList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ExpiringBaseGrantModel' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedExpressionPolicyList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ExpressionPolicy' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedExtraRoleObjectPermissionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ExtraRoleObjectPermission' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedFleetConnectorList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/FleetConnector' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedFlowList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Flow' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedFlowStageBindingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/FlowStageBinding' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGeoIPPolicyList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GeoIPPolicy' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGoogleChromeConnectorList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GoogleChromeConnector' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGoogleEndpointDeviceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GoogleEndpointDevice' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGoogleWorkspaceProviderGroupList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GoogleWorkspaceProviderGroup' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGoogleWorkspaceProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GoogleWorkspaceProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGoogleWorkspaceProviderMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GoogleWorkspaceProviderMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGoogleWorkspaceProviderUserList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GoogleWorkspaceProviderUser' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGroupKerberosSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GroupKerberosSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGroupLDAPSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GroupLDAPSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGroupList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Group' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGroupOAuthSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GroupOAuthSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGroupPlexSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GroupPlexSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGroupSAMLSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GroupSAMLSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGroupSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GroupSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedGroupTelegramSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/GroupTelegramSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedIdentificationStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/IdentificationStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedInitialPermissionsList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/InitialPermissions' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedInvitationList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Invitation' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedInvitationStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/InvitationStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedKerberosSourceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/KerberosSource' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedKerberosSourcePropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/KerberosSourcePropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedKubernetesServiceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/KubernetesServiceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedLDAPOutpostConfigList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/LDAPOutpostConfig' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedLDAPProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/LDAPProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedLDAPSourceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/LDAPSource' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedLDAPSourcePropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/LDAPSourcePropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedLicenseList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/License' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedLifecycleIterationList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/LifecycleIteration' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedLifecycleRuleList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/LifecycleRule' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedMicrosoftEntraProviderGroupList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/MicrosoftEntraProviderGroup' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedMicrosoftEntraProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/MicrosoftEntraProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedMicrosoftEntraProviderMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/MicrosoftEntraProviderMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedMicrosoftEntraProviderUserList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/MicrosoftEntraProviderUser' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedMutualTLSStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/MutualTLSStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedNotificationList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Notification' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedNotificationRuleList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/NotificationRule' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedNotificationTransportList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/NotificationTransport' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedNotificationWebhookMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/NotificationWebhookMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedOAuth2ProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/OAuth2Provider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedOAuthSourceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/OAuthSource' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedOAuthSourcePropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/OAuthSourcePropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedOutpostList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Outpost' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPasswordExpiryPolicyList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/PasswordExpiryPolicy' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPasswordPolicyList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/PasswordPolicy' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPasswordStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/PasswordStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPermissionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Permission' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPlexSourceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/PlexSource' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPlexSourcePropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/PlexSourcePropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPolicyBindingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/PolicyBinding' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPolicyList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Policy' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPromptList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Prompt' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPromptStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/PromptStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedPropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/PropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Provider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedProxyOutpostConfigList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ProxyOutpostConfig' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedProxyProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ProxyProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedRACPropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/RACPropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedRACProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/RACProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedRadiusOutpostConfigList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/RadiusOutpostConfig' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedRadiusProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/RadiusProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedRadiusProviderPropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/RadiusProviderPropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedRedirectStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/RedirectStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedReputationList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Reputation' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedReputationPolicyList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ReputationPolicy' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedRoleAssignedObjectPermissionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/RoleAssignedObjectPermission' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedRoleList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Role' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSAMLPropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SAMLPropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSAMLProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SAMLProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSAMLSourceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SAMLSource' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSAMLSourcePropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SAMLSourcePropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSCIMMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SCIMMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSCIMProviderGroupList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SCIMProviderGroup' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSCIMProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SCIMProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSCIMProviderUserList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SCIMProviderUser' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSCIMSourceGroupList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SCIMSourceGroup' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSCIMSourceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SCIMSource' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSCIMSourcePropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SCIMSourcePropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSCIMSourceUserList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SCIMSourceUser' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSMSDeviceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SMSDevice' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSSFProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SSFProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSSFStreamList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SSFStream' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedScheduleList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Schedule' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedScopeMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ScopeMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedServiceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/ServiceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSourceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Source' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedSourceStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/SourceStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Stage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedStaticDeviceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/StaticDevice' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedTOTPDeviceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/TOTPDevice' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedTaskList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Task' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedTelegramSourceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/TelegramSource' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedTelegramSourcePropertyMappingList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/TelegramSourcePropertyMapping' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedTenantList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Tenant' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedTokenList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/Token' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedTokenModelList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/TokenModel' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUniquePasswordPolicyList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UniquePasswordPolicy' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserConsentList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserConsent' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserDeleteStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserDeleteStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserKerberosSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserKerberosSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserLDAPSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserLDAPSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/User' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserLoginStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserLoginStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserLogoutStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserLogoutStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserOAuthSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserOAuthSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserPlexSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserPlexSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserSAMLSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserSAMLSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserTelegramSourceConnectionList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserTelegramSourceConnection' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedUserWriteStageList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/UserWriteStage' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedWSFederationProviderList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/WSFederationProvider' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedWebAuthnDeviceList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/WebAuthnDevice' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + PaginatedWebAuthnDeviceTypeList: + type: object + properties: + pagination: + $ref: '#/components/schemas/Pagination' + results: + type: array + items: + $ref: '#/components/schemas/WebAuthnDeviceType' + autocomplete: + $ref: '#/components/schemas/Autocomplete' + required: + - autocomplete + - pagination + - results + Pagination: + type: object + properties: + next: + type: number + previous: + type: number + count: + type: number + current: + type: number + total_pages: + type: number + start_index: + type: number + end_index: + type: number + required: + - count + - current + - end_index + - next + - previous + - start_index + - total_pages + PartialGroup: + type: object + description: Partial Group Serializer, does not include child relations. + properties: + pk: + type: string + format: uuid + readOnly: true + title: Group uuid + num_pk: + type: integer + description: Get a numerical, int32 ID for the group + readOnly: true + name: + type: string + is_superuser: + type: boolean + description: Users added to this group will be superusers. + attributes: + type: object + additionalProperties: {} + required: + - name + - num_pk + - pk + PartialUser: + type: object + description: Partial User Serializer, does not include child relations. + properties: + pk: + type: integer + readOnly: true + title: ID + username: + type: string + description: Required. 150 characters or fewer. Letters, digits and @/./+/-/_ + only. + pattern: ^[\w.@+-]+$ + maxLength: 150 + name: + type: string + description: User's display name. + is_active: + type: boolean + title: Active + description: Designates whether this user should be treated as active. Unselect + this instead of deleting accounts. + last_login: + type: string + format: date-time + nullable: true + email: + type: string + format: email + title: Email address + maxLength: 254 + attributes: + type: object + additionalProperties: {} + uid: + type: string + readOnly: true + required: + - name + - pk + - uid + - username + PasswordChallenge: + type: object + description: Password challenge UI fields + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-password + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + recovery_url: + type: string + allow_show_password: + type: boolean + default: false + required: + - pending_user + - pending_user_avatar + PasswordChallengeResponseRequest: + type: object + description: Password challenge response + properties: + component: + type: string + minLength: 1 + default: ak-stage-password + password: + type: string + minLength: 1 + required: + - password + PasswordExpiryPolicy: + type: object + description: Password Expiry Policy Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy uuid + name: + type: string + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + bound_to: + type: integer + description: Return objects policy is bound to + readOnly: true + days: + type: integer + maximum: 2147483647 + minimum: -2147483648 + deny_only: + type: boolean + required: + - bound_to + - component + - days + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + PasswordExpiryPolicyRequest: + type: object + description: Password Expiry Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + days: + type: integer + maximum: 2147483647 + minimum: -2147483648 + deny_only: + type: boolean + required: + - days + - name + PasswordPolicy: + type: object + description: Password Policy Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy uuid + name: + type: string + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + bound_to: + type: integer + description: Return objects policy is bound to + readOnly: true + password_field: + type: string + description: Field key to check, field keys defined in Prompt stages are + available. + amount_digits: + type: integer + maximum: 2147483647 + minimum: 0 + amount_uppercase: + type: integer + maximum: 2147483647 + minimum: 0 + amount_lowercase: + type: integer + maximum: 2147483647 + minimum: 0 + amount_symbols: + type: integer + maximum: 2147483647 + minimum: 0 + length_min: + type: integer + maximum: 2147483647 + minimum: 0 + symbol_charset: + type: string + error_message: + type: string + check_static_rules: + type: boolean + check_have_i_been_pwned: + type: boolean + check_zxcvbn: + type: boolean + hibp_allowed_count: + type: integer + maximum: 2147483647 + minimum: 0 + description: How many times the password hash is allowed to be on haveibeenpwned + zxcvbn_score_threshold: + type: integer + maximum: 2147483647 + minimum: 0 + description: If the zxcvbn score is equal or less than this value, the policy + will fail. + required: + - bound_to + - component + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + PasswordPolicyRequest: + type: object + description: Password Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + password_field: + type: string + minLength: 1 + description: Field key to check, field keys defined in Prompt stages are + available. + amount_digits: + type: integer + maximum: 2147483647 + minimum: 0 + amount_uppercase: + type: integer + maximum: 2147483647 + minimum: 0 + amount_lowercase: + type: integer + maximum: 2147483647 + minimum: 0 + amount_symbols: + type: integer + maximum: 2147483647 + minimum: 0 + length_min: + type: integer + maximum: 2147483647 + minimum: 0 + symbol_charset: + type: string + minLength: 1 + error_message: + type: string + check_static_rules: + type: boolean + check_have_i_been_pwned: + type: boolean + check_zxcvbn: + type: boolean + hibp_allowed_count: + type: integer + maximum: 2147483647 + minimum: 0 + description: How many times the password hash is allowed to be on haveibeenpwned + zxcvbn_score_threshold: + type: integer + maximum: 2147483647 + minimum: 0 + description: If the zxcvbn score is equal or less than this value, the policy + will fail. + required: + - name + PasswordStage: + type: object + description: PasswordStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + backends: + type: array + items: + $ref: '#/components/schemas/BackendsEnum' + description: Selection of backends to test the password against. + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + failed_attempts_before_cancel: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: How many attempts a user has before the flow is canceled. To + lock the user out, use a reputation policy and a user_write stage. + allow_show_password: + type: boolean + description: When enabled, provides a 'show password' button with the password + input field. + required: + - backends + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + PasswordStageRequest: + type: object + description: PasswordStage Serializer + properties: + name: + type: string + minLength: 1 + backends: + type: array + items: + $ref: '#/components/schemas/BackendsEnum' + description: Selection of backends to test the password against. + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + failed_attempts_before_cancel: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: How many attempts a user has before the flow is canceled. To + lock the user out, use a reputation policy and a user_write stage. + allow_show_password: + type: boolean + description: When enabled, provides a 'show password' button with the password + input field. + required: + - backends + - name + PatchedAccountLockdownStageRequest: + type: object + description: AccountLockdownStage Serializer + properties: + name: + type: string + minLength: 1 + deactivate_user: + type: boolean + description: Deactivate the user account (set is_active to False) + set_unusable_password: + type: boolean + description: Set an unusable password for the user + delete_sessions: + type: boolean + description: Delete all active sessions for the user + revoke_tokens: + type: boolean + description: Revoke all tokens for the user (API, app password, recovery, + verification, OAuth) + self_service_completion_flow: + type: string + format: uuid + nullable: true + description: Flow to redirect users to after self-service lockdown. This + flow should not require authentication since the user's session is deleted. + PatchedAgentConnectorRequest: + type: object + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + minLength: 1 + enabled: + type: boolean + snapshot_expiry: + type: string + minLength: 1 + auth_session_duration: + type: string + minLength: 1 + auth_terminate_session_on_expiry: + type: boolean + refresh_interval: + type: string + minLength: 1 + authorization_flow: + type: string + format: uuid + nullable: true + nss_uid_offset: + type: integer + maximum: 2147483647 + minimum: 0 + nss_gid_offset: + type: integer + maximum: 2147483647 + minimum: 0 + challenge_key: + type: string + format: uuid + nullable: true + challenge_idle_timeout: + type: string + minLength: 1 + challenge_trigger_check_in: + type: boolean + jwt_federation_providers: + type: array + items: + type: integer + PatchedAppleIndependentSecureEnclaveRequest: + type: object + properties: + uuid: + type: string + format: uuid + user: + type: integer + description: The user that this device belongs to. + apple_secure_enclave_key: + type: string + minLength: 1 + apple_enclave_key_id: + type: string + minLength: 1 + device_type: + type: string + minLength: 1 + PatchedApplicationEntitlementRequest: + type: object + description: ApplicationEntitlement Serializer + properties: + name: + type: string + minLength: 1 + app: + type: string + format: uuid + attributes: + type: object + additionalProperties: {} + PatchedApplicationRequest: + type: object + description: Application Serializer + properties: + name: + type: string + minLength: 1 + description: Application's display Name. + slug: + type: string + minLength: 1 + description: Internal application name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + provider: + type: integer + nullable: true + backchannel_providers: + type: array + items: + type: integer + open_in_new_tab: + type: boolean + description: Open launch URL in a new browser tab or window. + meta_launch_url: + type: string + format: uri + meta_icon: + type: string + meta_description: + type: string + meta_publisher: + type: string + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + group: + type: string + meta_hide: + type: boolean + description: Hide this application from the user's My applications page. + PatchedAuthenticatorDuoStageRequest: + type: object + description: AuthenticatorDuoStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + client_id: + type: string + minLength: 1 + client_secret: + type: string + writeOnly: true + minLength: 1 + api_hostname: + type: string + minLength: 1 + admin_integration_key: + type: string + admin_secret_key: + type: string + writeOnly: true + PatchedAuthenticatorEmailStageRequest: + type: object + description: AuthenticatorEmailStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + use_global_settings: + type: boolean + description: When enabled, global Email connection settings will be used + and connection settings below will be ignored. + host: + type: string + minLength: 1 + port: + type: integer + maximum: 2147483647 + minimum: -2147483648 + username: + type: string + password: + type: string + writeOnly: true + use_tls: + type: boolean + use_ssl: + type: boolean + timeout: + type: integer + maximum: 2147483647 + minimum: -2147483648 + from_address: + type: string + format: email + minLength: 1 + maxLength: 254 + subject: + type: string + minLength: 1 + token_expiry: + type: string + minLength: 1 + description: 'Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).' + template: + type: string + minLength: 1 + PatchedAuthenticatorEndpointGDTCStageRequest: + type: object + description: AuthenticatorEndpointGDTCStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + credentials: + type: object + additionalProperties: {} + PatchedAuthenticatorSMSStageRequest: + type: object + description: AuthenticatorSMSStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + provider: + $ref: '#/components/schemas/ProviderEnum' + from_number: + type: string + minLength: 1 + account_sid: + type: string + minLength: 1 + auth: + type: string + writeOnly: true + minLength: 1 + auth_password: + type: string + writeOnly: true + auth_type: + $ref: '#/components/schemas/AuthTypeEnum' + verify_only: + type: boolean + description: When enabled, the Phone number is only used during enrollment + to verify the users authenticity. Only a hash of the phone number is saved + to ensure it is not reused in the future. + mapping: + type: string + format: uuid + nullable: true + description: Optionally modify the payload being sent to custom providers. + PatchedAuthenticatorStaticStageRequest: + type: object + description: AuthenticatorStaticStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + token_count: + type: integer + maximum: 2147483647 + minimum: 0 + token_length: + type: integer + maximum: 100 + minimum: 0 + PatchedAuthenticatorTOTPStageRequest: + type: object + description: AuthenticatorTOTPStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + digits: + $ref: '#/components/schemas/DigitsEnum' + PatchedAuthenticatorValidateStageRequest: + type: object + description: AuthenticatorValidateStage Serializer + properties: + name: + type: string + minLength: 1 + not_configured_action: + $ref: '#/components/schemas/NotConfiguredActionEnum' + device_classes: + type: array + items: + $ref: '#/components/schemas/DeviceClassesEnum' + description: Device classes which can be used to authenticate + configuration_stages: + type: array + items: + type: string + format: uuid + description: Stages used to configure Authenticator when user doesn't have + any compatible devices. After this configuration Stage passes, the user + is not prompted again. + last_auth_threshold: + type: string + minLength: 1 + description: If any of the user's device has been used within this threshold, + this stage will be skipped + webauthn_user_verification: + allOf: + - $ref: '#/components/schemas/UserVerificationEnum' + description: Enforce user verification for WebAuthn devices. + webauthn_hints: + type: array + items: + $ref: '#/components/schemas/WebAuthnHintEnum' + webauthn_allowed_device_types: + type: array + items: + type: string + format: uuid + email_otp_throttling_factor: + type: number + format: double + sms_otp_throttling_factor: + type: number + format: double + totp_otp_throttling_factor: + type: number + format: double + static_otp_throttling_factor: + type: number + format: double + PatchedAuthenticatorWebAuthnStageRequest: + type: object + description: AuthenticatorWebAuthnStage Serializer + properties: + name: + type: string + minLength: 1 + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + friendly_name: + type: string + user_verification: + $ref: '#/components/schemas/UserVerificationEnum' + authenticator_attachment: + allOf: + - $ref: '#/components/schemas/AuthenticatorAttachmentEnum' + nullable: true + resident_key_requirement: + $ref: '#/components/schemas/UserVerificationEnum' + hints: + type: array + items: + $ref: '#/components/schemas/WebAuthnHintEnum' + device_type_restrictions: + type: array + items: + type: string + format: uuid + prevent_duplicate_devices: + type: boolean + description: When enabled, a given device can only be registered once. + max_attempts: + type: integer + maximum: 2147483647 + minimum: 0 + PatchedBlueprintInstanceRequest: + type: object + description: Info about a single blueprint instance file + properties: + name: + type: string + minLength: 1 + path: + type: string + default: '' + context: + type: object + additionalProperties: {} + enabled: + type: boolean + content: + type: string + PatchedBrandRequest: + type: object + description: Brand Serializer + properties: + domain: + type: string + minLength: 1 + description: Domain that activates this brand. Can be a superset, i.e. `a.b` + for `aa.b` and `ba.b` + default: + type: boolean + branding_title: + type: string + minLength: 1 + branding_logo: + type: string + minLength: 1 + branding_favicon: + type: string + minLength: 1 + branding_custom_css: + type: string + branding_default_flow_background: + type: string + minLength: 1 + flow_authentication: + type: string + format: uuid + nullable: true + flow_invalidation: + type: string + format: uuid + nullable: true + flow_recovery: + type: string + format: uuid + nullable: true + flow_unenrollment: + type: string + format: uuid + nullable: true + flow_user_settings: + type: string + format: uuid + nullable: true + flow_device_code: + type: string + format: uuid + nullable: true + flow_lockdown: + type: string + format: uuid + nullable: true + default_application: + type: string + format: uuid + nullable: true + description: When set, external users will be redirected to this application + after authenticating. + web_certificate: + type: string + format: uuid + nullable: true + description: Web Certificate used by the authentik Core webserver. + client_certificates: + type: array + items: + type: string + format: uuid + description: Certificates used for client authentication. + attributes: + type: object + additionalProperties: {} + PatchedCaptchaStageRequest: + type: object + description: CaptchaStage Serializer + properties: + name: + type: string + minLength: 1 + public_key: + type: string + minLength: 1 + description: Public key, acquired your captcha Provider. + private_key: + type: string + writeOnly: true + minLength: 1 + description: Private key, acquired your captcha Provider. + js_url: + type: string + minLength: 1 + api_url: + type: string + minLength: 1 + interactive: + type: boolean + score_min_threshold: + type: number + format: double + score_max_threshold: + type: number + format: double + error_on_invalid_score: + type: boolean + description: When enabled and the received captcha score is outside of the + given threshold, the stage will show an error message. When not enabled, + the flow will continue, but the data from the captcha will be available + in the context for policy decisions + PatchedCertificateKeyPairRequest: + type: object + description: CertificateKeyPair Serializer + properties: + name: + type: string + minLength: 1 + certificate_data: + type: string + writeOnly: true + minLength: 1 + description: PEM-encoded Certificate data + key_data: + type: string + writeOnly: true + description: Optional Private Key. If this is set, you can use this keypair + for encryption. + PatchedConnectionTokenRequest: + type: object + description: ConnectionToken Serializer + properties: + pk: + type: string + format: uuid + title: Connection token uuid + provider: + type: integer + endpoint: + type: string + format: uuid + PatchedConsentStageRequest: + type: object + description: ConsentStage Serializer + properties: + name: + type: string + minLength: 1 + mode: + $ref: '#/components/schemas/ConsentModeEnum' + consent_expire_in: + type: string + minLength: 1 + title: Consent expires in + description: 'Offset after which consent expires. (Format: hours=1;minutes=2;seconds=3).' + PatchedDenyStageRequest: + type: object + description: DenyStage Serializer + properties: + name: + type: string + minLength: 1 + deny_message: + type: string + PatchedDeviceAccessGroupRequest: + type: object + properties: + name: + type: string + minLength: 1 + attributes: + type: object + additionalProperties: {} + PatchedDeviceUserBindingRequest: + type: object + description: PolicyBinding Serializer + properties: + policy: + type: string + format: uuid + nullable: true + group: + type: string + format: uuid + nullable: true + user: + type: integer + nullable: true + target: + type: string + format: uuid + negate: + type: boolean + description: Negates the outcome of the policy. Messages are unaffected. + enabled: + type: boolean + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + timeout: + type: integer + maximum: 2147483647 + minimum: 0 + description: Timeout after which Policy execution is terminated. + failure_result: + type: boolean + description: Result if the Policy execution fails. + is_primary: + type: boolean + PatchedDockerServiceConnectionRequest: + type: object + description: DockerServiceConnection Serializer + properties: + name: + type: string + minLength: 1 + local: + type: boolean + description: If enabled, use the local connection. Required Docker socket/Kubernetes + Integration + url: + type: string + minLength: 1 + description: Can be in the format of 'unix://' when connecting to + a local docker daemon, or 'https://:2376' when connecting to + a remote system. + tls_verification: + type: string + format: uuid + nullable: true + description: CA which the endpoint's Certificate is verified against. Can + be left empty for no validation. + tls_authentication: + type: string + format: uuid + nullable: true + description: Certificate/Key used for authentication. Can be left empty + for no authentication. + PatchedDomainRequest: + type: object + description: Domain Serializer + properties: + domain: + type: string + minLength: 1 + maxLength: 253 + is_primary: + type: boolean + tenant: + type: string + format: uuid + PatchedDummyPolicyRequest: + type: object + description: Dummy Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + result: + type: boolean + wait_min: + type: integer + maximum: 2147483647 + minimum: -2147483648 + wait_max: + type: integer + maximum: 2147483647 + minimum: -2147483648 + PatchedDummyStageRequest: + type: object + description: DummyStage Serializer + properties: + name: + type: string + minLength: 1 + throw_error: + type: boolean + PatchedDuoDeviceRequest: + type: object + description: Serializer for Duo authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + PatchedEmailDeviceRequest: + type: object + description: Serializer for email authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + PatchedEmailStageRequest: + type: object + description: EmailStage Serializer + properties: + name: + type: string + minLength: 1 + use_global_settings: + type: boolean + description: When enabled, global Email connection settings will be used + and connection settings below will be ignored. + host: + type: string + minLength: 1 + port: + type: integer + maximum: 2147483647 + minimum: -2147483648 + username: + type: string + password: + type: string + writeOnly: true + use_tls: + type: boolean + use_ssl: + type: boolean + timeout: + type: integer + maximum: 2147483647 + minimum: -2147483648 + from_address: + type: string + format: email + minLength: 1 + maxLength: 254 + token_expiry: + type: string + minLength: 1 + description: 'Time the token sent is valid (Format: hours=3,minutes=17,seconds=300).' + subject: + type: string + minLength: 1 + template: + type: string + minLength: 1 + activate_user_on_success: + type: boolean + description: Activate users upon completion of stage. + recovery_max_attempts: + type: integer + maximum: 2147483647 + minimum: 0 + recovery_cache_timeout: + type: string + minLength: 1 + description: 'The time window used to count recent account recovery attempts. + If the number of attempts exceed recovery_max_attempts within this period, + further attempts will be rate-limited. (Format: hours=1;minutes=2;seconds=3).' + PatchedEndpointDeviceRequest: + type: object + properties: + device_uuid: + type: string + format: uuid + name: + type: string + minLength: 1 + access_group: + type: string + format: uuid + nullable: true + access_group_obj: + $ref: '#/components/schemas/DeviceAccessGroupRequest' + expiring: + type: boolean + expires: + type: string + format: date-time + nullable: true + attributes: + type: object + additionalProperties: {} + PatchedEndpointRequest: + type: object + description: Endpoint Serializer + properties: + name: + type: string + minLength: 1 + provider: + type: integer + protocol: + $ref: '#/components/schemas/ProtocolEnum' + host: + type: string + minLength: 1 + settings: + type: object + additionalProperties: {} + property_mappings: + type: array + items: + type: string + format: uuid + auth_mode: + $ref: '#/components/schemas/EndpointAuthModeEnum' + maximum_connections: + type: integer + maximum: 2147483647 + minimum: -2147483648 + PatchedEndpointStageRequest: + type: object + description: EndpointStage Serializer + properties: + name: + type: string + minLength: 1 + connector: + type: string + format: uuid + mode: + $ref: '#/components/schemas/StageModeEnum' + PatchedEnrollmentTokenRequest: + type: object + properties: + device_group: + type: string + format: uuid + nullable: true + connector: + type: string + format: uuid + name: + type: string + minLength: 1 + expiring: + type: boolean + expires: + type: string + format: date-time + nullable: true + PatchedEventMatcherPolicyRequest: + type: object + description: Event Matcher Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + action: + allOf: + - $ref: '#/components/schemas/EventActions' + nullable: true + description: Match created events with this action type. When left empty, + all action types will be matched. + client_ip: + type: string + nullable: true + minLength: 1 + description: Matches Event's Client IP (strict matching, for network matching + use an Expression Policy) + app: + allOf: + - $ref: '#/components/schemas/AppEnum' + nullable: true + description: Match events created by selected application. When left empty, + all applications are matched. + model: + allOf: + - $ref: '#/components/schemas/ModelEnum' + nullable: true + description: Match events created by selected model. When left empty, all + models are matched. When an app is selected, all the application's models + are matched. + query: + type: string + nullable: true + minLength: 1 + PatchedEventRequest: + type: object + description: Event Serializer + properties: + user: + type: object + additionalProperties: {} + action: + $ref: '#/components/schemas/EventActions' + app: + type: string + minLength: 1 + context: + type: object + additionalProperties: {} + client_ip: + type: string + nullable: true + minLength: 1 + expires: + type: string + format: date-time + brand: + type: object + additionalProperties: {} + PatchedExpressionPolicyRequest: + type: object + description: Group Membership Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + expression: + type: string + minLength: 1 + PatchedFleetConnectorRequest: + type: object + description: FleetConnector Serializer + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + minLength: 1 + enabled: + type: boolean + url: + type: string + format: uri + minLength: 1 + maxLength: 200 + token: + type: string + writeOnly: true + minLength: 1 + headers_mapping: + type: string + format: uuid + nullable: true + description: Configure additional headers to be sent. Mapping should return + a dictionary of key-value pairs + map_users: + type: boolean + map_teams_access_group: + type: boolean + PatchedFlowRequest: + type: object + description: Flow Serializer + properties: + name: + type: string + minLength: 1 + slug: + type: string + minLength: 1 + description: Visible in the URL. + pattern: ^[-a-zA-Z0-9_]+$ + title: + type: string + minLength: 1 + description: Shown as the Title in Flow pages. + designation: + allOf: + - $ref: '#/components/schemas/FlowDesignationEnum' + description: Decides what this Flow is used for. For example, the Authentication + flow is redirect to when an un-authenticated user visits authentik. + background: + type: string + description: Background shown during execution + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + compatibility_mode: + type: boolean + description: Enable compatibility mode, increases compatibility with password + managers on mobile devices. + layout: + $ref: '#/components/schemas/FlowLayoutEnum' + denied_action: + allOf: + - $ref: '#/components/schemas/DeniedActionEnum' + description: Configure what should happen when a flow denies access to a + user. + authentication: + allOf: + - $ref: '#/components/schemas/AuthenticationEnum' + description: Required level of authentication and authorization to access + a flow. + PatchedFlowStageBindingRequest: + type: object + description: FlowStageBinding Serializer + properties: + target: + type: string + format: uuid + stage: + type: string + format: uuid + evaluate_on_plan: + type: boolean + description: Evaluate policies during the Flow planning process. + re_evaluate_policies: + type: boolean + description: Evaluate policies when the Stage is presented to the user. + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + invalid_response_action: + allOf: + - $ref: '#/components/schemas/InvalidResponseActionEnum' + description: Configure how the flow executor should handle an invalid response + to a challenge. RETRY returns the error message and a similar challenge + to the executor. RESTART restarts the flow from the beginning, and RESTART_WITH_CONTEXT + restarts the flow while keeping the current context. + PatchedGeoIPPolicyRequest: + type: object + description: GeoIP Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + asns: + type: array + items: + type: integer + maximum: 2147483647 + minimum: -2147483648 + countries: + type: array + items: + $ref: '#/components/schemas/CountryCodeEnum' + maxItems: 249 + check_history_distance: + type: boolean + history_max_distance_km: + type: integer + maximum: 9223372036854775807 + minimum: 0 + format: int64 + distance_tolerance_km: + type: integer + maximum: 2147483647 + minimum: 0 + history_login_count: + type: integer + maximum: 2147483647 + minimum: 0 + check_impossible_travel: + type: boolean + impossible_tolerance_km: + type: integer + maximum: 2147483647 + minimum: 0 + PatchedGoogleChromeConnectorRequest: + type: object + description: GoogleChromeConnector Serializer + properties: + connector_uuid: + type: string + format: uuid + name: + type: string + minLength: 1 + enabled: + type: boolean + credentials: + type: object + additionalProperties: {} + PatchedGoogleEndpointDeviceRequest: + type: object + description: Serializer for Endpoint authenticator devices + properties: + pk: + type: string + format: uuid + title: Uuid + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + PatchedGoogleWorkspaceProviderMappingRequest: + type: object + description: GoogleWorkspaceProviderMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedGoogleWorkspaceProviderRequest: + type: object + description: GoogleWorkspaceProvider Serializer + properties: + name: + type: string + minLength: 1 + property_mappings: + type: array + items: + type: string + format: uuid + property_mappings_group: + type: array + items: + type: string + format: uuid + description: Property mappings used for group creation/updating. + delegated_subject: + type: string + format: email + minLength: 1 + maxLength: 254 + credentials: + type: object + additionalProperties: {} + scopes: + type: string + minLength: 1 + exclude_users_service_account: + type: boolean + filter_group: + type: string + format: uuid + nullable: true + user_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + group_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + default_group_email_domain: + type: string + minLength: 1 + sync_page_size: + type: integer + maximum: 2147483647 + minimum: 1 + description: Controls the number of objects synced in a single task + sync_page_timeout: + type: string + minLength: 1 + description: Timeout for synchronization of a single page + dry_run: + type: boolean + description: When enabled, provider will not modify or create objects in + the remote system. + PatchedGroupKerberosSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedGroupLDAPSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedGroupOAuthSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedGroupPlexSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedGroupRequest: + type: object + description: Group Serializer + properties: + name: + type: string + minLength: 1 + is_superuser: + type: boolean + description: Users added to this group will be superusers. + parents: + type: array + items: + type: string + format: uuid + users: + type: array + items: + type: integer + attributes: + type: object + additionalProperties: {} + roles: + type: array + items: + type: string + format: uuid + PatchedGroupSAMLSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedGroupSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedGroupTelegramSourceConnectionRequest: + type: object + description: Group Source Connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedIdentificationStageRequest: + type: object + description: IdentificationStage Serializer + properties: + name: + type: string + minLength: 1 + user_fields: + type: array + items: + $ref: '#/components/schemas/UserFieldsEnum' + description: Fields of the user object to match against. (Hold shift to + select multiple options) + password_stage: + type: string + format: uuid + nullable: true + description: When set, shows a password field, instead of showing the password + field as separate step. + captcha_stage: + type: string + format: uuid + nullable: true + description: When set, adds functionality exactly like a Captcha stage, + but baked into the Identification stage. + case_insensitive_matching: + type: boolean + description: When enabled, user fields are matched regardless of their casing. + show_matched_user: + type: boolean + description: When a valid username/email has been entered, and this option + is enabled, the user's username and avatar will be shown. Otherwise, the + text that the user entered will be shown + enrollment_flow: + type: string + format: uuid + nullable: true + description: Optional enrollment flow, which is linked at the bottom of + the page. + recovery_flow: + type: string + format: uuid + nullable: true + description: Optional recovery flow, which is linked at the bottom of the + page. + passwordless_flow: + type: string + format: uuid + nullable: true + description: Optional passwordless flow, which is linked at the bottom of + the page. + sources: + type: array + items: + type: string + format: uuid + description: Specify which sources should be shown. + show_source_labels: + type: boolean + pretend_user_exists: + type: boolean + description: When enabled, the stage will succeed and continue even when + incorrect user info is entered. + enable_remember_me: + type: boolean + description: Show the user the 'Remember me on this device' toggle, allowing + repeat users to skip straight to entering their password. + webauthn_stage: + type: string + format: uuid + nullable: true + description: When set, and conditional WebAuthn is available, allow the + user to use their passkey as a first factor. + PatchedInitialPermissionsRequest: + type: object + description: InitialPermissions serializer + properties: + name: + type: string + minLength: 1 + maxLength: 150 + role: + type: string + format: uuid + permissions: + type: array + items: + type: integer + PatchedInvitationRequest: + type: object + description: Invitation Serializer + properties: + name: + type: string + minLength: 1 + pattern: ^[-a-zA-Z0-9_]+$ + expires: + type: string + format: date-time + nullable: true + fixed_data: + type: object + additionalProperties: {} + single_use: + type: boolean + description: When enabled, the invitation will be deleted after usage. + flow: + type: string + format: uuid + nullable: true + description: When set, only the configured flow can use this invitation. + PatchedInvitationStageRequest: + type: object + description: InvitationStage Serializer + properties: + name: + type: string + minLength: 1 + continue_flow_without_invitation: + type: boolean + description: If this flag is set, this Stage will jump to the next Stage + when no Invitation is given. By default this Stage will cancel the Flow + when no invitation is given. + PatchedKerberosSourcePropertyMappingRequest: + type: object + description: Kerberos PropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedKerberosSourceRequest: + type: object + description: Kerberos Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + realm: + type: string + minLength: 1 + description: Kerberos realm + krb5_conf: + type: string + description: Custom krb5.conf to use. Uses the system one by default + kadmin_type: + allOf: + - $ref: '#/components/schemas/KadminTypeEnum' + description: KAdmin server type + sync_users: + type: boolean + description: Sync users from Kerberos into authentik + sync_users_password: + type: boolean + description: When a user changes their password, sync it back to Kerberos + sync_principal: + type: string + description: Principal to authenticate to kadmin for sync. + sync_password: + type: string + writeOnly: true + description: Password to authenticate to kadmin for sync + sync_keytab: + type: string + writeOnly: true + description: Keytab to authenticate to kadmin for sync. Must be base64-encoded + or in the form TYPE:residual + sync_ccache: + type: string + writeOnly: true + description: Credentials cache to authenticate to kadmin for sync. Must + be in the form TYPE:residual + spnego_server_name: + type: string + description: Force the use of a specific server name for SPNEGO. Must be + in the form HTTP@hostname + spnego_keytab: + type: string + writeOnly: true + description: SPNEGO keytab base64-encoded or path to keytab in the form + FILE:path + spnego_ccache: + type: string + writeOnly: true + description: Credential cache to use for SPNEGO in form type:residual + password_login_update_internal_password: + type: boolean + description: If enabled, the authentik-stored password will be updated upon + login with the Kerberos password backend + sync_outgoing_trigger_mode: + allOf: + - $ref: '#/components/schemas/SyncOutgoingTriggerModeEnum' + description: When to trigger sync for outgoing providers + PatchedKubernetesServiceConnectionRequest: + type: object + description: KubernetesServiceConnection Serializer + properties: + name: + type: string + minLength: 1 + local: + type: boolean + description: If enabled, use the local connection. Required Docker socket/Kubernetes + Integration + kubeconfig: + type: object + additionalProperties: {} + description: Paste your kubeconfig here. authentik will automatically use + the currently selected context. + verify_ssl: + type: boolean + description: Verify SSL Certificates of the Kubernetes API endpoint + PatchedLDAPProviderRequest: + type: object + description: LDAPProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + base_dn: + type: string + minLength: 1 + description: DN under which objects are accessible. + certificate: + type: string + format: uuid + nullable: true + tls_server_name: + type: string + uid_start_number: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: The start for uidNumbers, this number is added to the user.pk + to make sure that the numbers aren't too low for POSIX users. Default + is 2000 to ensure that we don't collide with local users uidNumber + gid_start_number: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: The start for gidNumbers, this number is added to a number + generated from the group.pk to make sure that the numbers aren't too low + for POSIX groups. Default is 4000 to ensure that we don't collide with + local groups or users primary groups gidNumber + search_mode: + $ref: '#/components/schemas/LDAPAPIAccessMode' + bind_mode: + $ref: '#/components/schemas/LDAPAPIAccessMode' + mfa_support: + type: boolean + description: When enabled, code-based multi-factor authentication can be + used by appending a semicolon and the TOTP code to the password. This + should only be enabled if all users that will bind to this provider have + a TOTP device configured, as otherwise a password may incorrectly be rejected + if it contains a semicolon. + PatchedLDAPSourcePropertyMappingRequest: + type: object + description: LDAP PropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedLDAPSourceRequest: + type: object + description: LDAP Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + server_uri: + type: string + minLength: 1 + format: uri + peer_certificate: + type: string + format: uuid + nullable: true + description: Optionally verify the LDAP Server's Certificate against the + CA Chain in this keypair. + client_certificate: + type: string + format: uuid + nullable: true + description: Client certificate to authenticate against the LDAP Server's + Certificate. + bind_cn: + type: string + bind_password: + type: string + writeOnly: true + start_tls: + type: boolean + title: Enable Start TLS + sni: + type: boolean + title: Use Server URI for SNI verification + base_dn: + type: string + minLength: 1 + additional_user_dn: + type: string + title: Addition User DN + description: Prepended to Base DN for User-queries. + additional_group_dn: + type: string + title: Addition Group DN + description: Prepended to Base DN for Group-queries. + user_object_filter: + type: string + minLength: 1 + description: Consider Objects matching this filter to be Users. + group_object_filter: + type: string + minLength: 1 + description: Consider Objects matching this filter to be Groups. + group_membership_field: + type: string + minLength: 1 + description: Field which contains members of a group. + user_membership_attribute: + type: string + minLength: 1 + description: Attribute which matches the value of `group_membership_field`. + object_uniqueness_field: + type: string + minLength: 1 + description: Field which contains a unique Identifier. + password_login_update_internal_password: + type: boolean + description: Update internal authentik password when login succeeds with + LDAP + sync_users: + type: boolean + sync_users_password: + type: boolean + description: When a user changes their password, sync it back to LDAP. This + can only be enabled on a single LDAP source. + sync_groups: + type: boolean + sync_parent_group: + type: string + format: uuid + nullable: true + lookup_groups_from_user: + type: boolean + description: Lookup group membership based on a user attribute instead of + a group attribute. This allows nested group resolution on systems like + FreeIPA and Active Directory + delete_not_found_objects: + type: boolean + description: Delete authentik users and groups which were previously supplied + by this source, but are now missing from it. + sync_outgoing_trigger_mode: + allOf: + - $ref: '#/components/schemas/SyncOutgoingTriggerModeEnum' + description: When to trigger sync for outgoing providers + PatchedLicenseRequest: + type: object + description: License Serializer + properties: + key: + type: string + minLength: 1 + PatchedLifecycleRuleRequest: + type: object + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + properties: + name: + type: string + minLength: 1 + content_type: + $ref: '#/components/schemas/ContentTypeEnum' + object_id: + type: string + nullable: true + minLength: 1 + interval: + type: string + minLength: 1 + grace_period: + type: string + minLength: 1 + reviewer_groups: + type: array + items: + type: string + format: uuid + min_reviewers: + type: integer + maximum: 32767 + minimum: 0 + min_reviewers_is_per_group: + type: boolean + reviewers: + type: array + items: + type: string + format: uuid + notification_transports: + type: array + items: + type: string + format: uuid + description: Select which transports should be used to notify the reviewers. + If none are selected, the notification will only be shown in the authentik + UI. + PatchedMicrosoftEntraProviderMappingRequest: + type: object + description: MicrosoftEntraProviderMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedMicrosoftEntraProviderRequest: + type: object + description: MicrosoftEntraProvider Serializer + properties: + name: + type: string + minLength: 1 + property_mappings: + type: array + items: + type: string + format: uuid + property_mappings_group: + type: array + items: + type: string + format: uuid + description: Property mappings used for group creation/updating. + client_id: + type: string + minLength: 1 + client_secret: + type: string + writeOnly: true + minLength: 1 + tenant_id: + type: string + minLength: 1 + exclude_users_service_account: + type: boolean + filter_group: + type: string + format: uuid + nullable: true + user_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + group_delete_action: + $ref: '#/components/schemas/OutgoingSyncDeleteAction' + sync_page_size: + type: integer + maximum: 2147483647 + minimum: 1 + description: Controls the number of objects synced in a single task + sync_page_timeout: + type: string + minLength: 1 + description: Timeout for synchronization of a single page + dry_run: + type: boolean + description: When enabled, provider will not modify or create objects in + the remote system. + PatchedMutualTLSStageRequest: + type: object + description: MutualTLSStage Serializer + properties: + name: + type: string + minLength: 1 + mode: + $ref: '#/components/schemas/StageModeEnum' + certificate_authorities: + type: array + items: + type: string + format: uuid + description: Configure certificate authorities to validate the certificate + against. This option has a higher priority than the `client_certificate` + option on `Brand`. + cert_attribute: + $ref: '#/components/schemas/CertAttributeEnum' + user_attribute: + $ref: '#/components/schemas/UserAttributeEnum' + PatchedNotificationRequest: + type: object + description: Notification Serializer + properties: + hyperlink: + type: string + nullable: true + maxLength: 4096 + hyperlink_label: + type: string + nullable: true + event: + $ref: '#/components/schemas/EventRequest' + seen: + type: boolean + PatchedNotificationRuleRequest: + type: object + description: NotificationRule Serializer + properties: + name: + type: string + minLength: 1 + transports: + type: array + items: + type: string + format: uuid + description: Select which transports should be used to notify the user. + If none are selected, the notification will only be shown in the authentik + UI. + severity: + allOf: + - $ref: '#/components/schemas/SeverityEnum' + description: Controls which severity level the created notifications will + have. + destination_group: + type: string + format: uuid + nullable: true + description: Define which group of users this notification should be sent + and shown to. If left empty, Notification won't ben sent. + destination_event_user: + type: boolean + description: When enabled, notification will be sent to user the user that + triggered the event.When destination_group is configured, notification + is sent to both. + PatchedNotificationTransportRequest: + type: object + description: NotificationTransport Serializer + properties: + name: + type: string + minLength: 1 + mode: + $ref: '#/components/schemas/TransportModeEnum' + webhook_url: + type: string + format: uri + webhook_ca: + type: string + format: uuid + nullable: true + description: When set, the selected certificate is used to validate the + certificate of the webhook server. + webhook_mapping_body: + type: string + format: uuid + nullable: true + description: Customize the body of the request. Mapping should return data + that is JSON-serializable. + webhook_mapping_headers: + type: string + format: uuid + nullable: true + description: Configure additional headers to be sent. Mapping should return + a dictionary of key-value pairs + email_subject_prefix: + type: string + email_template: + type: string + minLength: 1 + send_once: + type: boolean + description: Only send notification once, for example when sending a webhook + into a chat channel. + PatchedNotificationWebhookMappingRequest: + type: object + description: NotificationWebhookMapping Serializer + properties: + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedOAuth2ProviderRequest: + type: object + description: OAuth2Provider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + client_type: + allOf: + - $ref: '#/components/schemas/ClientTypeEnum' + description: Confidential clients are capable of maintaining the confidentiality + of their credentials. Public clients are incapable + grant_types: + type: array + items: + $ref: '#/components/schemas/GrantTypesEnum' + client_id: + type: string + minLength: 1 + maxLength: 255 + client_secret: + type: string + maxLength: 255 + access_code_validity: + type: string + minLength: 1 + description: 'Access codes not valid on or after current time + this value + (Format: hours=1;minutes=2;seconds=3).' + access_token_validity: + type: string + minLength: 1 + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + refresh_token_validity: + type: string + minLength: 1 + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + refresh_token_threshold: + type: string + minLength: 1 + description: 'When refreshing a token, if the refresh token is valid for + less than this duration, it will be renewed. When set to seconds=0, token + will always be renewed. (Format: hours=1;minutes=2;seconds=3).' + include_claims_in_id_token: + type: boolean + description: Include User claims from scopes in the id_token, for applications + that don't access the userinfo endpoint. + signing_key: + type: string + format: uuid + nullable: true + description: Key used to sign the tokens. + encryption_key: + type: string + format: uuid + nullable: true + description: Key used to encrypt the tokens. When set, tokens will be encrypted + and returned as JWEs. + redirect_uris: + type: array + items: + $ref: '#/components/schemas/RedirectURIRequest' + logout_uri: + type: string + format: uri + logout_method: + allOf: + - $ref: '#/components/schemas/OAuth2ProviderLogoutMethodEnum' + description: Backchannel logs out with server to server calls. Frontchannel + uses iframes in your browser + sub_mode: + allOf: + - $ref: '#/components/schemas/SubModeEnum' + description: Configure what data should be used as unique User Identifier. + For most cases, the default should be fine. + issuer_mode: + allOf: + - $ref: '#/components/schemas/IssuerModeEnum' + description: Configure how the issuer field of the ID Token should be filled. + jwt_federation_sources: + type: array + items: + type: string + format: uuid + title: Any JWT signed by the JWK of the selected source can be used to + authenticate. + title: Any JWT signed by the JWK of the selected source can be used to authenticate. + jwt_federation_providers: + type: array + items: + type: integer + PatchedOAuthSourcePropertyMappingRequest: + type: object + description: OAuthSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedOAuthSourceRequest: + type: object + description: OAuth Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + provider_type: + $ref: '#/components/schemas/ProviderTypeEnum' + request_token_url: + type: string + nullable: true + description: URL used to request the initial token. This URL is only required + for OAuth 1. + maxLength: 255 + authorization_url: + type: string + nullable: true + description: URL the user is redirect to to conest the flow. + maxLength: 255 + access_token_url: + type: string + nullable: true + description: URL used by authentik to retrieve tokens. + maxLength: 255 + profile_url: + type: string + nullable: true + description: URL used by authentik to get user information. + maxLength: 255 + pkce: + $ref: '#/components/schemas/PKCEMethodEnum' + consumer_key: + type: string + minLength: 1 + consumer_secret: + type: string + writeOnly: true + minLength: 1 + additional_scopes: + type: string + oidc_well_known_url: + type: string + oidc_jwks_url: + type: string + oidc_jwks: + type: object + additionalProperties: {} + authorization_code_auth_method: + allOf: + - $ref: '#/components/schemas/AuthorizationCodeAuthMethodEnum' + description: How to perform authentication during an authorization_code + token request flow + PatchedOutpostRequest: + type: object + description: Outpost Serializer + properties: + name: + type: string + minLength: 1 + type: + $ref: '#/components/schemas/OutpostTypeEnum' + providers: + type: array + items: + type: integer + service_connection: + type: string + format: uuid + nullable: true + description: Select Service-Connection authentik should use to manage this + outpost. Leave empty if authentik should not handle the deployment. + config: + type: object + additionalProperties: {} + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + PatchedPasswordExpiryPolicyRequest: + type: object + description: Password Expiry Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + days: + type: integer + maximum: 2147483647 + minimum: -2147483648 + deny_only: + type: boolean + PatchedPasswordPolicyRequest: + type: object + description: Password Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + password_field: + type: string + minLength: 1 + description: Field key to check, field keys defined in Prompt stages are + available. + amount_digits: + type: integer + maximum: 2147483647 + minimum: 0 + amount_uppercase: + type: integer + maximum: 2147483647 + minimum: 0 + amount_lowercase: + type: integer + maximum: 2147483647 + minimum: 0 + amount_symbols: + type: integer + maximum: 2147483647 + minimum: 0 + length_min: + type: integer + maximum: 2147483647 + minimum: 0 + symbol_charset: + type: string + minLength: 1 + error_message: + type: string + check_static_rules: + type: boolean + check_have_i_been_pwned: + type: boolean + check_zxcvbn: + type: boolean + hibp_allowed_count: + type: integer + maximum: 2147483647 + minimum: 0 + description: How many times the password hash is allowed to be on haveibeenpwned + zxcvbn_score_threshold: + type: integer + maximum: 2147483647 + minimum: 0 + description: If the zxcvbn score is equal or less than this value, the policy + will fail. + PatchedPasswordStageRequest: + type: object + description: PasswordStage Serializer + properties: + name: + type: string + minLength: 1 + backends: + type: array + items: + $ref: '#/components/schemas/BackendsEnum' + description: Selection of backends to test the password against. + configure_flow: + type: string + format: uuid + nullable: true + description: Flow used by an authenticated user to configure this Stage. + If empty, user will not be able to configure this stage. + failed_attempts_before_cancel: + type: integer + maximum: 2147483647 + minimum: -2147483648 + description: How many attempts a user has before the flow is canceled. To + lock the user out, use a reputation policy and a user_write stage. + allow_show_password: + type: boolean + description: When enabled, provides a 'show password' button with the password + input field. + PatchedPermissionAssignRequest: + type: object + description: Request to assign a new permission + properties: + permissions: + type: array + items: + type: string + minLength: 1 + model: + $ref: '#/components/schemas/ModelEnum' + object_pk: + type: string + minLength: 1 + PatchedPlexSourcePropertyMappingRequest: + type: object + description: PlexSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedPlexSourceRequest: + type: object + description: Plex Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + client_id: + type: string + minLength: 1 + description: Client identifier used to talk to Plex. + allowed_servers: + type: array + items: + type: string + minLength: 1 + description: Which servers a user has to be a member of to be granted access. + Empty list allows every server. + allow_friends: + type: boolean + description: Allow friends to authenticate, even if you don't share a server. + plex_token: + type: string + minLength: 1 + description: Plex token used to check friends + PatchedPolicyBindingRequest: + type: object + description: PolicyBinding Serializer + properties: + policy: + type: string + format: uuid + nullable: true + group: + type: string + format: uuid + nullable: true + user: + type: integer + nullable: true + target: + type: string + format: uuid + negate: + type: boolean + description: Negates the outcome of the policy. Messages are unaffected. + enabled: + type: boolean + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + timeout: + type: integer + maximum: 2147483647 + minimum: 0 + description: Timeout after which Policy execution is terminated. + failure_result: + type: boolean + description: Result if the Policy execution fails. + PatchedPromptRequest: + type: object + description: Prompt Serializer + properties: + name: + type: string + minLength: 1 + field_key: + type: string + minLength: 1 + description: Name of the form field, also used to store the value + label: + type: string + minLength: 1 + type: + $ref: '#/components/schemas/PromptTypeEnum' + required: + type: boolean + placeholder: + type: string + description: Optionally provide a short hint that describes the expected + input value. When creating a fixed choice field, enable interpreting as + expression and return a list to return multiple choices. + initial_value: + type: string + description: Optionally pre-fill the input with an initial value. When creating + a fixed choice field, enable interpreting as expression and return a list + to return multiple default choices. + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + sub_text: + type: string + placeholder_expression: + type: boolean + initial_value_expression: + type: boolean + PatchedPromptStageRequest: + type: object + description: PromptStage Serializer + properties: + name: + type: string + minLength: 1 + fields: + type: array + items: + type: string + format: uuid + validation_policies: + type: array + items: + type: string + format: uuid + PatchedProxyProviderRequest: + type: object + description: ProxyProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + internal_host: + type: string + format: uri + external_host: + type: string + minLength: 1 + format: uri + internal_host_ssl_validation: + type: boolean + description: Validate SSL Certificates of upstream servers + certificate: + type: string + format: uuid + nullable: true + skip_path_regex: + type: string + description: Regular expressions for which authentication is not required. + Each new line is interpreted as a new Regular Expression. + basic_auth_enabled: + type: boolean + title: Set HTTP-Basic Authentication + description: Set a custom HTTP-Basic Authentication header based on values + from authentik. + basic_auth_password_attribute: + type: string + title: HTTP-Basic Password Key + description: User/Group Attribute used for the password part of the HTTP-Basic + Header. + basic_auth_user_attribute: + type: string + title: HTTP-Basic Username Key + description: User/Group Attribute used for the user part of the HTTP-Basic + Header. If not set, the user's Email address is used. + mode: + allOf: + - $ref: '#/components/schemas/ProxyMode' + description: Enable support for forwardAuth in traefik and nginx auth_request. + Exclusive with internal_host. + intercept_header_auth: + type: boolean + description: When enabled, this provider will intercept the authorization + header and authenticate requests based on its value. + cookie_domain: + type: string + jwt_federation_sources: + type: array + items: + type: string + format: uuid + title: Any JWT signed by the JWK of the selected source can be used to + authenticate. + title: Any JWT signed by the JWK of the selected source can be used to authenticate. + jwt_federation_providers: + type: array + items: + type: integer + access_token_validity: + type: string + minLength: 1 + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + refresh_token_validity: + type: string + minLength: 1 + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + PatchedRACPropertyMappingRequest: + type: object + description: RACPropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + static_settings: + type: object + additionalProperties: {} + PatchedRACProviderRequest: + type: object + description: RACProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + property_mappings: + type: array + items: + type: string + format: uuid + settings: + type: object + additionalProperties: {} + connection_expiry: + type: string + minLength: 1 + description: 'Determines how long a session lasts. Default of 0 means that + the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)' + delete_token_on_disconnect: + type: boolean + description: When set to true, connection tokens will be deleted upon disconnect. + PatchedRadiusProviderPropertyMappingRequest: + type: object + description: RadiusProviderPropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedRadiusProviderRequest: + type: object + description: RadiusProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + client_networks: + type: string + minLength: 1 + description: List of CIDRs (comma-separated) that clients can connect from. + A more specific CIDR will match before a looser one. Clients connecting + from a non-specified CIDR will be dropped. + shared_secret: + type: string + minLength: 1 + description: Shared secret between clients and server to hash packets. + mfa_support: + type: boolean + description: When enabled, code-based multi-factor authentication can be + used by appending a semicolon and the TOTP code to the password. This + should only be enabled if all users that will bind to this provider have + a TOTP device configured, as otherwise a password may incorrectly be rejected + if it contains a semicolon. + certificate: + type: string + format: uuid + nullable: true + PatchedRedirectStageRequest: + type: object + description: RedirectStage Serializer + properties: + name: + type: string + minLength: 1 + keep_context: + type: boolean + mode: + $ref: '#/components/schemas/RedirectStageModeEnum' + target_static: + type: string + target_flow: + type: string + format: uuid + nullable: true + PatchedReputationPolicyRequest: + type: object + description: Reputation Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + check_ip: + type: boolean + check_username: + type: boolean + threshold: + type: integer + maximum: 2147483647 + minimum: -2147483648 + PatchedRoleRequest: + type: object + description: Role serializer + properties: + name: + type: string + minLength: 1 + PatchedSAMLPropertyMappingRequest: + type: object + description: SAMLPropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + saml_name: + type: string + minLength: 1 + friendly_name: + type: string + nullable: true + PatchedSAMLProviderRequest: + type: object + description: SAMLProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + acs_url: + type: string + minLength: 1 + format: uri + sls_url: + type: string + description: Single Logout Service URL where the logout response should + be sent. + format: uri + audience: + type: string + description: Value of the audience restriction field of the assertion. When + left empty, no audience restriction will be added. + issuer_override: + type: string + description: Also known as EntityID. Providing a value overrides the default + issuer generated by authentik. + assertion_valid_not_before: + type: string + minLength: 1 + description: 'Assertion valid not before current time + this value (Format: + hours=-1;minutes=-2;seconds=-3).' + assertion_valid_not_on_or_after: + type: string + minLength: 1 + description: 'Assertion not valid on or after current time + this value + (Format: hours=1;minutes=2;seconds=3).' + session_valid_not_on_or_after: + type: string + minLength: 1 + description: 'Session not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + name_id_mapping: + type: string + format: uuid + nullable: true + title: NameID Property Mapping + description: Configure how the NameID value will be created. When left empty, + the NameIDPolicy of the incoming request will be considered + authn_context_class_ref_mapping: + type: string + format: uuid + nullable: true + title: AuthnContextClassRef Property Mapping + description: Configure how the AuthnContextClassRef value will be created. + When left empty, the AuthnContextClassRef will be set based on which authentication + methods the user used to authenticate. + digest_algorithm: + $ref: '#/components/schemas/DigestAlgorithmEnum' + signature_algorithm: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + signing_kp: + type: string + format: uuid + nullable: true + title: Signing Keypair + description: Keypair used to sign outgoing Responses going to the Service + Provider. + verification_kp: + type: string + format: uuid + nullable: true + title: Verification Certificate + description: When selected, incoming assertion's Signatures will be validated + against this certificate. To allow unsigned Requests, leave on default. + encryption_kp: + type: string + format: uuid + nullable: true + title: Encryption Keypair + description: When selected, incoming assertions are encrypted by the IdP + using the public key of the encryption keypair. The assertion is decrypted + by the SP using the the private key. + sign_assertion: + type: boolean + sign_response: + type: boolean + sign_logout_request: + type: boolean + sign_logout_response: + type: boolean + sp_binding: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + title: Service Provider Binding + description: This determines how authentik sends the response back to the + Service Provider. + sls_binding: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + description: This determines how authentik sends the logout response back + to the Service Provider. + logout_method: + allOf: + - $ref: '#/components/schemas/SAMLLogoutMethods' + description: Method to use for logout. Front-channel iframe loads all logout + URLs simultaneously in hidden iframes. Front-channel native uses your + active browser tab to send post requests and redirect to providers. Back-channel + sends logout requests directly from the server without user interaction + (requires POST SLS binding). + default_relay_state: + type: string + description: Default relay_state value for IDP-initiated logins + default_name_id_policy: + $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + PatchedSAMLSourcePropertyMappingRequest: + type: object + description: SAMLSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedSAMLSourceRequest: + type: object + description: SAMLSource Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + pre_authentication_flow: + type: string + format: uuid + description: Flow used before authentication. + issuer: + type: string + description: Also known as Entity ID. Defaults the Metadata URL. + sso_url: + type: string + minLength: 1 + description: URL that the initial Login request is sent to. + format: uri + slo_url: + type: string + nullable: true + description: Optional URL if your IDP supports Single-Logout. + format: uri + allow_idp_initiated: + type: boolean + description: Allows authentication flows initiated by the IdP. This can + be a security risk, as no validation of the request ID is done. + force_authn: + type: boolean + description: When enabled, the IdP will re-authenticate the user even if + a session exists. + name_id_policy: + allOf: + - $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + description: NameID Policy sent to the IdP. Can be unset, in which case + no Policy is sent. + binding_type: + $ref: '#/components/schemas/BindingTypeEnum' + verification_kp: + type: string + format: uuid + nullable: true + title: Verification Certificate + description: When selected, incoming assertion's Signatures will be validated + against this certificate. To allow unsigned Requests, leave on default. + signing_kp: + type: string + format: uuid + nullable: true + title: Signing Keypair + description: Keypair used to sign outgoing Responses going to the Identity + Provider. + digest_algorithm: + $ref: '#/components/schemas/DigestAlgorithmEnum' + signature_algorithm: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + temporary_user_delete_after: + type: string + minLength: 1 + title: Delete temporary users after + description: 'Time offset when temporary users should be deleted. This only + applies if your IDP uses the NameID Format ''transient'', and the user + doesn''t log out manually. (Format: hours=1;minutes=2;seconds=3).' + encryption_kp: + type: string + format: uuid + nullable: true + title: Encryption Keypair + description: When selected, incoming assertions are encrypted by the IdP + using the public key of the encryption keypair. The assertion is decrypted + by the SP using the the private key. + signed_assertion: + type: boolean + signed_response: + type: boolean + PatchedSCIMMappingRequest: + type: object + description: SCIMMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedSCIMProviderRequest: + type: object + description: SCIMProvider Serializer + properties: + name: + type: string + minLength: 1 + property_mappings: + type: array + items: + type: string + format: uuid + property_mappings_group: + type: array + items: + type: string + format: uuid + description: Property mappings used for group creation/updating. + url: + type: string + minLength: 1 + description: Base URL to SCIM requests, usually ends in /v2 + verify_certificates: + type: boolean + token: + type: string + writeOnly: true + description: Authentication token + auth_mode: + $ref: '#/components/schemas/SCIMAuthenticationModeEnum' + auth_oauth: + type: string + format: uuid + nullable: true + description: OAuth Source used for authentication + auth_oauth_params: + type: object + additionalProperties: {} + description: Additional OAuth parameters, such as grant_type + compatibility_mode: + allOf: + - $ref: '#/components/schemas/CompatibilityModeEnum' + title: SCIM Compatibility Mode + description: Alter authentik behavior for vendor-specific SCIM implementations. + service_provider_config_cache_timeout: + type: string + minLength: 1 + description: Cache duration for ServiceProviderConfig responses. Set minutes=0 + to disable. + exclude_users_service_account: + type: boolean + sync_page_size: + type: integer + maximum: 2147483647 + minimum: 1 + description: Controls the number of objects synced in a single task + sync_page_timeout: + type: string + minLength: 1 + description: Timeout for synchronization of a single page + group_filters: + type: array + items: + type: string + format: uuid + description: Group filters used to define sync-scope for groups. + dry_run: + type: boolean + description: When enabled, provider will not modify or create objects in + the remote system. + PatchedSCIMSourceGroupRequest: + type: object + description: SCIMSourceGroup Serializer + properties: + id: + type: string + minLength: 1 + external_id: + type: string + minLength: 1 + group: + type: string + format: uuid + source: + type: string + format: uuid + attributes: + type: object + additionalProperties: {} + PatchedSCIMSourcePropertyMappingRequest: + type: object + description: SCIMSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedSCIMSourceRequest: + type: object + description: SCIMSource Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + user_path_template: + type: string + minLength: 1 + PatchedSCIMSourceUserRequest: + type: object + description: SCIMSourceUser Serializer + properties: + id: + type: string + minLength: 1 + external_id: + type: string + minLength: 1 + user: + type: integer + source: + type: string + format: uuid + attributes: + type: object + additionalProperties: {} + PatchedSMSDeviceRequest: + type: object + description: Serializer for sms authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + PatchedSSFProviderRequest: + type: object + description: SSFProvider Serializer + properties: + name: + type: string + minLength: 1 + signing_key: + type: string + format: uuid + description: Key used to sign the SSF Events. + oidc_auth_providers: + type: array + items: + type: integer + event_retention: + type: string + minLength: 1 + push_verify_certificates: + type: boolean + PatchedScheduleRequest: + type: object + properties: + rel_obj_id: + type: string + nullable: true + minLength: 1 + crontab: + type: string + minLength: 1 + description: When to schedule tasks + paused: + type: boolean + description: Pause this schedule + PatchedScopeMappingRequest: + type: object + description: ScopeMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + scope_name: + type: string + minLength: 1 + description: Scope name requested by the client + description: + type: string + description: Description shown to the user when consenting. If left empty, + the user won't be informed. + PatchedSettingsRequest: + type: object + description: Settings Serializer + properties: + avatars: + type: string + minLength: 1 + description: Configure how authentik should show avatars for users. + default_user_change_name: + type: boolean + description: Enable the ability for users to change their name. + default_user_change_email: + type: boolean + description: Enable the ability for users to change their email address. + default_user_change_username: + type: boolean + description: Enable the ability for users to change their username. + event_retention: + type: string + minLength: 1 + description: 'Events will be deleted after this duration.(Format: weeks=3;days=2;hours=3,seconds=2).' + reputation_lower_limit: + type: integer + maximum: 0 + minimum: -2147483648 + description: Reputation cannot decrease lower than this value. Zero or negative. + reputation_upper_limit: + type: integer + maximum: 2147483647 + minimum: 0 + description: Reputation cannot increase higher than this value. Zero or + positive. + footer_links: {} + gdpr_compliance: + type: boolean + description: When enabled, all the events caused by a user will be deleted + upon the user's deletion. + impersonation: + type: boolean + description: Globally enable/disable impersonation. + impersonation_require_reason: + type: boolean + description: Require administrators to provide a reason for impersonating + a user. + default_token_duration: + type: string + minLength: 1 + description: Default token duration + default_token_length: + type: integer + maximum: 2147483647 + minimum: 1 + description: Default token length + pagination_default_page_size: + type: integer + maximum: 2147483647 + minimum: 0 + description: Default page size for API responses, if no size was requested. + pagination_max_page_size: + type: integer + maximum: 2147483647 + minimum: 0 + description: Maximum page size + flags: + type: object + properties: + core_default_app_access: + type: boolean + description: Configure if applications without any policy/group/user + bindings should be accessible to any user. + enterprise_audit_include_expanded_diff: + type: boolean + description: Include additional information in audit logs, may incur + a performance penalty. + flows_continuous_login: + type: boolean + description: Upon successful authentication, re-start authentication + in other open tabs. + flows_refresh_others: + type: boolean + description: Refresh other tabs after successful authentication. + deprecated: true + required: + - core_default_app_access + - enterprise_audit_include_expanded_diff + - flows_continuous_login + - flows_refresh_others + PatchedSourceStageRequest: + type: object + description: SourceStage Serializer + properties: + name: + type: string + minLength: 1 + source: + type: string + format: uuid + resume_timeout: + type: string + minLength: 1 + description: 'Amount of time a user can take to return from the source to + continue the flow (Format: hours=-1;minutes=-2;seconds=-3)' + PatchedStaticDeviceRequest: + type: object + description: Serializer for static authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + PatchedTOTPDeviceRequest: + type: object + description: Serializer for totp authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + PatchedTelegramSourcePropertyMappingRequest: + type: object + description: TelegramSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + PatchedTelegramSourceRequest: + type: object + description: Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + bot_username: + type: string + minLength: 1 + description: Telegram bot username + bot_token: + type: string + writeOnly: true + minLength: 1 + description: Telegram bot token + request_message_access: + type: boolean + description: Request access to send messages from your bot. + pre_authentication_flow: + type: string + format: uuid + description: Flow used before authentication. + PatchedTenantRequest: + type: object + description: Tenant Serializer + properties: + schema_name: + type: string + minLength: 1 + maxLength: 63 + name: + type: string + minLength: 1 + ready: + type: boolean + PatchedTokenRequest: + type: object + description: Token Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + identifier: + type: string + minLength: 1 + maxLength: 255 + pattern: ^[-a-zA-Z0-9_]+$ + intent: + $ref: '#/components/schemas/IntentEnum' + user: + type: integer + description: + type: string + expires: + type: string + format: date-time + nullable: true + expiring: + type: boolean + PatchedUniquePasswordPolicyRequest: + type: object + description: Password Uniqueness Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + password_field: + type: string + minLength: 1 + description: Field key to check, field keys defined in Prompt stages are + available. + num_historical_passwords: + type: integer + maximum: 2147483647 + minimum: 0 + description: Number of passwords to check against. + PatchedUserDeleteStageRequest: + type: object + description: UserDeleteStage Serializer + properties: + name: + type: string + minLength: 1 + PatchedUserKerberosSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedUserLDAPSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedUserLoginStageRequest: + type: object + description: UserLoginStage Serializer + properties: + name: + type: string + minLength: 1 + session_duration: + type: string + minLength: 1 + description: 'Determines how long a session lasts. Default of 0 means that + the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)' + terminate_other_sessions: + type: boolean + description: Terminate all other sessions of the user logging in. + remember_me_offset: + type: string + minLength: 1 + description: 'Offset the session will be extended by when the user picks + the remember me option. Default of 0 means that the remember me option + will not be shown. (Format: hours=-1;minutes=-2;seconds=-3)' + network_binding: + allOf: + - $ref: '#/components/schemas/NetworkBindingEnum' + description: Bind sessions created by this stage to the configured network + geoip_binding: + allOf: + - $ref: '#/components/schemas/GeoipBindingEnum' + description: Bind sessions created by this stage to the configured GeoIP + location + remember_device: + type: string + minLength: 1 + description: 'When set to a non-zero value, authentik will save a cookie + with a longer expiry,to remember the device the user is logging in from. + (Format: hours=-1;minutes=-2;seconds=-3)' + PatchedUserLogoutStageRequest: + type: object + description: UserLogoutStage Serializer + properties: + name: + type: string + minLength: 1 + PatchedUserOAuthSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + access_token: + type: string + writeOnly: true + nullable: true + expires: + type: string + format: date-time + PatchedUserPlexSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + plex_token: + type: string + writeOnly: true + minLength: 1 + PatchedUserRequest: + type: object + description: User Serializer + properties: + username: + type: string + minLength: 1 + maxLength: 150 + name: + type: string + description: User's display name. + is_active: + type: boolean + title: Active + description: Designates whether this user should be treated as active. Unselect + this instead of deleting accounts. + last_login: + type: string + format: date-time + nullable: true + groups: + type: array + items: + type: string + format: uuid + roles: + type: array + items: + type: string + format: uuid + email: + type: string + format: email + title: Email address + maxLength: 254 + attributes: + type: object + additionalProperties: {} + path: + type: string + minLength: 1 + type: + $ref: '#/components/schemas/UserTypeEnum' + PatchedUserSAMLSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedUserSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedUserTelegramSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + PatchedUserWriteStageRequest: + type: object + description: UserWriteStage Serializer + properties: + name: + type: string + minLength: 1 + user_creation_mode: + $ref: '#/components/schemas/UserCreationModeEnum' + create_users_as_inactive: + type: boolean + description: When set, newly created users are inactive and cannot login. + create_users_group: + type: string + format: uuid + nullable: true + description: Optionally add newly created users to this group. + user_type: + $ref: '#/components/schemas/UserTypeEnum' + user_path_template: + type: string + PatchedWSFederationProviderRequest: + type: object + description: WSFederationProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + reply_url: + type: string + format: uri + minLength: 1 + wtrealm: + type: string + minLength: 1 + assertion_valid_not_before: + type: string + minLength: 1 + description: 'Assertion valid not before current time + this value (Format: + hours=-1;minutes=-2;seconds=-3).' + assertion_valid_not_on_or_after: + type: string + minLength: 1 + description: 'Assertion not valid on or after current time + this value + (Format: hours=1;minutes=2;seconds=3).' + session_valid_not_on_or_after: + type: string + minLength: 1 + description: 'Session not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + name_id_mapping: + type: string + format: uuid + nullable: true + title: NameID Property Mapping + description: Configure how the NameID value will be created. When left empty, + the NameIDPolicy of the incoming request will be considered + authn_context_class_ref_mapping: + type: string + format: uuid + nullable: true + title: AuthnContextClassRef Property Mapping + description: Configure how the AuthnContextClassRef value will be created. + When left empty, the AuthnContextClassRef will be set based on which authentication + methods the user used to authenticate. + digest_algorithm: + $ref: '#/components/schemas/DigestAlgorithmEnum' + signature_algorithm: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + signing_kp: + type: string + format: uuid + nullable: true + title: Signing Keypair + description: Keypair used to sign outgoing Responses going to the Service + Provider. + encryption_kp: + type: string + format: uuid + nullable: true + title: Encryption Keypair + description: When selected, incoming assertions are encrypted by the IdP + using the public key of the encryption keypair. The assertion is decrypted + by the SP using the the private key. + sign_assertion: + type: boolean + sign_logout_request: + type: boolean + default_name_id_policy: + $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + PatchedWebAuthnDeviceRequest: + type: object + description: Serializer for WebAuthn authenticator devices + properties: + name: + type: string + minLength: 1 + maxLength: 200 + Permission: + type: object + description: Global permission + properties: + id: + type: integer + readOnly: true + name: + type: string + maxLength: 255 + codename: + type: string + maxLength: 100 + model: + type: string + title: Python model class name + readOnly: true + app_label: + type: string + readOnly: true + app_label_verbose: + type: string + description: Human-readable app label + readOnly: true + model_verbose: + type: string + description: Human-readable model name + readOnly: true + required: + - app_label + - app_label_verbose + - codename + - id + - model + - model_verbose + - name + PermissionAssignRequest: + type: object + description: Request to assign a new permission + properties: + permissions: + type: array + items: + type: string + minLength: 1 + model: + $ref: '#/components/schemas/ModelEnum' + object_pk: + type: string + minLength: 1 + required: + - permissions + PermissionAssignResult: + type: object + description: Result from assigning permissions to a user/role + properties: + id: + type: string + required: + - id + PlexAuthenticationChallenge: + type: object + description: Challenge shown to the user in identification stage + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-source-plex + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + client_id: + type: string + slug: + type: string + required: + - client_id + - slug + PlexAuthenticationChallengeResponseRequest: + type: object + description: Pseudo class for plex response + properties: + component: + type: string + minLength: 1 + default: ak-source-plex + PlexSource: + type: object + description: Plex Source Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + description: Source's display Name. + slug: + type: string + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + readOnly: true + user_path_template: + type: string + icon: + type: string + icon_url: + type: string + readOnly: true + icon_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + client_id: + type: string + description: Client identifier used to talk to Plex. + allowed_servers: + type: array + items: + type: string + description: Which servers a user has to be a member of to be granted access. + Empty list allows every server. + allow_friends: + type: boolean + description: Allow friends to authenticate, even if you don't share a server. + plex_token: + type: string + description: Plex token used to check friends + required: + - component + - icon_themed_urls + - icon_url + - managed + - meta_model_name + - name + - pk + - plex_token + - slug + - verbose_name + - verbose_name_plural + PlexSourcePropertyMapping: + type: object + description: PlexSourcePropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + PlexSourcePropertyMappingRequest: + type: object + description: PlexSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + PlexSourceRequest: + type: object + description: Plex Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + client_id: + type: string + minLength: 1 + description: Client identifier used to talk to Plex. + allowed_servers: + type: array + items: + type: string + minLength: 1 + description: Which servers a user has to be a member of to be granted access. + Empty list allows every server. + allow_friends: + type: boolean + description: Allow friends to authenticate, even if you don't share a server. + plex_token: + type: string + minLength: 1 + description: Plex token used to check friends + required: + - name + - plex_token + - slug + PlexTokenRedeemRequest: + type: object + description: Serializer to redeem a plex token + properties: + plex_token: + type: string + minLength: 1 + required: + - plex_token + Policy: + type: object + description: Policy Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy uuid + name: + type: string + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + bound_to: + type: integer + description: Return objects policy is bound to + readOnly: true + required: + - bound_to + - component + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + PolicyBinding: + type: object + description: PolicyBinding Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy binding uuid + policy: + type: string + format: uuid + nullable: true + group: + type: string + format: uuid + nullable: true + user: + type: integer + nullable: true + policy_obj: + allOf: + - $ref: '#/components/schemas/Policy' + readOnly: true + nullable: true + group_obj: + allOf: + - $ref: '#/components/schemas/PartialGroup' + readOnly: true + nullable: true + user_obj: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + nullable: true + target: + type: string + format: uuid + negate: + type: boolean + description: Negates the outcome of the policy. Messages are unaffected. + enabled: + type: boolean + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + timeout: + type: integer + maximum: 2147483647 + minimum: 0 + description: Timeout after which Policy execution is terminated. + failure_result: + type: boolean + description: Result if the Policy execution fails. + required: + - group_obj + - order + - pk + - policy_obj + - target + - user_obj + PolicyBindingRequest: + type: object + description: PolicyBinding Serializer + properties: + policy: + type: string + format: uuid + nullable: true + group: + type: string + format: uuid + nullable: true + user: + type: integer + nullable: true + target: + type: string + format: uuid + negate: + type: boolean + description: Negates the outcome of the policy. Messages are unaffected. + enabled: + type: boolean + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + timeout: + type: integer + maximum: 2147483647 + minimum: 0 + description: Timeout after which Policy execution is terminated. + failure_result: + type: boolean + description: Result if the Policy execution fails. + required: + - order + - target + PolicyEngineMode: + enum: + - all + - any + type: string + PolicyTestRequest: + type: object + description: Test policy execution for a user with context + properties: + user: + type: integer + context: + type: object + additionalProperties: {} + required: + - user + PolicyTestResult: + type: object + description: result of a policy test + properties: + passing: + type: boolean + messages: + type: array + items: + type: string + readOnly: true + log_messages: + type: array + items: + $ref: '#/components/schemas/LogEvent' + readOnly: true + required: + - log_messages + - messages + - passing + Process: + type: object + properties: + id: + type: integer + name: + type: string + user: + type: string + required: + - id + - name + ProcessRequest: + type: object + properties: + id: + type: integer + name: + type: string + minLength: 1 + user: + type: string + minLength: 1 + required: + - id + - name + Prompt: + type: object + description: Prompt Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Prompt uuid + name: + type: string + field_key: + type: string + description: Name of the form field, also used to store the value + label: + type: string + type: + $ref: '#/components/schemas/PromptTypeEnum' + required: + type: boolean + placeholder: + type: string + description: Optionally provide a short hint that describes the expected + input value. When creating a fixed choice field, enable interpreting as + expression and return a list to return multiple choices. + initial_value: + type: string + description: Optionally pre-fill the input with an initial value. When creating + a fixed choice field, enable interpreting as expression and return a list + to return multiple default choices. + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + prompt_stages_obj: + type: array + items: + $ref: '#/components/schemas/PromptStage' + readOnly: true + sub_text: + type: string + placeholder_expression: + type: boolean + initial_value_expression: + type: boolean + required: + - field_key + - label + - name + - pk + - prompt_stages_obj + - type + PromptChallenge: + type: object + description: Initial challenge being sent, define fields + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-prompt + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + fields: + type: array + items: + $ref: '#/components/schemas/StagePrompt' + required: + - fields + PromptChallengeResponseRequest: + type: object + description: |- + Validate response, fields are dynamically created based + on the stage + properties: + component: + type: string + minLength: 1 + default: ak-stage-prompt + additionalProperties: {} + PromptChoice: + type: object + description: Serializer for a single Choice field + properties: + value: + type: string + label: + type: string + required: + - label + - value + PromptRequest: + type: object + description: Prompt Serializer + properties: + name: + type: string + minLength: 1 + field_key: + type: string + minLength: 1 + description: Name of the form field, also used to store the value + label: + type: string + minLength: 1 + type: + $ref: '#/components/schemas/PromptTypeEnum' + required: + type: boolean + placeholder: + type: string + description: Optionally provide a short hint that describes the expected + input value. When creating a fixed choice field, enable interpreting as + expression and return a list to return multiple choices. + initial_value: + type: string + description: Optionally pre-fill the input with an initial value. When creating + a fixed choice field, enable interpreting as expression and return a list + to return multiple default choices. + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + sub_text: + type: string + placeholder_expression: + type: boolean + initial_value_expression: + type: boolean + required: + - field_key + - label + - name + - type + PromptStage: + type: object + description: PromptStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + fields: + type: array + items: + type: string + format: uuid + validation_policies: + type: array + items: + type: string + format: uuid + required: + - component + - fields + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + PromptStageRequest: + type: object + description: PromptStage Serializer + properties: + name: + type: string + minLength: 1 + fields: + type: array + items: + type: string + format: uuid + validation_policies: + type: array + items: + type: string + format: uuid + required: + - fields + - name + PromptTypeEnum: + enum: + - text + - text_area + - text_read_only + - text_area_read_only + - username + - email + - password + - number + - checkbox + - radio-button-group + - dropdown + - date + - date-time + - file + - separator + - hidden + - static + - alert_info + - alert_warning + - alert_danger + - ak-locale + type: string + PropertyMapping: + type: object + description: PropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + PropertyMappingPreview: + type: object + description: Preview how the current user is mapped via the property mappings + selected in a provider + properties: + preview: + type: object + additionalProperties: {} + readOnly: true + required: + - preview + PropertyMappingTestRequest: + type: object + description: Test property mapping execution for a user/group with context + properties: + user: + type: integer + nullable: true + context: + type: object + additionalProperties: {} + group: + type: string + format: uuid + nullable: true + PropertyMappingTestResult: + type: object + description: Result of a Property-mapping test + properties: + result: + type: string + readOnly: true + successful: + type: boolean + readOnly: true + required: + - result + - successful + ProtocolEnum: + enum: + - rdp + - vnc + - ssh + type: string + Provider: + type: object + description: Provider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - assigned_application_name + - assigned_application_slug + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - authorization_flow + - component + - invalidation_flow + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + ProviderEnum: + enum: + - twilio + - generic + type: string + ProviderModelEnum: + enum: + - authentik_providers_google_workspace.googleworkspaceprovider + - authentik_providers_ldap.ldapprovider + - authentik_providers_microsoft_entra.microsoftentraprovider + - authentik_providers_oauth2.oauth2provider + - authentik_providers_proxy.proxyprovider + - authentik_providers_rac.racprovider + - authentik_providers_radius.radiusprovider + - authentik_providers_saml.samlprovider + - authentik_providers_scim.scimprovider + - authentik_providers_ssf.ssfprovider + - authentik_providers_ws_federation.wsfederationprovider + type: string + ProviderTypeEnum: + enum: + - openidconnect + - apple + - entraid + - azuread + - discord + - facebook + - github + - gitlab + - google + - mailcow + - okta + - patreon + - reddit + - slack + - twitch + - twitter + - wechat + type: string + ProxyMode: + enum: + - proxy + - forward_single + - forward_domain + type: string + ProxyOutpostConfig: + type: object + description: Proxy provider serializer for outposts + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + internal_host: + type: string + format: uri + external_host: + type: string + format: uri + internal_host_ssl_validation: + type: boolean + description: Validate SSL Certificates of upstream servers + client_id: + type: string + maxLength: 255 + client_secret: + type: string + maxLength: 255 + oidc_configuration: + allOf: + - $ref: '#/components/schemas/OpenIDConnectConfiguration' + readOnly: true + cookie_secret: + type: string + certificate: + type: string + format: uuid + nullable: true + skip_path_regex: + type: string + description: Regular expressions for which authentication is not required. + Each new line is interpreted as a new Regular Expression. + basic_auth_enabled: + type: boolean + title: Set HTTP-Basic Authentication + description: Set a custom HTTP-Basic Authentication header based on values + from authentik. + basic_auth_password_attribute: + type: string + title: HTTP-Basic Password Key + description: User/Group Attribute used for the password part of the HTTP-Basic + Header. + basic_auth_user_attribute: + type: string + title: HTTP-Basic Username Key + description: User/Group Attribute used for the user part of the HTTP-Basic + Header. If not set, the user's Email address is used. + mode: + allOf: + - $ref: '#/components/schemas/ProxyMode' + description: Enable support for forwardAuth in traefik and nginx auth_request. + Exclusive with internal_host. + cookie_domain: + type: string + access_token_validity: + type: number + format: double + nullable: true + description: Get token validity as second count + readOnly: true + intercept_header_auth: + type: boolean + description: When enabled, this provider will intercept the authorization + header and authenticate requests based on its value. + scopes_to_request: + type: array + items: + type: string + description: |- + Get all the scope names the outpost should request, + including custom-defined ones + readOnly: true + assigned_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + assigned_application_name: + type: string + description: Application's display Name. + readOnly: true + required: + - access_token_validity + - assigned_application_name + - assigned_application_slug + - external_host + - name + - oidc_configuration + - pk + - scopes_to_request + ProxyProvider: + type: object + description: ProxyProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + client_id: + type: string + readOnly: true + internal_host: + type: string + format: uri + external_host: + type: string + format: uri + internal_host_ssl_validation: + type: boolean + description: Validate SSL Certificates of upstream servers + certificate: + type: string + format: uuid + nullable: true + skip_path_regex: + type: string + description: Regular expressions for which authentication is not required. + Each new line is interpreted as a new Regular Expression. + basic_auth_enabled: + type: boolean + title: Set HTTP-Basic Authentication + description: Set a custom HTTP-Basic Authentication header based on values + from authentik. + basic_auth_password_attribute: + type: string + title: HTTP-Basic Password Key + description: User/Group Attribute used for the password part of the HTTP-Basic + Header. + basic_auth_user_attribute: + type: string + title: HTTP-Basic Username Key + description: User/Group Attribute used for the user part of the HTTP-Basic + Header. If not set, the user's Email address is used. + mode: + allOf: + - $ref: '#/components/schemas/ProxyMode' + description: Enable support for forwardAuth in traefik and nginx auth_request. + Exclusive with internal_host. + intercept_header_auth: + type: boolean + description: When enabled, this provider will intercept the authorization + header and authenticate requests based on its value. + redirect_uris: + type: array + items: + $ref: '#/components/schemas/RedirectURI' + readOnly: true + cookie_domain: + type: string + jwt_federation_sources: + type: array + items: + type: string + format: uuid + title: Any JWT signed by the JWK of the selected source can be used to + authenticate. + title: Any JWT signed by the JWK of the selected source can be used to authenticate. + jwt_federation_providers: + type: array + items: + type: integer + access_token_validity: + type: string + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + refresh_token_validity: + type: string + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + outpost_set: + type: array + items: + type: string + readOnly: true + required: + - assigned_application_name + - assigned_application_slug + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - authorization_flow + - client_id + - component + - external_host + - invalidation_flow + - meta_model_name + - name + - outpost_set + - pk + - redirect_uris + - verbose_name + - verbose_name_plural + ProxyProviderRequest: + type: object + description: ProxyProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + internal_host: + type: string + format: uri + external_host: + type: string + minLength: 1 + format: uri + internal_host_ssl_validation: + type: boolean + description: Validate SSL Certificates of upstream servers + certificate: + type: string + format: uuid + nullable: true + skip_path_regex: + type: string + description: Regular expressions for which authentication is not required. + Each new line is interpreted as a new Regular Expression. + basic_auth_enabled: + type: boolean + title: Set HTTP-Basic Authentication + description: Set a custom HTTP-Basic Authentication header based on values + from authentik. + basic_auth_password_attribute: + type: string + title: HTTP-Basic Password Key + description: User/Group Attribute used for the password part of the HTTP-Basic + Header. + basic_auth_user_attribute: + type: string + title: HTTP-Basic Username Key + description: User/Group Attribute used for the user part of the HTTP-Basic + Header. If not set, the user's Email address is used. + mode: + allOf: + - $ref: '#/components/schemas/ProxyMode' + description: Enable support for forwardAuth in traefik and nginx auth_request. + Exclusive with internal_host. + intercept_header_auth: + type: boolean + description: When enabled, this provider will intercept the authorization + header and authenticate requests based on its value. + cookie_domain: + type: string + jwt_federation_sources: + type: array + items: + type: string + format: uuid + title: Any JWT signed by the JWK of the selected source can be used to + authenticate. + title: Any JWT signed by the JWK of the selected source can be used to authenticate. + jwt_federation_providers: + type: array + items: + type: integer + access_token_validity: + type: string + minLength: 1 + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + refresh_token_validity: + type: string + minLength: 1 + description: 'Tokens not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + required: + - authorization_flow + - external_host + - invalidation_flow + - name + RACPropertyMapping: + type: object + description: RACPropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + static_settings: + type: object + additionalProperties: {} + required: + - component + - meta_model_name + - name + - pk + - static_settings + - verbose_name + - verbose_name_plural + RACPropertyMappingRequest: + type: object + description: RACPropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + static_settings: + type: object + additionalProperties: {} + required: + - name + - static_settings + RACProvider: + type: object + description: RACProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + settings: + type: object + additionalProperties: {} + outpost_set: + type: array + items: + type: string + readOnly: true + connection_expiry: + type: string + description: 'Determines how long a session lasts. Default of 0 means that + the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)' + delete_token_on_disconnect: + type: boolean + description: When set to true, connection tokens will be deleted upon disconnect. + required: + - assigned_application_name + - assigned_application_slug + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - authorization_flow + - component + - meta_model_name + - name + - outpost_set + - pk + - verbose_name + - verbose_name_plural + RACProviderRequest: + type: object + description: RACProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + property_mappings: + type: array + items: + type: string + format: uuid + settings: + type: object + additionalProperties: {} + connection_expiry: + type: string + minLength: 1 + description: 'Determines how long a session lasts. Default of 0 means that + the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)' + delete_token_on_disconnect: + type: boolean + description: When set to true, connection tokens will be deleted upon disconnect. + required: + - authorization_flow + - name + RadiusCheckAccess: + type: object + description: Base serializer class which doesn't implement create/update methods + properties: + attributes: + type: string + access: + $ref: '#/components/schemas/PolicyTestResult' + required: + - access + RadiusOutpostConfig: + type: object + description: RadiusProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + application_slug: + type: string + auth_flow_slug: + type: string + client_networks: + type: string + description: List of CIDRs (comma-separated) that clients can connect from. + A more specific CIDR will match before a looser one. Clients connecting + from a non-specified CIDR will be dropped. + shared_secret: + type: string + description: Shared secret between clients and server to hash packets. + mfa_support: + type: boolean + description: When enabled, code-based multi-factor authentication can be + used by appending a semicolon and the TOTP code to the password. This + should only be enabled if all users that will bind to this provider have + a TOTP device configured, as otherwise a password may incorrectly be rejected + if it contains a semicolon. + certificate: + type: string + format: uuid + nullable: true + required: + - application_slug + - auth_flow_slug + - name + - pk + RadiusProvider: + type: object + description: RadiusProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + client_networks: + type: string + description: List of CIDRs (comma-separated) that clients can connect from. + A more specific CIDR will match before a looser one. Clients connecting + from a non-specified CIDR will be dropped. + shared_secret: + type: string + description: Shared secret between clients and server to hash packets. + outpost_set: + type: array + items: + type: string + readOnly: true + mfa_support: + type: boolean + description: When enabled, code-based multi-factor authentication can be + used by appending a semicolon and the TOTP code to the password. This + should only be enabled if all users that will bind to this provider have + a TOTP device configured, as otherwise a password may incorrectly be rejected + if it contains a semicolon. + certificate: + type: string + format: uuid + nullable: true + required: + - assigned_application_name + - assigned_application_slug + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - authorization_flow + - component + - invalidation_flow + - meta_model_name + - name + - outpost_set + - pk + - verbose_name + - verbose_name_plural + RadiusProviderPropertyMapping: + type: object + description: RadiusProviderPropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + RadiusProviderPropertyMappingRequest: + type: object + description: RadiusProviderPropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + RadiusProviderRequest: + type: object + description: RadiusProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + client_networks: + type: string + minLength: 1 + description: List of CIDRs (comma-separated) that clients can connect from. + A more specific CIDR will match before a looser one. Clients connecting + from a non-specified CIDR will be dropped. + shared_secret: + type: string + minLength: 1 + description: Shared secret between clients and server to hash packets. + mfa_support: + type: boolean + description: When enabled, code-based multi-factor authentication can be + used by appending a semicolon and the TOTP code to the password. This + should only be enabled if all users that will bind to this provider have + a TOTP device configured, as otherwise a password may incorrectly be rejected + if it contains a semicolon. + certificate: + type: string + format: uuid + nullable: true + required: + - authorization_flow + - invalidation_flow + - name + RedirectChallenge: + type: object + description: Challenge type to redirect the client + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: xak-flow-redirect + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + to: + type: string + final_redirect: + type: boolean + default: false + required: + - to + RedirectChallengeResponseRequest: + type: object + description: Redirect challenge response + properties: + component: + type: string + minLength: 1 + default: xak-flow-redirect + to: + type: string + minLength: 1 + required: + - to + RedirectStage: + type: object + description: RedirectStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + keep_context: + type: boolean + mode: + $ref: '#/components/schemas/RedirectStageModeEnum' + target_static: + type: string + target_flow: + type: string + format: uuid + nullable: true + required: + - component + - flow_set + - meta_model_name + - mode + - name + - pk + - verbose_name + - verbose_name_plural + RedirectStageModeEnum: + enum: + - static + - flow + type: string + RedirectStageRequest: + type: object + description: RedirectStage Serializer + properties: + name: + type: string + minLength: 1 + keep_context: + type: boolean + mode: + $ref: '#/components/schemas/RedirectStageModeEnum' + target_static: + type: string + target_flow: + type: string + format: uuid + nullable: true + required: + - mode + - name + RedirectURI: + type: object + description: A single allowed redirect URI entry + properties: + matching_mode: + $ref: '#/components/schemas/MatchingModeEnum' + url: + type: string + redirect_uri_type: + allOf: + - $ref: '#/components/schemas/RedirectURITypeEnum' + default: authorization + required: + - matching_mode + - url + RedirectURIRequest: + type: object + description: A single allowed redirect URI entry + properties: + matching_mode: + $ref: '#/components/schemas/MatchingModeEnum' + url: + type: string + minLength: 1 + redirect_uri_type: + allOf: + - $ref: '#/components/schemas/RedirectURITypeEnum' + default: authorization + required: + - matching_mode + - url + RedirectURITypeEnum: + enum: + - authorization + - logout + type: string + RelatedGroup: + type: object + description: Stripped down group serializer to show relevant children/parents + for groups + properties: + pk: + type: string + format: uuid + readOnly: true + title: Group uuid + name: + type: string + is_superuser: + type: boolean + description: Users added to this group will be superusers. + attributes: + type: object + additionalProperties: {} + group_uuid: + type: string + format: uuid + readOnly: true + required: + - group_uuid + - name + - pk + RelatedRule: + type: object + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + properties: + id: + type: string + format: uuid + name: + type: string + reviewer_groups: + type: array + items: + $ref: '#/components/schemas/ReviewerGroup' + readOnly: true + min_reviewers: + type: integer + readOnly: true + reviewers: + type: array + items: + $ref: '#/components/schemas/ReviewerUser' + readOnly: true + required: + - min_reviewers + - name + - reviewer_groups + - reviewers + Reputation: + type: object + description: Reputation Serializer + properties: + pk: + type: string + format: uuid + title: Reputation uuid + identifier: + type: string + ip: + type: string + ip_geo_data: + type: object + additionalProperties: {} + ip_asn_data: + type: object + additionalProperties: {} + score: + type: integer + maximum: 9223372036854775807 + minimum: -9223372036854775808 + format: int64 + updated: + type: string + format: date-time + readOnly: true + required: + - identifier + - ip + - updated + ReputationPolicy: + type: object + description: Reputation Policy Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy uuid + name: + type: string + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + bound_to: + type: integer + description: Return objects policy is bound to + readOnly: true + check_ip: + type: boolean + check_username: + type: boolean + threshold: + type: integer + maximum: 2147483647 + minimum: -2147483648 + required: + - bound_to + - component + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + ReputationPolicyRequest: + type: object + description: Reputation Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + check_ip: + type: boolean + check_username: + type: boolean + threshold: + type: integer + maximum: 2147483647 + minimum: -2147483648 + required: + - name + Review: + type: object + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + properties: + id: + type: string + format: uuid + readOnly: true + iteration: + type: string + format: uuid + reviewer: + allOf: + - $ref: '#/components/schemas/ReviewerUser' + readOnly: true + timestamp: + type: string + format: date-time + readOnly: true + note: + type: string + nullable: true + required: + - id + - iteration + - reviewer + - timestamp + ReviewRequest: + type: object + description: |- + Mixin to validate that a valid enterprise license + exists before allowing to save the object + properties: + iteration: + type: string + format: uuid + note: + type: string + nullable: true + minLength: 1 + required: + - iteration + ReviewerGroup: + type: object + properties: + pk: + type: string + format: uuid + readOnly: true + title: Group uuid + name: + type: string + required: + - name + - pk + ReviewerUser: + type: object + properties: + pk: + type: integer + readOnly: true + title: ID + uuid: + type: string + format: uuid + readOnly: true + username: + type: string + description: Required. 150 characters or fewer. Letters, digits and @/./+/-/_ + only. + pattern: ^[\w.@+-]+$ + maxLength: 150 + name: + type: string + description: User's display name. + required: + - name + - pk + - username + - uuid + Role: + type: object + description: Role serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Uuid + name: + type: string + required: + - name + - pk + RoleAssignedObjectPermission: + type: object + description: Roles assigned object permission serializer + properties: + role_pk: + type: string + readOnly: true + name: + type: string + readOnly: true + object_permissions: + type: array + items: + $ref: '#/components/schemas/RoleObjectPermission' + model_permissions: + type: array + items: + $ref: '#/components/schemas/RoleModelPermission' + required: + - model_permissions + - name + - object_permissions + - role_pk + RoleModelPermission: + type: object + description: Role-bound object level permission + properties: + id: + type: integer + readOnly: true + codename: + type: string + readOnly: true + model: + type: string + title: Python model class name + readOnly: true + app_label: + type: string + readOnly: true + name: + type: string + readOnly: true + required: + - app_label + - codename + - id + - model + - name + RoleObjectPermission: + type: object + description: Role-bound object level permission + properties: + id: + type: integer + readOnly: true + codename: + type: string + readOnly: true + model: + type: string + title: Python model class name + readOnly: true + app_label: + type: string + readOnly: true + object_pk: + type: string + name: + type: string + readOnly: true + required: + - app_label + - codename + - id + - model + - name + - object_pk + RoleRequest: + type: object + description: Role serializer + properties: + name: + type: string + minLength: 1 + required: + - name + SAMLBindingsEnum: + enum: + - redirect + - post + type: string + SAMLLogoutMethods: + enum: + - frontchannel_iframe + - frontchannel_native + - backchannel + type: string + SAMLMetadata: + type: object + description: SAML Provider Metadata serializer + properties: + metadata: + type: string + download_url: + type: string + nullable: true + required: + - metadata + SAMLNameIDPolicyEnum: + enum: + - urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress + - urn:oasis:names:tc:SAML:2.0:nameid-format:persistent + - urn:oasis:names:tc:SAML:1.1:nameid-format:X509SubjectName + - urn:oasis:names:tc:SAML:2.0:nameid-format:WindowsDomainQualifiedName + - urn:oasis:names:tc:SAML:2.0:nameid-format:transient + - urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified + type: string + SAMLPropertyMapping: + type: object + description: SAMLPropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + saml_name: + type: string + friendly_name: + type: string + nullable: true + required: + - component + - expression + - meta_model_name + - name + - pk + - saml_name + - verbose_name + - verbose_name_plural + SAMLPropertyMappingRequest: + type: object + description: SAMLPropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + saml_name: + type: string + minLength: 1 + friendly_name: + type: string + nullable: true + required: + - expression + - name + - saml_name + SAMLProvider: + type: object + description: SAMLProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + acs_url: + type: string + format: uri + sls_url: + type: string + description: Single Logout Service URL where the logout response should + be sent. + format: uri + audience: + type: string + description: Value of the audience restriction field of the assertion. When + left empty, no audience restriction will be added. + issuer_override: + type: string + description: Also known as EntityID. Providing a value overrides the default + issuer generated by authentik. + assertion_valid_not_before: + type: string + description: 'Assertion valid not before current time + this value (Format: + hours=-1;minutes=-2;seconds=-3).' + assertion_valid_not_on_or_after: + type: string + description: 'Assertion not valid on or after current time + this value + (Format: hours=1;minutes=2;seconds=3).' + session_valid_not_on_or_after: + type: string + description: 'Session not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + name_id_mapping: + type: string + format: uuid + nullable: true + title: NameID Property Mapping + description: Configure how the NameID value will be created. When left empty, + the NameIDPolicy of the incoming request will be considered + authn_context_class_ref_mapping: + type: string + format: uuid + nullable: true + title: AuthnContextClassRef Property Mapping + description: Configure how the AuthnContextClassRef value will be created. + When left empty, the AuthnContextClassRef will be set based on which authentication + methods the user used to authenticate. + digest_algorithm: + $ref: '#/components/schemas/DigestAlgorithmEnum' + signature_algorithm: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + signing_kp: + type: string + format: uuid + nullable: true + title: Signing Keypair + description: Keypair used to sign outgoing Responses going to the Service + Provider. + verification_kp: + type: string + format: uuid + nullable: true + title: Verification Certificate + description: When selected, incoming assertion's Signatures will be validated + against this certificate. To allow unsigned Requests, leave on default. + encryption_kp: + type: string + format: uuid + nullable: true + title: Encryption Keypair + description: When selected, incoming assertions are encrypted by the IdP + using the public key of the encryption keypair. The assertion is decrypted + by the SP using the the private key. + sign_assertion: + type: boolean + sign_response: + type: boolean + sign_logout_request: + type: boolean + sign_logout_response: + type: boolean + sp_binding: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + title: Service Provider Binding + description: This determines how authentik sends the response back to the + Service Provider. + sls_binding: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + description: This determines how authentik sends the logout response back + to the Service Provider. + logout_method: + allOf: + - $ref: '#/components/schemas/SAMLLogoutMethods' + description: Method to use for logout. Front-channel iframe loads all logout + URLs simultaneously in hidden iframes. Front-channel native uses your + active browser tab to send post requests and redirect to providers. Back-channel + sends logout requests directly from the server without user interaction + (requires POST SLS binding). + default_relay_state: + type: string + description: Default relay_state value for IDP-initiated logins + default_name_id_policy: + $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + url_download_metadata: + type: string + description: Get metadata download URL + readOnly: true + url_issuer: + type: string + description: Get Issuer/EntityID URL + readOnly: true + url_unified: + type: string + description: Get unified SAML endpoint URL (handles SSO and SLO) + readOnly: true + url_unified_init: + type: string + description: Get IdP-initiated SAML URL + readOnly: true + url_sso_post: + type: string + description: Get SSO Post URL + readOnly: true + url_sso_redirect: + type: string + description: Get SSO Redirect URL + readOnly: true + url_sso_init: + type: string + description: Get SSO IDP-Initiated URL + readOnly: true + url_slo_post: + type: string + description: Get SLO POST URL + readOnly: true + url_slo_redirect: + type: string + description: Get SLO redirect URL + readOnly: true + required: + - acs_url + - assigned_application_name + - assigned_application_slug + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - authorization_flow + - component + - invalidation_flow + - meta_model_name + - name + - pk + - url_download_metadata + - url_issuer + - url_slo_post + - url_slo_redirect + - url_sso_init + - url_sso_post + - url_sso_redirect + - url_unified + - url_unified_init + - verbose_name + - verbose_name_plural + SAMLProviderImportRequest: + type: object + description: Import saml provider from XML Metadata + properties: + name: + type: string + minLength: 1 + authorization_flow: + type: string + format: uuid + invalidation_flow: + type: string + format: uuid + file: + type: string + format: binary + required: + - authorization_flow + - file + - invalidation_flow + - name + SAMLProviderRequest: + type: object + description: SAMLProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + acs_url: + type: string + minLength: 1 + format: uri + sls_url: + type: string + description: Single Logout Service URL where the logout response should + be sent. + format: uri + audience: + type: string + description: Value of the audience restriction field of the assertion. When + left empty, no audience restriction will be added. + issuer_override: + type: string + description: Also known as EntityID. Providing a value overrides the default + issuer generated by authentik. + assertion_valid_not_before: + type: string + minLength: 1 + description: 'Assertion valid not before current time + this value (Format: + hours=-1;minutes=-2;seconds=-3).' + assertion_valid_not_on_or_after: + type: string + minLength: 1 + description: 'Assertion not valid on or after current time + this value + (Format: hours=1;minutes=2;seconds=3).' + session_valid_not_on_or_after: + type: string + minLength: 1 + description: 'Session not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + name_id_mapping: + type: string + format: uuid + nullable: true + title: NameID Property Mapping + description: Configure how the NameID value will be created. When left empty, + the NameIDPolicy of the incoming request will be considered + authn_context_class_ref_mapping: + type: string + format: uuid + nullable: true + title: AuthnContextClassRef Property Mapping + description: Configure how the AuthnContextClassRef value will be created. + When left empty, the AuthnContextClassRef will be set based on which authentication + methods the user used to authenticate. + digest_algorithm: + $ref: '#/components/schemas/DigestAlgorithmEnum' + signature_algorithm: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + signing_kp: + type: string + format: uuid + nullable: true + title: Signing Keypair + description: Keypair used to sign outgoing Responses going to the Service + Provider. + verification_kp: + type: string + format: uuid + nullable: true + title: Verification Certificate + description: When selected, incoming assertion's Signatures will be validated + against this certificate. To allow unsigned Requests, leave on default. + encryption_kp: + type: string + format: uuid + nullable: true + title: Encryption Keypair + description: When selected, incoming assertions are encrypted by the IdP + using the public key of the encryption keypair. The assertion is decrypted + by the SP using the the private key. + sign_assertion: + type: boolean + sign_response: + type: boolean + sign_logout_request: + type: boolean + sign_logout_response: + type: boolean + sp_binding: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + title: Service Provider Binding + description: This determines how authentik sends the response back to the + Service Provider. + sls_binding: + allOf: + - $ref: '#/components/schemas/SAMLBindingsEnum' + description: This determines how authentik sends the logout response back + to the Service Provider. + logout_method: + allOf: + - $ref: '#/components/schemas/SAMLLogoutMethods' + description: Method to use for logout. Front-channel iframe loads all logout + URLs simultaneously in hidden iframes. Front-channel native uses your + active browser tab to send post requests and redirect to providers. Back-channel + sends logout requests directly from the server without user interaction + (requires POST SLS binding). + default_relay_state: + type: string + description: Default relay_state value for IDP-initiated logins + default_name_id_policy: + $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + required: + - acs_url + - authorization_flow + - invalidation_flow + - name + SAMLSource: + type: object + description: SAMLSource Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + description: Source's display Name. + slug: + type: string + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + readOnly: true + user_path_template: + type: string + icon: + type: string + icon_url: + type: string + readOnly: true + icon_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + pre_authentication_flow: + type: string + format: uuid + description: Flow used before authentication. + issuer: + type: string + description: Also known as Entity ID. Defaults the Metadata URL. + sso_url: + type: string + description: URL that the initial Login request is sent to. + format: uri + slo_url: + type: string + nullable: true + description: Optional URL if your IDP supports Single-Logout. + format: uri + allow_idp_initiated: + type: boolean + description: Allows authentication flows initiated by the IdP. This can + be a security risk, as no validation of the request ID is done. + force_authn: + type: boolean + description: When enabled, the IdP will re-authenticate the user even if + a session exists. + name_id_policy: + allOf: + - $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + description: NameID Policy sent to the IdP. Can be unset, in which case + no Policy is sent. + binding_type: + $ref: '#/components/schemas/BindingTypeEnum' + verification_kp: + type: string + format: uuid + nullable: true + title: Verification Certificate + description: When selected, incoming assertion's Signatures will be validated + against this certificate. To allow unsigned Requests, leave on default. + signing_kp: + type: string + format: uuid + nullable: true + title: Signing Keypair + description: Keypair used to sign outgoing Responses going to the Identity + Provider. + digest_algorithm: + $ref: '#/components/schemas/DigestAlgorithmEnum' + signature_algorithm: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + temporary_user_delete_after: + type: string + title: Delete temporary users after + description: 'Time offset when temporary users should be deleted. This only + applies if your IDP uses the NameID Format ''transient'', and the user + doesn''t log out manually. (Format: hours=1;minutes=2;seconds=3).' + encryption_kp: + type: string + format: uuid + nullable: true + title: Encryption Keypair + description: When selected, incoming assertions are encrypted by the IdP + using the public key of the encryption keypair. The assertion is decrypted + by the SP using the the private key. + signed_assertion: + type: boolean + signed_response: + type: boolean + required: + - component + - icon_themed_urls + - icon_url + - managed + - meta_model_name + - name + - pk + - pre_authentication_flow + - slug + - sso_url + - verbose_name + - verbose_name_plural + SAMLSourcePropertyMapping: + type: object + description: SAMLSourcePropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + SAMLSourcePropertyMappingRequest: + type: object + description: SAMLSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + SAMLSourceRequest: + type: object + description: SAMLSource Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + group_matching_mode: + allOf: + - $ref: '#/components/schemas/GroupMatchingModeEnum' + description: How the source determines if an existing group should be used + or a new group created. + pre_authentication_flow: + type: string + format: uuid + description: Flow used before authentication. + issuer: + type: string + description: Also known as Entity ID. Defaults the Metadata URL. + sso_url: + type: string + minLength: 1 + description: URL that the initial Login request is sent to. + format: uri + slo_url: + type: string + nullable: true + description: Optional URL if your IDP supports Single-Logout. + format: uri + allow_idp_initiated: + type: boolean + description: Allows authentication flows initiated by the IdP. This can + be a security risk, as no validation of the request ID is done. + force_authn: + type: boolean + description: When enabled, the IdP will re-authenticate the user even if + a session exists. + name_id_policy: + allOf: + - $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + description: NameID Policy sent to the IdP. Can be unset, in which case + no Policy is sent. + binding_type: + $ref: '#/components/schemas/BindingTypeEnum' + verification_kp: + type: string + format: uuid + nullable: true + title: Verification Certificate + description: When selected, incoming assertion's Signatures will be validated + against this certificate. To allow unsigned Requests, leave on default. + signing_kp: + type: string + format: uuid + nullable: true + title: Signing Keypair + description: Keypair used to sign outgoing Responses going to the Identity + Provider. + digest_algorithm: + $ref: '#/components/schemas/DigestAlgorithmEnum' + signature_algorithm: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + temporary_user_delete_after: + type: string + minLength: 1 + title: Delete temporary users after + description: 'Time offset when temporary users should be deleted. This only + applies if your IDP uses the NameID Format ''transient'', and the user + doesn''t log out manually. (Format: hours=1;minutes=2;seconds=3).' + encryption_kp: + type: string + format: uuid + nullable: true + title: Encryption Keypair + description: When selected, incoming assertions are encrypted by the IdP + using the public key of the encryption keypair. The assertion is decrypted + by the SP using the the private key. + signed_assertion: + type: boolean + signed_response: + type: boolean + required: + - name + - pre_authentication_flow + - slug + - sso_url + SCIMAuthenticationModeEnum: + enum: + - token + - oauth + - oauth_interactive + type: string + SCIMMapping: + type: object + description: SCIMMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + SCIMMappingRequest: + type: object + description: SCIMMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + SCIMProvider: + type: object + description: SCIMProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + property_mappings: + type: array + items: + type: string + format: uuid + property_mappings_group: + type: array + items: + type: string + format: uuid + description: Property mappings used for group creation/updating. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + url: + type: string + description: Base URL to SCIM requests, usually ends in /v2 + verify_certificates: + type: boolean + auth_mode: + $ref: '#/components/schemas/SCIMAuthenticationModeEnum' + auth_oauth: + type: string + format: uuid + nullable: true + description: OAuth Source used for authentication + auth_oauth_params: + type: object + additionalProperties: {} + description: Additional OAuth parameters, such as grant_type + auth_oauth_token_last_updated: + type: string + format: date-time + nullable: true + readOnly: true + auth_oauth_token_expires: + type: string + format: date-time + nullable: true + readOnly: true + auth_oauth_url_callback: + type: string + nullable: true + readOnly: true + auth_oauth_url_start: + type: string + nullable: true + readOnly: true + compatibility_mode: + allOf: + - $ref: '#/components/schemas/CompatibilityModeEnum' + title: SCIM Compatibility Mode + description: Alter authentik behavior for vendor-specific SCIM implementations. + service_provider_config_cache_timeout: + type: string + description: Cache duration for ServiceProviderConfig responses. Set minutes=0 + to disable. + exclude_users_service_account: + type: boolean + sync_page_size: + type: integer + maximum: 2147483647 + minimum: 1 + description: Controls the number of objects synced in a single task + sync_page_timeout: + type: string + description: Timeout for synchronization of a single page + group_filters: + type: array + items: + type: string + format: uuid + description: Group filters used to define sync-scope for groups. + dry_run: + type: boolean + description: When enabled, provider will not modify or create objects in + the remote system. + required: + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - auth_oauth_token_expires + - auth_oauth_token_last_updated + - auth_oauth_url_callback + - auth_oauth_url_start + - component + - meta_model_name + - name + - pk + - url + - verbose_name + - verbose_name_plural + SCIMProviderGroup: + type: object + description: SCIMProviderGroup Serializer + properties: + id: + type: string + format: uuid + readOnly: true + scim_id: + type: string + group: + type: string + format: uuid + group_obj: + allOf: + - $ref: '#/components/schemas/PartialGroup' + readOnly: true + provider: + type: integer + attributes: + type: object + additionalProperties: {} + readOnly: true + required: + - attributes + - group + - group_obj + - id + - provider + - scim_id + SCIMProviderGroupRequest: + type: object + description: SCIMProviderGroup Serializer + properties: + scim_id: + type: string + minLength: 1 + group: + type: string + format: uuid + provider: + type: integer + required: + - group + - provider + - scim_id + SCIMProviderRequest: + type: object + description: SCIMProvider Serializer + properties: + name: + type: string + minLength: 1 + property_mappings: + type: array + items: + type: string + format: uuid + property_mappings_group: + type: array + items: + type: string + format: uuid + description: Property mappings used for group creation/updating. + url: + type: string + minLength: 1 + description: Base URL to SCIM requests, usually ends in /v2 + verify_certificates: + type: boolean + token: + type: string + writeOnly: true + description: Authentication token + auth_mode: + $ref: '#/components/schemas/SCIMAuthenticationModeEnum' + auth_oauth: + type: string + format: uuid + nullable: true + description: OAuth Source used for authentication + auth_oauth_params: + type: object + additionalProperties: {} + description: Additional OAuth parameters, such as grant_type + compatibility_mode: + allOf: + - $ref: '#/components/schemas/CompatibilityModeEnum' + title: SCIM Compatibility Mode + description: Alter authentik behavior for vendor-specific SCIM implementations. + service_provider_config_cache_timeout: + type: string + minLength: 1 + description: Cache duration for ServiceProviderConfig responses. Set minutes=0 + to disable. + exclude_users_service_account: + type: boolean + sync_page_size: + type: integer + maximum: 2147483647 + minimum: 1 + description: Controls the number of objects synced in a single task + sync_page_timeout: + type: string + minLength: 1 + description: Timeout for synchronization of a single page + group_filters: + type: array + items: + type: string + format: uuid + description: Group filters used to define sync-scope for groups. + dry_run: + type: boolean + description: When enabled, provider will not modify or create objects in + the remote system. + required: + - name + - url + SCIMProviderUser: + type: object + description: SCIMProviderUser Serializer + properties: + id: + type: string + format: uuid + readOnly: true + scim_id: + type: string + user: + type: integer + user_obj: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + provider: + type: integer + attributes: + type: object + additionalProperties: {} + readOnly: true + required: + - attributes + - id + - provider + - scim_id + - user + - user_obj + SCIMProviderUserRequest: + type: object + description: SCIMProviderUser Serializer + properties: + scim_id: + type: string + minLength: 1 + user: + type: integer + provider: + type: integer + required: + - provider + - scim_id + - user + SCIMSource: + type: object + description: SCIMSource Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + description: Source's display Name. + slug: + type: string + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + readOnly: true + user_path_template: + type: string + root_url: + type: string + description: Get Root URL + readOnly: true + token_obj: + allOf: + - $ref: '#/components/schemas/Token' + readOnly: true + required: + - component + - managed + - meta_model_name + - name + - pk + - root_url + - slug + - token_obj + - verbose_name + - verbose_name_plural + SCIMSourceGroup: + type: object + description: SCIMSourceGroup Serializer + properties: + id: + type: string + external_id: + type: string + group: + type: string + format: uuid + group_obj: + allOf: + - $ref: '#/components/schemas/PartialGroup' + readOnly: true + source: + type: string + format: uuid + attributes: + type: object + additionalProperties: {} + required: + - external_id + - group + - group_obj + - source + SCIMSourceGroupRequest: + type: object + description: SCIMSourceGroup Serializer + properties: + id: + type: string + minLength: 1 + external_id: + type: string + minLength: 1 + group: + type: string + format: uuid + source: + type: string + format: uuid + attributes: + type: object + additionalProperties: {} + required: + - external_id + - group + - source + SCIMSourcePropertyMapping: + type: object + description: SCIMSourcePropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + SCIMSourcePropertyMappingRequest: + type: object + description: SCIMSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + SCIMSourceRequest: + type: object + description: SCIMSource Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + user_path_template: + type: string + minLength: 1 + required: + - name + - slug + SCIMSourceUser: + type: object + description: SCIMSourceUser Serializer + properties: + id: + type: string + external_id: + type: string + user: + type: integer + user_obj: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + source: + type: string + format: uuid + attributes: + type: object + additionalProperties: {} + required: + - external_id + - source + - user + - user_obj + SCIMSourceUserRequest: + type: object + description: SCIMSourceUser Serializer + properties: + id: + type: string + minLength: 1 + external_id: + type: string + minLength: 1 + user: + type: integer + source: + type: string + format: uuid + attributes: + type: object + additionalProperties: {} + required: + - external_id + - source + - user + SMSDevice: + type: object + description: Serializer for sms authenticator devices + properties: + name: + type: string + description: The human-readable name of this device. + maxLength: 64 + pk: + type: integer + readOnly: true + title: ID + phone_number: + type: string + readOnly: true + user: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + required: + - name + - phone_number + - pk + - user + SMSDeviceRequest: + type: object + description: Serializer for sms authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + required: + - name + SSFProvider: + type: object + description: SSFProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + signing_key: + type: string + format: uuid + description: Key used to sign the SSF Events. + token_obj: + allOf: + - $ref: '#/components/schemas/Token' + readOnly: true + oidc_auth_providers: + type: array + items: + type: integer + oidc_auth_providers_obj: + type: array + items: + $ref: '#/components/schemas/Provider' + readOnly: true + ssf_url: + type: string + nullable: true + readOnly: true + event_retention: + type: string + push_verify_certificates: + type: boolean + required: + - component + - meta_model_name + - name + - oidc_auth_providers_obj + - pk + - signing_key + - ssf_url + - token_obj + - verbose_name + - verbose_name_plural + SSFProviderRequest: + type: object + description: SSFProvider Serializer + properties: + name: + type: string + minLength: 1 + signing_key: + type: string + format: uuid + description: Key used to sign the SSF Events. + oidc_auth_providers: + type: array + items: + type: integer + event_retention: + type: string + minLength: 1 + push_verify_certificates: + type: boolean + required: + - name + - signing_key + SSFStream: + type: object + description: SSFStream Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Uuid + status: + $ref: '#/components/schemas/SSFStreamStatusEnum' + provider: + type: integer + provider_obj: + allOf: + - $ref: '#/components/schemas/SSFProvider' + readOnly: true + delivery_method: + $ref: '#/components/schemas/DeliveryMethodEnum' + endpoint_url: + type: string + nullable: true + events_requested: + type: array + items: + $ref: '#/components/schemas/EventsRequestedEnum' + format: + type: string + aud: + type: array + items: + type: string + iss: + type: string + required: + - delivery_method + - format + - iss + - pk + - provider + - provider_obj + SSFStreamStatusEnum: + enum: + - enabled + - paused + - disabled + - disabled_deleted + type: string + Schedule: + type: object + properties: + id: + type: string + format: uuid + readOnly: true + identifier: + type: string + readOnly: true + nullable: true + description: Unique schedule identifier + uid: + type: string + readOnly: true + actor_name: + type: string + readOnly: true + description: Dramatiq actor to call + rel_obj_app_label: + type: string + readOnly: true + rel_obj_model: + type: string + title: Python model class name + readOnly: true + rel_obj_id: + type: string + nullable: true + crontab: + type: string + description: When to schedule tasks + paused: + type: boolean + description: Pause this schedule + next_run: + type: string + format: date-time + readOnly: true + description: + type: string + nullable: true + readOnly: true + last_task_status: + allOf: + - $ref: '#/components/schemas/LastTaskStatusEnum' + nullable: true + readOnly: true + required: + - actor_name + - crontab + - description + - id + - identifier + - last_task_status + - next_run + - rel_obj_app_label + - rel_obj_model + - uid + ScheduleRequest: + type: object + properties: + rel_obj_id: + type: string + nullable: true + minLength: 1 + crontab: + type: string + minLength: 1 + description: When to schedule tasks + paused: + type: boolean + description: Pause this schedule + required: + - crontab + ScopeMapping: + type: object + description: ScopeMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + scope_name: + type: string + description: Scope name requested by the client + description: + type: string + description: Description shown to the user when consenting. If left empty, + the user won't be informed. + required: + - component + - expression + - meta_model_name + - name + - pk + - scope_name + - verbose_name + - verbose_name_plural + ScopeMappingRequest: + type: object + description: ScopeMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + scope_name: + type: string + minLength: 1 + description: Scope name requested by the client + description: + type: string + description: Description shown to the user when consenting. If left empty, + the user won't be informed. + required: + - expression + - name + - scope_name + SelectableStage: + type: object + description: Serializer for stages which can be selected by users + properties: + pk: + type: string + format: uuid + name: + type: string + verbose_name: + type: string + meta_model_name: + type: string + required: + - meta_model_name + - name + - pk + - verbose_name + ServiceConnection: + type: object + description: ServiceConnection Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Uuid + name: + type: string + local: + type: boolean + description: If enabled, use the local connection. Required Docker socket/Kubernetes + Integration + component: + type: string + description: Return component used to edit this object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + ServiceConnectionState: + type: object + description: Serializer for Service connection state + properties: + healthy: + type: boolean + readOnly: true + version: + type: string + readOnly: true + required: + - healthy + - version + SessionEndChallenge: + type: object + description: Challenge for ending a session + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-session-end + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + application_name: + type: string + application_launch_url: + type: string + invalidation_flow_url: + type: string + overview_url: + type: string + brand_name: + type: string + required: + - brand_name + - pending_user + - pending_user_avatar + SessionUser: + type: object + description: |- + Response for the /user/me endpoint, returns the currently active user (as `user` property) + and, if this user is being impersonated, the original user in the `original` property. + properties: + user: + $ref: '#/components/schemas/UserSelf' + original: + $ref: '#/components/schemas/UserSelf' + required: + - user + Settings: + type: object + description: Settings Serializer + properties: + avatars: + type: string + description: Configure how authentik should show avatars for users. + default_user_change_name: + type: boolean + description: Enable the ability for users to change their name. + default_user_change_email: + type: boolean + description: Enable the ability for users to change their email address. + default_user_change_username: + type: boolean + description: Enable the ability for users to change their username. + event_retention: + type: string + description: 'Events will be deleted after this duration.(Format: weeks=3;days=2;hours=3,seconds=2).' + reputation_lower_limit: + type: integer + maximum: 0 + minimum: -2147483648 + description: Reputation cannot decrease lower than this value. Zero or negative. + reputation_upper_limit: + type: integer + maximum: 2147483647 + minimum: 0 + description: Reputation cannot increase higher than this value. Zero or + positive. + footer_links: {} + gdpr_compliance: + type: boolean + description: When enabled, all the events caused by a user will be deleted + upon the user's deletion. + impersonation: + type: boolean + description: Globally enable/disable impersonation. + impersonation_require_reason: + type: boolean + description: Require administrators to provide a reason for impersonating + a user. + default_token_duration: + type: string + description: Default token duration + default_token_length: + type: integer + maximum: 2147483647 + minimum: 1 + description: Default token length + pagination_default_page_size: + type: integer + maximum: 2147483647 + minimum: 0 + description: Default page size for API responses, if no size was requested. + pagination_max_page_size: + type: integer + maximum: 2147483647 + minimum: 0 + description: Maximum page size + flags: + type: object + properties: + core_default_app_access: + type: boolean + description: Configure if applications without any policy/group/user + bindings should be accessible to any user. + enterprise_audit_include_expanded_diff: + type: boolean + description: Include additional information in audit logs, may incur + a performance penalty. + flows_continuous_login: + type: boolean + description: Upon successful authentication, re-start authentication + in other open tabs. + flows_refresh_others: + type: boolean + description: Refresh other tabs after successful authentication. + deprecated: true + required: + - core_default_app_access + - enterprise_audit_include_expanded_diff + - flows_continuous_login + - flows_refresh_others + required: + - flags + SettingsRequest: + type: object + description: Settings Serializer + properties: + avatars: + type: string + minLength: 1 + description: Configure how authentik should show avatars for users. + default_user_change_name: + type: boolean + description: Enable the ability for users to change their name. + default_user_change_email: + type: boolean + description: Enable the ability for users to change their email address. + default_user_change_username: + type: boolean + description: Enable the ability for users to change their username. + event_retention: + type: string + minLength: 1 + description: 'Events will be deleted after this duration.(Format: weeks=3;days=2;hours=3,seconds=2).' + reputation_lower_limit: + type: integer + maximum: 0 + minimum: -2147483648 + description: Reputation cannot decrease lower than this value. Zero or negative. + reputation_upper_limit: + type: integer + maximum: 2147483647 + minimum: 0 + description: Reputation cannot increase higher than this value. Zero or + positive. + footer_links: {} + gdpr_compliance: + type: boolean + description: When enabled, all the events caused by a user will be deleted + upon the user's deletion. + impersonation: + type: boolean + description: Globally enable/disable impersonation. + impersonation_require_reason: + type: boolean + description: Require administrators to provide a reason for impersonating + a user. + default_token_duration: + type: string + minLength: 1 + description: Default token duration + default_token_length: + type: integer + maximum: 2147483647 + minimum: 1 + description: Default token length + pagination_default_page_size: + type: integer + maximum: 2147483647 + minimum: 0 + description: Default page size for API responses, if no size was requested. + pagination_max_page_size: + type: integer + maximum: 2147483647 + minimum: 0 + description: Maximum page size + flags: + type: object + properties: + core_default_app_access: + type: boolean + description: Configure if applications without any policy/group/user + bindings should be accessible to any user. + enterprise_audit_include_expanded_diff: + type: boolean + description: Include additional information in audit logs, may incur + a performance penalty. + flows_continuous_login: + type: boolean + description: Upon successful authentication, re-start authentication + in other open tabs. + flows_refresh_others: + type: boolean + description: Refresh other tabs after successful authentication. + deprecated: true + required: + - core_default_app_access + - enterprise_audit_include_expanded_diff + - flows_continuous_login + - flows_refresh_others + required: + - flags + SeverityEnum: + enum: + - notice + - warning + - alert + type: string + ShellChallenge: + type: object + description: challenge type to render HTML as-is + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: xak-flow-shell + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + body: + type: string + required: + - body + SignatureAlgorithmEnum: + enum: + - http://www.w3.org/2000/09/xmldsig#rsa-sha1 + - http://www.w3.org/2001/04/xmldsig-more#rsa-sha256 + - http://www.w3.org/2001/04/xmldsig-more#rsa-sha384 + - http://www.w3.org/2001/04/xmldsig-more#rsa-sha512 + - http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha1 + - http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha256 + - http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha384 + - http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha512 + - http://www.w3.org/2000/09/xmldsig#dsa-sha1 + type: string + Software: + type: object + properties: + name: + type: string + version: + type: string + source: + type: string + path: + type: string + required: + - name + - source + SoftwareRequest: + type: object + properties: + name: + type: string + minLength: 1 + version: + type: string + source: + type: string + minLength: 1 + path: + type: string + minLength: 1 + required: + - name + - source + Source: + type: object + description: Source Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + description: Source's display Name. + slug: + type: string + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + readOnly: true + user_path_template: + type: string + icon: + type: string + icon_url: + type: string + nullable: true + description: Get the URL to the source icon + readOnly: true + icon_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + required: + - component + - icon_themed_urls + - icon_url + - managed + - meta_model_name + - name + - pk + - slug + - verbose_name + - verbose_name_plural + SourceStage: + type: object + description: SourceStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + source: + type: string + format: uuid + resume_timeout: + type: string + description: 'Amount of time a user can take to return from the source to + continue the flow (Format: hours=-1;minutes=-2;seconds=-3)' + required: + - component + - flow_set + - meta_model_name + - name + - pk + - source + - verbose_name + - verbose_name_plural + SourceStageRequest: + type: object + description: SourceStage Serializer + properties: + name: + type: string + minLength: 1 + source: + type: string + format: uuid + resume_timeout: + type: string + minLength: 1 + description: 'Amount of time a user can take to return from the source to + continue the flow (Format: hours=-1;minutes=-2;seconds=-3)' + required: + - name + - source + SourceType: + type: object + description: Serializer for SourceType + properties: + name: + type: string + verbose_name: + type: string + urls_customizable: + type: boolean + request_token_url: + type: string + readOnly: true + nullable: true + authorization_url: + type: string + readOnly: true + nullable: true + access_token_url: + type: string + readOnly: true + nullable: true + profile_url: + type: string + readOnly: true + nullable: true + oidc_well_known_url: + type: string + readOnly: true + nullable: true + oidc_jwks_url: + type: string + readOnly: true + nullable: true + required: + - access_token_url + - authorization_url + - name + - oidc_jwks_url + - oidc_well_known_url + - profile_url + - request_token_url + - urls_customizable + - verbose_name + Stage: + type: object + description: Stage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + StageModeEnum: + enum: + - optional + - required + type: string + StagePrompt: + type: object + description: Serializer for a single Prompt field + properties: + field_key: + type: string + label: + type: string + type: + $ref: '#/components/schemas/PromptTypeEnum' + required: + type: boolean + placeholder: + type: string + initial_value: + type: string + order: + type: integer + sub_text: + type: string + choices: + type: array + items: + $ref: '#/components/schemas/PromptChoice' + nullable: true + required: + - choices + - field_key + - initial_value + - label + - order + - placeholder + - required + - sub_text + - type + StaticDevice: + type: object + description: Serializer for static authenticator devices + properties: + name: + type: string + description: The human-readable name of this device. + maxLength: 64 + token_set: + type: array + items: + $ref: '#/components/schemas/StaticDeviceToken' + readOnly: true + pk: + type: integer + readOnly: true + title: ID + user: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + required: + - name + - pk + - token_set + - user + StaticDeviceRequest: + type: object + description: Serializer for static authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + required: + - name + StaticDeviceToken: + type: object + description: Serializer for static device's tokens + properties: + token: + type: string + maxLength: 100 + required: + - token + SubModeEnum: + enum: + - hashed_user_id + - user_id + - user_uuid + - user_username + - user_email + - user_upn + type: string + SyncObjectModelEnum: + enum: + - authentik.core.models.User + - authentik.core.models.Group + type: string + SyncObjectRequest: + type: object + description: Sync object serializer + properties: + sync_object_model: + $ref: '#/components/schemas/SyncObjectModelEnum' + sync_object_id: + type: string + minLength: 1 + override_dry_run: + type: boolean + default: false + required: + - sync_object_id + - sync_object_model + SyncObjectResult: + type: object + description: Result of a single object sync + properties: + messages: + type: array + items: + $ref: '#/components/schemas/LogEvent' + readOnly: true + required: + - messages + SyncOutgoingTriggerModeEnum: + enum: + - none + - immediate + - deferred_end + type: string + SyncStatus: + type: object + description: Provider/source sync status + properties: + is_running: + type: boolean + last_successful_sync: + type: string + format: date-time + last_sync_status: + $ref: '#/components/schemas/TaskAggregatedStatusEnum' + required: + - is_running + SystemInfo: + type: object + description: Get system information. + properties: + http_headers: + type: object + additionalProperties: + type: string + description: Get HTTP Request headers + readOnly: true + http_host: + type: string + description: Get HTTP host + readOnly: true + http_is_secure: + type: boolean + description: Get HTTP Secure flag + readOnly: true + runtime: + type: object + description: Get versions + properties: + python_version: + type: string + environment: + type: string + architecture: + type: string + platform: + type: string + uname: + type: string + openssl_version: + type: string + openssl_fips_enabled: + type: boolean + nullable: true + authentik_version: + type: string + required: + - architecture + - authentik_version + - environment + - openssl_fips_enabled + - openssl_version + - platform + - python_version + - uname + readOnly: true + brand: + type: string + description: Currently active brand + readOnly: true + server_time: + type: string + format: date-time + description: Current server time + readOnly: true + embedded_outpost_disabled: + type: boolean + description: Whether the embedded outpost is disabled + readOnly: true + embedded_outpost_host: + type: string + description: Get the FQDN configured on the embedded outpost + readOnly: true + required: + - brand + - embedded_outpost_disabled + - embedded_outpost_host + - http_headers + - http_host + - http_is_secure + - runtime + - server_time + TOTPDevice: + type: object + description: Serializer for totp authenticator devices + properties: + name: + type: string + description: The human-readable name of this device. + maxLength: 64 + pk: + type: integer + readOnly: true + title: ID + user: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + required: + - name + - pk + - user + TOTPDeviceRequest: + type: object + description: Serializer for totp authenticator devices + properties: + name: + type: string + minLength: 1 + description: The human-readable name of this device. + maxLength: 64 + required: + - name + Task: + type: object + properties: + message_id: + type: string + format: uuid + queue_name: + type: string + description: Queue name + actor_name: + type: string + description: Dramatiq actor name + state: + allOf: + - $ref: '#/components/schemas/TaskStatusEnum' + description: Task status + mtime: + type: string + format: date-time + description: Task last modified time + retries: + type: integer + maximum: 9223372036854775807 + minimum: 0 + format: int64 + description: Number of retries + eta: + type: string + format: date-time + nullable: true + description: Planned execution time + rel_obj_app_label: + type: string + readOnly: true + rel_obj_model: + type: string + title: Python model class name + readOnly: true + rel_obj_id: + type: string + nullable: true + uid: + type: string + readOnly: true + logs: + type: array + items: + $ref: '#/components/schemas/LogEvent' + readOnly: true + previous_logs: + type: array + items: + $ref: '#/components/schemas/LogEvent' + readOnly: true + aggregated_status: + $ref: '#/components/schemas/TaskAggregatedStatusEnum' + description: + type: string + nullable: true + readOnly: true + required: + - actor_name + - aggregated_status + - description + - logs + - previous_logs + - rel_obj_app_label + - rel_obj_model + - uid + TaskAggregatedStatusEnum: + enum: + - queued + - consumed + - preprocess + - running + - postprocess + - rejected + - done + - info + - warning + - error + type: string + TaskStatusEnum: + enum: + - queued + - consumed + - preprocess + - running + - postprocess + - rejected + - done + type: string + TelegramAuthRequest: + type: object + properties: + id: + type: integer + first_name: + type: string + minLength: 1 + maxLength: 255 + last_name: + type: string + minLength: 1 + maxLength: 255 + username: + type: string + minLength: 1 + maxLength: 255 + photo_url: + type: string + format: uri + minLength: 1 + auth_date: + type: integer + hash: + type: string + minLength: 1 + maxLength: 64 + required: + - auth_date + - hash + - id + TelegramChallengeResponseRequest: + type: object + description: Base class for all challenge responses + properties: + id: + type: integer + first_name: + type: string + minLength: 1 + maxLength: 255 + last_name: + type: string + minLength: 1 + maxLength: 255 + username: + type: string + minLength: 1 + maxLength: 255 + photo_url: + type: string + format: uri + minLength: 1 + auth_date: + type: integer + hash: + type: string + minLength: 1 + maxLength: 64 + component: + type: string + minLength: 1 + default: ak-source-telegram + required: + - auth_date + - hash + - id + TelegramLoginChallenge: + type: object + description: Base login challenge for Identification stage + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-source-telegram + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + bot_username: + type: string + description: Telegram bot username + request_message_access: + type: boolean + required: + - bot_username + - request_message_access + TelegramSource: + type: object + description: Source Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pbm uuid + name: + type: string + description: Source's display Name. + slug: + type: string + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + readOnly: true + user_path_template: + type: string + icon: + type: string + icon_url: + type: string + nullable: true + readOnly: true + icon_themed_urls: + allOf: + - $ref: '#/components/schemas/ThemedUrls' + readOnly: true + nullable: true + bot_username: + type: string + description: Telegram bot username + request_message_access: + type: boolean + description: Request access to send messages from your bot. + pre_authentication_flow: + type: string + format: uuid + description: Flow used before authentication. + required: + - bot_username + - component + - icon_themed_urls + - icon_url + - managed + - meta_model_name + - name + - pk + - pre_authentication_flow + - slug + - verbose_name + - verbose_name_plural + TelegramSourcePropertyMapping: + type: object + description: TelegramSourcePropertyMapping Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Pm uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + expression: + type: string + component: + type: string + description: Get object's component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + required: + - component + - expression + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + TelegramSourcePropertyMappingRequest: + type: object + description: TelegramSourcePropertyMapping Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + name: + type: string + minLength: 1 + expression: + type: string + minLength: 1 + required: + - expression + - name + TelegramSourceRequest: + type: object + description: Source Serializer + properties: + name: + type: string + minLength: 1 + description: Source's display Name. + slug: + type: string + minLength: 1 + description: Internal source name, used in URLs. + pattern: ^[-a-zA-Z0-9_]+$ + enabled: + type: boolean + promoted: + type: boolean + description: When enabled, this source will be displayed as a prominent + button on the login page, instead of a small icon. + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow to use when authenticating existing users. + enrollment_flow: + type: string + format: uuid + nullable: true + description: Flow to use when enrolling new users. + user_property_mappings: + type: array + items: + type: string + format: uuid + group_property_mappings: + type: array + items: + type: string + format: uuid + policy_engine_mode: + $ref: '#/components/schemas/PolicyEngineMode' + user_matching_mode: + allOf: + - $ref: '#/components/schemas/UserMatchingModeEnum' + description: How the source determines if an existing user should be authenticated + or a new user enrolled. + user_path_template: + type: string + minLength: 1 + icon: + type: string + bot_username: + type: string + minLength: 1 + description: Telegram bot username + bot_token: + type: string + writeOnly: true + minLength: 1 + description: Telegram bot token + request_message_access: + type: boolean + description: Request access to send messages from your bot. + pre_authentication_flow: + type: string + format: uuid + description: Flow used before authentication. + required: + - bot_token + - bot_username + - name + - pre_authentication_flow + - slug + Tenant: + type: object + description: Tenant Serializer + properties: + tenant_uuid: + type: string + format: uuid + readOnly: true + schema_name: + type: string + maxLength: 63 + name: + type: string + ready: + type: boolean + required: + - name + - schema_name + - tenant_uuid + TenantAdminGroupRequestRequest: + type: object + description: Tenant admin group creation request serializer + properties: + user: + type: string + minLength: 1 + required: + - user + TenantRecoveryKeyRequestRequest: + type: object + description: Tenant recovery key creation request serializer + properties: + user: + type: string + minLength: 1 + duration_days: + type: integer + required: + - duration_days + - user + TenantRecoveryKeyResponse: + type: object + description: Tenant recovery key creation response serializer + properties: + expiry: + type: string + format: date-time + url: + type: string + required: + - expiry + - url + TenantRequest: + type: object + description: Tenant Serializer + properties: + schema_name: + type: string + minLength: 1 + maxLength: 63 + name: + type: string + minLength: 1 + ready: + type: boolean + required: + - name + - schema_name + ThemedUrls: + type: object + description: Themed URLs - maps theme names to URLs for light and dark themes + properties: + light: + type: string + nullable: true + dark: + type: string + nullable: true + Token: + type: object + description: Token Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Token uuid + managed: + type: string + nullable: true + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + identifier: + type: string + maxLength: 255 + pattern: ^[-a-zA-Z0-9_]+$ + intent: + $ref: '#/components/schemas/IntentEnum' + user: + type: integer + user_obj: + allOf: + - $ref: '#/components/schemas/User' + readOnly: true + description: + type: string + expires: + type: string + format: date-time + nullable: true + expiring: + type: boolean + required: + - identifier + - pk + - user_obj + TokenModel: + type: object + description: Serializer for BaseGrantModel and RefreshToken + properties: + pk: + type: integer + readOnly: true + title: ID + provider: + $ref: '#/components/schemas/Provider' + user: + $ref: '#/components/schemas/User' + is_expired: + type: boolean + description: Check if token is expired yet. + readOnly: true + expires: + type: string + format: date-time + nullable: true + scope: + type: array + items: + type: string + id_token: + type: string + description: Get the token's id_token as JSON String + readOnly: true + revoked: + type: boolean + required: + - id_token + - is_expired + - pk + - provider + - scope + - user + TokenRequest: + type: object + description: Token Serializer + properties: + managed: + type: string + nullable: true + minLength: 1 + title: Managed by authentik + description: Objects that are managed by authentik. These objects are created + and updated automatically. This flag only indicates that an object can + be overwritten by migrations. You can still modify the objects via the + API, but expect changes to be overwritten in a later update. + identifier: + type: string + minLength: 1 + maxLength: 255 + pattern: ^[-a-zA-Z0-9_]+$ + intent: + $ref: '#/components/schemas/IntentEnum' + user: + type: integer + description: + type: string + expires: + type: string + format: date-time + nullable: true + expiring: + type: boolean + required: + - identifier + TokenSetKeyRequest: + type: object + description: Set token's key + properties: + key: + type: string + minLength: 1 + required: + - key + TokenView: + type: object + description: Show token's current key + properties: + key: + type: string + readOnly: true + required: + - key + TransactionApplicationRequest: + type: object + description: Serializer for creating a provider and an application in one transaction + properties: + app: + $ref: '#/components/schemas/ApplicationRequest' + provider_model: + $ref: '#/components/schemas/ProviderModelEnum' + provider: + $ref: '#/components/schemas/modelRequest' + policy_bindings: + type: array + items: + $ref: '#/components/schemas/TransactionPolicyBindingRequest' + required: + - app + - provider + - provider_model + TransactionApplicationResponse: + type: object + description: Transactional creation response + properties: + applied: + type: boolean + logs: + type: array + items: + type: string + required: + - applied + - logs + TransactionPolicyBindingRequest: + type: object + description: PolicyBindingSerializer which does not require target as target + is set implicitly + properties: + policy: + type: string + format: uuid + nullable: true + group: + type: string + format: uuid + nullable: true + user: + type: integer + nullable: true + negate: + type: boolean + description: Negates the outcome of the policy. Messages are unaffected. + enabled: + type: boolean + order: + type: integer + maximum: 2147483647 + minimum: -2147483648 + timeout: + type: integer + maximum: 2147483647 + minimum: 0 + description: Timeout after which Policy execution is terminated. + failure_result: + type: boolean + description: Result if the Policy execution fails. + required: + - order + TransportModeEnum: + enum: + - local + - webhook + - webhook_slack + - email + type: string + TypeCreate: + type: object + description: Types of an object that can be created + properties: + name: + type: string + description: + type: string + component: + type: string + model_name: + type: string + icon_url: + type: string + requires_enterprise: + type: boolean + default: false + deprecated: + type: boolean + default: false + required: + - component + - description + - model_name + - name + UiThemeEnum: + enum: + - automatic + - light + - dark + type: string + UniquePasswordPolicy: + type: object + description: Password Uniqueness Policy Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Policy uuid + name: + type: string + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + bound_to: + type: integer + description: Return objects policy is bound to + readOnly: true + password_field: + type: string + description: Field key to check, field keys defined in Prompt stages are + available. + num_historical_passwords: + type: integer + maximum: 2147483647 + minimum: 0 + description: Number of passwords to check against. + required: + - bound_to + - component + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + UniquePasswordPolicyRequest: + type: object + description: Password Uniqueness Policy Serializer + properties: + name: + type: string + minLength: 1 + execution_logging: + type: boolean + description: When this option is enabled, all executions of this policy + will be logged. By default, only execution errors are logged. + password_field: + type: string + minLength: 1 + description: Field key to check, field keys defined in Prompt stages are + available. + num_historical_passwords: + type: integer + maximum: 2147483647 + minimum: 0 + description: Number of passwords to check against. + required: + - name + UsageEnum: + enum: + - media + type: string + UsedBy: + type: object + description: A list of all objects referencing the queried object + properties: + app: + type: string + model_name: + type: string + pk: + type: string + name: + type: string + action: + $ref: '#/components/schemas/UsedByActionEnum' + required: + - action + - app + - model_name + - name + - pk + UsedByActionEnum: + enum: + - cascade + - cascade_many + - set_null + - set_default + - left_dangling + type: string + User: + type: object + description: User Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + username: + type: string + maxLength: 150 + name: + type: string + description: User's display name. + is_active: + type: boolean + title: Active + description: Designates whether this user should be treated as active. Unselect + this instead of deleting accounts. + last_login: + type: string + format: date-time + nullable: true + date_joined: + type: string + format: date-time + readOnly: true + is_superuser: + type: boolean + readOnly: true + groups: + type: array + items: + type: string + format: uuid + groups_obj: + type: array + items: + $ref: '#/components/schemas/PartialGroup' + readOnly: true + nullable: true + roles: + type: array + items: + type: string + format: uuid + roles_obj: + type: array + items: + $ref: '#/components/schemas/Role' + readOnly: true + nullable: true + email: + type: string + format: email + title: Email address + maxLength: 254 + avatar: + type: string + description: User's avatar, either a http/https URL or a data URI + readOnly: true + attributes: + type: object + additionalProperties: {} + uid: + type: string + readOnly: true + path: + type: string + type: + $ref: '#/components/schemas/UserTypeEnum' + uuid: + type: string + format: uuid + readOnly: true + password_change_date: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - avatar + - date_joined + - groups_obj + - is_superuser + - last_updated + - name + - password_change_date + - pk + - roles_obj + - uid + - username + - uuid + UserAccountLockdownRequest: + type: object + description: Choose the target account before starting the lockdown flow. + properties: + user: + type: integer + nullable: true + description: User to lock. If omitted, locks the current user (self-service). + UserAccountRequest: + type: object + description: Account adding/removing operations + properties: + pk: + type: integer + required: + - pk + UserAccountSerializerForRoleRequest: + type: object + description: Account adding/removing operations + properties: + pk: + type: integer + required: + - pk + UserAttributeEnum: + enum: + - username + - email + type: string + UserConsent: + type: object + description: UserConsent Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + expires: + type: string + format: date-time + nullable: true + expiring: + type: boolean + user: + $ref: '#/components/schemas/User' + application: + $ref: '#/components/schemas/Application' + permissions: + type: string + default: '' + required: + - application + - pk + - user + UserCreationModeEnum: + enum: + - never_create + - create_when_required + - always_create + type: string + UserDeleteStage: + type: object + description: UserDeleteStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + UserDeleteStageRequest: + type: object + description: UserDeleteStage Serializer + properties: + name: + type: string + minLength: 1 + required: + - name + UserFieldsEnum: + enum: + - email + - username + - upn + type: string + UserKerberosSourceConnection: + type: object + description: User source connection + properties: + pk: + type: integer + readOnly: true + title: ID + user: + type: integer + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - identifier + - last_updated + - pk + - source + - source_obj + - user + UserKerberosSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + UserLDAPSourceConnection: + type: object + description: User source connection + properties: + pk: + type: integer + readOnly: true + title: ID + user: + type: integer + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + user_obj: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + required: + - created + - identifier + - last_updated + - pk + - source + - source_obj + - user + - user_obj + UserLDAPSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + UserLoginChallenge: + type: object + description: Empty challenge + properties: + flow_info: + $ref: '#/components/schemas/ContextualFlowInfo' + component: + type: string + default: ak-stage-user-login + response_errors: + type: object + additionalProperties: + type: array + items: + $ref: '#/components/schemas/ErrorDetail' + pending_user: + type: string + pending_user_avatar: + type: string + required: + - pending_user + - pending_user_avatar + UserLoginChallengeResponseRequest: + type: object + description: User login challenge + properties: + component: + type: string + minLength: 1 + default: ak-stage-user-login + remember_me: + type: boolean + required: + - remember_me + UserLoginStage: + type: object + description: UserLoginStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + session_duration: + type: string + description: 'Determines how long a session lasts. Default of 0 means that + the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)' + terminate_other_sessions: + type: boolean + description: Terminate all other sessions of the user logging in. + remember_me_offset: + type: string + description: 'Offset the session will be extended by when the user picks + the remember me option. Default of 0 means that the remember me option + will not be shown. (Format: hours=-1;minutes=-2;seconds=-3)' + network_binding: + allOf: + - $ref: '#/components/schemas/NetworkBindingEnum' + description: Bind sessions created by this stage to the configured network + geoip_binding: + allOf: + - $ref: '#/components/schemas/GeoipBindingEnum' + description: Bind sessions created by this stage to the configured GeoIP + location + remember_device: + type: string + description: 'When set to a non-zero value, authentik will save a cookie + with a longer expiry,to remember the device the user is logging in from. + (Format: hours=-1;minutes=-2;seconds=-3)' + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + UserLoginStageRequest: + type: object + description: UserLoginStage Serializer + properties: + name: + type: string + minLength: 1 + session_duration: + type: string + minLength: 1 + description: 'Determines how long a session lasts. Default of 0 means that + the sessions lasts until the browser is closed. (Format: hours=-1;minutes=-2;seconds=-3)' + terminate_other_sessions: + type: boolean + description: Terminate all other sessions of the user logging in. + remember_me_offset: + type: string + minLength: 1 + description: 'Offset the session will be extended by when the user picks + the remember me option. Default of 0 means that the remember me option + will not be shown. (Format: hours=-1;minutes=-2;seconds=-3)' + network_binding: + allOf: + - $ref: '#/components/schemas/NetworkBindingEnum' + description: Bind sessions created by this stage to the configured network + geoip_binding: + allOf: + - $ref: '#/components/schemas/GeoipBindingEnum' + description: Bind sessions created by this stage to the configured GeoIP + location + remember_device: + type: string + minLength: 1 + description: 'When set to a non-zero value, authentik will save a cookie + with a longer expiry,to remember the device the user is logging in from. + (Format: hours=-1;minutes=-2;seconds=-3)' + required: + - name + UserLogoutStage: + type: object + description: UserLogoutStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + UserLogoutStageRequest: + type: object + description: UserLogoutStage Serializer + properties: + name: + type: string + minLength: 1 + required: + - name + UserMatchingModeEnum: + enum: + - identifier + - email_link + - email_deny + - username_link + - username_deny + type: string + UserOAuthSourceConnection: + type: object + description: User source connection + properties: + pk: + type: integer + readOnly: true + title: ID + user: + type: integer + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + expires: + type: string + format: date-time + required: + - created + - identifier + - last_updated + - pk + - source + - source_obj + - user + UserOAuthSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + access_token: + type: string + writeOnly: true + nullable: true + expires: + type: string + format: date-time + required: + - identifier + - source + UserPasswordHashSetRequest: + type: object + description: Payload to set a users' password hash directly + properties: + password: + type: string + minLength: 1 + required: + - password + UserPasswordSetRequest: + type: object + description: Payload to set a users' password directly + properties: + password: + type: string + minLength: 1 + required: + - password + UserPath: + type: object + properties: + paths: + type: array + items: + type: string + readOnly: true + required: + - paths + UserPlexSourceConnection: + type: object + description: User source connection + properties: + pk: + type: integer + readOnly: true + title: ID + user: + type: integer + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - identifier + - last_updated + - pk + - source + - source_obj + - user + UserPlexSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + plex_token: + type: string + writeOnly: true + minLength: 1 + required: + - identifier + - plex_token + - source + UserRecoveryEmailRequest: + type: object + description: Payload to create and email a recovery link + properties: + token_duration: + type: string + minLength: 1 + email_stage: + type: string + format: uuid + required: + - email_stage + UserRecoveryLinkRequest: + type: object + description: Payload to create a recovery link + properties: + token_duration: + type: string + minLength: 1 + UserRequest: + type: object + description: User Serializer + properties: + username: + type: string + minLength: 1 + maxLength: 150 + name: + type: string + description: User's display name. + is_active: + type: boolean + title: Active + description: Designates whether this user should be treated as active. Unselect + this instead of deleting accounts. + last_login: + type: string + format: date-time + nullable: true + groups: + type: array + items: + type: string + format: uuid + roles: + type: array + items: + type: string + format: uuid + email: + type: string + format: email + title: Email address + maxLength: 254 + attributes: + type: object + additionalProperties: {} + path: + type: string + minLength: 1 + type: + $ref: '#/components/schemas/UserTypeEnum' + required: + - name + - username + UserSAMLSourceConnection: + type: object + description: User source connection + properties: + pk: + type: integer + readOnly: true + title: ID + user: + type: integer + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - identifier + - last_updated + - pk + - source + - source_obj + - user + UserSAMLSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + UserSelf: + type: object + description: User Serializer for information a user can retrieve about themselves + properties: + pk: + type: integer + readOnly: true + title: ID + username: + type: string + description: Required. 150 characters or fewer. Letters, digits and @/./+/-/_ + only. + pattern: ^[\w.@+-]+$ + maxLength: 150 + name: + type: string + description: User's display name. + is_active: + type: boolean + readOnly: true + title: Active + description: Designates whether this user should be treated as active. Unselect + this instead of deleting accounts. + is_superuser: + type: boolean + readOnly: true + groups: + type: array + items: + $ref: '#/components/schemas/UserSelfGroups' + readOnly: true + roles: + type: array + items: + $ref: '#/components/schemas/UserSelfRoles' + readOnly: true + email: + type: string + format: email + title: Email address + maxLength: 254 + avatar: + type: string + description: User's avatar, either a http/https URL or a data URI + readOnly: true + uid: + type: string + readOnly: true + settings: + type: object + additionalProperties: {} + description: Get user settings with brand and group settings applied + readOnly: true + type: + $ref: '#/components/schemas/UserTypeEnum' + system_permissions: + type: array + items: + type: string + description: Get all system permissions assigned to the user + readOnly: true + required: + - avatar + - groups + - is_active + - is_superuser + - name + - pk + - roles + - settings + - system_permissions + - uid + - username + UserSelfGroups: + type: object + properties: + name: + type: string + readOnly: true + pk: + type: string + readOnly: true + required: + - name + - pk + UserSelfRoles: + type: object + properties: + name: + type: string + readOnly: true + pk: + type: string + readOnly: true + required: + - name + - pk + UserServiceAccountRequest: + type: object + description: Payload to create a service account + properties: + name: + type: string + minLength: 1 + create_group: + type: boolean + default: false + expiring: + type: boolean + default: true + expires: + type: string + format: date-time + description: If not provided, valid for 360 days + required: + - name + UserServiceAccountResponse: + type: object + properties: + username: + type: string + token: + type: string + user_uid: + type: string + user_pk: + type: integer + group_pk: + type: string + required: + - token + - user_pk + - user_uid + - username + UserSetting: + type: object + description: Serializer for User settings for stages and sources + properties: + object_uid: + type: string + component: + type: string + title: + type: string + configure_url: + type: string + icon_url: + type: string + required: + - component + - object_uid + - title + UserSourceConnection: + type: object + description: User source connection + properties: + pk: + type: integer + readOnly: true + title: ID + user: + type: integer + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - identifier + - last_updated + - pk + - source + - source_obj + - user + UserSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + UserTelegramSourceConnection: + type: object + description: User source connection + properties: + pk: + type: integer + readOnly: true + title: ID + user: + type: integer + readOnly: true + source: + type: string + format: uuid + source_obj: + allOf: + - $ref: '#/components/schemas/Source' + readOnly: true + identifier: + type: string + created: + type: string + format: date-time + readOnly: true + last_updated: + type: string + format: date-time + readOnly: true + required: + - created + - identifier + - last_updated + - pk + - source + - source_obj + - user + UserTelegramSourceConnectionRequest: + type: object + description: User source connection + properties: + source: + type: string + format: uuid + identifier: + type: string + minLength: 1 + required: + - identifier + - source + UserTypeEnum: + enum: + - internal + - external + - service_account + - internal_service_account + type: string + UserVerificationEnum: + enum: + - required + - preferred + - discouraged + type: string + UserWriteStage: + type: object + description: UserWriteStage Serializer + properties: + pk: + type: string + format: uuid + readOnly: true + title: Stage uuid + name: + type: string + component: + type: string + description: Get object type so that we know how to edit the object + readOnly: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + flow_set: + type: array + items: + $ref: '#/components/schemas/FlowSet' + readOnly: true + user_creation_mode: + $ref: '#/components/schemas/UserCreationModeEnum' + create_users_as_inactive: + type: boolean + description: When set, newly created users are inactive and cannot login. + create_users_group: + type: string + format: uuid + nullable: true + description: Optionally add newly created users to this group. + user_type: + $ref: '#/components/schemas/UserTypeEnum' + user_path_template: + type: string + required: + - component + - flow_set + - meta_model_name + - name + - pk + - verbose_name + - verbose_name_plural + UserWriteStageRequest: + type: object + description: UserWriteStage Serializer + properties: + name: + type: string + minLength: 1 + user_creation_mode: + $ref: '#/components/schemas/UserCreationModeEnum' + create_users_as_inactive: + type: boolean + description: When set, newly created users are inactive and cannot login. + create_users_group: + type: string + format: uuid + nullable: true + description: Optionally add newly created users to this group. + user_type: + $ref: '#/components/schemas/UserTypeEnum' + user_path_template: + type: string + required: + - name + ValidationError: + type: object + description: Validation Error + properties: + non_field_errors: + type: array + items: + type: string + code: + type: string + additionalProperties: {} + VendorEnum: + enum: + - goauthentik.io/@merged + - goauthentik.io/platform + - fleetdm.com + - chrome.google.com + type: string + Version: + type: object + description: Get running and latest version. + properties: + version_current: + type: string + description: Get current version + readOnly: true + version_latest: + type: string + description: Get latest version from cache + readOnly: true + version_latest_valid: + type: boolean + description: Check if latest version is valid + readOnly: true + build_hash: + type: string + description: Get build hash, if version is not latest or released + readOnly: true + outdated: + type: boolean + description: Check if we're running the latest version + readOnly: true + outpost_outdated: + type: boolean + description: Check if any outpost is outdated/has a version mismatch + readOnly: true + required: + - build_hash + - outdated + - outpost_outdated + - version_current + - version_latest + - version_latest_valid + VersionHistory: + type: object + description: VersionHistory Serializer + properties: + id: + type: integer + readOnly: true + timestamp: + type: string + format: date-time + version: + type: string + build: + type: string + required: + - build + - id + - timestamp + - version + WSFederationProvider: + type: object + description: WSFederationProvider Serializer + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + component: + type: string + description: Get object component so that we know how to edit the object + readOnly: true + assigned_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + assigned_backchannel_application_slug: + type: string + description: Internal application name, used in URLs. + readOnly: true + nullable: true + assigned_backchannel_application_name: + type: string + description: Application's display Name. + readOnly: true + nullable: true + verbose_name: + type: string + description: Return object's verbose_name + readOnly: true + verbose_name_plural: + type: string + description: Return object's plural verbose_name + readOnly: true + meta_model_name: + type: string + description: Return internal model name + readOnly: true + reply_url: + type: string + format: uri + wtrealm: + type: string + assertion_valid_not_before: + type: string + description: 'Assertion valid not before current time + this value (Format: + hours=-1;minutes=-2;seconds=-3).' + assertion_valid_not_on_or_after: + type: string + description: 'Assertion not valid on or after current time + this value + (Format: hours=1;minutes=2;seconds=3).' + session_valid_not_on_or_after: + type: string + description: 'Session not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + name_id_mapping: + type: string + format: uuid + nullable: true + title: NameID Property Mapping + description: Configure how the NameID value will be created. When left empty, + the NameIDPolicy of the incoming request will be considered + authn_context_class_ref_mapping: + type: string + format: uuid + nullable: true + title: AuthnContextClassRef Property Mapping + description: Configure how the AuthnContextClassRef value will be created. + When left empty, the AuthnContextClassRef will be set based on which authentication + methods the user used to authenticate. + digest_algorithm: + $ref: '#/components/schemas/DigestAlgorithmEnum' + signature_algorithm: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + signing_kp: + type: string + format: uuid + nullable: true + title: Signing Keypair + description: Keypair used to sign outgoing Responses going to the Service + Provider. + encryption_kp: + type: string + format: uuid + nullable: true + title: Encryption Keypair + description: When selected, incoming assertions are encrypted by the IdP + using the public key of the encryption keypair. The assertion is decrypted + by the SP using the the private key. + sign_assertion: + type: boolean + sign_logout_request: + type: boolean + default_name_id_policy: + $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + url_download_metadata: + type: string + description: Get metadata download URL + readOnly: true + url_wsfed: + type: string + description: Get WS-Fed url + readOnly: true + required: + - assigned_application_name + - assigned_application_slug + - assigned_backchannel_application_name + - assigned_backchannel_application_slug + - authorization_flow + - component + - invalidation_flow + - meta_model_name + - name + - pk + - reply_url + - url_download_metadata + - url_wsfed + - verbose_name + - verbose_name_plural + - wtrealm + WSFederationProviderRequest: + type: object + description: WSFederationProvider Serializer + properties: + name: + type: string + minLength: 1 + authentication_flow: + type: string + format: uuid + nullable: true + description: Flow used for authentication when the associated application + is accessed by an un-authenticated user. + authorization_flow: + type: string + format: uuid + description: Flow used when authorizing this provider. + invalidation_flow: + type: string + format: uuid + description: Flow used ending the session from a provider. + property_mappings: + type: array + items: + type: string + format: uuid + reply_url: + type: string + format: uri + minLength: 1 + wtrealm: + type: string + minLength: 1 + assertion_valid_not_before: + type: string + minLength: 1 + description: 'Assertion valid not before current time + this value (Format: + hours=-1;minutes=-2;seconds=-3).' + assertion_valid_not_on_or_after: + type: string + minLength: 1 + description: 'Assertion not valid on or after current time + this value + (Format: hours=1;minutes=2;seconds=3).' + session_valid_not_on_or_after: + type: string + minLength: 1 + description: 'Session not valid on or after current time + this value (Format: + hours=1;minutes=2;seconds=3).' + name_id_mapping: + type: string + format: uuid + nullable: true + title: NameID Property Mapping + description: Configure how the NameID value will be created. When left empty, + the NameIDPolicy of the incoming request will be considered + authn_context_class_ref_mapping: + type: string + format: uuid + nullable: true + title: AuthnContextClassRef Property Mapping + description: Configure how the AuthnContextClassRef value will be created. + When left empty, the AuthnContextClassRef will be set based on which authentication + methods the user used to authenticate. + digest_algorithm: + $ref: '#/components/schemas/DigestAlgorithmEnum' + signature_algorithm: + $ref: '#/components/schemas/SignatureAlgorithmEnum' + signing_kp: + type: string + format: uuid + nullable: true + title: Signing Keypair + description: Keypair used to sign outgoing Responses going to the Service + Provider. + encryption_kp: + type: string + format: uuid + nullable: true + title: Encryption Keypair + description: When selected, incoming assertions are encrypted by the IdP + using the public key of the encryption keypair. The assertion is decrypted + by the SP using the the private key. + sign_assertion: + type: boolean + sign_logout_request: + type: boolean + default_name_id_policy: + $ref: '#/components/schemas/SAMLNameIDPolicyEnum' + required: + - authorization_flow + - invalidation_flow + - name + - reply_url + - wtrealm + WebAuthnDevice: + type: object + description: Serializer for WebAuthn authenticator devices + properties: + pk: + type: integer + readOnly: true + title: ID + name: + type: string + maxLength: 200 + created_on: + type: string + format: date-time + readOnly: true + device_type: + allOf: + - $ref: '#/components/schemas/WebAuthnDeviceType' + readOnly: true + nullable: true + aaguid: + type: string + readOnly: true + user: + allOf: + - $ref: '#/components/schemas/PartialUser' + readOnly: true + required: + - aaguid + - created_on + - device_type + - name + - pk + - user + WebAuthnDeviceRequest: + type: object + description: Serializer for WebAuthn authenticator devices + properties: + name: + type: string + minLength: 1 + maxLength: 200 + required: + - name + WebAuthnDeviceType: + type: object + description: WebAuthnDeviceType Serializer + properties: + aaguid: + type: string + format: uuid + description: + type: string + required: + - aaguid + - description + WebAuthnHintEnum: + enum: + - security-key + - client-device + - hybrid + type: string + Worker: + type: object + properties: + worker_id: + type: string + version: + type: string + version_matching: + type: boolean + required: + - version + - version_matching + - worker_id + modelRequest: + oneOf: + - $ref: '#/components/schemas/GoogleWorkspaceProviderRequest' + - $ref: '#/components/schemas/LDAPProviderRequest' + - $ref: '#/components/schemas/MicrosoftEntraProviderRequest' + - $ref: '#/components/schemas/OAuth2ProviderRequest' + - $ref: '#/components/schemas/ProxyProviderRequest' + - $ref: '#/components/schemas/RACProviderRequest' + - $ref: '#/components/schemas/RadiusProviderRequest' + - $ref: '#/components/schemas/SAMLProviderRequest' + - $ref: '#/components/schemas/SCIMProviderRequest' + - $ref: '#/components/schemas/SSFProviderRequest' + - $ref: '#/components/schemas/WSFederationProviderRequest' + discriminator: + propertyName: provider_model + mapping: + authentik_providers_google_workspace.googleworkspaceprovider: '#/components/schemas/GoogleWorkspaceProviderRequest' + authentik_providers_ldap.ldapprovider: '#/components/schemas/LDAPProviderRequest' + authentik_providers_microsoft_entra.microsoftentraprovider: '#/components/schemas/MicrosoftEntraProviderRequest' + authentik_providers_oauth2.oauth2provider: '#/components/schemas/OAuth2ProviderRequest' + authentik_providers_proxy.proxyprovider: '#/components/schemas/ProxyProviderRequest' + authentik_providers_rac.racprovider: '#/components/schemas/RACProviderRequest' + authentik_providers_radius.radiusprovider: '#/components/schemas/RadiusProviderRequest' + authentik_providers_saml.samlprovider: '#/components/schemas/SAMLProviderRequest' + authentik_providers_scim.scimprovider: '#/components/schemas/SCIMProviderRequest' + authentik_providers_ssf.ssfprovider: '#/components/schemas/SSFProviderRequest' + authentik_providers_ws_federation.wsfederationprovider: '#/components/schemas/WSFederationProviderRequest' + securitySchemes: + authentik: + type: http + scheme: bearer + authentik_device_auth: + type: http + scheme: bearer+agent + authentik_device_enroll: + type: http + scheme: bearer + authentik_device_federation: + type: http + scheme: bearer +servers: +- url: /api/v3 diff --git a/setup.cfg b/setup.cfg new file mode 100644 index 000000000..11433ee87 --- /dev/null +++ b/setup.cfg @@ -0,0 +1,2 @@ +[flake8] +max-line-length=99 diff --git a/setup.py b/setup.py new file mode 100644 index 000000000..a9e8771c6 --- /dev/null +++ b/setup.py @@ -0,0 +1,49 @@ +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.7 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from setuptools import setup, find_packages # noqa: H301 + +# To install the library, run the following +# +# python setup.py install +# +# prerequisite: setuptools +# http://pypi.python.org/pypi/setuptools +NAME = "authentik-client" +VERSION = "2026.5.7" +PYTHON_REQUIRES = ">= 3.10" +REQUIRES = [ + "urllib3 >= 2.1.0, < 3.0.0", + "python-dateutil >= 2.8.2", + "pydantic >= 2.11", + "typing-extensions >= 4.7.1", +] + +setup( + name=NAME, + version=VERSION, + description="authentik", + author="authentik Team", + author_email="hello@goauthentik.io", + url="", + keywords=["OpenAPI", "OpenAPI-Generator", "authentik"], + install_requires=REQUIRES, + packages=find_packages(exclude=["test", "tests"]), + include_package_data=True, + license="MIT", + long_description_content_type='text/markdown', + long_description="""\ + Making authentication simple. + """, # noqa: E501 + package_data={"authentik_client": ["py.typed"]}, +) diff --git a/test-requirements.txt b/test-requirements.txt new file mode 100644 index 000000000..e98555c11 --- /dev/null +++ b/test-requirements.txt @@ -0,0 +1,6 @@ +pytest >= 7.2.1 +pytest-cov >= 2.8.1 +tox >= 3.9.0 +flake8 >= 4.0.0 +types-python-dateutil >= 2.8.19.14 +mypy >= 1.5 diff --git a/test/__init__.py b/test/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/test/test_access_denied_challenge.py b/test/test_access_denied_challenge.py new file mode 100644 index 000000000..a7b6a959b --- /dev/null +++ b/test/test_access_denied_challenge.py @@ -0,0 +1,70 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.access_denied_challenge import AccessDeniedChallenge + +class TestAccessDeniedChallenge(unittest.TestCase): + """AccessDeniedChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AccessDeniedChallenge: + """Test AccessDeniedChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AccessDeniedChallenge` + """ + model = AccessDeniedChallenge() + if include_optional: + return AccessDeniedChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-access-denied', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + error_message = '' + ) + else: + return AccessDeniedChallenge( + pending_user = '', + pending_user_avatar = '', + ) + """ + + def testAccessDeniedChallenge(self): + """Test AccessDeniedChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_account_lockdown_stage.py b/test/test_account_lockdown_stage.py new file mode 100644 index 000000000..123d82ae5 --- /dev/null +++ b/test/test_account_lockdown_stage.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.account_lockdown_stage import AccountLockdownStage + +class TestAccountLockdownStage(unittest.TestCase): + """AccountLockdownStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AccountLockdownStage: + """Test AccountLockdownStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AccountLockdownStage` + """ + model = AccountLockdownStage() + if include_optional: + return AccountLockdownStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + deactivate_user = True, + set_unusable_password = True, + delete_sessions = True, + revoke_tokens = True, + self_service_completion_flow = '' + ) + else: + return AccountLockdownStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testAccountLockdownStage(self): + """Test AccountLockdownStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_account_lockdown_stage_request.py b/test/test_account_lockdown_stage_request.py new file mode 100644 index 000000000..edcc3822f --- /dev/null +++ b/test/test_account_lockdown_stage_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.account_lockdown_stage_request import AccountLockdownStageRequest + +class TestAccountLockdownStageRequest(unittest.TestCase): + """AccountLockdownStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AccountLockdownStageRequest: + """Test AccountLockdownStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AccountLockdownStageRequest` + """ + model = AccountLockdownStageRequest() + if include_optional: + return AccountLockdownStageRequest( + name = '0', + deactivate_user = True, + set_unusable_password = True, + delete_sessions = True, + revoke_tokens = True, + self_service_completion_flow = '' + ) + else: + return AccountLockdownStageRequest( + name = '0', + ) + """ + + def testAccountLockdownStageRequest(self): + """Test AccountLockdownStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_admin_api.py b/test/test_admin_api.py new file mode 100644 index 000000000..7d7cda0d9 --- /dev/null +++ b/test/test_admin_api.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.admin_api import AdminApi + + +class TestAdminApi(unittest.TestCase): + """AdminApi unit test stubs""" + + def setUp(self) -> None: + self.api = AdminApi() + + def tearDown(self) -> None: + pass + + def test_admin_apps_list(self) -> None: + """Test case for admin_apps_list + + """ + pass + + def test_admin_file_create(self) -> None: + """Test case for admin_file_create + + """ + pass + + def test_admin_file_destroy(self) -> None: + """Test case for admin_file_destroy + + """ + pass + + def test_admin_file_list(self) -> None: + """Test case for admin_file_list + + """ + pass + + def test_admin_file_used_by_list(self) -> None: + """Test case for admin_file_used_by_list + + """ + pass + + def test_admin_models_list(self) -> None: + """Test case for admin_models_list + + """ + pass + + def test_admin_settings_partial_update(self) -> None: + """Test case for admin_settings_partial_update + + """ + pass + + def test_admin_settings_retrieve(self) -> None: + """Test case for admin_settings_retrieve + + """ + pass + + def test_admin_settings_update(self) -> None: + """Test case for admin_settings_update + + """ + pass + + def test_admin_system_create(self) -> None: + """Test case for admin_system_create + + """ + pass + + def test_admin_system_retrieve(self) -> None: + """Test case for admin_system_retrieve + + """ + pass + + def test_admin_version_history_list(self) -> None: + """Test case for admin_version_history_list + + """ + pass + + def test_admin_version_history_retrieve(self) -> None: + """Test case for admin_version_history_retrieve + + """ + pass + + def test_admin_version_retrieve(self) -> None: + """Test case for admin_version_retrieve + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_agent_authentication_response.py b/test/test_agent_authentication_response.py new file mode 100644 index 000000000..33bf14887 --- /dev/null +++ b/test/test_agent_authentication_response.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.agent_authentication_response import AgentAuthenticationResponse + +class TestAgentAuthenticationResponse(unittest.TestCase): + """AgentAuthenticationResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AgentAuthenticationResponse: + """Test AgentAuthenticationResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AgentAuthenticationResponse` + """ + model = AgentAuthenticationResponse() + if include_optional: + return AgentAuthenticationResponse( + url = '' + ) + else: + return AgentAuthenticationResponse( + url = '', + ) + """ + + def testAgentAuthenticationResponse(self): + """Test AgentAuthenticationResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_agent_config.py b/test/test_agent_config.py new file mode 100644 index 000000000..1a1e99e33 --- /dev/null +++ b/test/test_agent_config.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.agent_config import AgentConfig + +class TestAgentConfig(unittest.TestCase): + """AgentConfig unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AgentConfig: + """Test AgentConfig + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AgentConfig` + """ + model = AgentConfig() + if include_optional: + return AgentConfig( + device_id = '', + refresh_interval = 56, + authorization_flow = '', + jwks_auth = { + 'key' : null + }, + jwks_challenge = { + 'key' : null + }, + nss_uid_offset = 56, + nss_gid_offset = 56, + auth_terminate_session_on_expiry = True, + system_config = authentik_client.models.config.Config( + error_reporting = authentik_client.models.error_reporting_config.ErrorReportingConfig( + enabled = True, + sentry_dsn = '', + environment = '', + send_pii = True, + traces_sample_rate = 1.337, ), + capabilities = [ + 'can_save_media' + ], + cache_timeout = 56, + cache_timeout_flows = 56, + cache_timeout_policies = 56, ), + license_status = 'unlicensed' + ) + else: + return AgentConfig( + device_id = '', + refresh_interval = 56, + authorization_flow = '', + jwks_auth = { + 'key' : null + }, + jwks_challenge = { + 'key' : null + }, + nss_uid_offset = 56, + nss_gid_offset = 56, + auth_terminate_session_on_expiry = True, + system_config = authentik_client.models.config.Config( + error_reporting = authentik_client.models.error_reporting_config.ErrorReportingConfig( + enabled = True, + sentry_dsn = '', + environment = '', + send_pii = True, + traces_sample_rate = 1.337, ), + capabilities = [ + 'can_save_media' + ], + cache_timeout = 56, + cache_timeout_flows = 56, + cache_timeout_policies = 56, ), + license_status = 'unlicensed', + ) + """ + + def testAgentConfig(self): + """Test AgentConfig""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_agent_connector.py b/test/test_agent_connector.py new file mode 100644 index 000000000..ebf8b2be2 --- /dev/null +++ b/test/test_agent_connector.py @@ -0,0 +1,76 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.agent_connector import AgentConnector + +class TestAgentConnector(unittest.TestCase): + """AgentConnector unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AgentConnector: + """Test AgentConnector + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AgentConnector` + """ + model = AgentConnector() + if include_optional: + return AgentConnector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + snapshot_expiry = '', + auth_session_duration = '', + auth_terminate_session_on_expiry = True, + refresh_interval = '', + authorization_flow = '', + nss_uid_offset = 0, + nss_gid_offset = 0, + challenge_key = '', + challenge_idle_timeout = '', + challenge_trigger_check_in = True, + jwt_federation_providers = [ + 56 + ] + ) + else: + return AgentConnector( + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testAgentConnector(self): + """Test AgentConnector""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_agent_connector_request.py b/test/test_agent_connector_request.py new file mode 100644 index 000000000..43c319c15 --- /dev/null +++ b/test/test_agent_connector_request.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.agent_connector_request import AgentConnectorRequest + +class TestAgentConnectorRequest(unittest.TestCase): + """AgentConnectorRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AgentConnectorRequest: + """Test AgentConnectorRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AgentConnectorRequest` + """ + model = AgentConnectorRequest() + if include_optional: + return AgentConnectorRequest( + connector_uuid = '', + name = '0', + enabled = True, + snapshot_expiry = '0', + auth_session_duration = '0', + auth_terminate_session_on_expiry = True, + refresh_interval = '0', + authorization_flow = '', + nss_uid_offset = 0, + nss_gid_offset = 0, + challenge_key = '', + challenge_idle_timeout = '0', + challenge_trigger_check_in = True, + jwt_federation_providers = [ + 56 + ] + ) + else: + return AgentConnectorRequest( + name = '0', + ) + """ + + def testAgentConnectorRequest(self): + """Test AgentConnectorRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_agent_psso_device_registration_request.py b/test/test_agent_psso_device_registration_request.py new file mode 100644 index 000000000..95d9fa8c1 --- /dev/null +++ b/test/test_agent_psso_device_registration_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.agent_psso_device_registration_request import AgentPSSODeviceRegistrationRequest + +class TestAgentPSSODeviceRegistrationRequest(unittest.TestCase): + """AgentPSSODeviceRegistrationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AgentPSSODeviceRegistrationRequest: + """Test AgentPSSODeviceRegistrationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AgentPSSODeviceRegistrationRequest` + """ + model = AgentPSSODeviceRegistrationRequest() + if include_optional: + return AgentPSSODeviceRegistrationRequest( + device_signing_key = '0', + device_encryption_key = '0', + sign_key_id = '0', + enc_key_id = '0' + ) + else: + return AgentPSSODeviceRegistrationRequest( + device_signing_key = '0', + device_encryption_key = '0', + sign_key_id = '0', + enc_key_id = '0', + ) + """ + + def testAgentPSSODeviceRegistrationRequest(self): + """Test AgentPSSODeviceRegistrationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_agent_psso_device_registration_response.py b/test/test_agent_psso_device_registration_response.py new file mode 100644 index 000000000..7b694ddc8 --- /dev/null +++ b/test/test_agent_psso_device_registration_response.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.agent_psso_device_registration_response import AgentPSSODeviceRegistrationResponse + +class TestAgentPSSODeviceRegistrationResponse(unittest.TestCase): + """AgentPSSODeviceRegistrationResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AgentPSSODeviceRegistrationResponse: + """Test AgentPSSODeviceRegistrationResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AgentPSSODeviceRegistrationResponse` + """ + model = AgentPSSODeviceRegistrationResponse() + if include_optional: + return AgentPSSODeviceRegistrationResponse( + client_id = '', + issuer = '', + token_endpoint = '', + jwks_endpoint = '', + audience = '', + nonce_endpoint = '' + ) + else: + return AgentPSSODeviceRegistrationResponse( + client_id = '', + issuer = '', + token_endpoint = '', + jwks_endpoint = '', + audience = '', + nonce_endpoint = '', + ) + """ + + def testAgentPSSODeviceRegistrationResponse(self): + """Test AgentPSSODeviceRegistrationResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_agent_psso_user_registration_request.py b/test/test_agent_psso_user_registration_request.py new file mode 100644 index 000000000..0b0dd968e --- /dev/null +++ b/test/test_agent_psso_user_registration_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.agent_psso_user_registration_request import AgentPSSOUserRegistrationRequest + +class TestAgentPSSOUserRegistrationRequest(unittest.TestCase): + """AgentPSSOUserRegistrationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AgentPSSOUserRegistrationRequest: + """Test AgentPSSOUserRegistrationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AgentPSSOUserRegistrationRequest` + """ + model = AgentPSSOUserRegistrationRequest() + if include_optional: + return AgentPSSOUserRegistrationRequest( + user_auth = '0', + user_secure_enclave_key = '0', + enclave_key_id = '0' + ) + else: + return AgentPSSOUserRegistrationRequest( + user_auth = '0', + user_secure_enclave_key = '0', + enclave_key_id = '0', + ) + """ + + def testAgentPSSOUserRegistrationRequest(self): + """Test AgentPSSOUserRegistrationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_agent_token_response.py b/test/test_agent_token_response.py new file mode 100644 index 000000000..aa9d1a20c --- /dev/null +++ b/test/test_agent_token_response.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.agent_token_response import AgentTokenResponse + +class TestAgentTokenResponse(unittest.TestCase): + """AgentTokenResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AgentTokenResponse: + """Test AgentTokenResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AgentTokenResponse` + """ + model = AgentTokenResponse() + if include_optional: + return AgentTokenResponse( + token = '', + expires_in = 56 + ) + else: + return AgentTokenResponse( + token = '', + ) + """ + + def testAgentTokenResponse(self): + """Test AgentTokenResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_alg_enum.py b/test/test_alg_enum.py new file mode 100644 index 000000000..88934ce5f --- /dev/null +++ b/test/test_alg_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.alg_enum import AlgEnum + +class TestAlgEnum(unittest.TestCase): + """AlgEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testAlgEnum(self): + """Test AlgEnum""" + # inst = AlgEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_app.py b/test/test_app.py new file mode 100644 index 000000000..adb3a28a3 --- /dev/null +++ b/test/test_app.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.app import App + +class TestApp(unittest.TestCase): + """App unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> App: + """Test App + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `App` + """ + model = App() + if include_optional: + return App( + name = '', + label = '' + ) + else: + return App( + name = '', + label = '', + ) + """ + + def testApp(self): + """Test App""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_app_enum.py b/test/test_app_enum.py new file mode 100644 index 000000000..fe04b7d23 --- /dev/null +++ b/test/test_app_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.app_enum import AppEnum + +class TestAppEnum(unittest.TestCase): + """AppEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testAppEnum(self): + """Test AppEnum""" + # inst = AppEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_apple_challenge_response_request.py b/test/test_apple_challenge_response_request.py new file mode 100644 index 000000000..7421b698d --- /dev/null +++ b/test/test_apple_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.apple_challenge_response_request import AppleChallengeResponseRequest + +class TestAppleChallengeResponseRequest(unittest.TestCase): + """AppleChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AppleChallengeResponseRequest: + """Test AppleChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AppleChallengeResponseRequest` + """ + model = AppleChallengeResponseRequest() + if include_optional: + return AppleChallengeResponseRequest( + component = 'ak-source-oauth-apple' + ) + else: + return AppleChallengeResponseRequest( + ) + """ + + def testAppleChallengeResponseRequest(self): + """Test AppleChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_apple_independent_secure_enclave.py b/test/test_apple_independent_secure_enclave.py new file mode 100644 index 000000000..30742332b --- /dev/null +++ b/test/test_apple_independent_secure_enclave.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.apple_independent_secure_enclave import AppleIndependentSecureEnclave + +class TestAppleIndependentSecureEnclave(unittest.TestCase): + """AppleIndependentSecureEnclave unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AppleIndependentSecureEnclave: + """Test AppleIndependentSecureEnclave + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AppleIndependentSecureEnclave` + """ + model = AppleIndependentSecureEnclave() + if include_optional: + return AppleIndependentSecureEnclave( + uuid = '', + user = 56, + apple_secure_enclave_key = '', + apple_enclave_key_id = '', + device_type = '' + ) + else: + return AppleIndependentSecureEnclave( + user = 56, + apple_secure_enclave_key = '', + apple_enclave_key_id = '', + device_type = '', + ) + """ + + def testAppleIndependentSecureEnclave(self): + """Test AppleIndependentSecureEnclave""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_apple_independent_secure_enclave_request.py b/test/test_apple_independent_secure_enclave_request.py new file mode 100644 index 000000000..c970ddb1b --- /dev/null +++ b/test/test_apple_independent_secure_enclave_request.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.apple_independent_secure_enclave_request import AppleIndependentSecureEnclaveRequest + +class TestAppleIndependentSecureEnclaveRequest(unittest.TestCase): + """AppleIndependentSecureEnclaveRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AppleIndependentSecureEnclaveRequest: + """Test AppleIndependentSecureEnclaveRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AppleIndependentSecureEnclaveRequest` + """ + model = AppleIndependentSecureEnclaveRequest() + if include_optional: + return AppleIndependentSecureEnclaveRequest( + uuid = '', + user = 56, + apple_secure_enclave_key = '0', + apple_enclave_key_id = '0', + device_type = '0' + ) + else: + return AppleIndependentSecureEnclaveRequest( + user = 56, + apple_secure_enclave_key = '0', + apple_enclave_key_id = '0', + device_type = '0', + ) + """ + + def testAppleIndependentSecureEnclaveRequest(self): + """Test AppleIndependentSecureEnclaveRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_apple_login_challenge.py b/test/test_apple_login_challenge.py new file mode 100644 index 000000000..045050502 --- /dev/null +++ b/test/test_apple_login_challenge.py @@ -0,0 +1,73 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.apple_login_challenge import AppleLoginChallenge + +class TestAppleLoginChallenge(unittest.TestCase): + """AppleLoginChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AppleLoginChallenge: + """Test AppleLoginChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AppleLoginChallenge` + """ + model = AppleLoginChallenge() + if include_optional: + return AppleLoginChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-source-oauth-apple', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + client_id = '', + scope = '', + redirect_uri = '', + state = '' + ) + else: + return AppleLoginChallenge( + client_id = '', + scope = '', + redirect_uri = '', + state = '', + ) + """ + + def testAppleLoginChallenge(self): + """Test AppleLoginChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_application.py b/test/test_application.py new file mode 100644 index 000000000..dcb5fe3df --- /dev/null +++ b/test/test_application.py @@ -0,0 +1,151 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.application import Application + +class TestApplication(unittest.TestCase): + """Application unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Application: + """Test Application + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Application` + """ + model = Application() + if include_optional: + return Application( + pk = '', + name = '', + slug = 'z', + provider = 56, + provider_obj = authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ), + backchannel_providers = [ + 56 + ], + backchannel_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + launch_url = '', + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_icon_url = '', + meta_icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True + ) + else: + return Application( + pk = '', + name = '', + slug = 'z', + provider_obj = authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ), + backchannel_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + launch_url = '', + meta_icon_url = '', + meta_icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + ) + """ + + def testApplication(self): + """Test Application""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_application_entitlement.py b/test/test_application_entitlement.py new file mode 100644 index 000000000..2f8dfb4b6 --- /dev/null +++ b/test/test_application_entitlement.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.application_entitlement import ApplicationEntitlement + +class TestApplicationEntitlement(unittest.TestCase): + """ApplicationEntitlement unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ApplicationEntitlement: + """Test ApplicationEntitlement + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ApplicationEntitlement` + """ + model = ApplicationEntitlement() + if include_optional: + return ApplicationEntitlement( + pbm_uuid = '', + name = '', + app = '', + attributes = { + 'key' : null + } + ) + else: + return ApplicationEntitlement( + pbm_uuid = '', + name = '', + app = '', + ) + """ + + def testApplicationEntitlement(self): + """Test ApplicationEntitlement""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_application_entitlement_request.py b/test/test_application_entitlement_request.py new file mode 100644 index 000000000..d51917944 --- /dev/null +++ b/test/test_application_entitlement_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.application_entitlement_request import ApplicationEntitlementRequest + +class TestApplicationEntitlementRequest(unittest.TestCase): + """ApplicationEntitlementRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ApplicationEntitlementRequest: + """Test ApplicationEntitlementRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ApplicationEntitlementRequest` + """ + model = ApplicationEntitlementRequest() + if include_optional: + return ApplicationEntitlementRequest( + name = '0', + app = '', + attributes = { + 'key' : null + } + ) + else: + return ApplicationEntitlementRequest( + name = '0', + app = '', + ) + """ + + def testApplicationEntitlementRequest(self): + """Test ApplicationEntitlementRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_application_request.py b/test/test_application_request.py new file mode 100644 index 000000000..d1e77812e --- /dev/null +++ b/test/test_application_request.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.application_request import ApplicationRequest + +class TestApplicationRequest(unittest.TestCase): + """ApplicationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ApplicationRequest: + """Test ApplicationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ApplicationRequest` + """ + model = ApplicationRequest() + if include_optional: + return ApplicationRequest( + name = '0', + slug = 'z0', + provider = 56, + backchannel_providers = [ + 56 + ], + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True + ) + else: + return ApplicationRequest( + name = '0', + slug = 'z0', + ) + """ + + def testApplicationRequest(self): + """Test ApplicationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_auth_type_enum.py b/test/test_auth_type_enum.py new file mode 100644 index 000000000..888fc608d --- /dev/null +++ b/test/test_auth_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.auth_type_enum import AuthTypeEnum + +class TestAuthTypeEnum(unittest.TestCase): + """AuthTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testAuthTypeEnum(self): + """Test AuthTypeEnum""" + # inst = AuthTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticated_session.py b/test/test_authenticated_session.py new file mode 100644 index 000000000..71fd5c64e --- /dev/null +++ b/test/test_authenticated_session.py @@ -0,0 +1,118 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticated_session import AuthenticatedSession + +class TestAuthenticatedSession(unittest.TestCase): + """AuthenticatedSession unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatedSession: + """Test AuthenticatedSession + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatedSession` + """ + model = AuthenticatedSession() + if include_optional: + return AuthenticatedSession( + uuid = '', + current = True, + user_agent = authentik_client.models.authenticated_session_user_agent.AuthenticatedSession_user_agent( + device = authentik_client.models.authenticated_session_user_agent_device.AuthenticatedSession_user_agent_device( + brand = '', + family = '', + model = '', ), + os = authentik_client.models.authenticated_session_user_agent_os.AuthenticatedSession_user_agent_os( + family = '', + major = '', + minor = '', + patch = '', + patch_minor = '', ), + user_agent = authentik_client.models.authenticated_session_user_agent_user_agent.AuthenticatedSession_user_agent_user_agent( + family = '', + major = '', + minor = '', + patch = '', ), + string = '', ), + geo_ip = authentik_client.models.authenticated_session_geo_ip.AuthenticatedSession_geo_ip( + continent = '', + country = '', + lat = 1.337, + long = 1.337, + city = '', ), + asn = authentik_client.models.authenticated_session_asn.AuthenticatedSession_asn( + asn = 56, + as_org = '', + network = '', ), + user = 56, + last_ip = '', + last_user_agent = '', + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return AuthenticatedSession( + current = True, + user_agent = authentik_client.models.authenticated_session_user_agent.AuthenticatedSession_user_agent( + device = authentik_client.models.authenticated_session_user_agent_device.AuthenticatedSession_user_agent_device( + brand = '', + family = '', + model = '', ), + os = authentik_client.models.authenticated_session_user_agent_os.AuthenticatedSession_user_agent_os( + family = '', + major = '', + minor = '', + patch = '', + patch_minor = '', ), + user_agent = authentik_client.models.authenticated_session_user_agent_user_agent.AuthenticatedSession_user_agent_user_agent( + family = '', + major = '', + minor = '', + patch = '', ), + string = '', ), + geo_ip = authentik_client.models.authenticated_session_geo_ip.AuthenticatedSession_geo_ip( + continent = '', + country = '', + lat = 1.337, + long = 1.337, + city = '', ), + asn = authentik_client.models.authenticated_session_asn.AuthenticatedSession_asn( + asn = 56, + as_org = '', + network = '', ), + user = 56, + last_ip = '', + last_user_agent = '', + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testAuthenticatedSession(self): + """Test AuthenticatedSession""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticated_session_asn.py b/test/test_authenticated_session_asn.py new file mode 100644 index 000000000..768496984 --- /dev/null +++ b/test/test_authenticated_session_asn.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticated_session_asn import AuthenticatedSessionAsn + +class TestAuthenticatedSessionAsn(unittest.TestCase): + """AuthenticatedSessionAsn unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatedSessionAsn: + """Test AuthenticatedSessionAsn + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatedSessionAsn` + """ + model = AuthenticatedSessionAsn() + if include_optional: + return AuthenticatedSessionAsn( + asn = 56, + as_org = '', + network = '' + ) + else: + return AuthenticatedSessionAsn( + asn = 56, + as_org = '', + network = '', + ) + """ + + def testAuthenticatedSessionAsn(self): + """Test AuthenticatedSessionAsn""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticated_session_geo_ip.py b/test/test_authenticated_session_geo_ip.py new file mode 100644 index 000000000..6f6e8f699 --- /dev/null +++ b/test/test_authenticated_session_geo_ip.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticated_session_geo_ip import AuthenticatedSessionGeoIp + +class TestAuthenticatedSessionGeoIp(unittest.TestCase): + """AuthenticatedSessionGeoIp unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatedSessionGeoIp: + """Test AuthenticatedSessionGeoIp + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatedSessionGeoIp` + """ + model = AuthenticatedSessionGeoIp() + if include_optional: + return AuthenticatedSessionGeoIp( + continent = '', + country = '', + lat = 1.337, + long = 1.337, + city = '' + ) + else: + return AuthenticatedSessionGeoIp( + continent = '', + country = '', + lat = 1.337, + long = 1.337, + city = '', + ) + """ + + def testAuthenticatedSessionGeoIp(self): + """Test AuthenticatedSessionGeoIp""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticated_session_user_agent.py b/test/test_authenticated_session_user_agent.py new file mode 100644 index 000000000..073299151 --- /dev/null +++ b/test/test_authenticated_session_user_agent.py @@ -0,0 +1,83 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticated_session_user_agent import AuthenticatedSessionUserAgent + +class TestAuthenticatedSessionUserAgent(unittest.TestCase): + """AuthenticatedSessionUserAgent unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatedSessionUserAgent: + """Test AuthenticatedSessionUserAgent + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatedSessionUserAgent` + """ + model = AuthenticatedSessionUserAgent() + if include_optional: + return AuthenticatedSessionUserAgent( + device = authentik_client.models.authenticated_session_user_agent_device.AuthenticatedSession_user_agent_device( + brand = '', + family = '', + model = '', ), + os = authentik_client.models.authenticated_session_user_agent_os.AuthenticatedSession_user_agent_os( + family = '', + major = '', + minor = '', + patch = '', + patch_minor = '', ), + user_agent = authentik_client.models.authenticated_session_user_agent_user_agent.AuthenticatedSession_user_agent_user_agent( + family = '', + major = '', + minor = '', + patch = '', ), + string = '' + ) + else: + return AuthenticatedSessionUserAgent( + device = authentik_client.models.authenticated_session_user_agent_device.AuthenticatedSession_user_agent_device( + brand = '', + family = '', + model = '', ), + os = authentik_client.models.authenticated_session_user_agent_os.AuthenticatedSession_user_agent_os( + family = '', + major = '', + minor = '', + patch = '', + patch_minor = '', ), + user_agent = authentik_client.models.authenticated_session_user_agent_user_agent.AuthenticatedSession_user_agent_user_agent( + family = '', + major = '', + minor = '', + patch = '', ), + string = '', + ) + """ + + def testAuthenticatedSessionUserAgent(self): + """Test AuthenticatedSessionUserAgent""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticated_session_user_agent_device.py b/test/test_authenticated_session_user_agent_device.py new file mode 100644 index 000000000..3a3bcfe59 --- /dev/null +++ b/test/test_authenticated_session_user_agent_device.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticated_session_user_agent_device import AuthenticatedSessionUserAgentDevice + +class TestAuthenticatedSessionUserAgentDevice(unittest.TestCase): + """AuthenticatedSessionUserAgentDevice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatedSessionUserAgentDevice: + """Test AuthenticatedSessionUserAgentDevice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatedSessionUserAgentDevice` + """ + model = AuthenticatedSessionUserAgentDevice() + if include_optional: + return AuthenticatedSessionUserAgentDevice( + brand = '', + family = '', + model = '' + ) + else: + return AuthenticatedSessionUserAgentDevice( + brand = '', + family = '', + model = '', + ) + """ + + def testAuthenticatedSessionUserAgentDevice(self): + """Test AuthenticatedSessionUserAgentDevice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticated_session_user_agent_os.py b/test/test_authenticated_session_user_agent_os.py new file mode 100644 index 000000000..e679a351a --- /dev/null +++ b/test/test_authenticated_session_user_agent_os.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticated_session_user_agent_os import AuthenticatedSessionUserAgentOs + +class TestAuthenticatedSessionUserAgentOs(unittest.TestCase): + """AuthenticatedSessionUserAgentOs unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatedSessionUserAgentOs: + """Test AuthenticatedSessionUserAgentOs + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatedSessionUserAgentOs` + """ + model = AuthenticatedSessionUserAgentOs() + if include_optional: + return AuthenticatedSessionUserAgentOs( + family = '', + major = '', + minor = '', + patch = '', + patch_minor = '' + ) + else: + return AuthenticatedSessionUserAgentOs( + family = '', + major = '', + minor = '', + patch = '', + patch_minor = '', + ) + """ + + def testAuthenticatedSessionUserAgentOs(self): + """Test AuthenticatedSessionUserAgentOs""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticated_session_user_agent_user_agent.py b/test/test_authenticated_session_user_agent_user_agent.py new file mode 100644 index 000000000..bb3ec388e --- /dev/null +++ b/test/test_authenticated_session_user_agent_user_agent.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticated_session_user_agent_user_agent import AuthenticatedSessionUserAgentUserAgent + +class TestAuthenticatedSessionUserAgentUserAgent(unittest.TestCase): + """AuthenticatedSessionUserAgentUserAgent unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatedSessionUserAgentUserAgent: + """Test AuthenticatedSessionUserAgentUserAgent + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatedSessionUserAgentUserAgent` + """ + model = AuthenticatedSessionUserAgentUserAgent() + if include_optional: + return AuthenticatedSessionUserAgentUserAgent( + family = '', + major = '', + minor = '', + patch = '' + ) + else: + return AuthenticatedSessionUserAgentUserAgent( + family = '', + major = '', + minor = '', + patch = '', + ) + """ + + def testAuthenticatedSessionUserAgentUserAgent(self): + """Test AuthenticatedSessionUserAgentUserAgent""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authentication_enum.py b/test/test_authentication_enum.py new file mode 100644 index 000000000..6866c9dc2 --- /dev/null +++ b/test/test_authentication_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authentication_enum import AuthenticationEnum + +class TestAuthenticationEnum(unittest.TestCase): + """AuthenticationEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testAuthenticationEnum(self): + """Test AuthenticationEnum""" + # inst = AuthenticationEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_attachment_enum.py b/test/test_authenticator_attachment_enum.py new file mode 100644 index 000000000..de50aa18a --- /dev/null +++ b/test/test_authenticator_attachment_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_attachment_enum import AuthenticatorAttachmentEnum + +class TestAuthenticatorAttachmentEnum(unittest.TestCase): + """AuthenticatorAttachmentEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testAuthenticatorAttachmentEnum(self): + """Test AuthenticatorAttachmentEnum""" + # inst = AuthenticatorAttachmentEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_duo_challenge.py b/test/test_authenticator_duo_challenge.py new file mode 100644 index 000000000..31965a86a --- /dev/null +++ b/test/test_authenticator_duo_challenge.py @@ -0,0 +1,75 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_duo_challenge import AuthenticatorDuoChallenge + +class TestAuthenticatorDuoChallenge(unittest.TestCase): + """AuthenticatorDuoChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorDuoChallenge: + """Test AuthenticatorDuoChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorDuoChallenge` + """ + model = AuthenticatorDuoChallenge() + if include_optional: + return AuthenticatorDuoChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-authenticator-duo', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + activation_barcode = '', + activation_code = '', + stage_uuid = '' + ) + else: + return AuthenticatorDuoChallenge( + pending_user = '', + pending_user_avatar = '', + activation_barcode = '', + activation_code = '', + stage_uuid = '', + ) + """ + + def testAuthenticatorDuoChallenge(self): + """Test AuthenticatorDuoChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_duo_challenge_response_request.py b/test/test_authenticator_duo_challenge_response_request.py new file mode 100644 index 000000000..853cedafa --- /dev/null +++ b/test/test_authenticator_duo_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_duo_challenge_response_request import AuthenticatorDuoChallengeResponseRequest + +class TestAuthenticatorDuoChallengeResponseRequest(unittest.TestCase): + """AuthenticatorDuoChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorDuoChallengeResponseRequest: + """Test AuthenticatorDuoChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorDuoChallengeResponseRequest` + """ + model = AuthenticatorDuoChallengeResponseRequest() + if include_optional: + return AuthenticatorDuoChallengeResponseRequest( + component = 'ak-stage-authenticator-duo' + ) + else: + return AuthenticatorDuoChallengeResponseRequest( + ) + """ + + def testAuthenticatorDuoChallengeResponseRequest(self): + """Test AuthenticatorDuoChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_duo_stage.py b/test/test_authenticator_duo_stage.py new file mode 100644 index 000000000..50f9a4246 --- /dev/null +++ b/test/test_authenticator_duo_stage.py @@ -0,0 +1,100 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_duo_stage import AuthenticatorDuoStage + +class TestAuthenticatorDuoStage(unittest.TestCase): + """AuthenticatorDuoStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorDuoStage: + """Test AuthenticatorDuoStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorDuoStage` + """ + model = AuthenticatorDuoStage() + if include_optional: + return AuthenticatorDuoStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + client_id = '', + api_hostname = '', + admin_integration_key = '' + ) + else: + return AuthenticatorDuoStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + client_id = '', + api_hostname = '', + ) + """ + + def testAuthenticatorDuoStage(self): + """Test AuthenticatorDuoStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_duo_stage_device_import_response.py b/test/test_authenticator_duo_stage_device_import_response.py new file mode 100644 index 000000000..d6ed759b2 --- /dev/null +++ b/test/test_authenticator_duo_stage_device_import_response.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_duo_stage_device_import_response import AuthenticatorDuoStageDeviceImportResponse + +class TestAuthenticatorDuoStageDeviceImportResponse(unittest.TestCase): + """AuthenticatorDuoStageDeviceImportResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorDuoStageDeviceImportResponse: + """Test AuthenticatorDuoStageDeviceImportResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorDuoStageDeviceImportResponse` + """ + model = AuthenticatorDuoStageDeviceImportResponse() + if include_optional: + return AuthenticatorDuoStageDeviceImportResponse( + count = 56, + error = '' + ) + else: + return AuthenticatorDuoStageDeviceImportResponse( + count = 56, + error = '', + ) + """ + + def testAuthenticatorDuoStageDeviceImportResponse(self): + """Test AuthenticatorDuoStageDeviceImportResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_duo_stage_manual_device_import_request.py b/test/test_authenticator_duo_stage_manual_device_import_request.py new file mode 100644 index 000000000..051b08ed3 --- /dev/null +++ b/test/test_authenticator_duo_stage_manual_device_import_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_duo_stage_manual_device_import_request import AuthenticatorDuoStageManualDeviceImportRequest + +class TestAuthenticatorDuoStageManualDeviceImportRequest(unittest.TestCase): + """AuthenticatorDuoStageManualDeviceImportRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorDuoStageManualDeviceImportRequest: + """Test AuthenticatorDuoStageManualDeviceImportRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorDuoStageManualDeviceImportRequest` + """ + model = AuthenticatorDuoStageManualDeviceImportRequest() + if include_optional: + return AuthenticatorDuoStageManualDeviceImportRequest( + duo_user_id = '0', + username = '0' + ) + else: + return AuthenticatorDuoStageManualDeviceImportRequest( + duo_user_id = '0', + username = '0', + ) + """ + + def testAuthenticatorDuoStageManualDeviceImportRequest(self): + """Test AuthenticatorDuoStageManualDeviceImportRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_duo_stage_request.py b/test/test_authenticator_duo_stage_request.py new file mode 100644 index 000000000..5c9f1fc55 --- /dev/null +++ b/test/test_authenticator_duo_stage_request.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_duo_stage_request import AuthenticatorDuoStageRequest + +class TestAuthenticatorDuoStageRequest(unittest.TestCase): + """AuthenticatorDuoStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorDuoStageRequest: + """Test AuthenticatorDuoStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorDuoStageRequest` + """ + model = AuthenticatorDuoStageRequest() + if include_optional: + return AuthenticatorDuoStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + client_id = '0', + client_secret = '0', + api_hostname = '0', + admin_integration_key = '', + admin_secret_key = '' + ) + else: + return AuthenticatorDuoStageRequest( + name = '0', + client_id = '0', + client_secret = '0', + api_hostname = '0', + ) + """ + + def testAuthenticatorDuoStageRequest(self): + """Test AuthenticatorDuoStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_email_challenge.py b/test/test_authenticator_email_challenge.py new file mode 100644 index 000000000..8738b8631 --- /dev/null +++ b/test/test_authenticator_email_challenge.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_email_challenge import AuthenticatorEmailChallenge + +class TestAuthenticatorEmailChallenge(unittest.TestCase): + """AuthenticatorEmailChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorEmailChallenge: + """Test AuthenticatorEmailChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorEmailChallenge` + """ + model = AuthenticatorEmailChallenge() + if include_optional: + return AuthenticatorEmailChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-authenticator-email', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + email = '', + email_required = True + ) + else: + return AuthenticatorEmailChallenge( + pending_user = '', + pending_user_avatar = '', + ) + """ + + def testAuthenticatorEmailChallenge(self): + """Test AuthenticatorEmailChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_email_challenge_response_request.py b/test/test_authenticator_email_challenge_response_request.py new file mode 100644 index 000000000..0a7d64610 --- /dev/null +++ b/test/test_authenticator_email_challenge_response_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_email_challenge_response_request import AuthenticatorEmailChallengeResponseRequest + +class TestAuthenticatorEmailChallengeResponseRequest(unittest.TestCase): + """AuthenticatorEmailChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorEmailChallengeResponseRequest: + """Test AuthenticatorEmailChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorEmailChallengeResponseRequest` + """ + model = AuthenticatorEmailChallengeResponseRequest() + if include_optional: + return AuthenticatorEmailChallengeResponseRequest( + component = 'ak-stage-authenticator-email', + code = '0', + email = '0' + ) + else: + return AuthenticatorEmailChallengeResponseRequest( + ) + """ + + def testAuthenticatorEmailChallengeResponseRequest(self): + """Test AuthenticatorEmailChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_email_stage.py b/test/test_authenticator_email_stage.py new file mode 100644 index 000000000..546fe72f4 --- /dev/null +++ b/test/test_authenticator_email_stage.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_email_stage import AuthenticatorEmailStage + +class TestAuthenticatorEmailStage(unittest.TestCase): + """AuthenticatorEmailStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorEmailStage: + """Test AuthenticatorEmailStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorEmailStage` + """ + model = AuthenticatorEmailStage() + if include_optional: + return AuthenticatorEmailStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + use_global_settings = True, + host = '', + port = -2147483648, + username = '', + password = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '', + subject = '', + token_expiry = '', + template = '' + ) + else: + return AuthenticatorEmailStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testAuthenticatorEmailStage(self): + """Test AuthenticatorEmailStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_email_stage_request.py b/test/test_authenticator_email_stage_request.py new file mode 100644 index 000000000..2630868d2 --- /dev/null +++ b/test/test_authenticator_email_stage_request.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_email_stage_request import AuthenticatorEmailStageRequest + +class TestAuthenticatorEmailStageRequest(unittest.TestCase): + """AuthenticatorEmailStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorEmailStageRequest: + """Test AuthenticatorEmailStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorEmailStageRequest` + """ + model = AuthenticatorEmailStageRequest() + if include_optional: + return AuthenticatorEmailStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + use_global_settings = True, + host = '0', + port = -2147483648, + username = '', + password = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '0', + subject = '0', + token_expiry = '0', + template = '0' + ) + else: + return AuthenticatorEmailStageRequest( + name = '0', + ) + """ + + def testAuthenticatorEmailStageRequest(self): + """Test AuthenticatorEmailStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_endpoint_gdtc_stage.py b/test/test_authenticator_endpoint_gdtc_stage.py new file mode 100644 index 000000000..ff9a9ce10 --- /dev/null +++ b/test/test_authenticator_endpoint_gdtc_stage.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_endpoint_gdtc_stage import AuthenticatorEndpointGDTCStage + +class TestAuthenticatorEndpointGDTCStage(unittest.TestCase): + """AuthenticatorEndpointGDTCStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorEndpointGDTCStage: + """Test AuthenticatorEndpointGDTCStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorEndpointGDTCStage` + """ + model = AuthenticatorEndpointGDTCStage() + if include_optional: + return AuthenticatorEndpointGDTCStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + credentials = { + 'key' : null + } + ) + else: + return AuthenticatorEndpointGDTCStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + credentials = { + 'key' : null + }, + ) + """ + + def testAuthenticatorEndpointGDTCStage(self): + """Test AuthenticatorEndpointGDTCStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_endpoint_gdtc_stage_request.py b/test/test_authenticator_endpoint_gdtc_stage_request.py new file mode 100644 index 000000000..de3d7bb65 --- /dev/null +++ b/test/test_authenticator_endpoint_gdtc_stage_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_endpoint_gdtc_stage_request import AuthenticatorEndpointGDTCStageRequest + +class TestAuthenticatorEndpointGDTCStageRequest(unittest.TestCase): + """AuthenticatorEndpointGDTCStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorEndpointGDTCStageRequest: + """Test AuthenticatorEndpointGDTCStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorEndpointGDTCStageRequest` + """ + model = AuthenticatorEndpointGDTCStageRequest() + if include_optional: + return AuthenticatorEndpointGDTCStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + credentials = { + 'key' : null + } + ) + else: + return AuthenticatorEndpointGDTCStageRequest( + name = '0', + credentials = { + 'key' : null + }, + ) + """ + + def testAuthenticatorEndpointGDTCStageRequest(self): + """Test AuthenticatorEndpointGDTCStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_sms_challenge.py b/test/test_authenticator_sms_challenge.py new file mode 100644 index 000000000..987cdd817 --- /dev/null +++ b/test/test_authenticator_sms_challenge.py @@ -0,0 +1,70 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_sms_challenge import AuthenticatorSMSChallenge + +class TestAuthenticatorSMSChallenge(unittest.TestCase): + """AuthenticatorSMSChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorSMSChallenge: + """Test AuthenticatorSMSChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorSMSChallenge` + """ + model = AuthenticatorSMSChallenge() + if include_optional: + return AuthenticatorSMSChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-authenticator-sms', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + phone_number_required = True + ) + else: + return AuthenticatorSMSChallenge( + pending_user = '', + pending_user_avatar = '', + ) + """ + + def testAuthenticatorSMSChallenge(self): + """Test AuthenticatorSMSChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_sms_challenge_response_request.py b/test/test_authenticator_sms_challenge_response_request.py new file mode 100644 index 000000000..ed2e9204d --- /dev/null +++ b/test/test_authenticator_sms_challenge_response_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_sms_challenge_response_request import AuthenticatorSMSChallengeResponseRequest + +class TestAuthenticatorSMSChallengeResponseRequest(unittest.TestCase): + """AuthenticatorSMSChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorSMSChallengeResponseRequest: + """Test AuthenticatorSMSChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorSMSChallengeResponseRequest` + """ + model = AuthenticatorSMSChallengeResponseRequest() + if include_optional: + return AuthenticatorSMSChallengeResponseRequest( + component = 'ak-stage-authenticator-sms', + code = '0', + phone_number = '0' + ) + else: + return AuthenticatorSMSChallengeResponseRequest( + ) + """ + + def testAuthenticatorSMSChallengeResponseRequest(self): + """Test AuthenticatorSMSChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_sms_stage.py b/test/test_authenticator_sms_stage.py new file mode 100644 index 000000000..b028b5c3c --- /dev/null +++ b/test/test_authenticator_sms_stage.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_sms_stage import AuthenticatorSMSStage + +class TestAuthenticatorSMSStage(unittest.TestCase): + """AuthenticatorSMSStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorSMSStage: + """Test AuthenticatorSMSStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorSMSStage` + """ + model = AuthenticatorSMSStage() + if include_optional: + return AuthenticatorSMSStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + provider = 'twilio', + from_number = '', + account_sid = '', + auth = '', + auth_password = '', + auth_type = 'basic', + verify_only = True, + mapping = '' + ) + else: + return AuthenticatorSMSStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + provider = 'twilio', + from_number = '', + account_sid = '', + auth = '', + ) + """ + + def testAuthenticatorSMSStage(self): + """Test AuthenticatorSMSStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_sms_stage_request.py b/test/test_authenticator_sms_stage_request.py new file mode 100644 index 000000000..ca776cc05 --- /dev/null +++ b/test/test_authenticator_sms_stage_request.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_sms_stage_request import AuthenticatorSMSStageRequest + +class TestAuthenticatorSMSStageRequest(unittest.TestCase): + """AuthenticatorSMSStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorSMSStageRequest: + """Test AuthenticatorSMSStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorSMSStageRequest` + """ + model = AuthenticatorSMSStageRequest() + if include_optional: + return AuthenticatorSMSStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + provider = 'twilio', + from_number = '0', + account_sid = '0', + auth = '0', + auth_password = '', + auth_type = 'basic', + verify_only = True, + mapping = '' + ) + else: + return AuthenticatorSMSStageRequest( + name = '0', + provider = 'twilio', + from_number = '0', + account_sid = '0', + auth = '0', + ) + """ + + def testAuthenticatorSMSStageRequest(self): + """Test AuthenticatorSMSStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_static_challenge.py b/test/test_authenticator_static_challenge.py new file mode 100644 index 000000000..1d933fc2c --- /dev/null +++ b/test/test_authenticator_static_challenge.py @@ -0,0 +1,75 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_static_challenge import AuthenticatorStaticChallenge + +class TestAuthenticatorStaticChallenge(unittest.TestCase): + """AuthenticatorStaticChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorStaticChallenge: + """Test AuthenticatorStaticChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorStaticChallenge` + """ + model = AuthenticatorStaticChallenge() + if include_optional: + return AuthenticatorStaticChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-authenticator-static', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + codes = [ + '' + ] + ) + else: + return AuthenticatorStaticChallenge( + pending_user = '', + pending_user_avatar = '', + codes = [ + '' + ], + ) + """ + + def testAuthenticatorStaticChallenge(self): + """Test AuthenticatorStaticChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_static_challenge_response_request.py b/test/test_authenticator_static_challenge_response_request.py new file mode 100644 index 000000000..7925eb741 --- /dev/null +++ b/test/test_authenticator_static_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_static_challenge_response_request import AuthenticatorStaticChallengeResponseRequest + +class TestAuthenticatorStaticChallengeResponseRequest(unittest.TestCase): + """AuthenticatorStaticChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorStaticChallengeResponseRequest: + """Test AuthenticatorStaticChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorStaticChallengeResponseRequest` + """ + model = AuthenticatorStaticChallengeResponseRequest() + if include_optional: + return AuthenticatorStaticChallengeResponseRequest( + component = 'ak-stage-authenticator-static' + ) + else: + return AuthenticatorStaticChallengeResponseRequest( + ) + """ + + def testAuthenticatorStaticChallengeResponseRequest(self): + """Test AuthenticatorStaticChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_static_stage.py b/test/test_authenticator_static_stage.py new file mode 100644 index 000000000..a5b2fb332 --- /dev/null +++ b/test/test_authenticator_static_stage.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_static_stage import AuthenticatorStaticStage + +class TestAuthenticatorStaticStage(unittest.TestCase): + """AuthenticatorStaticStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorStaticStage: + """Test AuthenticatorStaticStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorStaticStage` + """ + model = AuthenticatorStaticStage() + if include_optional: + return AuthenticatorStaticStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + token_count = 0, + token_length = 0 + ) + else: + return AuthenticatorStaticStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testAuthenticatorStaticStage(self): + """Test AuthenticatorStaticStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_static_stage_request.py b/test/test_authenticator_static_stage_request.py new file mode 100644 index 000000000..8efd28bf1 --- /dev/null +++ b/test/test_authenticator_static_stage_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_static_stage_request import AuthenticatorStaticStageRequest + +class TestAuthenticatorStaticStageRequest(unittest.TestCase): + """AuthenticatorStaticStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorStaticStageRequest: + """Test AuthenticatorStaticStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorStaticStageRequest` + """ + model = AuthenticatorStaticStageRequest() + if include_optional: + return AuthenticatorStaticStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + token_count = 0, + token_length = 0 + ) + else: + return AuthenticatorStaticStageRequest( + name = '0', + ) + """ + + def testAuthenticatorStaticStageRequest(self): + """Test AuthenticatorStaticStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_totp_challenge.py b/test/test_authenticator_totp_challenge.py new file mode 100644 index 000000000..28e38853f --- /dev/null +++ b/test/test_authenticator_totp_challenge.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_totp_challenge import AuthenticatorTOTPChallenge + +class TestAuthenticatorTOTPChallenge(unittest.TestCase): + """AuthenticatorTOTPChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorTOTPChallenge: + """Test AuthenticatorTOTPChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorTOTPChallenge` + """ + model = AuthenticatorTOTPChallenge() + if include_optional: + return AuthenticatorTOTPChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-authenticator-totp', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + config_url = '' + ) + else: + return AuthenticatorTOTPChallenge( + pending_user = '', + pending_user_avatar = '', + config_url = '', + ) + """ + + def testAuthenticatorTOTPChallenge(self): + """Test AuthenticatorTOTPChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_totp_challenge_response_request.py b/test/test_authenticator_totp_challenge_response_request.py new file mode 100644 index 000000000..4ebfb1e80 --- /dev/null +++ b/test/test_authenticator_totp_challenge_response_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_totp_challenge_response_request import AuthenticatorTOTPChallengeResponseRequest + +class TestAuthenticatorTOTPChallengeResponseRequest(unittest.TestCase): + """AuthenticatorTOTPChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorTOTPChallengeResponseRequest: + """Test AuthenticatorTOTPChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorTOTPChallengeResponseRequest` + """ + model = AuthenticatorTOTPChallengeResponseRequest() + if include_optional: + return AuthenticatorTOTPChallengeResponseRequest( + component = 'ak-stage-authenticator-totp', + code = '0' + ) + else: + return AuthenticatorTOTPChallengeResponseRequest( + code = '0', + ) + """ + + def testAuthenticatorTOTPChallengeResponseRequest(self): + """Test AuthenticatorTOTPChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_totp_stage.py b/test/test_authenticator_totp_stage.py new file mode 100644 index 000000000..1e135dbdb --- /dev/null +++ b/test/test_authenticator_totp_stage.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_totp_stage import AuthenticatorTOTPStage + +class TestAuthenticatorTOTPStage(unittest.TestCase): + """AuthenticatorTOTPStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorTOTPStage: + """Test AuthenticatorTOTPStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorTOTPStage` + """ + model = AuthenticatorTOTPStage() + if include_optional: + return AuthenticatorTOTPStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + digits = '6' + ) + else: + return AuthenticatorTOTPStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + digits = '6', + ) + """ + + def testAuthenticatorTOTPStage(self): + """Test AuthenticatorTOTPStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_totp_stage_request.py b/test/test_authenticator_totp_stage_request.py new file mode 100644 index 000000000..d78a6cbe3 --- /dev/null +++ b/test/test_authenticator_totp_stage_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_totp_stage_request import AuthenticatorTOTPStageRequest + +class TestAuthenticatorTOTPStageRequest(unittest.TestCase): + """AuthenticatorTOTPStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorTOTPStageRequest: + """Test AuthenticatorTOTPStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorTOTPStageRequest` + """ + model = AuthenticatorTOTPStageRequest() + if include_optional: + return AuthenticatorTOTPStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + digits = '6' + ) + else: + return AuthenticatorTOTPStageRequest( + name = '0', + digits = '6', + ) + """ + + def testAuthenticatorTOTPStageRequest(self): + """Test AuthenticatorTOTPStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_validate_stage.py b/test/test_authenticator_validate_stage.py new file mode 100644 index 000000000..8831a1dfd --- /dev/null +++ b/test/test_authenticator_validate_stage.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_validate_stage import AuthenticatorValidateStage + +class TestAuthenticatorValidateStage(unittest.TestCase): + """AuthenticatorValidateStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorValidateStage: + """Test AuthenticatorValidateStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorValidateStage` + """ + model = AuthenticatorValidateStage() + if include_optional: + return AuthenticatorValidateStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + not_configured_action = 'skip', + device_classes = [ + 'static' + ], + configuration_stages = [ + '' + ], + last_auth_threshold = '', + webauthn_user_verification = 'required', + webauthn_hints = [ + 'security-key' + ], + webauthn_allowed_device_types = [ + '' + ], + webauthn_allowed_device_types_obj = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + email_otp_throttling_factor = 1.337, + sms_otp_throttling_factor = 1.337, + totp_otp_throttling_factor = 1.337, + static_otp_throttling_factor = 1.337 + ) + else: + return AuthenticatorValidateStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + webauthn_allowed_device_types_obj = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + ) + """ + + def testAuthenticatorValidateStage(self): + """Test AuthenticatorValidateStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_validate_stage_request.py b/test/test_authenticator_validate_stage_request.py new file mode 100644 index 000000000..c94df65c6 --- /dev/null +++ b/test/test_authenticator_validate_stage_request.py @@ -0,0 +1,72 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_validate_stage_request import AuthenticatorValidateStageRequest + +class TestAuthenticatorValidateStageRequest(unittest.TestCase): + """AuthenticatorValidateStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorValidateStageRequest: + """Test AuthenticatorValidateStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorValidateStageRequest` + """ + model = AuthenticatorValidateStageRequest() + if include_optional: + return AuthenticatorValidateStageRequest( + name = '0', + not_configured_action = 'skip', + device_classes = [ + 'static' + ], + configuration_stages = [ + '' + ], + last_auth_threshold = '0', + webauthn_user_verification = 'required', + webauthn_hints = [ + 'security-key' + ], + webauthn_allowed_device_types = [ + '' + ], + email_otp_throttling_factor = 1.337, + sms_otp_throttling_factor = 1.337, + totp_otp_throttling_factor = 1.337, + static_otp_throttling_factor = 1.337 + ) + else: + return AuthenticatorValidateStageRequest( + name = '0', + ) + """ + + def testAuthenticatorValidateStageRequest(self): + """Test AuthenticatorValidateStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_validation_challenge.py b/test/test_authenticator_validation_challenge.py new file mode 100644 index 000000000..372a01e18 --- /dev/null +++ b/test/test_authenticator_validation_challenge.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_validation_challenge import AuthenticatorValidationChallenge + +class TestAuthenticatorValidationChallenge(unittest.TestCase): + """AuthenticatorValidationChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorValidationChallenge: + """Test AuthenticatorValidationChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorValidationChallenge` + """ + model = AuthenticatorValidationChallenge() + if include_optional: + return AuthenticatorValidationChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-authenticator-validate', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + device_challenges = [ + authentik_client.models.device_challenge.DeviceChallenge( + device_class = 'static', + device_uid = '', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + configuration_stages = [ + authentik_client.models.selectable_stage.SelectableStage( + pk = '', + name = '', + verbose_name = '', + meta_model_name = '', ) + ] + ) + else: + return AuthenticatorValidationChallenge( + pending_user = '', + pending_user_avatar = '', + device_challenges = [ + authentik_client.models.device_challenge.DeviceChallenge( + device_class = 'static', + device_uid = '', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + configuration_stages = [ + authentik_client.models.selectable_stage.SelectableStage( + pk = '', + name = '', + verbose_name = '', + meta_model_name = '', ) + ], + ) + """ + + def testAuthenticatorValidationChallenge(self): + """Test AuthenticatorValidationChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_validation_challenge_response_request.py b/test/test_authenticator_validation_challenge_response_request.py new file mode 100644 index 000000000..698df816b --- /dev/null +++ b/test/test_authenticator_validation_challenge_response_request.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_validation_challenge_response_request import AuthenticatorValidationChallengeResponseRequest + +class TestAuthenticatorValidationChallengeResponseRequest(unittest.TestCase): + """AuthenticatorValidationChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorValidationChallengeResponseRequest: + """Test AuthenticatorValidationChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorValidationChallengeResponseRequest` + """ + model = AuthenticatorValidationChallengeResponseRequest() + if include_optional: + return AuthenticatorValidationChallengeResponseRequest( + component = 'ak-stage-authenticator-validate', + selected_challenge = authentik_client.models.device_challenge_request.DeviceChallengeRequest( + device_class = 'static', + device_uid = '0', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + selected_stage = '0', + code = '0', + webauthn = { + 'key' : null + }, + duo = 56 + ) + else: + return AuthenticatorValidationChallengeResponseRequest( + ) + """ + + def testAuthenticatorValidationChallengeResponseRequest(self): + """Test AuthenticatorValidationChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_web_authn_challenge.py b/test/test_authenticator_web_authn_challenge.py new file mode 100644 index 000000000..e987ae7f3 --- /dev/null +++ b/test/test_authenticator_web_authn_challenge.py @@ -0,0 +1,75 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_web_authn_challenge import AuthenticatorWebAuthnChallenge + +class TestAuthenticatorWebAuthnChallenge(unittest.TestCase): + """AuthenticatorWebAuthnChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorWebAuthnChallenge: + """Test AuthenticatorWebAuthnChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorWebAuthnChallenge` + """ + model = AuthenticatorWebAuthnChallenge() + if include_optional: + return AuthenticatorWebAuthnChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-authenticator-webauthn', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + registration = { + 'key' : null + } + ) + else: + return AuthenticatorWebAuthnChallenge( + pending_user = '', + pending_user_avatar = '', + registration = { + 'key' : null + }, + ) + """ + + def testAuthenticatorWebAuthnChallenge(self): + """Test AuthenticatorWebAuthnChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_web_authn_challenge_response_request.py b/test/test_authenticator_web_authn_challenge_response_request.py new file mode 100644 index 000000000..453f98fbd --- /dev/null +++ b/test/test_authenticator_web_authn_challenge_response_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_web_authn_challenge_response_request import AuthenticatorWebAuthnChallengeResponseRequest + +class TestAuthenticatorWebAuthnChallengeResponseRequest(unittest.TestCase): + """AuthenticatorWebAuthnChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorWebAuthnChallengeResponseRequest: + """Test AuthenticatorWebAuthnChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorWebAuthnChallengeResponseRequest` + """ + model = AuthenticatorWebAuthnChallengeResponseRequest() + if include_optional: + return AuthenticatorWebAuthnChallengeResponseRequest( + component = 'ak-stage-authenticator-webauthn', + response = { + 'key' : null + } + ) + else: + return AuthenticatorWebAuthnChallengeResponseRequest( + response = { + 'key' : null + }, + ) + """ + + def testAuthenticatorWebAuthnChallengeResponseRequest(self): + """Test AuthenticatorWebAuthnChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_web_authn_stage.py b/test/test_authenticator_web_authn_stage.py new file mode 100644 index 000000000..c878b93c7 --- /dev/null +++ b/test/test_authenticator_web_authn_stage.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_web_authn_stage import AuthenticatorWebAuthnStage + +class TestAuthenticatorWebAuthnStage(unittest.TestCase): + """AuthenticatorWebAuthnStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorWebAuthnStage: + """Test AuthenticatorWebAuthnStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorWebAuthnStage` + """ + model = AuthenticatorWebAuthnStage() + if include_optional: + return AuthenticatorWebAuthnStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + user_verification = 'required', + authenticator_attachment = 'platform', + resident_key_requirement = 'required', + hints = [ + 'security-key' + ], + device_type_restrictions = [ + '' + ], + device_type_restrictions_obj = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + prevent_duplicate_devices = True, + max_attempts = 0 + ) + else: + return AuthenticatorWebAuthnStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + device_type_restrictions_obj = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + ) + """ + + def testAuthenticatorWebAuthnStage(self): + """Test AuthenticatorWebAuthnStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticator_web_authn_stage_request.py b/test/test_authenticator_web_authn_stage_request.py new file mode 100644 index 000000000..9b501951b --- /dev/null +++ b/test/test_authenticator_web_authn_stage_request.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authenticator_web_authn_stage_request import AuthenticatorWebAuthnStageRequest + +class TestAuthenticatorWebAuthnStageRequest(unittest.TestCase): + """AuthenticatorWebAuthnStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AuthenticatorWebAuthnStageRequest: + """Test AuthenticatorWebAuthnStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AuthenticatorWebAuthnStageRequest` + """ + model = AuthenticatorWebAuthnStageRequest() + if include_optional: + return AuthenticatorWebAuthnStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + user_verification = 'required', + authenticator_attachment = 'platform', + resident_key_requirement = 'required', + hints = [ + 'security-key' + ], + device_type_restrictions = [ + '' + ], + prevent_duplicate_devices = True, + max_attempts = 0 + ) + else: + return AuthenticatorWebAuthnStageRequest( + name = '0', + ) + """ + + def testAuthenticatorWebAuthnStageRequest(self): + """Test AuthenticatorWebAuthnStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authenticators_api.py b/test/test_authenticators_api.py new file mode 100644 index 000000000..ae4359dd8 --- /dev/null +++ b/test/test_authenticators_api.py @@ -0,0 +1,530 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.authenticators_api import AuthenticatorsApi + + +class TestAuthenticatorsApi(unittest.TestCase): + """AuthenticatorsApi unit test stubs""" + + def setUp(self) -> None: + self.api = AuthenticatorsApi() + + def tearDown(self) -> None: + pass + + def test_authenticators_admin_all_list(self) -> None: + """Test case for authenticators_admin_all_list + + """ + pass + + def test_authenticators_admin_duo_create(self) -> None: + """Test case for authenticators_admin_duo_create + + """ + pass + + def test_authenticators_admin_duo_destroy(self) -> None: + """Test case for authenticators_admin_duo_destroy + + """ + pass + + def test_authenticators_admin_duo_list(self) -> None: + """Test case for authenticators_admin_duo_list + + """ + pass + + def test_authenticators_admin_duo_partial_update(self) -> None: + """Test case for authenticators_admin_duo_partial_update + + """ + pass + + def test_authenticators_admin_duo_retrieve(self) -> None: + """Test case for authenticators_admin_duo_retrieve + + """ + pass + + def test_authenticators_admin_duo_update(self) -> None: + """Test case for authenticators_admin_duo_update + + """ + pass + + def test_authenticators_admin_email_create(self) -> None: + """Test case for authenticators_admin_email_create + + """ + pass + + def test_authenticators_admin_email_destroy(self) -> None: + """Test case for authenticators_admin_email_destroy + + """ + pass + + def test_authenticators_admin_email_list(self) -> None: + """Test case for authenticators_admin_email_list + + """ + pass + + def test_authenticators_admin_email_partial_update(self) -> None: + """Test case for authenticators_admin_email_partial_update + + """ + pass + + def test_authenticators_admin_email_retrieve(self) -> None: + """Test case for authenticators_admin_email_retrieve + + """ + pass + + def test_authenticators_admin_email_update(self) -> None: + """Test case for authenticators_admin_email_update + + """ + pass + + def test_authenticators_admin_endpoint_create(self) -> None: + """Test case for authenticators_admin_endpoint_create + + """ + pass + + def test_authenticators_admin_endpoint_destroy(self) -> None: + """Test case for authenticators_admin_endpoint_destroy + + """ + pass + + def test_authenticators_admin_endpoint_list(self) -> None: + """Test case for authenticators_admin_endpoint_list + + """ + pass + + def test_authenticators_admin_endpoint_partial_update(self) -> None: + """Test case for authenticators_admin_endpoint_partial_update + + """ + pass + + def test_authenticators_admin_endpoint_retrieve(self) -> None: + """Test case for authenticators_admin_endpoint_retrieve + + """ + pass + + def test_authenticators_admin_endpoint_update(self) -> None: + """Test case for authenticators_admin_endpoint_update + + """ + pass + + def test_authenticators_admin_sms_create(self) -> None: + """Test case for authenticators_admin_sms_create + + """ + pass + + def test_authenticators_admin_sms_destroy(self) -> None: + """Test case for authenticators_admin_sms_destroy + + """ + pass + + def test_authenticators_admin_sms_list(self) -> None: + """Test case for authenticators_admin_sms_list + + """ + pass + + def test_authenticators_admin_sms_partial_update(self) -> None: + """Test case for authenticators_admin_sms_partial_update + + """ + pass + + def test_authenticators_admin_sms_retrieve(self) -> None: + """Test case for authenticators_admin_sms_retrieve + + """ + pass + + def test_authenticators_admin_sms_update(self) -> None: + """Test case for authenticators_admin_sms_update + + """ + pass + + def test_authenticators_admin_static_create(self) -> None: + """Test case for authenticators_admin_static_create + + """ + pass + + def test_authenticators_admin_static_destroy(self) -> None: + """Test case for authenticators_admin_static_destroy + + """ + pass + + def test_authenticators_admin_static_list(self) -> None: + """Test case for authenticators_admin_static_list + + """ + pass + + def test_authenticators_admin_static_partial_update(self) -> None: + """Test case for authenticators_admin_static_partial_update + + """ + pass + + def test_authenticators_admin_static_retrieve(self) -> None: + """Test case for authenticators_admin_static_retrieve + + """ + pass + + def test_authenticators_admin_static_update(self) -> None: + """Test case for authenticators_admin_static_update + + """ + pass + + def test_authenticators_admin_totp_create(self) -> None: + """Test case for authenticators_admin_totp_create + + """ + pass + + def test_authenticators_admin_totp_destroy(self) -> None: + """Test case for authenticators_admin_totp_destroy + + """ + pass + + def test_authenticators_admin_totp_list(self) -> None: + """Test case for authenticators_admin_totp_list + + """ + pass + + def test_authenticators_admin_totp_partial_update(self) -> None: + """Test case for authenticators_admin_totp_partial_update + + """ + pass + + def test_authenticators_admin_totp_retrieve(self) -> None: + """Test case for authenticators_admin_totp_retrieve + + """ + pass + + def test_authenticators_admin_totp_update(self) -> None: + """Test case for authenticators_admin_totp_update + + """ + pass + + def test_authenticators_admin_webauthn_create(self) -> None: + """Test case for authenticators_admin_webauthn_create + + """ + pass + + def test_authenticators_admin_webauthn_destroy(self) -> None: + """Test case for authenticators_admin_webauthn_destroy + + """ + pass + + def test_authenticators_admin_webauthn_list(self) -> None: + """Test case for authenticators_admin_webauthn_list + + """ + pass + + def test_authenticators_admin_webauthn_partial_update(self) -> None: + """Test case for authenticators_admin_webauthn_partial_update + + """ + pass + + def test_authenticators_admin_webauthn_retrieve(self) -> None: + """Test case for authenticators_admin_webauthn_retrieve + + """ + pass + + def test_authenticators_admin_webauthn_update(self) -> None: + """Test case for authenticators_admin_webauthn_update + + """ + pass + + def test_authenticators_all_list(self) -> None: + """Test case for authenticators_all_list + + """ + pass + + def test_authenticators_duo_destroy(self) -> None: + """Test case for authenticators_duo_destroy + + """ + pass + + def test_authenticators_duo_list(self) -> None: + """Test case for authenticators_duo_list + + """ + pass + + def test_authenticators_duo_partial_update(self) -> None: + """Test case for authenticators_duo_partial_update + + """ + pass + + def test_authenticators_duo_retrieve(self) -> None: + """Test case for authenticators_duo_retrieve + + """ + pass + + def test_authenticators_duo_update(self) -> None: + """Test case for authenticators_duo_update + + """ + pass + + def test_authenticators_duo_used_by_list(self) -> None: + """Test case for authenticators_duo_used_by_list + + """ + pass + + def test_authenticators_email_destroy(self) -> None: + """Test case for authenticators_email_destroy + + """ + pass + + def test_authenticators_email_list(self) -> None: + """Test case for authenticators_email_list + + """ + pass + + def test_authenticators_email_partial_update(self) -> None: + """Test case for authenticators_email_partial_update + + """ + pass + + def test_authenticators_email_retrieve(self) -> None: + """Test case for authenticators_email_retrieve + + """ + pass + + def test_authenticators_email_update(self) -> None: + """Test case for authenticators_email_update + + """ + pass + + def test_authenticators_email_used_by_list(self) -> None: + """Test case for authenticators_email_used_by_list + + """ + pass + + def test_authenticators_endpoint_list(self) -> None: + """Test case for authenticators_endpoint_list + + """ + pass + + def test_authenticators_endpoint_retrieve(self) -> None: + """Test case for authenticators_endpoint_retrieve + + """ + pass + + def test_authenticators_endpoint_used_by_list(self) -> None: + """Test case for authenticators_endpoint_used_by_list + + """ + pass + + def test_authenticators_sms_destroy(self) -> None: + """Test case for authenticators_sms_destroy + + """ + pass + + def test_authenticators_sms_list(self) -> None: + """Test case for authenticators_sms_list + + """ + pass + + def test_authenticators_sms_partial_update(self) -> None: + """Test case for authenticators_sms_partial_update + + """ + pass + + def test_authenticators_sms_retrieve(self) -> None: + """Test case for authenticators_sms_retrieve + + """ + pass + + def test_authenticators_sms_update(self) -> None: + """Test case for authenticators_sms_update + + """ + pass + + def test_authenticators_sms_used_by_list(self) -> None: + """Test case for authenticators_sms_used_by_list + + """ + pass + + def test_authenticators_static_destroy(self) -> None: + """Test case for authenticators_static_destroy + + """ + pass + + def test_authenticators_static_list(self) -> None: + """Test case for authenticators_static_list + + """ + pass + + def test_authenticators_static_partial_update(self) -> None: + """Test case for authenticators_static_partial_update + + """ + pass + + def test_authenticators_static_retrieve(self) -> None: + """Test case for authenticators_static_retrieve + + """ + pass + + def test_authenticators_static_update(self) -> None: + """Test case for authenticators_static_update + + """ + pass + + def test_authenticators_static_used_by_list(self) -> None: + """Test case for authenticators_static_used_by_list + + """ + pass + + def test_authenticators_totp_destroy(self) -> None: + """Test case for authenticators_totp_destroy + + """ + pass + + def test_authenticators_totp_list(self) -> None: + """Test case for authenticators_totp_list + + """ + pass + + def test_authenticators_totp_partial_update(self) -> None: + """Test case for authenticators_totp_partial_update + + """ + pass + + def test_authenticators_totp_retrieve(self) -> None: + """Test case for authenticators_totp_retrieve + + """ + pass + + def test_authenticators_totp_update(self) -> None: + """Test case for authenticators_totp_update + + """ + pass + + def test_authenticators_totp_used_by_list(self) -> None: + """Test case for authenticators_totp_used_by_list + + """ + pass + + def test_authenticators_webauthn_destroy(self) -> None: + """Test case for authenticators_webauthn_destroy + + """ + pass + + def test_authenticators_webauthn_list(self) -> None: + """Test case for authenticators_webauthn_list + + """ + pass + + def test_authenticators_webauthn_partial_update(self) -> None: + """Test case for authenticators_webauthn_partial_update + + """ + pass + + def test_authenticators_webauthn_retrieve(self) -> None: + """Test case for authenticators_webauthn_retrieve + + """ + pass + + def test_authenticators_webauthn_update(self) -> None: + """Test case for authenticators_webauthn_update + + """ + pass + + def test_authenticators_webauthn_used_by_list(self) -> None: + """Test case for authenticators_webauthn_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_authorization_code_auth_method_enum.py b/test/test_authorization_code_auth_method_enum.py new file mode 100644 index 000000000..6822581db --- /dev/null +++ b/test/test_authorization_code_auth_method_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.authorization_code_auth_method_enum import AuthorizationCodeAuthMethodEnum + +class TestAuthorizationCodeAuthMethodEnum(unittest.TestCase): + """AuthorizationCodeAuthMethodEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testAuthorizationCodeAuthMethodEnum(self): + """Test AuthorizationCodeAuthMethodEnum""" + # inst = AuthorizationCodeAuthMethodEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_auto_submit_challenge_response_request.py b/test/test_auto_submit_challenge_response_request.py new file mode 100644 index 000000000..bed125afe --- /dev/null +++ b/test/test_auto_submit_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.auto_submit_challenge_response_request import AutoSubmitChallengeResponseRequest + +class TestAutoSubmitChallengeResponseRequest(unittest.TestCase): + """AutoSubmitChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AutoSubmitChallengeResponseRequest: + """Test AutoSubmitChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AutoSubmitChallengeResponseRequest` + """ + model = AutoSubmitChallengeResponseRequest() + if include_optional: + return AutoSubmitChallengeResponseRequest( + component = 'ak-stage-autosubmit' + ) + else: + return AutoSubmitChallengeResponseRequest( + ) + """ + + def testAutoSubmitChallengeResponseRequest(self): + """Test AutoSubmitChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_autosubmit_challenge.py b/test/test_autosubmit_challenge.py new file mode 100644 index 000000000..32e343c46 --- /dev/null +++ b/test/test_autosubmit_challenge.py @@ -0,0 +1,74 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.autosubmit_challenge import AutosubmitChallenge + +class TestAutosubmitChallenge(unittest.TestCase): + """AutosubmitChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> AutosubmitChallenge: + """Test AutosubmitChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `AutosubmitChallenge` + """ + model = AutosubmitChallenge() + if include_optional: + return AutosubmitChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-autosubmit', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + url = '', + attrs = { + 'key' : '' + }, + title = '' + ) + else: + return AutosubmitChallenge( + url = '', + attrs = { + 'key' : '' + }, + ) + """ + + def testAutosubmitChallenge(self): + """Test AutosubmitChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_backends_enum.py b/test/test_backends_enum.py new file mode 100644 index 000000000..cff90df36 --- /dev/null +++ b/test/test_backends_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.backends_enum import BackendsEnum + +class TestBackendsEnum(unittest.TestCase): + """BackendsEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testBackendsEnum(self): + """Test BackendsEnum""" + # inst = BackendsEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_binding_type_enum.py b/test/test_binding_type_enum.py new file mode 100644 index 000000000..abf01b01e --- /dev/null +++ b/test/test_binding_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.binding_type_enum import BindingTypeEnum + +class TestBindingTypeEnum(unittest.TestCase): + """BindingTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testBindingTypeEnum(self): + """Test BindingTypeEnum""" + # inst = BindingTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_blueprint_file.py b/test/test_blueprint_file.py new file mode 100644 index 000000000..081283b39 --- /dev/null +++ b/test/test_blueprint_file.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.blueprint_file import BlueprintFile + +class TestBlueprintFile(unittest.TestCase): + """BlueprintFile unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> BlueprintFile: + """Test BlueprintFile + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `BlueprintFile` + """ + model = BlueprintFile() + if include_optional: + return BlueprintFile( + path = '', + last_m = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + hash = '', + meta = authentik_client.models.metadata.Metadata( + name = '', + labels = { + 'key' : null + }, ) + ) + else: + return BlueprintFile( + path = '', + last_m = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + hash = '', + meta = authentik_client.models.metadata.Metadata( + name = '', + labels = { + 'key' : null + }, ), + ) + """ + + def testBlueprintFile(self): + """Test BlueprintFile""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_blueprint_import_result.py b/test/test_blueprint_import_result.py new file mode 100644 index 000000000..a62e91462 --- /dev/null +++ b/test/test_blueprint_import_result.py @@ -0,0 +1,73 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.blueprint_import_result import BlueprintImportResult + +class TestBlueprintImportResult(unittest.TestCase): + """BlueprintImportResult unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> BlueprintImportResult: + """Test BlueprintImportResult + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `BlueprintImportResult` + """ + model = BlueprintImportResult() + if include_optional: + return BlueprintImportResult( + logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + success = True + ) + else: + return BlueprintImportResult( + logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + success = True, + ) + """ + + def testBlueprintImportResult(self): + """Test BlueprintImportResult""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_blueprint_instance.py b/test/test_blueprint_instance.py new file mode 100644 index 000000000..2177810ee --- /dev/null +++ b/test/test_blueprint_instance.py @@ -0,0 +1,79 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.blueprint_instance import BlueprintInstance + +class TestBlueprintInstance(unittest.TestCase): + """BlueprintInstance unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> BlueprintInstance: + """Test BlueprintInstance + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `BlueprintInstance` + """ + model = BlueprintInstance() + if include_optional: + return BlueprintInstance( + pk = '', + name = '', + path = '', + context = { + 'key' : null + }, + last_applied = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_applied_hash = '', + status = 'successful', + enabled = True, + managed_models = [ + '' + ], + metadata = { + 'key' : null + }, + content = '' + ) + else: + return BlueprintInstance( + pk = '', + name = '', + last_applied = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_applied_hash = '', + status = 'successful', + managed_models = [ + '' + ], + metadata = { + 'key' : null + }, + ) + """ + + def testBlueprintInstance(self): + """Test BlueprintInstance""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_blueprint_instance_request.py b/test/test_blueprint_instance_request.py new file mode 100644 index 000000000..32a3dba54 --- /dev/null +++ b/test/test_blueprint_instance_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.blueprint_instance_request import BlueprintInstanceRequest + +class TestBlueprintInstanceRequest(unittest.TestCase): + """BlueprintInstanceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> BlueprintInstanceRequest: + """Test BlueprintInstanceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `BlueprintInstanceRequest` + """ + model = BlueprintInstanceRequest() + if include_optional: + return BlueprintInstanceRequest( + name = '0', + path = '', + context = { + 'key' : null + }, + enabled = True, + content = '' + ) + else: + return BlueprintInstanceRequest( + name = '0', + ) + """ + + def testBlueprintInstanceRequest(self): + """Test BlueprintInstanceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_blueprint_instance_status_enum.py b/test/test_blueprint_instance_status_enum.py new file mode 100644 index 000000000..610e31304 --- /dev/null +++ b/test/test_blueprint_instance_status_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.blueprint_instance_status_enum import BlueprintInstanceStatusEnum + +class TestBlueprintInstanceStatusEnum(unittest.TestCase): + """BlueprintInstanceStatusEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testBlueprintInstanceStatusEnum(self): + """Test BlueprintInstanceStatusEnum""" + # inst = BlueprintInstanceStatusEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_brand.py b/test/test_brand.py new file mode 100644 index 000000000..92eca932e --- /dev/null +++ b/test/test_brand.py @@ -0,0 +1,76 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.brand import Brand + +class TestBrand(unittest.TestCase): + """Brand unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Brand: + """Test Brand + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Brand` + """ + model = Brand() + if include_optional: + return Brand( + brand_uuid = '', + domain = '', + default = True, + branding_title = '', + branding_logo = '', + branding_favicon = '', + branding_custom_css = '', + branding_default_flow_background = '', + flow_authentication = '', + flow_invalidation = '', + flow_recovery = '', + flow_unenrollment = '', + flow_user_settings = '', + flow_device_code = '', + flow_lockdown = '', + default_application = '', + web_certificate = '', + client_certificates = [ + '' + ], + attributes = { + 'key' : null + } + ) + else: + return Brand( + brand_uuid = '', + domain = '', + ) + """ + + def testBrand(self): + """Test Brand""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_brand_request.py b/test/test_brand_request.py new file mode 100644 index 000000000..84bb36146 --- /dev/null +++ b/test/test_brand_request.py @@ -0,0 +1,74 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.brand_request import BrandRequest + +class TestBrandRequest(unittest.TestCase): + """BrandRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> BrandRequest: + """Test BrandRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `BrandRequest` + """ + model = BrandRequest() + if include_optional: + return BrandRequest( + domain = '0', + default = True, + branding_title = '0', + branding_logo = '0', + branding_favicon = '0', + branding_custom_css = '', + branding_default_flow_background = '0', + flow_authentication = '', + flow_invalidation = '', + flow_recovery = '', + flow_unenrollment = '', + flow_user_settings = '', + flow_device_code = '', + flow_lockdown = '', + default_application = '', + web_certificate = '', + client_certificates = [ + '' + ], + attributes = { + 'key' : null + } + ) + else: + return BrandRequest( + domain = '0', + ) + """ + + def testBrandRequest(self): + """Test BrandRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_bulk_delete_session_response.py b/test/test_bulk_delete_session_response.py new file mode 100644 index 000000000..90fdd5713 --- /dev/null +++ b/test/test_bulk_delete_session_response.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.bulk_delete_session_response import BulkDeleteSessionResponse + +class TestBulkDeleteSessionResponse(unittest.TestCase): + """BulkDeleteSessionResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> BulkDeleteSessionResponse: + """Test BulkDeleteSessionResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `BulkDeleteSessionResponse` + """ + model = BulkDeleteSessionResponse() + if include_optional: + return BulkDeleteSessionResponse( + deleted = 56 + ) + else: + return BulkDeleteSessionResponse( + deleted = 56, + ) + """ + + def testBulkDeleteSessionResponse(self): + """Test BulkDeleteSessionResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_cache.py b/test/test_cache.py new file mode 100644 index 000000000..31e48cf03 --- /dev/null +++ b/test/test_cache.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.cache import Cache + +class TestCache(unittest.TestCase): + """Cache unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Cache: + """Test Cache + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Cache` + """ + model = Cache() + if include_optional: + return Cache( + count = 56 + ) + else: + return Cache( + count = 56, + ) + """ + + def testCache(self): + """Test Cache""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_capabilities_enum.py b/test/test_capabilities_enum.py new file mode 100644 index 000000000..c08f14f0f --- /dev/null +++ b/test/test_capabilities_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.capabilities_enum import CapabilitiesEnum + +class TestCapabilitiesEnum(unittest.TestCase): + """CapabilitiesEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testCapabilitiesEnum(self): + """Test CapabilitiesEnum""" + # inst = CapabilitiesEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_captcha_challenge.py b/test/test_captcha_challenge.py new file mode 100644 index 000000000..27db38688 --- /dev/null +++ b/test/test_captcha_challenge.py @@ -0,0 +1,75 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.captcha_challenge import CaptchaChallenge + +class TestCaptchaChallenge(unittest.TestCase): + """CaptchaChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CaptchaChallenge: + """Test CaptchaChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CaptchaChallenge` + """ + model = CaptchaChallenge() + if include_optional: + return CaptchaChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-captcha', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + site_key = '', + js_url = '', + interactive = True + ) + else: + return CaptchaChallenge( + pending_user = '', + pending_user_avatar = '', + site_key = '', + js_url = '', + interactive = True, + ) + """ + + def testCaptchaChallenge(self): + """Test CaptchaChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_captcha_challenge_response_request.py b/test/test_captcha_challenge_response_request.py new file mode 100644 index 000000000..a657099a7 --- /dev/null +++ b/test/test_captcha_challenge_response_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.captcha_challenge_response_request import CaptchaChallengeResponseRequest + +class TestCaptchaChallengeResponseRequest(unittest.TestCase): + """CaptchaChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CaptchaChallengeResponseRequest: + """Test CaptchaChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CaptchaChallengeResponseRequest` + """ + model = CaptchaChallengeResponseRequest() + if include_optional: + return CaptchaChallengeResponseRequest( + component = 'ak-stage-captcha', + token = '0' + ) + else: + return CaptchaChallengeResponseRequest( + token = '0', + ) + """ + + def testCaptchaChallengeResponseRequest(self): + """Test CaptchaChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_captcha_stage.py b/test/test_captcha_stage.py new file mode 100644 index 000000000..09d725926 --- /dev/null +++ b/test/test_captcha_stage.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.captcha_stage import CaptchaStage + +class TestCaptchaStage(unittest.TestCase): + """CaptchaStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CaptchaStage: + """Test CaptchaStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CaptchaStage` + """ + model = CaptchaStage() + if include_optional: + return CaptchaStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + public_key = '', + js_url = '', + api_url = '', + interactive = True, + score_min_threshold = 1.337, + score_max_threshold = 1.337, + error_on_invalid_score = True + ) + else: + return CaptchaStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + public_key = '', + ) + """ + + def testCaptchaStage(self): + """Test CaptchaStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_captcha_stage_request.py b/test/test_captcha_stage_request.py new file mode 100644 index 000000000..35b826b98 --- /dev/null +++ b/test/test_captcha_stage_request.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.captcha_stage_request import CaptchaStageRequest + +class TestCaptchaStageRequest(unittest.TestCase): + """CaptchaStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CaptchaStageRequest: + """Test CaptchaStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CaptchaStageRequest` + """ + model = CaptchaStageRequest() + if include_optional: + return CaptchaStageRequest( + name = '0', + public_key = '0', + private_key = '0', + js_url = '0', + api_url = '0', + interactive = True, + score_min_threshold = 1.337, + score_max_threshold = 1.337, + error_on_invalid_score = True + ) + else: + return CaptchaStageRequest( + name = '0', + public_key = '0', + private_key = '0', + ) + """ + + def testCaptchaStageRequest(self): + """Test CaptchaStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_cert_attribute_enum.py b/test/test_cert_attribute_enum.py new file mode 100644 index 000000000..3694ffd5a --- /dev/null +++ b/test/test_cert_attribute_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.cert_attribute_enum import CertAttributeEnum + +class TestCertAttributeEnum(unittest.TestCase): + """CertAttributeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testCertAttributeEnum(self): + """Test CertAttributeEnum""" + # inst = CertAttributeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_certificate_data.py b/test/test_certificate_data.py new file mode 100644 index 000000000..c153516c9 --- /dev/null +++ b/test/test_certificate_data.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.certificate_data import CertificateData + +class TestCertificateData(unittest.TestCase): + """CertificateData unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CertificateData: + """Test CertificateData + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CertificateData` + """ + model = CertificateData() + if include_optional: + return CertificateData( + data = '' + ) + else: + return CertificateData( + data = '', + ) + """ + + def testCertificateData(self): + """Test CertificateData""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_certificate_generation_request.py b/test/test_certificate_generation_request.py new file mode 100644 index 000000000..6ef73d5ec --- /dev/null +++ b/test/test_certificate_generation_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.certificate_generation_request import CertificateGenerationRequest + +class TestCertificateGenerationRequest(unittest.TestCase): + """CertificateGenerationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CertificateGenerationRequest: + """Test CertificateGenerationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CertificateGenerationRequest` + """ + model = CertificateGenerationRequest() + if include_optional: + return CertificateGenerationRequest( + common_name = '0', + subject_alt_name = '', + validity_days = 56, + alg = 'rsa' + ) + else: + return CertificateGenerationRequest( + common_name = '0', + validity_days = 56, + ) + """ + + def testCertificateGenerationRequest(self): + """Test CertificateGenerationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_certificate_key_pair.py b/test/test_certificate_key_pair.py new file mode 100644 index 000000000..749f4ac45 --- /dev/null +++ b/test/test_certificate_key_pair.py @@ -0,0 +1,73 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.certificate_key_pair import CertificateKeyPair + +class TestCertificateKeyPair(unittest.TestCase): + """CertificateKeyPair unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CertificateKeyPair: + """Test CertificateKeyPair + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CertificateKeyPair` + """ + model = CertificateKeyPair() + if include_optional: + return CertificateKeyPair( + pk = '', + name = '', + fingerprint_sha256 = '', + fingerprint_sha1 = '', + cert_expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + cert_subject = '', + private_key_available = True, + key_type = 'rsa', + certificate_download_url = '', + private_key_download_url = '', + managed = '' + ) + else: + return CertificateKeyPair( + pk = '', + name = '', + fingerprint_sha256 = '', + fingerprint_sha1 = '', + cert_expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + cert_subject = '', + private_key_available = True, + key_type = 'rsa', + certificate_download_url = '', + private_key_download_url = '', + managed = '', + ) + """ + + def testCertificateKeyPair(self): + """Test CertificateKeyPair""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_certificate_key_pair_key_type_enum.py b/test/test_certificate_key_pair_key_type_enum.py new file mode 100644 index 000000000..6ba648ad3 --- /dev/null +++ b/test/test_certificate_key_pair_key_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.certificate_key_pair_key_type_enum import CertificateKeyPairKeyTypeEnum + +class TestCertificateKeyPairKeyTypeEnum(unittest.TestCase): + """CertificateKeyPairKeyTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testCertificateKeyPairKeyTypeEnum(self): + """Test CertificateKeyPairKeyTypeEnum""" + # inst = CertificateKeyPairKeyTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_certificate_key_pair_request.py b/test/test_certificate_key_pair_request.py new file mode 100644 index 000000000..fe227a10c --- /dev/null +++ b/test/test_certificate_key_pair_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.certificate_key_pair_request import CertificateKeyPairRequest + +class TestCertificateKeyPairRequest(unittest.TestCase): + """CertificateKeyPairRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CertificateKeyPairRequest: + """Test CertificateKeyPairRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CertificateKeyPairRequest` + """ + model = CertificateKeyPairRequest() + if include_optional: + return CertificateKeyPairRequest( + name = '0', + certificate_data = '0', + key_data = '' + ) + else: + return CertificateKeyPairRequest( + name = '0', + certificate_data = '0', + ) + """ + + def testCertificateKeyPairRequest(self): + """Test CertificateKeyPairRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_challenge_types.py b/test/test_challenge_types.py new file mode 100644 index 000000000..49e9938e3 --- /dev/null +++ b/test/test_challenge_types.py @@ -0,0 +1,300 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.challenge_types import ChallengeTypes + +class TestChallengeTypes(unittest.TestCase): + """ChallengeTypes unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ChallengeTypes: + """Test ChallengeTypes + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ChallengeTypes` + """ + model = ChallengeTypes() + if include_optional: + return ChallengeTypes( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-user-login', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + error_message = '', + client_id = '', + scope = '', + redirect_uri = '', + state = '', + activation_barcode = '', + activation_code = '', + stage_uuid = '', + email = '', + email_required = True, + phone_number_required = True, + codes = [ + '' + ], + config_url = '', + device_challenges = [ + authentik_client.models.device_challenge.DeviceChallenge( + device_class = 'static', + device_uid = '', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + configuration_stages = [ + authentik_client.models.selectable_stage.SelectableStage( + pk = '', + name = '', + verbose_name = '', + meta_model_name = '', ) + ], + registration = { + 'key' : None + }, + url = '', + attrs = { + 'key' : '' + }, + title = '', + site_key = '', + js_url = '', + interactive = True, + header_text = '', + permissions = [ + authentik_client.models.consent_permission.ConsentPermission( + name = '', + id = '', ) + ], + additional_permissions = [ + authentik_client.models.consent_permission.ConsentPermission( + name = '', + id = '', ) + ], + token = '', + name = '', + challenge = '', + challenge_idle_timeout = 56, + request_id = '', + error = '', + traceback = '', + loading_overlay = True, + loading_text = '', + user_fields = [ + '' + ], + pending_user_identifier = '', + password_fields = True, + allow_show_password = True, + application_pre = '', + application_pre_launch = '', + flow_designation = 'authentication', + captcha_stage = authentik_client.models.captcha_challenge.CaptchaChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-captcha', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + site_key = '', + js_url = '', + interactive = True, ), + enroll_url = '', + recovery_url = '', + passwordless_url = '', + primary_action = '', + sources = [ + authentik_client.models.login_source.LoginSource( + name = '', + icon_url = '', + promoted = True, + challenge = null, ) + ], + show_source_labels = True, + enable_remember_me = True, + passkey_challenge = { + 'key' : None + }, + logout_urls = [ + authentik_client.models.logout_url.LogoutURL( + url = '', + provider_name = '', + binding = '', + saml_request = '', + saml_response = '', + saml_relay_state = '', ) + ], + provider_name = '', + is_complete = True, + post_url = '', + redirect_url = '', + saml_binding = 'redirect', + saml_request = '', + saml_response = '', + saml_relay_state = '', + slug = '', + fields = [ + authentik_client.models.stage_prompt.StagePrompt( + field_key = '', + label = '', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = 56, + sub_text = '', + choices = [ + authentik_client.models.prompt_choice.PromptChoice( + value = '', + label = '', ) + ], ) + ], + to = '', + application_name = '', + application_launch_url = '', + invalidation_flow_url = '', + brand_name = '', + body = '', + bot_username = '', + request_message_access = True + ) + else: + return ChallengeTypes( + pending_user = '', + pending_user_avatar = '', + client_id = '', + scope = '', + redirect_uri = '', + state = '', + activation_barcode = '', + activation_code = '', + stage_uuid = '', + codes = [ + '' + ], + config_url = '', + device_challenges = [ + authentik_client.models.device_challenge.DeviceChallenge( + device_class = 'static', + device_uid = '', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + configuration_stages = [ + authentik_client.models.selectable_stage.SelectableStage( + pk = '', + name = '', + verbose_name = '', + meta_model_name = '', ) + ], + registration = { + 'key' : None + }, + url = '', + attrs = { + 'key' : '' + }, + site_key = '', + js_url = '', + interactive = True, + permissions = [ + authentik_client.models.consent_permission.ConsentPermission( + name = '', + id = '', ) + ], + additional_permissions = [ + authentik_client.models.consent_permission.ConsentPermission( + name = '', + id = '', ) + ], + token = '', + name = '', + challenge = '', + challenge_idle_timeout = 56, + request_id = '', + loading_text = '', + user_fields = [ + '' + ], + password_fields = True, + flow_designation = 'authentication', + primary_action = '', + show_source_labels = True, + slug = '', + fields = [ + authentik_client.models.stage_prompt.StagePrompt( + field_key = '', + label = '', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = 56, + sub_text = '', + choices = [ + authentik_client.models.prompt_choice.PromptChoice( + value = '', + label = '', ) + ], ) + ], + to = '', + brand_name = '', + body = '', + bot_username = '', + request_message_access = True, + ) + """ + + def testChallengeTypes(self): + """Test ChallengeTypes""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_client_type_enum.py b/test/test_client_type_enum.py new file mode 100644 index 000000000..91ac906d6 --- /dev/null +++ b/test/test_client_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.client_type_enum import ClientTypeEnum + +class TestClientTypeEnum(unittest.TestCase): + """ClientTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testClientTypeEnum(self): + """Test ClientTypeEnum""" + # inst = ClientTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_compatibility_mode_enum.py b/test/test_compatibility_mode_enum.py new file mode 100644 index 000000000..1c791c27d --- /dev/null +++ b/test/test_compatibility_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.compatibility_mode_enum import CompatibilityModeEnum + +class TestCompatibilityModeEnum(unittest.TestCase): + """CompatibilityModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testCompatibilityModeEnum(self): + """Test CompatibilityModeEnum""" + # inst = CompatibilityModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_config.py b/test/test_config.py new file mode 100644 index 000000000..87129ffd7 --- /dev/null +++ b/test/test_config.py @@ -0,0 +1,75 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.config import Config + +class TestConfig(unittest.TestCase): + """Config unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Config: + """Test Config + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Config` + """ + model = Config() + if include_optional: + return Config( + error_reporting = authentik_client.models.error_reporting_config.ErrorReportingConfig( + enabled = True, + sentry_dsn = '', + environment = '', + send_pii = True, + traces_sample_rate = 1.337, ), + capabilities = [ + 'can_save_media' + ], + cache_timeout = 56, + cache_timeout_flows = 56, + cache_timeout_policies = 56 + ) + else: + return Config( + error_reporting = authentik_client.models.error_reporting_config.ErrorReportingConfig( + enabled = True, + sentry_dsn = '', + environment = '', + send_pii = True, + traces_sample_rate = 1.337, ), + capabilities = [ + 'can_save_media' + ], + cache_timeout = 56, + cache_timeout_flows = 56, + cache_timeout_policies = 56, + ) + """ + + def testConfig(self): + """Test Config""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_connection_token.py b/test/test_connection_token.py new file mode 100644 index 000000000..45815f301 --- /dev/null +++ b/test/test_connection_token.py @@ -0,0 +1,158 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.connection_token import ConnectionToken + +class TestConnectionToken(unittest.TestCase): + """ConnectionToken unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ConnectionToken: + """Test ConnectionToken + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ConnectionToken` + """ + model = ConnectionToken() + if include_optional: + return ConnectionToken( + pk = '', + provider = 56, + provider_obj = authentik_client.models.rac_provider.RACProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + settings = { + 'key' : null + }, + outpost_set = [ + '' + ], + connection_expiry = '', + delete_token_on_disconnect = True, ), + endpoint = '', + endpoint_obj = authentik_client.models.endpoint.Endpoint( + pk = '', + name = '', + provider = 56, + provider_obj = null, + protocol = 'rdp', + host = '', + settings = { + 'key' : null + }, + property_mappings = [ + '' + ], + auth_mode = 'static', + launch_url = '', + maximum_connections = -2147483648, ), + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ) + else: + return ConnectionToken( + provider = 56, + provider_obj = authentik_client.models.rac_provider.RACProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + settings = { + 'key' : null + }, + outpost_set = [ + '' + ], + connection_expiry = '', + delete_token_on_disconnect = True, ), + endpoint = '', + endpoint_obj = authentik_client.models.endpoint.Endpoint( + pk = '', + name = '', + provider = 56, + provider_obj = null, + protocol = 'rdp', + host = '', + settings = { + 'key' : null + }, + property_mappings = [ + '' + ], + auth_mode = 'static', + launch_url = '', + maximum_connections = -2147483648, ), + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + ) + """ + + def testConnectionToken(self): + """Test ConnectionToken""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_connection_token_request.py b/test/test_connection_token_request.py new file mode 100644 index 000000000..dc127ccbf --- /dev/null +++ b/test/test_connection_token_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.connection_token_request import ConnectionTokenRequest + +class TestConnectionTokenRequest(unittest.TestCase): + """ConnectionTokenRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ConnectionTokenRequest: + """Test ConnectionTokenRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ConnectionTokenRequest` + """ + model = ConnectionTokenRequest() + if include_optional: + return ConnectionTokenRequest( + pk = '', + provider = 56, + endpoint = '' + ) + else: + return ConnectionTokenRequest( + provider = 56, + endpoint = '', + ) + """ + + def testConnectionTokenRequest(self): + """Test ConnectionTokenRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_connector.py b/test/test_connector.py new file mode 100644 index 000000000..cb1237b5e --- /dev/null +++ b/test/test_connector.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.connector import Connector + +class TestConnector(unittest.TestCase): + """Connector unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Connector: + """Test Connector + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Connector` + """ + model = Connector() + if include_optional: + return Connector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return Connector( + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testConnector(self): + """Test Connector""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_consent_challenge.py b/test/test_consent_challenge.py new file mode 100644 index 000000000..54ae8fe99 --- /dev/null +++ b/test/test_consent_challenge.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.consent_challenge import ConsentChallenge + +class TestConsentChallenge(unittest.TestCase): + """ConsentChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ConsentChallenge: + """Test ConsentChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ConsentChallenge` + """ + model = ConsentChallenge() + if include_optional: + return ConsentChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-consent', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + header_text = '', + permissions = [ + authentik_client.models.consent_permission.ConsentPermission( + name = '', + id = '', ) + ], + additional_permissions = [ + authentik_client.models.consent_permission.ConsentPermission( + name = '', + id = '', ) + ], + token = '' + ) + else: + return ConsentChallenge( + pending_user = '', + pending_user_avatar = '', + permissions = [ + authentik_client.models.consent_permission.ConsentPermission( + name = '', + id = '', ) + ], + additional_permissions = [ + authentik_client.models.consent_permission.ConsentPermission( + name = '', + id = '', ) + ], + token = '', + ) + """ + + def testConsentChallenge(self): + """Test ConsentChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_consent_challenge_response_request.py b/test/test_consent_challenge_response_request.py new file mode 100644 index 000000000..87fae50cf --- /dev/null +++ b/test/test_consent_challenge_response_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.consent_challenge_response_request import ConsentChallengeResponseRequest + +class TestConsentChallengeResponseRequest(unittest.TestCase): + """ConsentChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ConsentChallengeResponseRequest: + """Test ConsentChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ConsentChallengeResponseRequest` + """ + model = ConsentChallengeResponseRequest() + if include_optional: + return ConsentChallengeResponseRequest( + component = 'ak-stage-consent', + token = '0' + ) + else: + return ConsentChallengeResponseRequest( + token = '0', + ) + """ + + def testConsentChallengeResponseRequest(self): + """Test ConsentChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_consent_mode_enum.py b/test/test_consent_mode_enum.py new file mode 100644 index 000000000..3743617b6 --- /dev/null +++ b/test/test_consent_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.consent_mode_enum import ConsentModeEnum + +class TestConsentModeEnum(unittest.TestCase): + """ConsentModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testConsentModeEnum(self): + """Test ConsentModeEnum""" + # inst = ConsentModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_consent_permission.py b/test/test_consent_permission.py new file mode 100644 index 000000000..f2f89d7e9 --- /dev/null +++ b/test/test_consent_permission.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.consent_permission import ConsentPermission + +class TestConsentPermission(unittest.TestCase): + """ConsentPermission unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ConsentPermission: + """Test ConsentPermission + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ConsentPermission` + """ + model = ConsentPermission() + if include_optional: + return ConsentPermission( + name = '', + id = '' + ) + else: + return ConsentPermission( + name = '', + id = '', + ) + """ + + def testConsentPermission(self): + """Test ConsentPermission""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_consent_stage.py b/test/test_consent_stage.py new file mode 100644 index 000000000..a35a73c21 --- /dev/null +++ b/test/test_consent_stage.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.consent_stage import ConsentStage + +class TestConsentStage(unittest.TestCase): + """ConsentStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ConsentStage: + """Test ConsentStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ConsentStage` + """ + model = ConsentStage() + if include_optional: + return ConsentStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + mode = 'always_require', + consent_expire_in = '' + ) + else: + return ConsentStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testConsentStage(self): + """Test ConsentStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_consent_stage_request.py b/test/test_consent_stage_request.py new file mode 100644 index 000000000..4762e8662 --- /dev/null +++ b/test/test_consent_stage_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.consent_stage_request import ConsentStageRequest + +class TestConsentStageRequest(unittest.TestCase): + """ConsentStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ConsentStageRequest: + """Test ConsentStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ConsentStageRequest` + """ + model = ConsentStageRequest() + if include_optional: + return ConsentStageRequest( + name = '0', + mode = 'always_require', + consent_expire_in = '0' + ) + else: + return ConsentStageRequest( + name = '0', + ) + """ + + def testConsentStageRequest(self): + """Test ConsentStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_content_type.py b/test/test_content_type.py new file mode 100644 index 000000000..360d58cab --- /dev/null +++ b/test/test_content_type.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.content_type import ContentType + +class TestContentType(unittest.TestCase): + """ContentType unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ContentType: + """Test ContentType + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ContentType` + """ + model = ContentType() + if include_optional: + return ContentType( + id = 56, + app_label = '', + model = '', + verbose_name_plural = '' + ) + else: + return ContentType( + id = 56, + app_label = '', + model = '', + verbose_name_plural = '', + ) + """ + + def testContentType(self): + """Test ContentType""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_content_type_enum.py b/test/test_content_type_enum.py new file mode 100644 index 000000000..1da5f9351 --- /dev/null +++ b/test/test_content_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.content_type_enum import ContentTypeEnum + +class TestContentTypeEnum(unittest.TestCase): + """ContentTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testContentTypeEnum(self): + """Test ContentTypeEnum""" + # inst = ContentTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_contextual_flow_info.py b/test/test_contextual_flow_info.py new file mode 100644 index 000000000..96c98d321 --- /dev/null +++ b/test/test_contextual_flow_info.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.contextual_flow_info import ContextualFlowInfo + +class TestContextualFlowInfo(unittest.TestCase): + """ContextualFlowInfo unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ContextualFlowInfo: + """Test ContextualFlowInfo + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ContextualFlowInfo` + """ + model = ContextualFlowInfo() + if include_optional: + return ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + cancel_url = '', + layout = 'stacked' + ) + else: + return ContextualFlowInfo( + cancel_url = '', + layout = 'stacked', + ) + """ + + def testContextualFlowInfo(self): + """Test ContextualFlowInfo""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_contextual_flow_info_layout_enum.py b/test/test_contextual_flow_info_layout_enum.py new file mode 100644 index 000000000..ea749ac4f --- /dev/null +++ b/test/test_contextual_flow_info_layout_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.contextual_flow_info_layout_enum import ContextualFlowInfoLayoutEnum + +class TestContextualFlowInfoLayoutEnum(unittest.TestCase): + """ContextualFlowInfoLayoutEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testContextualFlowInfoLayoutEnum(self): + """Test ContextualFlowInfoLayoutEnum""" + # inst = ContextualFlowInfoLayoutEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_core_api.py b/test/test_core_api.py new file mode 100644 index 000000000..4e0e89a5e --- /dev/null +++ b/test/test_core_api.py @@ -0,0 +1,446 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.core_api import CoreApi + + +class TestCoreApi(unittest.TestCase): + """CoreApi unit test stubs""" + + def setUp(self) -> None: + self.api = CoreApi() + + def tearDown(self) -> None: + pass + + def test_core_application_entitlements_create(self) -> None: + """Test case for core_application_entitlements_create + + """ + pass + + def test_core_application_entitlements_destroy(self) -> None: + """Test case for core_application_entitlements_destroy + + """ + pass + + def test_core_application_entitlements_list(self) -> None: + """Test case for core_application_entitlements_list + + """ + pass + + def test_core_application_entitlements_partial_update(self) -> None: + """Test case for core_application_entitlements_partial_update + + """ + pass + + def test_core_application_entitlements_retrieve(self) -> None: + """Test case for core_application_entitlements_retrieve + + """ + pass + + def test_core_application_entitlements_update(self) -> None: + """Test case for core_application_entitlements_update + + """ + pass + + def test_core_application_entitlements_used_by_list(self) -> None: + """Test case for core_application_entitlements_used_by_list + + """ + pass + + def test_core_applications_check_access_retrieve(self) -> None: + """Test case for core_applications_check_access_retrieve + + """ + pass + + def test_core_applications_create(self) -> None: + """Test case for core_applications_create + + """ + pass + + def test_core_applications_destroy(self) -> None: + """Test case for core_applications_destroy + + """ + pass + + def test_core_applications_list(self) -> None: + """Test case for core_applications_list + + """ + pass + + def test_core_applications_partial_update(self) -> None: + """Test case for core_applications_partial_update + + """ + pass + + def test_core_applications_retrieve(self) -> None: + """Test case for core_applications_retrieve + + """ + pass + + def test_core_applications_update(self) -> None: + """Test case for core_applications_update + + """ + pass + + def test_core_applications_used_by_list(self) -> None: + """Test case for core_applications_used_by_list + + """ + pass + + def test_core_authenticated_sessions_bulk_delete_destroy(self) -> None: + """Test case for core_authenticated_sessions_bulk_delete_destroy + + """ + pass + + def test_core_authenticated_sessions_destroy(self) -> None: + """Test case for core_authenticated_sessions_destroy + + """ + pass + + def test_core_authenticated_sessions_list(self) -> None: + """Test case for core_authenticated_sessions_list + + """ + pass + + def test_core_authenticated_sessions_retrieve(self) -> None: + """Test case for core_authenticated_sessions_retrieve + + """ + pass + + def test_core_authenticated_sessions_used_by_list(self) -> None: + """Test case for core_authenticated_sessions_used_by_list + + """ + pass + + def test_core_brands_create(self) -> None: + """Test case for core_brands_create + + """ + pass + + def test_core_brands_current_retrieve(self) -> None: + """Test case for core_brands_current_retrieve + + """ + pass + + def test_core_brands_destroy(self) -> None: + """Test case for core_brands_destroy + + """ + pass + + def test_core_brands_list(self) -> None: + """Test case for core_brands_list + + """ + pass + + def test_core_brands_partial_update(self) -> None: + """Test case for core_brands_partial_update + + """ + pass + + def test_core_brands_retrieve(self) -> None: + """Test case for core_brands_retrieve + + """ + pass + + def test_core_brands_update(self) -> None: + """Test case for core_brands_update + + """ + pass + + def test_core_brands_used_by_list(self) -> None: + """Test case for core_brands_used_by_list + + """ + pass + + def test_core_groups_add_user_create(self) -> None: + """Test case for core_groups_add_user_create + + """ + pass + + def test_core_groups_create(self) -> None: + """Test case for core_groups_create + + """ + pass + + def test_core_groups_destroy(self) -> None: + """Test case for core_groups_destroy + + """ + pass + + def test_core_groups_list(self) -> None: + """Test case for core_groups_list + + """ + pass + + def test_core_groups_partial_update(self) -> None: + """Test case for core_groups_partial_update + + """ + pass + + def test_core_groups_remove_user_create(self) -> None: + """Test case for core_groups_remove_user_create + + """ + pass + + def test_core_groups_retrieve(self) -> None: + """Test case for core_groups_retrieve + + """ + pass + + def test_core_groups_update(self) -> None: + """Test case for core_groups_update + + """ + pass + + def test_core_groups_used_by_list(self) -> None: + """Test case for core_groups_used_by_list + + """ + pass + + def test_core_tokens_create(self) -> None: + """Test case for core_tokens_create + + """ + pass + + def test_core_tokens_destroy(self) -> None: + """Test case for core_tokens_destroy + + """ + pass + + def test_core_tokens_list(self) -> None: + """Test case for core_tokens_list + + """ + pass + + def test_core_tokens_partial_update(self) -> None: + """Test case for core_tokens_partial_update + + """ + pass + + def test_core_tokens_retrieve(self) -> None: + """Test case for core_tokens_retrieve + + """ + pass + + def test_core_tokens_set_key_create(self) -> None: + """Test case for core_tokens_set_key_create + + """ + pass + + def test_core_tokens_update(self) -> None: + """Test case for core_tokens_update + + """ + pass + + def test_core_tokens_used_by_list(self) -> None: + """Test case for core_tokens_used_by_list + + """ + pass + + def test_core_tokens_view_key_retrieve(self) -> None: + """Test case for core_tokens_view_key_retrieve + + """ + pass + + def test_core_transactional_applications_update(self) -> None: + """Test case for core_transactional_applications_update + + """ + pass + + def test_core_user_consent_destroy(self) -> None: + """Test case for core_user_consent_destroy + + """ + pass + + def test_core_user_consent_list(self) -> None: + """Test case for core_user_consent_list + + """ + pass + + def test_core_user_consent_retrieve(self) -> None: + """Test case for core_user_consent_retrieve + + """ + pass + + def test_core_user_consent_used_by_list(self) -> None: + """Test case for core_user_consent_used_by_list + + """ + pass + + def test_core_users_account_lockdown_create(self) -> None: + """Test case for core_users_account_lockdown_create + + """ + pass + + def test_core_users_create(self) -> None: + """Test case for core_users_create + + """ + pass + + def test_core_users_destroy(self) -> None: + """Test case for core_users_destroy + + """ + pass + + def test_core_users_export_create(self) -> None: + """Test case for core_users_export_create + + """ + pass + + def test_core_users_impersonate_create(self) -> None: + """Test case for core_users_impersonate_create + + """ + pass + + def test_core_users_impersonate_end_retrieve(self) -> None: + """Test case for core_users_impersonate_end_retrieve + + """ + pass + + def test_core_users_list(self) -> None: + """Test case for core_users_list + + """ + pass + + def test_core_users_me_retrieve(self) -> None: + """Test case for core_users_me_retrieve + + """ + pass + + def test_core_users_partial_update(self) -> None: + """Test case for core_users_partial_update + + """ + pass + + def test_core_users_paths_retrieve(self) -> None: + """Test case for core_users_paths_retrieve + + """ + pass + + def test_core_users_recovery_create(self) -> None: + """Test case for core_users_recovery_create + + """ + pass + + def test_core_users_recovery_email_create(self) -> None: + """Test case for core_users_recovery_email_create + + """ + pass + + def test_core_users_retrieve(self) -> None: + """Test case for core_users_retrieve + + """ + pass + + def test_core_users_service_account_create(self) -> None: + """Test case for core_users_service_account_create + + """ + pass + + def test_core_users_set_password_create(self) -> None: + """Test case for core_users_set_password_create + + """ + pass + + def test_core_users_set_password_hash_create(self) -> None: + """Test case for core_users_set_password_hash_create + + """ + pass + + def test_core_users_update(self) -> None: + """Test case for core_users_update + + """ + pass + + def test_core_users_used_by_list(self) -> None: + """Test case for core_users_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_country_code_enum.py b/test/test_country_code_enum.py new file mode 100644 index 000000000..f512f93b9 --- /dev/null +++ b/test/test_country_code_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.country_code_enum import CountryCodeEnum + +class TestCountryCodeEnum(unittest.TestCase): + """CountryCodeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testCountryCodeEnum(self): + """Test CountryCodeEnum""" + # inst = CountryCodeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_crypto_api.py b/test/test_crypto_api.py new file mode 100644 index 000000000..cee44ee66 --- /dev/null +++ b/test/test_crypto_api.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.crypto_api import CryptoApi + + +class TestCryptoApi(unittest.TestCase): + """CryptoApi unit test stubs""" + + def setUp(self) -> None: + self.api = CryptoApi() + + def tearDown(self) -> None: + pass + + def test_crypto_certificatekeypairs_create(self) -> None: + """Test case for crypto_certificatekeypairs_create + + """ + pass + + def test_crypto_certificatekeypairs_destroy(self) -> None: + """Test case for crypto_certificatekeypairs_destroy + + """ + pass + + def test_crypto_certificatekeypairs_generate_create(self) -> None: + """Test case for crypto_certificatekeypairs_generate_create + + """ + pass + + def test_crypto_certificatekeypairs_list(self) -> None: + """Test case for crypto_certificatekeypairs_list + + """ + pass + + def test_crypto_certificatekeypairs_partial_update(self) -> None: + """Test case for crypto_certificatekeypairs_partial_update + + """ + pass + + def test_crypto_certificatekeypairs_retrieve(self) -> None: + """Test case for crypto_certificatekeypairs_retrieve + + """ + pass + + def test_crypto_certificatekeypairs_update(self) -> None: + """Test case for crypto_certificatekeypairs_update + + """ + pass + + def test_crypto_certificatekeypairs_used_by_list(self) -> None: + """Test case for crypto_certificatekeypairs_used_by_list + + """ + pass + + def test_crypto_certificatekeypairs_view_certificate_retrieve(self) -> None: + """Test case for crypto_certificatekeypairs_view_certificate_retrieve + + """ + pass + + def test_crypto_certificatekeypairs_view_private_key_retrieve(self) -> None: + """Test case for crypto_certificatekeypairs_view_private_key_retrieve + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_current_brand.py b/test/test_current_brand.py new file mode 100644 index 000000000..1349d9125 --- /dev/null +++ b/test/test_current_brand.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.current_brand import CurrentBrand + +class TestCurrentBrand(unittest.TestCase): + """CurrentBrand unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CurrentBrand: + """Test CurrentBrand + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CurrentBrand` + """ + model = CurrentBrand() + if include_optional: + return CurrentBrand( + matched_domain = '', + branding_title = '', + branding_logo = '', + branding_logo_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + branding_favicon = '', + branding_favicon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + branding_custom_css = '', + ui_footer_links = [ + authentik_client.models.footer_link.FooterLink( + href = '', + name = '', ) + ], + ui_theme = 'automatic', + flow_authentication = '', + flow_invalidation = '', + flow_recovery = '', + flow_unenrollment = '', + flow_user_settings = '', + flow_device_code = '', + flow_lockdown = '', + default_locale = '', + flags = authentik_client.models.current_brand_flags.CurrentBrand_flags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True, ) + ) + else: + return CurrentBrand( + matched_domain = '', + branding_title = '', + branding_logo = '', + branding_logo_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + branding_favicon = '', + branding_favicon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + branding_custom_css = '', + ui_footer_links = [ + authentik_client.models.footer_link.FooterLink( + href = '', + name = '', ) + ], + ui_theme = 'automatic', + default_locale = '', + flags = authentik_client.models.current_brand_flags.CurrentBrand_flags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True, ), + ) + """ + + def testCurrentBrand(self): + """Test CurrentBrand""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_current_brand_flags.py b/test/test_current_brand_flags.py new file mode 100644 index 000000000..5ba7fb44e --- /dev/null +++ b/test/test_current_brand_flags.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.current_brand_flags import CurrentBrandFlags + +class TestCurrentBrandFlags(unittest.TestCase): + """CurrentBrandFlags unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> CurrentBrandFlags: + """Test CurrentBrandFlags + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `CurrentBrandFlags` + """ + model = CurrentBrandFlags() + if include_optional: + return CurrentBrandFlags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True + ) + else: + return CurrentBrandFlags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True, + ) + """ + + def testCurrentBrandFlags(self): + """Test CurrentBrandFlags""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_data_export.py b/test/test_data_export.py new file mode 100644 index 000000000..c66234025 --- /dev/null +++ b/test/test_data_export.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.data_export import DataExport + +class TestDataExport(unittest.TestCase): + """DataExport unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DataExport: + """Test DataExport + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DataExport` + """ + model = DataExport() + if include_optional: + return DataExport( + id = '', + requested_by = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + requested_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + content_type = authentik_client.models.content_type.ContentType( + id = 56, + app_label = '', + model = '', + verbose_name_plural = '', ), + var_query_params = { + 'key' : null + }, + file_url = '', + completed = True + ) + else: + return DataExport( + id = '', + requested_by = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + requested_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + content_type = authentik_client.models.content_type.ContentType( + id = 56, + app_label = '', + model = '', + verbose_name_plural = '', ), + var_query_params = { + 'key' : null + }, + file_url = '', + completed = True, + ) + """ + + def testDataExport(self): + """Test DataExport""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_delivery_method_enum.py b/test/test_delivery_method_enum.py new file mode 100644 index 000000000..bf1c48bc6 --- /dev/null +++ b/test/test_delivery_method_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.delivery_method_enum import DeliveryMethodEnum + +class TestDeliveryMethodEnum(unittest.TestCase): + """DeliveryMethodEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testDeliveryMethodEnum(self): + """Test DeliveryMethodEnum""" + # inst = DeliveryMethodEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_denied_action_enum.py b/test/test_denied_action_enum.py new file mode 100644 index 000000000..ae66dc6e9 --- /dev/null +++ b/test/test_denied_action_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.denied_action_enum import DeniedActionEnum + +class TestDeniedActionEnum(unittest.TestCase): + """DeniedActionEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testDeniedActionEnum(self): + """Test DeniedActionEnum""" + # inst = DeniedActionEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_deny_stage.py b/test/test_deny_stage.py new file mode 100644 index 000000000..ba9a17190 --- /dev/null +++ b/test/test_deny_stage.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.deny_stage import DenyStage + +class TestDenyStage(unittest.TestCase): + """DenyStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DenyStage: + """Test DenyStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DenyStage` + """ + model = DenyStage() + if include_optional: + return DenyStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + deny_message = '' + ) + else: + return DenyStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testDenyStage(self): + """Test DenyStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_deny_stage_request.py b/test/test_deny_stage_request.py new file mode 100644 index 000000000..000519917 --- /dev/null +++ b/test/test_deny_stage_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.deny_stage_request import DenyStageRequest + +class TestDenyStageRequest(unittest.TestCase): + """DenyStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DenyStageRequest: + """Test DenyStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DenyStageRequest` + """ + model = DenyStageRequest() + if include_optional: + return DenyStageRequest( + name = '0', + deny_message = '' + ) + else: + return DenyStageRequest( + name = '0', + ) + """ + + def testDenyStageRequest(self): + """Test DenyStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_detailed_country.py b/test/test_detailed_country.py new file mode 100644 index 000000000..fd070dccc --- /dev/null +++ b/test/test_detailed_country.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.detailed_country import DetailedCountry + +class TestDetailedCountry(unittest.TestCase): + """DetailedCountry unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DetailedCountry: + """Test DetailedCountry + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DetailedCountry` + """ + model = DetailedCountry() + if include_optional: + return DetailedCountry( + code = 'AF', + name = '' + ) + else: + return DetailedCountry( + code = 'AF', + name = '', + ) + """ + + def testDetailedCountry(self): + """Test DetailedCountry""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device.py b/test/test_device.py new file mode 100644 index 000000000..d91dabdd8 --- /dev/null +++ b/test/test_device.py @@ -0,0 +1,75 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device import Device + +class TestDevice(unittest.TestCase): + """Device unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Device: + """Test Device + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Device` + """ + model = Device() + if include_optional: + return Device( + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + pk = '', + name = '', + type = '', + confirmed = True, + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + extra_description = '', + external_id = '' + ) + else: + return Device( + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + pk = '', + name = '', + type = '', + confirmed = True, + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + extra_description = '', + external_id = '', + ) + """ + + def testDevice(self): + """Test Device""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_access_group.py b/test/test_device_access_group.py new file mode 100644 index 000000000..b72f3f42b --- /dev/null +++ b/test/test_device_access_group.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_access_group import DeviceAccessGroup + +class TestDeviceAccessGroup(unittest.TestCase): + """DeviceAccessGroup unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceAccessGroup: + """Test DeviceAccessGroup + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceAccessGroup` + """ + model = DeviceAccessGroup() + if include_optional: + return DeviceAccessGroup( + pbm_uuid = '', + name = '', + attributes = { + 'key' : null + } + ) + else: + return DeviceAccessGroup( + pbm_uuid = '', + name = '', + ) + """ + + def testDeviceAccessGroup(self): + """Test DeviceAccessGroup""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_access_group_request.py b/test/test_device_access_group_request.py new file mode 100644 index 000000000..603b12852 --- /dev/null +++ b/test/test_device_access_group_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_access_group_request import DeviceAccessGroupRequest + +class TestDeviceAccessGroupRequest(unittest.TestCase): + """DeviceAccessGroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceAccessGroupRequest: + """Test DeviceAccessGroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceAccessGroupRequest` + """ + model = DeviceAccessGroupRequest() + if include_optional: + return DeviceAccessGroupRequest( + name = '0', + attributes = { + 'key' : null + } + ) + else: + return DeviceAccessGroupRequest( + name = '0', + ) + """ + + def testDeviceAccessGroupRequest(self): + """Test DeviceAccessGroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_challenge.py b/test/test_device_challenge.py new file mode 100644 index 000000000..ad8e0751c --- /dev/null +++ b/test/test_device_challenge.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_challenge import DeviceChallenge + +class TestDeviceChallenge(unittest.TestCase): + """DeviceChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceChallenge: + """Test DeviceChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceChallenge` + """ + model = DeviceChallenge() + if include_optional: + return DeviceChallenge( + device_class = 'static', + device_uid = '', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return DeviceChallenge( + device_class = 'static', + device_uid = '', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testDeviceChallenge(self): + """Test DeviceChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_challenge_request.py b/test/test_device_challenge_request.py new file mode 100644 index 000000000..c930d8878 --- /dev/null +++ b/test/test_device_challenge_request.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_challenge_request import DeviceChallengeRequest + +class TestDeviceChallengeRequest(unittest.TestCase): + """DeviceChallengeRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceChallengeRequest: + """Test DeviceChallengeRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceChallengeRequest` + """ + model = DeviceChallengeRequest() + if include_optional: + return DeviceChallengeRequest( + device_class = 'static', + device_uid = '0', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return DeviceChallengeRequest( + device_class = 'static', + device_uid = '0', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testDeviceChallengeRequest(self): + """Test DeviceChallengeRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_classes_enum.py b/test/test_device_classes_enum.py new file mode 100644 index 000000000..20c70d275 --- /dev/null +++ b/test/test_device_classes_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_classes_enum import DeviceClassesEnum + +class TestDeviceClassesEnum(unittest.TestCase): + """DeviceClassesEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testDeviceClassesEnum(self): + """Test DeviceClassesEnum""" + # inst = DeviceClassesEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_connection.py b/test/test_device_connection.py new file mode 100644 index 000000000..091be4944 --- /dev/null +++ b/test/test_device_connection.py @@ -0,0 +1,163 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_connection import DeviceConnection + +class TestDeviceConnection(unittest.TestCase): + """DeviceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceConnection: + """Test DeviceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceConnection` + """ + model = DeviceConnection() + if include_optional: + return DeviceConnection( + device = '', + connector = '', + connector_obj = authentik_client.models.connector.Connector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ), + latest_snapshot = authentik_client.models.device_fact_snapshot.DeviceFactSnapshot( + data = authentik_client.models.device_facts.DeviceFacts( + os = null, + disks = [ + authentik_client.models.disk.Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = null, + hardware = null, + software = [ + authentik_client.models.software.Software( + name = '', + version = '', + source = '', + path = '', ) + ], + processes = [ + authentik_client.models.process.Process( + id = 56, + name = '', + user = '', ) + ], + users = [ + authentik_client.models.device_user.DeviceUser( + id = '', + username = '', + name = '', + home = '', ) + ], + groups = [ + authentik_client.models.device_group.DeviceGroup( + id = '', + name = '', ) + ], + vendor = { + 'key' : null + }, ), + connection = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + vendor = null, ) + ) + else: + return DeviceConnection( + device = '', + connector = '', + connector_obj = authentik_client.models.connector.Connector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ), + latest_snapshot = authentik_client.models.device_fact_snapshot.DeviceFactSnapshot( + data = authentik_client.models.device_facts.DeviceFacts( + os = null, + disks = [ + authentik_client.models.disk.Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = null, + hardware = null, + software = [ + authentik_client.models.software.Software( + name = '', + version = '', + source = '', + path = '', ) + ], + processes = [ + authentik_client.models.process.Process( + id = 56, + name = '', + user = '', ) + ], + users = [ + authentik_client.models.device_user.DeviceUser( + id = '', + username = '', + name = '', + home = '', ) + ], + groups = [ + authentik_client.models.device_group.DeviceGroup( + id = '', + name = '', ) + ], + vendor = { + 'key' : null + }, ), + connection = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + vendor = null, ), + ) + """ + + def testDeviceConnection(self): + """Test DeviceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_fact_snapshot.py b/test/test_device_fact_snapshot.py new file mode 100644 index 000000000..c049532f8 --- /dev/null +++ b/test/test_device_fact_snapshot.py @@ -0,0 +1,141 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_fact_snapshot import DeviceFactSnapshot + +class TestDeviceFactSnapshot(unittest.TestCase): + """DeviceFactSnapshot unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceFactSnapshot: + """Test DeviceFactSnapshot + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceFactSnapshot` + """ + model = DeviceFactSnapshot() + if include_optional: + return DeviceFactSnapshot( + data = authentik_client.models.device_facts.DeviceFacts( + os = null, + disks = [ + authentik_client.models.disk.Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = null, + hardware = null, + software = [ + authentik_client.models.software.Software( + name = '', + version = '', + source = '', + path = '', ) + ], + processes = [ + authentik_client.models.process.Process( + id = 56, + name = '', + user = '', ) + ], + users = [ + authentik_client.models.device_user.DeviceUser( + id = '', + username = '', + name = '', + home = '', ) + ], + groups = [ + authentik_client.models.device_group.DeviceGroup( + id = '', + name = '', ) + ], + vendor = { + 'key' : null + }, ), + connection = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + vendor = 'goauthentik.io/@merged' + ) + else: + return DeviceFactSnapshot( + data = authentik_client.models.device_facts.DeviceFacts( + os = null, + disks = [ + authentik_client.models.disk.Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = null, + hardware = null, + software = [ + authentik_client.models.software.Software( + name = '', + version = '', + source = '', + path = '', ) + ], + processes = [ + authentik_client.models.process.Process( + id = 56, + name = '', + user = '', ) + ], + users = [ + authentik_client.models.device_user.DeviceUser( + id = '', + username = '', + name = '', + home = '', ) + ], + groups = [ + authentik_client.models.device_group.DeviceGroup( + id = '', + name = '', ) + ], + vendor = { + 'key' : null + }, ), + connection = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + vendor = 'goauthentik.io/@merged', + ) + """ + + def testDeviceFactSnapshot(self): + """Test DeviceFactSnapshot""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_facts.py b/test/test_device_facts.py new file mode 100644 index 000000000..9837e8f59 --- /dev/null +++ b/test/test_device_facts.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_facts import DeviceFacts + +class TestDeviceFacts(unittest.TestCase): + """DeviceFacts unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceFacts: + """Test DeviceFacts + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceFacts` + """ + model = DeviceFacts() + if include_optional: + return DeviceFacts( + os = authentik_client.models.operating_system.OperatingSystem( + family = 'linux', + name = '', + version = '', + arch = '', ), + disks = [ + authentik_client.models.disk.Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = authentik_client.models.network.Network( + hostname = '', + firewall_enabled = True, + interfaces = [ + authentik_client.models.network_interface.NetworkInterface( + name = '', + hardware_address = '', + ip_addresses = [ + '' + ], + dns_servers = [ + '' + ], ) + ], + gateway = '', ), + hardware = authentik_client.models.hardware.Hardware( + model = '', + manufacturer = '', + serial = '', + cpu_name = '', + cpu_count = 56, + memory_bytes = 56, ), + software = [ + authentik_client.models.software.Software( + name = '', + version = '', + source = '', + path = '', ) + ], + processes = [ + authentik_client.models.process.Process( + id = 56, + name = '', + user = '', ) + ], + users = [ + authentik_client.models.device_user.DeviceUser( + id = '', + username = '', + name = '', + home = '', ) + ], + groups = [ + authentik_client.models.device_group.DeviceGroup( + id = '', + name = '', ) + ], + vendor = { + 'key' : null + } + ) + else: + return DeviceFacts( + ) + """ + + def testDeviceFacts(self): + """Test DeviceFacts""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_facts_os_family.py b/test/test_device_facts_os_family.py new file mode 100644 index 000000000..8143dae2c --- /dev/null +++ b/test/test_device_facts_os_family.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_facts_os_family import DeviceFactsOSFamily + +class TestDeviceFactsOSFamily(unittest.TestCase): + """DeviceFactsOSFamily unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testDeviceFactsOSFamily(self): + """Test DeviceFactsOSFamily""" + # inst = DeviceFactsOSFamily() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_facts_request.py b/test/test_device_facts_request.py new file mode 100644 index 000000000..52098d44e --- /dev/null +++ b/test/test_device_facts_request.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_facts_request import DeviceFactsRequest + +class TestDeviceFactsRequest(unittest.TestCase): + """DeviceFactsRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceFactsRequest: + """Test DeviceFactsRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceFactsRequest` + """ + model = DeviceFactsRequest() + if include_optional: + return DeviceFactsRequest( + os = authentik_client.models.operating_system_request.OperatingSystemRequest( + family = 'linux', + name = '0', + version = '0', + arch = '0', ), + disks = [ + authentik_client.models.disk_request.DiskRequest( + name = '0', + mountpoint = '0', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = authentik_client.models.network_request.NetworkRequest( + hostname = '0', + firewall_enabled = True, + interfaces = [ + authentik_client.models.network_interface_request.NetworkInterfaceRequest( + name = '0', + hardware_address = '0', + ip_addresses = [ + '0' + ], + dns_servers = [ + '0' + ], ) + ], + gateway = '0', ), + hardware = authentik_client.models.hardware_request.HardwareRequest( + model = '0', + manufacturer = '0', + serial = '0', + cpu_name = '0', + cpu_count = 56, + memory_bytes = 56, ), + software = [ + authentik_client.models.software_request.SoftwareRequest( + name = '0', + version = '', + source = '0', + path = '0', ) + ], + processes = [ + authentik_client.models.process_request.ProcessRequest( + id = 56, + name = '0', + user = '0', ) + ], + users = [ + authentik_client.models.device_user_request.DeviceUserRequest( + id = '0', + username = '0', + name = '0', + home = '0', ) + ], + groups = [ + authentik_client.models.device_group_request.DeviceGroupRequest( + id = '0', + name = '0', ) + ], + vendor = { + 'key' : null + } + ) + else: + return DeviceFactsRequest( + ) + """ + + def testDeviceFactsRequest(self): + """Test DeviceFactsRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_group.py b/test/test_device_group.py new file mode 100644 index 000000000..42c8bccc2 --- /dev/null +++ b/test/test_device_group.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_group import DeviceGroup + +class TestDeviceGroup(unittest.TestCase): + """DeviceGroup unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceGroup: + """Test DeviceGroup + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceGroup` + """ + model = DeviceGroup() + if include_optional: + return DeviceGroup( + id = '', + name = '' + ) + else: + return DeviceGroup( + id = '', + ) + """ + + def testDeviceGroup(self): + """Test DeviceGroup""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_group_request.py b/test/test_device_group_request.py new file mode 100644 index 000000000..ae605a55d --- /dev/null +++ b/test/test_device_group_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_group_request import DeviceGroupRequest + +class TestDeviceGroupRequest(unittest.TestCase): + """DeviceGroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceGroupRequest: + """Test DeviceGroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceGroupRequest` + """ + model = DeviceGroupRequest() + if include_optional: + return DeviceGroupRequest( + id = '0', + name = '0' + ) + else: + return DeviceGroupRequest( + id = '0', + ) + """ + + def testDeviceGroupRequest(self): + """Test DeviceGroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_summary.py b/test/test_device_summary.py new file mode 100644 index 000000000..f09c012c6 --- /dev/null +++ b/test/test_device_summary.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_summary import DeviceSummary + +class TestDeviceSummary(unittest.TestCase): + """DeviceSummary unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceSummary: + """Test DeviceSummary + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceSummary` + """ + model = DeviceSummary() + if include_optional: + return DeviceSummary( + total_count = 56, + unreachable_count = 56, + outdated_agent_count = 56 + ) + else: + return DeviceSummary( + total_count = 56, + unreachable_count = 56, + outdated_agent_count = 56, + ) + """ + + def testDeviceSummary(self): + """Test DeviceSummary""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_user.py b/test/test_device_user.py new file mode 100644 index 000000000..f90856397 --- /dev/null +++ b/test/test_device_user.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_user import DeviceUser + +class TestDeviceUser(unittest.TestCase): + """DeviceUser unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceUser: + """Test DeviceUser + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceUser` + """ + model = DeviceUser() + if include_optional: + return DeviceUser( + id = '', + username = '', + name = '', + home = '' + ) + else: + return DeviceUser( + id = '', + ) + """ + + def testDeviceUser(self): + """Test DeviceUser""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_user_binding.py b/test/test_device_user_binding.py new file mode 100644 index 000000000..7895b57e0 --- /dev/null +++ b/test/test_device_user_binding.py @@ -0,0 +1,139 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_user_binding import DeviceUserBinding + +class TestDeviceUserBinding(unittest.TestCase): + """DeviceUserBinding unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceUserBinding: + """Test DeviceUserBinding + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceUserBinding` + """ + model = DeviceUserBinding() + if include_optional: + return DeviceUserBinding( + pk = '', + policy = '', + group = '', + user = 56, + policy_obj = authentik_client.models.policy.Policy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, ), + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True, + is_primary = True, + connector = '', + connector_obj = authentik_client.models.connector.Connector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ) + else: + return DeviceUserBinding( + pk = '', + policy_obj = authentik_client.models.policy.Policy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, ), + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + target = '', + order = -2147483648, + connector = '', + connector_obj = authentik_client.models.connector.Connector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ), + ) + """ + + def testDeviceUserBinding(self): + """Test DeviceUserBinding""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_user_binding_request.py b/test/test_device_user_binding_request.py new file mode 100644 index 000000000..c7af8dd4c --- /dev/null +++ b/test/test_device_user_binding_request.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_user_binding_request import DeviceUserBindingRequest + +class TestDeviceUserBindingRequest(unittest.TestCase): + """DeviceUserBindingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceUserBindingRequest: + """Test DeviceUserBindingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceUserBindingRequest` + """ + model = DeviceUserBindingRequest() + if include_optional: + return DeviceUserBindingRequest( + policy = '', + group = '', + user = 56, + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True, + is_primary = True + ) + else: + return DeviceUserBindingRequest( + target = '', + order = -2147483648, + ) + """ + + def testDeviceUserBindingRequest(self): + """Test DeviceUserBindingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_device_user_request.py b/test/test_device_user_request.py new file mode 100644 index 000000000..02e9562bf --- /dev/null +++ b/test/test_device_user_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.device_user_request import DeviceUserRequest + +class TestDeviceUserRequest(unittest.TestCase): + """DeviceUserRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeviceUserRequest: + """Test DeviceUserRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeviceUserRequest` + """ + model = DeviceUserRequest() + if include_optional: + return DeviceUserRequest( + id = '0', + username = '0', + name = '0', + home = '0' + ) + else: + return DeviceUserRequest( + id = '0', + ) + """ + + def testDeviceUserRequest(self): + """Test DeviceUserRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_digest_algorithm_enum.py b/test/test_digest_algorithm_enum.py new file mode 100644 index 000000000..3267cfed9 --- /dev/null +++ b/test/test_digest_algorithm_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.digest_algorithm_enum import DigestAlgorithmEnum + +class TestDigestAlgorithmEnum(unittest.TestCase): + """DigestAlgorithmEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testDigestAlgorithmEnum(self): + """Test DigestAlgorithmEnum""" + # inst = DigestAlgorithmEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_digits_enum.py b/test/test_digits_enum.py new file mode 100644 index 000000000..5dae94ef2 --- /dev/null +++ b/test/test_digits_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.digits_enum import DigitsEnum + +class TestDigitsEnum(unittest.TestCase): + """DigitsEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testDigitsEnum(self): + """Test DigitsEnum""" + # inst = DigitsEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_disk.py b/test/test_disk.py new file mode 100644 index 000000000..50d511fe1 --- /dev/null +++ b/test/test_disk.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.disk import Disk + +class TestDisk(unittest.TestCase): + """Disk unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Disk: + """Test Disk + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Disk` + """ + model = Disk() + if include_optional: + return Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True + ) + else: + return Disk( + name = '', + mountpoint = '', + ) + """ + + def testDisk(self): + """Test Disk""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_disk_request.py b/test/test_disk_request.py new file mode 100644 index 000000000..1208199fc --- /dev/null +++ b/test/test_disk_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.disk_request import DiskRequest + +class TestDiskRequest(unittest.TestCase): + """DiskRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DiskRequest: + """Test DiskRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DiskRequest` + """ + model = DiskRequest() + if include_optional: + return DiskRequest( + name = '0', + mountpoint = '0', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True + ) + else: + return DiskRequest( + name = '0', + mountpoint = '0', + ) + """ + + def testDiskRequest(self): + """Test DiskRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_docker_service_connection.py b/test/test_docker_service_connection.py new file mode 100644 index 000000000..d1e5d65ae --- /dev/null +++ b/test/test_docker_service_connection.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.docker_service_connection import DockerServiceConnection + +class TestDockerServiceConnection(unittest.TestCase): + """DockerServiceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DockerServiceConnection: + """Test DockerServiceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DockerServiceConnection` + """ + model = DockerServiceConnection() + if include_optional: + return DockerServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + tls_verification = '', + tls_authentication = '' + ) + else: + return DockerServiceConnection( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + ) + """ + + def testDockerServiceConnection(self): + """Test DockerServiceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_docker_service_connection_request.py b/test/test_docker_service_connection_request.py new file mode 100644 index 000000000..9caa67a98 --- /dev/null +++ b/test/test_docker_service_connection_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.docker_service_connection_request import DockerServiceConnectionRequest + +class TestDockerServiceConnectionRequest(unittest.TestCase): + """DockerServiceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DockerServiceConnectionRequest: + """Test DockerServiceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DockerServiceConnectionRequest` + """ + model = DockerServiceConnectionRequest() + if include_optional: + return DockerServiceConnectionRequest( + name = '0', + local = True, + url = '0', + tls_verification = '', + tls_authentication = '' + ) + else: + return DockerServiceConnectionRequest( + name = '0', + url = '0', + ) + """ + + def testDockerServiceConnectionRequest(self): + """Test DockerServiceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_domain.py b/test/test_domain.py new file mode 100644 index 000000000..a2d51cb95 --- /dev/null +++ b/test/test_domain.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.domain import Domain + +class TestDomain(unittest.TestCase): + """Domain unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Domain: + """Test Domain + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Domain` + """ + model = Domain() + if include_optional: + return Domain( + id = 56, + domain = '', + is_primary = True, + tenant = '' + ) + else: + return Domain( + id = 56, + domain = '', + tenant = '', + ) + """ + + def testDomain(self): + """Test Domain""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_domain_request.py b/test/test_domain_request.py new file mode 100644 index 000000000..e0b2ca6cc --- /dev/null +++ b/test/test_domain_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.domain_request import DomainRequest + +class TestDomainRequest(unittest.TestCase): + """DomainRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DomainRequest: + """Test DomainRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DomainRequest` + """ + model = DomainRequest() + if include_optional: + return DomainRequest( + domain = '0', + is_primary = True, + tenant = '' + ) + else: + return DomainRequest( + domain = '0', + tenant = '', + ) + """ + + def testDomainRequest(self): + """Test DomainRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_dummy_challenge.py b/test/test_dummy_challenge.py new file mode 100644 index 000000000..875cae79c --- /dev/null +++ b/test/test_dummy_challenge.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.dummy_challenge import DummyChallenge + +class TestDummyChallenge(unittest.TestCase): + """DummyChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DummyChallenge: + """Test DummyChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DummyChallenge` + """ + model = DummyChallenge() + if include_optional: + return DummyChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-dummy', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + name = '' + ) + else: + return DummyChallenge( + name = '', + ) + """ + + def testDummyChallenge(self): + """Test DummyChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_dummy_challenge_response_request.py b/test/test_dummy_challenge_response_request.py new file mode 100644 index 000000000..f3875dd14 --- /dev/null +++ b/test/test_dummy_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.dummy_challenge_response_request import DummyChallengeResponseRequest + +class TestDummyChallengeResponseRequest(unittest.TestCase): + """DummyChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DummyChallengeResponseRequest: + """Test DummyChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DummyChallengeResponseRequest` + """ + model = DummyChallengeResponseRequest() + if include_optional: + return DummyChallengeResponseRequest( + component = 'ak-stage-dummy' + ) + else: + return DummyChallengeResponseRequest( + ) + """ + + def testDummyChallengeResponseRequest(self): + """Test DummyChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_dummy_policy.py b/test/test_dummy_policy.py new file mode 100644 index 000000000..fc97b0ef2 --- /dev/null +++ b/test/test_dummy_policy.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.dummy_policy import DummyPolicy + +class TestDummyPolicy(unittest.TestCase): + """DummyPolicy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DummyPolicy: + """Test DummyPolicy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DummyPolicy` + """ + model = DummyPolicy() + if include_optional: + return DummyPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + result = True, + wait_min = -2147483648, + wait_max = -2147483648 + ) + else: + return DummyPolicy( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + ) + """ + + def testDummyPolicy(self): + """Test DummyPolicy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_dummy_policy_request.py b/test/test_dummy_policy_request.py new file mode 100644 index 000000000..a7d649c53 --- /dev/null +++ b/test/test_dummy_policy_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.dummy_policy_request import DummyPolicyRequest + +class TestDummyPolicyRequest(unittest.TestCase): + """DummyPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DummyPolicyRequest: + """Test DummyPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DummyPolicyRequest` + """ + model = DummyPolicyRequest() + if include_optional: + return DummyPolicyRequest( + name = '0', + execution_logging = True, + result = True, + wait_min = -2147483648, + wait_max = -2147483648 + ) + else: + return DummyPolicyRequest( + name = '0', + ) + """ + + def testDummyPolicyRequest(self): + """Test DummyPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_dummy_stage.py b/test/test_dummy_stage.py new file mode 100644 index 000000000..0cf7eac1c --- /dev/null +++ b/test/test_dummy_stage.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.dummy_stage import DummyStage + +class TestDummyStage(unittest.TestCase): + """DummyStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DummyStage: + """Test DummyStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DummyStage` + """ + model = DummyStage() + if include_optional: + return DummyStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + throw_error = True + ) + else: + return DummyStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testDummyStage(self): + """Test DummyStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_dummy_stage_request.py b/test/test_dummy_stage_request.py new file mode 100644 index 000000000..fdadea631 --- /dev/null +++ b/test/test_dummy_stage_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.dummy_stage_request import DummyStageRequest + +class TestDummyStageRequest(unittest.TestCase): + """DummyStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DummyStageRequest: + """Test DummyStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DummyStageRequest` + """ + model = DummyStageRequest() + if include_optional: + return DummyStageRequest( + name = '0', + throw_error = True + ) + else: + return DummyStageRequest( + name = '0', + ) + """ + + def testDummyStageRequest(self): + """Test DummyStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_duo_device.py b/test/test_duo_device.py new file mode 100644 index 000000000..1db68e8e6 --- /dev/null +++ b/test/test_duo_device.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.duo_device import DuoDevice + +class TestDuoDevice(unittest.TestCase): + """DuoDevice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DuoDevice: + """Test DuoDevice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DuoDevice` + """ + model = DuoDevice() + if include_optional: + return DuoDevice( + pk = 56, + name = '', + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ) + else: + return DuoDevice( + pk = 56, + name = '', + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + ) + """ + + def testDuoDevice(self): + """Test DuoDevice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_duo_device_enrollment_status.py b/test/test_duo_device_enrollment_status.py new file mode 100644 index 000000000..c5e5d68a3 --- /dev/null +++ b/test/test_duo_device_enrollment_status.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.duo_device_enrollment_status import DuoDeviceEnrollmentStatus + +class TestDuoDeviceEnrollmentStatus(unittest.TestCase): + """DuoDeviceEnrollmentStatus unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DuoDeviceEnrollmentStatus: + """Test DuoDeviceEnrollmentStatus + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DuoDeviceEnrollmentStatus` + """ + model = DuoDeviceEnrollmentStatus() + if include_optional: + return DuoDeviceEnrollmentStatus( + duo_response = 'success' + ) + else: + return DuoDeviceEnrollmentStatus( + duo_response = 'success', + ) + """ + + def testDuoDeviceEnrollmentStatus(self): + """Test DuoDeviceEnrollmentStatus""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_duo_device_request.py b/test/test_duo_device_request.py new file mode 100644 index 000000000..acadf7803 --- /dev/null +++ b/test/test_duo_device_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.duo_device_request import DuoDeviceRequest + +class TestDuoDeviceRequest(unittest.TestCase): + """DuoDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DuoDeviceRequest: + """Test DuoDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DuoDeviceRequest` + """ + model = DuoDeviceRequest() + if include_optional: + return DuoDeviceRequest( + name = '0' + ) + else: + return DuoDeviceRequest( + name = '0', + ) + """ + + def testDuoDeviceRequest(self): + """Test DuoDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_duo_response_enum.py b/test/test_duo_response_enum.py new file mode 100644 index 000000000..0ac0dbb16 --- /dev/null +++ b/test/test_duo_response_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.duo_response_enum import DuoResponseEnum + +class TestDuoResponseEnum(unittest.TestCase): + """DuoResponseEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testDuoResponseEnum(self): + """Test DuoResponseEnum""" + # inst = DuoResponseEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_email_challenge.py b/test/test_email_challenge.py new file mode 100644 index 000000000..b92737c50 --- /dev/null +++ b/test/test_email_challenge.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.email_challenge import EmailChallenge + +class TestEmailChallenge(unittest.TestCase): + """EmailChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EmailChallenge: + """Test EmailChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EmailChallenge` + """ + model = EmailChallenge() + if include_optional: + return EmailChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-email', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + } + ) + else: + return EmailChallenge( + ) + """ + + def testEmailChallenge(self): + """Test EmailChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_email_challenge_response_request.py b/test/test_email_challenge_response_request.py new file mode 100644 index 000000000..f30c94311 --- /dev/null +++ b/test/test_email_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.email_challenge_response_request import EmailChallengeResponseRequest + +class TestEmailChallengeResponseRequest(unittest.TestCase): + """EmailChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EmailChallengeResponseRequest: + """Test EmailChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EmailChallengeResponseRequest` + """ + model = EmailChallengeResponseRequest() + if include_optional: + return EmailChallengeResponseRequest( + component = 'ak-stage-email' + ) + else: + return EmailChallengeResponseRequest( + ) + """ + + def testEmailChallengeResponseRequest(self): + """Test EmailChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_email_device.py b/test/test_email_device.py new file mode 100644 index 000000000..91038c568 --- /dev/null +++ b/test/test_email_device.py @@ -0,0 +1,79 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.email_device import EmailDevice + +class TestEmailDevice(unittest.TestCase): + """EmailDevice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EmailDevice: + """Test EmailDevice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EmailDevice` + """ + model = EmailDevice() + if include_optional: + return EmailDevice( + name = '', + pk = 56, + email = '', + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ) + else: + return EmailDevice( + name = '', + pk = 56, + email = '', + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + ) + """ + + def testEmailDevice(self): + """Test EmailDevice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_email_device_request.py b/test/test_email_device_request.py new file mode 100644 index 000000000..bf2266acc --- /dev/null +++ b/test/test_email_device_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.email_device_request import EmailDeviceRequest + +class TestEmailDeviceRequest(unittest.TestCase): + """EmailDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EmailDeviceRequest: + """Test EmailDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EmailDeviceRequest` + """ + model = EmailDeviceRequest() + if include_optional: + return EmailDeviceRequest( + name = '0' + ) + else: + return EmailDeviceRequest( + name = '0', + ) + """ + + def testEmailDeviceRequest(self): + """Test EmailDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_email_stage.py b/test/test_email_stage.py new file mode 100644 index 000000000..425b9acd6 --- /dev/null +++ b/test/test_email_stage.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.email_stage import EmailStage + +class TestEmailStage(unittest.TestCase): + """EmailStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EmailStage: + """Test EmailStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EmailStage` + """ + model = EmailStage() + if include_optional: + return EmailStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + use_global_settings = True, + host = '', + port = -2147483648, + username = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '', + token_expiry = '', + subject = '', + template = '', + activate_user_on_success = True, + recovery_max_attempts = 0, + recovery_cache_timeout = '' + ) + else: + return EmailStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testEmailStage(self): + """Test EmailStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_email_stage_request.py b/test/test_email_stage_request.py new file mode 100644 index 000000000..2d4543cf3 --- /dev/null +++ b/test/test_email_stage_request.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.email_stage_request import EmailStageRequest + +class TestEmailStageRequest(unittest.TestCase): + """EmailStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EmailStageRequest: + """Test EmailStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EmailStageRequest` + """ + model = EmailStageRequest() + if include_optional: + return EmailStageRequest( + name = '0', + use_global_settings = True, + host = '0', + port = -2147483648, + username = '', + password = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '0', + token_expiry = '0', + subject = '0', + template = '0', + activate_user_on_success = True, + recovery_max_attempts = 0, + recovery_cache_timeout = '0' + ) + else: + return EmailStageRequest( + name = '0', + ) + """ + + def testEmailStageRequest(self): + """Test EmailStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint.py b/test/test_endpoint.py new file mode 100644 index 000000000..5e3526d88 --- /dev/null +++ b/test/test_endpoint.py @@ -0,0 +1,120 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint import Endpoint + +class TestEndpoint(unittest.TestCase): + """Endpoint unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Endpoint: + """Test Endpoint + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Endpoint` + """ + model = Endpoint() + if include_optional: + return Endpoint( + pk = '', + name = '', + provider = 56, + provider_obj = authentik_client.models.rac_provider.RACProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + settings = { + 'key' : null + }, + outpost_set = [ + '' + ], + connection_expiry = '', + delete_token_on_disconnect = True, ), + protocol = 'rdp', + host = '', + settings = { + 'key' : null + }, + property_mappings = [ + '' + ], + auth_mode = 'static', + launch_url = '', + maximum_connections = -2147483648 + ) + else: + return Endpoint( + pk = '', + name = '', + provider = 56, + provider_obj = authentik_client.models.rac_provider.RACProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + settings = { + 'key' : null + }, + outpost_set = [ + '' + ], + connection_expiry = '', + delete_token_on_disconnect = True, ), + protocol = 'rdp', + host = '', + auth_mode = 'static', + launch_url = '', + ) + """ + + def testEndpoint(self): + """Test Endpoint""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint_agent_challenge.py b/test/test_endpoint_agent_challenge.py new file mode 100644 index 000000000..58cb3c34a --- /dev/null +++ b/test/test_endpoint_agent_challenge.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint_agent_challenge import EndpointAgentChallenge + +class TestEndpointAgentChallenge(unittest.TestCase): + """EndpointAgentChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EndpointAgentChallenge: + """Test EndpointAgentChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EndpointAgentChallenge` + """ + model = EndpointAgentChallenge() + if include_optional: + return EndpointAgentChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-endpoint-agent', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + challenge = '', + challenge_idle_timeout = 56 + ) + else: + return EndpointAgentChallenge( + challenge = '', + challenge_idle_timeout = 56, + ) + """ + + def testEndpointAgentChallenge(self): + """Test EndpointAgentChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint_agent_challenge_response_request.py b/test/test_endpoint_agent_challenge_response_request.py new file mode 100644 index 000000000..90946d2d4 --- /dev/null +++ b/test/test_endpoint_agent_challenge_response_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint_agent_challenge_response_request import EndpointAgentChallengeResponseRequest + +class TestEndpointAgentChallengeResponseRequest(unittest.TestCase): + """EndpointAgentChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EndpointAgentChallengeResponseRequest: + """Test EndpointAgentChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EndpointAgentChallengeResponseRequest` + """ + model = EndpointAgentChallengeResponseRequest() + if include_optional: + return EndpointAgentChallengeResponseRequest( + component = 'ak-stage-endpoint-agent', + response = '0' + ) + else: + return EndpointAgentChallengeResponseRequest( + ) + """ + + def testEndpointAgentChallengeResponseRequest(self): + """Test EndpointAgentChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint_auth_mode_enum.py b/test/test_endpoint_auth_mode_enum.py new file mode 100644 index 000000000..d685a3fd0 --- /dev/null +++ b/test/test_endpoint_auth_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint_auth_mode_enum import EndpointAuthModeEnum + +class TestEndpointAuthModeEnum(unittest.TestCase): + """EndpointAuthModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testEndpointAuthModeEnum(self): + """Test EndpointAuthModeEnum""" + # inst = EndpointAuthModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint_device.py b/test/test_endpoint_device.py new file mode 100644 index 000000000..33589cbb9 --- /dev/null +++ b/test/test_endpoint_device.py @@ -0,0 +1,160 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint_device import EndpointDevice + +class TestEndpointDevice(unittest.TestCase): + """EndpointDevice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EndpointDevice: + """Test EndpointDevice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EndpointDevice` + """ + model = EndpointDevice() + if include_optional: + return EndpointDevice( + device_uuid = '', + pbm_uuid = '', + name = '', + access_group = '', + access_group_obj = authentik_client.models.device_access_group.DeviceAccessGroup( + pbm_uuid = '', + name = '', + attributes = { + 'key' : null + }, ), + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + facts = authentik_client.models.device_fact_snapshot.DeviceFactSnapshot( + data = authentik_client.models.device_facts.DeviceFacts( + os = null, + disks = [ + authentik_client.models.disk.Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = null, + hardware = null, + software = [ + authentik_client.models.software.Software( + name = '', + version = '', + source = '', + path = '', ) + ], + processes = [ + authentik_client.models.process.Process( + id = 56, + name = '', + user = '', ) + ], + users = [ + authentik_client.models.device_user.DeviceUser( + id = '', + username = '', + name = '', + home = '', ) + ], + groups = [ + authentik_client.models.device_group.DeviceGroup( + id = '', + name = '', ) + ], + vendor = { + 'key' : null + }, ), + connection = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + vendor = null, ), + attributes = { + 'key' : null + } + ) + else: + return EndpointDevice( + pbm_uuid = '', + name = '', + facts = authentik_client.models.device_fact_snapshot.DeviceFactSnapshot( + data = authentik_client.models.device_facts.DeviceFacts( + os = null, + disks = [ + authentik_client.models.disk.Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = null, + hardware = null, + software = [ + authentik_client.models.software.Software( + name = '', + version = '', + source = '', + path = '', ) + ], + processes = [ + authentik_client.models.process.Process( + id = 56, + name = '', + user = '', ) + ], + users = [ + authentik_client.models.device_user.DeviceUser( + id = '', + username = '', + name = '', + home = '', ) + ], + groups = [ + authentik_client.models.device_group.DeviceGroup( + id = '', + name = '', ) + ], + vendor = { + 'key' : null + }, ), + connection = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + vendor = null, ), + ) + """ + + def testEndpointDevice(self): + """Test EndpointDevice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint_device_details.py b/test/test_endpoint_device_details.py new file mode 100644 index 000000000..dd7139fd7 --- /dev/null +++ b/test/test_endpoint_device_details.py @@ -0,0 +1,186 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint_device_details import EndpointDeviceDetails + +class TestEndpointDeviceDetails(unittest.TestCase): + """EndpointDeviceDetails unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EndpointDeviceDetails: + """Test EndpointDeviceDetails + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EndpointDeviceDetails` + """ + model = EndpointDeviceDetails() + if include_optional: + return EndpointDeviceDetails( + device_uuid = '', + pbm_uuid = '', + name = '', + access_group = '', + access_group_obj = authentik_client.models.device_access_group.DeviceAccessGroup( + pbm_uuid = '', + name = '', + attributes = { + 'key' : null + }, ), + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + facts = authentik_client.models.device_fact_snapshot.DeviceFactSnapshot( + data = authentik_client.models.device_facts.DeviceFacts( + os = null, + disks = [ + authentik_client.models.disk.Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = null, + hardware = null, + software = [ + authentik_client.models.software.Software( + name = '', + version = '', + source = '', + path = '', ) + ], + processes = [ + authentik_client.models.process.Process( + id = 56, + name = '', + user = '', ) + ], + users = [ + authentik_client.models.device_user.DeviceUser( + id = '', + username = '', + name = '', + home = '', ) + ], + groups = [ + authentik_client.models.device_group.DeviceGroup( + id = '', + name = '', ) + ], + vendor = { + 'key' : null + }, ), + connection = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + vendor = null, ), + attributes = { + 'key' : null + }, + connections_obj = [ + authentik_client.models.device_connection.DeviceConnection( + device = '', + connector = '', + connector_obj = null, + latest_snapshot = null, ) + ], + policies = [ + '' + ], + connections = [ + '' + ] + ) + else: + return EndpointDeviceDetails( + pbm_uuid = '', + name = '', + facts = authentik_client.models.device_fact_snapshot.DeviceFactSnapshot( + data = authentik_client.models.device_facts.DeviceFacts( + os = null, + disks = [ + authentik_client.models.disk.Disk( + name = '', + mountpoint = '', + label = '', + capacity_total_bytes = 56, + capacity_used_bytes = 56, + encryption_enabled = True, ) + ], + network = null, + hardware = null, + software = [ + authentik_client.models.software.Software( + name = '', + version = '', + source = '', + path = '', ) + ], + processes = [ + authentik_client.models.process.Process( + id = 56, + name = '', + user = '', ) + ], + users = [ + authentik_client.models.device_user.DeviceUser( + id = '', + username = '', + name = '', + home = '', ) + ], + groups = [ + authentik_client.models.device_group.DeviceGroup( + id = '', + name = '', ) + ], + vendor = { + 'key' : null + }, ), + connection = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + vendor = null, ), + connections_obj = [ + authentik_client.models.device_connection.DeviceConnection( + device = '', + connector = '', + connector_obj = null, + latest_snapshot = null, ) + ], + policies = [ + '' + ], + connections = [ + '' + ], + ) + """ + + def testEndpointDeviceDetails(self): + """Test EndpointDeviceDetails""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint_device_request.py b/test/test_endpoint_device_request.py new file mode 100644 index 000000000..a765f134a --- /dev/null +++ b/test/test_endpoint_device_request.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint_device_request import EndpointDeviceRequest + +class TestEndpointDeviceRequest(unittest.TestCase): + """EndpointDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EndpointDeviceRequest: + """Test EndpointDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EndpointDeviceRequest` + """ + model = EndpointDeviceRequest() + if include_optional: + return EndpointDeviceRequest( + device_uuid = '', + name = '0', + access_group = '', + access_group_obj = authentik_client.models.device_access_group_request.DeviceAccessGroupRequest( + name = '0', + attributes = { + 'key' : null + }, ), + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + attributes = { + 'key' : null + } + ) + else: + return EndpointDeviceRequest( + name = '0', + ) + """ + + def testEndpointDeviceRequest(self): + """Test EndpointDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint_request.py b/test/test_endpoint_request.py new file mode 100644 index 000000000..a44a53ebb --- /dev/null +++ b/test/test_endpoint_request.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint_request import EndpointRequest + +class TestEndpointRequest(unittest.TestCase): + """EndpointRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EndpointRequest: + """Test EndpointRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EndpointRequest` + """ + model = EndpointRequest() + if include_optional: + return EndpointRequest( + name = '0', + provider = 56, + protocol = 'rdp', + host = '0', + settings = { + 'key' : null + }, + property_mappings = [ + '' + ], + auth_mode = 'static', + maximum_connections = -2147483648 + ) + else: + return EndpointRequest( + name = '0', + provider = 56, + protocol = 'rdp', + host = '0', + auth_mode = 'static', + ) + """ + + def testEndpointRequest(self): + """Test EndpointRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint_stage.py b/test/test_endpoint_stage.py new file mode 100644 index 000000000..622e84fa8 --- /dev/null +++ b/test/test_endpoint_stage.py @@ -0,0 +1,112 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint_stage import EndpointStage + +class TestEndpointStage(unittest.TestCase): + """EndpointStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EndpointStage: + """Test EndpointStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EndpointStage` + """ + model = EndpointStage() + if include_optional: + return EndpointStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + connector = '', + connector_obj = authentik_client.models.connector.Connector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ), + mode = 'optional' + ) + else: + return EndpointStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + connector = '', + connector_obj = authentik_client.models.connector.Connector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ), + ) + """ + + def testEndpointStage(self): + """Test EndpointStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoint_stage_request.py b/test/test_endpoint_stage_request.py new file mode 100644 index 000000000..084595da5 --- /dev/null +++ b/test/test_endpoint_stage_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.endpoint_stage_request import EndpointStageRequest + +class TestEndpointStageRequest(unittest.TestCase): + """EndpointStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EndpointStageRequest: + """Test EndpointStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EndpointStageRequest` + """ + model = EndpointStageRequest() + if include_optional: + return EndpointStageRequest( + name = '0', + connector = '', + mode = 'optional' + ) + else: + return EndpointStageRequest( + name = '0', + connector = '', + ) + """ + + def testEndpointStageRequest(self): + """Test EndpointStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_endpoints_api.py b/test/test_endpoints_api.py new file mode 100644 index 000000000..27fb5595e --- /dev/null +++ b/test/test_endpoints_api.py @@ -0,0 +1,452 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.endpoints_api import EndpointsApi + + +class TestEndpointsApi(unittest.TestCase): + """EndpointsApi unit test stubs""" + + def setUp(self) -> None: + self.api = EndpointsApi() + + def tearDown(self) -> None: + pass + + def test_endpoints_agents_connectors_agent_config_retrieve(self) -> None: + """Test case for endpoints_agents_connectors_agent_config_retrieve + + """ + pass + + def test_endpoints_agents_connectors_auth_fed_create(self) -> None: + """Test case for endpoints_agents_connectors_auth_fed_create + + """ + pass + + def test_endpoints_agents_connectors_auth_ia_create(self) -> None: + """Test case for endpoints_agents_connectors_auth_ia_create + + """ + pass + + def test_endpoints_agents_connectors_check_in_create(self) -> None: + """Test case for endpoints_agents_connectors_check_in_create + + """ + pass + + def test_endpoints_agents_connectors_create(self) -> None: + """Test case for endpoints_agents_connectors_create + + """ + pass + + def test_endpoints_agents_connectors_destroy(self) -> None: + """Test case for endpoints_agents_connectors_destroy + + """ + pass + + def test_endpoints_agents_connectors_enroll_create(self) -> None: + """Test case for endpoints_agents_connectors_enroll_create + + """ + pass + + def test_endpoints_agents_connectors_list(self) -> None: + """Test case for endpoints_agents_connectors_list + + """ + pass + + def test_endpoints_agents_connectors_mdm_config_create(self) -> None: + """Test case for endpoints_agents_connectors_mdm_config_create + + """ + pass + + def test_endpoints_agents_connectors_partial_update(self) -> None: + """Test case for endpoints_agents_connectors_partial_update + + """ + pass + + def test_endpoints_agents_connectors_retrieve(self) -> None: + """Test case for endpoints_agents_connectors_retrieve + + """ + pass + + def test_endpoints_agents_connectors_update(self) -> None: + """Test case for endpoints_agents_connectors_update + + """ + pass + + def test_endpoints_agents_connectors_used_by_list(self) -> None: + """Test case for endpoints_agents_connectors_used_by_list + + """ + pass + + def test_endpoints_agents_enrollment_tokens_create(self) -> None: + """Test case for endpoints_agents_enrollment_tokens_create + + """ + pass + + def test_endpoints_agents_enrollment_tokens_destroy(self) -> None: + """Test case for endpoints_agents_enrollment_tokens_destroy + + """ + pass + + def test_endpoints_agents_enrollment_tokens_list(self) -> None: + """Test case for endpoints_agents_enrollment_tokens_list + + """ + pass + + def test_endpoints_agents_enrollment_tokens_partial_update(self) -> None: + """Test case for endpoints_agents_enrollment_tokens_partial_update + + """ + pass + + def test_endpoints_agents_enrollment_tokens_retrieve(self) -> None: + """Test case for endpoints_agents_enrollment_tokens_retrieve + + """ + pass + + def test_endpoints_agents_enrollment_tokens_update(self) -> None: + """Test case for endpoints_agents_enrollment_tokens_update + + """ + pass + + def test_endpoints_agents_enrollment_tokens_used_by_list(self) -> None: + """Test case for endpoints_agents_enrollment_tokens_used_by_list + + """ + pass + + def test_endpoints_agents_enrollment_tokens_view_key_retrieve(self) -> None: + """Test case for endpoints_agents_enrollment_tokens_view_key_retrieve + + """ + pass + + def test_endpoints_agents_psso_ise_create(self) -> None: + """Test case for endpoints_agents_psso_ise_create + + """ + pass + + def test_endpoints_agents_psso_ise_destroy(self) -> None: + """Test case for endpoints_agents_psso_ise_destroy + + """ + pass + + def test_endpoints_agents_psso_ise_list(self) -> None: + """Test case for endpoints_agents_psso_ise_list + + """ + pass + + def test_endpoints_agents_psso_ise_partial_update(self) -> None: + """Test case for endpoints_agents_psso_ise_partial_update + + """ + pass + + def test_endpoints_agents_psso_ise_retrieve(self) -> None: + """Test case for endpoints_agents_psso_ise_retrieve + + """ + pass + + def test_endpoints_agents_psso_ise_update(self) -> None: + """Test case for endpoints_agents_psso_ise_update + + """ + pass + + def test_endpoints_agents_psso_ise_used_by_list(self) -> None: + """Test case for endpoints_agents_psso_ise_used_by_list + + """ + pass + + def test_endpoints_agents_psso_register_device_create(self) -> None: + """Test case for endpoints_agents_psso_register_device_create + + """ + pass + + def test_endpoints_agents_psso_register_user_create(self) -> None: + """Test case for endpoints_agents_psso_register_user_create + + """ + pass + + def test_endpoints_connectors_destroy(self) -> None: + """Test case for endpoints_connectors_destroy + + """ + pass + + def test_endpoints_connectors_list(self) -> None: + """Test case for endpoints_connectors_list + + """ + pass + + def test_endpoints_connectors_retrieve(self) -> None: + """Test case for endpoints_connectors_retrieve + + """ + pass + + def test_endpoints_connectors_types_list(self) -> None: + """Test case for endpoints_connectors_types_list + + """ + pass + + def test_endpoints_connectors_used_by_list(self) -> None: + """Test case for endpoints_connectors_used_by_list + + """ + pass + + def test_endpoints_device_access_groups_create(self) -> None: + """Test case for endpoints_device_access_groups_create + + """ + pass + + def test_endpoints_device_access_groups_destroy(self) -> None: + """Test case for endpoints_device_access_groups_destroy + + """ + pass + + def test_endpoints_device_access_groups_list(self) -> None: + """Test case for endpoints_device_access_groups_list + + """ + pass + + def test_endpoints_device_access_groups_partial_update(self) -> None: + """Test case for endpoints_device_access_groups_partial_update + + """ + pass + + def test_endpoints_device_access_groups_retrieve(self) -> None: + """Test case for endpoints_device_access_groups_retrieve + + """ + pass + + def test_endpoints_device_access_groups_update(self) -> None: + """Test case for endpoints_device_access_groups_update + + """ + pass + + def test_endpoints_device_access_groups_used_by_list(self) -> None: + """Test case for endpoints_device_access_groups_used_by_list + + """ + pass + + def test_endpoints_device_bindings_create(self) -> None: + """Test case for endpoints_device_bindings_create + + """ + pass + + def test_endpoints_device_bindings_destroy(self) -> None: + """Test case for endpoints_device_bindings_destroy + + """ + pass + + def test_endpoints_device_bindings_list(self) -> None: + """Test case for endpoints_device_bindings_list + + """ + pass + + def test_endpoints_device_bindings_partial_update(self) -> None: + """Test case for endpoints_device_bindings_partial_update + + """ + pass + + def test_endpoints_device_bindings_retrieve(self) -> None: + """Test case for endpoints_device_bindings_retrieve + + """ + pass + + def test_endpoints_device_bindings_update(self) -> None: + """Test case for endpoints_device_bindings_update + + """ + pass + + def test_endpoints_device_bindings_used_by_list(self) -> None: + """Test case for endpoints_device_bindings_used_by_list + + """ + pass + + def test_endpoints_devices_destroy(self) -> None: + """Test case for endpoints_devices_destroy + + """ + pass + + def test_endpoints_devices_list(self) -> None: + """Test case for endpoints_devices_list + + """ + pass + + def test_endpoints_devices_partial_update(self) -> None: + """Test case for endpoints_devices_partial_update + + """ + pass + + def test_endpoints_devices_retrieve(self) -> None: + """Test case for endpoints_devices_retrieve + + """ + pass + + def test_endpoints_devices_summary_retrieve(self) -> None: + """Test case for endpoints_devices_summary_retrieve + + """ + pass + + def test_endpoints_devices_update(self) -> None: + """Test case for endpoints_devices_update + + """ + pass + + def test_endpoints_devices_used_by_list(self) -> None: + """Test case for endpoints_devices_used_by_list + + """ + pass + + def test_endpoints_fleet_connectors_create(self) -> None: + """Test case for endpoints_fleet_connectors_create + + """ + pass + + def test_endpoints_fleet_connectors_destroy(self) -> None: + """Test case for endpoints_fleet_connectors_destroy + + """ + pass + + def test_endpoints_fleet_connectors_list(self) -> None: + """Test case for endpoints_fleet_connectors_list + + """ + pass + + def test_endpoints_fleet_connectors_partial_update(self) -> None: + """Test case for endpoints_fleet_connectors_partial_update + + """ + pass + + def test_endpoints_fleet_connectors_retrieve(self) -> None: + """Test case for endpoints_fleet_connectors_retrieve + + """ + pass + + def test_endpoints_fleet_connectors_update(self) -> None: + """Test case for endpoints_fleet_connectors_update + + """ + pass + + def test_endpoints_fleet_connectors_used_by_list(self) -> None: + """Test case for endpoints_fleet_connectors_used_by_list + + """ + pass + + def test_endpoints_google_chrome_connectors_create(self) -> None: + """Test case for endpoints_google_chrome_connectors_create + + """ + pass + + def test_endpoints_google_chrome_connectors_destroy(self) -> None: + """Test case for endpoints_google_chrome_connectors_destroy + + """ + pass + + def test_endpoints_google_chrome_connectors_list(self) -> None: + """Test case for endpoints_google_chrome_connectors_list + + """ + pass + + def test_endpoints_google_chrome_connectors_partial_update(self) -> None: + """Test case for endpoints_google_chrome_connectors_partial_update + + """ + pass + + def test_endpoints_google_chrome_connectors_retrieve(self) -> None: + """Test case for endpoints_google_chrome_connectors_retrieve + + """ + pass + + def test_endpoints_google_chrome_connectors_update(self) -> None: + """Test case for endpoints_google_chrome_connectors_update + + """ + pass + + def test_endpoints_google_chrome_connectors_used_by_list(self) -> None: + """Test case for endpoints_google_chrome_connectors_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_enroll_request.py b/test/test_enroll_request.py new file mode 100644 index 000000000..5d86a51f4 --- /dev/null +++ b/test/test_enroll_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.enroll_request import EnrollRequest + +class TestEnrollRequest(unittest.TestCase): + """EnrollRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EnrollRequest: + """Test EnrollRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EnrollRequest` + """ + model = EnrollRequest() + if include_optional: + return EnrollRequest( + device_serial = '0', + device_name = '0' + ) + else: + return EnrollRequest( + device_serial = '0', + device_name = '0', + ) + """ + + def testEnrollRequest(self): + """Test EnrollRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_enrollment_token.py b/test/test_enrollment_token.py new file mode 100644 index 000000000..3e5130427 --- /dev/null +++ b/test/test_enrollment_token.py @@ -0,0 +1,72 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.enrollment_token import EnrollmentToken + +class TestEnrollmentToken(unittest.TestCase): + """EnrollmentToken unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EnrollmentToken: + """Test EnrollmentToken + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EnrollmentToken` + """ + model = EnrollmentToken() + if include_optional: + return EnrollmentToken( + token_uuid = '', + device_group = '', + device_group_obj = authentik_client.models.device_access_group.DeviceAccessGroup( + pbm_uuid = '', + name = '', + attributes = { + 'key' : null + }, ), + connector = '', + name = '', + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return EnrollmentToken( + token_uuid = '', + device_group_obj = authentik_client.models.device_access_group.DeviceAccessGroup( + pbm_uuid = '', + name = '', + attributes = { + 'key' : null + }, ), + connector = '', + name = '', + ) + """ + + def testEnrollmentToken(self): + """Test EnrollmentToken""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_enrollment_token_request.py b/test/test_enrollment_token_request.py new file mode 100644 index 000000000..3d7f467a2 --- /dev/null +++ b/test/test_enrollment_token_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.enrollment_token_request import EnrollmentTokenRequest + +class TestEnrollmentTokenRequest(unittest.TestCase): + """EnrollmentTokenRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EnrollmentTokenRequest: + """Test EnrollmentTokenRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EnrollmentTokenRequest` + """ + model = EnrollmentTokenRequest() + if include_optional: + return EnrollmentTokenRequest( + device_group = '', + connector = '', + name = '0', + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return EnrollmentTokenRequest( + connector = '', + name = '0', + ) + """ + + def testEnrollmentTokenRequest(self): + """Test EnrollmentTokenRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_enterprise_api.py b/test/test_enterprise_api.py new file mode 100644 index 000000000..6f7ff2e3e --- /dev/null +++ b/test/test_enterprise_api.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.enterprise_api import EnterpriseApi + + +class TestEnterpriseApi(unittest.TestCase): + """EnterpriseApi unit test stubs""" + + def setUp(self) -> None: + self.api = EnterpriseApi() + + def tearDown(self) -> None: + pass + + def test_enterprise_license_create(self) -> None: + """Test case for enterprise_license_create + + """ + pass + + def test_enterprise_license_destroy(self) -> None: + """Test case for enterprise_license_destroy + + """ + pass + + def test_enterprise_license_forecast_retrieve(self) -> None: + """Test case for enterprise_license_forecast_retrieve + + """ + pass + + def test_enterprise_license_install_id_retrieve(self) -> None: + """Test case for enterprise_license_install_id_retrieve + + """ + pass + + def test_enterprise_license_list(self) -> None: + """Test case for enterprise_license_list + + """ + pass + + def test_enterprise_license_partial_update(self) -> None: + """Test case for enterprise_license_partial_update + + """ + pass + + def test_enterprise_license_retrieve(self) -> None: + """Test case for enterprise_license_retrieve + + """ + pass + + def test_enterprise_license_summary_retrieve(self) -> None: + """Test case for enterprise_license_summary_retrieve + + """ + pass + + def test_enterprise_license_update(self) -> None: + """Test case for enterprise_license_update + + """ + pass + + def test_enterprise_license_used_by_list(self) -> None: + """Test case for enterprise_license_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_error_detail.py b/test/test_error_detail.py new file mode 100644 index 000000000..05bb4c15b --- /dev/null +++ b/test/test_error_detail.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.error_detail import ErrorDetail + +class TestErrorDetail(unittest.TestCase): + """ErrorDetail unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ErrorDetail: + """Test ErrorDetail + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ErrorDetail` + """ + model = ErrorDetail() + if include_optional: + return ErrorDetail( + string = '', + code = '' + ) + else: + return ErrorDetail( + string = '', + code = '', + ) + """ + + def testErrorDetail(self): + """Test ErrorDetail""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_error_reporting_config.py b/test/test_error_reporting_config.py new file mode 100644 index 000000000..0e558e554 --- /dev/null +++ b/test/test_error_reporting_config.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.error_reporting_config import ErrorReportingConfig + +class TestErrorReportingConfig(unittest.TestCase): + """ErrorReportingConfig unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ErrorReportingConfig: + """Test ErrorReportingConfig + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ErrorReportingConfig` + """ + model = ErrorReportingConfig() + if include_optional: + return ErrorReportingConfig( + enabled = True, + sentry_dsn = '', + environment = '', + send_pii = True, + traces_sample_rate = 1.337 + ) + else: + return ErrorReportingConfig( + enabled = True, + sentry_dsn = '', + environment = '', + send_pii = True, + traces_sample_rate = 1.337, + ) + """ + + def testErrorReportingConfig(self): + """Test ErrorReportingConfig""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_event.py b/test/test_event.py new file mode 100644 index 000000000..4588f92de --- /dev/null +++ b/test/test_event.py @@ -0,0 +1,70 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.event import Event + +class TestEvent(unittest.TestCase): + """Event unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Event: + """Test Event + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Event` + """ + model = Event() + if include_optional: + return Event( + pk = '', + user = { + 'key' : null + }, + action = 'login', + app = '', + context = { + 'key' : null + }, + client_ip = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + } + ) + else: + return Event( + pk = '', + action = 'login', + app = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testEvent(self): + """Test Event""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_event_actions.py b/test/test_event_actions.py new file mode 100644 index 000000000..a41056730 --- /dev/null +++ b/test/test_event_actions.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.event_actions import EventActions + +class TestEventActions(unittest.TestCase): + """EventActions unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testEventActions(self): + """Test EventActions""" + # inst = EventActions() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_event_matcher_policy.py b/test/test_event_matcher_policy.py new file mode 100644 index 000000000..134182c9d --- /dev/null +++ b/test/test_event_matcher_policy.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.event_matcher_policy import EventMatcherPolicy + +class TestEventMatcherPolicy(unittest.TestCase): + """EventMatcherPolicy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EventMatcherPolicy: + """Test EventMatcherPolicy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EventMatcherPolicy` + """ + model = EventMatcherPolicy() + if include_optional: + return EventMatcherPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + action = 'login', + client_ip = '', + app = 'authentik.commands', + model = 'authentik_tenants.domain', + query = '' + ) + else: + return EventMatcherPolicy( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + ) + """ + + def testEventMatcherPolicy(self): + """Test EventMatcherPolicy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_event_matcher_policy_request.py b/test/test_event_matcher_policy_request.py new file mode 100644 index 000000000..032181df0 --- /dev/null +++ b/test/test_event_matcher_policy_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.event_matcher_policy_request import EventMatcherPolicyRequest + +class TestEventMatcherPolicyRequest(unittest.TestCase): + """EventMatcherPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EventMatcherPolicyRequest: + """Test EventMatcherPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EventMatcherPolicyRequest` + """ + model = EventMatcherPolicyRequest() + if include_optional: + return EventMatcherPolicyRequest( + name = '0', + execution_logging = True, + action = 'login', + client_ip = '0', + app = 'authentik.commands', + model = 'authentik_tenants.domain', + query = '0' + ) + else: + return EventMatcherPolicyRequest( + name = '0', + ) + """ + + def testEventMatcherPolicyRequest(self): + """Test EventMatcherPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_event_request.py b/test/test_event_request.py new file mode 100644 index 000000000..6d9b362f5 --- /dev/null +++ b/test/test_event_request.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.event_request import EventRequest + +class TestEventRequest(unittest.TestCase): + """EventRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EventRequest: + """Test EventRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EventRequest` + """ + model = EventRequest() + if include_optional: + return EventRequest( + user = { + 'key' : null + }, + action = 'login', + app = '0', + context = { + 'key' : null + }, + client_ip = '0', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + } + ) + else: + return EventRequest( + action = 'login', + app = '0', + ) + """ + + def testEventRequest(self): + """Test EventRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_event_stats.py b/test/test_event_stats.py new file mode 100644 index 000000000..b3a33335d --- /dev/null +++ b/test/test_event_stats.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.event_stats import EventStats + +class TestEventStats(unittest.TestCase): + """EventStats unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EventStats: + """Test EventStats + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EventStats` + """ + model = EventStats() + if include_optional: + return EventStats( + unique_users = 56, + count_step = { + 'key' : null + } + ) + else: + return EventStats( + unique_users = 56, + count_step = { + 'key' : null + }, + ) + """ + + def testEventStats(self): + """Test EventStats""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_event_top_per_user.py b/test/test_event_top_per_user.py new file mode 100644 index 000000000..af7628ad0 --- /dev/null +++ b/test/test_event_top_per_user.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.event_top_per_user import EventTopPerUser + +class TestEventTopPerUser(unittest.TestCase): + """EventTopPerUser unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EventTopPerUser: + """Test EventTopPerUser + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EventTopPerUser` + """ + model = EventTopPerUser() + if include_optional: + return EventTopPerUser( + application = { + 'key' : null + }, + counted_events = 56, + unique_users = 56 + ) + else: + return EventTopPerUser( + application = { + 'key' : null + }, + counted_events = 56, + unique_users = 56, + ) + """ + + def testEventTopPerUser(self): + """Test EventTopPerUser""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_event_volume.py b/test/test_event_volume.py new file mode 100644 index 000000000..3b69a8dc9 --- /dev/null +++ b/test/test_event_volume.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.event_volume import EventVolume + +class TestEventVolume(unittest.TestCase): + """EventVolume unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> EventVolume: + """Test EventVolume + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `EventVolume` + """ + model = EventVolume() + if include_optional: + return EventVolume( + action = 'login', + time = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + count = 56 + ) + else: + return EventVolume( + action = 'login', + time = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + count = 56, + ) + """ + + def testEventVolume(self): + """Test EventVolume""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_events_api.py b/test/test_events_api.py new file mode 100644 index 000000000..1cfffe8c5 --- /dev/null +++ b/test/test_events_api.py @@ -0,0 +1,230 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.events_api import EventsApi + + +class TestEventsApi(unittest.TestCase): + """EventsApi unit test stubs""" + + def setUp(self) -> None: + self.api = EventsApi() + + def tearDown(self) -> None: + pass + + def test_events_events_actions_list(self) -> None: + """Test case for events_events_actions_list + + """ + pass + + def test_events_events_create(self) -> None: + """Test case for events_events_create + + """ + pass + + def test_events_events_destroy(self) -> None: + """Test case for events_events_destroy + + """ + pass + + def test_events_events_export_create(self) -> None: + """Test case for events_events_export_create + + """ + pass + + def test_events_events_list(self) -> None: + """Test case for events_events_list + + """ + pass + + def test_events_events_partial_update(self) -> None: + """Test case for events_events_partial_update + + """ + pass + + def test_events_events_retrieve(self) -> None: + """Test case for events_events_retrieve + + """ + pass + + def test_events_events_stats_retrieve(self) -> None: + """Test case for events_events_stats_retrieve + + """ + pass + + def test_events_events_top_per_user_list(self) -> None: + """Test case for events_events_top_per_user_list + + """ + pass + + def test_events_events_update(self) -> None: + """Test case for events_events_update + + """ + pass + + def test_events_events_volume_list(self) -> None: + """Test case for events_events_volume_list + + """ + pass + + def test_events_notifications_destroy(self) -> None: + """Test case for events_notifications_destroy + + """ + pass + + def test_events_notifications_list(self) -> None: + """Test case for events_notifications_list + + """ + pass + + def test_events_notifications_mark_all_seen_create(self) -> None: + """Test case for events_notifications_mark_all_seen_create + + """ + pass + + def test_events_notifications_partial_update(self) -> None: + """Test case for events_notifications_partial_update + + """ + pass + + def test_events_notifications_retrieve(self) -> None: + """Test case for events_notifications_retrieve + + """ + pass + + def test_events_notifications_update(self) -> None: + """Test case for events_notifications_update + + """ + pass + + def test_events_notifications_used_by_list(self) -> None: + """Test case for events_notifications_used_by_list + + """ + pass + + def test_events_rules_create(self) -> None: + """Test case for events_rules_create + + """ + pass + + def test_events_rules_destroy(self) -> None: + """Test case for events_rules_destroy + + """ + pass + + def test_events_rules_list(self) -> None: + """Test case for events_rules_list + + """ + pass + + def test_events_rules_partial_update(self) -> None: + """Test case for events_rules_partial_update + + """ + pass + + def test_events_rules_retrieve(self) -> None: + """Test case for events_rules_retrieve + + """ + pass + + def test_events_rules_update(self) -> None: + """Test case for events_rules_update + + """ + pass + + def test_events_rules_used_by_list(self) -> None: + """Test case for events_rules_used_by_list + + """ + pass + + def test_events_transports_create(self) -> None: + """Test case for events_transports_create + + """ + pass + + def test_events_transports_destroy(self) -> None: + """Test case for events_transports_destroy + + """ + pass + + def test_events_transports_list(self) -> None: + """Test case for events_transports_list + + """ + pass + + def test_events_transports_partial_update(self) -> None: + """Test case for events_transports_partial_update + + """ + pass + + def test_events_transports_retrieve(self) -> None: + """Test case for events_transports_retrieve + + """ + pass + + def test_events_transports_test_create(self) -> None: + """Test case for events_transports_test_create + + """ + pass + + def test_events_transports_update(self) -> None: + """Test case for events_transports_update + + """ + pass + + def test_events_transports_used_by_list(self) -> None: + """Test case for events_transports_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_events_requested_enum.py b/test/test_events_requested_enum.py new file mode 100644 index 000000000..b5b4c0d83 --- /dev/null +++ b/test/test_events_requested_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.events_requested_enum import EventsRequestedEnum + +class TestEventsRequestedEnum(unittest.TestCase): + """EventsRequestedEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testEventsRequestedEnum(self): + """Test EventsRequestedEnum""" + # inst = EventsRequestedEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_expiring_base_grant_model.py b/test/test_expiring_base_grant_model.py new file mode 100644 index 000000000..442684b9e --- /dev/null +++ b/test/test_expiring_base_grant_model.py @@ -0,0 +1,234 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.expiring_base_grant_model import ExpiringBaseGrantModel + +class TestExpiringBaseGrantModel(unittest.TestCase): + """ExpiringBaseGrantModel unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ExpiringBaseGrantModel: + """Test ExpiringBaseGrantModel + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ExpiringBaseGrantModel` + """ + model = ExpiringBaseGrantModel() + if include_optional: + return ExpiringBaseGrantModel( + pk = 56, + provider = authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ), + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + is_expired = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + scope = [ + '' + ] + ) + else: + return ExpiringBaseGrantModel( + pk = 56, + provider = authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ), + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + is_expired = True, + scope = [ + '' + ], + ) + """ + + def testExpiringBaseGrantModel(self): + """Test ExpiringBaseGrantModel""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_expression_policy.py b/test/test_expression_policy.py new file mode 100644 index 000000000..bf278fe56 --- /dev/null +++ b/test/test_expression_policy.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.expression_policy import ExpressionPolicy + +class TestExpressionPolicy(unittest.TestCase): + """ExpressionPolicy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ExpressionPolicy: + """Test ExpressionPolicy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ExpressionPolicy` + """ + model = ExpressionPolicy() + if include_optional: + return ExpressionPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + expression = '' + ) + else: + return ExpressionPolicy( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + expression = '', + ) + """ + + def testExpressionPolicy(self): + """Test ExpressionPolicy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_expression_policy_request.py b/test/test_expression_policy_request.py new file mode 100644 index 000000000..92f65cf60 --- /dev/null +++ b/test/test_expression_policy_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.expression_policy_request import ExpressionPolicyRequest + +class TestExpressionPolicyRequest(unittest.TestCase): + """ExpressionPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ExpressionPolicyRequest: + """Test ExpressionPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ExpressionPolicyRequest` + """ + model = ExpressionPolicyRequest() + if include_optional: + return ExpressionPolicyRequest( + name = '0', + execution_logging = True, + expression = '0' + ) + else: + return ExpressionPolicyRequest( + name = '0', + expression = '0', + ) + """ + + def testExpressionPolicyRequest(self): + """Test ExpressionPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_extra_role_object_permission.py b/test/test_extra_role_object_permission.py new file mode 100644 index 000000000..b583267ef --- /dev/null +++ b/test/test_extra_role_object_permission.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.extra_role_object_permission import ExtraRoleObjectPermission + +class TestExtraRoleObjectPermission(unittest.TestCase): + """ExtraRoleObjectPermission unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ExtraRoleObjectPermission: + """Test ExtraRoleObjectPermission + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ExtraRoleObjectPermission` + """ + model = ExtraRoleObjectPermission() + if include_optional: + return ExtraRoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '', + app_label_verbose = '', + model_verbose = '', + object_description = '' + ) + else: + return ExtraRoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '', + app_label_verbose = '', + model_verbose = '', + object_description = '', + ) + """ + + def testExtraRoleObjectPermission(self): + """Test ExtraRoleObjectPermission""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_file_list.py b/test/test_file_list.py new file mode 100644 index 000000000..2ef48040b --- /dev/null +++ b/test/test_file_list.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.file_list import FileList + +class TestFileList(unittest.TestCase): + """FileList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FileList: + """Test FileList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FileList` + """ + model = FileList() + if include_optional: + return FileList( + name = '', + mime_type = '', + url = '', + themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ) + ) + else: + return FileList( + name = '', + mime_type = '', + url = '', + ) + """ + + def testFileList(self): + """Test FileList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_fleet_connector.py b/test/test_fleet_connector.py new file mode 100644 index 000000000..5a82b6b5f --- /dev/null +++ b/test/test_fleet_connector.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.fleet_connector import FleetConnector + +class TestFleetConnector(unittest.TestCase): + """FleetConnector unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FleetConnector: + """Test FleetConnector + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FleetConnector` + """ + model = FleetConnector() + if include_optional: + return FleetConnector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + headers_mapping = '', + map_users = True, + map_teams_access_group = True + ) + else: + return FleetConnector( + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + ) + """ + + def testFleetConnector(self): + """Test FleetConnector""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_fleet_connector_request.py b/test/test_fleet_connector_request.py new file mode 100644 index 000000000..d5278d87e --- /dev/null +++ b/test/test_fleet_connector_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.fleet_connector_request import FleetConnectorRequest + +class TestFleetConnectorRequest(unittest.TestCase): + """FleetConnectorRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FleetConnectorRequest: + """Test FleetConnectorRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FleetConnectorRequest` + """ + model = FleetConnectorRequest() + if include_optional: + return FleetConnectorRequest( + connector_uuid = '', + name = '0', + enabled = True, + url = '0', + token = '0', + headers_mapping = '', + map_users = True, + map_teams_access_group = True + ) + else: + return FleetConnectorRequest( + name = '0', + url = '0', + token = '0', + ) + """ + + def testFleetConnectorRequest(self): + """Test FleetConnectorRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow.py b/test/test_flow.py new file mode 100644 index 000000000..449993700 --- /dev/null +++ b/test/test_flow.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow import Flow + +class TestFlow(unittest.TestCase): + """Flow unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Flow: + """Test Flow + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Flow` + """ + model = Flow() + if include_optional: + return Flow( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = 'authentication', + background = '', + background_url = '', + background_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + stages = [ + '' + ], + policies = [ + '' + ], + cache_count = 56, + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = 'message_continue', + authentication = 'none' + ) + else: + return Flow( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = 'authentication', + background_url = '', + background_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + stages = [ + '' + ], + policies = [ + '' + ], + cache_count = 56, + export_url = '', + ) + """ + + def testFlow(self): + """Test Flow""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_challenge_response_request.py b/test/test_flow_challenge_response_request.py new file mode 100644 index 000000000..40b921389 --- /dev/null +++ b/test/test_flow_challenge_response_request.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_challenge_response_request import FlowChallengeResponseRequest + +class TestFlowChallengeResponseRequest(unittest.TestCase): + """FlowChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FlowChallengeResponseRequest: + """Test FlowChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FlowChallengeResponseRequest` + """ + model = FlowChallengeResponseRequest() + if include_optional: + return FlowChallengeResponseRequest( + component = 'ak-stage-user-login', + code = '0', + email = '0', + phone_number = '0', + selected_challenge = authentik_client.models.device_challenge_request.DeviceChallengeRequest( + device_class = 'static', + device_uid = '0', + challenge = { + 'key' : null + }, + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + selected_stage = '0', + webauthn = { + 'key' : None + }, + duo = 56, + response = '0', + token = '0', + uid_field = '', + password = '0', + captcha_token = '', + passkey = { + 'key' : None + }, + to = '0', + id = 56, + first_name = '0', + last_name = '0', + username = '0', + photo_url = '0', + auth_date = 56, + hash = '0', + remember_me = True + ) + else: + return FlowChallengeResponseRequest( + code = '0', + response = '0', + token = '0', + password = '0', + to = '0', + id = 56, + auth_date = 56, + hash = '0', + remember_me = True, + ) + """ + + def testFlowChallengeResponseRequest(self): + """Test FlowChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_designation_enum.py b/test/test_flow_designation_enum.py new file mode 100644 index 000000000..e7181e19a --- /dev/null +++ b/test/test_flow_designation_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_designation_enum import FlowDesignationEnum + +class TestFlowDesignationEnum(unittest.TestCase): + """FlowDesignationEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testFlowDesignationEnum(self): + """Test FlowDesignationEnum""" + # inst = FlowDesignationEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_diagram.py b/test/test_flow_diagram.py new file mode 100644 index 000000000..45cd49084 --- /dev/null +++ b/test/test_flow_diagram.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_diagram import FlowDiagram + +class TestFlowDiagram(unittest.TestCase): + """FlowDiagram unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FlowDiagram: + """Test FlowDiagram + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FlowDiagram` + """ + model = FlowDiagram() + if include_optional: + return FlowDiagram( + diagram = '' + ) + else: + return FlowDiagram( + diagram = '', + ) + """ + + def testFlowDiagram(self): + """Test FlowDiagram""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_error_challenge.py b/test/test_flow_error_challenge.py new file mode 100644 index 000000000..1693c556c --- /dev/null +++ b/test/test_flow_error_challenge.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_error_challenge import FlowErrorChallenge + +class TestFlowErrorChallenge(unittest.TestCase): + """FlowErrorChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FlowErrorChallenge: + """Test FlowErrorChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FlowErrorChallenge` + """ + model = FlowErrorChallenge() + if include_optional: + return FlowErrorChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-flow-error', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + request_id = '', + error = '', + traceback = '' + ) + else: + return FlowErrorChallenge( + request_id = '', + ) + """ + + def testFlowErrorChallenge(self): + """Test FlowErrorChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_inspection.py b/test/test_flow_inspection.py new file mode 100644 index 000000000..72b145fcf --- /dev/null +++ b/test/test_flow_inspection.py @@ -0,0 +1,78 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_inspection import FlowInspection + +class TestFlowInspection(unittest.TestCase): + """FlowInspection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FlowInspection: + """Test FlowInspection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FlowInspection` + """ + model = FlowInspection() + if include_optional: + return FlowInspection( + plans = [ + authentik_client.models.flow_inspector_plan.FlowInspectorPlan( + current_stage = null, + next_planned_stage = null, + plan_context = { + 'key' : null + }, + session_id = '', ) + ], + current_plan = authentik_client.models.flow_inspector_plan.FlowInspectorPlan( + current_stage = null, + next_planned_stage = null, + plan_context = { + 'key' : null + }, + session_id = '', ), + is_completed = True + ) + else: + return FlowInspection( + plans = [ + authentik_client.models.flow_inspector_plan.FlowInspectorPlan( + current_stage = null, + next_planned_stage = null, + plan_context = { + 'key' : null + }, + session_id = '', ) + ], + is_completed = True, + ) + """ + + def testFlowInspection(self): + """Test FlowInspection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_inspector_plan.py b/test/test_flow_inspector_plan.py new file mode 100644 index 000000000..815aca93b --- /dev/null +++ b/test/test_flow_inspector_plan.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_inspector_plan import FlowInspectorPlan + +class TestFlowInspectorPlan(unittest.TestCase): + """FlowInspectorPlan unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FlowInspectorPlan: + """Test FlowInspectorPlan + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FlowInspectorPlan` + """ + model = FlowInspectorPlan() + if include_optional: + return FlowInspectorPlan( + current_stage = authentik_client.models.flow_stage_binding.FlowStageBinding( + pk = '', + policybindingmodel_ptr_id = '', + target = '', + stage = '', + stage_obj = null, + evaluate_on_plan = True, + re_evaluate_policies = True, + order = -2147483648, + policy_engine_mode = 'all', + invalid_response_action = null, ), + next_planned_stage = authentik_client.models.flow_stage_binding.FlowStageBinding( + pk = '', + policybindingmodel_ptr_id = '', + target = '', + stage = '', + stage_obj = null, + evaluate_on_plan = True, + re_evaluate_policies = True, + order = -2147483648, + policy_engine_mode = 'all', + invalid_response_action = null, ), + plan_context = { + 'key' : null + }, + session_id = '' + ) + else: + return FlowInspectorPlan( + current_stage = authentik_client.models.flow_stage_binding.FlowStageBinding( + pk = '', + policybindingmodel_ptr_id = '', + target = '', + stage = '', + stage_obj = null, + evaluate_on_plan = True, + re_evaluate_policies = True, + order = -2147483648, + policy_engine_mode = 'all', + invalid_response_action = null, ), + next_planned_stage = authentik_client.models.flow_stage_binding.FlowStageBinding( + pk = '', + policybindingmodel_ptr_id = '', + target = '', + stage = '', + stage_obj = null, + evaluate_on_plan = True, + re_evaluate_policies = True, + order = -2147483648, + policy_engine_mode = 'all', + invalid_response_action = null, ), + plan_context = { + 'key' : null + }, + session_id = '', + ) + """ + + def testFlowInspectorPlan(self): + """Test FlowInspectorPlan""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_layout_enum.py b/test/test_flow_layout_enum.py new file mode 100644 index 000000000..50dff7963 --- /dev/null +++ b/test/test_flow_layout_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_layout_enum import FlowLayoutEnum + +class TestFlowLayoutEnum(unittest.TestCase): + """FlowLayoutEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testFlowLayoutEnum(self): + """Test FlowLayoutEnum""" + # inst = FlowLayoutEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_request.py b/test/test_flow_request.py new file mode 100644 index 000000000..a6ab3ce8e --- /dev/null +++ b/test/test_flow_request.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_request import FlowRequest + +class TestFlowRequest(unittest.TestCase): + """FlowRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FlowRequest: + """Test FlowRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FlowRequest` + """ + model = FlowRequest() + if include_optional: + return FlowRequest( + name = '0', + slug = 'z0', + title = '0', + designation = 'authentication', + background = '', + policy_engine_mode = 'all', + compatibility_mode = True, + layout = 'stacked', + denied_action = 'message_continue', + authentication = 'none' + ) + else: + return FlowRequest( + name = '0', + slug = 'z0', + title = '0', + designation = 'authentication', + ) + """ + + def testFlowRequest(self): + """Test FlowRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_set.py b/test/test_flow_set.py new file mode 100644 index 000000000..18192509a --- /dev/null +++ b/test/test_flow_set.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_set import FlowSet + +class TestFlowSet(unittest.TestCase): + """FlowSet unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FlowSet: + """Test FlowSet + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FlowSet` + """ + model = FlowSet() + if include_optional: + return FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = 'authentication', + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = 'message_continue' + ) + else: + return FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = 'authentication', + background_url = '', + export_url = '', + ) + """ + + def testFlowSet(self): + """Test FlowSet""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_stage_binding.py b/test/test_flow_stage_binding.py new file mode 100644 index 000000000..e596ee392 --- /dev/null +++ b/test/test_flow_stage_binding.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_stage_binding import FlowStageBinding + +class TestFlowStageBinding(unittest.TestCase): + """FlowStageBinding unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FlowStageBinding: + """Test FlowStageBinding + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FlowStageBinding` + """ + model = FlowStageBinding() + if include_optional: + return FlowStageBinding( + pk = '', + policybindingmodel_ptr_id = '', + target = '', + stage = '', + stage_obj = authentik_client.models.stage.Stage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], ), + evaluate_on_plan = True, + re_evaluate_policies = True, + order = -2147483648, + policy_engine_mode = 'all', + invalid_response_action = 'retry' + ) + else: + return FlowStageBinding( + pk = '', + policybindingmodel_ptr_id = '', + target = '', + stage = '', + stage_obj = authentik_client.models.stage.Stage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], ), + order = -2147483648, + ) + """ + + def testFlowStageBinding(self): + """Test FlowStageBinding""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flow_stage_binding_request.py b/test/test_flow_stage_binding_request.py new file mode 100644 index 000000000..79566e9c0 --- /dev/null +++ b/test/test_flow_stage_binding_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.flow_stage_binding_request import FlowStageBindingRequest + +class TestFlowStageBindingRequest(unittest.TestCase): + """FlowStageBindingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FlowStageBindingRequest: + """Test FlowStageBindingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FlowStageBindingRequest` + """ + model = FlowStageBindingRequest() + if include_optional: + return FlowStageBindingRequest( + target = '', + stage = '', + evaluate_on_plan = True, + re_evaluate_policies = True, + order = -2147483648, + policy_engine_mode = 'all', + invalid_response_action = 'retry' + ) + else: + return FlowStageBindingRequest( + target = '', + stage = '', + order = -2147483648, + ) + """ + + def testFlowStageBindingRequest(self): + """Test FlowStageBindingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_flows_api.py b/test/test_flows_api.py new file mode 100644 index 000000000..8ffd7d6fc --- /dev/null +++ b/test/test_flows_api.py @@ -0,0 +1,164 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.flows_api import FlowsApi + + +class TestFlowsApi(unittest.TestCase): + """FlowsApi unit test stubs""" + + def setUp(self) -> None: + self.api = FlowsApi() + + def tearDown(self) -> None: + pass + + def test_flows_bindings_create(self) -> None: + """Test case for flows_bindings_create + + """ + pass + + def test_flows_bindings_destroy(self) -> None: + """Test case for flows_bindings_destroy + + """ + pass + + def test_flows_bindings_list(self) -> None: + """Test case for flows_bindings_list + + """ + pass + + def test_flows_bindings_partial_update(self) -> None: + """Test case for flows_bindings_partial_update + + """ + pass + + def test_flows_bindings_retrieve(self) -> None: + """Test case for flows_bindings_retrieve + + """ + pass + + def test_flows_bindings_update(self) -> None: + """Test case for flows_bindings_update + + """ + pass + + def test_flows_bindings_used_by_list(self) -> None: + """Test case for flows_bindings_used_by_list + + """ + pass + + def test_flows_executor_get(self) -> None: + """Test case for flows_executor_get + + """ + pass + + def test_flows_executor_solve(self) -> None: + """Test case for flows_executor_solve + + """ + pass + + def test_flows_inspector_get(self) -> None: + """Test case for flows_inspector_get + + """ + pass + + def test_flows_instances_cache_clear_create(self) -> None: + """Test case for flows_instances_cache_clear_create + + """ + pass + + def test_flows_instances_cache_info_retrieve(self) -> None: + """Test case for flows_instances_cache_info_retrieve + + """ + pass + + def test_flows_instances_create(self) -> None: + """Test case for flows_instances_create + + """ + pass + + def test_flows_instances_destroy(self) -> None: + """Test case for flows_instances_destroy + + """ + pass + + def test_flows_instances_diagram_retrieve(self) -> None: + """Test case for flows_instances_diagram_retrieve + + """ + pass + + def test_flows_instances_execute_retrieve(self) -> None: + """Test case for flows_instances_execute_retrieve + + """ + pass + + def test_flows_instances_export_retrieve(self) -> None: + """Test case for flows_instances_export_retrieve + + """ + pass + + def test_flows_instances_list(self) -> None: + """Test case for flows_instances_list + + """ + pass + + def test_flows_instances_partial_update(self) -> None: + """Test case for flows_instances_partial_update + + """ + pass + + def test_flows_instances_retrieve(self) -> None: + """Test case for flows_instances_retrieve + + """ + pass + + def test_flows_instances_update(self) -> None: + """Test case for flows_instances_update + + """ + pass + + def test_flows_instances_used_by_list(self) -> None: + """Test case for flows_instances_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_footer_link.py b/test/test_footer_link.py new file mode 100644 index 000000000..caa28d0b2 --- /dev/null +++ b/test/test_footer_link.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.footer_link import FooterLink + +class TestFooterLink(unittest.TestCase): + """FooterLink unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FooterLink: + """Test FooterLink + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FooterLink` + """ + model = FooterLink() + if include_optional: + return FooterLink( + href = '', + name = '' + ) + else: + return FooterLink( + href = '', + name = '', + ) + """ + + def testFooterLink(self): + """Test FooterLink""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_force_binding_enum.py b/test/test_force_binding_enum.py new file mode 100644 index 000000000..ce615c296 --- /dev/null +++ b/test/test_force_binding_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.force_binding_enum import ForceBindingEnum + +class TestForceBindingEnum(unittest.TestCase): + """ForceBindingEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testForceBindingEnum(self): + """Test ForceBindingEnum""" + # inst = ForceBindingEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_format_enum.py b/test/test_format_enum.py new file mode 100644 index 000000000..a734b0d70 --- /dev/null +++ b/test/test_format_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.format_enum import FormatEnum + +class TestFormatEnum(unittest.TestCase): + """FormatEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testFormatEnum(self): + """Test FormatEnum""" + # inst = FormatEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_frame_challenge.py b/test/test_frame_challenge.py new file mode 100644 index 000000000..2022aad4c --- /dev/null +++ b/test/test_frame_challenge.py @@ -0,0 +1,70 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.frame_challenge import FrameChallenge + +class TestFrameChallenge(unittest.TestCase): + """FrameChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FrameChallenge: + """Test FrameChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FrameChallenge` + """ + model = FrameChallenge() + if include_optional: + return FrameChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'xak-flow-frame', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + url = '', + loading_overlay = True, + loading_text = '' + ) + else: + return FrameChallenge( + url = '', + loading_text = '', + ) + """ + + def testFrameChallenge(self): + """Test FrameChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_frame_challenge_response_request.py b/test/test_frame_challenge_response_request.py new file mode 100644 index 000000000..7d5e8d1f8 --- /dev/null +++ b/test/test_frame_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.frame_challenge_response_request import FrameChallengeResponseRequest + +class TestFrameChallengeResponseRequest(unittest.TestCase): + """FrameChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> FrameChallengeResponseRequest: + """Test FrameChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `FrameChallengeResponseRequest` + """ + model = FrameChallengeResponseRequest() + if include_optional: + return FrameChallengeResponseRequest( + component = 'xak-flow-frame' + ) + else: + return FrameChallengeResponseRequest( + ) + """ + + def testFrameChallengeResponseRequest(self): + """Test FrameChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_generic_error.py b/test/test_generic_error.py new file mode 100644 index 000000000..117a1d52e --- /dev/null +++ b/test/test_generic_error.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.generic_error import GenericError + +class TestGenericError(unittest.TestCase): + """GenericError unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GenericError: + """Test GenericError + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GenericError` + """ + model = GenericError() + if include_optional: + return GenericError( + detail = '', + code = '' + ) + else: + return GenericError( + detail = '', + ) + """ + + def testGenericError(self): + """Test GenericError""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_geo_ip_policy.py b/test/test_geo_ip_policy.py new file mode 100644 index 000000000..7e6b58334 --- /dev/null +++ b/test/test_geo_ip_policy.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.geo_ip_policy import GeoIPPolicy + +class TestGeoIPPolicy(unittest.TestCase): + """GeoIPPolicy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GeoIPPolicy: + """Test GeoIPPolicy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GeoIPPolicy` + """ + model = GeoIPPolicy() + if include_optional: + return GeoIPPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + asns = [ + -2147483648 + ], + countries = [ + 'AF' + ], + countries_obj = [ + authentik_client.models.geo_ip_policy_countries_obj_inner.GeoIPPolicy_countries_obj_inner( + code = '01', + name = '', ) + ], + check_history_distance = True, + history_max_distance_km = 0, + distance_tolerance_km = 0, + history_login_count = 0, + check_impossible_travel = True, + impossible_tolerance_km = 0 + ) + else: + return GeoIPPolicy( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + countries = [ + 'AF' + ], + countries_obj = [ + authentik_client.models.geo_ip_policy_countries_obj_inner.GeoIPPolicy_countries_obj_inner( + code = '01', + name = '', ) + ], + ) + """ + + def testGeoIPPolicy(self): + """Test GeoIPPolicy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_geo_ip_policy_countries_obj_inner.py b/test/test_geo_ip_policy_countries_obj_inner.py new file mode 100644 index 000000000..05975e0e3 --- /dev/null +++ b/test/test_geo_ip_policy_countries_obj_inner.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.geo_ip_policy_countries_obj_inner import GeoIPPolicyCountriesObjInner + +class TestGeoIPPolicyCountriesObjInner(unittest.TestCase): + """GeoIPPolicyCountriesObjInner unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GeoIPPolicyCountriesObjInner: + """Test GeoIPPolicyCountriesObjInner + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GeoIPPolicyCountriesObjInner` + """ + model = GeoIPPolicyCountriesObjInner() + if include_optional: + return GeoIPPolicyCountriesObjInner( + code = '01', + name = '' + ) + else: + return GeoIPPolicyCountriesObjInner( + code = '01', + name = '', + ) + """ + + def testGeoIPPolicyCountriesObjInner(self): + """Test GeoIPPolicyCountriesObjInner""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_geo_ip_policy_request.py b/test/test_geo_ip_policy_request.py new file mode 100644 index 000000000..ed62997f3 --- /dev/null +++ b/test/test_geo_ip_policy_request.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.geo_ip_policy_request import GeoIPPolicyRequest + +class TestGeoIPPolicyRequest(unittest.TestCase): + """GeoIPPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GeoIPPolicyRequest: + """Test GeoIPPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GeoIPPolicyRequest` + """ + model = GeoIPPolicyRequest() + if include_optional: + return GeoIPPolicyRequest( + name = '0', + execution_logging = True, + asns = [ + -2147483648 + ], + countries = [ + 'AF' + ], + check_history_distance = True, + history_max_distance_km = 0, + distance_tolerance_km = 0, + history_login_count = 0, + check_impossible_travel = True, + impossible_tolerance_km = 0 + ) + else: + return GeoIPPolicyRequest( + name = '0', + countries = [ + 'AF' + ], + ) + """ + + def testGeoIPPolicyRequest(self): + """Test GeoIPPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_geoip_binding_enum.py b/test/test_geoip_binding_enum.py new file mode 100644 index 000000000..f78e2f6f6 --- /dev/null +++ b/test/test_geoip_binding_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.geoip_binding_enum import GeoipBindingEnum + +class TestGeoipBindingEnum(unittest.TestCase): + """GeoipBindingEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testGeoipBindingEnum(self): + """Test GeoipBindingEnum""" + # inst = GeoipBindingEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_global_task_status.py b/test/test_global_task_status.py new file mode 100644 index 000000000..e3677c827 --- /dev/null +++ b/test/test_global_task_status.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.global_task_status import GlobalTaskStatus + +class TestGlobalTaskStatus(unittest.TestCase): + """GlobalTaskStatus unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GlobalTaskStatus: + """Test GlobalTaskStatus + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GlobalTaskStatus` + """ + model = GlobalTaskStatus() + if include_optional: + return GlobalTaskStatus( + queued = 56, + consumed = 56, + preprocess = 56, + running = 56, + postprocess = 56, + rejected = 56, + done = 56, + info = 56, + warning = 56, + error = 56 + ) + else: + return GlobalTaskStatus( + queued = 56, + consumed = 56, + preprocess = 56, + running = 56, + postprocess = 56, + rejected = 56, + done = 56, + info = 56, + warning = 56, + error = 56, + ) + """ + + def testGlobalTaskStatus(self): + """Test GlobalTaskStatus""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_chrome_connector.py b/test/test_google_chrome_connector.py new file mode 100644 index 000000000..378435bb2 --- /dev/null +++ b/test/test_google_chrome_connector.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_chrome_connector import GoogleChromeConnector + +class TestGoogleChromeConnector(unittest.TestCase): + """GoogleChromeConnector unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleChromeConnector: + """Test GoogleChromeConnector + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleChromeConnector` + """ + model = GoogleChromeConnector() + if include_optional: + return GoogleChromeConnector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + credentials = { + 'key' : null + }, + chrome_url = '' + ) + else: + return GoogleChromeConnector( + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + credentials = { + 'key' : null + }, + chrome_url = '', + ) + """ + + def testGoogleChromeConnector(self): + """Test GoogleChromeConnector""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_chrome_connector_request.py b/test/test_google_chrome_connector_request.py new file mode 100644 index 000000000..e493f47a9 --- /dev/null +++ b/test/test_google_chrome_connector_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_chrome_connector_request import GoogleChromeConnectorRequest + +class TestGoogleChromeConnectorRequest(unittest.TestCase): + """GoogleChromeConnectorRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleChromeConnectorRequest: + """Test GoogleChromeConnectorRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleChromeConnectorRequest` + """ + model = GoogleChromeConnectorRequest() + if include_optional: + return GoogleChromeConnectorRequest( + connector_uuid = '', + name = '0', + enabled = True, + credentials = { + 'key' : null + } + ) + else: + return GoogleChromeConnectorRequest( + name = '0', + credentials = { + 'key' : null + }, + ) + """ + + def testGoogleChromeConnectorRequest(self): + """Test GoogleChromeConnectorRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_endpoint_device.py b/test/test_google_endpoint_device.py new file mode 100644 index 000000000..83be77bcc --- /dev/null +++ b/test/test_google_endpoint_device.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_endpoint_device import GoogleEndpointDevice + +class TestGoogleEndpointDevice(unittest.TestCase): + """GoogleEndpointDevice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleEndpointDevice: + """Test GoogleEndpointDevice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleEndpointDevice` + """ + model = GoogleEndpointDevice() + if include_optional: + return GoogleEndpointDevice( + pk = '', + name = '' + ) + else: + return GoogleEndpointDevice( + name = '', + ) + """ + + def testGoogleEndpointDevice(self): + """Test GoogleEndpointDevice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_endpoint_device_request.py b/test/test_google_endpoint_device_request.py new file mode 100644 index 000000000..f2eb88a31 --- /dev/null +++ b/test/test_google_endpoint_device_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_endpoint_device_request import GoogleEndpointDeviceRequest + +class TestGoogleEndpointDeviceRequest(unittest.TestCase): + """GoogleEndpointDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleEndpointDeviceRequest: + """Test GoogleEndpointDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleEndpointDeviceRequest` + """ + model = GoogleEndpointDeviceRequest() + if include_optional: + return GoogleEndpointDeviceRequest( + pk = '', + name = '0' + ) + else: + return GoogleEndpointDeviceRequest( + name = '0', + ) + """ + + def testGoogleEndpointDeviceRequest(self): + """Test GoogleEndpointDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_workspace_provider.py b/test/test_google_workspace_provider.py new file mode 100644 index 000000000..b0c0e5b92 --- /dev/null +++ b/test/test_google_workspace_provider.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_workspace_provider import GoogleWorkspaceProvider + +class TestGoogleWorkspaceProvider(unittest.TestCase): + """GoogleWorkspaceProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleWorkspaceProvider: + """Test GoogleWorkspaceProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleWorkspaceProvider` + """ + model = GoogleWorkspaceProvider() + if include_optional: + return GoogleWorkspaceProvider( + pk = 56, + name = '', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + delegated_subject = '', + credentials = { + 'key' : null + }, + scopes = '', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + default_group_email_domain = '', + sync_page_size = 1, + sync_page_timeout = '', + dry_run = True + ) + else: + return GoogleWorkspaceProvider( + pk = 56, + name = '', + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + delegated_subject = '', + credentials = { + 'key' : null + }, + default_group_email_domain = '', + ) + """ + + def testGoogleWorkspaceProvider(self): + """Test GoogleWorkspaceProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_workspace_provider_group.py b/test/test_google_workspace_provider_group.py new file mode 100644 index 000000000..ed6e90c45 --- /dev/null +++ b/test/test_google_workspace_provider_group.py @@ -0,0 +1,81 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_workspace_provider_group import GoogleWorkspaceProviderGroup + +class TestGoogleWorkspaceProviderGroup(unittest.TestCase): + """GoogleWorkspaceProviderGroup unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleWorkspaceProviderGroup: + """Test GoogleWorkspaceProviderGroup + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleWorkspaceProviderGroup` + """ + model = GoogleWorkspaceProviderGroup() + if include_optional: + return GoogleWorkspaceProviderGroup( + id = '', + google_id = '', + group = '', + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + provider = 56, + attributes = { + 'key' : null + } + ) + else: + return GoogleWorkspaceProviderGroup( + id = '', + google_id = '', + group = '', + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + provider = 56, + attributes = { + 'key' : null + }, + ) + """ + + def testGoogleWorkspaceProviderGroup(self): + """Test GoogleWorkspaceProviderGroup""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_workspace_provider_group_request.py b/test/test_google_workspace_provider_group_request.py new file mode 100644 index 000000000..226b583eb --- /dev/null +++ b/test/test_google_workspace_provider_group_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_workspace_provider_group_request import GoogleWorkspaceProviderGroupRequest + +class TestGoogleWorkspaceProviderGroupRequest(unittest.TestCase): + """GoogleWorkspaceProviderGroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleWorkspaceProviderGroupRequest: + """Test GoogleWorkspaceProviderGroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleWorkspaceProviderGroupRequest` + """ + model = GoogleWorkspaceProviderGroupRequest() + if include_optional: + return GoogleWorkspaceProviderGroupRequest( + google_id = '0', + group = '', + provider = 56 + ) + else: + return GoogleWorkspaceProviderGroupRequest( + google_id = '0', + group = '', + provider = 56, + ) + """ + + def testGoogleWorkspaceProviderGroupRequest(self): + """Test GoogleWorkspaceProviderGroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_workspace_provider_mapping.py b/test/test_google_workspace_provider_mapping.py new file mode 100644 index 000000000..3846b1c19 --- /dev/null +++ b/test/test_google_workspace_provider_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_workspace_provider_mapping import GoogleWorkspaceProviderMapping + +class TestGoogleWorkspaceProviderMapping(unittest.TestCase): + """GoogleWorkspaceProviderMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleWorkspaceProviderMapping: + """Test GoogleWorkspaceProviderMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleWorkspaceProviderMapping` + """ + model = GoogleWorkspaceProviderMapping() + if include_optional: + return GoogleWorkspaceProviderMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return GoogleWorkspaceProviderMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testGoogleWorkspaceProviderMapping(self): + """Test GoogleWorkspaceProviderMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_workspace_provider_mapping_request.py b/test/test_google_workspace_provider_mapping_request.py new file mode 100644 index 000000000..0261e2f35 --- /dev/null +++ b/test/test_google_workspace_provider_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_workspace_provider_mapping_request import GoogleWorkspaceProviderMappingRequest + +class TestGoogleWorkspaceProviderMappingRequest(unittest.TestCase): + """GoogleWorkspaceProviderMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleWorkspaceProviderMappingRequest: + """Test GoogleWorkspaceProviderMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleWorkspaceProviderMappingRequest` + """ + model = GoogleWorkspaceProviderMappingRequest() + if include_optional: + return GoogleWorkspaceProviderMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return GoogleWorkspaceProviderMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testGoogleWorkspaceProviderMappingRequest(self): + """Test GoogleWorkspaceProviderMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_workspace_provider_request.py b/test/test_google_workspace_provider_request.py new file mode 100644 index 000000000..800fc594c --- /dev/null +++ b/test/test_google_workspace_provider_request.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_workspace_provider_request import GoogleWorkspaceProviderRequest + +class TestGoogleWorkspaceProviderRequest(unittest.TestCase): + """GoogleWorkspaceProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleWorkspaceProviderRequest: + """Test GoogleWorkspaceProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleWorkspaceProviderRequest` + """ + model = GoogleWorkspaceProviderRequest() + if include_optional: + return GoogleWorkspaceProviderRequest( + name = '0', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + delegated_subject = '0', + credentials = { + 'key' : null + }, + scopes = '0', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + default_group_email_domain = '0', + sync_page_size = 1, + sync_page_timeout = '0', + dry_run = True + ) + else: + return GoogleWorkspaceProviderRequest( + name = '0', + delegated_subject = '0', + credentials = { + 'key' : null + }, + default_group_email_domain = '0', + ) + """ + + def testGoogleWorkspaceProviderRequest(self): + """Test GoogleWorkspaceProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_workspace_provider_user.py b/test/test_google_workspace_provider_user.py new file mode 100644 index 000000000..b0ce747ce --- /dev/null +++ b/test/test_google_workspace_provider_user.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_workspace_provider_user import GoogleWorkspaceProviderUser + +class TestGoogleWorkspaceProviderUser(unittest.TestCase): + """GoogleWorkspaceProviderUser unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleWorkspaceProviderUser: + """Test GoogleWorkspaceProviderUser + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleWorkspaceProviderUser` + """ + model = GoogleWorkspaceProviderUser() + if include_optional: + return GoogleWorkspaceProviderUser( + id = '', + google_id = '', + user = 56, + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + provider = 56, + attributes = { + 'key' : null + } + ) + else: + return GoogleWorkspaceProviderUser( + id = '', + google_id = '', + user = 56, + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + provider = 56, + attributes = { + 'key' : null + }, + ) + """ + + def testGoogleWorkspaceProviderUser(self): + """Test GoogleWorkspaceProviderUser""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_google_workspace_provider_user_request.py b/test/test_google_workspace_provider_user_request.py new file mode 100644 index 000000000..0fc3c5dcb --- /dev/null +++ b/test/test_google_workspace_provider_user_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.google_workspace_provider_user_request import GoogleWorkspaceProviderUserRequest + +class TestGoogleWorkspaceProviderUserRequest(unittest.TestCase): + """GoogleWorkspaceProviderUserRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GoogleWorkspaceProviderUserRequest: + """Test GoogleWorkspaceProviderUserRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GoogleWorkspaceProviderUserRequest` + """ + model = GoogleWorkspaceProviderUserRequest() + if include_optional: + return GoogleWorkspaceProviderUserRequest( + google_id = '0', + user = 56, + provider = 56 + ) + else: + return GoogleWorkspaceProviderUserRequest( + google_id = '0', + user = 56, + provider = 56, + ) + """ + + def testGoogleWorkspaceProviderUserRequest(self): + """Test GoogleWorkspaceProviderUserRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_grant_types_enum.py b/test/test_grant_types_enum.py new file mode 100644 index 000000000..fe433a3af --- /dev/null +++ b/test/test_grant_types_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.grant_types_enum import GrantTypesEnum + +class TestGrantTypesEnum(unittest.TestCase): + """GrantTypesEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testGrantTypesEnum(self): + """Test GrantTypesEnum""" + # inst = GrantTypesEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group.py b/test/test_group.py new file mode 100644 index 000000000..b6953fdb6 --- /dev/null +++ b/test/test_group.py @@ -0,0 +1,162 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group import Group + +class TestGroup(unittest.TestCase): + """Group unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Group: + """Test Group + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Group` + """ + model = Group() + if include_optional: + return Group( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + parents = [ + '' + ], + parents_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, + group_uuid = '', ) + ], + users = [ + 56 + ], + users_obj = [ + authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ], + attributes = { + 'key' : null + }, + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + inherited_roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + children = [ + '' + ], + children_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, + group_uuid = '', ) + ] + ) + else: + return Group( + pk = '', + num_pk = 56, + name = '', + parents_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, + group_uuid = '', ) + ], + users_obj = [ + authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + inherited_roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + children = [ + '' + ], + children_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, + group_uuid = '', ) + ], + ) + """ + + def testGroup(self): + """Test Group""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_kerberos_source_connection.py b/test/test_group_kerberos_source_connection.py new file mode 100644 index 000000000..ca10144f9 --- /dev/null +++ b/test/test_group_kerberos_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_kerberos_source_connection import GroupKerberosSourceConnection + +class TestGroupKerberosSourceConnection(unittest.TestCase): + """GroupKerberosSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupKerberosSourceConnection: + """Test GroupKerberosSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupKerberosSourceConnection` + """ + model = GroupKerberosSourceConnection() + if include_optional: + return GroupKerberosSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return GroupKerberosSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testGroupKerberosSourceConnection(self): + """Test GroupKerberosSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_kerberos_source_connection_request.py b/test/test_group_kerberos_source_connection_request.py new file mode 100644 index 000000000..54643f360 --- /dev/null +++ b/test/test_group_kerberos_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_kerberos_source_connection_request import GroupKerberosSourceConnectionRequest + +class TestGroupKerberosSourceConnectionRequest(unittest.TestCase): + """GroupKerberosSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupKerberosSourceConnectionRequest: + """Test GroupKerberosSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupKerberosSourceConnectionRequest` + """ + model = GroupKerberosSourceConnectionRequest() + if include_optional: + return GroupKerberosSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return GroupKerberosSourceConnectionRequest( + group = '', + source = '', + identifier = '0', + ) + """ + + def testGroupKerberosSourceConnectionRequest(self): + """Test GroupKerberosSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_ldap_source_connection.py b/test/test_group_ldap_source_connection.py new file mode 100644 index 000000000..5d0b4bb57 --- /dev/null +++ b/test/test_group_ldap_source_connection.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_ldap_source_connection import GroupLDAPSourceConnection + +class TestGroupLDAPSourceConnection(unittest.TestCase): + """GroupLDAPSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupLDAPSourceConnection: + """Test GroupLDAPSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupLDAPSourceConnection` + """ + model = GroupLDAPSourceConnection() + if include_optional: + return GroupLDAPSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ) + else: + return GroupLDAPSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + ) + """ + + def testGroupLDAPSourceConnection(self): + """Test GroupLDAPSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_ldap_source_connection_request.py b/test/test_group_ldap_source_connection_request.py new file mode 100644 index 000000000..e5f7ecd92 --- /dev/null +++ b/test/test_group_ldap_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_ldap_source_connection_request import GroupLDAPSourceConnectionRequest + +class TestGroupLDAPSourceConnectionRequest(unittest.TestCase): + """GroupLDAPSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupLDAPSourceConnectionRequest: + """Test GroupLDAPSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupLDAPSourceConnectionRequest` + """ + model = GroupLDAPSourceConnectionRequest() + if include_optional: + return GroupLDAPSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return GroupLDAPSourceConnectionRequest( + group = '', + source = '', + identifier = '0', + ) + """ + + def testGroupLDAPSourceConnectionRequest(self): + """Test GroupLDAPSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_matching_mode_enum.py b/test/test_group_matching_mode_enum.py new file mode 100644 index 000000000..8c3428ab1 --- /dev/null +++ b/test/test_group_matching_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_matching_mode_enum import GroupMatchingModeEnum + +class TestGroupMatchingModeEnum(unittest.TestCase): + """GroupMatchingModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testGroupMatchingModeEnum(self): + """Test GroupMatchingModeEnum""" + # inst = GroupMatchingModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_o_auth_source_connection.py b/test/test_group_o_auth_source_connection.py new file mode 100644 index 000000000..92b271ea3 --- /dev/null +++ b/test/test_group_o_auth_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_o_auth_source_connection import GroupOAuthSourceConnection + +class TestGroupOAuthSourceConnection(unittest.TestCase): + """GroupOAuthSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupOAuthSourceConnection: + """Test GroupOAuthSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupOAuthSourceConnection` + """ + model = GroupOAuthSourceConnection() + if include_optional: + return GroupOAuthSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return GroupOAuthSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testGroupOAuthSourceConnection(self): + """Test GroupOAuthSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_o_auth_source_connection_request.py b/test/test_group_o_auth_source_connection_request.py new file mode 100644 index 000000000..c7c4415b4 --- /dev/null +++ b/test/test_group_o_auth_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_o_auth_source_connection_request import GroupOAuthSourceConnectionRequest + +class TestGroupOAuthSourceConnectionRequest(unittest.TestCase): + """GroupOAuthSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupOAuthSourceConnectionRequest: + """Test GroupOAuthSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupOAuthSourceConnectionRequest` + """ + model = GroupOAuthSourceConnectionRequest() + if include_optional: + return GroupOAuthSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return GroupOAuthSourceConnectionRequest( + group = '', + source = '', + identifier = '0', + ) + """ + + def testGroupOAuthSourceConnectionRequest(self): + """Test GroupOAuthSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_plex_source_connection.py b/test/test_group_plex_source_connection.py new file mode 100644 index 000000000..af084e7d0 --- /dev/null +++ b/test/test_group_plex_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_plex_source_connection import GroupPlexSourceConnection + +class TestGroupPlexSourceConnection(unittest.TestCase): + """GroupPlexSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupPlexSourceConnection: + """Test GroupPlexSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupPlexSourceConnection` + """ + model = GroupPlexSourceConnection() + if include_optional: + return GroupPlexSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return GroupPlexSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testGroupPlexSourceConnection(self): + """Test GroupPlexSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_plex_source_connection_request.py b/test/test_group_plex_source_connection_request.py new file mode 100644 index 000000000..0002ff34c --- /dev/null +++ b/test/test_group_plex_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_plex_source_connection_request import GroupPlexSourceConnectionRequest + +class TestGroupPlexSourceConnectionRequest(unittest.TestCase): + """GroupPlexSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupPlexSourceConnectionRequest: + """Test GroupPlexSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupPlexSourceConnectionRequest` + """ + model = GroupPlexSourceConnectionRequest() + if include_optional: + return GroupPlexSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return GroupPlexSourceConnectionRequest( + group = '', + source = '', + identifier = '0', + ) + """ + + def testGroupPlexSourceConnectionRequest(self): + """Test GroupPlexSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_request.py b/test/test_group_request.py new file mode 100644 index 000000000..9fcfe6c67 --- /dev/null +++ b/test/test_group_request.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_request import GroupRequest + +class TestGroupRequest(unittest.TestCase): + """GroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupRequest: + """Test GroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupRequest` + """ + model = GroupRequest() + if include_optional: + return GroupRequest( + name = '0', + is_superuser = True, + parents = [ + '' + ], + users = [ + 56 + ], + attributes = { + 'key' : null + }, + roles = [ + '' + ] + ) + else: + return GroupRequest( + name = '0', + ) + """ + + def testGroupRequest(self): + """Test GroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_saml_source_connection.py b/test/test_group_saml_source_connection.py new file mode 100644 index 000000000..bf0b46136 --- /dev/null +++ b/test/test_group_saml_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_saml_source_connection import GroupSAMLSourceConnection + +class TestGroupSAMLSourceConnection(unittest.TestCase): + """GroupSAMLSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupSAMLSourceConnection: + """Test GroupSAMLSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupSAMLSourceConnection` + """ + model = GroupSAMLSourceConnection() + if include_optional: + return GroupSAMLSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return GroupSAMLSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testGroupSAMLSourceConnection(self): + """Test GroupSAMLSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_saml_source_connection_request.py b/test/test_group_saml_source_connection_request.py new file mode 100644 index 000000000..1e29cb873 --- /dev/null +++ b/test/test_group_saml_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_saml_source_connection_request import GroupSAMLSourceConnectionRequest + +class TestGroupSAMLSourceConnectionRequest(unittest.TestCase): + """GroupSAMLSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupSAMLSourceConnectionRequest: + """Test GroupSAMLSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupSAMLSourceConnectionRequest` + """ + model = GroupSAMLSourceConnectionRequest() + if include_optional: + return GroupSAMLSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return GroupSAMLSourceConnectionRequest( + group = '', + source = '', + identifier = '0', + ) + """ + + def testGroupSAMLSourceConnectionRequest(self): + """Test GroupSAMLSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_source_connection.py b/test/test_group_source_connection.py new file mode 100644 index 000000000..a39e16f39 --- /dev/null +++ b/test/test_group_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_source_connection import GroupSourceConnection + +class TestGroupSourceConnection(unittest.TestCase): + """GroupSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupSourceConnection: + """Test GroupSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupSourceConnection` + """ + model = GroupSourceConnection() + if include_optional: + return GroupSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return GroupSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testGroupSourceConnection(self): + """Test GroupSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_source_connection_request.py b/test/test_group_source_connection_request.py new file mode 100644 index 000000000..af74e7878 --- /dev/null +++ b/test/test_group_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_source_connection_request import GroupSourceConnectionRequest + +class TestGroupSourceConnectionRequest(unittest.TestCase): + """GroupSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupSourceConnectionRequest: + """Test GroupSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupSourceConnectionRequest` + """ + model = GroupSourceConnectionRequest() + if include_optional: + return GroupSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return GroupSourceConnectionRequest( + group = '', + source = '', + identifier = '0', + ) + """ + + def testGroupSourceConnectionRequest(self): + """Test GroupSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_telegram_source_connection.py b/test/test_group_telegram_source_connection.py new file mode 100644 index 000000000..a9bac3f3c --- /dev/null +++ b/test/test_group_telegram_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_telegram_source_connection import GroupTelegramSourceConnection + +class TestGroupTelegramSourceConnection(unittest.TestCase): + """GroupTelegramSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupTelegramSourceConnection: + """Test GroupTelegramSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupTelegramSourceConnection` + """ + model = GroupTelegramSourceConnection() + if include_optional: + return GroupTelegramSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return GroupTelegramSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testGroupTelegramSourceConnection(self): + """Test GroupTelegramSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_group_telegram_source_connection_request.py b/test/test_group_telegram_source_connection_request.py new file mode 100644 index 000000000..a30bc3622 --- /dev/null +++ b/test/test_group_telegram_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.group_telegram_source_connection_request import GroupTelegramSourceConnectionRequest + +class TestGroupTelegramSourceConnectionRequest(unittest.TestCase): + """GroupTelegramSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GroupTelegramSourceConnectionRequest: + """Test GroupTelegramSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GroupTelegramSourceConnectionRequest` + """ + model = GroupTelegramSourceConnectionRequest() + if include_optional: + return GroupTelegramSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return GroupTelegramSourceConnectionRequest( + group = '', + source = '', + identifier = '0', + ) + """ + + def testGroupTelegramSourceConnectionRequest(self): + """Test GroupTelegramSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_hardware.py b/test/test_hardware.py new file mode 100644 index 000000000..aed882075 --- /dev/null +++ b/test/test_hardware.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.hardware import Hardware + +class TestHardware(unittest.TestCase): + """Hardware unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Hardware: + """Test Hardware + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Hardware` + """ + model = Hardware() + if include_optional: + return Hardware( + model = '', + manufacturer = '', + serial = '', + cpu_name = '', + cpu_count = 56, + memory_bytes = 56 + ) + else: + return Hardware( + serial = '', + ) + """ + + def testHardware(self): + """Test Hardware""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_hardware_request.py b/test/test_hardware_request.py new file mode 100644 index 000000000..aa69527ed --- /dev/null +++ b/test/test_hardware_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.hardware_request import HardwareRequest + +class TestHardwareRequest(unittest.TestCase): + """HardwareRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> HardwareRequest: + """Test HardwareRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `HardwareRequest` + """ + model = HardwareRequest() + if include_optional: + return HardwareRequest( + model = '0', + manufacturer = '0', + serial = '0', + cpu_name = '0', + cpu_count = 56, + memory_bytes = 56 + ) + else: + return HardwareRequest( + serial = '0', + ) + """ + + def testHardwareRequest(self): + """Test HardwareRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_identification_challenge.py b/test/test_identification_challenge.py new file mode 100644 index 000000000..527e48673 --- /dev/null +++ b/test/test_identification_challenge.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.identification_challenge import IdentificationChallenge + +class TestIdentificationChallenge(unittest.TestCase): + """IdentificationChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> IdentificationChallenge: + """Test IdentificationChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `IdentificationChallenge` + """ + model = IdentificationChallenge() + if include_optional: + return IdentificationChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-identification', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + user_fields = [ + '' + ], + pending_user_identifier = '', + password_fields = True, + allow_show_password = True, + application_pre = '', + application_pre_launch = '', + flow_designation = 'authentication', + captcha_stage = authentik_client.models.captcha_challenge.CaptchaChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-captcha', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + site_key = '', + js_url = '', + interactive = True, ), + enroll_url = '', + recovery_url = '', + passwordless_url = '', + primary_action = '', + sources = [ + authentik_client.models.login_source.LoginSource( + name = '', + icon_url = '', + promoted = True, + challenge = null, ) + ], + show_source_labels = True, + enable_remember_me = True, + passkey_challenge = { + 'key' : null + } + ) + else: + return IdentificationChallenge( + user_fields = [ + '' + ], + password_fields = True, + flow_designation = 'authentication', + primary_action = '', + show_source_labels = True, + ) + """ + + def testIdentificationChallenge(self): + """Test IdentificationChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_identification_challenge_response_request.py b/test/test_identification_challenge_response_request.py new file mode 100644 index 000000000..6357f721c --- /dev/null +++ b/test/test_identification_challenge_response_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.identification_challenge_response_request import IdentificationChallengeResponseRequest + +class TestIdentificationChallengeResponseRequest(unittest.TestCase): + """IdentificationChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> IdentificationChallengeResponseRequest: + """Test IdentificationChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `IdentificationChallengeResponseRequest` + """ + model = IdentificationChallengeResponseRequest() + if include_optional: + return IdentificationChallengeResponseRequest( + component = 'ak-stage-identification', + uid_field = '', + password = '', + captcha_token = '', + passkey = { + 'key' : null + } + ) + else: + return IdentificationChallengeResponseRequest( + ) + """ + + def testIdentificationChallengeResponseRequest(self): + """Test IdentificationChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_identification_stage.py b/test/test_identification_stage.py new file mode 100644 index 000000000..87e20fda5 --- /dev/null +++ b/test/test_identification_stage.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.identification_stage import IdentificationStage + +class TestIdentificationStage(unittest.TestCase): + """IdentificationStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> IdentificationStage: + """Test IdentificationStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `IdentificationStage` + """ + model = IdentificationStage() + if include_optional: + return IdentificationStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + user_fields = [ + 'email' + ], + password_stage = '', + captcha_stage = '', + case_insensitive_matching = True, + show_matched_user = True, + enrollment_flow = '', + recovery_flow = '', + passwordless_flow = '', + sources = [ + '' + ], + show_source_labels = True, + pretend_user_exists = True, + enable_remember_me = True, + webauthn_stage = '' + ) + else: + return IdentificationStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testIdentificationStage(self): + """Test IdentificationStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_identification_stage_request.py b/test/test_identification_stage_request.py new file mode 100644 index 000000000..cf688b403 --- /dev/null +++ b/test/test_identification_stage_request.py @@ -0,0 +1,70 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.identification_stage_request import IdentificationStageRequest + +class TestIdentificationStageRequest(unittest.TestCase): + """IdentificationStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> IdentificationStageRequest: + """Test IdentificationStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `IdentificationStageRequest` + """ + model = IdentificationStageRequest() + if include_optional: + return IdentificationStageRequest( + name = '0', + user_fields = [ + 'email' + ], + password_stage = '', + captcha_stage = '', + case_insensitive_matching = True, + show_matched_user = True, + enrollment_flow = '', + recovery_flow = '', + passwordless_flow = '', + sources = [ + '' + ], + show_source_labels = True, + pretend_user_exists = True, + enable_remember_me = True, + webauthn_stage = '' + ) + else: + return IdentificationStageRequest( + name = '0', + ) + """ + + def testIdentificationStageRequest(self): + """Test IdentificationStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_iframe_logout_challenge.py b/test/test_iframe_logout_challenge.py new file mode 100644 index 000000000..66e334cec --- /dev/null +++ b/test/test_iframe_logout_challenge.py @@ -0,0 +1,74 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.iframe_logout_challenge import IframeLogoutChallenge + +class TestIframeLogoutChallenge(unittest.TestCase): + """IframeLogoutChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> IframeLogoutChallenge: + """Test IframeLogoutChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `IframeLogoutChallenge` + """ + model = IframeLogoutChallenge() + if include_optional: + return IframeLogoutChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-provider-iframe-logout', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + logout_urls = [ + authentik_client.models.logout_url.LogoutURL( + url = '', + provider_name = '', + binding = '', + saml_request = '', + saml_response = '', + saml_relay_state = '', ) + ] + ) + else: + return IframeLogoutChallenge( + ) + """ + + def testIframeLogoutChallenge(self): + """Test IframeLogoutChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_iframe_logout_challenge_response_request.py b/test/test_iframe_logout_challenge_response_request.py new file mode 100644 index 000000000..812be7735 --- /dev/null +++ b/test/test_iframe_logout_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.iframe_logout_challenge_response_request import IframeLogoutChallengeResponseRequest + +class TestIframeLogoutChallengeResponseRequest(unittest.TestCase): + """IframeLogoutChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> IframeLogoutChallengeResponseRequest: + """Test IframeLogoutChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `IframeLogoutChallengeResponseRequest` + """ + model = IframeLogoutChallengeResponseRequest() + if include_optional: + return IframeLogoutChallengeResponseRequest( + component = 'ak-provider-iframe-logout' + ) + else: + return IframeLogoutChallengeResponseRequest( + ) + """ + + def testIframeLogoutChallengeResponseRequest(self): + """Test IframeLogoutChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_impersonation_request.py b/test/test_impersonation_request.py new file mode 100644 index 000000000..25d6b3440 --- /dev/null +++ b/test/test_impersonation_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.impersonation_request import ImpersonationRequest + +class TestImpersonationRequest(unittest.TestCase): + """ImpersonationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ImpersonationRequest: + """Test ImpersonationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ImpersonationRequest` + """ + model = ImpersonationRequest() + if include_optional: + return ImpersonationRequest( + reason = '0' + ) + else: + return ImpersonationRequest( + reason = '0', + ) + """ + + def testImpersonationRequest(self): + """Test ImpersonationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_initial_permissions.py b/test/test_initial_permissions.py new file mode 100644 index 000000000..7d009d34d --- /dev/null +++ b/test/test_initial_permissions.py @@ -0,0 +1,80 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.initial_permissions import InitialPermissions + +class TestInitialPermissions(unittest.TestCase): + """InitialPermissions unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> InitialPermissions: + """Test InitialPermissions + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `InitialPermissions` + """ + model = InitialPermissions() + if include_optional: + return InitialPermissions( + pk = 56, + name = '', + role = '', + permissions = [ + 56 + ], + permissions_obj = [ + authentik_client.models.permission.Permission( + id = 56, + name = '', + codename = '', + model = '', + app_label = '', + app_label_verbose = '', + model_verbose = '', ) + ] + ) + else: + return InitialPermissions( + pk = 56, + name = '', + role = '', + permissions_obj = [ + authentik_client.models.permission.Permission( + id = 56, + name = '', + codename = '', + model = '', + app_label = '', + app_label_verbose = '', + model_verbose = '', ) + ], + ) + """ + + def testInitialPermissions(self): + """Test InitialPermissions""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_initial_permissions_request.py b/test/test_initial_permissions_request.py new file mode 100644 index 000000000..9945327a9 --- /dev/null +++ b/test/test_initial_permissions_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.initial_permissions_request import InitialPermissionsRequest + +class TestInitialPermissionsRequest(unittest.TestCase): + """InitialPermissionsRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> InitialPermissionsRequest: + """Test InitialPermissionsRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `InitialPermissionsRequest` + """ + model = InitialPermissionsRequest() + if include_optional: + return InitialPermissionsRequest( + name = '0', + role = '', + permissions = [ + 56 + ] + ) + else: + return InitialPermissionsRequest( + name = '0', + role = '', + ) + """ + + def testInitialPermissionsRequest(self): + """Test InitialPermissionsRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_install_id.py b/test/test_install_id.py new file mode 100644 index 000000000..eda0d63e0 --- /dev/null +++ b/test/test_install_id.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.install_id import InstallID + +class TestInstallID(unittest.TestCase): + """InstallID unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> InstallID: + """Test InstallID + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `InstallID` + """ + model = InstallID() + if include_optional: + return InstallID( + install_id = '' + ) + else: + return InstallID( + install_id = '', + ) + """ + + def testInstallID(self): + """Test InstallID""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_intent_enum.py b/test/test_intent_enum.py new file mode 100644 index 000000000..bd940941f --- /dev/null +++ b/test/test_intent_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.intent_enum import IntentEnum + +class TestIntentEnum(unittest.TestCase): + """IntentEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testIntentEnum(self): + """Test IntentEnum""" + # inst = IntentEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_invalid_response_action_enum.py b/test/test_invalid_response_action_enum.py new file mode 100644 index 000000000..32a5a3f7b --- /dev/null +++ b/test/test_invalid_response_action_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.invalid_response_action_enum import InvalidResponseActionEnum + +class TestInvalidResponseActionEnum(unittest.TestCase): + """InvalidResponseActionEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testInvalidResponseActionEnum(self): + """Test InvalidResponseActionEnum""" + # inst = InvalidResponseActionEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_invitation.py b/test/test_invitation.py new file mode 100644 index 000000000..3e76342e4 --- /dev/null +++ b/test/test_invitation.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.invitation import Invitation + +class TestInvitation(unittest.TestCase): + """Invitation unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Invitation: + """Test Invitation + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Invitation` + """ + model = Invitation() + if include_optional: + return Invitation( + pk = '', + name = 'z', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + fixed_data = { + 'key' : null + }, + created_by = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + single_use = True, + flow = '', + flow_obj = authentik_client.models.flow.Flow( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background = '', + background_url = '', + background_themed_urls = null, + stages = [ + '' + ], + policies = [ + '' + ], + cache_count = 56, + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, + authentication = null, ) + ) + else: + return Invitation( + pk = '', + name = 'z', + created_by = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + flow_obj = authentik_client.models.flow.Flow( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background = '', + background_url = '', + background_themed_urls = null, + stages = [ + '' + ], + policies = [ + '' + ], + cache_count = 56, + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, + authentication = null, ), + ) + """ + + def testInvitation(self): + """Test Invitation""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_invitation_request.py b/test/test_invitation_request.py new file mode 100644 index 000000000..4ade7d394 --- /dev/null +++ b/test/test_invitation_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.invitation_request import InvitationRequest + +class TestInvitationRequest(unittest.TestCase): + """InvitationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> InvitationRequest: + """Test InvitationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `InvitationRequest` + """ + model = InvitationRequest() + if include_optional: + return InvitationRequest( + name = 'z0', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + fixed_data = { + 'key' : null + }, + single_use = True, + flow = '' + ) + else: + return InvitationRequest( + name = 'z0', + ) + """ + + def testInvitationRequest(self): + """Test InvitationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_invitation_send_email_request.py b/test/test_invitation_send_email_request.py new file mode 100644 index 000000000..c579643b4 --- /dev/null +++ b/test/test_invitation_send_email_request.py @@ -0,0 +1,64 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.invitation_send_email_request import InvitationSendEmailRequest + +class TestInvitationSendEmailRequest(unittest.TestCase): + """InvitationSendEmailRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> InvitationSendEmailRequest: + """Test InvitationSendEmailRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `InvitationSendEmailRequest` + """ + model = InvitationSendEmailRequest() + if include_optional: + return InvitationSendEmailRequest( + email_addresses = [ + null + ], + cc_addresses = [ + null + ], + bcc_addresses = [ + null + ], + template = 'invitation' + ) + else: + return InvitationSendEmailRequest( + email_addresses = [ + null + ], + ) + """ + + def testInvitationSendEmailRequest(self): + """Test InvitationSendEmailRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_invitation_stage.py b/test/test_invitation_stage.py new file mode 100644 index 000000000..30a692094 --- /dev/null +++ b/test/test_invitation_stage.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.invitation_stage import InvitationStage + +class TestInvitationStage(unittest.TestCase): + """InvitationStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> InvitationStage: + """Test InvitationStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `InvitationStage` + """ + model = InvitationStage() + if include_optional: + return InvitationStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + continue_flow_without_invitation = True + ) + else: + return InvitationStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testInvitationStage(self): + """Test InvitationStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_invitation_stage_request.py b/test/test_invitation_stage_request.py new file mode 100644 index 000000000..10be5c0df --- /dev/null +++ b/test/test_invitation_stage_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.invitation_stage_request import InvitationStageRequest + +class TestInvitationStageRequest(unittest.TestCase): + """InvitationStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> InvitationStageRequest: + """Test InvitationStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `InvitationStageRequest` + """ + model = InvitationStageRequest() + if include_optional: + return InvitationStageRequest( + name = '0', + continue_flow_without_invitation = True + ) + else: + return InvitationStageRequest( + name = '0', + ) + """ + + def testInvitationStageRequest(self): + """Test InvitationStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_issuer_mode_enum.py b/test/test_issuer_mode_enum.py new file mode 100644 index 000000000..f7babd45e --- /dev/null +++ b/test/test_issuer_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.issuer_mode_enum import IssuerModeEnum + +class TestIssuerModeEnum(unittest.TestCase): + """IssuerModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testIssuerModeEnum(self): + """Test IssuerModeEnum""" + # inst = IssuerModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_kadmin_type_enum.py b/test/test_kadmin_type_enum.py new file mode 100644 index 000000000..bcf4c0642 --- /dev/null +++ b/test/test_kadmin_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.kadmin_type_enum import KadminTypeEnum + +class TestKadminTypeEnum(unittest.TestCase): + """KadminTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testKadminTypeEnum(self): + """Test KadminTypeEnum""" + # inst = KadminTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_kerberos_source.py b/test/test_kerberos_source.py new file mode 100644 index 000000000..ca764cfd0 --- /dev/null +++ b/test/test_kerberos_source.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.kerberos_source import KerberosSource + +class TestKerberosSource(unittest.TestCase): + """KerberosSource unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> KerberosSource: + """Test KerberosSource + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `KerberosSource` + """ + model = KerberosSource() + if include_optional: + return KerberosSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + group_matching_mode = 'identifier', + realm = '', + krb5_conf = '', + kadmin_type = 'MIT', + sync_users = True, + sync_users_password = True, + sync_principal = '', + sync_ccache = '', + connectivity = { + 'key' : '' + }, + spnego_server_name = '', + spnego_ccache = '', + password_login_update_internal_password = True, + sync_outgoing_trigger_mode = 'none' + ) + else: + return KerberosSource( + pk = '', + name = '', + slug = 'z', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + realm = '', + connectivity = { + 'key' : '' + }, + ) + """ + + def testKerberosSource(self): + """Test KerberosSource""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_kerberos_source_property_mapping.py b/test/test_kerberos_source_property_mapping.py new file mode 100644 index 000000000..0e3c0782e --- /dev/null +++ b/test/test_kerberos_source_property_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.kerberos_source_property_mapping import KerberosSourcePropertyMapping + +class TestKerberosSourcePropertyMapping(unittest.TestCase): + """KerberosSourcePropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> KerberosSourcePropertyMapping: + """Test KerberosSourcePropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `KerberosSourcePropertyMapping` + """ + model = KerberosSourcePropertyMapping() + if include_optional: + return KerberosSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return KerberosSourcePropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testKerberosSourcePropertyMapping(self): + """Test KerberosSourcePropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_kerberos_source_property_mapping_request.py b/test/test_kerberos_source_property_mapping_request.py new file mode 100644 index 000000000..864f9ca5d --- /dev/null +++ b/test/test_kerberos_source_property_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.kerberos_source_property_mapping_request import KerberosSourcePropertyMappingRequest + +class TestKerberosSourcePropertyMappingRequest(unittest.TestCase): + """KerberosSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> KerberosSourcePropertyMappingRequest: + """Test KerberosSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `KerberosSourcePropertyMappingRequest` + """ + model = KerberosSourcePropertyMappingRequest() + if include_optional: + return KerberosSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return KerberosSourcePropertyMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testKerberosSourcePropertyMappingRequest(self): + """Test KerberosSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_kerberos_source_request.py b/test/test_kerberos_source_request.py new file mode 100644 index 000000000..4c31b7705 --- /dev/null +++ b/test/test_kerberos_source_request.py @@ -0,0 +1,85 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.kerberos_source_request import KerberosSourceRequest + +class TestKerberosSourceRequest(unittest.TestCase): + """KerberosSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> KerberosSourceRequest: + """Test KerberosSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `KerberosSourceRequest` + """ + model = KerberosSourceRequest() + if include_optional: + return KerberosSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + group_matching_mode = 'identifier', + realm = '0', + krb5_conf = '', + kadmin_type = 'MIT', + sync_users = True, + sync_users_password = True, + sync_principal = '', + sync_password = '', + sync_keytab = '', + sync_ccache = '', + spnego_server_name = '', + spnego_keytab = '', + spnego_ccache = '', + password_login_update_internal_password = True, + sync_outgoing_trigger_mode = 'none' + ) + else: + return KerberosSourceRequest( + name = '0', + slug = 'z0', + realm = '0', + ) + """ + + def testKerberosSourceRequest(self): + """Test KerberosSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_key_type_enum.py b/test/test_key_type_enum.py new file mode 100644 index 000000000..7ecaba530 --- /dev/null +++ b/test/test_key_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.key_type_enum import KeyTypeEnum + +class TestKeyTypeEnum(unittest.TestCase): + """KeyTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testKeyTypeEnum(self): + """Test KeyTypeEnum""" + # inst = KeyTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_kubernetes_service_connection.py b/test/test_kubernetes_service_connection.py new file mode 100644 index 000000000..7feebb27f --- /dev/null +++ b/test/test_kubernetes_service_connection.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.kubernetes_service_connection import KubernetesServiceConnection + +class TestKubernetesServiceConnection(unittest.TestCase): + """KubernetesServiceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> KubernetesServiceConnection: + """Test KubernetesServiceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `KubernetesServiceConnection` + """ + model = KubernetesServiceConnection() + if include_optional: + return KubernetesServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + kubeconfig = { + 'key' : null + }, + verify_ssl = True + ) + else: + return KubernetesServiceConnection( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testKubernetesServiceConnection(self): + """Test KubernetesServiceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_kubernetes_service_connection_request.py b/test/test_kubernetes_service_connection_request.py new file mode 100644 index 000000000..628d27328 --- /dev/null +++ b/test/test_kubernetes_service_connection_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.kubernetes_service_connection_request import KubernetesServiceConnectionRequest + +class TestKubernetesServiceConnectionRequest(unittest.TestCase): + """KubernetesServiceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> KubernetesServiceConnectionRequest: + """Test KubernetesServiceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `KubernetesServiceConnectionRequest` + """ + model = KubernetesServiceConnectionRequest() + if include_optional: + return KubernetesServiceConnectionRequest( + name = '0', + local = True, + kubeconfig = { + 'key' : null + }, + verify_ssl = True + ) + else: + return KubernetesServiceConnectionRequest( + name = '0', + ) + """ + + def testKubernetesServiceConnectionRequest(self): + """Test KubernetesServiceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_lang_enum.py b/test/test_lang_enum.py new file mode 100644 index 000000000..47a78f5db --- /dev/null +++ b/test/test_lang_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.lang_enum import LangEnum + +class TestLangEnum(unittest.TestCase): + """LangEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testLangEnum(self): + """Test LangEnum""" + # inst = LangEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_last_task_status_enum.py b/test/test_last_task_status_enum.py new file mode 100644 index 000000000..32089581a --- /dev/null +++ b/test/test_last_task_status_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.last_task_status_enum import LastTaskStatusEnum + +class TestLastTaskStatusEnum(unittest.TestCase): + """LastTaskStatusEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testLastTaskStatusEnum(self): + """Test LastTaskStatusEnum""" + # inst = LastTaskStatusEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldap_check_access.py b/test/test_ldap_check_access.py new file mode 100644 index 000000000..bb2f1008c --- /dev/null +++ b/test/test_ldap_check_access.py @@ -0,0 +1,82 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldap_check_access import LDAPCheckAccess + +class TestLDAPCheckAccess(unittest.TestCase): + """LDAPCheckAccess unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LDAPCheckAccess: + """Test LDAPCheckAccess + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LDAPCheckAccess` + """ + model = LDAPCheckAccess() + if include_optional: + return LDAPCheckAccess( + has_search_permission = True, + access = authentik_client.models.policy_test_result.PolicyTestResult( + passing = True, + messages = [ + '' + ], + log_messages = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], ) + ) + else: + return LDAPCheckAccess( + access = authentik_client.models.policy_test_result.PolicyTestResult( + passing = True, + messages = [ + '' + ], + log_messages = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], ), + ) + """ + + def testLDAPCheckAccess(self): + """Test LDAPCheckAccess""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldap_debug.py b/test/test_ldap_debug.py new file mode 100644 index 000000000..984efc500 --- /dev/null +++ b/test/test_ldap_debug.py @@ -0,0 +1,81 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldap_debug import LDAPDebug + +class TestLDAPDebug(unittest.TestCase): + """LDAPDebug unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LDAPDebug: + """Test LDAPDebug + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LDAPDebug` + """ + model = LDAPDebug() + if include_optional: + return LDAPDebug( + user = [ + { + 'key' : null + } + ], + group = [ + { + 'key' : null + } + ], + membership = [ + { + 'key' : null + } + ] + ) + else: + return LDAPDebug( + user = [ + { + 'key' : null + } + ], + group = [ + { + 'key' : null + } + ], + membership = [ + { + 'key' : null + } + ], + ) + """ + + def testLDAPDebug(self): + """Test LDAPDebug""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldap_outpost_config.py b/test/test_ldap_outpost_config.py new file mode 100644 index 000000000..c596b187c --- /dev/null +++ b/test/test_ldap_outpost_config.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldap_outpost_config import LDAPOutpostConfig + +class TestLDAPOutpostConfig(unittest.TestCase): + """LDAPOutpostConfig unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LDAPOutpostConfig: + """Test LDAPOutpostConfig + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LDAPOutpostConfig` + """ + model = LDAPOutpostConfig() + if include_optional: + return LDAPOutpostConfig( + pk = 56, + name = '', + base_dn = '', + bind_flow_slug = '', + unbind_flow_slug = '', + application_slug = '', + certificate = '', + tls_server_name = '', + uid_start_number = -2147483648, + gid_start_number = -2147483648, + search_mode = 'direct', + bind_mode = 'direct', + mfa_support = True + ) + else: + return LDAPOutpostConfig( + pk = 56, + name = '', + bind_flow_slug = '', + unbind_flow_slug = '', + application_slug = '', + ) + """ + + def testLDAPOutpostConfig(self): + """Test LDAPOutpostConfig""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldap_provider.py b/test/test_ldap_provider.py new file mode 100644 index 000000000..dfe603c33 --- /dev/null +++ b/test/test_ldap_provider.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldap_provider import LDAPProvider + +class TestLDAPProvider(unittest.TestCase): + """LDAPProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LDAPProvider: + """Test LDAPProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LDAPProvider` + """ + model = LDAPProvider() + if include_optional: + return LDAPProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + base_dn = '', + certificate = '', + tls_server_name = '', + uid_start_number = -2147483648, + gid_start_number = -2147483648, + outpost_set = [ + '' + ], + search_mode = 'direct', + bind_mode = 'direct', + mfa_support = True + ) + else: + return LDAPProvider( + pk = 56, + name = '', + authorization_flow = '', + invalidation_flow = '', + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + outpost_set = [ + '' + ], + ) + """ + + def testLDAPProvider(self): + """Test LDAPProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldap_provider_request.py b/test/test_ldap_provider_request.py new file mode 100644 index 000000000..45a2a5310 --- /dev/null +++ b/test/test_ldap_provider_request.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldap_provider_request import LDAPProviderRequest + +class TestLDAPProviderRequest(unittest.TestCase): + """LDAPProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LDAPProviderRequest: + """Test LDAPProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LDAPProviderRequest` + """ + model = LDAPProviderRequest() + if include_optional: + return LDAPProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + base_dn = '0', + certificate = '', + tls_server_name = '', + uid_start_number = -2147483648, + gid_start_number = -2147483648, + search_mode = 'direct', + bind_mode = 'direct', + mfa_support = True + ) + else: + return LDAPProviderRequest( + name = '0', + authorization_flow = '', + invalidation_flow = '', + ) + """ + + def testLDAPProviderRequest(self): + """Test LDAPProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldap_source.py b/test/test_ldap_source.py new file mode 100644 index 000000000..f2c313d15 --- /dev/null +++ b/test/test_ldap_source.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldap_source import LDAPSource + +class TestLDAPSource(unittest.TestCase): + """LDAPSource unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LDAPSource: + """Test LDAPSource + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LDAPSource` + """ + model = LDAPSource() + if include_optional: + return LDAPSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + server_uri = '', + peer_certificate = '', + client_certificate = '', + bind_cn = '', + start_tls = True, + sni = True, + base_dn = '', + additional_user_dn = '', + additional_group_dn = '', + user_object_filter = '', + group_object_filter = '', + group_membership_field = '', + user_membership_attribute = '', + object_uniqueness_field = '', + password_login_update_internal_password = True, + sync_users = True, + sync_users_password = True, + sync_groups = True, + sync_parent_group = '', + connectivity = { + 'key' : { + 'key' : '' + } + }, + lookup_groups_from_user = True, + delete_not_found_objects = True, + sync_outgoing_trigger_mode = 'none' + ) + else: + return LDAPSource( + pk = '', + name = '', + slug = 'z', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + server_uri = '', + base_dn = '', + connectivity = { + 'key' : { + 'key' : '' + } + }, + ) + """ + + def testLDAPSource(self): + """Test LDAPSource""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldap_source_property_mapping.py b/test/test_ldap_source_property_mapping.py new file mode 100644 index 000000000..c1f7bc618 --- /dev/null +++ b/test/test_ldap_source_property_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldap_source_property_mapping import LDAPSourcePropertyMapping + +class TestLDAPSourcePropertyMapping(unittest.TestCase): + """LDAPSourcePropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LDAPSourcePropertyMapping: + """Test LDAPSourcePropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LDAPSourcePropertyMapping` + """ + model = LDAPSourcePropertyMapping() + if include_optional: + return LDAPSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return LDAPSourcePropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testLDAPSourcePropertyMapping(self): + """Test LDAPSourcePropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldap_source_property_mapping_request.py b/test/test_ldap_source_property_mapping_request.py new file mode 100644 index 000000000..8d2e9d5b9 --- /dev/null +++ b/test/test_ldap_source_property_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldap_source_property_mapping_request import LDAPSourcePropertyMappingRequest + +class TestLDAPSourcePropertyMappingRequest(unittest.TestCase): + """LDAPSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LDAPSourcePropertyMappingRequest: + """Test LDAPSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LDAPSourcePropertyMappingRequest` + """ + model = LDAPSourcePropertyMappingRequest() + if include_optional: + return LDAPSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return LDAPSourcePropertyMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testLDAPSourcePropertyMappingRequest(self): + """Test LDAPSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldap_source_request.py b/test/test_ldap_source_request.py new file mode 100644 index 000000000..a665db086 --- /dev/null +++ b/test/test_ldap_source_request.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldap_source_request import LDAPSourceRequest + +class TestLDAPSourceRequest(unittest.TestCase): + """LDAPSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LDAPSourceRequest: + """Test LDAPSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LDAPSourceRequest` + """ + model = LDAPSourceRequest() + if include_optional: + return LDAPSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + server_uri = '0', + peer_certificate = '', + client_certificate = '', + bind_cn = '', + bind_password = '', + start_tls = True, + sni = True, + base_dn = '0', + additional_user_dn = '', + additional_group_dn = '', + user_object_filter = '0', + group_object_filter = '0', + group_membership_field = '0', + user_membership_attribute = '0', + object_uniqueness_field = '0', + password_login_update_internal_password = True, + sync_users = True, + sync_users_password = True, + sync_groups = True, + sync_parent_group = '', + lookup_groups_from_user = True, + delete_not_found_objects = True, + sync_outgoing_trigger_mode = 'none' + ) + else: + return LDAPSourceRequest( + name = '0', + slug = 'z0', + server_uri = '0', + base_dn = '0', + ) + """ + + def testLDAPSourceRequest(self): + """Test LDAPSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ldapapi_access_mode.py b/test/test_ldapapi_access_mode.py new file mode 100644 index 000000000..016d135d1 --- /dev/null +++ b/test/test_ldapapi_access_mode.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ldapapi_access_mode import LDAPAPIAccessMode + +class TestLDAPAPIAccessMode(unittest.TestCase): + """LDAPAPIAccessMode unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testLDAPAPIAccessMode(self): + """Test LDAPAPIAccessMode""" + # inst = LDAPAPIAccessMode() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_license.py b/test/test_license.py new file mode 100644 index 000000000..8dcd2a4fd --- /dev/null +++ b/test/test_license.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.license import License + +class TestLicense(unittest.TestCase): + """License unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> License: + """Test License + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `License` + """ + model = License() + if include_optional: + return License( + license_uuid = '', + name = '', + key = '', + expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + internal_users = 56, + external_users = 56 + ) + else: + return License( + license_uuid = '', + name = '', + key = '', + expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + internal_users = 56, + external_users = 56, + ) + """ + + def testLicense(self): + """Test License""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_license_flags_enum.py b/test/test_license_flags_enum.py new file mode 100644 index 000000000..c94582836 --- /dev/null +++ b/test/test_license_flags_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.license_flags_enum import LicenseFlagsEnum + +class TestLicenseFlagsEnum(unittest.TestCase): + """LicenseFlagsEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testLicenseFlagsEnum(self): + """Test LicenseFlagsEnum""" + # inst = LicenseFlagsEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_license_forecast.py b/test/test_license_forecast.py new file mode 100644 index 000000000..f42c4308a --- /dev/null +++ b/test/test_license_forecast.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.license_forecast import LicenseForecast + +class TestLicenseForecast(unittest.TestCase): + """LicenseForecast unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LicenseForecast: + """Test LicenseForecast + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LicenseForecast` + """ + model = LicenseForecast() + if include_optional: + return LicenseForecast( + internal_users = 56, + external_users = 56, + forecasted_internal_users = 56, + forecasted_external_users = 56 + ) + else: + return LicenseForecast( + internal_users = 56, + external_users = 56, + forecasted_internal_users = 56, + forecasted_external_users = 56, + ) + """ + + def testLicenseForecast(self): + """Test LicenseForecast""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_license_request.py b/test/test_license_request.py new file mode 100644 index 000000000..ca8df0e75 --- /dev/null +++ b/test/test_license_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.license_request import LicenseRequest + +class TestLicenseRequest(unittest.TestCase): + """LicenseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LicenseRequest: + """Test LicenseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LicenseRequest` + """ + model = LicenseRequest() + if include_optional: + return LicenseRequest( + key = '0' + ) + else: + return LicenseRequest( + key = '0', + ) + """ + + def testLicenseRequest(self): + """Test LicenseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_license_status_enum.py b/test/test_license_status_enum.py new file mode 100644 index 000000000..ba2541d56 --- /dev/null +++ b/test/test_license_status_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.license_status_enum import LicenseStatusEnum + +class TestLicenseStatusEnum(unittest.TestCase): + """LicenseStatusEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testLicenseStatusEnum(self): + """Test LicenseStatusEnum""" + # inst = LicenseStatusEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_license_summary.py b/test/test_license_summary.py new file mode 100644 index 000000000..2534d1ce9 --- /dev/null +++ b/test/test_license_summary.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.license_summary import LicenseSummary + +class TestLicenseSummary(unittest.TestCase): + """LicenseSummary unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LicenseSummary: + """Test LicenseSummary + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LicenseSummary` + """ + model = LicenseSummary() + if include_optional: + return LicenseSummary( + internal_users = 56, + external_users = 56, + status = 'unlicensed', + latest_valid = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + license_flags = [ + 'trial' + ] + ) + else: + return LicenseSummary( + internal_users = 56, + external_users = 56, + status = 'unlicensed', + latest_valid = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + license_flags = [ + 'trial' + ], + ) + """ + + def testLicenseSummary(self): + """Test LicenseSummary""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_license_summary_status_enum.py b/test/test_license_summary_status_enum.py new file mode 100644 index 000000000..3afb69c74 --- /dev/null +++ b/test/test_license_summary_status_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.license_summary_status_enum import LicenseSummaryStatusEnum + +class TestLicenseSummaryStatusEnum(unittest.TestCase): + """LicenseSummaryStatusEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testLicenseSummaryStatusEnum(self): + """Test LicenseSummaryStatusEnum""" + # inst = LicenseSummaryStatusEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_lifecycle_api.py b/test/test_lifecycle_api.py new file mode 100644 index 000000000..c20cbedf3 --- /dev/null +++ b/test/test_lifecycle_api.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.lifecycle_api import LifecycleApi + + +class TestLifecycleApi(unittest.TestCase): + """LifecycleApi unit test stubs""" + + def setUp(self) -> None: + self.api = LifecycleApi() + + def tearDown(self) -> None: + pass + + def test_lifecycle_iterations_create(self) -> None: + """Test case for lifecycle_iterations_create + + """ + pass + + def test_lifecycle_iterations_list_latest(self) -> None: + """Test case for lifecycle_iterations_list_latest + + """ + pass + + def test_lifecycle_iterations_list_open(self) -> None: + """Test case for lifecycle_iterations_list_open + + """ + pass + + def test_lifecycle_reviews_create(self) -> None: + """Test case for lifecycle_reviews_create + + """ + pass + + def test_lifecycle_rules_create(self) -> None: + """Test case for lifecycle_rules_create + + """ + pass + + def test_lifecycle_rules_destroy(self) -> None: + """Test case for lifecycle_rules_destroy + + """ + pass + + def test_lifecycle_rules_list(self) -> None: + """Test case for lifecycle_rules_list + + """ + pass + + def test_lifecycle_rules_partial_update(self) -> None: + """Test case for lifecycle_rules_partial_update + + """ + pass + + def test_lifecycle_rules_retrieve(self) -> None: + """Test case for lifecycle_rules_retrieve + + """ + pass + + def test_lifecycle_rules_update(self) -> None: + """Test case for lifecycle_rules_update + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_lifecycle_iteration.py b/test/test_lifecycle_iteration.py new file mode 100644 index 000000000..22b132c27 --- /dev/null +++ b/test/test_lifecycle_iteration.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.lifecycle_iteration import LifecycleIteration + +class TestLifecycleIteration(unittest.TestCase): + """LifecycleIteration unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LifecycleIteration: + """Test LifecycleIteration + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LifecycleIteration` + """ + model = LifecycleIteration() + if include_optional: + return LifecycleIteration( + id = '', + content_type = 'authentik_core.application', + object_id = '', + object_verbose = '', + object_admin_url = '', + state = 'REVIEWED', + opened_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + grace_period_end = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + next_review_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + reviews = [ + authentik_client.models.review.Review( + id = '', + iteration = '', + reviewer = null, + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + note = '', ) + ], + rule = authentik_client.models.related_rule.RelatedRule( + id = '', + name = '', + reviewer_groups = [ + authentik_client.models.reviewer_group.ReviewerGroup( + pk = '', + name = '', ) + ], + min_reviewers = 56, + reviewers = [ + authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ) + ], ), + user_can_review = True + ) + else: + return LifecycleIteration( + id = '', + content_type = 'authentik_core.application', + object_id = '', + object_verbose = '', + object_admin_url = '', + state = 'REVIEWED', + opened_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + grace_period_end = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + next_review_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + reviews = [ + authentik_client.models.review.Review( + id = '', + iteration = '', + reviewer = null, + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + note = '', ) + ], + rule = authentik_client.models.related_rule.RelatedRule( + id = '', + name = '', + reviewer_groups = [ + authentik_client.models.reviewer_group.ReviewerGroup( + pk = '', + name = '', ) + ], + min_reviewers = 56, + reviewers = [ + authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ) + ], ), + user_can_review = True, + ) + """ + + def testLifecycleIteration(self): + """Test LifecycleIteration""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_lifecycle_iteration_request.py b/test/test_lifecycle_iteration_request.py new file mode 100644 index 000000000..cdfe59eb7 --- /dev/null +++ b/test/test_lifecycle_iteration_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.lifecycle_iteration_request import LifecycleIterationRequest + +class TestLifecycleIterationRequest(unittest.TestCase): + """LifecycleIterationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LifecycleIterationRequest: + """Test LifecycleIterationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LifecycleIterationRequest` + """ + model = LifecycleIterationRequest() + if include_optional: + return LifecycleIterationRequest( + content_type = 'authentik_core.application' + ) + else: + return LifecycleIterationRequest( + content_type = 'authentik_core.application', + ) + """ + + def testLifecycleIterationRequest(self): + """Test LifecycleIterationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_lifecycle_iteration_state_enum.py b/test/test_lifecycle_iteration_state_enum.py new file mode 100644 index 000000000..0f400b1d5 --- /dev/null +++ b/test/test_lifecycle_iteration_state_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.lifecycle_iteration_state_enum import LifecycleIterationStateEnum + +class TestLifecycleIterationStateEnum(unittest.TestCase): + """LifecycleIterationStateEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testLifecycleIterationStateEnum(self): + """Test LifecycleIterationStateEnum""" + # inst = LifecycleIterationStateEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_lifecycle_rule.py b/test/test_lifecycle_rule.py new file mode 100644 index 000000000..b2936d641 --- /dev/null +++ b/test/test_lifecycle_rule.py @@ -0,0 +1,100 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.lifecycle_rule import LifecycleRule + +class TestLifecycleRule(unittest.TestCase): + """LifecycleRule unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LifecycleRule: + """Test LifecycleRule + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LifecycleRule` + """ + model = LifecycleRule() + if include_optional: + return LifecycleRule( + id = '', + name = '', + content_type = 'authentik_core.application', + object_id = '', + interval = '', + grace_period = '', + reviewer_groups = [ + '' + ], + reviewer_groups_obj = [ + authentik_client.models.reviewer_group.ReviewerGroup( + pk = '', + name = '', ) + ], + min_reviewers = 0, + min_reviewers_is_per_group = True, + reviewers = [ + '' + ], + reviewers_obj = [ + authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ) + ], + notification_transports = [ + '' + ], + target_verbose = '' + ) + else: + return LifecycleRule( + id = '', + name = '', + content_type = 'authentik_core.application', + reviewer_groups_obj = [ + authentik_client.models.reviewer_group.ReviewerGroup( + pk = '', + name = '', ) + ], + reviewers = [ + '' + ], + reviewers_obj = [ + authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ) + ], + target_verbose = '', + ) + """ + + def testLifecycleRule(self): + """Test LifecycleRule""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_lifecycle_rule_request.py b/test/test_lifecycle_rule_request.py new file mode 100644 index 000000000..2da6b6e11 --- /dev/null +++ b/test/test_lifecycle_rule_request.py @@ -0,0 +1,72 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.lifecycle_rule_request import LifecycleRuleRequest + +class TestLifecycleRuleRequest(unittest.TestCase): + """LifecycleRuleRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LifecycleRuleRequest: + """Test LifecycleRuleRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LifecycleRuleRequest` + """ + model = LifecycleRuleRequest() + if include_optional: + return LifecycleRuleRequest( + name = '0', + content_type = 'authentik_core.application', + object_id = '0', + interval = '0', + grace_period = '0', + reviewer_groups = [ + '' + ], + min_reviewers = 0, + min_reviewers_is_per_group = True, + reviewers = [ + '' + ], + notification_transports = [ + '' + ] + ) + else: + return LifecycleRuleRequest( + name = '0', + content_type = 'authentik_core.application', + reviewers = [ + '' + ], + ) + """ + + def testLifecycleRuleRequest(self): + """Test LifecycleRuleRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_link.py b/test/test_link.py new file mode 100644 index 000000000..37f438e2f --- /dev/null +++ b/test/test_link.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.link import Link + +class TestLink(unittest.TestCase): + """Link unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Link: + """Test Link + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Link` + """ + model = Link() + if include_optional: + return Link( + link = '' + ) + else: + return Link( + link = '', + ) + """ + + def testLink(self): + """Test Link""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_log_event.py b/test/test_log_event.py new file mode 100644 index 000000000..388d032a3 --- /dev/null +++ b/test/test_log_event.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.log_event import LogEvent + +class TestLogEvent(unittest.TestCase): + """LogEvent unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LogEvent: + """Test LogEvent + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LogEvent` + """ + model = LogEvent() + if include_optional: + return LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + } + ) + else: + return LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, + ) + """ + + def testLogEvent(self): + """Test LogEvent""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_log_level_enum.py b/test/test_log_level_enum.py new file mode 100644 index 000000000..68a9d8f6d --- /dev/null +++ b/test/test_log_level_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.log_level_enum import LogLevelEnum + +class TestLogLevelEnum(unittest.TestCase): + """LogLevelEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testLogLevelEnum(self): + """Test LogLevelEnum""" + # inst = LogLevelEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_login_challenge_types.py b/test/test_login_challenge_types.py new file mode 100644 index 000000000..cdcf2104f --- /dev/null +++ b/test/test_login_challenge_types.py @@ -0,0 +1,81 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.login_challenge_types import LoginChallengeTypes + +class TestLoginChallengeTypes(unittest.TestCase): + """LoginChallengeTypes unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LoginChallengeTypes: + """Test LoginChallengeTypes + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LoginChallengeTypes` + """ + model = LoginChallengeTypes() + if include_optional: + return LoginChallengeTypes( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-source-telegram', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + to = '', + client_id = '', + scope = '', + redirect_uri = '', + state = '', + slug = '', + bot_username = '', + request_message_access = True + ) + else: + return LoginChallengeTypes( + to = '', + client_id = '', + scope = '', + redirect_uri = '', + state = '', + slug = '', + bot_username = '', + request_message_access = True, + ) + """ + + def testLoginChallengeTypes(self): + """Test LoginChallengeTypes""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_login_source.py b/test/test_login_source.py new file mode 100644 index 000000000..f2a47c3e4 --- /dev/null +++ b/test/test_login_source.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.login_source import LoginSource + +class TestLoginSource(unittest.TestCase): + """LoginSource unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LoginSource: + """Test LoginSource + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LoginSource` + """ + model = LoginSource() + if include_optional: + return LoginSource( + name = '', + icon_url = '', + promoted = True, + challenge = None + ) + else: + return LoginSource( + name = '', + challenge = None, + ) + """ + + def testLoginSource(self): + """Test LoginSource""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_logout_url.py b/test/test_logout_url.py new file mode 100644 index 000000000..ba21e9c3a --- /dev/null +++ b/test/test_logout_url.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.logout_url import LogoutURL + +class TestLogoutURL(unittest.TestCase): + """LogoutURL unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> LogoutURL: + """Test LogoutURL + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `LogoutURL` + """ + model = LogoutURL() + if include_optional: + return LogoutURL( + url = '', + provider_name = '', + binding = '', + saml_request = '', + saml_response = '', + saml_relay_state = '' + ) + else: + return LogoutURL( + url = '', + ) + """ + + def testLogoutURL(self): + """Test LogoutURL""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_managed_api.py b/test/test_managed_api.py new file mode 100644 index 000000000..2b10925bf --- /dev/null +++ b/test/test_managed_api.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.managed_api import ManagedApi + + +class TestManagedApi(unittest.TestCase): + """ManagedApi unit test stubs""" + + def setUp(self) -> None: + self.api = ManagedApi() + + def tearDown(self) -> None: + pass + + def test_managed_blueprints_apply_create(self) -> None: + """Test case for managed_blueprints_apply_create + + """ + pass + + def test_managed_blueprints_available_list(self) -> None: + """Test case for managed_blueprints_available_list + + """ + pass + + def test_managed_blueprints_create(self) -> None: + """Test case for managed_blueprints_create + + """ + pass + + def test_managed_blueprints_destroy(self) -> None: + """Test case for managed_blueprints_destroy + + """ + pass + + def test_managed_blueprints_import_create(self) -> None: + """Test case for managed_blueprints_import_create + + """ + pass + + def test_managed_blueprints_list(self) -> None: + """Test case for managed_blueprints_list + + """ + pass + + def test_managed_blueprints_partial_update(self) -> None: + """Test case for managed_blueprints_partial_update + + """ + pass + + def test_managed_blueprints_retrieve(self) -> None: + """Test case for managed_blueprints_retrieve + + """ + pass + + def test_managed_blueprints_update(self) -> None: + """Test case for managed_blueprints_update + + """ + pass + + def test_managed_blueprints_used_by_list(self) -> None: + """Test case for managed_blueprints_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_matching_mode_enum.py b/test/test_matching_mode_enum.py new file mode 100644 index 000000000..cd86a8a00 --- /dev/null +++ b/test/test_matching_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.matching_mode_enum import MatchingModeEnum + +class TestMatchingModeEnum(unittest.TestCase): + """MatchingModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testMatchingModeEnum(self): + """Test MatchingModeEnum""" + # inst = MatchingModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_mdm_config_request.py b/test/test_mdm_config_request.py new file mode 100644 index 000000000..d6674ae4e --- /dev/null +++ b/test/test_mdm_config_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.mdm_config_request import MDMConfigRequest + +class TestMDMConfigRequest(unittest.TestCase): + """MDMConfigRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MDMConfigRequest: + """Test MDMConfigRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MDMConfigRequest` + """ + model = MDMConfigRequest() + if include_optional: + return MDMConfigRequest( + platform = 'linux', + enrollment_token = '' + ) + else: + return MDMConfigRequest( + platform = 'linux', + enrollment_token = '', + ) + """ + + def testMDMConfigRequest(self): + """Test MDMConfigRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_mdm_config_response.py b/test/test_mdm_config_response.py new file mode 100644 index 000000000..20a08bc93 --- /dev/null +++ b/test/test_mdm_config_response.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.mdm_config_response import MDMConfigResponse + +class TestMDMConfigResponse(unittest.TestCase): + """MDMConfigResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MDMConfigResponse: + """Test MDMConfigResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MDMConfigResponse` + """ + model = MDMConfigResponse() + if include_optional: + return MDMConfigResponse( + config = '', + mime_type = '', + filename = '' + ) + else: + return MDMConfigResponse( + config = '', + mime_type = '', + filename = '', + ) + """ + + def testMDMConfigResponse(self): + """Test MDMConfigResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_metadata.py b/test/test_metadata.py new file mode 100644 index 000000000..eb4f1b9ac --- /dev/null +++ b/test/test_metadata.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.metadata import Metadata + +class TestMetadata(unittest.TestCase): + """Metadata unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Metadata: + """Test Metadata + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Metadata` + """ + model = Metadata() + if include_optional: + return Metadata( + name = '', + labels = { + 'key' : null + } + ) + else: + return Metadata( + name = '', + labels = { + 'key' : null + }, + ) + """ + + def testMetadata(self): + """Test Metadata""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_microsoft_entra_provider.py b/test/test_microsoft_entra_provider.py new file mode 100644 index 000000000..6cb3cceaf --- /dev/null +++ b/test/test_microsoft_entra_provider.py @@ -0,0 +1,86 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.microsoft_entra_provider import MicrosoftEntraProvider + +class TestMicrosoftEntraProvider(unittest.TestCase): + """MicrosoftEntraProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MicrosoftEntraProvider: + """Test MicrosoftEntraProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MicrosoftEntraProvider` + """ + model = MicrosoftEntraProvider() + if include_optional: + return MicrosoftEntraProvider( + pk = 56, + name = '', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_id = '', + client_secret = '', + tenant_id = '', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + sync_page_size = 1, + sync_page_timeout = '', + dry_run = True + ) + else: + return MicrosoftEntraProvider( + pk = 56, + name = '', + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_id = '', + client_secret = '', + tenant_id = '', + ) + """ + + def testMicrosoftEntraProvider(self): + """Test MicrosoftEntraProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_microsoft_entra_provider_group.py b/test/test_microsoft_entra_provider_group.py new file mode 100644 index 000000000..c0251edee --- /dev/null +++ b/test/test_microsoft_entra_provider_group.py @@ -0,0 +1,81 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.microsoft_entra_provider_group import MicrosoftEntraProviderGroup + +class TestMicrosoftEntraProviderGroup(unittest.TestCase): + """MicrosoftEntraProviderGroup unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MicrosoftEntraProviderGroup: + """Test MicrosoftEntraProviderGroup + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MicrosoftEntraProviderGroup` + """ + model = MicrosoftEntraProviderGroup() + if include_optional: + return MicrosoftEntraProviderGroup( + id = '', + microsoft_id = '', + group = '', + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + provider = 56, + attributes = { + 'key' : null + } + ) + else: + return MicrosoftEntraProviderGroup( + id = '', + microsoft_id = '', + group = '', + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + provider = 56, + attributes = { + 'key' : null + }, + ) + """ + + def testMicrosoftEntraProviderGroup(self): + """Test MicrosoftEntraProviderGroup""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_microsoft_entra_provider_group_request.py b/test/test_microsoft_entra_provider_group_request.py new file mode 100644 index 000000000..7c3819977 --- /dev/null +++ b/test/test_microsoft_entra_provider_group_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.microsoft_entra_provider_group_request import MicrosoftEntraProviderGroupRequest + +class TestMicrosoftEntraProviderGroupRequest(unittest.TestCase): + """MicrosoftEntraProviderGroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MicrosoftEntraProviderGroupRequest: + """Test MicrosoftEntraProviderGroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MicrosoftEntraProviderGroupRequest` + """ + model = MicrosoftEntraProviderGroupRequest() + if include_optional: + return MicrosoftEntraProviderGroupRequest( + microsoft_id = '0', + group = '', + provider = 56 + ) + else: + return MicrosoftEntraProviderGroupRequest( + microsoft_id = '0', + group = '', + provider = 56, + ) + """ + + def testMicrosoftEntraProviderGroupRequest(self): + """Test MicrosoftEntraProviderGroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_microsoft_entra_provider_mapping.py b/test/test_microsoft_entra_provider_mapping.py new file mode 100644 index 000000000..da93e4a9d --- /dev/null +++ b/test/test_microsoft_entra_provider_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.microsoft_entra_provider_mapping import MicrosoftEntraProviderMapping + +class TestMicrosoftEntraProviderMapping(unittest.TestCase): + """MicrosoftEntraProviderMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MicrosoftEntraProviderMapping: + """Test MicrosoftEntraProviderMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MicrosoftEntraProviderMapping` + """ + model = MicrosoftEntraProviderMapping() + if include_optional: + return MicrosoftEntraProviderMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return MicrosoftEntraProviderMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testMicrosoftEntraProviderMapping(self): + """Test MicrosoftEntraProviderMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_microsoft_entra_provider_mapping_request.py b/test/test_microsoft_entra_provider_mapping_request.py new file mode 100644 index 000000000..5d26b7d82 --- /dev/null +++ b/test/test_microsoft_entra_provider_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.microsoft_entra_provider_mapping_request import MicrosoftEntraProviderMappingRequest + +class TestMicrosoftEntraProviderMappingRequest(unittest.TestCase): + """MicrosoftEntraProviderMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MicrosoftEntraProviderMappingRequest: + """Test MicrosoftEntraProviderMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MicrosoftEntraProviderMappingRequest` + """ + model = MicrosoftEntraProviderMappingRequest() + if include_optional: + return MicrosoftEntraProviderMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return MicrosoftEntraProviderMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testMicrosoftEntraProviderMappingRequest(self): + """Test MicrosoftEntraProviderMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_microsoft_entra_provider_request.py b/test/test_microsoft_entra_provider_request.py new file mode 100644 index 000000000..277c79702 --- /dev/null +++ b/test/test_microsoft_entra_provider_request.py @@ -0,0 +1,72 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.microsoft_entra_provider_request import MicrosoftEntraProviderRequest + +class TestMicrosoftEntraProviderRequest(unittest.TestCase): + """MicrosoftEntraProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MicrosoftEntraProviderRequest: + """Test MicrosoftEntraProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MicrosoftEntraProviderRequest` + """ + model = MicrosoftEntraProviderRequest() + if include_optional: + return MicrosoftEntraProviderRequest( + name = '0', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + client_id = '0', + client_secret = '0', + tenant_id = '0', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + sync_page_size = 1, + sync_page_timeout = '0', + dry_run = True + ) + else: + return MicrosoftEntraProviderRequest( + name = '0', + client_id = '0', + client_secret = '0', + tenant_id = '0', + ) + """ + + def testMicrosoftEntraProviderRequest(self): + """Test MicrosoftEntraProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_microsoft_entra_provider_user.py b/test/test_microsoft_entra_provider_user.py new file mode 100644 index 000000000..3945775fe --- /dev/null +++ b/test/test_microsoft_entra_provider_user.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.microsoft_entra_provider_user import MicrosoftEntraProviderUser + +class TestMicrosoftEntraProviderUser(unittest.TestCase): + """MicrosoftEntraProviderUser unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MicrosoftEntraProviderUser: + """Test MicrosoftEntraProviderUser + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MicrosoftEntraProviderUser` + """ + model = MicrosoftEntraProviderUser() + if include_optional: + return MicrosoftEntraProviderUser( + id = '', + microsoft_id = '', + user = 56, + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + provider = 56, + attributes = { + 'key' : null + } + ) + else: + return MicrosoftEntraProviderUser( + id = '', + microsoft_id = '', + user = 56, + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + provider = 56, + attributes = { + 'key' : null + }, + ) + """ + + def testMicrosoftEntraProviderUser(self): + """Test MicrosoftEntraProviderUser""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_microsoft_entra_provider_user_request.py b/test/test_microsoft_entra_provider_user_request.py new file mode 100644 index 000000000..51c8c0310 --- /dev/null +++ b/test/test_microsoft_entra_provider_user_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.microsoft_entra_provider_user_request import MicrosoftEntraProviderUserRequest + +class TestMicrosoftEntraProviderUserRequest(unittest.TestCase): + """MicrosoftEntraProviderUserRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MicrosoftEntraProviderUserRequest: + """Test MicrosoftEntraProviderUserRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MicrosoftEntraProviderUserRequest` + """ + model = MicrosoftEntraProviderUserRequest() + if include_optional: + return MicrosoftEntraProviderUserRequest( + microsoft_id = '0', + user = 56, + provider = 56 + ) + else: + return MicrosoftEntraProviderUserRequest( + microsoft_id = '0', + user = 56, + provider = 56, + ) + """ + + def testMicrosoftEntraProviderUserRequest(self): + """Test MicrosoftEntraProviderUserRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_model_enum.py b/test/test_model_enum.py new file mode 100644 index 000000000..fa326ca98 --- /dev/null +++ b/test/test_model_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.model_enum import ModelEnum + +class TestModelEnum(unittest.TestCase): + """ModelEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testModelEnum(self): + """Test ModelEnum""" + # inst = ModelEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_model_request.py b/test/test_model_request.py new file mode 100644 index 000000000..6155bd6e3 --- /dev/null +++ b/test/test_model_request.py @@ -0,0 +1,194 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.model_request import ModelRequest + +class TestModelRequest(unittest.TestCase): + """ModelRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ModelRequest: + """Test ModelRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ModelRequest` + """ + model = ModelRequest() + if include_optional: + return ModelRequest( + name = '0', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + delegated_subject = '0', + credentials = { + 'key' : None + }, + scopes = '0', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + default_group_email_domain = '0', + sync_page_size = 1, + sync_page_timeout = '0', + dry_run = True, + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + base_dn = '0', + certificate = '', + tls_server_name = '', + uid_start_number = -2147483648, + gid_start_number = -2147483648, + search_mode = 'direct', + bind_mode = 'direct', + mfa_support = True, + client_id = '0', + client_secret = '', + tenant_id = '0', + client_type = 'confidential', + grant_types = [ + 'authorization_code' + ], + access_code_validity = '0', + access_token_validity = '0', + refresh_token_validity = '0', + refresh_token_threshold = '0', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri_request.RedirectURIRequest( + matching_mode = 'strict', + url = '0', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = 'frontchannel_iframe', + sub_mode = 'hashed_user_id', + issuer_mode = 'global', + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], + internal_host = '', + external_host = '0', + internal_host_ssl_validation = True, + skip_path_regex = '', + basic_auth_enabled = True, + basic_auth_password_attribute = '', + basic_auth_user_attribute = '', + mode = 'proxy', + intercept_header_auth = True, + cookie_domain = '', + settings = { + 'key' : None + }, + connection_expiry = '0', + delete_token_on_disconnect = True, + client_networks = '0', + shared_secret = '0', + acs_url = '0', + sls_url = '', + audience = '', + issuer_override = '', + assertion_valid_not_before = '0', + assertion_valid_not_on_or_after = '0', + session_valid_not_on_or_after = '0', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + verification_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_response = True, + sign_logout_request = True, + sign_logout_response = True, + sp_binding = 'redirect', + sls_binding = 'redirect', + default_relay_state = '', + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + url = '0', + verify_certificates = True, + token = '', + auth_mode = 'token', + auth_oauth = '', + auth_oauth_params = { + 'key' : None + }, + compatibility_mode = 'default', + service_provider_config_cache_timeout = '0', + group_filters = [ + '' + ], + oidc_auth_providers = [ + 56 + ], + event_retention = '0', + push_verify_certificates = True, + reply_url = '0', + wtrealm = '0' + ) + else: + return ModelRequest( + name = '0', + delegated_subject = '0', + credentials = { + 'key' : None + }, + default_group_email_domain = '0', + authorization_flow = '', + invalidation_flow = '', + client_id = '0', + client_secret = '', + tenant_id = '0', + signing_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri_request.RedirectURIRequest( + matching_mode = 'strict', + url = '0', + redirect_uri_type = null, ) + ], + external_host = '0', + acs_url = '0', + url = '0', + reply_url = '0', + wtrealm = '0', + ) + """ + + def testModelRequest(self): + """Test ModelRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_mutual_tls_stage.py b/test/test_mutual_tls_stage.py new file mode 100644 index 000000000..fe0c668c6 --- /dev/null +++ b/test/test_mutual_tls_stage.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.mutual_tls_stage import MutualTLSStage + +class TestMutualTLSStage(unittest.TestCase): + """MutualTLSStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MutualTLSStage: + """Test MutualTLSStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MutualTLSStage` + """ + model = MutualTLSStage() + if include_optional: + return MutualTLSStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + mode = 'optional', + certificate_authorities = [ + '' + ], + cert_attribute = 'subject', + user_attribute = 'username' + ) + else: + return MutualTLSStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + mode = 'optional', + cert_attribute = 'subject', + user_attribute = 'username', + ) + """ + + def testMutualTLSStage(self): + """Test MutualTLSStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_mutual_tls_stage_request.py b/test/test_mutual_tls_stage_request.py new file mode 100644 index 000000000..6bbb136ed --- /dev/null +++ b/test/test_mutual_tls_stage_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.mutual_tls_stage_request import MutualTLSStageRequest + +class TestMutualTLSStageRequest(unittest.TestCase): + """MutualTLSStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> MutualTLSStageRequest: + """Test MutualTLSStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `MutualTLSStageRequest` + """ + model = MutualTLSStageRequest() + if include_optional: + return MutualTLSStageRequest( + name = '0', + mode = 'optional', + certificate_authorities = [ + '' + ], + cert_attribute = 'subject', + user_attribute = 'username' + ) + else: + return MutualTLSStageRequest( + name = '0', + mode = 'optional', + cert_attribute = 'subject', + user_attribute = 'username', + ) + """ + + def testMutualTLSStageRequest(self): + """Test MutualTLSStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_native_logout_challenge.py b/test/test_native_logout_challenge.py new file mode 100644 index 000000000..68f6470dd --- /dev/null +++ b/test/test_native_logout_challenge.py @@ -0,0 +1,73 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.native_logout_challenge import NativeLogoutChallenge + +class TestNativeLogoutChallenge(unittest.TestCase): + """NativeLogoutChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NativeLogoutChallenge: + """Test NativeLogoutChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NativeLogoutChallenge` + """ + model = NativeLogoutChallenge() + if include_optional: + return NativeLogoutChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-provider-saml-native-logout', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + provider_name = '', + is_complete = True, + post_url = '', + redirect_url = '', + saml_binding = 'redirect', + saml_request = '', + saml_response = '', + saml_relay_state = '' + ) + else: + return NativeLogoutChallenge( + ) + """ + + def testNativeLogoutChallenge(self): + """Test NativeLogoutChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_native_logout_challenge_response_request.py b/test/test_native_logout_challenge_response_request.py new file mode 100644 index 000000000..d52cf79ae --- /dev/null +++ b/test/test_native_logout_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.native_logout_challenge_response_request import NativeLogoutChallengeResponseRequest + +class TestNativeLogoutChallengeResponseRequest(unittest.TestCase): + """NativeLogoutChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NativeLogoutChallengeResponseRequest: + """Test NativeLogoutChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NativeLogoutChallengeResponseRequest` + """ + model = NativeLogoutChallengeResponseRequest() + if include_optional: + return NativeLogoutChallengeResponseRequest( + component = 'ak-provider-saml-native-logout' + ) + else: + return NativeLogoutChallengeResponseRequest( + ) + """ + + def testNativeLogoutChallengeResponseRequest(self): + """Test NativeLogoutChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_network.py b/test/test_network.py new file mode 100644 index 000000000..f12a612e0 --- /dev/null +++ b/test/test_network.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.network import Network + +class TestNetwork(unittest.TestCase): + """Network unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Network: + """Test Network + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Network` + """ + model = Network() + if include_optional: + return Network( + hostname = '', + firewall_enabled = True, + interfaces = [ + authentik_client.models.network_interface.NetworkInterface( + name = '', + hardware_address = '', + ip_addresses = [ + '' + ], + dns_servers = [ + '' + ], ) + ], + gateway = '' + ) + else: + return Network( + hostname = '', + interfaces = [ + authentik_client.models.network_interface.NetworkInterface( + name = '', + hardware_address = '', + ip_addresses = [ + '' + ], + dns_servers = [ + '' + ], ) + ], + ) + """ + + def testNetwork(self): + """Test Network""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_network_binding_enum.py b/test/test_network_binding_enum.py new file mode 100644 index 000000000..33290748f --- /dev/null +++ b/test/test_network_binding_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.network_binding_enum import NetworkBindingEnum + +class TestNetworkBindingEnum(unittest.TestCase): + """NetworkBindingEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testNetworkBindingEnum(self): + """Test NetworkBindingEnum""" + # inst = NetworkBindingEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_network_interface.py b/test/test_network_interface.py new file mode 100644 index 000000000..b9d3f85ff --- /dev/null +++ b/test/test_network_interface.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.network_interface import NetworkInterface + +class TestNetworkInterface(unittest.TestCase): + """NetworkInterface unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NetworkInterface: + """Test NetworkInterface + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NetworkInterface` + """ + model = NetworkInterface() + if include_optional: + return NetworkInterface( + name = '', + hardware_address = '', + ip_addresses = [ + '' + ], + dns_servers = [ + '' + ] + ) + else: + return NetworkInterface( + name = '', + hardware_address = '', + ) + """ + + def testNetworkInterface(self): + """Test NetworkInterface""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_network_interface_request.py b/test/test_network_interface_request.py new file mode 100644 index 000000000..296cb5b57 --- /dev/null +++ b/test/test_network_interface_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.network_interface_request import NetworkInterfaceRequest + +class TestNetworkInterfaceRequest(unittest.TestCase): + """NetworkInterfaceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NetworkInterfaceRequest: + """Test NetworkInterfaceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NetworkInterfaceRequest` + """ + model = NetworkInterfaceRequest() + if include_optional: + return NetworkInterfaceRequest( + name = '0', + hardware_address = '0', + ip_addresses = [ + '0' + ], + dns_servers = [ + '0' + ] + ) + else: + return NetworkInterfaceRequest( + name = '0', + hardware_address = '0', + ) + """ + + def testNetworkInterfaceRequest(self): + """Test NetworkInterfaceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_network_request.py b/test/test_network_request.py new file mode 100644 index 000000000..65696930d --- /dev/null +++ b/test/test_network_request.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.network_request import NetworkRequest + +class TestNetworkRequest(unittest.TestCase): + """NetworkRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NetworkRequest: + """Test NetworkRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NetworkRequest` + """ + model = NetworkRequest() + if include_optional: + return NetworkRequest( + hostname = '0', + firewall_enabled = True, + interfaces = [ + authentik_client.models.network_interface_request.NetworkInterfaceRequest( + name = '0', + hardware_address = '0', + ip_addresses = [ + '0' + ], + dns_servers = [ + '0' + ], ) + ], + gateway = '0' + ) + else: + return NetworkRequest( + hostname = '0', + interfaces = [ + authentik_client.models.network_interface_request.NetworkInterfaceRequest( + name = '0', + hardware_address = '0', + ip_addresses = [ + '0' + ], + dns_servers = [ + '0' + ], ) + ], + ) + """ + + def testNetworkRequest(self): + """Test NetworkRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_not_configured_action_enum.py b/test/test_not_configured_action_enum.py new file mode 100644 index 000000000..e5bc32c57 --- /dev/null +++ b/test/test_not_configured_action_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.not_configured_action_enum import NotConfiguredActionEnum + +class TestNotConfiguredActionEnum(unittest.TestCase): + """NotConfiguredActionEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testNotConfiguredActionEnum(self): + """Test NotConfiguredActionEnum""" + # inst = NotConfiguredActionEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_notification.py b/test/test_notification.py new file mode 100644 index 000000000..e3f4cf02e --- /dev/null +++ b/test/test_notification.py @@ -0,0 +1,78 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.notification import Notification + +class TestNotification(unittest.TestCase): + """Notification unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Notification: + """Test Notification + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Notification` + """ + model = Notification() + if include_optional: + return Notification( + pk = '', + severity = 'notice', + body = '', + hyperlink = '', + hyperlink_label = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + event = authentik_client.models.event.Event( + pk = '', + user = { + 'key' : null + }, + action = 'login', + app = '', + context = { + 'key' : null + }, + client_ip = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + }, ), + seen = True + ) + else: + return Notification( + pk = '', + severity = 'notice', + body = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testNotification(self): + """Test Notification""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_notification_request.py b/test/test_notification_request.py new file mode 100644 index 000000000..ebcbc0fd4 --- /dev/null +++ b/test/test_notification_request.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.notification_request import NotificationRequest + +class TestNotificationRequest(unittest.TestCase): + """NotificationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NotificationRequest: + """Test NotificationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NotificationRequest` + """ + model = NotificationRequest() + if include_optional: + return NotificationRequest( + hyperlink = '', + hyperlink_label = '', + event = authentik_client.models.event_request.EventRequest( + user = { + 'key' : null + }, + action = 'login', + app = '0', + context = { + 'key' : null + }, + client_ip = '0', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + }, ), + seen = True + ) + else: + return NotificationRequest( + ) + """ + + def testNotificationRequest(self): + """Test NotificationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_notification_rule.py b/test/test_notification_rule.py new file mode 100644 index 000000000..81a555abe --- /dev/null +++ b/test/test_notification_rule.py @@ -0,0 +1,175 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.notification_rule import NotificationRule + +class TestNotificationRule(unittest.TestCase): + """NotificationRule unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NotificationRule: + """Test NotificationRule + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NotificationRule` + """ + model = NotificationRule() + if include_optional: + return NotificationRule( + pk = '', + name = '', + transports = [ + '' + ], + severity = 'notice', + destination_group = '', + destination_group_obj = authentik_client.models.group.Group( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + parents = [ + '' + ], + parents_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, + group_uuid = '', ) + ], + users = [ + 56 + ], + users_obj = [ + authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + uid = '', ) + ], + attributes = { + 'key' : null + }, + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + inherited_roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + children = [ + '' + ], + children_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + group_uuid = '', ) + ], ), + destination_event_user = True + ) + else: + return NotificationRule( + pk = '', + name = '', + destination_group_obj = authentik_client.models.group.Group( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + parents = [ + '' + ], + parents_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, + group_uuid = '', ) + ], + users = [ + 56 + ], + users_obj = [ + authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + uid = '', ) + ], + attributes = { + 'key' : null + }, + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + inherited_roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + children = [ + '' + ], + children_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + group_uuid = '', ) + ], ), + ) + """ + + def testNotificationRule(self): + """Test NotificationRule""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_notification_rule_request.py b/test/test_notification_rule_request.py new file mode 100644 index 000000000..c87d6b2de --- /dev/null +++ b/test/test_notification_rule_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.notification_rule_request import NotificationRuleRequest + +class TestNotificationRuleRequest(unittest.TestCase): + """NotificationRuleRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NotificationRuleRequest: + """Test NotificationRuleRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NotificationRuleRequest` + """ + model = NotificationRuleRequest() + if include_optional: + return NotificationRuleRequest( + name = '0', + transports = [ + '' + ], + severity = 'notice', + destination_group = '', + destination_event_user = True + ) + else: + return NotificationRuleRequest( + name = '0', + ) + """ + + def testNotificationRuleRequest(self): + """Test NotificationRuleRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_notification_transport.py b/test/test_notification_transport.py new file mode 100644 index 000000000..14d9b3e67 --- /dev/null +++ b/test/test_notification_transport.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.notification_transport import NotificationTransport + +class TestNotificationTransport(unittest.TestCase): + """NotificationTransport unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NotificationTransport: + """Test NotificationTransport + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NotificationTransport` + """ + model = NotificationTransport() + if include_optional: + return NotificationTransport( + pk = '', + name = '', + mode = 'local', + mode_verbose = '', + webhook_url = '', + webhook_ca = '', + webhook_mapping_body = '', + webhook_mapping_headers = '', + email_subject_prefix = '', + email_template = '', + send_once = True + ) + else: + return NotificationTransport( + pk = '', + name = '', + mode_verbose = '', + ) + """ + + def testNotificationTransport(self): + """Test NotificationTransport""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_notification_transport_request.py b/test/test_notification_transport_request.py new file mode 100644 index 000000000..89e3b532f --- /dev/null +++ b/test/test_notification_transport_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.notification_transport_request import NotificationTransportRequest + +class TestNotificationTransportRequest(unittest.TestCase): + """NotificationTransportRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NotificationTransportRequest: + """Test NotificationTransportRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NotificationTransportRequest` + """ + model = NotificationTransportRequest() + if include_optional: + return NotificationTransportRequest( + name = '0', + mode = 'local', + webhook_url = '', + webhook_ca = '', + webhook_mapping_body = '', + webhook_mapping_headers = '', + email_subject_prefix = '', + email_template = '0', + send_once = True + ) + else: + return NotificationTransportRequest( + name = '0', + ) + """ + + def testNotificationTransportRequest(self): + """Test NotificationTransportRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_notification_transport_test.py b/test/test_notification_transport_test.py new file mode 100644 index 000000000..f66cbcfcb --- /dev/null +++ b/test/test_notification_transport_test.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.notification_transport_test import NotificationTransportTest + +class TestNotificationTransportTest(unittest.TestCase): + """NotificationTransportTest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NotificationTransportTest: + """Test NotificationTransportTest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NotificationTransportTest` + """ + model = NotificationTransportTest() + if include_optional: + return NotificationTransportTest( + messages = [ + '' + ] + ) + else: + return NotificationTransportTest( + messages = [ + '' + ], + ) + """ + + def testNotificationTransportTest(self): + """Test NotificationTransportTest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_notification_webhook_mapping.py b/test/test_notification_webhook_mapping.py new file mode 100644 index 000000000..4fe605961 --- /dev/null +++ b/test/test_notification_webhook_mapping.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.notification_webhook_mapping import NotificationWebhookMapping + +class TestNotificationWebhookMapping(unittest.TestCase): + """NotificationWebhookMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NotificationWebhookMapping: + """Test NotificationWebhookMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NotificationWebhookMapping` + """ + model = NotificationWebhookMapping() + if include_optional: + return NotificationWebhookMapping( + pk = '', + name = '', + expression = '' + ) + else: + return NotificationWebhookMapping( + pk = '', + name = '', + expression = '', + ) + """ + + def testNotificationWebhookMapping(self): + """Test NotificationWebhookMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_notification_webhook_mapping_request.py b/test/test_notification_webhook_mapping_request.py new file mode 100644 index 000000000..0f2549d3d --- /dev/null +++ b/test/test_notification_webhook_mapping_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.notification_webhook_mapping_request import NotificationWebhookMappingRequest + +class TestNotificationWebhookMappingRequest(unittest.TestCase): + """NotificationWebhookMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> NotificationWebhookMappingRequest: + """Test NotificationWebhookMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `NotificationWebhookMappingRequest` + """ + model = NotificationWebhookMappingRequest() + if include_optional: + return NotificationWebhookMappingRequest( + name = '0', + expression = '0' + ) + else: + return NotificationWebhookMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testNotificationWebhookMappingRequest(self): + """Test NotificationWebhookMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth2_provider.py b/test/test_o_auth2_provider.py new file mode 100644 index 000000000..ede767c80 --- /dev/null +++ b/test/test_o_auth2_provider.py @@ -0,0 +1,114 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth2_provider import OAuth2Provider + +class TestOAuth2Provider(unittest.TestCase): + """OAuth2Provider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuth2Provider: + """Test OAuth2Provider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuth2Provider` + """ + model = OAuth2Provider() + if include_optional: + return OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = 'confidential', + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = 'backchannel', + sub_mode = 'hashed_user_id', + issuer_mode = 'global', + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ] + ) + else: + return OAuth2Provider( + pk = 56, + name = '', + authorization_flow = '', + invalidation_flow = '', + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + ) + """ + + def testOAuth2Provider(self): + """Test OAuth2Provider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth2_provider_logout_method_enum.py b/test/test_o_auth2_provider_logout_method_enum.py new file mode 100644 index 000000000..351554076 --- /dev/null +++ b/test/test_o_auth2_provider_logout_method_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth2_provider_logout_method_enum import OAuth2ProviderLogoutMethodEnum + +class TestOAuth2ProviderLogoutMethodEnum(unittest.TestCase): + """OAuth2ProviderLogoutMethodEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testOAuth2ProviderLogoutMethodEnum(self): + """Test OAuth2ProviderLogoutMethodEnum""" + # inst = OAuth2ProviderLogoutMethodEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth2_provider_request.py b/test/test_o_auth2_provider_request.py new file mode 100644 index 000000000..87eb892aa --- /dev/null +++ b/test/test_o_auth2_provider_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth2_provider_request import OAuth2ProviderRequest + +class TestOAuth2ProviderRequest(unittest.TestCase): + """OAuth2ProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuth2ProviderRequest: + """Test OAuth2ProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuth2ProviderRequest` + """ + model = OAuth2ProviderRequest() + if include_optional: + return OAuth2ProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + client_type = 'confidential', + grant_types = [ + 'authorization_code' + ], + client_id = '0', + client_secret = '', + access_code_validity = '0', + access_token_validity = '0', + refresh_token_validity = '0', + refresh_token_threshold = '0', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri_request.RedirectURIRequest( + matching_mode = 'strict', + url = '0', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = 'backchannel', + sub_mode = 'hashed_user_id', + issuer_mode = 'global', + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ] + ) + else: + return OAuth2ProviderRequest( + name = '0', + authorization_flow = '', + invalidation_flow = '', + redirect_uris = [ + authentik_client.models.redirect_uri_request.RedirectURIRequest( + matching_mode = 'strict', + url = '0', + redirect_uri_type = null, ) + ], + ) + """ + + def testOAuth2ProviderRequest(self): + """Test OAuth2ProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth2_provider_setup_urls.py b/test/test_o_auth2_provider_setup_urls.py new file mode 100644 index 000000000..5d3981bda --- /dev/null +++ b/test/test_o_auth2_provider_setup_urls.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth2_provider_setup_urls import OAuth2ProviderSetupURLs + +class TestOAuth2ProviderSetupURLs(unittest.TestCase): + """OAuth2ProviderSetupURLs unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuth2ProviderSetupURLs: + """Test OAuth2ProviderSetupURLs + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuth2ProviderSetupURLs` + """ + model = OAuth2ProviderSetupURLs() + if include_optional: + return OAuth2ProviderSetupURLs( + issuer = '', + authorize = '', + token = '', + user_info = '', + provider_info = '', + logout = '', + jwks = '' + ) + else: + return OAuth2ProviderSetupURLs( + issuer = '', + authorize = '', + token = '', + user_info = '', + provider_info = '', + logout = '', + jwks = '', + ) + """ + + def testOAuth2ProviderSetupURLs(self): + """Test OAuth2ProviderSetupURLs""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth_device_code_challenge.py b/test/test_o_auth_device_code_challenge.py new file mode 100644 index 000000000..902e335ae --- /dev/null +++ b/test/test_o_auth_device_code_challenge.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth_device_code_challenge import OAuthDeviceCodeChallenge + +class TestOAuthDeviceCodeChallenge(unittest.TestCase): + """OAuthDeviceCodeChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuthDeviceCodeChallenge: + """Test OAuthDeviceCodeChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuthDeviceCodeChallenge` + """ + model = OAuthDeviceCodeChallenge() + if include_optional: + return OAuthDeviceCodeChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-provider-oauth2-device-code', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + } + ) + else: + return OAuthDeviceCodeChallenge( + ) + """ + + def testOAuthDeviceCodeChallenge(self): + """Test OAuthDeviceCodeChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth_device_code_challenge_response_request.py b/test/test_o_auth_device_code_challenge_response_request.py new file mode 100644 index 000000000..f3fb9e629 --- /dev/null +++ b/test/test_o_auth_device_code_challenge_response_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth_device_code_challenge_response_request import OAuthDeviceCodeChallengeResponseRequest + +class TestOAuthDeviceCodeChallengeResponseRequest(unittest.TestCase): + """OAuthDeviceCodeChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuthDeviceCodeChallengeResponseRequest: + """Test OAuthDeviceCodeChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuthDeviceCodeChallengeResponseRequest` + """ + model = OAuthDeviceCodeChallengeResponseRequest() + if include_optional: + return OAuthDeviceCodeChallengeResponseRequest( + component = 'ak-provider-oauth2-device-code', + code = '0' + ) + else: + return OAuthDeviceCodeChallengeResponseRequest( + code = '0', + ) + """ + + def testOAuthDeviceCodeChallengeResponseRequest(self): + """Test OAuthDeviceCodeChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth_device_code_finish_challenge.py b/test/test_o_auth_device_code_finish_challenge.py new file mode 100644 index 000000000..e35127318 --- /dev/null +++ b/test/test_o_auth_device_code_finish_challenge.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth_device_code_finish_challenge import OAuthDeviceCodeFinishChallenge + +class TestOAuthDeviceCodeFinishChallenge(unittest.TestCase): + """OAuthDeviceCodeFinishChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuthDeviceCodeFinishChallenge: + """Test OAuthDeviceCodeFinishChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuthDeviceCodeFinishChallenge` + """ + model = OAuthDeviceCodeFinishChallenge() + if include_optional: + return OAuthDeviceCodeFinishChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-provider-oauth2-device-code-finish', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + } + ) + else: + return OAuthDeviceCodeFinishChallenge( + ) + """ + + def testOAuthDeviceCodeFinishChallenge(self): + """Test OAuthDeviceCodeFinishChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth_device_code_finish_challenge_response_request.py b/test/test_o_auth_device_code_finish_challenge_response_request.py new file mode 100644 index 000000000..a344f5ab4 --- /dev/null +++ b/test/test_o_auth_device_code_finish_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth_device_code_finish_challenge_response_request import OAuthDeviceCodeFinishChallengeResponseRequest + +class TestOAuthDeviceCodeFinishChallengeResponseRequest(unittest.TestCase): + """OAuthDeviceCodeFinishChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuthDeviceCodeFinishChallengeResponseRequest: + """Test OAuthDeviceCodeFinishChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuthDeviceCodeFinishChallengeResponseRequest` + """ + model = OAuthDeviceCodeFinishChallengeResponseRequest() + if include_optional: + return OAuthDeviceCodeFinishChallengeResponseRequest( + component = 'ak-provider-oauth2-device-code-finish' + ) + else: + return OAuthDeviceCodeFinishChallengeResponseRequest( + ) + """ + + def testOAuthDeviceCodeFinishChallengeResponseRequest(self): + """Test OAuthDeviceCodeFinishChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth_source.py b/test/test_o_auth_source.py new file mode 100644 index 000000000..3d5c63220 --- /dev/null +++ b/test/test_o_auth_source.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth_source import OAuthSource + +class TestOAuthSource(unittest.TestCase): + """OAuthSource unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuthSource: + """Test OAuthSource + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuthSource` + """ + model = OAuthSource() + if include_optional: + return OAuthSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + group_matching_mode = 'identifier', + provider_type = 'apple', + request_token_url = '', + authorization_url = '', + access_token_url = '', + profile_url = '', + pkce = 'none', + consumer_key = '', + callback_url = '', + additional_scopes = '', + type = authentik_client.models.source_type.SourceType( + name = '', + verbose_name = '', + urls_customizable = True, + request_token_url = '', + authorization_url = '', + access_token_url = '', + profile_url = '', + oidc_well_known_url = '', + oidc_jwks_url = '', ), + oidc_well_known_url = '', + oidc_jwks_url = '', + oidc_jwks = { + 'key' : null + }, + authorization_code_auth_method = 'basic_auth' + ) + else: + return OAuthSource( + pk = '', + name = '', + slug = 'z', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + provider_type = 'apple', + consumer_key = '', + callback_url = '', + type = authentik_client.models.source_type.SourceType( + name = '', + verbose_name = '', + urls_customizable = True, + request_token_url = '', + authorization_url = '', + access_token_url = '', + profile_url = '', + oidc_well_known_url = '', + oidc_jwks_url = '', ), + ) + """ + + def testOAuthSource(self): + """Test OAuthSource""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth_source_property_mapping.py b/test/test_o_auth_source_property_mapping.py new file mode 100644 index 000000000..0ef50f093 --- /dev/null +++ b/test/test_o_auth_source_property_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth_source_property_mapping import OAuthSourcePropertyMapping + +class TestOAuthSourcePropertyMapping(unittest.TestCase): + """OAuthSourcePropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuthSourcePropertyMapping: + """Test OAuthSourcePropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuthSourcePropertyMapping` + """ + model = OAuthSourcePropertyMapping() + if include_optional: + return OAuthSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return OAuthSourcePropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testOAuthSourcePropertyMapping(self): + """Test OAuthSourcePropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth_source_property_mapping_request.py b/test/test_o_auth_source_property_mapping_request.py new file mode 100644 index 000000000..9fb2e9fad --- /dev/null +++ b/test/test_o_auth_source_property_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth_source_property_mapping_request import OAuthSourcePropertyMappingRequest + +class TestOAuthSourcePropertyMappingRequest(unittest.TestCase): + """OAuthSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuthSourcePropertyMappingRequest: + """Test OAuthSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuthSourcePropertyMappingRequest` + """ + model = OAuthSourcePropertyMappingRequest() + if include_optional: + return OAuthSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return OAuthSourcePropertyMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testOAuthSourcePropertyMappingRequest(self): + """Test OAuthSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_o_auth_source_request.py b/test/test_o_auth_source_request.py new file mode 100644 index 000000000..5533dc5cb --- /dev/null +++ b/test/test_o_auth_source_request.py @@ -0,0 +1,88 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.o_auth_source_request import OAuthSourceRequest + +class TestOAuthSourceRequest(unittest.TestCase): + """OAuthSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OAuthSourceRequest: + """Test OAuthSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OAuthSourceRequest` + """ + model = OAuthSourceRequest() + if include_optional: + return OAuthSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + group_matching_mode = 'identifier', + provider_type = 'apple', + request_token_url = '', + authorization_url = '', + access_token_url = '', + profile_url = '', + pkce = 'none', + consumer_key = '0', + consumer_secret = '0', + additional_scopes = '', + oidc_well_known_url = '', + oidc_jwks_url = '', + oidc_jwks = { + 'key' : null + }, + authorization_code_auth_method = 'basic_auth' + ) + else: + return OAuthSourceRequest( + name = '0', + slug = 'z0', + provider_type = 'apple', + consumer_key = '0', + consumer_secret = '0', + ) + """ + + def testOAuthSourceRequest(self): + """Test OAuthSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_oauth2_api.py b/test/test_oauth2_api.py new file mode 100644 index 000000000..e14e64dbb --- /dev/null +++ b/test/test_oauth2_api.py @@ -0,0 +1,104 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.oauth2_api import Oauth2Api + + +class TestOauth2Api(unittest.TestCase): + """Oauth2Api unit test stubs""" + + def setUp(self) -> None: + self.api = Oauth2Api() + + def tearDown(self) -> None: + pass + + def test_oauth2_access_tokens_destroy(self) -> None: + """Test case for oauth2_access_tokens_destroy + + """ + pass + + def test_oauth2_access_tokens_list(self) -> None: + """Test case for oauth2_access_tokens_list + + """ + pass + + def test_oauth2_access_tokens_retrieve(self) -> None: + """Test case for oauth2_access_tokens_retrieve + + """ + pass + + def test_oauth2_access_tokens_used_by_list(self) -> None: + """Test case for oauth2_access_tokens_used_by_list + + """ + pass + + def test_oauth2_authorization_codes_destroy(self) -> None: + """Test case for oauth2_authorization_codes_destroy + + """ + pass + + def test_oauth2_authorization_codes_list(self) -> None: + """Test case for oauth2_authorization_codes_list + + """ + pass + + def test_oauth2_authorization_codes_retrieve(self) -> None: + """Test case for oauth2_authorization_codes_retrieve + + """ + pass + + def test_oauth2_authorization_codes_used_by_list(self) -> None: + """Test case for oauth2_authorization_codes_used_by_list + + """ + pass + + def test_oauth2_refresh_tokens_destroy(self) -> None: + """Test case for oauth2_refresh_tokens_destroy + + """ + pass + + def test_oauth2_refresh_tokens_list(self) -> None: + """Test case for oauth2_refresh_tokens_list + + """ + pass + + def test_oauth2_refresh_tokens_retrieve(self) -> None: + """Test case for oauth2_refresh_tokens_retrieve + + """ + pass + + def test_oauth2_refresh_tokens_used_by_list(self) -> None: + """Test case for oauth2_refresh_tokens_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_open_id_connect_configuration.py b/test/test_open_id_connect_configuration.py new file mode 100644 index 000000000..519781794 --- /dev/null +++ b/test/test_open_id_connect_configuration.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.open_id_connect_configuration import OpenIDConnectConfiguration + +class TestOpenIDConnectConfiguration(unittest.TestCase): + """OpenIDConnectConfiguration unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OpenIDConnectConfiguration: + """Test OpenIDConnectConfiguration + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OpenIDConnectConfiguration` + """ + model = OpenIDConnectConfiguration() + if include_optional: + return OpenIDConnectConfiguration( + issuer = '', + authorization_endpoint = '', + token_endpoint = '', + userinfo_endpoint = '', + end_session_endpoint = '', + introspection_endpoint = '', + jwks_uri = '', + response_types_supported = [ + '' + ], + id_token_signing_alg_values_supported = [ + '' + ], + subject_types_supported = [ + '' + ], + token_endpoint_auth_methods_supported = [ + '' + ] + ) + else: + return OpenIDConnectConfiguration( + issuer = '', + authorization_endpoint = '', + token_endpoint = '', + userinfo_endpoint = '', + end_session_endpoint = '', + introspection_endpoint = '', + jwks_uri = '', + response_types_supported = [ + '' + ], + id_token_signing_alg_values_supported = [ + '' + ], + subject_types_supported = [ + '' + ], + token_endpoint_auth_methods_supported = [ + '' + ], + ) + """ + + def testOpenIDConnectConfiguration(self): + """Test OpenIDConnectConfiguration""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_operating_system.py b/test/test_operating_system.py new file mode 100644 index 000000000..614345eed --- /dev/null +++ b/test/test_operating_system.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.operating_system import OperatingSystem + +class TestOperatingSystem(unittest.TestCase): + """OperatingSystem unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OperatingSystem: + """Test OperatingSystem + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OperatingSystem` + """ + model = OperatingSystem() + if include_optional: + return OperatingSystem( + family = 'linux', + name = '', + version = '', + arch = '' + ) + else: + return OperatingSystem( + family = 'linux', + ) + """ + + def testOperatingSystem(self): + """Test OperatingSystem""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_operating_system_request.py b/test/test_operating_system_request.py new file mode 100644 index 000000000..8d4a849e1 --- /dev/null +++ b/test/test_operating_system_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.operating_system_request import OperatingSystemRequest + +class TestOperatingSystemRequest(unittest.TestCase): + """OperatingSystemRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OperatingSystemRequest: + """Test OperatingSystemRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OperatingSystemRequest` + """ + model = OperatingSystemRequest() + if include_optional: + return OperatingSystemRequest( + family = 'linux', + name = '0', + version = '0', + arch = '0' + ) + else: + return OperatingSystemRequest( + family = 'linux', + ) + """ + + def testOperatingSystemRequest(self): + """Test OperatingSystemRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_outgoing_sync_delete_action.py b/test/test_outgoing_sync_delete_action.py new file mode 100644 index 000000000..47683c417 --- /dev/null +++ b/test/test_outgoing_sync_delete_action.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.outgoing_sync_delete_action import OutgoingSyncDeleteAction + +class TestOutgoingSyncDeleteAction(unittest.TestCase): + """OutgoingSyncDeleteAction unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testOutgoingSyncDeleteAction(self): + """Test OutgoingSyncDeleteAction""" + # inst = OutgoingSyncDeleteAction() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_outpost.py b/test/test_outpost.py new file mode 100644 index 000000000..9767fb2db --- /dev/null +++ b/test/test_outpost.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.outpost import Outpost + +class TestOutpost(unittest.TestCase): + """Outpost unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Outpost: + """Test Outpost + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Outpost` + """ + model = Outpost() + if include_optional: + return Outpost( + pk = '', + name = '', + type = 'proxy', + providers = [ + 56 + ], + providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + service_connection = '', + service_connection_obj = authentik_client.models.service_connection.ServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ), + refresh_interval_s = 56, + token_identifier = '', + config = { + 'key' : null + }, + managed = '' + ) + else: + return Outpost( + pk = '', + name = '', + type = 'proxy', + providers = [ + 56 + ], + providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + service_connection_obj = authentik_client.models.service_connection.ServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ), + refresh_interval_s = 56, + token_identifier = '', + config = { + 'key' : null + }, + ) + """ + + def testOutpost(self): + """Test Outpost""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_outpost_default_config.py b/test/test_outpost_default_config.py new file mode 100644 index 000000000..7dce96c11 --- /dev/null +++ b/test/test_outpost_default_config.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.outpost_default_config import OutpostDefaultConfig + +class TestOutpostDefaultConfig(unittest.TestCase): + """OutpostDefaultConfig unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OutpostDefaultConfig: + """Test OutpostDefaultConfig + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OutpostDefaultConfig` + """ + model = OutpostDefaultConfig() + if include_optional: + return OutpostDefaultConfig( + config = { + 'key' : null + } + ) + else: + return OutpostDefaultConfig( + config = { + 'key' : null + }, + ) + """ + + def testOutpostDefaultConfig(self): + """Test OutpostDefaultConfig""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_outpost_health.py b/test/test_outpost_health.py new file mode 100644 index 000000000..a154c4b32 --- /dev/null +++ b/test/test_outpost_health.py @@ -0,0 +1,75 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.outpost_health import OutpostHealth + +class TestOutpostHealth(unittest.TestCase): + """OutpostHealth unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OutpostHealth: + """Test OutpostHealth + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OutpostHealth` + """ + model = OutpostHealth() + if include_optional: + return OutpostHealth( + uid = '', + last_seen = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + version = '', + golang_version = '', + openssl_enabled = True, + openssl_version = '', + fips_enabled = True, + version_should = '', + version_outdated = True, + build_hash = '', + build_hash_should = '', + hostname = '' + ) + else: + return OutpostHealth( + uid = '', + last_seen = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + version = '', + golang_version = '', + openssl_enabled = True, + openssl_version = '', + fips_enabled = True, + version_should = '', + version_outdated = True, + build_hash = '', + build_hash_should = '', + hostname = '', + ) + """ + + def testOutpostHealth(self): + """Test OutpostHealth""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_outpost_request.py b/test/test_outpost_request.py new file mode 100644 index 000000000..71140b6ea --- /dev/null +++ b/test/test_outpost_request.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.outpost_request import OutpostRequest + +class TestOutpostRequest(unittest.TestCase): + """OutpostRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> OutpostRequest: + """Test OutpostRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `OutpostRequest` + """ + model = OutpostRequest() + if include_optional: + return OutpostRequest( + name = '0', + type = 'proxy', + providers = [ + 56 + ], + service_connection = '', + config = { + 'key' : null + }, + managed = '0' + ) + else: + return OutpostRequest( + name = '0', + type = 'proxy', + providers = [ + 56 + ], + config = { + 'key' : null + }, + ) + """ + + def testOutpostRequest(self): + """Test OutpostRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_outpost_type_enum.py b/test/test_outpost_type_enum.py new file mode 100644 index 000000000..c07cef37c --- /dev/null +++ b/test/test_outpost_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.outpost_type_enum import OutpostTypeEnum + +class TestOutpostTypeEnum(unittest.TestCase): + """OutpostTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testOutpostTypeEnum(self): + """Test OutpostTypeEnum""" + # inst = OutpostTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_outposts_api.py b/test/test_outposts_api.py new file mode 100644 index 000000000..070fc5adb --- /dev/null +++ b/test/test_outposts_api.py @@ -0,0 +1,236 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.outposts_api import OutpostsApi + + +class TestOutpostsApi(unittest.TestCase): + """OutpostsApi unit test stubs""" + + def setUp(self) -> None: + self.api = OutpostsApi() + + def tearDown(self) -> None: + pass + + def test_outposts_instances_create(self) -> None: + """Test case for outposts_instances_create + + """ + pass + + def test_outposts_instances_default_settings_retrieve(self) -> None: + """Test case for outposts_instances_default_settings_retrieve + + """ + pass + + def test_outposts_instances_destroy(self) -> None: + """Test case for outposts_instances_destroy + + """ + pass + + def test_outposts_instances_health_list(self) -> None: + """Test case for outposts_instances_health_list + + """ + pass + + def test_outposts_instances_list(self) -> None: + """Test case for outposts_instances_list + + """ + pass + + def test_outposts_instances_partial_update(self) -> None: + """Test case for outposts_instances_partial_update + + """ + pass + + def test_outposts_instances_retrieve(self) -> None: + """Test case for outposts_instances_retrieve + + """ + pass + + def test_outposts_instances_update(self) -> None: + """Test case for outposts_instances_update + + """ + pass + + def test_outposts_instances_used_by_list(self) -> None: + """Test case for outposts_instances_used_by_list + + """ + pass + + def test_outposts_ldap_access_check(self) -> None: + """Test case for outposts_ldap_access_check + + """ + pass + + def test_outposts_ldap_list(self) -> None: + """Test case for outposts_ldap_list + + """ + pass + + def test_outposts_proxy_list(self) -> None: + """Test case for outposts_proxy_list + + """ + pass + + def test_outposts_radius_access_check(self) -> None: + """Test case for outposts_radius_access_check + + """ + pass + + def test_outposts_radius_list(self) -> None: + """Test case for outposts_radius_list + + """ + pass + + def test_outposts_service_connections_all_destroy(self) -> None: + """Test case for outposts_service_connections_all_destroy + + """ + pass + + def test_outposts_service_connections_all_list(self) -> None: + """Test case for outposts_service_connections_all_list + + """ + pass + + def test_outposts_service_connections_all_retrieve(self) -> None: + """Test case for outposts_service_connections_all_retrieve + + """ + pass + + def test_outposts_service_connections_all_state_retrieve(self) -> None: + """Test case for outposts_service_connections_all_state_retrieve + + """ + pass + + def test_outposts_service_connections_all_types_list(self) -> None: + """Test case for outposts_service_connections_all_types_list + + """ + pass + + def test_outposts_service_connections_all_used_by_list(self) -> None: + """Test case for outposts_service_connections_all_used_by_list + + """ + pass + + def test_outposts_service_connections_docker_create(self) -> None: + """Test case for outposts_service_connections_docker_create + + """ + pass + + def test_outposts_service_connections_docker_destroy(self) -> None: + """Test case for outposts_service_connections_docker_destroy + + """ + pass + + def test_outposts_service_connections_docker_list(self) -> None: + """Test case for outposts_service_connections_docker_list + + """ + pass + + def test_outposts_service_connections_docker_partial_update(self) -> None: + """Test case for outposts_service_connections_docker_partial_update + + """ + pass + + def test_outposts_service_connections_docker_retrieve(self) -> None: + """Test case for outposts_service_connections_docker_retrieve + + """ + pass + + def test_outposts_service_connections_docker_update(self) -> None: + """Test case for outposts_service_connections_docker_update + + """ + pass + + def test_outposts_service_connections_docker_used_by_list(self) -> None: + """Test case for outposts_service_connections_docker_used_by_list + + """ + pass + + def test_outposts_service_connections_kubernetes_create(self) -> None: + """Test case for outposts_service_connections_kubernetes_create + + """ + pass + + def test_outposts_service_connections_kubernetes_destroy(self) -> None: + """Test case for outposts_service_connections_kubernetes_destroy + + """ + pass + + def test_outposts_service_connections_kubernetes_list(self) -> None: + """Test case for outposts_service_connections_kubernetes_list + + """ + pass + + def test_outposts_service_connections_kubernetes_partial_update(self) -> None: + """Test case for outposts_service_connections_kubernetes_partial_update + + """ + pass + + def test_outposts_service_connections_kubernetes_retrieve(self) -> None: + """Test case for outposts_service_connections_kubernetes_retrieve + + """ + pass + + def test_outposts_service_connections_kubernetes_update(self) -> None: + """Test case for outposts_service_connections_kubernetes_update + + """ + pass + + def test_outposts_service_connections_kubernetes_used_by_list(self) -> None: + """Test case for outposts_service_connections_kubernetes_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_account_lockdown_stage_list.py b/test/test_paginated_account_lockdown_stage_list.py new file mode 100644 index 000000000..bbf5bb889 --- /dev/null +++ b/test/test_paginated_account_lockdown_stage_list.py @@ -0,0 +1,131 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_account_lockdown_stage_list import PaginatedAccountLockdownStageList + +class TestPaginatedAccountLockdownStageList(unittest.TestCase): + """PaginatedAccountLockdownStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAccountLockdownStageList: + """Test PaginatedAccountLockdownStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAccountLockdownStageList` + """ + model = PaginatedAccountLockdownStageList() + if include_optional: + return PaginatedAccountLockdownStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.account_lockdown_stage.AccountLockdownStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + deactivate_user = True, + set_unusable_password = True, + delete_sessions = True, + revoke_tokens = True, + self_service_completion_flow = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAccountLockdownStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.account_lockdown_stage.AccountLockdownStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + deactivate_user = True, + set_unusable_password = True, + delete_sessions = True, + revoke_tokens = True, + self_service_completion_flow = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAccountLockdownStageList(self): + """Test PaginatedAccountLockdownStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_agent_connector_list.py b/test/test_paginated_agent_connector_list.py new file mode 100644 index 000000000..52e464f2d --- /dev/null +++ b/test/test_paginated_agent_connector_list.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_agent_connector_list import PaginatedAgentConnectorList + +class TestPaginatedAgentConnectorList(unittest.TestCase): + """PaginatedAgentConnectorList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAgentConnectorList: + """Test PaginatedAgentConnectorList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAgentConnectorList` + """ + model = PaginatedAgentConnectorList() + if include_optional: + return PaginatedAgentConnectorList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.agent_connector.AgentConnector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + snapshot_expiry = '', + auth_session_duration = '', + auth_terminate_session_on_expiry = True, + refresh_interval = '', + authorization_flow = '', + nss_uid_offset = 0, + nss_gid_offset = 0, + challenge_key = '', + challenge_idle_timeout = '', + challenge_trigger_check_in = True, + jwt_federation_providers = [ + 56 + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAgentConnectorList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.agent_connector.AgentConnector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + snapshot_expiry = '', + auth_session_duration = '', + auth_terminate_session_on_expiry = True, + refresh_interval = '', + authorization_flow = '', + nss_uid_offset = 0, + nss_gid_offset = 0, + challenge_key = '', + challenge_idle_timeout = '', + challenge_trigger_check_in = True, + jwt_federation_providers = [ + 56 + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAgentConnectorList(self): + """Test PaginatedAgentConnectorList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_apple_independent_secure_enclave_list.py b/test/test_paginated_apple_independent_secure_enclave_list.py new file mode 100644 index 000000000..5a6bed0f2 --- /dev/null +++ b/test/test_paginated_apple_independent_secure_enclave_list.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_apple_independent_secure_enclave_list import PaginatedAppleIndependentSecureEnclaveList + +class TestPaginatedAppleIndependentSecureEnclaveList(unittest.TestCase): + """PaginatedAppleIndependentSecureEnclaveList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAppleIndependentSecureEnclaveList: + """Test PaginatedAppleIndependentSecureEnclaveList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAppleIndependentSecureEnclaveList` + """ + model = PaginatedAppleIndependentSecureEnclaveList() + if include_optional: + return PaginatedAppleIndependentSecureEnclaveList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.apple_independent_secure_enclave.AppleIndependentSecureEnclave( + uuid = '', + user = 56, + apple_secure_enclave_key = '', + apple_enclave_key_id = '', + device_type = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAppleIndependentSecureEnclaveList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.apple_independent_secure_enclave.AppleIndependentSecureEnclave( + uuid = '', + user = 56, + apple_secure_enclave_key = '', + apple_enclave_key_id = '', + device_type = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAppleIndependentSecureEnclaveList(self): + """Test PaginatedAppleIndependentSecureEnclaveList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_application_entitlement_list.py b/test/test_paginated_application_entitlement_list.py new file mode 100644 index 000000000..7dcceceaa --- /dev/null +++ b/test/test_paginated_application_entitlement_list.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_application_entitlement_list import PaginatedApplicationEntitlementList + +class TestPaginatedApplicationEntitlementList(unittest.TestCase): + """PaginatedApplicationEntitlementList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedApplicationEntitlementList: + """Test PaginatedApplicationEntitlementList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedApplicationEntitlementList` + """ + model = PaginatedApplicationEntitlementList() + if include_optional: + return PaginatedApplicationEntitlementList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.application_entitlement.ApplicationEntitlement( + pbm_uuid = '', + name = '', + app = '', + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedApplicationEntitlementList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.application_entitlement.ApplicationEntitlement( + pbm_uuid = '', + name = '', + app = '', + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedApplicationEntitlementList(self): + """Test PaginatedApplicationEntitlementList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_application_list.py b/test/test_paginated_application_list.py new file mode 100644 index 000000000..ff456d7bf --- /dev/null +++ b/test/test_paginated_application_list.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_application_list import PaginatedApplicationList + +class TestPaginatedApplicationList(unittest.TestCase): + """PaginatedApplicationList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedApplicationList: + """Test PaginatedApplicationList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedApplicationList` + """ + model = PaginatedApplicationList() + if include_optional: + return PaginatedApplicationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.application.Application( + pk = '', + name = '', + slug = 'z', + provider = 56, + provider_obj = null, + backchannel_providers = [ + 56 + ], + backchannel_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + launch_url = '', + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_icon_url = '', + meta_icon_themed_urls = null, + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedApplicationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.application.Application( + pk = '', + name = '', + slug = 'z', + provider = 56, + provider_obj = null, + backchannel_providers = [ + 56 + ], + backchannel_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + launch_url = '', + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_icon_url = '', + meta_icon_themed_urls = null, + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedApplicationList(self): + """Test PaginatedApplicationList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_authenticated_session_list.py b/test/test_paginated_authenticated_session_list.py new file mode 100644 index 000000000..f22dc8761 --- /dev/null +++ b/test/test_paginated_authenticated_session_list.py @@ -0,0 +1,147 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_authenticated_session_list import PaginatedAuthenticatedSessionList + +class TestPaginatedAuthenticatedSessionList(unittest.TestCase): + """PaginatedAuthenticatedSessionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAuthenticatedSessionList: + """Test PaginatedAuthenticatedSessionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAuthenticatedSessionList` + """ + model = PaginatedAuthenticatedSessionList() + if include_optional: + return PaginatedAuthenticatedSessionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticated_session.AuthenticatedSession( + uuid = '', + current = True, + user_agent = authentik_client.models.authenticated_session_user_agent.AuthenticatedSession_user_agent( + device = authentik_client.models.authenticated_session_user_agent_device.AuthenticatedSession_user_agent_device( + brand = '', + family = '', + model = '', ), + os = authentik_client.models.authenticated_session_user_agent_os.AuthenticatedSession_user_agent_os( + family = '', + major = '', + minor = '', + patch = '', + patch_minor = '', ), + user_agent = authentik_client.models.authenticated_session_user_agent_user_agent.AuthenticatedSession_user_agent_user_agent( + family = '', + major = '', + minor = '', + patch = '', ), + string = '', ), + geo_ip = authentik_client.models.authenticated_session_geo_ip.AuthenticatedSession_geo_ip( + continent = '', + country = '', + lat = 1.337, + long = 1.337, + city = '', ), + asn = authentik_client.models.authenticated_session_asn.AuthenticatedSession_asn( + asn = 56, + as_org = '', + network = '', ), + user = 56, + last_ip = '', + last_user_agent = '', + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAuthenticatedSessionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticated_session.AuthenticatedSession( + uuid = '', + current = True, + user_agent = authentik_client.models.authenticated_session_user_agent.AuthenticatedSession_user_agent( + device = authentik_client.models.authenticated_session_user_agent_device.AuthenticatedSession_user_agent_device( + brand = '', + family = '', + model = '', ), + os = authentik_client.models.authenticated_session_user_agent_os.AuthenticatedSession_user_agent_os( + family = '', + major = '', + minor = '', + patch = '', + patch_minor = '', ), + user_agent = authentik_client.models.authenticated_session_user_agent_user_agent.AuthenticatedSession_user_agent_user_agent( + family = '', + major = '', + minor = '', + patch = '', ), + string = '', ), + geo_ip = authentik_client.models.authenticated_session_geo_ip.AuthenticatedSession_geo_ip( + continent = '', + country = '', + lat = 1.337, + long = 1.337, + city = '', ), + asn = authentik_client.models.authenticated_session_asn.AuthenticatedSession_asn( + asn = 56, + as_org = '', + network = '', ), + user = 56, + last_ip = '', + last_user_agent = '', + last_used = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAuthenticatedSessionList(self): + """Test PaginatedAuthenticatedSessionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_authenticator_duo_stage_list.py b/test/test_paginated_authenticator_duo_stage_list.py new file mode 100644 index 000000000..51c7c2951 --- /dev/null +++ b/test/test_paginated_authenticator_duo_stage_list.py @@ -0,0 +1,131 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_authenticator_duo_stage_list import PaginatedAuthenticatorDuoStageList + +class TestPaginatedAuthenticatorDuoStageList(unittest.TestCase): + """PaginatedAuthenticatorDuoStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAuthenticatorDuoStageList: + """Test PaginatedAuthenticatorDuoStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAuthenticatorDuoStageList` + """ + model = PaginatedAuthenticatorDuoStageList() + if include_optional: + return PaginatedAuthenticatorDuoStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_duo_stage.AuthenticatorDuoStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + client_id = '', + api_hostname = '', + admin_integration_key = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAuthenticatorDuoStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_duo_stage.AuthenticatorDuoStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + client_id = '', + api_hostname = '', + admin_integration_key = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAuthenticatorDuoStageList(self): + """Test PaginatedAuthenticatorDuoStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_authenticator_email_stage_list.py b/test/test_paginated_authenticator_email_stage_list.py new file mode 100644 index 000000000..c4603564a --- /dev/null +++ b/test/test_paginated_authenticator_email_stage_list.py @@ -0,0 +1,149 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_authenticator_email_stage_list import PaginatedAuthenticatorEmailStageList + +class TestPaginatedAuthenticatorEmailStageList(unittest.TestCase): + """PaginatedAuthenticatorEmailStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAuthenticatorEmailStageList: + """Test PaginatedAuthenticatorEmailStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAuthenticatorEmailStageList` + """ + model = PaginatedAuthenticatorEmailStageList() + if include_optional: + return PaginatedAuthenticatorEmailStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_email_stage.AuthenticatorEmailStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + use_global_settings = True, + host = '', + port = -2147483648, + username = '', + password = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '', + subject = '', + token_expiry = '', + template = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAuthenticatorEmailStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_email_stage.AuthenticatorEmailStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + use_global_settings = True, + host = '', + port = -2147483648, + username = '', + password = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '', + subject = '', + token_expiry = '', + template = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAuthenticatorEmailStageList(self): + """Test PaginatedAuthenticatorEmailStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_authenticator_endpoint_gdtc_stage_list.py b/test/test_paginated_authenticator_endpoint_gdtc_stage_list.py new file mode 100644 index 000000000..0e335d4ae --- /dev/null +++ b/test/test_paginated_authenticator_endpoint_gdtc_stage_list.py @@ -0,0 +1,131 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_authenticator_endpoint_gdtc_stage_list import PaginatedAuthenticatorEndpointGDTCStageList + +class TestPaginatedAuthenticatorEndpointGDTCStageList(unittest.TestCase): + """PaginatedAuthenticatorEndpointGDTCStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAuthenticatorEndpointGDTCStageList: + """Test PaginatedAuthenticatorEndpointGDTCStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAuthenticatorEndpointGDTCStageList` + """ + model = PaginatedAuthenticatorEndpointGDTCStageList() + if include_optional: + return PaginatedAuthenticatorEndpointGDTCStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_endpoint_gdtc_stage.AuthenticatorEndpointGDTCStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + credentials = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAuthenticatorEndpointGDTCStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_endpoint_gdtc_stage.AuthenticatorEndpointGDTCStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + credentials = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAuthenticatorEndpointGDTCStageList(self): + """Test PaginatedAuthenticatorEndpointGDTCStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_authenticator_sms_stage_list.py b/test/test_paginated_authenticator_sms_stage_list.py new file mode 100644 index 000000000..9c41c060f --- /dev/null +++ b/test/test_paginated_authenticator_sms_stage_list.py @@ -0,0 +1,141 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_authenticator_sms_stage_list import PaginatedAuthenticatorSMSStageList + +class TestPaginatedAuthenticatorSMSStageList(unittest.TestCase): + """PaginatedAuthenticatorSMSStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAuthenticatorSMSStageList: + """Test PaginatedAuthenticatorSMSStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAuthenticatorSMSStageList` + """ + model = PaginatedAuthenticatorSMSStageList() + if include_optional: + return PaginatedAuthenticatorSMSStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_sms_stage.AuthenticatorSMSStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + provider = 'twilio', + from_number = '', + account_sid = '', + auth = '', + auth_password = '', + auth_type = 'basic', + verify_only = True, + mapping = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAuthenticatorSMSStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_sms_stage.AuthenticatorSMSStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + provider = 'twilio', + from_number = '', + account_sid = '', + auth = '', + auth_password = '', + auth_type = 'basic', + verify_only = True, + mapping = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAuthenticatorSMSStageList(self): + """Test PaginatedAuthenticatorSMSStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_authenticator_static_stage_list.py b/test/test_paginated_authenticator_static_stage_list.py new file mode 100644 index 000000000..feb6f02f7 --- /dev/null +++ b/test/test_paginated_authenticator_static_stage_list.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_authenticator_static_stage_list import PaginatedAuthenticatorStaticStageList + +class TestPaginatedAuthenticatorStaticStageList(unittest.TestCase): + """PaginatedAuthenticatorStaticStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAuthenticatorStaticStageList: + """Test PaginatedAuthenticatorStaticStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAuthenticatorStaticStageList` + """ + model = PaginatedAuthenticatorStaticStageList() + if include_optional: + return PaginatedAuthenticatorStaticStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_static_stage.AuthenticatorStaticStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + token_count = 0, + token_length = 0, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAuthenticatorStaticStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_static_stage.AuthenticatorStaticStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + token_count = 0, + token_length = 0, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAuthenticatorStaticStageList(self): + """Test PaginatedAuthenticatorStaticStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_authenticator_totp_stage_list.py b/test/test_paginated_authenticator_totp_stage_list.py new file mode 100644 index 000000000..dbf431710 --- /dev/null +++ b/test/test_paginated_authenticator_totp_stage_list.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_authenticator_totp_stage_list import PaginatedAuthenticatorTOTPStageList + +class TestPaginatedAuthenticatorTOTPStageList(unittest.TestCase): + """PaginatedAuthenticatorTOTPStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAuthenticatorTOTPStageList: + """Test PaginatedAuthenticatorTOTPStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAuthenticatorTOTPStageList` + """ + model = PaginatedAuthenticatorTOTPStageList() + if include_optional: + return PaginatedAuthenticatorTOTPStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_totp_stage.AuthenticatorTOTPStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + digits = '6', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAuthenticatorTOTPStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_totp_stage.AuthenticatorTOTPStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + digits = '6', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAuthenticatorTOTPStageList(self): + """Test PaginatedAuthenticatorTOTPStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_authenticator_validate_stage_list.py b/test/test_paginated_authenticator_validate_stage_list.py new file mode 100644 index 000000000..8a6004858 --- /dev/null +++ b/test/test_paginated_authenticator_validate_stage_list.py @@ -0,0 +1,169 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_authenticator_validate_stage_list import PaginatedAuthenticatorValidateStageList + +class TestPaginatedAuthenticatorValidateStageList(unittest.TestCase): + """PaginatedAuthenticatorValidateStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAuthenticatorValidateStageList: + """Test PaginatedAuthenticatorValidateStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAuthenticatorValidateStageList` + """ + model = PaginatedAuthenticatorValidateStageList() + if include_optional: + return PaginatedAuthenticatorValidateStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_validate_stage.AuthenticatorValidateStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + not_configured_action = 'skip', + device_classes = [ + 'static' + ], + configuration_stages = [ + '' + ], + last_auth_threshold = '', + webauthn_user_verification = null, + webauthn_hints = [ + 'security-key' + ], + webauthn_allowed_device_types = [ + '' + ], + webauthn_allowed_device_types_obj = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + email_otp_throttling_factor = 1.337, + sms_otp_throttling_factor = 1.337, + totp_otp_throttling_factor = 1.337, + static_otp_throttling_factor = 1.337, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAuthenticatorValidateStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_validate_stage.AuthenticatorValidateStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + not_configured_action = 'skip', + device_classes = [ + 'static' + ], + configuration_stages = [ + '' + ], + last_auth_threshold = '', + webauthn_user_verification = null, + webauthn_hints = [ + 'security-key' + ], + webauthn_allowed_device_types = [ + '' + ], + webauthn_allowed_device_types_obj = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + email_otp_throttling_factor = 1.337, + sms_otp_throttling_factor = 1.337, + totp_otp_throttling_factor = 1.337, + static_otp_throttling_factor = 1.337, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAuthenticatorValidateStageList(self): + """Test PaginatedAuthenticatorValidateStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_authenticator_web_authn_stage_list.py b/test/test_paginated_authenticator_web_authn_stage_list.py new file mode 100644 index 000000000..7bde2784c --- /dev/null +++ b/test/test_paginated_authenticator_web_authn_stage_list.py @@ -0,0 +1,157 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_authenticator_web_authn_stage_list import PaginatedAuthenticatorWebAuthnStageList + +class TestPaginatedAuthenticatorWebAuthnStageList(unittest.TestCase): + """PaginatedAuthenticatorWebAuthnStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedAuthenticatorWebAuthnStageList: + """Test PaginatedAuthenticatorWebAuthnStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedAuthenticatorWebAuthnStageList` + """ + model = PaginatedAuthenticatorWebAuthnStageList() + if include_optional: + return PaginatedAuthenticatorWebAuthnStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_web_authn_stage.AuthenticatorWebAuthnStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + user_verification = 'required', + authenticator_attachment = null, + resident_key_requirement = 'required', + hints = [ + 'security-key' + ], + device_type_restrictions = [ + '' + ], + device_type_restrictions_obj = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + prevent_duplicate_devices = True, + max_attempts = 0, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedAuthenticatorWebAuthnStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.authenticator_web_authn_stage.AuthenticatorWebAuthnStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + configure_flow = '', + friendly_name = '', + user_verification = 'required', + authenticator_attachment = null, + resident_key_requirement = 'required', + hints = [ + 'security-key' + ], + device_type_restrictions = [ + '' + ], + device_type_restrictions_obj = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + prevent_duplicate_devices = True, + max_attempts = 0, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedAuthenticatorWebAuthnStageList(self): + """Test PaginatedAuthenticatorWebAuthnStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_blueprint_instance_list.py b/test/test_paginated_blueprint_instance_list.py new file mode 100644 index 000000000..a965da6a1 --- /dev/null +++ b/test/test_paginated_blueprint_instance_list.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_blueprint_instance_list import PaginatedBlueprintInstanceList + +class TestPaginatedBlueprintInstanceList(unittest.TestCase): + """PaginatedBlueprintInstanceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedBlueprintInstanceList: + """Test PaginatedBlueprintInstanceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedBlueprintInstanceList` + """ + model = PaginatedBlueprintInstanceList() + if include_optional: + return PaginatedBlueprintInstanceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.blueprint_instance.BlueprintInstance( + pk = '', + name = '', + path = '', + context = { + 'key' : null + }, + last_applied = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_applied_hash = '', + status = null, + enabled = True, + managed_models = [ + '' + ], + metadata = { + 'key' : null + }, + content = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedBlueprintInstanceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.blueprint_instance.BlueprintInstance( + pk = '', + name = '', + path = '', + context = { + 'key' : null + }, + last_applied = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_applied_hash = '', + status = null, + enabled = True, + managed_models = [ + '' + ], + metadata = { + 'key' : null + }, + content = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedBlueprintInstanceList(self): + """Test PaginatedBlueprintInstanceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_brand_list.py b/test/test_paginated_brand_list.py new file mode 100644 index 000000000..d671e32c6 --- /dev/null +++ b/test/test_paginated_brand_list.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_brand_list import PaginatedBrandList + +class TestPaginatedBrandList(unittest.TestCase): + """PaginatedBrandList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedBrandList: + """Test PaginatedBrandList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedBrandList` + """ + model = PaginatedBrandList() + if include_optional: + return PaginatedBrandList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.brand.Brand( + brand_uuid = '', + domain = '', + default = True, + branding_title = '', + branding_logo = '', + branding_favicon = '', + branding_custom_css = '', + branding_default_flow_background = '', + flow_authentication = '', + flow_invalidation = '', + flow_recovery = '', + flow_unenrollment = '', + flow_user_settings = '', + flow_device_code = '', + flow_lockdown = '', + default_application = '', + web_certificate = '', + client_certificates = [ + '' + ], + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedBrandList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.brand.Brand( + brand_uuid = '', + domain = '', + default = True, + branding_title = '', + branding_logo = '', + branding_favicon = '', + branding_custom_css = '', + branding_default_flow_background = '', + flow_authentication = '', + flow_invalidation = '', + flow_recovery = '', + flow_unenrollment = '', + flow_user_settings = '', + flow_device_code = '', + flow_lockdown = '', + default_application = '', + web_certificate = '', + client_certificates = [ + '' + ], + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedBrandList(self): + """Test PaginatedBrandList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_captcha_stage_list.py b/test/test_paginated_captcha_stage_list.py new file mode 100644 index 000000000..36e268644 --- /dev/null +++ b/test/test_paginated_captcha_stage_list.py @@ -0,0 +1,135 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_captcha_stage_list import PaginatedCaptchaStageList + +class TestPaginatedCaptchaStageList(unittest.TestCase): + """PaginatedCaptchaStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedCaptchaStageList: + """Test PaginatedCaptchaStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedCaptchaStageList` + """ + model = PaginatedCaptchaStageList() + if include_optional: + return PaginatedCaptchaStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.captcha_stage.CaptchaStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + public_key = '', + js_url = '', + api_url = '', + interactive = True, + score_min_threshold = 1.337, + score_max_threshold = 1.337, + error_on_invalid_score = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedCaptchaStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.captcha_stage.CaptchaStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + public_key = '', + js_url = '', + api_url = '', + interactive = True, + score_min_threshold = 1.337, + score_max_threshold = 1.337, + error_on_invalid_score = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedCaptchaStageList(self): + """Test PaginatedCaptchaStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_certificate_key_pair_list.py b/test/test_paginated_certificate_key_pair_list.py new file mode 100644 index 000000000..0d1b61e59 --- /dev/null +++ b/test/test_paginated_certificate_key_pair_list.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_certificate_key_pair_list import PaginatedCertificateKeyPairList + +class TestPaginatedCertificateKeyPairList(unittest.TestCase): + """PaginatedCertificateKeyPairList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedCertificateKeyPairList: + """Test PaginatedCertificateKeyPairList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedCertificateKeyPairList` + """ + model = PaginatedCertificateKeyPairList() + if include_optional: + return PaginatedCertificateKeyPairList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.certificate_key_pair.CertificateKeyPair( + pk = '', + name = '', + fingerprint_sha256 = '', + fingerprint_sha1 = '', + cert_expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + cert_subject = '', + private_key_available = True, + key_type = null, + certificate_download_url = '', + private_key_download_url = '', + managed = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedCertificateKeyPairList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.certificate_key_pair.CertificateKeyPair( + pk = '', + name = '', + fingerprint_sha256 = '', + fingerprint_sha1 = '', + cert_expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + cert_subject = '', + private_key_available = True, + key_type = null, + certificate_download_url = '', + private_key_download_url = '', + managed = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedCertificateKeyPairList(self): + """Test PaginatedCertificateKeyPairList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_connection_token_list.py b/test/test_paginated_connection_token_list.py new file mode 100644 index 000000000..fa6d12841 --- /dev/null +++ b/test/test_paginated_connection_token_list.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_connection_token_list import PaginatedConnectionTokenList + +class TestPaginatedConnectionTokenList(unittest.TestCase): + """PaginatedConnectionTokenList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedConnectionTokenList: + """Test PaginatedConnectionTokenList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedConnectionTokenList` + """ + model = PaginatedConnectionTokenList() + if include_optional: + return PaginatedConnectionTokenList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.connection_token.ConnectionToken( + pk = '', + provider = 56, + provider_obj = null, + endpoint = '', + endpoint_obj = null, + user = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedConnectionTokenList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.connection_token.ConnectionToken( + pk = '', + provider = 56, + provider_obj = null, + endpoint = '', + endpoint_obj = null, + user = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedConnectionTokenList(self): + """Test PaginatedConnectionTokenList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_connector_list.py b/test/test_paginated_connector_list.py new file mode 100644 index 000000000..d65b92e94 --- /dev/null +++ b/test/test_paginated_connector_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_connector_list import PaginatedConnectorList + +class TestPaginatedConnectorList(unittest.TestCase): + """PaginatedConnectorList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedConnectorList: + """Test PaginatedConnectorList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedConnectorList` + """ + model = PaginatedConnectorList() + if include_optional: + return PaginatedConnectorList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.connector.Connector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedConnectorList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.connector.Connector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedConnectorList(self): + """Test PaginatedConnectorList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_consent_stage_list.py b/test/test_paginated_consent_stage_list.py new file mode 100644 index 000000000..7abf27663 --- /dev/null +++ b/test/test_paginated_consent_stage_list.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_consent_stage_list import PaginatedConsentStageList + +class TestPaginatedConsentStageList(unittest.TestCase): + """PaginatedConsentStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedConsentStageList: + """Test PaginatedConsentStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedConsentStageList` + """ + model = PaginatedConsentStageList() + if include_optional: + return PaginatedConsentStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.consent_stage.ConsentStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + mode = 'always_require', + consent_expire_in = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedConsentStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.consent_stage.ConsentStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + mode = 'always_require', + consent_expire_in = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedConsentStageList(self): + """Test PaginatedConsentStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_data_export_list.py b/test/test_paginated_data_export_list.py new file mode 100644 index 000000000..3d7c80937 --- /dev/null +++ b/test/test_paginated_data_export_list.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_data_export_list import PaginatedDataExportList + +class TestPaginatedDataExportList(unittest.TestCase): + """PaginatedDataExportList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedDataExportList: + """Test PaginatedDataExportList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedDataExportList` + """ + model = PaginatedDataExportList() + if include_optional: + return PaginatedDataExportList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.data_export.DataExport( + id = '', + requested_by = null, + requested_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + content_type = null, + query_params = { + 'key' : null + }, + file_url = '', + completed = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedDataExportList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.data_export.DataExport( + id = '', + requested_by = null, + requested_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + content_type = null, + query_params = { + 'key' : null + }, + file_url = '', + completed = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedDataExportList(self): + """Test PaginatedDataExportList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_deny_stage_list.py b/test/test_paginated_deny_stage_list.py new file mode 100644 index 000000000..b398773bf --- /dev/null +++ b/test/test_paginated_deny_stage_list.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_deny_stage_list import PaginatedDenyStageList + +class TestPaginatedDenyStageList(unittest.TestCase): + """PaginatedDenyStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedDenyStageList: + """Test PaginatedDenyStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedDenyStageList` + """ + model = PaginatedDenyStageList() + if include_optional: + return PaginatedDenyStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.deny_stage.DenyStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + deny_message = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedDenyStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.deny_stage.DenyStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + deny_message = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedDenyStageList(self): + """Test PaginatedDenyStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_device_access_group_list.py b/test/test_paginated_device_access_group_list.py new file mode 100644 index 000000000..4c729ad2d --- /dev/null +++ b/test/test_paginated_device_access_group_list.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_device_access_group_list import PaginatedDeviceAccessGroupList + +class TestPaginatedDeviceAccessGroupList(unittest.TestCase): + """PaginatedDeviceAccessGroupList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedDeviceAccessGroupList: + """Test PaginatedDeviceAccessGroupList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedDeviceAccessGroupList` + """ + model = PaginatedDeviceAccessGroupList() + if include_optional: + return PaginatedDeviceAccessGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.device_access_group.DeviceAccessGroup( + pbm_uuid = '', + name = '', + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedDeviceAccessGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.device_access_group.DeviceAccessGroup( + pbm_uuid = '', + name = '', + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedDeviceAccessGroupList(self): + """Test PaginatedDeviceAccessGroupList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_device_user_binding_list.py b/test/test_paginated_device_user_binding_list.py new file mode 100644 index 000000000..a7e912e8b --- /dev/null +++ b/test/test_paginated_device_user_binding_list.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_device_user_binding_list import PaginatedDeviceUserBindingList + +class TestPaginatedDeviceUserBindingList(unittest.TestCase): + """PaginatedDeviceUserBindingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedDeviceUserBindingList: + """Test PaginatedDeviceUserBindingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedDeviceUserBindingList` + """ + model = PaginatedDeviceUserBindingList() + if include_optional: + return PaginatedDeviceUserBindingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.device_user_binding.DeviceUserBinding( + pk = '', + policy = '', + group = '', + user = 56, + policy_obj = null, + group_obj = null, + user_obj = null, + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True, + is_primary = True, + connector = '', + connector_obj = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedDeviceUserBindingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.device_user_binding.DeviceUserBinding( + pk = '', + policy = '', + group = '', + user = 56, + policy_obj = null, + group_obj = null, + user_obj = null, + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True, + is_primary = True, + connector = '', + connector_obj = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedDeviceUserBindingList(self): + """Test PaginatedDeviceUserBindingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_docker_service_connection_list.py b/test/test_paginated_docker_service_connection_list.py new file mode 100644 index 000000000..f8b984c66 --- /dev/null +++ b/test/test_paginated_docker_service_connection_list.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_docker_service_connection_list import PaginatedDockerServiceConnectionList + +class TestPaginatedDockerServiceConnectionList(unittest.TestCase): + """PaginatedDockerServiceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedDockerServiceConnectionList: + """Test PaginatedDockerServiceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedDockerServiceConnectionList` + """ + model = PaginatedDockerServiceConnectionList() + if include_optional: + return PaginatedDockerServiceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.docker_service_connection.DockerServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + tls_verification = '', + tls_authentication = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedDockerServiceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.docker_service_connection.DockerServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + tls_verification = '', + tls_authentication = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedDockerServiceConnectionList(self): + """Test PaginatedDockerServiceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_domain_list.py b/test/test_paginated_domain_list.py new file mode 100644 index 000000000..054a2d45c --- /dev/null +++ b/test/test_paginated_domain_list.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_domain_list import PaginatedDomainList + +class TestPaginatedDomainList(unittest.TestCase): + """PaginatedDomainList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedDomainList: + """Test PaginatedDomainList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedDomainList` + """ + model = PaginatedDomainList() + if include_optional: + return PaginatedDomainList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.domain.Domain( + id = 56, + domain = '', + is_primary = True, + tenant = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedDomainList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.domain.Domain( + id = 56, + domain = '', + is_primary = True, + tenant = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedDomainList(self): + """Test PaginatedDomainList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_dummy_policy_list.py b/test/test_paginated_dummy_policy_list.py new file mode 100644 index 000000000..5270e1fe5 --- /dev/null +++ b/test/test_paginated_dummy_policy_list.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_dummy_policy_list import PaginatedDummyPolicyList + +class TestPaginatedDummyPolicyList(unittest.TestCase): + """PaginatedDummyPolicyList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedDummyPolicyList: + """Test PaginatedDummyPolicyList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedDummyPolicyList` + """ + model = PaginatedDummyPolicyList() + if include_optional: + return PaginatedDummyPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.dummy_policy.DummyPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + result = True, + wait_min = -2147483648, + wait_max = -2147483648, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedDummyPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.dummy_policy.DummyPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + result = True, + wait_min = -2147483648, + wait_max = -2147483648, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedDummyPolicyList(self): + """Test PaginatedDummyPolicyList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_dummy_stage_list.py b/test/test_paginated_dummy_stage_list.py new file mode 100644 index 000000000..7ba265218 --- /dev/null +++ b/test/test_paginated_dummy_stage_list.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_dummy_stage_list import PaginatedDummyStageList + +class TestPaginatedDummyStageList(unittest.TestCase): + """PaginatedDummyStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedDummyStageList: + """Test PaginatedDummyStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedDummyStageList` + """ + model = PaginatedDummyStageList() + if include_optional: + return PaginatedDummyStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.dummy_stage.DummyStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + throw_error = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedDummyStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.dummy_stage.DummyStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + throw_error = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedDummyStageList(self): + """Test PaginatedDummyStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_duo_device_list.py b/test/test_paginated_duo_device_list.py new file mode 100644 index 000000000..42c3c7850 --- /dev/null +++ b/test/test_paginated_duo_device_list.py @@ -0,0 +1,85 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_duo_device_list import PaginatedDuoDeviceList + +class TestPaginatedDuoDeviceList(unittest.TestCase): + """PaginatedDuoDeviceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedDuoDeviceList: + """Test PaginatedDuoDeviceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedDuoDeviceList` + """ + model = PaginatedDuoDeviceList() + if include_optional: + return PaginatedDuoDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.duo_device.DuoDevice( + pk = 56, + name = '', + user = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedDuoDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.duo_device.DuoDevice( + pk = 56, + name = '', + user = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedDuoDeviceList(self): + """Test PaginatedDuoDeviceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_email_device_list.py b/test/test_paginated_email_device_list.py new file mode 100644 index 000000000..c16e0a1d5 --- /dev/null +++ b/test/test_paginated_email_device_list.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_email_device_list import PaginatedEmailDeviceList + +class TestPaginatedEmailDeviceList(unittest.TestCase): + """PaginatedEmailDeviceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedEmailDeviceList: + """Test PaginatedEmailDeviceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedEmailDeviceList` + """ + model = PaginatedEmailDeviceList() + if include_optional: + return PaginatedEmailDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.email_device.EmailDevice( + name = '', + pk = 56, + email = '', + user = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedEmailDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.email_device.EmailDevice( + name = '', + pk = 56, + email = '', + user = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedEmailDeviceList(self): + """Test PaginatedEmailDeviceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_email_stage_list.py b/test/test_paginated_email_stage_list.py new file mode 100644 index 000000000..dd4e3c686 --- /dev/null +++ b/test/test_paginated_email_stage_list.py @@ -0,0 +1,149 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_email_stage_list import PaginatedEmailStageList + +class TestPaginatedEmailStageList(unittest.TestCase): + """PaginatedEmailStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedEmailStageList: + """Test PaginatedEmailStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedEmailStageList` + """ + model = PaginatedEmailStageList() + if include_optional: + return PaginatedEmailStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.email_stage.EmailStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + use_global_settings = True, + host = '', + port = -2147483648, + username = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '', + token_expiry = '', + subject = '', + template = '', + activate_user_on_success = True, + recovery_max_attempts = 0, + recovery_cache_timeout = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedEmailStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.email_stage.EmailStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + use_global_settings = True, + host = '', + port = -2147483648, + username = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '', + token_expiry = '', + subject = '', + template = '', + activate_user_on_success = True, + recovery_max_attempts = 0, + recovery_cache_timeout = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedEmailStageList(self): + """Test PaginatedEmailStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_endpoint_device_list.py b/test/test_paginated_endpoint_device_list.py new file mode 100644 index 000000000..63d701c0e --- /dev/null +++ b/test/test_paginated_endpoint_device_list.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_endpoint_device_list import PaginatedEndpointDeviceList + +class TestPaginatedEndpointDeviceList(unittest.TestCase): + """PaginatedEndpointDeviceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedEndpointDeviceList: + """Test PaginatedEndpointDeviceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedEndpointDeviceList` + """ + model = PaginatedEndpointDeviceList() + if include_optional: + return PaginatedEndpointDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.endpoint_device.EndpointDevice( + device_uuid = '', + pbm_uuid = '', + name = '', + access_group = '', + access_group_obj = authentik_client.models.device_access_group.DeviceAccessGroup( + pbm_uuid = '', + name = '', + attributes = { + 'key' : null + }, ), + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + facts = null, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedEndpointDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.endpoint_device.EndpointDevice( + device_uuid = '', + pbm_uuid = '', + name = '', + access_group = '', + access_group_obj = authentik_client.models.device_access_group.DeviceAccessGroup( + pbm_uuid = '', + name = '', + attributes = { + 'key' : null + }, ), + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + facts = null, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedEndpointDeviceList(self): + """Test PaginatedEndpointDeviceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_endpoint_list.py b/test/test_paginated_endpoint_list.py new file mode 100644 index 000000000..f30357c93 --- /dev/null +++ b/test/test_paginated_endpoint_list.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_endpoint_list import PaginatedEndpointList + +class TestPaginatedEndpointList(unittest.TestCase): + """PaginatedEndpointList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedEndpointList: + """Test PaginatedEndpointList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedEndpointList` + """ + model = PaginatedEndpointList() + if include_optional: + return PaginatedEndpointList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.endpoint.Endpoint( + pk = '', + name = '', + provider = 56, + provider_obj = null, + protocol = 'rdp', + host = '', + settings = { + 'key' : null + }, + property_mappings = [ + '' + ], + auth_mode = 'static', + launch_url = '', + maximum_connections = -2147483648, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedEndpointList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.endpoint.Endpoint( + pk = '', + name = '', + provider = 56, + provider_obj = null, + protocol = 'rdp', + host = '', + settings = { + 'key' : null + }, + property_mappings = [ + '' + ], + auth_mode = 'static', + launch_url = '', + maximum_connections = -2147483648, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedEndpointList(self): + """Test PaginatedEndpointList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_endpoint_stage_list.py b/test/test_paginated_endpoint_stage_list.py new file mode 100644 index 000000000..8ac8582b8 --- /dev/null +++ b/test/test_paginated_endpoint_stage_list.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_endpoint_stage_list import PaginatedEndpointStageList + +class TestPaginatedEndpointStageList(unittest.TestCase): + """PaginatedEndpointStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedEndpointStageList: + """Test PaginatedEndpointStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedEndpointStageList` + """ + model = PaginatedEndpointStageList() + if include_optional: + return PaginatedEndpointStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.endpoint_stage.EndpointStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + connector = '', + connector_obj = null, + mode = 'optional', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedEndpointStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.endpoint_stage.EndpointStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + connector = '', + connector_obj = null, + mode = 'optional', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedEndpointStageList(self): + """Test PaginatedEndpointStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_enrollment_token_list.py b/test/test_paginated_enrollment_token_list.py new file mode 100644 index 000000000..14f5770a9 --- /dev/null +++ b/test/test_paginated_enrollment_token_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_enrollment_token_list import PaginatedEnrollmentTokenList + +class TestPaginatedEnrollmentTokenList(unittest.TestCase): + """PaginatedEnrollmentTokenList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedEnrollmentTokenList: + """Test PaginatedEnrollmentTokenList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedEnrollmentTokenList` + """ + model = PaginatedEnrollmentTokenList() + if include_optional: + return PaginatedEnrollmentTokenList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.enrollment_token.EnrollmentToken( + token_uuid = '', + device_group = '', + device_group_obj = null, + connector = '', + name = '', + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedEnrollmentTokenList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.enrollment_token.EnrollmentToken( + token_uuid = '', + device_group = '', + device_group_obj = null, + connector = '', + name = '', + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedEnrollmentTokenList(self): + """Test PaginatedEnrollmentTokenList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_event_list.py b/test/test_paginated_event_list.py new file mode 100644 index 000000000..0a019aafb --- /dev/null +++ b/test/test_paginated_event_list.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_event_list import PaginatedEventList + +class TestPaginatedEventList(unittest.TestCase): + """PaginatedEventList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedEventList: + """Test PaginatedEventList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedEventList` + """ + model = PaginatedEventList() + if include_optional: + return PaginatedEventList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.event.Event( + pk = '', + user = { + 'key' : null + }, + action = 'login', + app = '', + context = { + 'key' : null + }, + client_ip = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedEventList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.event.Event( + pk = '', + user = { + 'key' : null + }, + action = 'login', + app = '', + context = { + 'key' : null + }, + client_ip = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedEventList(self): + """Test PaginatedEventList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_event_matcher_policy_list.py b/test/test_paginated_event_matcher_policy_list.py new file mode 100644 index 000000000..e17ef43de --- /dev/null +++ b/test/test_paginated_event_matcher_policy_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_event_matcher_policy_list import PaginatedEventMatcherPolicyList + +class TestPaginatedEventMatcherPolicyList(unittest.TestCase): + """PaginatedEventMatcherPolicyList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedEventMatcherPolicyList: + """Test PaginatedEventMatcherPolicyList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedEventMatcherPolicyList` + """ + model = PaginatedEventMatcherPolicyList() + if include_optional: + return PaginatedEventMatcherPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.event_matcher_policy.EventMatcherPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + action = null, + client_ip = '', + app = null, + model = null, + query = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedEventMatcherPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.event_matcher_policy.EventMatcherPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + action = null, + client_ip = '', + app = null, + model = null, + query = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedEventMatcherPolicyList(self): + """Test PaginatedEventMatcherPolicyList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_expiring_base_grant_model_list.py b/test/test_paginated_expiring_base_grant_model_list.py new file mode 100644 index 000000000..b82305a58 --- /dev/null +++ b/test/test_paginated_expiring_base_grant_model_list.py @@ -0,0 +1,263 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_expiring_base_grant_model_list import PaginatedExpiringBaseGrantModelList + +class TestPaginatedExpiringBaseGrantModelList(unittest.TestCase): + """PaginatedExpiringBaseGrantModelList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedExpiringBaseGrantModelList: + """Test PaginatedExpiringBaseGrantModelList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedExpiringBaseGrantModelList` + """ + model = PaginatedExpiringBaseGrantModelList() + if include_optional: + return PaginatedExpiringBaseGrantModelList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.expiring_base_grant_model.ExpiringBaseGrantModel( + pk = 56, + provider = authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ), + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + is_expired = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + scope = [ + '' + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedExpiringBaseGrantModelList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.expiring_base_grant_model.ExpiringBaseGrantModel( + pk = 56, + provider = authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ), + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + is_expired = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + scope = [ + '' + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedExpiringBaseGrantModelList(self): + """Test PaginatedExpiringBaseGrantModelList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_expression_policy_list.py b/test/test_paginated_expression_policy_list.py new file mode 100644 index 000000000..c1d476013 --- /dev/null +++ b/test/test_paginated_expression_policy_list.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_expression_policy_list import PaginatedExpressionPolicyList + +class TestPaginatedExpressionPolicyList(unittest.TestCase): + """PaginatedExpressionPolicyList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedExpressionPolicyList: + """Test PaginatedExpressionPolicyList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedExpressionPolicyList` + """ + model = PaginatedExpressionPolicyList() + if include_optional: + return PaginatedExpressionPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.expression_policy.ExpressionPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + expression = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedExpressionPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.expression_policy.ExpressionPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + expression = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedExpressionPolicyList(self): + """Test PaginatedExpressionPolicyList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_extra_role_object_permission_list.py b/test/test_paginated_extra_role_object_permission_list.py new file mode 100644 index 000000000..6b3efdc41 --- /dev/null +++ b/test/test_paginated_extra_role_object_permission_list.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_extra_role_object_permission_list import PaginatedExtraRoleObjectPermissionList + +class TestPaginatedExtraRoleObjectPermissionList(unittest.TestCase): + """PaginatedExtraRoleObjectPermissionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedExtraRoleObjectPermissionList: + """Test PaginatedExtraRoleObjectPermissionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedExtraRoleObjectPermissionList` + """ + model = PaginatedExtraRoleObjectPermissionList() + if include_optional: + return PaginatedExtraRoleObjectPermissionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.extra_role_object_permission.ExtraRoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '', + app_label_verbose = '', + model_verbose = '', + object_description = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedExtraRoleObjectPermissionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.extra_role_object_permission.ExtraRoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '', + app_label_verbose = '', + model_verbose = '', + object_description = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedExtraRoleObjectPermissionList(self): + """Test PaginatedExtraRoleObjectPermissionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_fleet_connector_list.py b/test/test_paginated_fleet_connector_list.py new file mode 100644 index 000000000..a2933c448 --- /dev/null +++ b/test/test_paginated_fleet_connector_list.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_fleet_connector_list import PaginatedFleetConnectorList + +class TestPaginatedFleetConnectorList(unittest.TestCase): + """PaginatedFleetConnectorList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedFleetConnectorList: + """Test PaginatedFleetConnectorList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedFleetConnectorList` + """ + model = PaginatedFleetConnectorList() + if include_optional: + return PaginatedFleetConnectorList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.fleet_connector.FleetConnector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + headers_mapping = '', + map_users = True, + map_teams_access_group = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedFleetConnectorList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.fleet_connector.FleetConnector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + headers_mapping = '', + map_users = True, + map_teams_access_group = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedFleetConnectorList(self): + """Test PaginatedFleetConnectorList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_flow_list.py b/test/test_paginated_flow_list.py new file mode 100644 index 000000000..6f3645c46 --- /dev/null +++ b/test/test_paginated_flow_list.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_flow_list import PaginatedFlowList + +class TestPaginatedFlowList(unittest.TestCase): + """PaginatedFlowList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedFlowList: + """Test PaginatedFlowList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedFlowList` + """ + model = PaginatedFlowList() + if include_optional: + return PaginatedFlowList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.flow.Flow( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background = '', + background_url = '', + background_themed_urls = null, + stages = [ + '' + ], + policies = [ + '' + ], + cache_count = 56, + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, + authentication = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedFlowList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.flow.Flow( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background = '', + background_url = '', + background_themed_urls = null, + stages = [ + '' + ], + policies = [ + '' + ], + cache_count = 56, + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, + authentication = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedFlowList(self): + """Test PaginatedFlowList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_flow_stage_binding_list.py b/test/test_paginated_flow_stage_binding_list.py new file mode 100644 index 000000000..17efe7eea --- /dev/null +++ b/test/test_paginated_flow_stage_binding_list.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_flow_stage_binding_list import PaginatedFlowStageBindingList + +class TestPaginatedFlowStageBindingList(unittest.TestCase): + """PaginatedFlowStageBindingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedFlowStageBindingList: + """Test PaginatedFlowStageBindingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedFlowStageBindingList` + """ + model = PaginatedFlowStageBindingList() + if include_optional: + return PaginatedFlowStageBindingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.flow_stage_binding.FlowStageBinding( + pk = '', + policybindingmodel_ptr_id = '', + target = '', + stage = '', + stage_obj = null, + evaluate_on_plan = True, + re_evaluate_policies = True, + order = -2147483648, + policy_engine_mode = 'all', + invalid_response_action = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedFlowStageBindingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.flow_stage_binding.FlowStageBinding( + pk = '', + policybindingmodel_ptr_id = '', + target = '', + stage = '', + stage_obj = null, + evaluate_on_plan = True, + re_evaluate_policies = True, + order = -2147483648, + policy_engine_mode = 'all', + invalid_response_action = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedFlowStageBindingList(self): + """Test PaginatedFlowStageBindingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_geo_ip_policy_list.py b/test/test_paginated_geo_ip_policy_list.py new file mode 100644 index 000000000..86fe23762 --- /dev/null +++ b/test/test_paginated_geo_ip_policy_list.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_geo_ip_policy_list import PaginatedGeoIPPolicyList + +class TestPaginatedGeoIPPolicyList(unittest.TestCase): + """PaginatedGeoIPPolicyList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGeoIPPolicyList: + """Test PaginatedGeoIPPolicyList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGeoIPPolicyList` + """ + model = PaginatedGeoIPPolicyList() + if include_optional: + return PaginatedGeoIPPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.geo_ip_policy.GeoIPPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + asns = [ + -2147483648 + ], + countries = [ + 'AF' + ], + countries_obj = [ + authentik_client.models.geo_ip_policy_countries_obj_inner.GeoIPPolicy_countries_obj_inner( + code = '01', + name = '', ) + ], + check_history_distance = True, + history_max_distance_km = 0, + distance_tolerance_km = 0, + history_login_count = 0, + check_impossible_travel = True, + impossible_tolerance_km = 0, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGeoIPPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.geo_ip_policy.GeoIPPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + asns = [ + -2147483648 + ], + countries = [ + 'AF' + ], + countries_obj = [ + authentik_client.models.geo_ip_policy_countries_obj_inner.GeoIPPolicy_countries_obj_inner( + code = '01', + name = '', ) + ], + check_history_distance = True, + history_max_distance_km = 0, + distance_tolerance_km = 0, + history_login_count = 0, + check_impossible_travel = True, + impossible_tolerance_km = 0, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGeoIPPolicyList(self): + """Test PaginatedGeoIPPolicyList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_google_chrome_connector_list.py b/test/test_paginated_google_chrome_connector_list.py new file mode 100644 index 000000000..513aa9c11 --- /dev/null +++ b/test/test_paginated_google_chrome_connector_list.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_google_chrome_connector_list import PaginatedGoogleChromeConnectorList + +class TestPaginatedGoogleChromeConnectorList(unittest.TestCase): + """PaginatedGoogleChromeConnectorList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGoogleChromeConnectorList: + """Test PaginatedGoogleChromeConnectorList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGoogleChromeConnectorList` + """ + model = PaginatedGoogleChromeConnectorList() + if include_optional: + return PaginatedGoogleChromeConnectorList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_chrome_connector.GoogleChromeConnector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + credentials = { + 'key' : null + }, + chrome_url = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGoogleChromeConnectorList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_chrome_connector.GoogleChromeConnector( + connector_uuid = '', + name = '', + enabled = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + credentials = { + 'key' : null + }, + chrome_url = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGoogleChromeConnectorList(self): + """Test PaginatedGoogleChromeConnectorList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_google_endpoint_device_list.py b/test/test_paginated_google_endpoint_device_list.py new file mode 100644 index 000000000..984aaff35 --- /dev/null +++ b/test/test_paginated_google_endpoint_device_list.py @@ -0,0 +1,83 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_google_endpoint_device_list import PaginatedGoogleEndpointDeviceList + +class TestPaginatedGoogleEndpointDeviceList(unittest.TestCase): + """PaginatedGoogleEndpointDeviceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGoogleEndpointDeviceList: + """Test PaginatedGoogleEndpointDeviceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGoogleEndpointDeviceList` + """ + model = PaginatedGoogleEndpointDeviceList() + if include_optional: + return PaginatedGoogleEndpointDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_endpoint_device.GoogleEndpointDevice( + pk = '', + name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGoogleEndpointDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_endpoint_device.GoogleEndpointDevice( + pk = '', + name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGoogleEndpointDeviceList(self): + """Test PaginatedGoogleEndpointDeviceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_google_workspace_provider_group_list.py b/test/test_paginated_google_workspace_provider_group_list.py new file mode 100644 index 000000000..f8fe280cd --- /dev/null +++ b/test/test_paginated_google_workspace_provider_group_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_google_workspace_provider_group_list import PaginatedGoogleWorkspaceProviderGroupList + +class TestPaginatedGoogleWorkspaceProviderGroupList(unittest.TestCase): + """PaginatedGoogleWorkspaceProviderGroupList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGoogleWorkspaceProviderGroupList: + """Test PaginatedGoogleWorkspaceProviderGroupList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGoogleWorkspaceProviderGroupList` + """ + model = PaginatedGoogleWorkspaceProviderGroupList() + if include_optional: + return PaginatedGoogleWorkspaceProviderGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_workspace_provider_group.GoogleWorkspaceProviderGroup( + id = '', + google_id = '', + group = '', + group_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGoogleWorkspaceProviderGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_workspace_provider_group.GoogleWorkspaceProviderGroup( + id = '', + google_id = '', + group = '', + group_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGoogleWorkspaceProviderGroupList(self): + """Test PaginatedGoogleWorkspaceProviderGroupList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_google_workspace_provider_list.py b/test/test_paginated_google_workspace_provider_list.py new file mode 100644 index 000000000..5abce6b34 --- /dev/null +++ b/test/test_paginated_google_workspace_provider_list.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_google_workspace_provider_list import PaginatedGoogleWorkspaceProviderList + +class TestPaginatedGoogleWorkspaceProviderList(unittest.TestCase): + """PaginatedGoogleWorkspaceProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGoogleWorkspaceProviderList: + """Test PaginatedGoogleWorkspaceProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGoogleWorkspaceProviderList` + """ + model = PaginatedGoogleWorkspaceProviderList() + if include_optional: + return PaginatedGoogleWorkspaceProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_workspace_provider.GoogleWorkspaceProvider( + pk = 56, + name = '', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + delegated_subject = '', + credentials = { + 'key' : null + }, + scopes = '', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + default_group_email_domain = '', + sync_page_size = 1, + sync_page_timeout = '', + dry_run = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGoogleWorkspaceProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_workspace_provider.GoogleWorkspaceProvider( + pk = 56, + name = '', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + delegated_subject = '', + credentials = { + 'key' : null + }, + scopes = '', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + default_group_email_domain = '', + sync_page_size = 1, + sync_page_timeout = '', + dry_run = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGoogleWorkspaceProviderList(self): + """Test PaginatedGoogleWorkspaceProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_google_workspace_provider_mapping_list.py b/test/test_paginated_google_workspace_provider_mapping_list.py new file mode 100644 index 000000000..f781ca72a --- /dev/null +++ b/test/test_paginated_google_workspace_provider_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_google_workspace_provider_mapping_list import PaginatedGoogleWorkspaceProviderMappingList + +class TestPaginatedGoogleWorkspaceProviderMappingList(unittest.TestCase): + """PaginatedGoogleWorkspaceProviderMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGoogleWorkspaceProviderMappingList: + """Test PaginatedGoogleWorkspaceProviderMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGoogleWorkspaceProviderMappingList` + """ + model = PaginatedGoogleWorkspaceProviderMappingList() + if include_optional: + return PaginatedGoogleWorkspaceProviderMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_workspace_provider_mapping.GoogleWorkspaceProviderMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGoogleWorkspaceProviderMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_workspace_provider_mapping.GoogleWorkspaceProviderMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGoogleWorkspaceProviderMappingList(self): + """Test PaginatedGoogleWorkspaceProviderMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_google_workspace_provider_user_list.py b/test/test_paginated_google_workspace_provider_user_list.py new file mode 100644 index 000000000..d7a79ea0e --- /dev/null +++ b/test/test_paginated_google_workspace_provider_user_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_google_workspace_provider_user_list import PaginatedGoogleWorkspaceProviderUserList + +class TestPaginatedGoogleWorkspaceProviderUserList(unittest.TestCase): + """PaginatedGoogleWorkspaceProviderUserList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGoogleWorkspaceProviderUserList: + """Test PaginatedGoogleWorkspaceProviderUserList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGoogleWorkspaceProviderUserList` + """ + model = PaginatedGoogleWorkspaceProviderUserList() + if include_optional: + return PaginatedGoogleWorkspaceProviderUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_workspace_provider_user.GoogleWorkspaceProviderUser( + id = '', + google_id = '', + user = 56, + user_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGoogleWorkspaceProviderUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.google_workspace_provider_user.GoogleWorkspaceProviderUser( + id = '', + google_id = '', + user = 56, + user_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGoogleWorkspaceProviderUserList(self): + """Test PaginatedGoogleWorkspaceProviderUserList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_group_kerberos_source_connection_list.py b/test/test_paginated_group_kerberos_source_connection_list.py new file mode 100644 index 000000000..64f9ac1a5 --- /dev/null +++ b/test/test_paginated_group_kerberos_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_group_kerberos_source_connection_list import PaginatedGroupKerberosSourceConnectionList + +class TestPaginatedGroupKerberosSourceConnectionList(unittest.TestCase): + """PaginatedGroupKerberosSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGroupKerberosSourceConnectionList: + """Test PaginatedGroupKerberosSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGroupKerberosSourceConnectionList` + """ + model = PaginatedGroupKerberosSourceConnectionList() + if include_optional: + return PaginatedGroupKerberosSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_kerberos_source_connection.GroupKerberosSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGroupKerberosSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_kerberos_source_connection.GroupKerberosSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGroupKerberosSourceConnectionList(self): + """Test PaginatedGroupKerberosSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_group_ldap_source_connection_list.py b/test/test_paginated_group_ldap_source_connection_list.py new file mode 100644 index 000000000..5fc97de5c --- /dev/null +++ b/test/test_paginated_group_ldap_source_connection_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_group_ldap_source_connection_list import PaginatedGroupLDAPSourceConnectionList + +class TestPaginatedGroupLDAPSourceConnectionList(unittest.TestCase): + """PaginatedGroupLDAPSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGroupLDAPSourceConnectionList: + """Test PaginatedGroupLDAPSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGroupLDAPSourceConnectionList` + """ + model = PaginatedGroupLDAPSourceConnectionList() + if include_optional: + return PaginatedGroupLDAPSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_ldap_source_connection.GroupLDAPSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + group_obj = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGroupLDAPSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_ldap_source_connection.GroupLDAPSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + group_obj = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGroupLDAPSourceConnectionList(self): + """Test PaginatedGroupLDAPSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_group_list.py b/test/test_paginated_group_list.py new file mode 100644 index 000000000..bbbee62fc --- /dev/null +++ b/test/test_paginated_group_list.py @@ -0,0 +1,191 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_group_list import PaginatedGroupList + +class TestPaginatedGroupList(unittest.TestCase): + """PaginatedGroupList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGroupList: + """Test PaginatedGroupList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGroupList` + """ + model = PaginatedGroupList() + if include_optional: + return PaginatedGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group.Group( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + parents = [ + '' + ], + parents_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, + group_uuid = '', ) + ], + users = [ + 56 + ], + users_obj = [ + authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + uid = '', ) + ], + attributes = { + 'key' : null + }, + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + inherited_roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + children = [ + '' + ], + children_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + group_uuid = '', ) + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group.Group( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + parents = [ + '' + ], + parents_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, + group_uuid = '', ) + ], + users = [ + 56 + ], + users_obj = [ + authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + uid = '', ) + ], + attributes = { + 'key' : null + }, + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + inherited_roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + children = [ + '' + ], + children_obj = [ + authentik_client.models.related_group.RelatedGroup( + pk = '', + name = '', + is_superuser = True, + group_uuid = '', ) + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGroupList(self): + """Test PaginatedGroupList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_group_o_auth_source_connection_list.py b/test/test_paginated_group_o_auth_source_connection_list.py new file mode 100644 index 000000000..4792d59f3 --- /dev/null +++ b/test/test_paginated_group_o_auth_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_group_o_auth_source_connection_list import PaginatedGroupOAuthSourceConnectionList + +class TestPaginatedGroupOAuthSourceConnectionList(unittest.TestCase): + """PaginatedGroupOAuthSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGroupOAuthSourceConnectionList: + """Test PaginatedGroupOAuthSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGroupOAuthSourceConnectionList` + """ + model = PaginatedGroupOAuthSourceConnectionList() + if include_optional: + return PaginatedGroupOAuthSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_o_auth_source_connection.GroupOAuthSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGroupOAuthSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_o_auth_source_connection.GroupOAuthSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGroupOAuthSourceConnectionList(self): + """Test PaginatedGroupOAuthSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_group_plex_source_connection_list.py b/test/test_paginated_group_plex_source_connection_list.py new file mode 100644 index 000000000..97f5868ad --- /dev/null +++ b/test/test_paginated_group_plex_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_group_plex_source_connection_list import PaginatedGroupPlexSourceConnectionList + +class TestPaginatedGroupPlexSourceConnectionList(unittest.TestCase): + """PaginatedGroupPlexSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGroupPlexSourceConnectionList: + """Test PaginatedGroupPlexSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGroupPlexSourceConnectionList` + """ + model = PaginatedGroupPlexSourceConnectionList() + if include_optional: + return PaginatedGroupPlexSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_plex_source_connection.GroupPlexSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGroupPlexSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_plex_source_connection.GroupPlexSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGroupPlexSourceConnectionList(self): + """Test PaginatedGroupPlexSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_group_saml_source_connection_list.py b/test/test_paginated_group_saml_source_connection_list.py new file mode 100644 index 000000000..3adf1b9a4 --- /dev/null +++ b/test/test_paginated_group_saml_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_group_saml_source_connection_list import PaginatedGroupSAMLSourceConnectionList + +class TestPaginatedGroupSAMLSourceConnectionList(unittest.TestCase): + """PaginatedGroupSAMLSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGroupSAMLSourceConnectionList: + """Test PaginatedGroupSAMLSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGroupSAMLSourceConnectionList` + """ + model = PaginatedGroupSAMLSourceConnectionList() + if include_optional: + return PaginatedGroupSAMLSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_saml_source_connection.GroupSAMLSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGroupSAMLSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_saml_source_connection.GroupSAMLSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGroupSAMLSourceConnectionList(self): + """Test PaginatedGroupSAMLSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_group_source_connection_list.py b/test/test_paginated_group_source_connection_list.py new file mode 100644 index 000000000..47653439e --- /dev/null +++ b/test/test_paginated_group_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_group_source_connection_list import PaginatedGroupSourceConnectionList + +class TestPaginatedGroupSourceConnectionList(unittest.TestCase): + """PaginatedGroupSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGroupSourceConnectionList: + """Test PaginatedGroupSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGroupSourceConnectionList` + """ + model = PaginatedGroupSourceConnectionList() + if include_optional: + return PaginatedGroupSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_source_connection.GroupSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGroupSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_source_connection.GroupSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGroupSourceConnectionList(self): + """Test PaginatedGroupSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_group_telegram_source_connection_list.py b/test/test_paginated_group_telegram_source_connection_list.py new file mode 100644 index 000000000..4383b355b --- /dev/null +++ b/test/test_paginated_group_telegram_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_group_telegram_source_connection_list import PaginatedGroupTelegramSourceConnectionList + +class TestPaginatedGroupTelegramSourceConnectionList(unittest.TestCase): + """PaginatedGroupTelegramSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedGroupTelegramSourceConnectionList: + """Test PaginatedGroupTelegramSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedGroupTelegramSourceConnectionList` + """ + model = PaginatedGroupTelegramSourceConnectionList() + if include_optional: + return PaginatedGroupTelegramSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_telegram_source_connection.GroupTelegramSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedGroupTelegramSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.group_telegram_source_connection.GroupTelegramSourceConnection( + pk = 56, + group = '', + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedGroupTelegramSourceConnectionList(self): + """Test PaginatedGroupTelegramSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_identification_stage_list.py b/test/test_paginated_identification_stage_list.py new file mode 100644 index 000000000..b357bbdff --- /dev/null +++ b/test/test_paginated_identification_stage_list.py @@ -0,0 +1,155 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_identification_stage_list import PaginatedIdentificationStageList + +class TestPaginatedIdentificationStageList(unittest.TestCase): + """PaginatedIdentificationStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedIdentificationStageList: + """Test PaginatedIdentificationStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedIdentificationStageList` + """ + model = PaginatedIdentificationStageList() + if include_optional: + return PaginatedIdentificationStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.identification_stage.IdentificationStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + user_fields = [ + 'email' + ], + password_stage = '', + captcha_stage = '', + case_insensitive_matching = True, + show_matched_user = True, + enrollment_flow = '', + recovery_flow = '', + passwordless_flow = '', + sources = [ + '' + ], + show_source_labels = True, + pretend_user_exists = True, + enable_remember_me = True, + webauthn_stage = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedIdentificationStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.identification_stage.IdentificationStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + user_fields = [ + 'email' + ], + password_stage = '', + captcha_stage = '', + case_insensitive_matching = True, + show_matched_user = True, + enrollment_flow = '', + recovery_flow = '', + passwordless_flow = '', + sources = [ + '' + ], + show_source_labels = True, + pretend_user_exists = True, + enable_remember_me = True, + webauthn_stage = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedIdentificationStageList(self): + """Test PaginatedIdentificationStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_initial_permissions_list.py b/test/test_paginated_initial_permissions_list.py new file mode 100644 index 000000000..3f2be6031 --- /dev/null +++ b/test/test_paginated_initial_permissions_list.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_initial_permissions_list import PaginatedInitialPermissionsList + +class TestPaginatedInitialPermissionsList(unittest.TestCase): + """PaginatedInitialPermissionsList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedInitialPermissionsList: + """Test PaginatedInitialPermissionsList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedInitialPermissionsList` + """ + model = PaginatedInitialPermissionsList() + if include_optional: + return PaginatedInitialPermissionsList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.initial_permissions.InitialPermissions( + pk = 56, + name = '', + role = '', + permissions = [ + 56 + ], + permissions_obj = [ + authentik_client.models.permission.Permission( + id = 56, + name = '', + codename = '', + model = '', + app_label = '', + app_label_verbose = '', + model_verbose = '', ) + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedInitialPermissionsList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.initial_permissions.InitialPermissions( + pk = 56, + name = '', + role = '', + permissions = [ + 56 + ], + permissions_obj = [ + authentik_client.models.permission.Permission( + id = 56, + name = '', + codename = '', + model = '', + app_label = '', + app_label_verbose = '', + model_verbose = '', ) + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedInitialPermissionsList(self): + """Test PaginatedInitialPermissionsList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_invitation_list.py b/test/test_paginated_invitation_list.py new file mode 100644 index 000000000..b23d84a67 --- /dev/null +++ b/test/test_paginated_invitation_list.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_invitation_list import PaginatedInvitationList + +class TestPaginatedInvitationList(unittest.TestCase): + """PaginatedInvitationList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedInvitationList: + """Test PaginatedInvitationList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedInvitationList` + """ + model = PaginatedInvitationList() + if include_optional: + return PaginatedInvitationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.invitation.Invitation( + pk = '', + name = 'z', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + fixed_data = { + 'key' : null + }, + created_by = null, + single_use = True, + flow = '', + flow_obj = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedInvitationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.invitation.Invitation( + pk = '', + name = 'z', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + fixed_data = { + 'key' : null + }, + created_by = null, + single_use = True, + flow = '', + flow_obj = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedInvitationList(self): + """Test PaginatedInvitationList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_invitation_stage_list.py b/test/test_paginated_invitation_stage_list.py new file mode 100644 index 000000000..2f340813c --- /dev/null +++ b/test/test_paginated_invitation_stage_list.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_invitation_stage_list import PaginatedInvitationStageList + +class TestPaginatedInvitationStageList(unittest.TestCase): + """PaginatedInvitationStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedInvitationStageList: + """Test PaginatedInvitationStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedInvitationStageList` + """ + model = PaginatedInvitationStageList() + if include_optional: + return PaginatedInvitationStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.invitation_stage.InvitationStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + continue_flow_without_invitation = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedInvitationStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.invitation_stage.InvitationStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + continue_flow_without_invitation = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedInvitationStageList(self): + """Test PaginatedInvitationStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_kerberos_source_list.py b/test/test_paginated_kerberos_source_list.py new file mode 100644 index 000000000..eeb1a601e --- /dev/null +++ b/test/test_paginated_kerberos_source_list.py @@ -0,0 +1,157 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_kerberos_source_list import PaginatedKerberosSourceList + +class TestPaginatedKerberosSourceList(unittest.TestCase): + """PaginatedKerberosSourceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedKerberosSourceList: + """Test PaginatedKerberosSourceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedKerberosSourceList` + """ + model = PaginatedKerberosSourceList() + if include_optional: + return PaginatedKerberosSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.kerberos_source.KerberosSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + group_matching_mode = null, + realm = '', + krb5_conf = '', + kadmin_type = null, + sync_users = True, + sync_users_password = True, + sync_principal = '', + sync_ccache = '', + connectivity = { + 'key' : '' + }, + spnego_server_name = '', + spnego_ccache = '', + password_login_update_internal_password = True, + sync_outgoing_trigger_mode = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedKerberosSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.kerberos_source.KerberosSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + group_matching_mode = null, + realm = '', + krb5_conf = '', + kadmin_type = null, + sync_users = True, + sync_users_password = True, + sync_principal = '', + sync_ccache = '', + connectivity = { + 'key' : '' + }, + spnego_server_name = '', + spnego_ccache = '', + password_login_update_internal_password = True, + sync_outgoing_trigger_mode = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedKerberosSourceList(self): + """Test PaginatedKerberosSourceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_kerberos_source_property_mapping_list.py b/test/test_paginated_kerberos_source_property_mapping_list.py new file mode 100644 index 000000000..d62b21186 --- /dev/null +++ b/test/test_paginated_kerberos_source_property_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_kerberos_source_property_mapping_list import PaginatedKerberosSourcePropertyMappingList + +class TestPaginatedKerberosSourcePropertyMappingList(unittest.TestCase): + """PaginatedKerberosSourcePropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedKerberosSourcePropertyMappingList: + """Test PaginatedKerberosSourcePropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedKerberosSourcePropertyMappingList` + """ + model = PaginatedKerberosSourcePropertyMappingList() + if include_optional: + return PaginatedKerberosSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.kerberos_source_property_mapping.KerberosSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedKerberosSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.kerberos_source_property_mapping.KerberosSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedKerberosSourcePropertyMappingList(self): + """Test PaginatedKerberosSourcePropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_kubernetes_service_connection_list.py b/test/test_paginated_kubernetes_service_connection_list.py new file mode 100644 index 000000000..219b245d0 --- /dev/null +++ b/test/test_paginated_kubernetes_service_connection_list.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_kubernetes_service_connection_list import PaginatedKubernetesServiceConnectionList + +class TestPaginatedKubernetesServiceConnectionList(unittest.TestCase): + """PaginatedKubernetesServiceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedKubernetesServiceConnectionList: + """Test PaginatedKubernetesServiceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedKubernetesServiceConnectionList` + """ + model = PaginatedKubernetesServiceConnectionList() + if include_optional: + return PaginatedKubernetesServiceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.kubernetes_service_connection.KubernetesServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + kubeconfig = { + 'key' : null + }, + verify_ssl = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedKubernetesServiceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.kubernetes_service_connection.KubernetesServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + kubeconfig = { + 'key' : null + }, + verify_ssl = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedKubernetesServiceConnectionList(self): + """Test PaginatedKubernetesServiceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_ldap_outpost_config_list.py b/test/test_paginated_ldap_outpost_config_list.py new file mode 100644 index 000000000..ca1154a56 --- /dev/null +++ b/test/test_paginated_ldap_outpost_config_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_ldap_outpost_config_list import PaginatedLDAPOutpostConfigList + +class TestPaginatedLDAPOutpostConfigList(unittest.TestCase): + """PaginatedLDAPOutpostConfigList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedLDAPOutpostConfigList: + """Test PaginatedLDAPOutpostConfigList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedLDAPOutpostConfigList` + """ + model = PaginatedLDAPOutpostConfigList() + if include_optional: + return PaginatedLDAPOutpostConfigList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ldap_outpost_config.LDAPOutpostConfig( + pk = 56, + name = '', + base_dn = '', + bind_flow_slug = '', + unbind_flow_slug = '', + application_slug = '', + certificate = '', + tls_server_name = '', + uid_start_number = -2147483648, + gid_start_number = -2147483648, + search_mode = 'direct', + bind_mode = 'direct', + mfa_support = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedLDAPOutpostConfigList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ldap_outpost_config.LDAPOutpostConfig( + pk = 56, + name = '', + base_dn = '', + bind_flow_slug = '', + unbind_flow_slug = '', + application_slug = '', + certificate = '', + tls_server_name = '', + uid_start_number = -2147483648, + gid_start_number = -2147483648, + search_mode = 'direct', + bind_mode = 'direct', + mfa_support = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedLDAPOutpostConfigList(self): + """Test PaginatedLDAPOutpostConfigList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_ldap_provider_list.py b/test/test_paginated_ldap_provider_list.py new file mode 100644 index 000000000..151150c5c --- /dev/null +++ b/test/test_paginated_ldap_provider_list.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_ldap_provider_list import PaginatedLDAPProviderList + +class TestPaginatedLDAPProviderList(unittest.TestCase): + """PaginatedLDAPProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedLDAPProviderList: + """Test PaginatedLDAPProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedLDAPProviderList` + """ + model = PaginatedLDAPProviderList() + if include_optional: + return PaginatedLDAPProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ldap_provider.LDAPProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + base_dn = '', + certificate = '', + tls_server_name = '', + uid_start_number = -2147483648, + gid_start_number = -2147483648, + outpost_set = [ + '' + ], + search_mode = 'direct', + bind_mode = 'direct', + mfa_support = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedLDAPProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ldap_provider.LDAPProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + base_dn = '', + certificate = '', + tls_server_name = '', + uid_start_number = -2147483648, + gid_start_number = -2147483648, + outpost_set = [ + '' + ], + search_mode = 'direct', + bind_mode = 'direct', + mfa_support = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedLDAPProviderList(self): + """Test PaginatedLDAPProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_ldap_source_list.py b/test/test_paginated_ldap_source_list.py new file mode 100644 index 000000000..488434214 --- /dev/null +++ b/test/test_paginated_ldap_source_list.py @@ -0,0 +1,181 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_ldap_source_list import PaginatedLDAPSourceList + +class TestPaginatedLDAPSourceList(unittest.TestCase): + """PaginatedLDAPSourceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedLDAPSourceList: + """Test PaginatedLDAPSourceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedLDAPSourceList` + """ + model = PaginatedLDAPSourceList() + if include_optional: + return PaginatedLDAPSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ldap_source.LDAPSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + server_uri = '', + peer_certificate = '', + client_certificate = '', + bind_cn = '', + start_tls = True, + sni = True, + base_dn = '', + additional_user_dn = '', + additional_group_dn = '', + user_object_filter = '', + group_object_filter = '', + group_membership_field = '', + user_membership_attribute = '', + object_uniqueness_field = '', + password_login_update_internal_password = True, + sync_users = True, + sync_users_password = True, + sync_groups = True, + sync_parent_group = '', + connectivity = { + 'key' : { + 'key' : '' + } + }, + lookup_groups_from_user = True, + delete_not_found_objects = True, + sync_outgoing_trigger_mode = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedLDAPSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ldap_source.LDAPSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + server_uri = '', + peer_certificate = '', + client_certificate = '', + bind_cn = '', + start_tls = True, + sni = True, + base_dn = '', + additional_user_dn = '', + additional_group_dn = '', + user_object_filter = '', + group_object_filter = '', + group_membership_field = '', + user_membership_attribute = '', + object_uniqueness_field = '', + password_login_update_internal_password = True, + sync_users = True, + sync_users_password = True, + sync_groups = True, + sync_parent_group = '', + connectivity = { + 'key' : { + 'key' : '' + } + }, + lookup_groups_from_user = True, + delete_not_found_objects = True, + sync_outgoing_trigger_mode = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedLDAPSourceList(self): + """Test PaginatedLDAPSourceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_ldap_source_property_mapping_list.py b/test/test_paginated_ldap_source_property_mapping_list.py new file mode 100644 index 000000000..93f678906 --- /dev/null +++ b/test/test_paginated_ldap_source_property_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_ldap_source_property_mapping_list import PaginatedLDAPSourcePropertyMappingList + +class TestPaginatedLDAPSourcePropertyMappingList(unittest.TestCase): + """PaginatedLDAPSourcePropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedLDAPSourcePropertyMappingList: + """Test PaginatedLDAPSourcePropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedLDAPSourcePropertyMappingList` + """ + model = PaginatedLDAPSourcePropertyMappingList() + if include_optional: + return PaginatedLDAPSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ldap_source_property_mapping.LDAPSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedLDAPSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ldap_source_property_mapping.LDAPSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedLDAPSourcePropertyMappingList(self): + """Test PaginatedLDAPSourcePropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_license_list.py b/test/test_paginated_license_list.py new file mode 100644 index 000000000..f40ad0d6b --- /dev/null +++ b/test/test_paginated_license_list.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_license_list import PaginatedLicenseList + +class TestPaginatedLicenseList(unittest.TestCase): + """PaginatedLicenseList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedLicenseList: + """Test PaginatedLicenseList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedLicenseList` + """ + model = PaginatedLicenseList() + if include_optional: + return PaginatedLicenseList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.license.License( + license_uuid = '', + name = '', + key = '', + expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + internal_users = 56, + external_users = 56, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedLicenseList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.license.License( + license_uuid = '', + name = '', + key = '', + expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + internal_users = 56, + external_users = 56, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedLicenseList(self): + """Test PaginatedLicenseList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_lifecycle_iteration_list.py b/test/test_paginated_lifecycle_iteration_list.py new file mode 100644 index 000000000..b7c4fc0ea --- /dev/null +++ b/test/test_paginated_lifecycle_iteration_list.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_lifecycle_iteration_list import PaginatedLifecycleIterationList + +class TestPaginatedLifecycleIterationList(unittest.TestCase): + """PaginatedLifecycleIterationList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedLifecycleIterationList: + """Test PaginatedLifecycleIterationList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedLifecycleIterationList` + """ + model = PaginatedLifecycleIterationList() + if include_optional: + return PaginatedLifecycleIterationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.lifecycle_iteration.LifecycleIteration( + id = '', + content_type = 'authentik_core.application', + object_id = '', + object_verbose = '', + object_admin_url = '', + state = null, + opened_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + grace_period_end = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + next_review_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + reviews = [ + authentik_client.models.review.Review( + id = '', + iteration = '', + reviewer = null, + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + note = '', ) + ], + rule = null, + user_can_review = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedLifecycleIterationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.lifecycle_iteration.LifecycleIteration( + id = '', + content_type = 'authentik_core.application', + object_id = '', + object_verbose = '', + object_admin_url = '', + state = null, + opened_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + grace_period_end = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + next_review_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + reviews = [ + authentik_client.models.review.Review( + id = '', + iteration = '', + reviewer = null, + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + note = '', ) + ], + rule = null, + user_can_review = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedLifecycleIterationList(self): + """Test PaginatedLifecycleIterationList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_lifecycle_rule_list.py b/test/test_paginated_lifecycle_rule_list.py new file mode 100644 index 000000000..06f0629a9 --- /dev/null +++ b/test/test_paginated_lifecycle_rule_list.py @@ -0,0 +1,139 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_lifecycle_rule_list import PaginatedLifecycleRuleList + +class TestPaginatedLifecycleRuleList(unittest.TestCase): + """PaginatedLifecycleRuleList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedLifecycleRuleList: + """Test PaginatedLifecycleRuleList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedLifecycleRuleList` + """ + model = PaginatedLifecycleRuleList() + if include_optional: + return PaginatedLifecycleRuleList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.lifecycle_rule.LifecycleRule( + id = '', + name = '', + content_type = 'authentik_core.application', + object_id = '', + interval = '', + grace_period = '', + reviewer_groups = [ + '' + ], + reviewer_groups_obj = [ + authentik_client.models.reviewer_group.ReviewerGroup( + pk = '', + name = '', ) + ], + min_reviewers = 0, + min_reviewers_is_per_group = True, + reviewers = [ + '' + ], + reviewers_obj = [ + authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ) + ], + notification_transports = [ + '' + ], + target_verbose = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedLifecycleRuleList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.lifecycle_rule.LifecycleRule( + id = '', + name = '', + content_type = 'authentik_core.application', + object_id = '', + interval = '', + grace_period = '', + reviewer_groups = [ + '' + ], + reviewer_groups_obj = [ + authentik_client.models.reviewer_group.ReviewerGroup( + pk = '', + name = '', ) + ], + min_reviewers = 0, + min_reviewers_is_per_group = True, + reviewers = [ + '' + ], + reviewers_obj = [ + authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ) + ], + notification_transports = [ + '' + ], + target_verbose = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedLifecycleRuleList(self): + """Test PaginatedLifecycleRuleList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_microsoft_entra_provider_group_list.py b/test/test_paginated_microsoft_entra_provider_group_list.py new file mode 100644 index 000000000..da73e0281 --- /dev/null +++ b/test/test_paginated_microsoft_entra_provider_group_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_microsoft_entra_provider_group_list import PaginatedMicrosoftEntraProviderGroupList + +class TestPaginatedMicrosoftEntraProviderGroupList(unittest.TestCase): + """PaginatedMicrosoftEntraProviderGroupList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedMicrosoftEntraProviderGroupList: + """Test PaginatedMicrosoftEntraProviderGroupList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedMicrosoftEntraProviderGroupList` + """ + model = PaginatedMicrosoftEntraProviderGroupList() + if include_optional: + return PaginatedMicrosoftEntraProviderGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.microsoft_entra_provider_group.MicrosoftEntraProviderGroup( + id = '', + microsoft_id = '', + group = '', + group_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedMicrosoftEntraProviderGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.microsoft_entra_provider_group.MicrosoftEntraProviderGroup( + id = '', + microsoft_id = '', + group = '', + group_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedMicrosoftEntraProviderGroupList(self): + """Test PaginatedMicrosoftEntraProviderGroupList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_microsoft_entra_provider_list.py b/test/test_paginated_microsoft_entra_provider_list.py new file mode 100644 index 000000000..0afc0f90b --- /dev/null +++ b/test/test_paginated_microsoft_entra_provider_list.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_microsoft_entra_provider_list import PaginatedMicrosoftEntraProviderList + +class TestPaginatedMicrosoftEntraProviderList(unittest.TestCase): + """PaginatedMicrosoftEntraProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedMicrosoftEntraProviderList: + """Test PaginatedMicrosoftEntraProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedMicrosoftEntraProviderList` + """ + model = PaginatedMicrosoftEntraProviderList() + if include_optional: + return PaginatedMicrosoftEntraProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.microsoft_entra_provider.MicrosoftEntraProvider( + pk = 56, + name = '', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_id = '', + client_secret = '', + tenant_id = '', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + sync_page_size = 1, + sync_page_timeout = '', + dry_run = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedMicrosoftEntraProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.microsoft_entra_provider.MicrosoftEntraProvider( + pk = 56, + name = '', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_id = '', + client_secret = '', + tenant_id = '', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + sync_page_size = 1, + sync_page_timeout = '', + dry_run = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedMicrosoftEntraProviderList(self): + """Test PaginatedMicrosoftEntraProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_microsoft_entra_provider_mapping_list.py b/test/test_paginated_microsoft_entra_provider_mapping_list.py new file mode 100644 index 000000000..249c9595e --- /dev/null +++ b/test/test_paginated_microsoft_entra_provider_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_microsoft_entra_provider_mapping_list import PaginatedMicrosoftEntraProviderMappingList + +class TestPaginatedMicrosoftEntraProviderMappingList(unittest.TestCase): + """PaginatedMicrosoftEntraProviderMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedMicrosoftEntraProviderMappingList: + """Test PaginatedMicrosoftEntraProviderMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedMicrosoftEntraProviderMappingList` + """ + model = PaginatedMicrosoftEntraProviderMappingList() + if include_optional: + return PaginatedMicrosoftEntraProviderMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.microsoft_entra_provider_mapping.MicrosoftEntraProviderMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedMicrosoftEntraProviderMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.microsoft_entra_provider_mapping.MicrosoftEntraProviderMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedMicrosoftEntraProviderMappingList(self): + """Test PaginatedMicrosoftEntraProviderMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_microsoft_entra_provider_user_list.py b/test/test_paginated_microsoft_entra_provider_user_list.py new file mode 100644 index 000000000..5ec923862 --- /dev/null +++ b/test/test_paginated_microsoft_entra_provider_user_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_microsoft_entra_provider_user_list import PaginatedMicrosoftEntraProviderUserList + +class TestPaginatedMicrosoftEntraProviderUserList(unittest.TestCase): + """PaginatedMicrosoftEntraProviderUserList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedMicrosoftEntraProviderUserList: + """Test PaginatedMicrosoftEntraProviderUserList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedMicrosoftEntraProviderUserList` + """ + model = PaginatedMicrosoftEntraProviderUserList() + if include_optional: + return PaginatedMicrosoftEntraProviderUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.microsoft_entra_provider_user.MicrosoftEntraProviderUser( + id = '', + microsoft_id = '', + user = 56, + user_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedMicrosoftEntraProviderUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.microsoft_entra_provider_user.MicrosoftEntraProviderUser( + id = '', + microsoft_id = '', + user = 56, + user_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedMicrosoftEntraProviderUserList(self): + """Test PaginatedMicrosoftEntraProviderUserList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_mutual_tls_stage_list.py b/test/test_paginated_mutual_tls_stage_list.py new file mode 100644 index 000000000..dc3c3964b --- /dev/null +++ b/test/test_paginated_mutual_tls_stage_list.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_mutual_tls_stage_list import PaginatedMutualTLSStageList + +class TestPaginatedMutualTLSStageList(unittest.TestCase): + """PaginatedMutualTLSStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedMutualTLSStageList: + """Test PaginatedMutualTLSStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedMutualTLSStageList` + """ + model = PaginatedMutualTLSStageList() + if include_optional: + return PaginatedMutualTLSStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.mutual_tls_stage.MutualTLSStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + mode = 'optional', + certificate_authorities = [ + '' + ], + cert_attribute = 'subject', + user_attribute = 'username', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedMutualTLSStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.mutual_tls_stage.MutualTLSStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + mode = 'optional', + certificate_authorities = [ + '' + ], + cert_attribute = 'subject', + user_attribute = 'username', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedMutualTLSStageList(self): + """Test PaginatedMutualTLSStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_notification_list.py b/test/test_paginated_notification_list.py new file mode 100644 index 000000000..e51d3fbc1 --- /dev/null +++ b/test/test_paginated_notification_list.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_notification_list import PaginatedNotificationList + +class TestPaginatedNotificationList(unittest.TestCase): + """PaginatedNotificationList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedNotificationList: + """Test PaginatedNotificationList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedNotificationList` + """ + model = PaginatedNotificationList() + if include_optional: + return PaginatedNotificationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.notification.Notification( + pk = '', + severity = null, + body = '', + hyperlink = '', + hyperlink_label = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + event = authentik_client.models.event.Event( + pk = '', + user = { + 'key' : null + }, + action = 'login', + app = '', + context = { + 'key' : null + }, + client_ip = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + }, ), + seen = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedNotificationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.notification.Notification( + pk = '', + severity = null, + body = '', + hyperlink = '', + hyperlink_label = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + event = authentik_client.models.event.Event( + pk = '', + user = { + 'key' : null + }, + action = 'login', + app = '', + context = { + 'key' : null + }, + client_ip = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + }, ), + seen = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedNotificationList(self): + """Test PaginatedNotificationList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_notification_rule_list.py b/test/test_paginated_notification_rule_list.py new file mode 100644 index 000000000..2ec49e459 --- /dev/null +++ b/test/test_paginated_notification_rule_list.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_notification_rule_list import PaginatedNotificationRuleList + +class TestPaginatedNotificationRuleList(unittest.TestCase): + """PaginatedNotificationRuleList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedNotificationRuleList: + """Test PaginatedNotificationRuleList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedNotificationRuleList` + """ + model = PaginatedNotificationRuleList() + if include_optional: + return PaginatedNotificationRuleList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.notification_rule.NotificationRule( + pk = '', + name = '', + transports = [ + '' + ], + severity = null, + destination_group = '', + destination_group_obj = null, + destination_event_user = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedNotificationRuleList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.notification_rule.NotificationRule( + pk = '', + name = '', + transports = [ + '' + ], + severity = null, + destination_group = '', + destination_group_obj = null, + destination_event_user = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedNotificationRuleList(self): + """Test PaginatedNotificationRuleList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_notification_transport_list.py b/test/test_paginated_notification_transport_list.py new file mode 100644 index 000000000..9d1bd2ef6 --- /dev/null +++ b/test/test_paginated_notification_transport_list.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_notification_transport_list import PaginatedNotificationTransportList + +class TestPaginatedNotificationTransportList(unittest.TestCase): + """PaginatedNotificationTransportList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedNotificationTransportList: + """Test PaginatedNotificationTransportList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedNotificationTransportList` + """ + model = PaginatedNotificationTransportList() + if include_optional: + return PaginatedNotificationTransportList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.notification_transport.NotificationTransport( + pk = '', + name = '', + mode = 'local', + mode_verbose = '', + webhook_url = '', + webhook_ca = '', + webhook_mapping_body = '', + webhook_mapping_headers = '', + email_subject_prefix = '', + email_template = '', + send_once = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedNotificationTransportList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.notification_transport.NotificationTransport( + pk = '', + name = '', + mode = 'local', + mode_verbose = '', + webhook_url = '', + webhook_ca = '', + webhook_mapping_body = '', + webhook_mapping_headers = '', + email_subject_prefix = '', + email_template = '', + send_once = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedNotificationTransportList(self): + """Test PaginatedNotificationTransportList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_notification_webhook_mapping_list.py b/test/test_paginated_notification_webhook_mapping_list.py new file mode 100644 index 000000000..95e71b0ee --- /dev/null +++ b/test/test_paginated_notification_webhook_mapping_list.py @@ -0,0 +1,85 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_notification_webhook_mapping_list import PaginatedNotificationWebhookMappingList + +class TestPaginatedNotificationWebhookMappingList(unittest.TestCase): + """PaginatedNotificationWebhookMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedNotificationWebhookMappingList: + """Test PaginatedNotificationWebhookMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedNotificationWebhookMappingList` + """ + model = PaginatedNotificationWebhookMappingList() + if include_optional: + return PaginatedNotificationWebhookMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.notification_webhook_mapping.NotificationWebhookMapping( + pk = '', + name = '', + expression = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedNotificationWebhookMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.notification_webhook_mapping.NotificationWebhookMapping( + pk = '', + name = '', + expression = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedNotificationWebhookMappingList(self): + """Test PaginatedNotificationWebhookMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_o_auth2_provider_list.py b/test/test_paginated_o_auth2_provider_list.py new file mode 100644 index 000000000..c6311955f --- /dev/null +++ b/test/test_paginated_o_auth2_provider_list.py @@ -0,0 +1,169 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_o_auth2_provider_list import PaginatedOAuth2ProviderList + +class TestPaginatedOAuth2ProviderList(unittest.TestCase): + """PaginatedOAuth2ProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedOAuth2ProviderList: + """Test PaginatedOAuth2ProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedOAuth2ProviderList` + """ + model = PaginatedOAuth2ProviderList() + if include_optional: + return PaginatedOAuth2ProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedOAuth2ProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedOAuth2ProviderList(self): + """Test PaginatedOAuth2ProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_o_auth_source_list.py b/test/test_paginated_o_auth_source_list.py new file mode 100644 index 000000000..8b3449b74 --- /dev/null +++ b/test/test_paginated_o_auth_source_list.py @@ -0,0 +1,161 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_o_auth_source_list import PaginatedOAuthSourceList + +class TestPaginatedOAuthSourceList(unittest.TestCase): + """PaginatedOAuthSourceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedOAuthSourceList: + """Test PaginatedOAuthSourceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedOAuthSourceList` + """ + model = PaginatedOAuthSourceList() + if include_optional: + return PaginatedOAuthSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.o_auth_source.OAuthSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + group_matching_mode = null, + provider_type = 'apple', + request_token_url = '', + authorization_url = '', + access_token_url = '', + profile_url = '', + pkce = 'none', + consumer_key = '', + callback_url = '', + additional_scopes = '', + type = null, + oidc_well_known_url = '', + oidc_jwks_url = '', + oidc_jwks = { + 'key' : null + }, + authorization_code_auth_method = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedOAuthSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.o_auth_source.OAuthSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + group_matching_mode = null, + provider_type = 'apple', + request_token_url = '', + authorization_url = '', + access_token_url = '', + profile_url = '', + pkce = 'none', + consumer_key = '', + callback_url = '', + additional_scopes = '', + type = null, + oidc_well_known_url = '', + oidc_jwks_url = '', + oidc_jwks = { + 'key' : null + }, + authorization_code_auth_method = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedOAuthSourceList(self): + """Test PaginatedOAuthSourceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_o_auth_source_property_mapping_list.py b/test/test_paginated_o_auth_source_property_mapping_list.py new file mode 100644 index 000000000..ced7f32d0 --- /dev/null +++ b/test/test_paginated_o_auth_source_property_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_o_auth_source_property_mapping_list import PaginatedOAuthSourcePropertyMappingList + +class TestPaginatedOAuthSourcePropertyMappingList(unittest.TestCase): + """PaginatedOAuthSourcePropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedOAuthSourcePropertyMappingList: + """Test PaginatedOAuthSourcePropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedOAuthSourcePropertyMappingList` + """ + model = PaginatedOAuthSourcePropertyMappingList() + if include_optional: + return PaginatedOAuthSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.o_auth_source_property_mapping.OAuthSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedOAuthSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.o_auth_source_property_mapping.OAuthSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedOAuthSourcePropertyMappingList(self): + """Test PaginatedOAuthSourcePropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_outpost_list.py b/test/test_paginated_outpost_list.py new file mode 100644 index 000000000..e303b106c --- /dev/null +++ b/test/test_paginated_outpost_list.py @@ -0,0 +1,145 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_outpost_list import PaginatedOutpostList + +class TestPaginatedOutpostList(unittest.TestCase): + """PaginatedOutpostList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedOutpostList: + """Test PaginatedOutpostList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedOutpostList` + """ + model = PaginatedOutpostList() + if include_optional: + return PaginatedOutpostList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.outpost.Outpost( + pk = '', + name = '', + type = 'proxy', + providers = [ + 56 + ], + providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + service_connection = '', + service_connection_obj = null, + refresh_interval_s = 56, + token_identifier = '', + config = { + 'key' : null + }, + managed = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedOutpostList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.outpost.Outpost( + pk = '', + name = '', + type = 'proxy', + providers = [ + 56 + ], + providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + service_connection = '', + service_connection_obj = null, + refresh_interval_s = 56, + token_identifier = '', + config = { + 'key' : null + }, + managed = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedOutpostList(self): + """Test PaginatedOutpostList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_password_expiry_policy_list.py b/test/test_paginated_password_expiry_policy_list.py new file mode 100644 index 000000000..3ff9b5cac --- /dev/null +++ b/test/test_paginated_password_expiry_policy_list.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_password_expiry_policy_list import PaginatedPasswordExpiryPolicyList + +class TestPaginatedPasswordExpiryPolicyList(unittest.TestCase): + """PaginatedPasswordExpiryPolicyList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPasswordExpiryPolicyList: + """Test PaginatedPasswordExpiryPolicyList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPasswordExpiryPolicyList` + """ + model = PaginatedPasswordExpiryPolicyList() + if include_optional: + return PaginatedPasswordExpiryPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.password_expiry_policy.PasswordExpiryPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + days = -2147483648, + deny_only = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPasswordExpiryPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.password_expiry_policy.PasswordExpiryPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + days = -2147483648, + deny_only = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPasswordExpiryPolicyList(self): + """Test PaginatedPasswordExpiryPolicyList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_password_policy_list.py b/test/test_paginated_password_policy_list.py new file mode 100644 index 000000000..32430d934 --- /dev/null +++ b/test/test_paginated_password_policy_list.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_password_policy_list import PaginatedPasswordPolicyList + +class TestPaginatedPasswordPolicyList(unittest.TestCase): + """PaginatedPasswordPolicyList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPasswordPolicyList: + """Test PaginatedPasswordPolicyList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPasswordPolicyList` + """ + model = PaginatedPasswordPolicyList() + if include_optional: + return PaginatedPasswordPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.password_policy.PasswordPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + password_field = '', + amount_digits = 0, + amount_uppercase = 0, + amount_lowercase = 0, + amount_symbols = 0, + length_min = 0, + symbol_charset = '', + error_message = '', + check_static_rules = True, + check_have_i_been_pwned = True, + check_zxcvbn = True, + hibp_allowed_count = 0, + zxcvbn_score_threshold = 0, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPasswordPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.password_policy.PasswordPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + password_field = '', + amount_digits = 0, + amount_uppercase = 0, + amount_lowercase = 0, + amount_symbols = 0, + length_min = 0, + symbol_charset = '', + error_message = '', + check_static_rules = True, + check_have_i_been_pwned = True, + check_zxcvbn = True, + hibp_allowed_count = 0, + zxcvbn_score_threshold = 0, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPasswordPolicyList(self): + """Test PaginatedPasswordPolicyList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_password_stage_list.py b/test/test_paginated_password_stage_list.py new file mode 100644 index 000000000..a3c5cc2d0 --- /dev/null +++ b/test/test_paginated_password_stage_list.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_password_stage_list import PaginatedPasswordStageList + +class TestPaginatedPasswordStageList(unittest.TestCase): + """PaginatedPasswordStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPasswordStageList: + """Test PaginatedPasswordStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPasswordStageList` + """ + model = PaginatedPasswordStageList() + if include_optional: + return PaginatedPasswordStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.password_stage.PasswordStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + backends = [ + 'authentik.core.auth.InbuiltBackend' + ], + configure_flow = '', + failed_attempts_before_cancel = -2147483648, + allow_show_password = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPasswordStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.password_stage.PasswordStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + backends = [ + 'authentik.core.auth.InbuiltBackend' + ], + configure_flow = '', + failed_attempts_before_cancel = -2147483648, + allow_show_password = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPasswordStageList(self): + """Test PaginatedPasswordStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_permission_list.py b/test/test_paginated_permission_list.py new file mode 100644 index 000000000..158dabf42 --- /dev/null +++ b/test/test_paginated_permission_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_permission_list import PaginatedPermissionList + +class TestPaginatedPermissionList(unittest.TestCase): + """PaginatedPermissionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPermissionList: + """Test PaginatedPermissionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPermissionList` + """ + model = PaginatedPermissionList() + if include_optional: + return PaginatedPermissionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.permission.Permission( + id = 56, + name = '', + codename = '', + model = '', + app_label = '', + app_label_verbose = '', + model_verbose = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPermissionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.permission.Permission( + id = 56, + name = '', + codename = '', + model = '', + app_label = '', + app_label_verbose = '', + model_verbose = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPermissionList(self): + """Test PaginatedPermissionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_plex_source_list.py b/test/test_paginated_plex_source_list.py new file mode 100644 index 000000000..63d97c4e1 --- /dev/null +++ b/test/test_paginated_plex_source_list.py @@ -0,0 +1,141 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_plex_source_list import PaginatedPlexSourceList + +class TestPaginatedPlexSourceList(unittest.TestCase): + """PaginatedPlexSourceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPlexSourceList: + """Test PaginatedPlexSourceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPlexSourceList` + """ + model = PaginatedPlexSourceList() + if include_optional: + return PaginatedPlexSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.plex_source.PlexSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + group_matching_mode = null, + client_id = '', + allowed_servers = [ + '' + ], + allow_friends = True, + plex_token = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPlexSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.plex_source.PlexSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + group_matching_mode = null, + client_id = '', + allowed_servers = [ + '' + ], + allow_friends = True, + plex_token = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPlexSourceList(self): + """Test PaginatedPlexSourceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_plex_source_property_mapping_list.py b/test/test_paginated_plex_source_property_mapping_list.py new file mode 100644 index 000000000..30e787131 --- /dev/null +++ b/test/test_paginated_plex_source_property_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_plex_source_property_mapping_list import PaginatedPlexSourcePropertyMappingList + +class TestPaginatedPlexSourcePropertyMappingList(unittest.TestCase): + """PaginatedPlexSourcePropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPlexSourcePropertyMappingList: + """Test PaginatedPlexSourcePropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPlexSourcePropertyMappingList` + """ + model = PaginatedPlexSourcePropertyMappingList() + if include_optional: + return PaginatedPlexSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.plex_source_property_mapping.PlexSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPlexSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.plex_source_property_mapping.PlexSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPlexSourcePropertyMappingList(self): + """Test PaginatedPlexSourcePropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_policy_binding_list.py b/test/test_paginated_policy_binding_list.py new file mode 100644 index 000000000..966045764 --- /dev/null +++ b/test/test_paginated_policy_binding_list.py @@ -0,0 +1,105 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_policy_binding_list import PaginatedPolicyBindingList + +class TestPaginatedPolicyBindingList(unittest.TestCase): + """PaginatedPolicyBindingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPolicyBindingList: + """Test PaginatedPolicyBindingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPolicyBindingList` + """ + model = PaginatedPolicyBindingList() + if include_optional: + return PaginatedPolicyBindingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.policy_binding.PolicyBinding( + pk = '', + policy = '', + group = '', + user = 56, + policy_obj = null, + group_obj = null, + user_obj = null, + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPolicyBindingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.policy_binding.PolicyBinding( + pk = '', + policy = '', + group = '', + user = 56, + policy_obj = null, + group_obj = null, + user_obj = null, + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPolicyBindingList(self): + """Test PaginatedPolicyBindingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_policy_list.py b/test/test_paginated_policy_list.py new file mode 100644 index 000000000..d7f0dc572 --- /dev/null +++ b/test/test_paginated_policy_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_policy_list import PaginatedPolicyList + +class TestPaginatedPolicyList(unittest.TestCase): + """PaginatedPolicyList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPolicyList: + """Test PaginatedPolicyList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPolicyList` + """ + model = PaginatedPolicyList() + if include_optional: + return PaginatedPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.policy.Policy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.policy.Policy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPolicyList(self): + """Test PaginatedPolicyList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_prompt_list.py b/test/test_paginated_prompt_list.py new file mode 100644 index 000000000..a21b38569 --- /dev/null +++ b/test/test_paginated_prompt_list.py @@ -0,0 +1,163 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_prompt_list import PaginatedPromptList + +class TestPaginatedPromptList(unittest.TestCase): + """PaginatedPromptList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPromptList: + """Test PaginatedPromptList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPromptList` + """ + model = PaginatedPromptList() + if include_optional: + return PaginatedPromptList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.prompt.Prompt( + pk = '', + name = '', + field_key = '', + label = '', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = -2147483648, + prompt_stages_obj = [ + authentik_client.models.prompt_stage.PromptStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + fields = [ + '' + ], + validation_policies = [ + '' + ], ) + ], + sub_text = '', + placeholder_expression = True, + initial_value_expression = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPromptList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.prompt.Prompt( + pk = '', + name = '', + field_key = '', + label = '', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = -2147483648, + prompt_stages_obj = [ + authentik_client.models.prompt_stage.PromptStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + fields = [ + '' + ], + validation_policies = [ + '' + ], ) + ], + sub_text = '', + placeholder_expression = True, + initial_value_expression = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPromptList(self): + """Test PaginatedPromptList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_prompt_stage_list.py b/test/test_paginated_prompt_stage_list.py new file mode 100644 index 000000000..6756dfb59 --- /dev/null +++ b/test/test_paginated_prompt_stage_list.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_prompt_stage_list import PaginatedPromptStageList + +class TestPaginatedPromptStageList(unittest.TestCase): + """PaginatedPromptStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPromptStageList: + """Test PaginatedPromptStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPromptStageList` + """ + model = PaginatedPromptStageList() + if include_optional: + return PaginatedPromptStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.prompt_stage.PromptStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + fields = [ + '' + ], + validation_policies = [ + '' + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPromptStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.prompt_stage.PromptStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + fields = [ + '' + ], + validation_policies = [ + '' + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPromptStageList(self): + """Test PaginatedPromptStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_property_mapping_list.py b/test/test_paginated_property_mapping_list.py new file mode 100644 index 000000000..a6f7ba5b2 --- /dev/null +++ b/test/test_paginated_property_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_property_mapping_list import PaginatedPropertyMappingList + +class TestPaginatedPropertyMappingList(unittest.TestCase): + """PaginatedPropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedPropertyMappingList: + """Test PaginatedPropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedPropertyMappingList` + """ + model = PaginatedPropertyMappingList() + if include_optional: + return PaginatedPropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.property_mapping.PropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedPropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.property_mapping.PropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedPropertyMappingList(self): + """Test PaginatedPropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_provider_list.py b/test/test_paginated_provider_list.py new file mode 100644 index 000000000..a6dc72b6a --- /dev/null +++ b/test/test_paginated_provider_list.py @@ -0,0 +1,111 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_provider_list import PaginatedProviderList + +class TestPaginatedProviderList(unittest.TestCase): + """PaginatedProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedProviderList: + """Test PaginatedProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedProviderList` + """ + model = PaginatedProviderList() + if include_optional: + return PaginatedProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedProviderList(self): + """Test PaginatedProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_proxy_outpost_config_list.py b/test/test_paginated_proxy_outpost_config_list.py new file mode 100644 index 000000000..122d941ad --- /dev/null +++ b/test/test_paginated_proxy_outpost_config_list.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_proxy_outpost_config_list import PaginatedProxyOutpostConfigList + +class TestPaginatedProxyOutpostConfigList(unittest.TestCase): + """PaginatedProxyOutpostConfigList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedProxyOutpostConfigList: + """Test PaginatedProxyOutpostConfigList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedProxyOutpostConfigList` + """ + model = PaginatedProxyOutpostConfigList() + if include_optional: + return PaginatedProxyOutpostConfigList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.proxy_outpost_config.ProxyOutpostConfig( + pk = 56, + name = '', + internal_host = '', + external_host = '', + internal_host_ssl_validation = True, + client_id = '', + client_secret = '', + oidc_configuration = null, + cookie_secret = '', + certificate = '', + skip_path_regex = '', + basic_auth_enabled = True, + basic_auth_password_attribute = '', + basic_auth_user_attribute = '', + mode = null, + cookie_domain = '', + access_token_validity = 1.337, + intercept_header_auth = True, + scopes_to_request = [ + '' + ], + assigned_application_slug = '', + assigned_application_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedProxyOutpostConfigList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.proxy_outpost_config.ProxyOutpostConfig( + pk = 56, + name = '', + internal_host = '', + external_host = '', + internal_host_ssl_validation = True, + client_id = '', + client_secret = '', + oidc_configuration = null, + cookie_secret = '', + certificate = '', + skip_path_regex = '', + basic_auth_enabled = True, + basic_auth_password_attribute = '', + basic_auth_user_attribute = '', + mode = null, + cookie_domain = '', + access_token_validity = 1.337, + intercept_header_auth = True, + scopes_to_request = [ + '' + ], + assigned_application_slug = '', + assigned_application_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedProxyOutpostConfigList(self): + """Test PaginatedProxyOutpostConfigList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_proxy_provider_list.py b/test/test_paginated_proxy_provider_list.py new file mode 100644 index 000000000..f52d6a488 --- /dev/null +++ b/test/test_paginated_proxy_provider_list.py @@ -0,0 +1,169 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_proxy_provider_list import PaginatedProxyProviderList + +class TestPaginatedProxyProviderList(unittest.TestCase): + """PaginatedProxyProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedProxyProviderList: + """Test PaginatedProxyProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedProxyProviderList` + """ + model = PaginatedProxyProviderList() + if include_optional: + return PaginatedProxyProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.proxy_provider.ProxyProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_id = '', + internal_host = '', + external_host = '', + internal_host_ssl_validation = True, + certificate = '', + skip_path_regex = '', + basic_auth_enabled = True, + basic_auth_password_attribute = '', + basic_auth_user_attribute = '', + mode = null, + intercept_header_auth = True, + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + cookie_domain = '', + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], + access_token_validity = '', + refresh_token_validity = '', + outpost_set = [ + '' + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedProxyProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.proxy_provider.ProxyProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_id = '', + internal_host = '', + external_host = '', + internal_host_ssl_validation = True, + certificate = '', + skip_path_regex = '', + basic_auth_enabled = True, + basic_auth_password_attribute = '', + basic_auth_user_attribute = '', + mode = null, + intercept_header_auth = True, + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + cookie_domain = '', + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], + access_token_validity = '', + refresh_token_validity = '', + outpost_set = [ + '' + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedProxyProviderList(self): + """Test PaginatedProxyProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_rac_property_mapping_list.py b/test/test_paginated_rac_property_mapping_list.py new file mode 100644 index 000000000..45b765277 --- /dev/null +++ b/test/test_paginated_rac_property_mapping_list.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_rac_property_mapping_list import PaginatedRACPropertyMappingList + +class TestPaginatedRACPropertyMappingList(unittest.TestCase): + """PaginatedRACPropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedRACPropertyMappingList: + """Test PaginatedRACPropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedRACPropertyMappingList` + """ + model = PaginatedRACPropertyMappingList() + if include_optional: + return PaginatedRACPropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.rac_property_mapping.RACPropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + static_settings = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedRACPropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.rac_property_mapping.RACPropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + static_settings = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedRACPropertyMappingList(self): + """Test PaginatedRACPropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_rac_provider_list.py b/test/test_paginated_rac_provider_list.py new file mode 100644 index 000000000..780979589 --- /dev/null +++ b/test/test_paginated_rac_provider_list.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_rac_provider_list import PaginatedRACProviderList + +class TestPaginatedRACProviderList(unittest.TestCase): + """PaginatedRACProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedRACProviderList: + """Test PaginatedRACProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedRACProviderList` + """ + model = PaginatedRACProviderList() + if include_optional: + return PaginatedRACProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.rac_provider.RACProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + settings = { + 'key' : null + }, + outpost_set = [ + '' + ], + connection_expiry = '', + delete_token_on_disconnect = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedRACProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.rac_provider.RACProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + settings = { + 'key' : null + }, + outpost_set = [ + '' + ], + connection_expiry = '', + delete_token_on_disconnect = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedRACProviderList(self): + """Test PaginatedRACProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_radius_outpost_config_list.py b/test/test_paginated_radius_outpost_config_list.py new file mode 100644 index 000000000..bbed56653 --- /dev/null +++ b/test/test_paginated_radius_outpost_config_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_radius_outpost_config_list import PaginatedRadiusOutpostConfigList + +class TestPaginatedRadiusOutpostConfigList(unittest.TestCase): + """PaginatedRadiusOutpostConfigList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedRadiusOutpostConfigList: + """Test PaginatedRadiusOutpostConfigList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedRadiusOutpostConfigList` + """ + model = PaginatedRadiusOutpostConfigList() + if include_optional: + return PaginatedRadiusOutpostConfigList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.radius_outpost_config.RadiusOutpostConfig( + pk = 56, + name = '', + application_slug = '', + auth_flow_slug = '', + client_networks = '', + shared_secret = '', + mfa_support = True, + certificate = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedRadiusOutpostConfigList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.radius_outpost_config.RadiusOutpostConfig( + pk = 56, + name = '', + application_slug = '', + auth_flow_slug = '', + client_networks = '', + shared_secret = '', + mfa_support = True, + certificate = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedRadiusOutpostConfigList(self): + """Test PaginatedRadiusOutpostConfigList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_radius_provider_list.py b/test/test_paginated_radius_provider_list.py new file mode 100644 index 000000000..81c774fc8 --- /dev/null +++ b/test/test_paginated_radius_provider_list.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_radius_provider_list import PaginatedRadiusProviderList + +class TestPaginatedRadiusProviderList(unittest.TestCase): + """PaginatedRadiusProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedRadiusProviderList: + """Test PaginatedRadiusProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedRadiusProviderList` + """ + model = PaginatedRadiusProviderList() + if include_optional: + return PaginatedRadiusProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.radius_provider.RadiusProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_networks = '', + shared_secret = '', + outpost_set = [ + '' + ], + mfa_support = True, + certificate = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedRadiusProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.radius_provider.RadiusProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_networks = '', + shared_secret = '', + outpost_set = [ + '' + ], + mfa_support = True, + certificate = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedRadiusProviderList(self): + """Test PaginatedRadiusProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_radius_provider_property_mapping_list.py b/test/test_paginated_radius_provider_property_mapping_list.py new file mode 100644 index 000000000..17435be71 --- /dev/null +++ b/test/test_paginated_radius_provider_property_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_radius_provider_property_mapping_list import PaginatedRadiusProviderPropertyMappingList + +class TestPaginatedRadiusProviderPropertyMappingList(unittest.TestCase): + """PaginatedRadiusProviderPropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedRadiusProviderPropertyMappingList: + """Test PaginatedRadiusProviderPropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedRadiusProviderPropertyMappingList` + """ + model = PaginatedRadiusProviderPropertyMappingList() + if include_optional: + return PaginatedRadiusProviderPropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.radius_provider_property_mapping.RadiusProviderPropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedRadiusProviderPropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.radius_provider_property_mapping.RadiusProviderPropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedRadiusProviderPropertyMappingList(self): + """Test PaginatedRadiusProviderPropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_redirect_stage_list.py b/test/test_paginated_redirect_stage_list.py new file mode 100644 index 000000000..c11db9234 --- /dev/null +++ b/test/test_paginated_redirect_stage_list.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_redirect_stage_list import PaginatedRedirectStageList + +class TestPaginatedRedirectStageList(unittest.TestCase): + """PaginatedRedirectStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedRedirectStageList: + """Test PaginatedRedirectStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedRedirectStageList` + """ + model = PaginatedRedirectStageList() + if include_optional: + return PaginatedRedirectStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.redirect_stage.RedirectStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + keep_context = True, + mode = 'static', + target_static = '', + target_flow = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedRedirectStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.redirect_stage.RedirectStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + keep_context = True, + mode = 'static', + target_static = '', + target_flow = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedRedirectStageList(self): + """Test PaginatedRedirectStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_reputation_list.py b/test/test_paginated_reputation_list.py new file mode 100644 index 000000000..e9cbd2934 --- /dev/null +++ b/test/test_paginated_reputation_list.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_reputation_list import PaginatedReputationList + +class TestPaginatedReputationList(unittest.TestCase): + """PaginatedReputationList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedReputationList: + """Test PaginatedReputationList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedReputationList` + """ + model = PaginatedReputationList() + if include_optional: + return PaginatedReputationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.reputation.Reputation( + pk = '', + identifier = '', + ip = '', + ip_geo_data = { + 'key' : null + }, + ip_asn_data = { + 'key' : null + }, + score = -9223372036854775808, + updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedReputationList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.reputation.Reputation( + pk = '', + identifier = '', + ip = '', + ip_geo_data = { + 'key' : null + }, + ip_asn_data = { + 'key' : null + }, + score = -9223372036854775808, + updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedReputationList(self): + """Test PaginatedReputationList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_reputation_policy_list.py b/test/test_paginated_reputation_policy_list.py new file mode 100644 index 000000000..bda50129d --- /dev/null +++ b/test/test_paginated_reputation_policy_list.py @@ -0,0 +1,101 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_reputation_policy_list import PaginatedReputationPolicyList + +class TestPaginatedReputationPolicyList(unittest.TestCase): + """PaginatedReputationPolicyList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedReputationPolicyList: + """Test PaginatedReputationPolicyList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedReputationPolicyList` + """ + model = PaginatedReputationPolicyList() + if include_optional: + return PaginatedReputationPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.reputation_policy.ReputationPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + check_ip = True, + check_username = True, + threshold = -2147483648, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedReputationPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.reputation_policy.ReputationPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + check_ip = True, + check_username = True, + threshold = -2147483648, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedReputationPolicyList(self): + """Test PaginatedReputationPolicyList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_role_assigned_object_permission_list.py b/test/test_paginated_role_assigned_object_permission_list.py new file mode 100644 index 000000000..9ea0764f7 --- /dev/null +++ b/test/test_paginated_role_assigned_object_permission_list.py @@ -0,0 +1,117 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_role_assigned_object_permission_list import PaginatedRoleAssignedObjectPermissionList + +class TestPaginatedRoleAssignedObjectPermissionList(unittest.TestCase): + """PaginatedRoleAssignedObjectPermissionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedRoleAssignedObjectPermissionList: + """Test PaginatedRoleAssignedObjectPermissionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedRoleAssignedObjectPermissionList` + """ + model = PaginatedRoleAssignedObjectPermissionList() + if include_optional: + return PaginatedRoleAssignedObjectPermissionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.role_assigned_object_permission.RoleAssignedObjectPermission( + role_pk = '', + name = '', + object_permissions = [ + authentik_client.models.role_object_permission.RoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '', ) + ], + model_permissions = [ + authentik_client.models.role_model_permission.RoleModelPermission( + id = 56, + codename = '', + model = '', + app_label = '', + name = '', ) + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedRoleAssignedObjectPermissionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.role_assigned_object_permission.RoleAssignedObjectPermission( + role_pk = '', + name = '', + object_permissions = [ + authentik_client.models.role_object_permission.RoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '', ) + ], + model_permissions = [ + authentik_client.models.role_model_permission.RoleModelPermission( + id = 56, + codename = '', + model = '', + app_label = '', + name = '', ) + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedRoleAssignedObjectPermissionList(self): + """Test PaginatedRoleAssignedObjectPermissionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_role_list.py b/test/test_paginated_role_list.py new file mode 100644 index 000000000..ef6903495 --- /dev/null +++ b/test/test_paginated_role_list.py @@ -0,0 +1,83 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_role_list import PaginatedRoleList + +class TestPaginatedRoleList(unittest.TestCase): + """PaginatedRoleList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedRoleList: + """Test PaginatedRoleList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedRoleList` + """ + model = PaginatedRoleList() + if include_optional: + return PaginatedRoleList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedRoleList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedRoleList(self): + """Test PaginatedRoleList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_saml_property_mapping_list.py b/test/test_paginated_saml_property_mapping_list.py new file mode 100644 index 000000000..e905491e9 --- /dev/null +++ b/test/test_paginated_saml_property_mapping_list.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_saml_property_mapping_list import PaginatedSAMLPropertyMappingList + +class TestPaginatedSAMLPropertyMappingList(unittest.TestCase): + """PaginatedSAMLPropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSAMLPropertyMappingList: + """Test PaginatedSAMLPropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSAMLPropertyMappingList` + """ + model = PaginatedSAMLPropertyMappingList() + if include_optional: + return PaginatedSAMLPropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.saml_property_mapping.SAMLPropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + saml_name = '', + friendly_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSAMLPropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.saml_property_mapping.SAMLPropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + saml_name = '', + friendly_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSAMLPropertyMappingList(self): + """Test PaginatedSAMLPropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_saml_provider_list.py b/test/test_paginated_saml_provider_list.py new file mode 100644 index 000000000..f55aa9cdb --- /dev/null +++ b/test/test_paginated_saml_provider_list.py @@ -0,0 +1,175 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_saml_provider_list import PaginatedSAMLProviderList + +class TestPaginatedSAMLProviderList(unittest.TestCase): + """PaginatedSAMLProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSAMLProviderList: + """Test PaginatedSAMLProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSAMLProviderList` + """ + model = PaginatedSAMLProviderList() + if include_optional: + return PaginatedSAMLProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.saml_provider.SAMLProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + acs_url = '', + sls_url = '', + audience = '', + issuer_override = '', + assertion_valid_not_before = '', + assertion_valid_not_on_or_after = '', + session_valid_not_on_or_after = '', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + verification_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_response = True, + sign_logout_request = True, + sign_logout_response = True, + sp_binding = null, + sls_binding = null, + logout_method = null, + default_relay_state = '', + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + url_download_metadata = '', + url_issuer = '', + url_unified = '', + url_unified_init = '', + url_sso_post = '', + url_sso_redirect = '', + url_sso_init = '', + url_slo_post = '', + url_slo_redirect = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSAMLProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.saml_provider.SAMLProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + acs_url = '', + sls_url = '', + audience = '', + issuer_override = '', + assertion_valid_not_before = '', + assertion_valid_not_on_or_after = '', + session_valid_not_on_or_after = '', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + verification_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_response = True, + sign_logout_request = True, + sign_logout_response = True, + sp_binding = null, + sls_binding = null, + logout_method = null, + default_relay_state = '', + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + url_download_metadata = '', + url_issuer = '', + url_unified = '', + url_unified_init = '', + url_sso_post = '', + url_sso_redirect = '', + url_sso_init = '', + url_slo_post = '', + url_slo_redirect = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSAMLProviderList(self): + """Test PaginatedSAMLProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_saml_source_list.py b/test/test_paginated_saml_source_list.py new file mode 100644 index 000000000..20c920728 --- /dev/null +++ b/test/test_paginated_saml_source_list.py @@ -0,0 +1,161 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_saml_source_list import PaginatedSAMLSourceList + +class TestPaginatedSAMLSourceList(unittest.TestCase): + """PaginatedSAMLSourceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSAMLSourceList: + """Test PaginatedSAMLSourceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSAMLSourceList` + """ + model = PaginatedSAMLSourceList() + if include_optional: + return PaginatedSAMLSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.saml_source.SAMLSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + group_matching_mode = null, + pre_authentication_flow = '', + issuer = '', + sso_url = '', + slo_url = '', + allow_idp_initiated = True, + force_authn = True, + name_id_policy = null, + binding_type = 'REDIRECT', + verification_kp = '', + signing_kp = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + temporary_user_delete_after = '', + encryption_kp = '', + signed_assertion = True, + signed_response = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSAMLSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.saml_source.SAMLSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + group_matching_mode = null, + pre_authentication_flow = '', + issuer = '', + sso_url = '', + slo_url = '', + allow_idp_initiated = True, + force_authn = True, + name_id_policy = null, + binding_type = 'REDIRECT', + verification_kp = '', + signing_kp = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + temporary_user_delete_after = '', + encryption_kp = '', + signed_assertion = True, + signed_response = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSAMLSourceList(self): + """Test PaginatedSAMLSourceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_saml_source_property_mapping_list.py b/test/test_paginated_saml_source_property_mapping_list.py new file mode 100644 index 000000000..b7ccb716c --- /dev/null +++ b/test/test_paginated_saml_source_property_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_saml_source_property_mapping_list import PaginatedSAMLSourcePropertyMappingList + +class TestPaginatedSAMLSourcePropertyMappingList(unittest.TestCase): + """PaginatedSAMLSourcePropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSAMLSourcePropertyMappingList: + """Test PaginatedSAMLSourcePropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSAMLSourcePropertyMappingList` + """ + model = PaginatedSAMLSourcePropertyMappingList() + if include_optional: + return PaginatedSAMLSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.saml_source_property_mapping.SAMLSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSAMLSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.saml_source_property_mapping.SAMLSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSAMLSourcePropertyMappingList(self): + """Test PaginatedSAMLSourcePropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_schedule_list.py b/test/test_paginated_schedule_list.py new file mode 100644 index 000000000..96cee499e --- /dev/null +++ b/test/test_paginated_schedule_list.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_schedule_list import PaginatedScheduleList + +class TestPaginatedScheduleList(unittest.TestCase): + """PaginatedScheduleList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedScheduleList: + """Test PaginatedScheduleList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedScheduleList` + """ + model = PaginatedScheduleList() + if include_optional: + return PaginatedScheduleList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.schedule.Schedule( + id = '', + identifier = '', + uid = '', + actor_name = '', + rel_obj_app_label = '', + rel_obj_model = '', + rel_obj_id = '', + crontab = '', + paused = True, + next_run = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + description = '', + last_task_status = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedScheduleList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.schedule.Schedule( + id = '', + identifier = '', + uid = '', + actor_name = '', + rel_obj_app_label = '', + rel_obj_model = '', + rel_obj_id = '', + crontab = '', + paused = True, + next_run = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + description = '', + last_task_status = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedScheduleList(self): + """Test PaginatedScheduleList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_scim_mapping_list.py b/test/test_paginated_scim_mapping_list.py new file mode 100644 index 000000000..95735c32b --- /dev/null +++ b/test/test_paginated_scim_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_scim_mapping_list import PaginatedSCIMMappingList + +class TestPaginatedSCIMMappingList(unittest.TestCase): + """PaginatedSCIMMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSCIMMappingList: + """Test PaginatedSCIMMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSCIMMappingList` + """ + model = PaginatedSCIMMappingList() + if include_optional: + return PaginatedSCIMMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_mapping.SCIMMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSCIMMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_mapping.SCIMMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSCIMMappingList(self): + """Test PaginatedSCIMMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_scim_provider_group_list.py b/test/test_paginated_scim_provider_group_list.py new file mode 100644 index 000000000..525b6ab3d --- /dev/null +++ b/test/test_paginated_scim_provider_group_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_scim_provider_group_list import PaginatedSCIMProviderGroupList + +class TestPaginatedSCIMProviderGroupList(unittest.TestCase): + """PaginatedSCIMProviderGroupList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSCIMProviderGroupList: + """Test PaginatedSCIMProviderGroupList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSCIMProviderGroupList` + """ + model = PaginatedSCIMProviderGroupList() + if include_optional: + return PaginatedSCIMProviderGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_provider_group.SCIMProviderGroup( + id = '', + scim_id = '', + group = '', + group_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSCIMProviderGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_provider_group.SCIMProviderGroup( + id = '', + scim_id = '', + group = '', + group_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSCIMProviderGroupList(self): + """Test PaginatedSCIMProviderGroupList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_scim_provider_list.py b/test/test_paginated_scim_provider_list.py new file mode 100644 index 000000000..630d69c86 --- /dev/null +++ b/test/test_paginated_scim_provider_list.py @@ -0,0 +1,141 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_scim_provider_list import PaginatedSCIMProviderList + +class TestPaginatedSCIMProviderList(unittest.TestCase): + """PaginatedSCIMProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSCIMProviderList: + """Test PaginatedSCIMProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSCIMProviderList` + """ + model = PaginatedSCIMProviderList() + if include_optional: + return PaginatedSCIMProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_provider.SCIMProvider( + pk = 56, + name = '', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + verify_certificates = True, + token = '', + auth_mode = 'token', + auth_oauth = '', + auth_oauth_params = { + 'key' : null + }, + compatibility_mode = null, + service_provider_config_cache_timeout = '', + exclude_users_service_account = True, + sync_page_size = 1, + sync_page_timeout = '', + group_filters = [ + '' + ], + dry_run = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSCIMProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_provider.SCIMProvider( + pk = 56, + name = '', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + verify_certificates = True, + token = '', + auth_mode = 'token', + auth_oauth = '', + auth_oauth_params = { + 'key' : null + }, + compatibility_mode = null, + service_provider_config_cache_timeout = '', + exclude_users_service_account = True, + sync_page_size = 1, + sync_page_timeout = '', + group_filters = [ + '' + ], + dry_run = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSCIMProviderList(self): + """Test PaginatedSCIMProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_scim_provider_user_list.py b/test/test_paginated_scim_provider_user_list.py new file mode 100644 index 000000000..2e343281d --- /dev/null +++ b/test/test_paginated_scim_provider_user_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_scim_provider_user_list import PaginatedSCIMProviderUserList + +class TestPaginatedSCIMProviderUserList(unittest.TestCase): + """PaginatedSCIMProviderUserList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSCIMProviderUserList: + """Test PaginatedSCIMProviderUserList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSCIMProviderUserList` + """ + model = PaginatedSCIMProviderUserList() + if include_optional: + return PaginatedSCIMProviderUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_provider_user.SCIMProviderUser( + id = '', + scim_id = '', + user = 56, + user_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSCIMProviderUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_provider_user.SCIMProviderUser( + id = '', + scim_id = '', + user = 56, + user_obj = null, + provider = 56, + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSCIMProviderUserList(self): + """Test PaginatedSCIMProviderUserList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_scim_source_group_list.py b/test/test_paginated_scim_source_group_list.py new file mode 100644 index 000000000..1c7288abf --- /dev/null +++ b/test/test_paginated_scim_source_group_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_scim_source_group_list import PaginatedSCIMSourceGroupList + +class TestPaginatedSCIMSourceGroupList(unittest.TestCase): + """PaginatedSCIMSourceGroupList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSCIMSourceGroupList: + """Test PaginatedSCIMSourceGroupList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSCIMSourceGroupList` + """ + model = PaginatedSCIMSourceGroupList() + if include_optional: + return PaginatedSCIMSourceGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_source_group.SCIMSourceGroup( + id = '', + external_id = '', + group = '', + group_obj = null, + source = '', + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSCIMSourceGroupList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_source_group.SCIMSourceGroup( + id = '', + external_id = '', + group = '', + group_obj = null, + source = '', + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSCIMSourceGroupList(self): + """Test PaginatedSCIMSourceGroupList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_scim_source_list.py b/test/test_paginated_scim_source_list.py new file mode 100644 index 000000000..16183f73c --- /dev/null +++ b/test/test_paginated_scim_source_list.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_scim_source_list import PaginatedSCIMSourceList + +class TestPaginatedSCIMSourceList(unittest.TestCase): + """PaginatedSCIMSourceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSCIMSourceList: + """Test PaginatedSCIMSourceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSCIMSourceList` + """ + model = PaginatedSCIMSourceList() + if include_optional: + return PaginatedSCIMSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_source.SCIMSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + user_path_template = '', + root_url = '', + token_obj = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSCIMSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_source.SCIMSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + user_path_template = '', + root_url = '', + token_obj = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSCIMSourceList(self): + """Test PaginatedSCIMSourceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_scim_source_property_mapping_list.py b/test/test_paginated_scim_source_property_mapping_list.py new file mode 100644 index 000000000..76daaa89e --- /dev/null +++ b/test/test_paginated_scim_source_property_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_scim_source_property_mapping_list import PaginatedSCIMSourcePropertyMappingList + +class TestPaginatedSCIMSourcePropertyMappingList(unittest.TestCase): + """PaginatedSCIMSourcePropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSCIMSourcePropertyMappingList: + """Test PaginatedSCIMSourcePropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSCIMSourcePropertyMappingList` + """ + model = PaginatedSCIMSourcePropertyMappingList() + if include_optional: + return PaginatedSCIMSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_source_property_mapping.SCIMSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSCIMSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_source_property_mapping.SCIMSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSCIMSourcePropertyMappingList(self): + """Test PaginatedSCIMSourcePropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_scim_source_user_list.py b/test/test_paginated_scim_source_user_list.py new file mode 100644 index 000000000..89dad7848 --- /dev/null +++ b/test/test_paginated_scim_source_user_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_scim_source_user_list import PaginatedSCIMSourceUserList + +class TestPaginatedSCIMSourceUserList(unittest.TestCase): + """PaginatedSCIMSourceUserList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSCIMSourceUserList: + """Test PaginatedSCIMSourceUserList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSCIMSourceUserList` + """ + model = PaginatedSCIMSourceUserList() + if include_optional: + return PaginatedSCIMSourceUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_source_user.SCIMSourceUser( + id = '', + external_id = '', + user = 56, + user_obj = null, + source = '', + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSCIMSourceUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scim_source_user.SCIMSourceUser( + id = '', + external_id = '', + user = 56, + user_obj = null, + source = '', + attributes = { + 'key' : null + }, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSCIMSourceUserList(self): + """Test PaginatedSCIMSourceUserList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_scope_mapping_list.py b/test/test_paginated_scope_mapping_list.py new file mode 100644 index 000000000..670b2e225 --- /dev/null +++ b/test/test_paginated_scope_mapping_list.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_scope_mapping_list import PaginatedScopeMappingList + +class TestPaginatedScopeMappingList(unittest.TestCase): + """PaginatedScopeMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedScopeMappingList: + """Test PaginatedScopeMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedScopeMappingList` + """ + model = PaginatedScopeMappingList() + if include_optional: + return PaginatedScopeMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scope_mapping.ScopeMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + scope_name = '', + description = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedScopeMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.scope_mapping.ScopeMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + scope_name = '', + description = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedScopeMappingList(self): + """Test PaginatedScopeMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_service_connection_list.py b/test/test_paginated_service_connection_list.py new file mode 100644 index 000000000..ed35d3d15 --- /dev/null +++ b/test/test_paginated_service_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_service_connection_list import PaginatedServiceConnectionList + +class TestPaginatedServiceConnectionList(unittest.TestCase): + """PaginatedServiceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedServiceConnectionList: + """Test PaginatedServiceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedServiceConnectionList` + """ + model = PaginatedServiceConnectionList() + if include_optional: + return PaginatedServiceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.service_connection.ServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedServiceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.service_connection.ServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedServiceConnectionList(self): + """Test PaginatedServiceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_sms_device_list.py b/test/test_paginated_sms_device_list.py new file mode 100644 index 000000000..4605f0e87 --- /dev/null +++ b/test/test_paginated_sms_device_list.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_sms_device_list import PaginatedSMSDeviceList + +class TestPaginatedSMSDeviceList(unittest.TestCase): + """PaginatedSMSDeviceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSMSDeviceList: + """Test PaginatedSMSDeviceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSMSDeviceList` + """ + model = PaginatedSMSDeviceList() + if include_optional: + return PaginatedSMSDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.sms_device.SMSDevice( + name = '', + pk = 56, + phone_number = '', + user = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSMSDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.sms_device.SMSDevice( + name = '', + pk = 56, + phone_number = '', + user = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSMSDeviceList(self): + """Test PaginatedSMSDeviceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_source_list.py b/test/test_paginated_source_list.py new file mode 100644 index 000000000..b516b1543 --- /dev/null +++ b/test/test_paginated_source_list.py @@ -0,0 +1,127 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_source_list import PaginatedSourceList + +class TestPaginatedSourceList(unittest.TestCase): + """PaginatedSourceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSourceList: + """Test PaginatedSourceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSourceList` + """ + model = PaginatedSourceList() + if include_optional: + return PaginatedSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSourceList(self): + """Test PaginatedSourceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_source_stage_list.py b/test/test_paginated_source_stage_list.py new file mode 100644 index 000000000..61b0182be --- /dev/null +++ b/test/test_paginated_source_stage_list.py @@ -0,0 +1,125 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_source_stage_list import PaginatedSourceStageList + +class TestPaginatedSourceStageList(unittest.TestCase): + """PaginatedSourceStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSourceStageList: + """Test PaginatedSourceStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSourceStageList` + """ + model = PaginatedSourceStageList() + if include_optional: + return PaginatedSourceStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.source_stage.SourceStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + source = '', + resume_timeout = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSourceStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.source_stage.SourceStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + source = '', + resume_timeout = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSourceStageList(self): + """Test PaginatedSourceStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_ssf_provider_list.py b/test/test_paginated_ssf_provider_list.py new file mode 100644 index 000000000..274c67517 --- /dev/null +++ b/test/test_paginated_ssf_provider_list.py @@ -0,0 +1,145 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_ssf_provider_list import PaginatedSSFProviderList + +class TestPaginatedSSFProviderList(unittest.TestCase): + """PaginatedSSFProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSSFProviderList: + """Test PaginatedSSFProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSSFProviderList` + """ + model = PaginatedSSFProviderList() + if include_optional: + return PaginatedSSFProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ssf_provider.SSFProvider( + pk = 56, + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + signing_key = '', + token_obj = null, + oidc_auth_providers = [ + 56 + ], + oidc_auth_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + ssf_url = '', + event_retention = '', + push_verify_certificates = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSSFProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ssf_provider.SSFProvider( + pk = 56, + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + signing_key = '', + token_obj = null, + oidc_auth_providers = [ + 56 + ], + oidc_auth_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + ssf_url = '', + event_retention = '', + push_verify_certificates = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSSFProviderList(self): + """Test PaginatedSSFProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_ssf_stream_list.py b/test/test_paginated_ssf_stream_list.py new file mode 100644 index 000000000..4b064fc5b --- /dev/null +++ b/test/test_paginated_ssf_stream_list.py @@ -0,0 +1,107 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_ssf_stream_list import PaginatedSSFStreamList + +class TestPaginatedSSFStreamList(unittest.TestCase): + """PaginatedSSFStreamList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedSSFStreamList: + """Test PaginatedSSFStreamList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedSSFStreamList` + """ + model = PaginatedSSFStreamList() + if include_optional: + return PaginatedSSFStreamList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ssf_stream.SSFStream( + pk = '', + status = 'enabled', + provider = 56, + provider_obj = null, + delivery_method = 'https://schemas.openid.net/secevent/risc/delivery-method/push', + endpoint_url = '', + events_requested = [ + 'https://schemas.openid.net/secevent/caep/event-type/session-revoked' + ], + format = '', + aud = [ + '' + ], + iss = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedSSFStreamList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ssf_stream.SSFStream( + pk = '', + status = 'enabled', + provider = 56, + provider_obj = null, + delivery_method = 'https://schemas.openid.net/secevent/risc/delivery-method/push', + endpoint_url = '', + events_requested = [ + 'https://schemas.openid.net/secevent/caep/event-type/session-revoked' + ], + format = '', + aud = [ + '' + ], + iss = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedSSFStreamList(self): + """Test PaginatedSSFStreamList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_stage_list.py b/test/test_paginated_stage_list.py new file mode 100644 index 000000000..8be49b23e --- /dev/null +++ b/test/test_paginated_stage_list.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_stage_list import PaginatedStageList + +class TestPaginatedStageList(unittest.TestCase): + """PaginatedStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedStageList: + """Test PaginatedStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedStageList` + """ + model = PaginatedStageList() + if include_optional: + return PaginatedStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.stage.Stage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.stage.Stage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedStageList(self): + """Test PaginatedStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_static_device_list.py b/test/test_paginated_static_device_list.py new file mode 100644 index 000000000..65632bde0 --- /dev/null +++ b/test/test_paginated_static_device_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_static_device_list import PaginatedStaticDeviceList + +class TestPaginatedStaticDeviceList(unittest.TestCase): + """PaginatedStaticDeviceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedStaticDeviceList: + """Test PaginatedStaticDeviceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedStaticDeviceList` + """ + model = PaginatedStaticDeviceList() + if include_optional: + return PaginatedStaticDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.static_device.StaticDevice( + name = '', + token_set = [ + authentik_client.models.static_device_token.StaticDeviceToken( + token = '', ) + ], + pk = 56, + user = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedStaticDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.static_device.StaticDevice( + name = '', + token_set = [ + authentik_client.models.static_device_token.StaticDeviceToken( + token = '', ) + ], + pk = 56, + user = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedStaticDeviceList(self): + """Test PaginatedStaticDeviceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_task_list.py b/test/test_paginated_task_list.py new file mode 100644 index 000000000..2b72bdfeb --- /dev/null +++ b/test/test_paginated_task_list.py @@ -0,0 +1,145 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_task_list import PaginatedTaskList + +class TestPaginatedTaskList(unittest.TestCase): + """PaginatedTaskList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedTaskList: + """Test PaginatedTaskList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedTaskList` + """ + model = PaginatedTaskList() + if include_optional: + return PaginatedTaskList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.task.Task( + message_id = '', + queue_name = '', + actor_name = '', + state = null, + mtime = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + retries = 0, + eta = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + rel_obj_app_label = '', + rel_obj_model = '', + rel_obj_id = '', + uid = '', + logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + previous_logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + aggregated_status = 'queued', + description = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedTaskList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.task.Task( + message_id = '', + queue_name = '', + actor_name = '', + state = null, + mtime = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + retries = 0, + eta = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + rel_obj_app_label = '', + rel_obj_model = '', + rel_obj_id = '', + uid = '', + logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + previous_logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + aggregated_status = 'queued', + description = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedTaskList(self): + """Test PaginatedTaskList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_telegram_source_list.py b/test/test_paginated_telegram_source_list.py new file mode 100644 index 000000000..7db406e3d --- /dev/null +++ b/test/test_paginated_telegram_source_list.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_telegram_source_list import PaginatedTelegramSourceList + +class TestPaginatedTelegramSourceList(unittest.TestCase): + """PaginatedTelegramSourceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedTelegramSourceList: + """Test PaginatedTelegramSourceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedTelegramSourceList` + """ + model = PaginatedTelegramSourceList() + if include_optional: + return PaginatedTelegramSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.telegram_source.TelegramSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + bot_username = '', + request_message_access = True, + pre_authentication_flow = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedTelegramSourceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.telegram_source.TelegramSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, + bot_username = '', + request_message_access = True, + pre_authentication_flow = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedTelegramSourceList(self): + """Test PaginatedTelegramSourceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_telegram_source_property_mapping_list.py b/test/test_paginated_telegram_source_property_mapping_list.py new file mode 100644 index 000000000..79dabbf1d --- /dev/null +++ b/test/test_paginated_telegram_source_property_mapping_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_telegram_source_property_mapping_list import PaginatedTelegramSourcePropertyMappingList + +class TestPaginatedTelegramSourcePropertyMappingList(unittest.TestCase): + """PaginatedTelegramSourcePropertyMappingList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedTelegramSourcePropertyMappingList: + """Test PaginatedTelegramSourcePropertyMappingList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedTelegramSourcePropertyMappingList` + """ + model = PaginatedTelegramSourcePropertyMappingList() + if include_optional: + return PaginatedTelegramSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.telegram_source_property_mapping.TelegramSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedTelegramSourcePropertyMappingList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.telegram_source_property_mapping.TelegramSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedTelegramSourcePropertyMappingList(self): + """Test PaginatedTelegramSourcePropertyMappingList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_tenant_list.py b/test/test_paginated_tenant_list.py new file mode 100644 index 000000000..1ce08d70b --- /dev/null +++ b/test/test_paginated_tenant_list.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_tenant_list import PaginatedTenantList + +class TestPaginatedTenantList(unittest.TestCase): + """PaginatedTenantList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedTenantList: + """Test PaginatedTenantList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedTenantList` + """ + model = PaginatedTenantList() + if include_optional: + return PaginatedTenantList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.tenant.Tenant( + tenant_uuid = '', + schema_name = '', + name = '', + ready = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedTenantList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.tenant.Tenant( + tenant_uuid = '', + schema_name = '', + name = '', + ready = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedTenantList(self): + """Test PaginatedTenantList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_token_list.py b/test/test_paginated_token_list.py new file mode 100644 index 000000000..75cde6266 --- /dev/null +++ b/test/test_paginated_token_list.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_token_list import PaginatedTokenList + +class TestPaginatedTokenList(unittest.TestCase): + """PaginatedTokenList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedTokenList: + """Test PaginatedTokenList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedTokenList` + """ + model = PaginatedTokenList() + if include_optional: + return PaginatedTokenList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.token.Token( + pk = '', + managed = '', + identifier = 'z', + intent = 'verification', + user = 56, + user_obj = null, + description = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedTokenList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.token.Token( + pk = '', + managed = '', + identifier = 'z', + intent = 'verification', + user = 56, + user_obj = null, + description = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedTokenList(self): + """Test PaginatedTokenList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_token_model_list.py b/test/test_paginated_token_model_list.py new file mode 100644 index 000000000..57f915fcc --- /dev/null +++ b/test/test_paginated_token_model_list.py @@ -0,0 +1,267 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_token_model_list import PaginatedTokenModelList + +class TestPaginatedTokenModelList(unittest.TestCase): + """PaginatedTokenModelList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedTokenModelList: + """Test PaginatedTokenModelList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedTokenModelList` + """ + model = PaginatedTokenModelList() + if include_optional: + return PaginatedTokenModelList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.token_model.TokenModel( + pk = 56, + provider = authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ), + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + is_expired = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + scope = [ + '' + ], + id_token = '', + revoked = True, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedTokenModelList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.token_model.TokenModel( + pk = 56, + provider = authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ), + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + is_expired = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + scope = [ + '' + ], + id_token = '', + revoked = True, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedTokenModelList(self): + """Test PaginatedTokenModelList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_totp_device_list.py b/test/test_paginated_totp_device_list.py new file mode 100644 index 000000000..a6d44f182 --- /dev/null +++ b/test/test_paginated_totp_device_list.py @@ -0,0 +1,85 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_totp_device_list import PaginatedTOTPDeviceList + +class TestPaginatedTOTPDeviceList(unittest.TestCase): + """PaginatedTOTPDeviceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedTOTPDeviceList: + """Test PaginatedTOTPDeviceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedTOTPDeviceList` + """ + model = PaginatedTOTPDeviceList() + if include_optional: + return PaginatedTOTPDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.totp_device.TOTPDevice( + name = '', + pk = 56, + user = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedTOTPDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.totp_device.TOTPDevice( + name = '', + pk = 56, + user = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedTOTPDeviceList(self): + """Test PaginatedTOTPDeviceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_unique_password_policy_list.py b/test/test_paginated_unique_password_policy_list.py new file mode 100644 index 000000000..8257b56ca --- /dev/null +++ b/test/test_paginated_unique_password_policy_list.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_unique_password_policy_list import PaginatedUniquePasswordPolicyList + +class TestPaginatedUniquePasswordPolicyList(unittest.TestCase): + """PaginatedUniquePasswordPolicyList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUniquePasswordPolicyList: + """Test PaginatedUniquePasswordPolicyList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUniquePasswordPolicyList` + """ + model = PaginatedUniquePasswordPolicyList() + if include_optional: + return PaginatedUniquePasswordPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.unique_password_policy.UniquePasswordPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + password_field = '', + num_historical_passwords = 0, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUniquePasswordPolicyList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.unique_password_policy.UniquePasswordPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + password_field = '', + num_historical_passwords = 0, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUniquePasswordPolicyList(self): + """Test PaginatedUniquePasswordPolicyList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_consent_list.py b/test/test_paginated_user_consent_list.py new file mode 100644 index 000000000..857fd9ae1 --- /dev/null +++ b/test/test_paginated_user_consent_list.py @@ -0,0 +1,245 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_consent_list import PaginatedUserConsentList + +class TestPaginatedUserConsentList(unittest.TestCase): + """PaginatedUserConsentList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserConsentList: + """Test PaginatedUserConsentList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserConsentList` + """ + model = PaginatedUserConsentList() + if include_optional: + return PaginatedUserConsentList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_consent.UserConsent( + pk = 56, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True, + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + application = authentik_client.models.application.Application( + pk = '', + name = '', + slug = 'z', + provider = 56, + provider_obj = null, + backchannel_providers = [ + 56 + ], + backchannel_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + launch_url = '', + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_icon_url = '', + meta_icon_themed_urls = null, + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True, ), + permissions = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserConsentList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_consent.UserConsent( + pk = 56, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True, + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + application = authentik_client.models.application.Application( + pk = '', + name = '', + slug = 'z', + provider = 56, + provider_obj = null, + backchannel_providers = [ + 56 + ], + backchannel_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + launch_url = '', + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_icon_url = '', + meta_icon_themed_urls = null, + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True, ), + permissions = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserConsentList(self): + """Test PaginatedUserConsentList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_delete_stage_list.py b/test/test_paginated_user_delete_stage_list.py new file mode 100644 index 000000000..1218855e9 --- /dev/null +++ b/test/test_paginated_user_delete_stage_list.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_delete_stage_list import PaginatedUserDeleteStageList + +class TestPaginatedUserDeleteStageList(unittest.TestCase): + """PaginatedUserDeleteStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserDeleteStageList: + """Test PaginatedUserDeleteStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserDeleteStageList` + """ + model = PaginatedUserDeleteStageList() + if include_optional: + return PaginatedUserDeleteStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_delete_stage.UserDeleteStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserDeleteStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_delete_stage.UserDeleteStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserDeleteStageList(self): + """Test PaginatedUserDeleteStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_kerberos_source_connection_list.py b/test/test_paginated_user_kerberos_source_connection_list.py new file mode 100644 index 000000000..23e341195 --- /dev/null +++ b/test/test_paginated_user_kerberos_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_kerberos_source_connection_list import PaginatedUserKerberosSourceConnectionList + +class TestPaginatedUserKerberosSourceConnectionList(unittest.TestCase): + """PaginatedUserKerberosSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserKerberosSourceConnectionList: + """Test PaginatedUserKerberosSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserKerberosSourceConnectionList` + """ + model = PaginatedUserKerberosSourceConnectionList() + if include_optional: + return PaginatedUserKerberosSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_kerberos_source_connection.UserKerberosSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserKerberosSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_kerberos_source_connection.UserKerberosSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserKerberosSourceConnectionList(self): + """Test PaginatedUserKerberosSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_ldap_source_connection_list.py b/test/test_paginated_user_ldap_source_connection_list.py new file mode 100644 index 000000000..c4752914e --- /dev/null +++ b/test/test_paginated_user_ldap_source_connection_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_ldap_source_connection_list import PaginatedUserLDAPSourceConnectionList + +class TestPaginatedUserLDAPSourceConnectionList(unittest.TestCase): + """PaginatedUserLDAPSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserLDAPSourceConnectionList: + """Test PaginatedUserLDAPSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserLDAPSourceConnectionList` + """ + model = PaginatedUserLDAPSourceConnectionList() + if include_optional: + return PaginatedUserLDAPSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_ldap_source_connection.UserLDAPSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + user_obj = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserLDAPSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_ldap_source_connection.UserLDAPSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + user_obj = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserLDAPSourceConnectionList(self): + """Test PaginatedUserLDAPSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_list.py b/test/test_paginated_user_list.py new file mode 100644 index 000000000..4e5e8b2ba --- /dev/null +++ b/test/test_paginated_user_list.py @@ -0,0 +1,157 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_list import PaginatedUserList + +class TestPaginatedUserList(unittest.TestCase): + """PaginatedUserList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserList: + """Test PaginatedUserList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserList` + """ + model = PaginatedUserList() + if include_optional: + return PaginatedUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserList(self): + """Test PaginatedUserList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_login_stage_list.py b/test/test_paginated_user_login_stage_list.py new file mode 100644 index 000000000..0063044e5 --- /dev/null +++ b/test/test_paginated_user_login_stage_list.py @@ -0,0 +1,133 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_login_stage_list import PaginatedUserLoginStageList + +class TestPaginatedUserLoginStageList(unittest.TestCase): + """PaginatedUserLoginStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserLoginStageList: + """Test PaginatedUserLoginStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserLoginStageList` + """ + model = PaginatedUserLoginStageList() + if include_optional: + return PaginatedUserLoginStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_login_stage.UserLoginStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + session_duration = '', + terminate_other_sessions = True, + remember_me_offset = '', + network_binding = null, + geoip_binding = null, + remember_device = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserLoginStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_login_stage.UserLoginStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + session_duration = '', + terminate_other_sessions = True, + remember_me_offset = '', + network_binding = null, + geoip_binding = null, + remember_device = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserLoginStageList(self): + """Test PaginatedUserLoginStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_logout_stage_list.py b/test/test_paginated_user_logout_stage_list.py new file mode 100644 index 000000000..a1eb81650 --- /dev/null +++ b/test/test_paginated_user_logout_stage_list.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_logout_stage_list import PaginatedUserLogoutStageList + +class TestPaginatedUserLogoutStageList(unittest.TestCase): + """PaginatedUserLogoutStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserLogoutStageList: + """Test PaginatedUserLogoutStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserLogoutStageList` + """ + model = PaginatedUserLogoutStageList() + if include_optional: + return PaginatedUserLogoutStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_logout_stage.UserLogoutStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserLogoutStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_logout_stage.UserLogoutStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserLogoutStageList(self): + """Test PaginatedUserLogoutStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_o_auth_source_connection_list.py b/test/test_paginated_user_o_auth_source_connection_list.py new file mode 100644 index 000000000..9182a066f --- /dev/null +++ b/test/test_paginated_user_o_auth_source_connection_list.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_o_auth_source_connection_list import PaginatedUserOAuthSourceConnectionList + +class TestPaginatedUserOAuthSourceConnectionList(unittest.TestCase): + """PaginatedUserOAuthSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserOAuthSourceConnectionList: + """Test PaginatedUserOAuthSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserOAuthSourceConnectionList` + """ + model = PaginatedUserOAuthSourceConnectionList() + if include_optional: + return PaginatedUserOAuthSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_o_auth_source_connection.UserOAuthSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserOAuthSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_o_auth_source_connection.UserOAuthSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserOAuthSourceConnectionList(self): + """Test PaginatedUserOAuthSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_plex_source_connection_list.py b/test/test_paginated_user_plex_source_connection_list.py new file mode 100644 index 000000000..515f7f5dd --- /dev/null +++ b/test/test_paginated_user_plex_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_plex_source_connection_list import PaginatedUserPlexSourceConnectionList + +class TestPaginatedUserPlexSourceConnectionList(unittest.TestCase): + """PaginatedUserPlexSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserPlexSourceConnectionList: + """Test PaginatedUserPlexSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserPlexSourceConnectionList` + """ + model = PaginatedUserPlexSourceConnectionList() + if include_optional: + return PaginatedUserPlexSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_plex_source_connection.UserPlexSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserPlexSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_plex_source_connection.UserPlexSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserPlexSourceConnectionList(self): + """Test PaginatedUserPlexSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_saml_source_connection_list.py b/test/test_paginated_user_saml_source_connection_list.py new file mode 100644 index 000000000..b8c959f1b --- /dev/null +++ b/test/test_paginated_user_saml_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_saml_source_connection_list import PaginatedUserSAMLSourceConnectionList + +class TestPaginatedUserSAMLSourceConnectionList(unittest.TestCase): + """PaginatedUserSAMLSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserSAMLSourceConnectionList: + """Test PaginatedUserSAMLSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserSAMLSourceConnectionList` + """ + model = PaginatedUserSAMLSourceConnectionList() + if include_optional: + return PaginatedUserSAMLSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_saml_source_connection.UserSAMLSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserSAMLSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_saml_source_connection.UserSAMLSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserSAMLSourceConnectionList(self): + """Test PaginatedUserSAMLSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_source_connection_list.py b/test/test_paginated_user_source_connection_list.py new file mode 100644 index 000000000..eb1d4823c --- /dev/null +++ b/test/test_paginated_user_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_source_connection_list import PaginatedUserSourceConnectionList + +class TestPaginatedUserSourceConnectionList(unittest.TestCase): + """PaginatedUserSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserSourceConnectionList: + """Test PaginatedUserSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserSourceConnectionList` + """ + model = PaginatedUserSourceConnectionList() + if include_optional: + return PaginatedUserSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_source_connection.UserSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_source_connection.UserSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserSourceConnectionList(self): + """Test PaginatedUserSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_telegram_source_connection_list.py b/test/test_paginated_user_telegram_source_connection_list.py new file mode 100644 index 000000000..e178cac83 --- /dev/null +++ b/test/test_paginated_user_telegram_source_connection_list.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_telegram_source_connection_list import PaginatedUserTelegramSourceConnectionList + +class TestPaginatedUserTelegramSourceConnectionList(unittest.TestCase): + """PaginatedUserTelegramSourceConnectionList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserTelegramSourceConnectionList: + """Test PaginatedUserTelegramSourceConnectionList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserTelegramSourceConnectionList` + """ + model = PaginatedUserTelegramSourceConnectionList() + if include_optional: + return PaginatedUserTelegramSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_telegram_source_connection.UserTelegramSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserTelegramSourceConnectionList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_telegram_source_connection.UserTelegramSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = null, + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserTelegramSourceConnectionList(self): + """Test PaginatedUserTelegramSourceConnectionList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_user_write_stage_list.py b/test/test_paginated_user_write_stage_list.py new file mode 100644 index 000000000..a79149b63 --- /dev/null +++ b/test/test_paginated_user_write_stage_list.py @@ -0,0 +1,131 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_user_write_stage_list import PaginatedUserWriteStageList + +class TestPaginatedUserWriteStageList(unittest.TestCase): + """PaginatedUserWriteStageList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedUserWriteStageList: + """Test PaginatedUserWriteStageList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedUserWriteStageList` + """ + model = PaginatedUserWriteStageList() + if include_optional: + return PaginatedUserWriteStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_write_stage.UserWriteStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + user_creation_mode = 'never_create', + create_users_as_inactive = True, + create_users_group = '', + user_type = 'internal', + user_path_template = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedUserWriteStageList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.user_write_stage.UserWriteStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + user_creation_mode = 'never_create', + create_users_as_inactive = True, + create_users_group = '', + user_type = 'internal', + user_path_template = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedUserWriteStageList(self): + """Test PaginatedUserWriteStageList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_web_authn_device_list.py b/test/test_paginated_web_authn_device_list.py new file mode 100644 index 000000000..6d1dd92e4 --- /dev/null +++ b/test/test_paginated_web_authn_device_list.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_web_authn_device_list import PaginatedWebAuthnDeviceList + +class TestPaginatedWebAuthnDeviceList(unittest.TestCase): + """PaginatedWebAuthnDeviceList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedWebAuthnDeviceList: + """Test PaginatedWebAuthnDeviceList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedWebAuthnDeviceList` + """ + model = PaginatedWebAuthnDeviceList() + if include_optional: + return PaginatedWebAuthnDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.web_authn_device.WebAuthnDevice( + pk = 56, + name = '', + created_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + device_type = null, + aaguid = '', + user = null, ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedWebAuthnDeviceList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.web_authn_device.WebAuthnDevice( + pk = 56, + name = '', + created_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + device_type = null, + aaguid = '', + user = null, ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedWebAuthnDeviceList(self): + """Test PaginatedWebAuthnDeviceList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_web_authn_device_type_list.py b/test/test_paginated_web_authn_device_type_list.py new file mode 100644 index 000000000..de061237e --- /dev/null +++ b/test/test_paginated_web_authn_device_type_list.py @@ -0,0 +1,83 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_web_authn_device_type_list import PaginatedWebAuthnDeviceTypeList + +class TestPaginatedWebAuthnDeviceTypeList(unittest.TestCase): + """PaginatedWebAuthnDeviceTypeList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedWebAuthnDeviceTypeList: + """Test PaginatedWebAuthnDeviceTypeList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedWebAuthnDeviceTypeList` + """ + model = PaginatedWebAuthnDeviceTypeList() + if include_optional: + return PaginatedWebAuthnDeviceTypeList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedWebAuthnDeviceTypeList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedWebAuthnDeviceTypeList(self): + """Test PaginatedWebAuthnDeviceTypeList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_paginated_ws_federation_provider_list.py b/test/test_paginated_ws_federation_provider_list.py new file mode 100644 index 000000000..8a7065eb1 --- /dev/null +++ b/test/test_paginated_ws_federation_provider_list.py @@ -0,0 +1,143 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.paginated_ws_federation_provider_list import PaginatedWSFederationProviderList + +class TestPaginatedWSFederationProviderList(unittest.TestCase): + """PaginatedWSFederationProviderList unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PaginatedWSFederationProviderList: + """Test PaginatedWSFederationProviderList + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PaginatedWSFederationProviderList` + """ + model = PaginatedWSFederationProviderList() + if include_optional: + return PaginatedWSFederationProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ws_federation_provider.WSFederationProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + reply_url = '', + wtrealm = '', + assertion_valid_not_before = '', + assertion_valid_not_on_or_after = '', + session_valid_not_on_or_after = '', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_logout_request = True, + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + url_download_metadata = '', + url_wsfed = '', ) + ], + autocomplete = { + 'key' : null + } + ) + else: + return PaginatedWSFederationProviderList( + pagination = authentik_client.models.pagination.Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, ), + results = [ + authentik_client.models.ws_federation_provider.WSFederationProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + reply_url = '', + wtrealm = '', + assertion_valid_not_before = '', + assertion_valid_not_on_or_after = '', + session_valid_not_on_or_after = '', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_logout_request = True, + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + url_download_metadata = '', + url_wsfed = '', ) + ], + autocomplete = { + 'key' : null + }, + ) + """ + + def testPaginatedWSFederationProviderList(self): + """Test PaginatedWSFederationProviderList""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_pagination.py b/test/test_pagination.py new file mode 100644 index 000000000..fb7ab69d8 --- /dev/null +++ b/test/test_pagination.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.pagination import Pagination + +class TestPagination(unittest.TestCase): + """Pagination unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Pagination: + """Test Pagination + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Pagination` + """ + model = Pagination() + if include_optional: + return Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337 + ) + else: + return Pagination( + next = 1.337, + previous = 1.337, + count = 1.337, + current = 1.337, + total_pages = 1.337, + start_index = 1.337, + end_index = 1.337, + ) + """ + + def testPagination(self): + """Test Pagination""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_partial_group.py b/test/test_partial_group.py new file mode 100644 index 000000000..21cd3db65 --- /dev/null +++ b/test/test_partial_group.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.partial_group import PartialGroup + +class TestPartialGroup(unittest.TestCase): + """PartialGroup unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PartialGroup: + """Test PartialGroup + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PartialGroup` + """ + model = PartialGroup() + if include_optional: + return PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + } + ) + else: + return PartialGroup( + pk = '', + num_pk = 56, + name = '', + ) + """ + + def testPartialGroup(self): + """Test PartialGroup""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_partial_user.py b/test/test_partial_user.py new file mode 100644 index 000000000..86edc8a53 --- /dev/null +++ b/test/test_partial_user.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.partial_user import PartialUser + +class TestPartialUser(unittest.TestCase): + """PartialUser unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PartialUser: + """Test PartialUser + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PartialUser` + """ + model = PartialUser() + if include_optional: + return PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '' + ) + else: + return PartialUser( + pk = 56, + username = 'A', + name = '', + uid = '', + ) + """ + + def testPartialUser(self): + """Test PartialUser""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_password_challenge.py b/test/test_password_challenge.py new file mode 100644 index 000000000..4b5cd795f --- /dev/null +++ b/test/test_password_challenge.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.password_challenge import PasswordChallenge + +class TestPasswordChallenge(unittest.TestCase): + """PasswordChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordChallenge: + """Test PasswordChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordChallenge` + """ + model = PasswordChallenge() + if include_optional: + return PasswordChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-password', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + recovery_url = '', + allow_show_password = True + ) + else: + return PasswordChallenge( + pending_user = '', + pending_user_avatar = '', + ) + """ + + def testPasswordChallenge(self): + """Test PasswordChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_password_challenge_response_request.py b/test/test_password_challenge_response_request.py new file mode 100644 index 000000000..7f87e24b5 --- /dev/null +++ b/test/test_password_challenge_response_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.password_challenge_response_request import PasswordChallengeResponseRequest + +class TestPasswordChallengeResponseRequest(unittest.TestCase): + """PasswordChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordChallengeResponseRequest: + """Test PasswordChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordChallengeResponseRequest` + """ + model = PasswordChallengeResponseRequest() + if include_optional: + return PasswordChallengeResponseRequest( + component = 'ak-stage-password', + password = '0' + ) + else: + return PasswordChallengeResponseRequest( + password = '0', + ) + """ + + def testPasswordChallengeResponseRequest(self): + """Test PasswordChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_password_expiry_policy.py b/test/test_password_expiry_policy.py new file mode 100644 index 000000000..dde9fa93d --- /dev/null +++ b/test/test_password_expiry_policy.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.password_expiry_policy import PasswordExpiryPolicy + +class TestPasswordExpiryPolicy(unittest.TestCase): + """PasswordExpiryPolicy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordExpiryPolicy: + """Test PasswordExpiryPolicy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordExpiryPolicy` + """ + model = PasswordExpiryPolicy() + if include_optional: + return PasswordExpiryPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + days = -2147483648, + deny_only = True + ) + else: + return PasswordExpiryPolicy( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + days = -2147483648, + ) + """ + + def testPasswordExpiryPolicy(self): + """Test PasswordExpiryPolicy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_password_expiry_policy_request.py b/test/test_password_expiry_policy_request.py new file mode 100644 index 000000000..936fdda91 --- /dev/null +++ b/test/test_password_expiry_policy_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.password_expiry_policy_request import PasswordExpiryPolicyRequest + +class TestPasswordExpiryPolicyRequest(unittest.TestCase): + """PasswordExpiryPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordExpiryPolicyRequest: + """Test PasswordExpiryPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordExpiryPolicyRequest` + """ + model = PasswordExpiryPolicyRequest() + if include_optional: + return PasswordExpiryPolicyRequest( + name = '0', + execution_logging = True, + days = -2147483648, + deny_only = True + ) + else: + return PasswordExpiryPolicyRequest( + name = '0', + days = -2147483648, + ) + """ + + def testPasswordExpiryPolicyRequest(self): + """Test PasswordExpiryPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_password_policy.py b/test/test_password_policy.py new file mode 100644 index 000000000..0319a1282 --- /dev/null +++ b/test/test_password_policy.py @@ -0,0 +1,79 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.password_policy import PasswordPolicy + +class TestPasswordPolicy(unittest.TestCase): + """PasswordPolicy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordPolicy: + """Test PasswordPolicy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordPolicy` + """ + model = PasswordPolicy() + if include_optional: + return PasswordPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + password_field = '', + amount_digits = 0, + amount_uppercase = 0, + amount_lowercase = 0, + amount_symbols = 0, + length_min = 0, + symbol_charset = '', + error_message = '', + check_static_rules = True, + check_have_i_been_pwned = True, + check_zxcvbn = True, + hibp_allowed_count = 0, + zxcvbn_score_threshold = 0 + ) + else: + return PasswordPolicy( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + ) + """ + + def testPasswordPolicy(self): + """Test PasswordPolicy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_password_policy_request.py b/test/test_password_policy_request.py new file mode 100644 index 000000000..02ab27dc7 --- /dev/null +++ b/test/test_password_policy_request.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.password_policy_request import PasswordPolicyRequest + +class TestPasswordPolicyRequest(unittest.TestCase): + """PasswordPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordPolicyRequest: + """Test PasswordPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordPolicyRequest` + """ + model = PasswordPolicyRequest() + if include_optional: + return PasswordPolicyRequest( + name = '0', + execution_logging = True, + password_field = '0', + amount_digits = 0, + amount_uppercase = 0, + amount_lowercase = 0, + amount_symbols = 0, + length_min = 0, + symbol_charset = '0', + error_message = '', + check_static_rules = True, + check_have_i_been_pwned = True, + check_zxcvbn = True, + hibp_allowed_count = 0, + zxcvbn_score_threshold = 0 + ) + else: + return PasswordPolicyRequest( + name = '0', + ) + """ + + def testPasswordPolicyRequest(self): + """Test PasswordPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_password_stage.py b/test/test_password_stage.py new file mode 100644 index 000000000..1740f9903 --- /dev/null +++ b/test/test_password_stage.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.password_stage import PasswordStage + +class TestPasswordStage(unittest.TestCase): + """PasswordStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordStage: + """Test PasswordStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordStage` + """ + model = PasswordStage() + if include_optional: + return PasswordStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + backends = [ + 'authentik.core.auth.InbuiltBackend' + ], + configure_flow = '', + failed_attempts_before_cancel = -2147483648, + allow_show_password = True + ) + else: + return PasswordStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + backends = [ + 'authentik.core.auth.InbuiltBackend' + ], + ) + """ + + def testPasswordStage(self): + """Test PasswordStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_password_stage_request.py b/test/test_password_stage_request.py new file mode 100644 index 000000000..ce19578ab --- /dev/null +++ b/test/test_password_stage_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.password_stage_request import PasswordStageRequest + +class TestPasswordStageRequest(unittest.TestCase): + """PasswordStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PasswordStageRequest: + """Test PasswordStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PasswordStageRequest` + """ + model = PasswordStageRequest() + if include_optional: + return PasswordStageRequest( + name = '0', + backends = [ + 'authentik.core.auth.InbuiltBackend' + ], + configure_flow = '', + failed_attempts_before_cancel = -2147483648, + allow_show_password = True + ) + else: + return PasswordStageRequest( + name = '0', + backends = [ + 'authentik.core.auth.InbuiltBackend' + ], + ) + """ + + def testPasswordStageRequest(self): + """Test PasswordStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_account_lockdown_stage_request.py b/test/test_patched_account_lockdown_stage_request.py new file mode 100644 index 000000000..f9dc1e15d --- /dev/null +++ b/test/test_patched_account_lockdown_stage_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_account_lockdown_stage_request import PatchedAccountLockdownStageRequest + +class TestPatchedAccountLockdownStageRequest(unittest.TestCase): + """PatchedAccountLockdownStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAccountLockdownStageRequest: + """Test PatchedAccountLockdownStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAccountLockdownStageRequest` + """ + model = PatchedAccountLockdownStageRequest() + if include_optional: + return PatchedAccountLockdownStageRequest( + name = '0', + deactivate_user = True, + set_unusable_password = True, + delete_sessions = True, + revoke_tokens = True, + self_service_completion_flow = '' + ) + else: + return PatchedAccountLockdownStageRequest( + ) + """ + + def testPatchedAccountLockdownStageRequest(self): + """Test PatchedAccountLockdownStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_agent_connector_request.py b/test/test_patched_agent_connector_request.py new file mode 100644 index 000000000..d16f64e26 --- /dev/null +++ b/test/test_patched_agent_connector_request.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_agent_connector_request import PatchedAgentConnectorRequest + +class TestPatchedAgentConnectorRequest(unittest.TestCase): + """PatchedAgentConnectorRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAgentConnectorRequest: + """Test PatchedAgentConnectorRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAgentConnectorRequest` + """ + model = PatchedAgentConnectorRequest() + if include_optional: + return PatchedAgentConnectorRequest( + connector_uuid = '', + name = '0', + enabled = True, + snapshot_expiry = '0', + auth_session_duration = '0', + auth_terminate_session_on_expiry = True, + refresh_interval = '0', + authorization_flow = '', + nss_uid_offset = 0, + nss_gid_offset = 0, + challenge_key = '', + challenge_idle_timeout = '0', + challenge_trigger_check_in = True, + jwt_federation_providers = [ + 56 + ] + ) + else: + return PatchedAgentConnectorRequest( + ) + """ + + def testPatchedAgentConnectorRequest(self): + """Test PatchedAgentConnectorRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_apple_independent_secure_enclave_request.py b/test/test_patched_apple_independent_secure_enclave_request.py new file mode 100644 index 000000000..999814f3d --- /dev/null +++ b/test/test_patched_apple_independent_secure_enclave_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_apple_independent_secure_enclave_request import PatchedAppleIndependentSecureEnclaveRequest + +class TestPatchedAppleIndependentSecureEnclaveRequest(unittest.TestCase): + """PatchedAppleIndependentSecureEnclaveRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAppleIndependentSecureEnclaveRequest: + """Test PatchedAppleIndependentSecureEnclaveRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAppleIndependentSecureEnclaveRequest` + """ + model = PatchedAppleIndependentSecureEnclaveRequest() + if include_optional: + return PatchedAppleIndependentSecureEnclaveRequest( + uuid = '', + user = 56, + apple_secure_enclave_key = '0', + apple_enclave_key_id = '0', + device_type = '0' + ) + else: + return PatchedAppleIndependentSecureEnclaveRequest( + ) + """ + + def testPatchedAppleIndependentSecureEnclaveRequest(self): + """Test PatchedAppleIndependentSecureEnclaveRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_application_entitlement_request.py b/test/test_patched_application_entitlement_request.py new file mode 100644 index 000000000..8bff7c3cf --- /dev/null +++ b/test/test_patched_application_entitlement_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_application_entitlement_request import PatchedApplicationEntitlementRequest + +class TestPatchedApplicationEntitlementRequest(unittest.TestCase): + """PatchedApplicationEntitlementRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedApplicationEntitlementRequest: + """Test PatchedApplicationEntitlementRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedApplicationEntitlementRequest` + """ + model = PatchedApplicationEntitlementRequest() + if include_optional: + return PatchedApplicationEntitlementRequest( + name = '0', + app = '', + attributes = { + 'key' : null + } + ) + else: + return PatchedApplicationEntitlementRequest( + ) + """ + + def testPatchedApplicationEntitlementRequest(self): + """Test PatchedApplicationEntitlementRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_application_request.py b/test/test_patched_application_request.py new file mode 100644 index 000000000..adfafa47d --- /dev/null +++ b/test/test_patched_application_request.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_application_request import PatchedApplicationRequest + +class TestPatchedApplicationRequest(unittest.TestCase): + """PatchedApplicationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedApplicationRequest: + """Test PatchedApplicationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedApplicationRequest` + """ + model = PatchedApplicationRequest() + if include_optional: + return PatchedApplicationRequest( + name = '0', + slug = 'z0', + provider = 56, + backchannel_providers = [ + 56 + ], + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True + ) + else: + return PatchedApplicationRequest( + ) + """ + + def testPatchedApplicationRequest(self): + """Test PatchedApplicationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_authenticator_duo_stage_request.py b/test/test_patched_authenticator_duo_stage_request.py new file mode 100644 index 000000000..7398da0ac --- /dev/null +++ b/test/test_patched_authenticator_duo_stage_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_authenticator_duo_stage_request import PatchedAuthenticatorDuoStageRequest + +class TestPatchedAuthenticatorDuoStageRequest(unittest.TestCase): + """PatchedAuthenticatorDuoStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAuthenticatorDuoStageRequest: + """Test PatchedAuthenticatorDuoStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAuthenticatorDuoStageRequest` + """ + model = PatchedAuthenticatorDuoStageRequest() + if include_optional: + return PatchedAuthenticatorDuoStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + client_id = '0', + client_secret = '0', + api_hostname = '0', + admin_integration_key = '', + admin_secret_key = '' + ) + else: + return PatchedAuthenticatorDuoStageRequest( + ) + """ + + def testPatchedAuthenticatorDuoStageRequest(self): + """Test PatchedAuthenticatorDuoStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_authenticator_email_stage_request.py b/test/test_patched_authenticator_email_stage_request.py new file mode 100644 index 000000000..cee627647 --- /dev/null +++ b/test/test_patched_authenticator_email_stage_request.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_authenticator_email_stage_request import PatchedAuthenticatorEmailStageRequest + +class TestPatchedAuthenticatorEmailStageRequest(unittest.TestCase): + """PatchedAuthenticatorEmailStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAuthenticatorEmailStageRequest: + """Test PatchedAuthenticatorEmailStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAuthenticatorEmailStageRequest` + """ + model = PatchedAuthenticatorEmailStageRequest() + if include_optional: + return PatchedAuthenticatorEmailStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + use_global_settings = True, + host = '0', + port = -2147483648, + username = '', + password = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '0', + subject = '0', + token_expiry = '0', + template = '0' + ) + else: + return PatchedAuthenticatorEmailStageRequest( + ) + """ + + def testPatchedAuthenticatorEmailStageRequest(self): + """Test PatchedAuthenticatorEmailStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_authenticator_endpoint_gdtc_stage_request.py b/test/test_patched_authenticator_endpoint_gdtc_stage_request.py new file mode 100644 index 000000000..514c4cf29 --- /dev/null +++ b/test/test_patched_authenticator_endpoint_gdtc_stage_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_authenticator_endpoint_gdtc_stage_request import PatchedAuthenticatorEndpointGDTCStageRequest + +class TestPatchedAuthenticatorEndpointGDTCStageRequest(unittest.TestCase): + """PatchedAuthenticatorEndpointGDTCStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAuthenticatorEndpointGDTCStageRequest: + """Test PatchedAuthenticatorEndpointGDTCStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAuthenticatorEndpointGDTCStageRequest` + """ + model = PatchedAuthenticatorEndpointGDTCStageRequest() + if include_optional: + return PatchedAuthenticatorEndpointGDTCStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + credentials = { + 'key' : null + } + ) + else: + return PatchedAuthenticatorEndpointGDTCStageRequest( + ) + """ + + def testPatchedAuthenticatorEndpointGDTCStageRequest(self): + """Test PatchedAuthenticatorEndpointGDTCStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_authenticator_sms_stage_request.py b/test/test_patched_authenticator_sms_stage_request.py new file mode 100644 index 000000000..f3cbf5362 --- /dev/null +++ b/test/test_patched_authenticator_sms_stage_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_authenticator_sms_stage_request import PatchedAuthenticatorSMSStageRequest + +class TestPatchedAuthenticatorSMSStageRequest(unittest.TestCase): + """PatchedAuthenticatorSMSStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAuthenticatorSMSStageRequest: + """Test PatchedAuthenticatorSMSStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAuthenticatorSMSStageRequest` + """ + model = PatchedAuthenticatorSMSStageRequest() + if include_optional: + return PatchedAuthenticatorSMSStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + provider = 'twilio', + from_number = '0', + account_sid = '0', + auth = '0', + auth_password = '', + auth_type = 'basic', + verify_only = True, + mapping = '' + ) + else: + return PatchedAuthenticatorSMSStageRequest( + ) + """ + + def testPatchedAuthenticatorSMSStageRequest(self): + """Test PatchedAuthenticatorSMSStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_authenticator_static_stage_request.py b/test/test_patched_authenticator_static_stage_request.py new file mode 100644 index 000000000..e21145189 --- /dev/null +++ b/test/test_patched_authenticator_static_stage_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_authenticator_static_stage_request import PatchedAuthenticatorStaticStageRequest + +class TestPatchedAuthenticatorStaticStageRequest(unittest.TestCase): + """PatchedAuthenticatorStaticStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAuthenticatorStaticStageRequest: + """Test PatchedAuthenticatorStaticStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAuthenticatorStaticStageRequest` + """ + model = PatchedAuthenticatorStaticStageRequest() + if include_optional: + return PatchedAuthenticatorStaticStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + token_count = 0, + token_length = 0 + ) + else: + return PatchedAuthenticatorStaticStageRequest( + ) + """ + + def testPatchedAuthenticatorStaticStageRequest(self): + """Test PatchedAuthenticatorStaticStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_authenticator_totp_stage_request.py b/test/test_patched_authenticator_totp_stage_request.py new file mode 100644 index 000000000..8a7cad21b --- /dev/null +++ b/test/test_patched_authenticator_totp_stage_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_authenticator_totp_stage_request import PatchedAuthenticatorTOTPStageRequest + +class TestPatchedAuthenticatorTOTPStageRequest(unittest.TestCase): + """PatchedAuthenticatorTOTPStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAuthenticatorTOTPStageRequest: + """Test PatchedAuthenticatorTOTPStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAuthenticatorTOTPStageRequest` + """ + model = PatchedAuthenticatorTOTPStageRequest() + if include_optional: + return PatchedAuthenticatorTOTPStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + digits = '6' + ) + else: + return PatchedAuthenticatorTOTPStageRequest( + ) + """ + + def testPatchedAuthenticatorTOTPStageRequest(self): + """Test PatchedAuthenticatorTOTPStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_authenticator_validate_stage_request.py b/test/test_patched_authenticator_validate_stage_request.py new file mode 100644 index 000000000..9620cdfe2 --- /dev/null +++ b/test/test_patched_authenticator_validate_stage_request.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_authenticator_validate_stage_request import PatchedAuthenticatorValidateStageRequest + +class TestPatchedAuthenticatorValidateStageRequest(unittest.TestCase): + """PatchedAuthenticatorValidateStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAuthenticatorValidateStageRequest: + """Test PatchedAuthenticatorValidateStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAuthenticatorValidateStageRequest` + """ + model = PatchedAuthenticatorValidateStageRequest() + if include_optional: + return PatchedAuthenticatorValidateStageRequest( + name = '0', + not_configured_action = 'skip', + device_classes = [ + 'static' + ], + configuration_stages = [ + '' + ], + last_auth_threshold = '0', + webauthn_user_verification = 'required', + webauthn_hints = [ + 'security-key' + ], + webauthn_allowed_device_types = [ + '' + ], + email_otp_throttling_factor = 1.337, + sms_otp_throttling_factor = 1.337, + totp_otp_throttling_factor = 1.337, + static_otp_throttling_factor = 1.337 + ) + else: + return PatchedAuthenticatorValidateStageRequest( + ) + """ + + def testPatchedAuthenticatorValidateStageRequest(self): + """Test PatchedAuthenticatorValidateStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_authenticator_web_authn_stage_request.py b/test/test_patched_authenticator_web_authn_stage_request.py new file mode 100644 index 000000000..300a8ee5d --- /dev/null +++ b/test/test_patched_authenticator_web_authn_stage_request.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_authenticator_web_authn_stage_request import PatchedAuthenticatorWebAuthnStageRequest + +class TestPatchedAuthenticatorWebAuthnStageRequest(unittest.TestCase): + """PatchedAuthenticatorWebAuthnStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedAuthenticatorWebAuthnStageRequest: + """Test PatchedAuthenticatorWebAuthnStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedAuthenticatorWebAuthnStageRequest` + """ + model = PatchedAuthenticatorWebAuthnStageRequest() + if include_optional: + return PatchedAuthenticatorWebAuthnStageRequest( + name = '0', + configure_flow = '', + friendly_name = '', + user_verification = 'required', + authenticator_attachment = 'platform', + resident_key_requirement = 'required', + hints = [ + 'security-key' + ], + device_type_restrictions = [ + '' + ], + prevent_duplicate_devices = True, + max_attempts = 0 + ) + else: + return PatchedAuthenticatorWebAuthnStageRequest( + ) + """ + + def testPatchedAuthenticatorWebAuthnStageRequest(self): + """Test PatchedAuthenticatorWebAuthnStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_blueprint_instance_request.py b/test/test_patched_blueprint_instance_request.py new file mode 100644 index 000000000..69fb1c26e --- /dev/null +++ b/test/test_patched_blueprint_instance_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_blueprint_instance_request import PatchedBlueprintInstanceRequest + +class TestPatchedBlueprintInstanceRequest(unittest.TestCase): + """PatchedBlueprintInstanceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedBlueprintInstanceRequest: + """Test PatchedBlueprintInstanceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedBlueprintInstanceRequest` + """ + model = PatchedBlueprintInstanceRequest() + if include_optional: + return PatchedBlueprintInstanceRequest( + name = '0', + path = '', + context = { + 'key' : null + }, + enabled = True, + content = '' + ) + else: + return PatchedBlueprintInstanceRequest( + ) + """ + + def testPatchedBlueprintInstanceRequest(self): + """Test PatchedBlueprintInstanceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_brand_request.py b/test/test_patched_brand_request.py new file mode 100644 index 000000000..c71ea9a36 --- /dev/null +++ b/test/test_patched_brand_request.py @@ -0,0 +1,73 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_brand_request import PatchedBrandRequest + +class TestPatchedBrandRequest(unittest.TestCase): + """PatchedBrandRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedBrandRequest: + """Test PatchedBrandRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedBrandRequest` + """ + model = PatchedBrandRequest() + if include_optional: + return PatchedBrandRequest( + domain = '0', + default = True, + branding_title = '0', + branding_logo = '0', + branding_favicon = '0', + branding_custom_css = '', + branding_default_flow_background = '0', + flow_authentication = '', + flow_invalidation = '', + flow_recovery = '', + flow_unenrollment = '', + flow_user_settings = '', + flow_device_code = '', + flow_lockdown = '', + default_application = '', + web_certificate = '', + client_certificates = [ + '' + ], + attributes = { + 'key' : null + } + ) + else: + return PatchedBrandRequest( + ) + """ + + def testPatchedBrandRequest(self): + """Test PatchedBrandRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_captcha_stage_request.py b/test/test_patched_captcha_stage_request.py new file mode 100644 index 000000000..6a7c3a205 --- /dev/null +++ b/test/test_patched_captcha_stage_request.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_captcha_stage_request import PatchedCaptchaStageRequest + +class TestPatchedCaptchaStageRequest(unittest.TestCase): + """PatchedCaptchaStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedCaptchaStageRequest: + """Test PatchedCaptchaStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedCaptchaStageRequest` + """ + model = PatchedCaptchaStageRequest() + if include_optional: + return PatchedCaptchaStageRequest( + name = '0', + public_key = '0', + private_key = '0', + js_url = '0', + api_url = '0', + interactive = True, + score_min_threshold = 1.337, + score_max_threshold = 1.337, + error_on_invalid_score = True + ) + else: + return PatchedCaptchaStageRequest( + ) + """ + + def testPatchedCaptchaStageRequest(self): + """Test PatchedCaptchaStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_certificate_key_pair_request.py b/test/test_patched_certificate_key_pair_request.py new file mode 100644 index 000000000..87ff5560a --- /dev/null +++ b/test/test_patched_certificate_key_pair_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_certificate_key_pair_request import PatchedCertificateKeyPairRequest + +class TestPatchedCertificateKeyPairRequest(unittest.TestCase): + """PatchedCertificateKeyPairRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedCertificateKeyPairRequest: + """Test PatchedCertificateKeyPairRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedCertificateKeyPairRequest` + """ + model = PatchedCertificateKeyPairRequest() + if include_optional: + return PatchedCertificateKeyPairRequest( + name = '0', + certificate_data = '0', + key_data = '' + ) + else: + return PatchedCertificateKeyPairRequest( + ) + """ + + def testPatchedCertificateKeyPairRequest(self): + """Test PatchedCertificateKeyPairRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_connection_token_request.py b/test/test_patched_connection_token_request.py new file mode 100644 index 000000000..ea9141132 --- /dev/null +++ b/test/test_patched_connection_token_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_connection_token_request import PatchedConnectionTokenRequest + +class TestPatchedConnectionTokenRequest(unittest.TestCase): + """PatchedConnectionTokenRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedConnectionTokenRequest: + """Test PatchedConnectionTokenRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedConnectionTokenRequest` + """ + model = PatchedConnectionTokenRequest() + if include_optional: + return PatchedConnectionTokenRequest( + pk = '', + provider = 56, + endpoint = '' + ) + else: + return PatchedConnectionTokenRequest( + ) + """ + + def testPatchedConnectionTokenRequest(self): + """Test PatchedConnectionTokenRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_consent_stage_request.py b/test/test_patched_consent_stage_request.py new file mode 100644 index 000000000..8183230ec --- /dev/null +++ b/test/test_patched_consent_stage_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_consent_stage_request import PatchedConsentStageRequest + +class TestPatchedConsentStageRequest(unittest.TestCase): + """PatchedConsentStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedConsentStageRequest: + """Test PatchedConsentStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedConsentStageRequest` + """ + model = PatchedConsentStageRequest() + if include_optional: + return PatchedConsentStageRequest( + name = '0', + mode = 'always_require', + consent_expire_in = '0' + ) + else: + return PatchedConsentStageRequest( + ) + """ + + def testPatchedConsentStageRequest(self): + """Test PatchedConsentStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_deny_stage_request.py b/test/test_patched_deny_stage_request.py new file mode 100644 index 000000000..94da13686 --- /dev/null +++ b/test/test_patched_deny_stage_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_deny_stage_request import PatchedDenyStageRequest + +class TestPatchedDenyStageRequest(unittest.TestCase): + """PatchedDenyStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedDenyStageRequest: + """Test PatchedDenyStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedDenyStageRequest` + """ + model = PatchedDenyStageRequest() + if include_optional: + return PatchedDenyStageRequest( + name = '0', + deny_message = '' + ) + else: + return PatchedDenyStageRequest( + ) + """ + + def testPatchedDenyStageRequest(self): + """Test PatchedDenyStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_device_access_group_request.py b/test/test_patched_device_access_group_request.py new file mode 100644 index 000000000..d97620196 --- /dev/null +++ b/test/test_patched_device_access_group_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_device_access_group_request import PatchedDeviceAccessGroupRequest + +class TestPatchedDeviceAccessGroupRequest(unittest.TestCase): + """PatchedDeviceAccessGroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedDeviceAccessGroupRequest: + """Test PatchedDeviceAccessGroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedDeviceAccessGroupRequest` + """ + model = PatchedDeviceAccessGroupRequest() + if include_optional: + return PatchedDeviceAccessGroupRequest( + name = '0', + attributes = { + 'key' : null + } + ) + else: + return PatchedDeviceAccessGroupRequest( + ) + """ + + def testPatchedDeviceAccessGroupRequest(self): + """Test PatchedDeviceAccessGroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_device_user_binding_request.py b/test/test_patched_device_user_binding_request.py new file mode 100644 index 000000000..ba5a69c7b --- /dev/null +++ b/test/test_patched_device_user_binding_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_device_user_binding_request import PatchedDeviceUserBindingRequest + +class TestPatchedDeviceUserBindingRequest(unittest.TestCase): + """PatchedDeviceUserBindingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedDeviceUserBindingRequest: + """Test PatchedDeviceUserBindingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedDeviceUserBindingRequest` + """ + model = PatchedDeviceUserBindingRequest() + if include_optional: + return PatchedDeviceUserBindingRequest( + policy = '', + group = '', + user = 56, + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True, + is_primary = True + ) + else: + return PatchedDeviceUserBindingRequest( + ) + """ + + def testPatchedDeviceUserBindingRequest(self): + """Test PatchedDeviceUserBindingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_docker_service_connection_request.py b/test/test_patched_docker_service_connection_request.py new file mode 100644 index 000000000..3d9b2f4ec --- /dev/null +++ b/test/test_patched_docker_service_connection_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_docker_service_connection_request import PatchedDockerServiceConnectionRequest + +class TestPatchedDockerServiceConnectionRequest(unittest.TestCase): + """PatchedDockerServiceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedDockerServiceConnectionRequest: + """Test PatchedDockerServiceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedDockerServiceConnectionRequest` + """ + model = PatchedDockerServiceConnectionRequest() + if include_optional: + return PatchedDockerServiceConnectionRequest( + name = '0', + local = True, + url = '0', + tls_verification = '', + tls_authentication = '' + ) + else: + return PatchedDockerServiceConnectionRequest( + ) + """ + + def testPatchedDockerServiceConnectionRequest(self): + """Test PatchedDockerServiceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_domain_request.py b/test/test_patched_domain_request.py new file mode 100644 index 000000000..fda3af4a2 --- /dev/null +++ b/test/test_patched_domain_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_domain_request import PatchedDomainRequest + +class TestPatchedDomainRequest(unittest.TestCase): + """PatchedDomainRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedDomainRequest: + """Test PatchedDomainRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedDomainRequest` + """ + model = PatchedDomainRequest() + if include_optional: + return PatchedDomainRequest( + domain = '0', + is_primary = True, + tenant = '' + ) + else: + return PatchedDomainRequest( + ) + """ + + def testPatchedDomainRequest(self): + """Test PatchedDomainRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_dummy_policy_request.py b/test/test_patched_dummy_policy_request.py new file mode 100644 index 000000000..be9f54a97 --- /dev/null +++ b/test/test_patched_dummy_policy_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_dummy_policy_request import PatchedDummyPolicyRequest + +class TestPatchedDummyPolicyRequest(unittest.TestCase): + """PatchedDummyPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedDummyPolicyRequest: + """Test PatchedDummyPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedDummyPolicyRequest` + """ + model = PatchedDummyPolicyRequest() + if include_optional: + return PatchedDummyPolicyRequest( + name = '0', + execution_logging = True, + result = True, + wait_min = -2147483648, + wait_max = -2147483648 + ) + else: + return PatchedDummyPolicyRequest( + ) + """ + + def testPatchedDummyPolicyRequest(self): + """Test PatchedDummyPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_dummy_stage_request.py b/test/test_patched_dummy_stage_request.py new file mode 100644 index 000000000..9b282973b --- /dev/null +++ b/test/test_patched_dummy_stage_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_dummy_stage_request import PatchedDummyStageRequest + +class TestPatchedDummyStageRequest(unittest.TestCase): + """PatchedDummyStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedDummyStageRequest: + """Test PatchedDummyStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedDummyStageRequest` + """ + model = PatchedDummyStageRequest() + if include_optional: + return PatchedDummyStageRequest( + name = '0', + throw_error = True + ) + else: + return PatchedDummyStageRequest( + ) + """ + + def testPatchedDummyStageRequest(self): + """Test PatchedDummyStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_duo_device_request.py b/test/test_patched_duo_device_request.py new file mode 100644 index 000000000..a1e75792a --- /dev/null +++ b/test/test_patched_duo_device_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_duo_device_request import PatchedDuoDeviceRequest + +class TestPatchedDuoDeviceRequest(unittest.TestCase): + """PatchedDuoDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedDuoDeviceRequest: + """Test PatchedDuoDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedDuoDeviceRequest` + """ + model = PatchedDuoDeviceRequest() + if include_optional: + return PatchedDuoDeviceRequest( + name = '0' + ) + else: + return PatchedDuoDeviceRequest( + ) + """ + + def testPatchedDuoDeviceRequest(self): + """Test PatchedDuoDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_email_device_request.py b/test/test_patched_email_device_request.py new file mode 100644 index 000000000..24639bb40 --- /dev/null +++ b/test/test_patched_email_device_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_email_device_request import PatchedEmailDeviceRequest + +class TestPatchedEmailDeviceRequest(unittest.TestCase): + """PatchedEmailDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedEmailDeviceRequest: + """Test PatchedEmailDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedEmailDeviceRequest` + """ + model = PatchedEmailDeviceRequest() + if include_optional: + return PatchedEmailDeviceRequest( + name = '0' + ) + else: + return PatchedEmailDeviceRequest( + ) + """ + + def testPatchedEmailDeviceRequest(self): + """Test PatchedEmailDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_email_stage_request.py b/test/test_patched_email_stage_request.py new file mode 100644 index 000000000..01a9e1825 --- /dev/null +++ b/test/test_patched_email_stage_request.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_email_stage_request import PatchedEmailStageRequest + +class TestPatchedEmailStageRequest(unittest.TestCase): + """PatchedEmailStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedEmailStageRequest: + """Test PatchedEmailStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedEmailStageRequest` + """ + model = PatchedEmailStageRequest() + if include_optional: + return PatchedEmailStageRequest( + name = '0', + use_global_settings = True, + host = '0', + port = -2147483648, + username = '', + password = '', + use_tls = True, + use_ssl = True, + timeout = -2147483648, + from_address = '0', + token_expiry = '0', + subject = '0', + template = '0', + activate_user_on_success = True, + recovery_max_attempts = 0, + recovery_cache_timeout = '0' + ) + else: + return PatchedEmailStageRequest( + ) + """ + + def testPatchedEmailStageRequest(self): + """Test PatchedEmailStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_endpoint_device_request.py b/test/test_patched_endpoint_device_request.py new file mode 100644 index 000000000..b9b39841e --- /dev/null +++ b/test/test_patched_endpoint_device_request.py @@ -0,0 +1,64 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_endpoint_device_request import PatchedEndpointDeviceRequest + +class TestPatchedEndpointDeviceRequest(unittest.TestCase): + """PatchedEndpointDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedEndpointDeviceRequest: + """Test PatchedEndpointDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedEndpointDeviceRequest` + """ + model = PatchedEndpointDeviceRequest() + if include_optional: + return PatchedEndpointDeviceRequest( + device_uuid = '', + name = '0', + access_group = '', + access_group_obj = authentik_client.models.device_access_group_request.DeviceAccessGroupRequest( + name = '0', + attributes = { + 'key' : null + }, ), + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + attributes = { + 'key' : null + } + ) + else: + return PatchedEndpointDeviceRequest( + ) + """ + + def testPatchedEndpointDeviceRequest(self): + """Test PatchedEndpointDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_endpoint_request.py b/test/test_patched_endpoint_request.py new file mode 100644 index 000000000..99246f38e --- /dev/null +++ b/test/test_patched_endpoint_request.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_endpoint_request import PatchedEndpointRequest + +class TestPatchedEndpointRequest(unittest.TestCase): + """PatchedEndpointRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedEndpointRequest: + """Test PatchedEndpointRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedEndpointRequest` + """ + model = PatchedEndpointRequest() + if include_optional: + return PatchedEndpointRequest( + name = '0', + provider = 56, + protocol = 'rdp', + host = '0', + settings = { + 'key' : null + }, + property_mappings = [ + '' + ], + auth_mode = 'static', + maximum_connections = -2147483648 + ) + else: + return PatchedEndpointRequest( + ) + """ + + def testPatchedEndpointRequest(self): + """Test PatchedEndpointRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_endpoint_stage_request.py b/test/test_patched_endpoint_stage_request.py new file mode 100644 index 000000000..9178892ec --- /dev/null +++ b/test/test_patched_endpoint_stage_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_endpoint_stage_request import PatchedEndpointStageRequest + +class TestPatchedEndpointStageRequest(unittest.TestCase): + """PatchedEndpointStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedEndpointStageRequest: + """Test PatchedEndpointStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedEndpointStageRequest` + """ + model = PatchedEndpointStageRequest() + if include_optional: + return PatchedEndpointStageRequest( + name = '0', + connector = '', + mode = 'optional' + ) + else: + return PatchedEndpointStageRequest( + ) + """ + + def testPatchedEndpointStageRequest(self): + """Test PatchedEndpointStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_enrollment_token_request.py b/test/test_patched_enrollment_token_request.py new file mode 100644 index 000000000..bd9094181 --- /dev/null +++ b/test/test_patched_enrollment_token_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_enrollment_token_request import PatchedEnrollmentTokenRequest + +class TestPatchedEnrollmentTokenRequest(unittest.TestCase): + """PatchedEnrollmentTokenRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedEnrollmentTokenRequest: + """Test PatchedEnrollmentTokenRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedEnrollmentTokenRequest` + """ + model = PatchedEnrollmentTokenRequest() + if include_optional: + return PatchedEnrollmentTokenRequest( + device_group = '', + connector = '', + name = '0', + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return PatchedEnrollmentTokenRequest( + ) + """ + + def testPatchedEnrollmentTokenRequest(self): + """Test PatchedEnrollmentTokenRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_event_matcher_policy_request.py b/test/test_patched_event_matcher_policy_request.py new file mode 100644 index 000000000..fbb8d6730 --- /dev/null +++ b/test/test_patched_event_matcher_policy_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_event_matcher_policy_request import PatchedEventMatcherPolicyRequest + +class TestPatchedEventMatcherPolicyRequest(unittest.TestCase): + """PatchedEventMatcherPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedEventMatcherPolicyRequest: + """Test PatchedEventMatcherPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedEventMatcherPolicyRequest` + """ + model = PatchedEventMatcherPolicyRequest() + if include_optional: + return PatchedEventMatcherPolicyRequest( + name = '0', + execution_logging = True, + action = 'login', + client_ip = '0', + app = 'authentik.commands', + model = 'authentik_tenants.domain', + query = '0' + ) + else: + return PatchedEventMatcherPolicyRequest( + ) + """ + + def testPatchedEventMatcherPolicyRequest(self): + """Test PatchedEventMatcherPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_event_request.py b/test/test_patched_event_request.py new file mode 100644 index 000000000..e4e9e88b0 --- /dev/null +++ b/test/test_patched_event_request.py @@ -0,0 +1,64 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_event_request import PatchedEventRequest + +class TestPatchedEventRequest(unittest.TestCase): + """PatchedEventRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedEventRequest: + """Test PatchedEventRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedEventRequest` + """ + model = PatchedEventRequest() + if include_optional: + return PatchedEventRequest( + user = { + 'key' : null + }, + action = 'login', + app = '0', + context = { + 'key' : null + }, + client_ip = '0', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + } + ) + else: + return PatchedEventRequest( + ) + """ + + def testPatchedEventRequest(self): + """Test PatchedEventRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_expression_policy_request.py b/test/test_patched_expression_policy_request.py new file mode 100644 index 000000000..f2f6c0bba --- /dev/null +++ b/test/test_patched_expression_policy_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_expression_policy_request import PatchedExpressionPolicyRequest + +class TestPatchedExpressionPolicyRequest(unittest.TestCase): + """PatchedExpressionPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedExpressionPolicyRequest: + """Test PatchedExpressionPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedExpressionPolicyRequest` + """ + model = PatchedExpressionPolicyRequest() + if include_optional: + return PatchedExpressionPolicyRequest( + name = '0', + execution_logging = True, + expression = '0' + ) + else: + return PatchedExpressionPolicyRequest( + ) + """ + + def testPatchedExpressionPolicyRequest(self): + """Test PatchedExpressionPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_fleet_connector_request.py b/test/test_patched_fleet_connector_request.py new file mode 100644 index 000000000..6d664430b --- /dev/null +++ b/test/test_patched_fleet_connector_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_fleet_connector_request import PatchedFleetConnectorRequest + +class TestPatchedFleetConnectorRequest(unittest.TestCase): + """PatchedFleetConnectorRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedFleetConnectorRequest: + """Test PatchedFleetConnectorRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedFleetConnectorRequest` + """ + model = PatchedFleetConnectorRequest() + if include_optional: + return PatchedFleetConnectorRequest( + connector_uuid = '', + name = '0', + enabled = True, + url = '0', + token = '0', + headers_mapping = '', + map_users = True, + map_teams_access_group = True + ) + else: + return PatchedFleetConnectorRequest( + ) + """ + + def testPatchedFleetConnectorRequest(self): + """Test PatchedFleetConnectorRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_flow_request.py b/test/test_patched_flow_request.py new file mode 100644 index 000000000..62f55a637 --- /dev/null +++ b/test/test_patched_flow_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_flow_request import PatchedFlowRequest + +class TestPatchedFlowRequest(unittest.TestCase): + """PatchedFlowRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedFlowRequest: + """Test PatchedFlowRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedFlowRequest` + """ + model = PatchedFlowRequest() + if include_optional: + return PatchedFlowRequest( + name = '0', + slug = 'z0', + title = '0', + designation = 'authentication', + background = '', + policy_engine_mode = 'all', + compatibility_mode = True, + layout = 'stacked', + denied_action = 'message_continue', + authentication = 'none' + ) + else: + return PatchedFlowRequest( + ) + """ + + def testPatchedFlowRequest(self): + """Test PatchedFlowRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_flow_stage_binding_request.py b/test/test_patched_flow_stage_binding_request.py new file mode 100644 index 000000000..4c3fc36cd --- /dev/null +++ b/test/test_patched_flow_stage_binding_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_flow_stage_binding_request import PatchedFlowStageBindingRequest + +class TestPatchedFlowStageBindingRequest(unittest.TestCase): + """PatchedFlowStageBindingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedFlowStageBindingRequest: + """Test PatchedFlowStageBindingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedFlowStageBindingRequest` + """ + model = PatchedFlowStageBindingRequest() + if include_optional: + return PatchedFlowStageBindingRequest( + target = '', + stage = '', + evaluate_on_plan = True, + re_evaluate_policies = True, + order = -2147483648, + policy_engine_mode = 'all', + invalid_response_action = 'retry' + ) + else: + return PatchedFlowStageBindingRequest( + ) + """ + + def testPatchedFlowStageBindingRequest(self): + """Test PatchedFlowStageBindingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_geo_ip_policy_request.py b/test/test_patched_geo_ip_policy_request.py new file mode 100644 index 000000000..19bd26775 --- /dev/null +++ b/test/test_patched_geo_ip_policy_request.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_geo_ip_policy_request import PatchedGeoIPPolicyRequest + +class TestPatchedGeoIPPolicyRequest(unittest.TestCase): + """PatchedGeoIPPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGeoIPPolicyRequest: + """Test PatchedGeoIPPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGeoIPPolicyRequest` + """ + model = PatchedGeoIPPolicyRequest() + if include_optional: + return PatchedGeoIPPolicyRequest( + name = '0', + execution_logging = True, + asns = [ + -2147483648 + ], + countries = [ + 'AF' + ], + check_history_distance = True, + history_max_distance_km = 0, + distance_tolerance_km = 0, + history_login_count = 0, + check_impossible_travel = True, + impossible_tolerance_km = 0 + ) + else: + return PatchedGeoIPPolicyRequest( + ) + """ + + def testPatchedGeoIPPolicyRequest(self): + """Test PatchedGeoIPPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_google_chrome_connector_request.py b/test/test_patched_google_chrome_connector_request.py new file mode 100644 index 000000000..4ff1686ed --- /dev/null +++ b/test/test_patched_google_chrome_connector_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_google_chrome_connector_request import PatchedGoogleChromeConnectorRequest + +class TestPatchedGoogleChromeConnectorRequest(unittest.TestCase): + """PatchedGoogleChromeConnectorRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGoogleChromeConnectorRequest: + """Test PatchedGoogleChromeConnectorRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGoogleChromeConnectorRequest` + """ + model = PatchedGoogleChromeConnectorRequest() + if include_optional: + return PatchedGoogleChromeConnectorRequest( + connector_uuid = '', + name = '0', + enabled = True, + credentials = { + 'key' : null + } + ) + else: + return PatchedGoogleChromeConnectorRequest( + ) + """ + + def testPatchedGoogleChromeConnectorRequest(self): + """Test PatchedGoogleChromeConnectorRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_google_endpoint_device_request.py b/test/test_patched_google_endpoint_device_request.py new file mode 100644 index 000000000..964103867 --- /dev/null +++ b/test/test_patched_google_endpoint_device_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_google_endpoint_device_request import PatchedGoogleEndpointDeviceRequest + +class TestPatchedGoogleEndpointDeviceRequest(unittest.TestCase): + """PatchedGoogleEndpointDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGoogleEndpointDeviceRequest: + """Test PatchedGoogleEndpointDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGoogleEndpointDeviceRequest` + """ + model = PatchedGoogleEndpointDeviceRequest() + if include_optional: + return PatchedGoogleEndpointDeviceRequest( + pk = '', + name = '0' + ) + else: + return PatchedGoogleEndpointDeviceRequest( + ) + """ + + def testPatchedGoogleEndpointDeviceRequest(self): + """Test PatchedGoogleEndpointDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_google_workspace_provider_mapping_request.py b/test/test_patched_google_workspace_provider_mapping_request.py new file mode 100644 index 000000000..f792d5b94 --- /dev/null +++ b/test/test_patched_google_workspace_provider_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_google_workspace_provider_mapping_request import PatchedGoogleWorkspaceProviderMappingRequest + +class TestPatchedGoogleWorkspaceProviderMappingRequest(unittest.TestCase): + """PatchedGoogleWorkspaceProviderMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGoogleWorkspaceProviderMappingRequest: + """Test PatchedGoogleWorkspaceProviderMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGoogleWorkspaceProviderMappingRequest` + """ + model = PatchedGoogleWorkspaceProviderMappingRequest() + if include_optional: + return PatchedGoogleWorkspaceProviderMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedGoogleWorkspaceProviderMappingRequest( + ) + """ + + def testPatchedGoogleWorkspaceProviderMappingRequest(self): + """Test PatchedGoogleWorkspaceProviderMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_google_workspace_provider_request.py b/test/test_patched_google_workspace_provider_request.py new file mode 100644 index 000000000..a39779656 --- /dev/null +++ b/test/test_patched_google_workspace_provider_request.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_google_workspace_provider_request import PatchedGoogleWorkspaceProviderRequest + +class TestPatchedGoogleWorkspaceProviderRequest(unittest.TestCase): + """PatchedGoogleWorkspaceProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGoogleWorkspaceProviderRequest: + """Test PatchedGoogleWorkspaceProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGoogleWorkspaceProviderRequest` + """ + model = PatchedGoogleWorkspaceProviderRequest() + if include_optional: + return PatchedGoogleWorkspaceProviderRequest( + name = '0', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + delegated_subject = '0', + credentials = { + 'key' : null + }, + scopes = '0', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + default_group_email_domain = '0', + sync_page_size = 1, + sync_page_timeout = '0', + dry_run = True + ) + else: + return PatchedGoogleWorkspaceProviderRequest( + ) + """ + + def testPatchedGoogleWorkspaceProviderRequest(self): + """Test PatchedGoogleWorkspaceProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_group_kerberos_source_connection_request.py b/test/test_patched_group_kerberos_source_connection_request.py new file mode 100644 index 000000000..2d5b1fb37 --- /dev/null +++ b/test/test_patched_group_kerberos_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_group_kerberos_source_connection_request import PatchedGroupKerberosSourceConnectionRequest + +class TestPatchedGroupKerberosSourceConnectionRequest(unittest.TestCase): + """PatchedGroupKerberosSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGroupKerberosSourceConnectionRequest: + """Test PatchedGroupKerberosSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGroupKerberosSourceConnectionRequest` + """ + model = PatchedGroupKerberosSourceConnectionRequest() + if include_optional: + return PatchedGroupKerberosSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return PatchedGroupKerberosSourceConnectionRequest( + ) + """ + + def testPatchedGroupKerberosSourceConnectionRequest(self): + """Test PatchedGroupKerberosSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_group_ldap_source_connection_request.py b/test/test_patched_group_ldap_source_connection_request.py new file mode 100644 index 000000000..25da1968f --- /dev/null +++ b/test/test_patched_group_ldap_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_group_ldap_source_connection_request import PatchedGroupLDAPSourceConnectionRequest + +class TestPatchedGroupLDAPSourceConnectionRequest(unittest.TestCase): + """PatchedGroupLDAPSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGroupLDAPSourceConnectionRequest: + """Test PatchedGroupLDAPSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGroupLDAPSourceConnectionRequest` + """ + model = PatchedGroupLDAPSourceConnectionRequest() + if include_optional: + return PatchedGroupLDAPSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return PatchedGroupLDAPSourceConnectionRequest( + ) + """ + + def testPatchedGroupLDAPSourceConnectionRequest(self): + """Test PatchedGroupLDAPSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_group_o_auth_source_connection_request.py b/test/test_patched_group_o_auth_source_connection_request.py new file mode 100644 index 000000000..e7ddecf15 --- /dev/null +++ b/test/test_patched_group_o_auth_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_group_o_auth_source_connection_request import PatchedGroupOAuthSourceConnectionRequest + +class TestPatchedGroupOAuthSourceConnectionRequest(unittest.TestCase): + """PatchedGroupOAuthSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGroupOAuthSourceConnectionRequest: + """Test PatchedGroupOAuthSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGroupOAuthSourceConnectionRequest` + """ + model = PatchedGroupOAuthSourceConnectionRequest() + if include_optional: + return PatchedGroupOAuthSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return PatchedGroupOAuthSourceConnectionRequest( + ) + """ + + def testPatchedGroupOAuthSourceConnectionRequest(self): + """Test PatchedGroupOAuthSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_group_plex_source_connection_request.py b/test/test_patched_group_plex_source_connection_request.py new file mode 100644 index 000000000..d4827534b --- /dev/null +++ b/test/test_patched_group_plex_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_group_plex_source_connection_request import PatchedGroupPlexSourceConnectionRequest + +class TestPatchedGroupPlexSourceConnectionRequest(unittest.TestCase): + """PatchedGroupPlexSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGroupPlexSourceConnectionRequest: + """Test PatchedGroupPlexSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGroupPlexSourceConnectionRequest` + """ + model = PatchedGroupPlexSourceConnectionRequest() + if include_optional: + return PatchedGroupPlexSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return PatchedGroupPlexSourceConnectionRequest( + ) + """ + + def testPatchedGroupPlexSourceConnectionRequest(self): + """Test PatchedGroupPlexSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_group_request.py b/test/test_patched_group_request.py new file mode 100644 index 000000000..33b6e7dd6 --- /dev/null +++ b/test/test_patched_group_request.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_group_request import PatchedGroupRequest + +class TestPatchedGroupRequest(unittest.TestCase): + """PatchedGroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGroupRequest: + """Test PatchedGroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGroupRequest` + """ + model = PatchedGroupRequest() + if include_optional: + return PatchedGroupRequest( + name = '0', + is_superuser = True, + parents = [ + '' + ], + users = [ + 56 + ], + attributes = { + 'key' : null + }, + roles = [ + '' + ] + ) + else: + return PatchedGroupRequest( + ) + """ + + def testPatchedGroupRequest(self): + """Test PatchedGroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_group_saml_source_connection_request.py b/test/test_patched_group_saml_source_connection_request.py new file mode 100644 index 000000000..f6499a9d5 --- /dev/null +++ b/test/test_patched_group_saml_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_group_saml_source_connection_request import PatchedGroupSAMLSourceConnectionRequest + +class TestPatchedGroupSAMLSourceConnectionRequest(unittest.TestCase): + """PatchedGroupSAMLSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGroupSAMLSourceConnectionRequest: + """Test PatchedGroupSAMLSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGroupSAMLSourceConnectionRequest` + """ + model = PatchedGroupSAMLSourceConnectionRequest() + if include_optional: + return PatchedGroupSAMLSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return PatchedGroupSAMLSourceConnectionRequest( + ) + """ + + def testPatchedGroupSAMLSourceConnectionRequest(self): + """Test PatchedGroupSAMLSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_group_source_connection_request.py b/test/test_patched_group_source_connection_request.py new file mode 100644 index 000000000..77e096f2e --- /dev/null +++ b/test/test_patched_group_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_group_source_connection_request import PatchedGroupSourceConnectionRequest + +class TestPatchedGroupSourceConnectionRequest(unittest.TestCase): + """PatchedGroupSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGroupSourceConnectionRequest: + """Test PatchedGroupSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGroupSourceConnectionRequest` + """ + model = PatchedGroupSourceConnectionRequest() + if include_optional: + return PatchedGroupSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return PatchedGroupSourceConnectionRequest( + ) + """ + + def testPatchedGroupSourceConnectionRequest(self): + """Test PatchedGroupSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_group_telegram_source_connection_request.py b/test/test_patched_group_telegram_source_connection_request.py new file mode 100644 index 000000000..c9bfa7383 --- /dev/null +++ b/test/test_patched_group_telegram_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_group_telegram_source_connection_request import PatchedGroupTelegramSourceConnectionRequest + +class TestPatchedGroupTelegramSourceConnectionRequest(unittest.TestCase): + """PatchedGroupTelegramSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedGroupTelegramSourceConnectionRequest: + """Test PatchedGroupTelegramSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedGroupTelegramSourceConnectionRequest` + """ + model = PatchedGroupTelegramSourceConnectionRequest() + if include_optional: + return PatchedGroupTelegramSourceConnectionRequest( + group = '', + source = '', + identifier = '0' + ) + else: + return PatchedGroupTelegramSourceConnectionRequest( + ) + """ + + def testPatchedGroupTelegramSourceConnectionRequest(self): + """Test PatchedGroupTelegramSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_identification_stage_request.py b/test/test_patched_identification_stage_request.py new file mode 100644 index 000000000..a93d4b663 --- /dev/null +++ b/test/test_patched_identification_stage_request.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_identification_stage_request import PatchedIdentificationStageRequest + +class TestPatchedIdentificationStageRequest(unittest.TestCase): + """PatchedIdentificationStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedIdentificationStageRequest: + """Test PatchedIdentificationStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedIdentificationStageRequest` + """ + model = PatchedIdentificationStageRequest() + if include_optional: + return PatchedIdentificationStageRequest( + name = '0', + user_fields = [ + 'email' + ], + password_stage = '', + captcha_stage = '', + case_insensitive_matching = True, + show_matched_user = True, + enrollment_flow = '', + recovery_flow = '', + passwordless_flow = '', + sources = [ + '' + ], + show_source_labels = True, + pretend_user_exists = True, + enable_remember_me = True, + webauthn_stage = '' + ) + else: + return PatchedIdentificationStageRequest( + ) + """ + + def testPatchedIdentificationStageRequest(self): + """Test PatchedIdentificationStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_initial_permissions_request.py b/test/test_patched_initial_permissions_request.py new file mode 100644 index 000000000..d99614d88 --- /dev/null +++ b/test/test_patched_initial_permissions_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_initial_permissions_request import PatchedInitialPermissionsRequest + +class TestPatchedInitialPermissionsRequest(unittest.TestCase): + """PatchedInitialPermissionsRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedInitialPermissionsRequest: + """Test PatchedInitialPermissionsRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedInitialPermissionsRequest` + """ + model = PatchedInitialPermissionsRequest() + if include_optional: + return PatchedInitialPermissionsRequest( + name = '0', + role = '', + permissions = [ + 56 + ] + ) + else: + return PatchedInitialPermissionsRequest( + ) + """ + + def testPatchedInitialPermissionsRequest(self): + """Test PatchedInitialPermissionsRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_invitation_request.py b/test/test_patched_invitation_request.py new file mode 100644 index 000000000..5ac885d83 --- /dev/null +++ b/test/test_patched_invitation_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_invitation_request import PatchedInvitationRequest + +class TestPatchedInvitationRequest(unittest.TestCase): + """PatchedInvitationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedInvitationRequest: + """Test PatchedInvitationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedInvitationRequest` + """ + model = PatchedInvitationRequest() + if include_optional: + return PatchedInvitationRequest( + name = 'z0', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + fixed_data = { + 'key' : null + }, + single_use = True, + flow = '' + ) + else: + return PatchedInvitationRequest( + ) + """ + + def testPatchedInvitationRequest(self): + """Test PatchedInvitationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_invitation_stage_request.py b/test/test_patched_invitation_stage_request.py new file mode 100644 index 000000000..014b72279 --- /dev/null +++ b/test/test_patched_invitation_stage_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_invitation_stage_request import PatchedInvitationStageRequest + +class TestPatchedInvitationStageRequest(unittest.TestCase): + """PatchedInvitationStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedInvitationStageRequest: + """Test PatchedInvitationStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedInvitationStageRequest` + """ + model = PatchedInvitationStageRequest() + if include_optional: + return PatchedInvitationStageRequest( + name = '0', + continue_flow_without_invitation = True + ) + else: + return PatchedInvitationStageRequest( + ) + """ + + def testPatchedInvitationStageRequest(self): + """Test PatchedInvitationStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_kerberos_source_property_mapping_request.py b/test/test_patched_kerberos_source_property_mapping_request.py new file mode 100644 index 000000000..aec0ddf37 --- /dev/null +++ b/test/test_patched_kerberos_source_property_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_kerberos_source_property_mapping_request import PatchedKerberosSourcePropertyMappingRequest + +class TestPatchedKerberosSourcePropertyMappingRequest(unittest.TestCase): + """PatchedKerberosSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedKerberosSourcePropertyMappingRequest: + """Test PatchedKerberosSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedKerberosSourcePropertyMappingRequest` + """ + model = PatchedKerberosSourcePropertyMappingRequest() + if include_optional: + return PatchedKerberosSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedKerberosSourcePropertyMappingRequest( + ) + """ + + def testPatchedKerberosSourcePropertyMappingRequest(self): + """Test PatchedKerberosSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_kerberos_source_request.py b/test/test_patched_kerberos_source_request.py new file mode 100644 index 000000000..bd2dd3984 --- /dev/null +++ b/test/test_patched_kerberos_source_request.py @@ -0,0 +1,82 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_kerberos_source_request import PatchedKerberosSourceRequest + +class TestPatchedKerberosSourceRequest(unittest.TestCase): + """PatchedKerberosSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedKerberosSourceRequest: + """Test PatchedKerberosSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedKerberosSourceRequest` + """ + model = PatchedKerberosSourceRequest() + if include_optional: + return PatchedKerberosSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + group_matching_mode = 'identifier', + realm = '0', + krb5_conf = '', + kadmin_type = 'MIT', + sync_users = True, + sync_users_password = True, + sync_principal = '', + sync_password = '', + sync_keytab = '', + sync_ccache = '', + spnego_server_name = '', + spnego_keytab = '', + spnego_ccache = '', + password_login_update_internal_password = True, + sync_outgoing_trigger_mode = 'none' + ) + else: + return PatchedKerberosSourceRequest( + ) + """ + + def testPatchedKerberosSourceRequest(self): + """Test PatchedKerberosSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_kubernetes_service_connection_request.py b/test/test_patched_kubernetes_service_connection_request.py new file mode 100644 index 000000000..13988a93f --- /dev/null +++ b/test/test_patched_kubernetes_service_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_kubernetes_service_connection_request import PatchedKubernetesServiceConnectionRequest + +class TestPatchedKubernetesServiceConnectionRequest(unittest.TestCase): + """PatchedKubernetesServiceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedKubernetesServiceConnectionRequest: + """Test PatchedKubernetesServiceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedKubernetesServiceConnectionRequest` + """ + model = PatchedKubernetesServiceConnectionRequest() + if include_optional: + return PatchedKubernetesServiceConnectionRequest( + name = '0', + local = True, + kubeconfig = { + 'key' : null + }, + verify_ssl = True + ) + else: + return PatchedKubernetesServiceConnectionRequest( + ) + """ + + def testPatchedKubernetesServiceConnectionRequest(self): + """Test PatchedKubernetesServiceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_ldap_provider_request.py b/test/test_patched_ldap_provider_request.py new file mode 100644 index 000000000..23da3533c --- /dev/null +++ b/test/test_patched_ldap_provider_request.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_ldap_provider_request import PatchedLDAPProviderRequest + +class TestPatchedLDAPProviderRequest(unittest.TestCase): + """PatchedLDAPProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedLDAPProviderRequest: + """Test PatchedLDAPProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedLDAPProviderRequest` + """ + model = PatchedLDAPProviderRequest() + if include_optional: + return PatchedLDAPProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + base_dn = '0', + certificate = '', + tls_server_name = '', + uid_start_number = -2147483648, + gid_start_number = -2147483648, + search_mode = 'direct', + bind_mode = 'direct', + mfa_support = True + ) + else: + return PatchedLDAPProviderRequest( + ) + """ + + def testPatchedLDAPProviderRequest(self): + """Test PatchedLDAPProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_ldap_source_property_mapping_request.py b/test/test_patched_ldap_source_property_mapping_request.py new file mode 100644 index 000000000..50a99d101 --- /dev/null +++ b/test/test_patched_ldap_source_property_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_ldap_source_property_mapping_request import PatchedLDAPSourcePropertyMappingRequest + +class TestPatchedLDAPSourcePropertyMappingRequest(unittest.TestCase): + """PatchedLDAPSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedLDAPSourcePropertyMappingRequest: + """Test PatchedLDAPSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedLDAPSourcePropertyMappingRequest` + """ + model = PatchedLDAPSourcePropertyMappingRequest() + if include_optional: + return PatchedLDAPSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedLDAPSourcePropertyMappingRequest( + ) + """ + + def testPatchedLDAPSourcePropertyMappingRequest(self): + """Test PatchedLDAPSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_ldap_source_request.py b/test/test_patched_ldap_source_request.py new file mode 100644 index 000000000..c08d93fad --- /dev/null +++ b/test/test_patched_ldap_source_request.py @@ -0,0 +1,90 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_ldap_source_request import PatchedLDAPSourceRequest + +class TestPatchedLDAPSourceRequest(unittest.TestCase): + """PatchedLDAPSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedLDAPSourceRequest: + """Test PatchedLDAPSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedLDAPSourceRequest` + """ + model = PatchedLDAPSourceRequest() + if include_optional: + return PatchedLDAPSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + server_uri = '0', + peer_certificate = '', + client_certificate = '', + bind_cn = '', + bind_password = '', + start_tls = True, + sni = True, + base_dn = '0', + additional_user_dn = '', + additional_group_dn = '', + user_object_filter = '0', + group_object_filter = '0', + group_membership_field = '0', + user_membership_attribute = '0', + object_uniqueness_field = '0', + password_login_update_internal_password = True, + sync_users = True, + sync_users_password = True, + sync_groups = True, + sync_parent_group = '', + lookup_groups_from_user = True, + delete_not_found_objects = True, + sync_outgoing_trigger_mode = 'none' + ) + else: + return PatchedLDAPSourceRequest( + ) + """ + + def testPatchedLDAPSourceRequest(self): + """Test PatchedLDAPSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_license_request.py b/test/test_patched_license_request.py new file mode 100644 index 000000000..d148e59ce --- /dev/null +++ b/test/test_patched_license_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_license_request import PatchedLicenseRequest + +class TestPatchedLicenseRequest(unittest.TestCase): + """PatchedLicenseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedLicenseRequest: + """Test PatchedLicenseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedLicenseRequest` + """ + model = PatchedLicenseRequest() + if include_optional: + return PatchedLicenseRequest( + key = '0' + ) + else: + return PatchedLicenseRequest( + ) + """ + + def testPatchedLicenseRequest(self): + """Test PatchedLicenseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_lifecycle_rule_request.py b/test/test_patched_lifecycle_rule_request.py new file mode 100644 index 000000000..064aa45aa --- /dev/null +++ b/test/test_patched_lifecycle_rule_request.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_lifecycle_rule_request import PatchedLifecycleRuleRequest + +class TestPatchedLifecycleRuleRequest(unittest.TestCase): + """PatchedLifecycleRuleRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedLifecycleRuleRequest: + """Test PatchedLifecycleRuleRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedLifecycleRuleRequest` + """ + model = PatchedLifecycleRuleRequest() + if include_optional: + return PatchedLifecycleRuleRequest( + name = '0', + content_type = 'authentik_core.application', + object_id = '0', + interval = '0', + grace_period = '0', + reviewer_groups = [ + '' + ], + min_reviewers = 0, + min_reviewers_is_per_group = True, + reviewers = [ + '' + ], + notification_transports = [ + '' + ] + ) + else: + return PatchedLifecycleRuleRequest( + ) + """ + + def testPatchedLifecycleRuleRequest(self): + """Test PatchedLifecycleRuleRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_microsoft_entra_provider_mapping_request.py b/test/test_patched_microsoft_entra_provider_mapping_request.py new file mode 100644 index 000000000..d9fcbba12 --- /dev/null +++ b/test/test_patched_microsoft_entra_provider_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_microsoft_entra_provider_mapping_request import PatchedMicrosoftEntraProviderMappingRequest + +class TestPatchedMicrosoftEntraProviderMappingRequest(unittest.TestCase): + """PatchedMicrosoftEntraProviderMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedMicrosoftEntraProviderMappingRequest: + """Test PatchedMicrosoftEntraProviderMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedMicrosoftEntraProviderMappingRequest` + """ + model = PatchedMicrosoftEntraProviderMappingRequest() + if include_optional: + return PatchedMicrosoftEntraProviderMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedMicrosoftEntraProviderMappingRequest( + ) + """ + + def testPatchedMicrosoftEntraProviderMappingRequest(self): + """Test PatchedMicrosoftEntraProviderMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_microsoft_entra_provider_request.py b/test/test_patched_microsoft_entra_provider_request.py new file mode 100644 index 000000000..417df99f2 --- /dev/null +++ b/test/test_patched_microsoft_entra_provider_request.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_microsoft_entra_provider_request import PatchedMicrosoftEntraProviderRequest + +class TestPatchedMicrosoftEntraProviderRequest(unittest.TestCase): + """PatchedMicrosoftEntraProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedMicrosoftEntraProviderRequest: + """Test PatchedMicrosoftEntraProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedMicrosoftEntraProviderRequest` + """ + model = PatchedMicrosoftEntraProviderRequest() + if include_optional: + return PatchedMicrosoftEntraProviderRequest( + name = '0', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + client_id = '0', + client_secret = '0', + tenant_id = '0', + exclude_users_service_account = True, + filter_group = '', + user_delete_action = 'do_nothing', + group_delete_action = 'do_nothing', + sync_page_size = 1, + sync_page_timeout = '0', + dry_run = True + ) + else: + return PatchedMicrosoftEntraProviderRequest( + ) + """ + + def testPatchedMicrosoftEntraProviderRequest(self): + """Test PatchedMicrosoftEntraProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_mutual_tls_stage_request.py b/test/test_patched_mutual_tls_stage_request.py new file mode 100644 index 000000000..1b984db55 --- /dev/null +++ b/test/test_patched_mutual_tls_stage_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_mutual_tls_stage_request import PatchedMutualTLSStageRequest + +class TestPatchedMutualTLSStageRequest(unittest.TestCase): + """PatchedMutualTLSStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedMutualTLSStageRequest: + """Test PatchedMutualTLSStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedMutualTLSStageRequest` + """ + model = PatchedMutualTLSStageRequest() + if include_optional: + return PatchedMutualTLSStageRequest( + name = '0', + mode = 'optional', + certificate_authorities = [ + '' + ], + cert_attribute = 'subject', + user_attribute = 'username' + ) + else: + return PatchedMutualTLSStageRequest( + ) + """ + + def testPatchedMutualTLSStageRequest(self): + """Test PatchedMutualTLSStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_notification_request.py b/test/test_patched_notification_request.py new file mode 100644 index 000000000..4d09aaa79 --- /dev/null +++ b/test/test_patched_notification_request.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_notification_request import PatchedNotificationRequest + +class TestPatchedNotificationRequest(unittest.TestCase): + """PatchedNotificationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedNotificationRequest: + """Test PatchedNotificationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedNotificationRequest` + """ + model = PatchedNotificationRequest() + if include_optional: + return PatchedNotificationRequest( + hyperlink = '', + hyperlink_label = '', + event = authentik_client.models.event_request.EventRequest( + user = { + 'key' : null + }, + action = 'login', + app = '0', + context = { + 'key' : null + }, + client_ip = '0', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + brand = { + 'key' : null + }, ), + seen = True + ) + else: + return PatchedNotificationRequest( + ) + """ + + def testPatchedNotificationRequest(self): + """Test PatchedNotificationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_notification_rule_request.py b/test/test_patched_notification_rule_request.py new file mode 100644 index 000000000..eed865b1a --- /dev/null +++ b/test/test_patched_notification_rule_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_notification_rule_request import PatchedNotificationRuleRequest + +class TestPatchedNotificationRuleRequest(unittest.TestCase): + """PatchedNotificationRuleRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedNotificationRuleRequest: + """Test PatchedNotificationRuleRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedNotificationRuleRequest` + """ + model = PatchedNotificationRuleRequest() + if include_optional: + return PatchedNotificationRuleRequest( + name = '0', + transports = [ + '' + ], + severity = 'notice', + destination_group = '', + destination_event_user = True + ) + else: + return PatchedNotificationRuleRequest( + ) + """ + + def testPatchedNotificationRuleRequest(self): + """Test PatchedNotificationRuleRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_notification_transport_request.py b/test/test_patched_notification_transport_request.py new file mode 100644 index 000000000..21cf3ab05 --- /dev/null +++ b/test/test_patched_notification_transport_request.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_notification_transport_request import PatchedNotificationTransportRequest + +class TestPatchedNotificationTransportRequest(unittest.TestCase): + """PatchedNotificationTransportRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedNotificationTransportRequest: + """Test PatchedNotificationTransportRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedNotificationTransportRequest` + """ + model = PatchedNotificationTransportRequest() + if include_optional: + return PatchedNotificationTransportRequest( + name = '0', + mode = 'local', + webhook_url = '', + webhook_ca = '', + webhook_mapping_body = '', + webhook_mapping_headers = '', + email_subject_prefix = '', + email_template = '0', + send_once = True + ) + else: + return PatchedNotificationTransportRequest( + ) + """ + + def testPatchedNotificationTransportRequest(self): + """Test PatchedNotificationTransportRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_notification_webhook_mapping_request.py b/test/test_patched_notification_webhook_mapping_request.py new file mode 100644 index 000000000..bbdd653b7 --- /dev/null +++ b/test/test_patched_notification_webhook_mapping_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_notification_webhook_mapping_request import PatchedNotificationWebhookMappingRequest + +class TestPatchedNotificationWebhookMappingRequest(unittest.TestCase): + """PatchedNotificationWebhookMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedNotificationWebhookMappingRequest: + """Test PatchedNotificationWebhookMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedNotificationWebhookMappingRequest` + """ + model = PatchedNotificationWebhookMappingRequest() + if include_optional: + return PatchedNotificationWebhookMappingRequest( + name = '0', + expression = '0' + ) + else: + return PatchedNotificationWebhookMappingRequest( + ) + """ + + def testPatchedNotificationWebhookMappingRequest(self): + """Test PatchedNotificationWebhookMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_o_auth2_provider_request.py b/test/test_patched_o_auth2_provider_request.py new file mode 100644 index 000000000..37ee036af --- /dev/null +++ b/test/test_patched_o_auth2_provider_request.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_o_auth2_provider_request import PatchedOAuth2ProviderRequest + +class TestPatchedOAuth2ProviderRequest(unittest.TestCase): + """PatchedOAuth2ProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedOAuth2ProviderRequest: + """Test PatchedOAuth2ProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedOAuth2ProviderRequest` + """ + model = PatchedOAuth2ProviderRequest() + if include_optional: + return PatchedOAuth2ProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + client_type = 'confidential', + grant_types = [ + 'authorization_code' + ], + client_id = '0', + client_secret = '', + access_code_validity = '0', + access_token_validity = '0', + refresh_token_validity = '0', + refresh_token_threshold = '0', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri_request.RedirectURIRequest( + matching_mode = 'strict', + url = '0', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = 'backchannel', + sub_mode = 'hashed_user_id', + issuer_mode = 'global', + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ] + ) + else: + return PatchedOAuth2ProviderRequest( + ) + """ + + def testPatchedOAuth2ProviderRequest(self): + """Test PatchedOAuth2ProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_o_auth_source_property_mapping_request.py b/test/test_patched_o_auth_source_property_mapping_request.py new file mode 100644 index 000000000..4b8e2916e --- /dev/null +++ b/test/test_patched_o_auth_source_property_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_o_auth_source_property_mapping_request import PatchedOAuthSourcePropertyMappingRequest + +class TestPatchedOAuthSourcePropertyMappingRequest(unittest.TestCase): + """PatchedOAuthSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedOAuthSourcePropertyMappingRequest: + """Test PatchedOAuthSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedOAuthSourcePropertyMappingRequest` + """ + model = PatchedOAuthSourcePropertyMappingRequest() + if include_optional: + return PatchedOAuthSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedOAuthSourcePropertyMappingRequest( + ) + """ + + def testPatchedOAuthSourcePropertyMappingRequest(self): + """Test PatchedOAuthSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_o_auth_source_request.py b/test/test_patched_o_auth_source_request.py new file mode 100644 index 000000000..822584d2f --- /dev/null +++ b/test/test_patched_o_auth_source_request.py @@ -0,0 +1,83 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_o_auth_source_request import PatchedOAuthSourceRequest + +class TestPatchedOAuthSourceRequest(unittest.TestCase): + """PatchedOAuthSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedOAuthSourceRequest: + """Test PatchedOAuthSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedOAuthSourceRequest` + """ + model = PatchedOAuthSourceRequest() + if include_optional: + return PatchedOAuthSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + group_matching_mode = 'identifier', + provider_type = 'apple', + request_token_url = '', + authorization_url = '', + access_token_url = '', + profile_url = '', + pkce = 'none', + consumer_key = '0', + consumer_secret = '0', + additional_scopes = '', + oidc_well_known_url = '', + oidc_jwks_url = '', + oidc_jwks = { + 'key' : null + }, + authorization_code_auth_method = 'basic_auth' + ) + else: + return PatchedOAuthSourceRequest( + ) + """ + + def testPatchedOAuthSourceRequest(self): + """Test PatchedOAuthSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_outpost_request.py b/test/test_patched_outpost_request.py new file mode 100644 index 000000000..b01a0d083 --- /dev/null +++ b/test/test_patched_outpost_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_outpost_request import PatchedOutpostRequest + +class TestPatchedOutpostRequest(unittest.TestCase): + """PatchedOutpostRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedOutpostRequest: + """Test PatchedOutpostRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedOutpostRequest` + """ + model = PatchedOutpostRequest() + if include_optional: + return PatchedOutpostRequest( + name = '0', + type = 'proxy', + providers = [ + 56 + ], + service_connection = '', + config = { + 'key' : null + }, + managed = '0' + ) + else: + return PatchedOutpostRequest( + ) + """ + + def testPatchedOutpostRequest(self): + """Test PatchedOutpostRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_password_expiry_policy_request.py b/test/test_patched_password_expiry_policy_request.py new file mode 100644 index 000000000..9a63a2427 --- /dev/null +++ b/test/test_patched_password_expiry_policy_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_password_expiry_policy_request import PatchedPasswordExpiryPolicyRequest + +class TestPatchedPasswordExpiryPolicyRequest(unittest.TestCase): + """PatchedPasswordExpiryPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedPasswordExpiryPolicyRequest: + """Test PatchedPasswordExpiryPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedPasswordExpiryPolicyRequest` + """ + model = PatchedPasswordExpiryPolicyRequest() + if include_optional: + return PatchedPasswordExpiryPolicyRequest( + name = '0', + execution_logging = True, + days = -2147483648, + deny_only = True + ) + else: + return PatchedPasswordExpiryPolicyRequest( + ) + """ + + def testPatchedPasswordExpiryPolicyRequest(self): + """Test PatchedPasswordExpiryPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_password_policy_request.py b/test/test_patched_password_policy_request.py new file mode 100644 index 000000000..c33e3ee07 --- /dev/null +++ b/test/test_patched_password_policy_request.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_password_policy_request import PatchedPasswordPolicyRequest + +class TestPatchedPasswordPolicyRequest(unittest.TestCase): + """PatchedPasswordPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedPasswordPolicyRequest: + """Test PatchedPasswordPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedPasswordPolicyRequest` + """ + model = PatchedPasswordPolicyRequest() + if include_optional: + return PatchedPasswordPolicyRequest( + name = '0', + execution_logging = True, + password_field = '0', + amount_digits = 0, + amount_uppercase = 0, + amount_lowercase = 0, + amount_symbols = 0, + length_min = 0, + symbol_charset = '0', + error_message = '', + check_static_rules = True, + check_have_i_been_pwned = True, + check_zxcvbn = True, + hibp_allowed_count = 0, + zxcvbn_score_threshold = 0 + ) + else: + return PatchedPasswordPolicyRequest( + ) + """ + + def testPatchedPasswordPolicyRequest(self): + """Test PatchedPasswordPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_password_stage_request.py b/test/test_patched_password_stage_request.py new file mode 100644 index 000000000..da2932b08 --- /dev/null +++ b/test/test_patched_password_stage_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_password_stage_request import PatchedPasswordStageRequest + +class TestPatchedPasswordStageRequest(unittest.TestCase): + """PatchedPasswordStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedPasswordStageRequest: + """Test PatchedPasswordStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedPasswordStageRequest` + """ + model = PatchedPasswordStageRequest() + if include_optional: + return PatchedPasswordStageRequest( + name = '0', + backends = [ + 'authentik.core.auth.InbuiltBackend' + ], + configure_flow = '', + failed_attempts_before_cancel = -2147483648, + allow_show_password = True + ) + else: + return PatchedPasswordStageRequest( + ) + """ + + def testPatchedPasswordStageRequest(self): + """Test PatchedPasswordStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_permission_assign_request.py b/test/test_patched_permission_assign_request.py new file mode 100644 index 000000000..b7727579f --- /dev/null +++ b/test/test_patched_permission_assign_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_permission_assign_request import PatchedPermissionAssignRequest + +class TestPatchedPermissionAssignRequest(unittest.TestCase): + """PatchedPermissionAssignRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedPermissionAssignRequest: + """Test PatchedPermissionAssignRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedPermissionAssignRequest` + """ + model = PatchedPermissionAssignRequest() + if include_optional: + return PatchedPermissionAssignRequest( + permissions = [ + '0' + ], + model = 'authentik_tenants.domain', + object_pk = '0' + ) + else: + return PatchedPermissionAssignRequest( + ) + """ + + def testPatchedPermissionAssignRequest(self): + """Test PatchedPermissionAssignRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_plex_source_property_mapping_request.py b/test/test_patched_plex_source_property_mapping_request.py new file mode 100644 index 000000000..cfa22196f --- /dev/null +++ b/test/test_patched_plex_source_property_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_plex_source_property_mapping_request import PatchedPlexSourcePropertyMappingRequest + +class TestPatchedPlexSourcePropertyMappingRequest(unittest.TestCase): + """PatchedPlexSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedPlexSourcePropertyMappingRequest: + """Test PatchedPlexSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedPlexSourcePropertyMappingRequest` + """ + model = PatchedPlexSourcePropertyMappingRequest() + if include_optional: + return PatchedPlexSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedPlexSourcePropertyMappingRequest( + ) + """ + + def testPatchedPlexSourcePropertyMappingRequest(self): + """Test PatchedPlexSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_plex_source_request.py b/test/test_patched_plex_source_request.py new file mode 100644 index 000000000..e849ca11f --- /dev/null +++ b/test/test_patched_plex_source_request.py @@ -0,0 +1,74 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_plex_source_request import PatchedPlexSourceRequest + +class TestPatchedPlexSourceRequest(unittest.TestCase): + """PatchedPlexSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedPlexSourceRequest: + """Test PatchedPlexSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedPlexSourceRequest` + """ + model = PatchedPlexSourceRequest() + if include_optional: + return PatchedPlexSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + group_matching_mode = 'identifier', + client_id = '0', + allowed_servers = [ + '0' + ], + allow_friends = True, + plex_token = '0' + ) + else: + return PatchedPlexSourceRequest( + ) + """ + + def testPatchedPlexSourceRequest(self): + """Test PatchedPlexSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_policy_binding_request.py b/test/test_patched_policy_binding_request.py new file mode 100644 index 000000000..6a2a501f8 --- /dev/null +++ b/test/test_patched_policy_binding_request.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_policy_binding_request import PatchedPolicyBindingRequest + +class TestPatchedPolicyBindingRequest(unittest.TestCase): + """PatchedPolicyBindingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedPolicyBindingRequest: + """Test PatchedPolicyBindingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedPolicyBindingRequest` + """ + model = PatchedPolicyBindingRequest() + if include_optional: + return PatchedPolicyBindingRequest( + policy = '', + group = '', + user = 56, + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True + ) + else: + return PatchedPolicyBindingRequest( + ) + """ + + def testPatchedPolicyBindingRequest(self): + """Test PatchedPolicyBindingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_prompt_request.py b/test/test_patched_prompt_request.py new file mode 100644 index 000000000..5b497b4f1 --- /dev/null +++ b/test/test_patched_prompt_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_prompt_request import PatchedPromptRequest + +class TestPatchedPromptRequest(unittest.TestCase): + """PatchedPromptRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedPromptRequest: + """Test PatchedPromptRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedPromptRequest` + """ + model = PatchedPromptRequest() + if include_optional: + return PatchedPromptRequest( + name = '0', + field_key = '0', + label = '0', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = -2147483648, + sub_text = '', + placeholder_expression = True, + initial_value_expression = True + ) + else: + return PatchedPromptRequest( + ) + """ + + def testPatchedPromptRequest(self): + """Test PatchedPromptRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_prompt_stage_request.py b/test/test_patched_prompt_stage_request.py new file mode 100644 index 000000000..6613de059 --- /dev/null +++ b/test/test_patched_prompt_stage_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_prompt_stage_request import PatchedPromptStageRequest + +class TestPatchedPromptStageRequest(unittest.TestCase): + """PatchedPromptStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedPromptStageRequest: + """Test PatchedPromptStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedPromptStageRequest` + """ + model = PatchedPromptStageRequest() + if include_optional: + return PatchedPromptStageRequest( + name = '0', + fields = [ + '' + ], + validation_policies = [ + '' + ] + ) + else: + return PatchedPromptStageRequest( + ) + """ + + def testPatchedPromptStageRequest(self): + """Test PatchedPromptStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_proxy_provider_request.py b/test/test_patched_proxy_provider_request.py new file mode 100644 index 000000000..33c619f15 --- /dev/null +++ b/test/test_patched_proxy_provider_request.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_proxy_provider_request import PatchedProxyProviderRequest + +class TestPatchedProxyProviderRequest(unittest.TestCase): + """PatchedProxyProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedProxyProviderRequest: + """Test PatchedProxyProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedProxyProviderRequest` + """ + model = PatchedProxyProviderRequest() + if include_optional: + return PatchedProxyProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + internal_host = '', + external_host = '0', + internal_host_ssl_validation = True, + certificate = '', + skip_path_regex = '', + basic_auth_enabled = True, + basic_auth_password_attribute = '', + basic_auth_user_attribute = '', + mode = 'proxy', + intercept_header_auth = True, + cookie_domain = '', + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], + access_token_validity = '0', + refresh_token_validity = '0' + ) + else: + return PatchedProxyProviderRequest( + ) + """ + + def testPatchedProxyProviderRequest(self): + """Test PatchedProxyProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_rac_property_mapping_request.py b/test/test_patched_rac_property_mapping_request.py new file mode 100644 index 000000000..a6cf706e7 --- /dev/null +++ b/test/test_patched_rac_property_mapping_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_rac_property_mapping_request import PatchedRACPropertyMappingRequest + +class TestPatchedRACPropertyMappingRequest(unittest.TestCase): + """PatchedRACPropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedRACPropertyMappingRequest: + """Test PatchedRACPropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedRACPropertyMappingRequest` + """ + model = PatchedRACPropertyMappingRequest() + if include_optional: + return PatchedRACPropertyMappingRequest( + managed = '0', + name = '0', + expression = '', + static_settings = { + 'key' : null + } + ) + else: + return PatchedRACPropertyMappingRequest( + ) + """ + + def testPatchedRACPropertyMappingRequest(self): + """Test PatchedRACPropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_rac_provider_request.py b/test/test_patched_rac_provider_request.py new file mode 100644 index 000000000..5e6aaf1e8 --- /dev/null +++ b/test/test_patched_rac_provider_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_rac_provider_request import PatchedRACProviderRequest + +class TestPatchedRACProviderRequest(unittest.TestCase): + """PatchedRACProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedRACProviderRequest: + """Test PatchedRACProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedRACProviderRequest` + """ + model = PatchedRACProviderRequest() + if include_optional: + return PatchedRACProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + property_mappings = [ + '' + ], + settings = { + 'key' : null + }, + connection_expiry = '0', + delete_token_on_disconnect = True + ) + else: + return PatchedRACProviderRequest( + ) + """ + + def testPatchedRACProviderRequest(self): + """Test PatchedRACProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_radius_provider_property_mapping_request.py b/test/test_patched_radius_provider_property_mapping_request.py new file mode 100644 index 000000000..8c2a41b44 --- /dev/null +++ b/test/test_patched_radius_provider_property_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_radius_provider_property_mapping_request import PatchedRadiusProviderPropertyMappingRequest + +class TestPatchedRadiusProviderPropertyMappingRequest(unittest.TestCase): + """PatchedRadiusProviderPropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedRadiusProviderPropertyMappingRequest: + """Test PatchedRadiusProviderPropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedRadiusProviderPropertyMappingRequest` + """ + model = PatchedRadiusProviderPropertyMappingRequest() + if include_optional: + return PatchedRadiusProviderPropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedRadiusProviderPropertyMappingRequest( + ) + """ + + def testPatchedRadiusProviderPropertyMappingRequest(self): + """Test PatchedRadiusProviderPropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_radius_provider_request.py b/test/test_patched_radius_provider_request.py new file mode 100644 index 000000000..b418c1da1 --- /dev/null +++ b/test/test_patched_radius_provider_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_radius_provider_request import PatchedRadiusProviderRequest + +class TestPatchedRadiusProviderRequest(unittest.TestCase): + """PatchedRadiusProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedRadiusProviderRequest: + """Test PatchedRadiusProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedRadiusProviderRequest` + """ + model = PatchedRadiusProviderRequest() + if include_optional: + return PatchedRadiusProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + client_networks = '0', + shared_secret = '0', + mfa_support = True, + certificate = '' + ) + else: + return PatchedRadiusProviderRequest( + ) + """ + + def testPatchedRadiusProviderRequest(self): + """Test PatchedRadiusProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_redirect_stage_request.py b/test/test_patched_redirect_stage_request.py new file mode 100644 index 000000000..35e9f8713 --- /dev/null +++ b/test/test_patched_redirect_stage_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_redirect_stage_request import PatchedRedirectStageRequest + +class TestPatchedRedirectStageRequest(unittest.TestCase): + """PatchedRedirectStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedRedirectStageRequest: + """Test PatchedRedirectStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedRedirectStageRequest` + """ + model = PatchedRedirectStageRequest() + if include_optional: + return PatchedRedirectStageRequest( + name = '0', + keep_context = True, + mode = 'static', + target_static = '', + target_flow = '' + ) + else: + return PatchedRedirectStageRequest( + ) + """ + + def testPatchedRedirectStageRequest(self): + """Test PatchedRedirectStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_reputation_policy_request.py b/test/test_patched_reputation_policy_request.py new file mode 100644 index 000000000..7076d3620 --- /dev/null +++ b/test/test_patched_reputation_policy_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_reputation_policy_request import PatchedReputationPolicyRequest + +class TestPatchedReputationPolicyRequest(unittest.TestCase): + """PatchedReputationPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedReputationPolicyRequest: + """Test PatchedReputationPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedReputationPolicyRequest` + """ + model = PatchedReputationPolicyRequest() + if include_optional: + return PatchedReputationPolicyRequest( + name = '0', + execution_logging = True, + check_ip = True, + check_username = True, + threshold = -2147483648 + ) + else: + return PatchedReputationPolicyRequest( + ) + """ + + def testPatchedReputationPolicyRequest(self): + """Test PatchedReputationPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_role_request.py b/test/test_patched_role_request.py new file mode 100644 index 000000000..b6874a696 --- /dev/null +++ b/test/test_patched_role_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_role_request import PatchedRoleRequest + +class TestPatchedRoleRequest(unittest.TestCase): + """PatchedRoleRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedRoleRequest: + """Test PatchedRoleRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedRoleRequest` + """ + model = PatchedRoleRequest() + if include_optional: + return PatchedRoleRequest( + name = '0' + ) + else: + return PatchedRoleRequest( + ) + """ + + def testPatchedRoleRequest(self): + """Test PatchedRoleRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_saml_property_mapping_request.py b/test/test_patched_saml_property_mapping_request.py new file mode 100644 index 000000000..48fcd8655 --- /dev/null +++ b/test/test_patched_saml_property_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_saml_property_mapping_request import PatchedSAMLPropertyMappingRequest + +class TestPatchedSAMLPropertyMappingRequest(unittest.TestCase): + """PatchedSAMLPropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSAMLPropertyMappingRequest: + """Test PatchedSAMLPropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSAMLPropertyMappingRequest` + """ + model = PatchedSAMLPropertyMappingRequest() + if include_optional: + return PatchedSAMLPropertyMappingRequest( + managed = '0', + name = '0', + expression = '0', + saml_name = '0', + friendly_name = '' + ) + else: + return PatchedSAMLPropertyMappingRequest( + ) + """ + + def testPatchedSAMLPropertyMappingRequest(self): + """Test PatchedSAMLPropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_saml_provider_request.py b/test/test_patched_saml_provider_request.py new file mode 100644 index 000000000..3044a383f --- /dev/null +++ b/test/test_patched_saml_provider_request.py @@ -0,0 +1,81 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_saml_provider_request import PatchedSAMLProviderRequest + +class TestPatchedSAMLProviderRequest(unittest.TestCase): + """PatchedSAMLProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSAMLProviderRequest: + """Test PatchedSAMLProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSAMLProviderRequest` + """ + model = PatchedSAMLProviderRequest() + if include_optional: + return PatchedSAMLProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + acs_url = '0', + sls_url = '', + audience = '', + issuer_override = '', + assertion_valid_not_before = '0', + assertion_valid_not_on_or_after = '0', + session_valid_not_on_or_after = '0', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + verification_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_response = True, + sign_logout_request = True, + sign_logout_response = True, + sp_binding = 'redirect', + sls_binding = 'redirect', + logout_method = 'frontchannel_iframe', + default_relay_state = '', + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress' + ) + else: + return PatchedSAMLProviderRequest( + ) + """ + + def testPatchedSAMLProviderRequest(self): + """Test PatchedSAMLProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_saml_source_property_mapping_request.py b/test/test_patched_saml_source_property_mapping_request.py new file mode 100644 index 000000000..09ccf1498 --- /dev/null +++ b/test/test_patched_saml_source_property_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_saml_source_property_mapping_request import PatchedSAMLSourcePropertyMappingRequest + +class TestPatchedSAMLSourcePropertyMappingRequest(unittest.TestCase): + """PatchedSAMLSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSAMLSourcePropertyMappingRequest: + """Test PatchedSAMLSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSAMLSourcePropertyMappingRequest` + """ + model = PatchedSAMLSourcePropertyMappingRequest() + if include_optional: + return PatchedSAMLSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedSAMLSourcePropertyMappingRequest( + ) + """ + + def testPatchedSAMLSourcePropertyMappingRequest(self): + """Test PatchedSAMLSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_saml_source_request.py b/test/test_patched_saml_source_request.py new file mode 100644 index 000000000..30bedeca1 --- /dev/null +++ b/test/test_patched_saml_source_request.py @@ -0,0 +1,84 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_saml_source_request import PatchedSAMLSourceRequest + +class TestPatchedSAMLSourceRequest(unittest.TestCase): + """PatchedSAMLSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSAMLSourceRequest: + """Test PatchedSAMLSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSAMLSourceRequest` + """ + model = PatchedSAMLSourceRequest() + if include_optional: + return PatchedSAMLSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + group_matching_mode = 'identifier', + pre_authentication_flow = '', + issuer = '', + sso_url = '0', + slo_url = '', + allow_idp_initiated = True, + force_authn = True, + name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + binding_type = 'REDIRECT', + verification_kp = '', + signing_kp = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + temporary_user_delete_after = '0', + encryption_kp = '', + signed_assertion = True, + signed_response = True + ) + else: + return PatchedSAMLSourceRequest( + ) + """ + + def testPatchedSAMLSourceRequest(self): + """Test PatchedSAMLSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_schedule_request.py b/test/test_patched_schedule_request.py new file mode 100644 index 000000000..624e6ede0 --- /dev/null +++ b/test/test_patched_schedule_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_schedule_request import PatchedScheduleRequest + +class TestPatchedScheduleRequest(unittest.TestCase): + """PatchedScheduleRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedScheduleRequest: + """Test PatchedScheduleRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedScheduleRequest` + """ + model = PatchedScheduleRequest() + if include_optional: + return PatchedScheduleRequest( + rel_obj_id = '0', + crontab = '0', + paused = True + ) + else: + return PatchedScheduleRequest( + ) + """ + + def testPatchedScheduleRequest(self): + """Test PatchedScheduleRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_scim_mapping_request.py b/test/test_patched_scim_mapping_request.py new file mode 100644 index 000000000..e4cbb76aa --- /dev/null +++ b/test/test_patched_scim_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_scim_mapping_request import PatchedSCIMMappingRequest + +class TestPatchedSCIMMappingRequest(unittest.TestCase): + """PatchedSCIMMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSCIMMappingRequest: + """Test PatchedSCIMMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSCIMMappingRequest` + """ + model = PatchedSCIMMappingRequest() + if include_optional: + return PatchedSCIMMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedSCIMMappingRequest( + ) + """ + + def testPatchedSCIMMappingRequest(self): + """Test PatchedSCIMMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_scim_provider_request.py b/test/test_patched_scim_provider_request.py new file mode 100644 index 000000000..448c8b1ac --- /dev/null +++ b/test/test_patched_scim_provider_request.py @@ -0,0 +1,75 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_scim_provider_request import PatchedSCIMProviderRequest + +class TestPatchedSCIMProviderRequest(unittest.TestCase): + """PatchedSCIMProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSCIMProviderRequest: + """Test PatchedSCIMProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSCIMProviderRequest` + """ + model = PatchedSCIMProviderRequest() + if include_optional: + return PatchedSCIMProviderRequest( + name = '0', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + url = '0', + verify_certificates = True, + token = '', + auth_mode = 'token', + auth_oauth = '', + auth_oauth_params = { + 'key' : null + }, + compatibility_mode = 'default', + service_provider_config_cache_timeout = '0', + exclude_users_service_account = True, + sync_page_size = 1, + sync_page_timeout = '0', + group_filters = [ + '' + ], + dry_run = True + ) + else: + return PatchedSCIMProviderRequest( + ) + """ + + def testPatchedSCIMProviderRequest(self): + """Test PatchedSCIMProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_scim_source_group_request.py b/test/test_patched_scim_source_group_request.py new file mode 100644 index 000000000..3a6ee2ac9 --- /dev/null +++ b/test/test_patched_scim_source_group_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_scim_source_group_request import PatchedSCIMSourceGroupRequest + +class TestPatchedSCIMSourceGroupRequest(unittest.TestCase): + """PatchedSCIMSourceGroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSCIMSourceGroupRequest: + """Test PatchedSCIMSourceGroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSCIMSourceGroupRequest` + """ + model = PatchedSCIMSourceGroupRequest() + if include_optional: + return PatchedSCIMSourceGroupRequest( + id = '0', + external_id = '0', + group = '', + source = '', + attributes = { + 'key' : null + } + ) + else: + return PatchedSCIMSourceGroupRequest( + ) + """ + + def testPatchedSCIMSourceGroupRequest(self): + """Test PatchedSCIMSourceGroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_scim_source_property_mapping_request.py b/test/test_patched_scim_source_property_mapping_request.py new file mode 100644 index 000000000..93174a015 --- /dev/null +++ b/test/test_patched_scim_source_property_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_scim_source_property_mapping_request import PatchedSCIMSourcePropertyMappingRequest + +class TestPatchedSCIMSourcePropertyMappingRequest(unittest.TestCase): + """PatchedSCIMSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSCIMSourcePropertyMappingRequest: + """Test PatchedSCIMSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSCIMSourcePropertyMappingRequest` + """ + model = PatchedSCIMSourcePropertyMappingRequest() + if include_optional: + return PatchedSCIMSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedSCIMSourcePropertyMappingRequest( + ) + """ + + def testPatchedSCIMSourcePropertyMappingRequest(self): + """Test PatchedSCIMSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_scim_source_request.py b/test/test_patched_scim_source_request.py new file mode 100644 index 000000000..6867c0b15 --- /dev/null +++ b/test/test_patched_scim_source_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_scim_source_request import PatchedSCIMSourceRequest + +class TestPatchedSCIMSourceRequest(unittest.TestCase): + """PatchedSCIMSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSCIMSourceRequest: + """Test PatchedSCIMSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSCIMSourceRequest` + """ + model = PatchedSCIMSourceRequest() + if include_optional: + return PatchedSCIMSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + user_path_template = '0' + ) + else: + return PatchedSCIMSourceRequest( + ) + """ + + def testPatchedSCIMSourceRequest(self): + """Test PatchedSCIMSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_scim_source_user_request.py b/test/test_patched_scim_source_user_request.py new file mode 100644 index 000000000..23a73b6ad --- /dev/null +++ b/test/test_patched_scim_source_user_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_scim_source_user_request import PatchedSCIMSourceUserRequest + +class TestPatchedSCIMSourceUserRequest(unittest.TestCase): + """PatchedSCIMSourceUserRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSCIMSourceUserRequest: + """Test PatchedSCIMSourceUserRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSCIMSourceUserRequest` + """ + model = PatchedSCIMSourceUserRequest() + if include_optional: + return PatchedSCIMSourceUserRequest( + id = '0', + external_id = '0', + user = 56, + source = '', + attributes = { + 'key' : null + } + ) + else: + return PatchedSCIMSourceUserRequest( + ) + """ + + def testPatchedSCIMSourceUserRequest(self): + """Test PatchedSCIMSourceUserRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_scope_mapping_request.py b/test/test_patched_scope_mapping_request.py new file mode 100644 index 000000000..9f2d3d65c --- /dev/null +++ b/test/test_patched_scope_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_scope_mapping_request import PatchedScopeMappingRequest + +class TestPatchedScopeMappingRequest(unittest.TestCase): + """PatchedScopeMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedScopeMappingRequest: + """Test PatchedScopeMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedScopeMappingRequest` + """ + model = PatchedScopeMappingRequest() + if include_optional: + return PatchedScopeMappingRequest( + managed = '0', + name = '0', + expression = '0', + scope_name = '0', + description = '' + ) + else: + return PatchedScopeMappingRequest( + ) + """ + + def testPatchedScopeMappingRequest(self): + """Test PatchedScopeMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_settings_request.py b/test/test_patched_settings_request.py new file mode 100644 index 000000000..332bc592e --- /dev/null +++ b/test/test_patched_settings_request.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_settings_request import PatchedSettingsRequest + +class TestPatchedSettingsRequest(unittest.TestCase): + """PatchedSettingsRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSettingsRequest: + """Test PatchedSettingsRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSettingsRequest` + """ + model = PatchedSettingsRequest() + if include_optional: + return PatchedSettingsRequest( + avatars = '0', + default_user_change_name = True, + default_user_change_email = True, + default_user_change_username = True, + event_retention = '0', + reputation_lower_limit = -2147483648, + reputation_upper_limit = 0, + footer_links = None, + gdpr_compliance = True, + impersonation = True, + impersonation_require_reason = True, + default_token_duration = '0', + default_token_length = 1, + pagination_default_page_size = 0, + pagination_max_page_size = 0, + flags = authentik_client.models.patched_settings_request_flags.PatchedSettingsRequest_flags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True, ) + ) + else: + return PatchedSettingsRequest( + ) + """ + + def testPatchedSettingsRequest(self): + """Test PatchedSettingsRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_settings_request_flags.py b/test/test_patched_settings_request_flags.py new file mode 100644 index 000000000..cbaea2d1e --- /dev/null +++ b/test/test_patched_settings_request_flags.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_settings_request_flags import PatchedSettingsRequestFlags + +class TestPatchedSettingsRequestFlags(unittest.TestCase): + """PatchedSettingsRequestFlags unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSettingsRequestFlags: + """Test PatchedSettingsRequestFlags + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSettingsRequestFlags` + """ + model = PatchedSettingsRequestFlags() + if include_optional: + return PatchedSettingsRequestFlags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True + ) + else: + return PatchedSettingsRequestFlags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True, + ) + """ + + def testPatchedSettingsRequestFlags(self): + """Test PatchedSettingsRequestFlags""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_sms_device_request.py b/test/test_patched_sms_device_request.py new file mode 100644 index 000000000..0a295567b --- /dev/null +++ b/test/test_patched_sms_device_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_sms_device_request import PatchedSMSDeviceRequest + +class TestPatchedSMSDeviceRequest(unittest.TestCase): + """PatchedSMSDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSMSDeviceRequest: + """Test PatchedSMSDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSMSDeviceRequest` + """ + model = PatchedSMSDeviceRequest() + if include_optional: + return PatchedSMSDeviceRequest( + name = '0' + ) + else: + return PatchedSMSDeviceRequest( + ) + """ + + def testPatchedSMSDeviceRequest(self): + """Test PatchedSMSDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_source_stage_request.py b/test/test_patched_source_stage_request.py new file mode 100644 index 000000000..3bb49fddf --- /dev/null +++ b/test/test_patched_source_stage_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_source_stage_request import PatchedSourceStageRequest + +class TestPatchedSourceStageRequest(unittest.TestCase): + """PatchedSourceStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSourceStageRequest: + """Test PatchedSourceStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSourceStageRequest` + """ + model = PatchedSourceStageRequest() + if include_optional: + return PatchedSourceStageRequest( + name = '0', + source = '', + resume_timeout = '0' + ) + else: + return PatchedSourceStageRequest( + ) + """ + + def testPatchedSourceStageRequest(self): + """Test PatchedSourceStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_ssf_provider_request.py b/test/test_patched_ssf_provider_request.py new file mode 100644 index 000000000..d86eb535d --- /dev/null +++ b/test/test_patched_ssf_provider_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_ssf_provider_request import PatchedSSFProviderRequest + +class TestPatchedSSFProviderRequest(unittest.TestCase): + """PatchedSSFProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedSSFProviderRequest: + """Test PatchedSSFProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedSSFProviderRequest` + """ + model = PatchedSSFProviderRequest() + if include_optional: + return PatchedSSFProviderRequest( + name = '0', + signing_key = '', + oidc_auth_providers = [ + 56 + ], + event_retention = '0', + push_verify_certificates = True + ) + else: + return PatchedSSFProviderRequest( + ) + """ + + def testPatchedSSFProviderRequest(self): + """Test PatchedSSFProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_static_device_request.py b/test/test_patched_static_device_request.py new file mode 100644 index 000000000..dc3086021 --- /dev/null +++ b/test/test_patched_static_device_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_static_device_request import PatchedStaticDeviceRequest + +class TestPatchedStaticDeviceRequest(unittest.TestCase): + """PatchedStaticDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedStaticDeviceRequest: + """Test PatchedStaticDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedStaticDeviceRequest` + """ + model = PatchedStaticDeviceRequest() + if include_optional: + return PatchedStaticDeviceRequest( + name = '0' + ) + else: + return PatchedStaticDeviceRequest( + ) + """ + + def testPatchedStaticDeviceRequest(self): + """Test PatchedStaticDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_telegram_source_property_mapping_request.py b/test/test_patched_telegram_source_property_mapping_request.py new file mode 100644 index 000000000..9b06759d3 --- /dev/null +++ b/test/test_patched_telegram_source_property_mapping_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_telegram_source_property_mapping_request import PatchedTelegramSourcePropertyMappingRequest + +class TestPatchedTelegramSourcePropertyMappingRequest(unittest.TestCase): + """PatchedTelegramSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedTelegramSourcePropertyMappingRequest: + """Test PatchedTelegramSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedTelegramSourcePropertyMappingRequest` + """ + model = PatchedTelegramSourcePropertyMappingRequest() + if include_optional: + return PatchedTelegramSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PatchedTelegramSourcePropertyMappingRequest( + ) + """ + + def testPatchedTelegramSourcePropertyMappingRequest(self): + """Test PatchedTelegramSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_telegram_source_request.py b/test/test_patched_telegram_source_request.py new file mode 100644 index 000000000..9389f36a8 --- /dev/null +++ b/test/test_patched_telegram_source_request.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_telegram_source_request import PatchedTelegramSourceRequest + +class TestPatchedTelegramSourceRequest(unittest.TestCase): + """PatchedTelegramSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedTelegramSourceRequest: + """Test PatchedTelegramSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedTelegramSourceRequest` + """ + model = PatchedTelegramSourceRequest() + if include_optional: + return PatchedTelegramSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + bot_username = '0', + bot_token = '0', + request_message_access = True, + pre_authentication_flow = '' + ) + else: + return PatchedTelegramSourceRequest( + ) + """ + + def testPatchedTelegramSourceRequest(self): + """Test PatchedTelegramSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_tenant_request.py b/test/test_patched_tenant_request.py new file mode 100644 index 000000000..6f1ccd0d6 --- /dev/null +++ b/test/test_patched_tenant_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_tenant_request import PatchedTenantRequest + +class TestPatchedTenantRequest(unittest.TestCase): + """PatchedTenantRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedTenantRequest: + """Test PatchedTenantRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedTenantRequest` + """ + model = PatchedTenantRequest() + if include_optional: + return PatchedTenantRequest( + schema_name = '0', + name = '0', + ready = True + ) + else: + return PatchedTenantRequest( + ) + """ + + def testPatchedTenantRequest(self): + """Test PatchedTenantRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_token_request.py b/test/test_patched_token_request.py new file mode 100644 index 000000000..f2704a91e --- /dev/null +++ b/test/test_patched_token_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_token_request import PatchedTokenRequest + +class TestPatchedTokenRequest(unittest.TestCase): + """PatchedTokenRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedTokenRequest: + """Test PatchedTokenRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedTokenRequest` + """ + model = PatchedTokenRequest() + if include_optional: + return PatchedTokenRequest( + managed = '0', + identifier = 'z0', + intent = 'verification', + user = 56, + description = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True + ) + else: + return PatchedTokenRequest( + ) + """ + + def testPatchedTokenRequest(self): + """Test PatchedTokenRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_totp_device_request.py b/test/test_patched_totp_device_request.py new file mode 100644 index 000000000..0e6a31109 --- /dev/null +++ b/test/test_patched_totp_device_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_totp_device_request import PatchedTOTPDeviceRequest + +class TestPatchedTOTPDeviceRequest(unittest.TestCase): + """PatchedTOTPDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedTOTPDeviceRequest: + """Test PatchedTOTPDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedTOTPDeviceRequest` + """ + model = PatchedTOTPDeviceRequest() + if include_optional: + return PatchedTOTPDeviceRequest( + name = '0' + ) + else: + return PatchedTOTPDeviceRequest( + ) + """ + + def testPatchedTOTPDeviceRequest(self): + """Test PatchedTOTPDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_unique_password_policy_request.py b/test/test_patched_unique_password_policy_request.py new file mode 100644 index 000000000..c6236e7e3 --- /dev/null +++ b/test/test_patched_unique_password_policy_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_unique_password_policy_request import PatchedUniquePasswordPolicyRequest + +class TestPatchedUniquePasswordPolicyRequest(unittest.TestCase): + """PatchedUniquePasswordPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUniquePasswordPolicyRequest: + """Test PatchedUniquePasswordPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUniquePasswordPolicyRequest` + """ + model = PatchedUniquePasswordPolicyRequest() + if include_optional: + return PatchedUniquePasswordPolicyRequest( + name = '0', + execution_logging = True, + password_field = '0', + num_historical_passwords = 0 + ) + else: + return PatchedUniquePasswordPolicyRequest( + ) + """ + + def testPatchedUniquePasswordPolicyRequest(self): + """Test PatchedUniquePasswordPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_delete_stage_request.py b/test/test_patched_user_delete_stage_request.py new file mode 100644 index 000000000..ebf531136 --- /dev/null +++ b/test/test_patched_user_delete_stage_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_delete_stage_request import PatchedUserDeleteStageRequest + +class TestPatchedUserDeleteStageRequest(unittest.TestCase): + """PatchedUserDeleteStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserDeleteStageRequest: + """Test PatchedUserDeleteStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserDeleteStageRequest` + """ + model = PatchedUserDeleteStageRequest() + if include_optional: + return PatchedUserDeleteStageRequest( + name = '0' + ) + else: + return PatchedUserDeleteStageRequest( + ) + """ + + def testPatchedUserDeleteStageRequest(self): + """Test PatchedUserDeleteStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_kerberos_source_connection_request.py b/test/test_patched_user_kerberos_source_connection_request.py new file mode 100644 index 000000000..38b5497fe --- /dev/null +++ b/test/test_patched_user_kerberos_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_kerberos_source_connection_request import PatchedUserKerberosSourceConnectionRequest + +class TestPatchedUserKerberosSourceConnectionRequest(unittest.TestCase): + """PatchedUserKerberosSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserKerberosSourceConnectionRequest: + """Test PatchedUserKerberosSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserKerberosSourceConnectionRequest` + """ + model = PatchedUserKerberosSourceConnectionRequest() + if include_optional: + return PatchedUserKerberosSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return PatchedUserKerberosSourceConnectionRequest( + ) + """ + + def testPatchedUserKerberosSourceConnectionRequest(self): + """Test PatchedUserKerberosSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_ldap_source_connection_request.py b/test/test_patched_user_ldap_source_connection_request.py new file mode 100644 index 000000000..01adc9a09 --- /dev/null +++ b/test/test_patched_user_ldap_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_ldap_source_connection_request import PatchedUserLDAPSourceConnectionRequest + +class TestPatchedUserLDAPSourceConnectionRequest(unittest.TestCase): + """PatchedUserLDAPSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserLDAPSourceConnectionRequest: + """Test PatchedUserLDAPSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserLDAPSourceConnectionRequest` + """ + model = PatchedUserLDAPSourceConnectionRequest() + if include_optional: + return PatchedUserLDAPSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return PatchedUserLDAPSourceConnectionRequest( + ) + """ + + def testPatchedUserLDAPSourceConnectionRequest(self): + """Test PatchedUserLDAPSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_login_stage_request.py b/test/test_patched_user_login_stage_request.py new file mode 100644 index 000000000..1c546ebf8 --- /dev/null +++ b/test/test_patched_user_login_stage_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_login_stage_request import PatchedUserLoginStageRequest + +class TestPatchedUserLoginStageRequest(unittest.TestCase): + """PatchedUserLoginStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserLoginStageRequest: + """Test PatchedUserLoginStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserLoginStageRequest` + """ + model = PatchedUserLoginStageRequest() + if include_optional: + return PatchedUserLoginStageRequest( + name = '0', + session_duration = '0', + terminate_other_sessions = True, + remember_me_offset = '0', + network_binding = 'no_binding', + geoip_binding = 'no_binding', + remember_device = '0' + ) + else: + return PatchedUserLoginStageRequest( + ) + """ + + def testPatchedUserLoginStageRequest(self): + """Test PatchedUserLoginStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_logout_stage_request.py b/test/test_patched_user_logout_stage_request.py new file mode 100644 index 000000000..f9e8ffa2d --- /dev/null +++ b/test/test_patched_user_logout_stage_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_logout_stage_request import PatchedUserLogoutStageRequest + +class TestPatchedUserLogoutStageRequest(unittest.TestCase): + """PatchedUserLogoutStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserLogoutStageRequest: + """Test PatchedUserLogoutStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserLogoutStageRequest` + """ + model = PatchedUserLogoutStageRequest() + if include_optional: + return PatchedUserLogoutStageRequest( + name = '0' + ) + else: + return PatchedUserLogoutStageRequest( + ) + """ + + def testPatchedUserLogoutStageRequest(self): + """Test PatchedUserLogoutStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_o_auth_source_connection_request.py b/test/test_patched_user_o_auth_source_connection_request.py new file mode 100644 index 000000000..168af50d2 --- /dev/null +++ b/test/test_patched_user_o_auth_source_connection_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_o_auth_source_connection_request import PatchedUserOAuthSourceConnectionRequest + +class TestPatchedUserOAuthSourceConnectionRequest(unittest.TestCase): + """PatchedUserOAuthSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserOAuthSourceConnectionRequest: + """Test PatchedUserOAuthSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserOAuthSourceConnectionRequest` + """ + model = PatchedUserOAuthSourceConnectionRequest() + if include_optional: + return PatchedUserOAuthSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + access_token = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return PatchedUserOAuthSourceConnectionRequest( + ) + """ + + def testPatchedUserOAuthSourceConnectionRequest(self): + """Test PatchedUserOAuthSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_plex_source_connection_request.py b/test/test_patched_user_plex_source_connection_request.py new file mode 100644 index 000000000..922da6809 --- /dev/null +++ b/test/test_patched_user_plex_source_connection_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_plex_source_connection_request import PatchedUserPlexSourceConnectionRequest + +class TestPatchedUserPlexSourceConnectionRequest(unittest.TestCase): + """PatchedUserPlexSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserPlexSourceConnectionRequest: + """Test PatchedUserPlexSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserPlexSourceConnectionRequest` + """ + model = PatchedUserPlexSourceConnectionRequest() + if include_optional: + return PatchedUserPlexSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + plex_token = '0' + ) + else: + return PatchedUserPlexSourceConnectionRequest( + ) + """ + + def testPatchedUserPlexSourceConnectionRequest(self): + """Test PatchedUserPlexSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_request.py b/test/test_patched_user_request.py new file mode 100644 index 000000000..ea8625cf8 --- /dev/null +++ b/test/test_patched_user_request.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_request import PatchedUserRequest + +class TestPatchedUserRequest(unittest.TestCase): + """PatchedUserRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserRequest: + """Test PatchedUserRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserRequest` + """ + model = PatchedUserRequest() + if include_optional: + return PatchedUserRequest( + username = '0', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + groups = [ + '' + ], + roles = [ + '' + ], + email = '', + attributes = { + 'key' : null + }, + path = '0', + type = 'internal' + ) + else: + return PatchedUserRequest( + ) + """ + + def testPatchedUserRequest(self): + """Test PatchedUserRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_saml_source_connection_request.py b/test/test_patched_user_saml_source_connection_request.py new file mode 100644 index 000000000..2f3db39c4 --- /dev/null +++ b/test/test_patched_user_saml_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_saml_source_connection_request import PatchedUserSAMLSourceConnectionRequest + +class TestPatchedUserSAMLSourceConnectionRequest(unittest.TestCase): + """PatchedUserSAMLSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserSAMLSourceConnectionRequest: + """Test PatchedUserSAMLSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserSAMLSourceConnectionRequest` + """ + model = PatchedUserSAMLSourceConnectionRequest() + if include_optional: + return PatchedUserSAMLSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return PatchedUserSAMLSourceConnectionRequest( + ) + """ + + def testPatchedUserSAMLSourceConnectionRequest(self): + """Test PatchedUserSAMLSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_source_connection_request.py b/test/test_patched_user_source_connection_request.py new file mode 100644 index 000000000..cdc48266c --- /dev/null +++ b/test/test_patched_user_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_source_connection_request import PatchedUserSourceConnectionRequest + +class TestPatchedUserSourceConnectionRequest(unittest.TestCase): + """PatchedUserSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserSourceConnectionRequest: + """Test PatchedUserSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserSourceConnectionRequest` + """ + model = PatchedUserSourceConnectionRequest() + if include_optional: + return PatchedUserSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return PatchedUserSourceConnectionRequest( + ) + """ + + def testPatchedUserSourceConnectionRequest(self): + """Test PatchedUserSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_telegram_source_connection_request.py b/test/test_patched_user_telegram_source_connection_request.py new file mode 100644 index 000000000..9807159fb --- /dev/null +++ b/test/test_patched_user_telegram_source_connection_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_telegram_source_connection_request import PatchedUserTelegramSourceConnectionRequest + +class TestPatchedUserTelegramSourceConnectionRequest(unittest.TestCase): + """PatchedUserTelegramSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserTelegramSourceConnectionRequest: + """Test PatchedUserTelegramSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserTelegramSourceConnectionRequest` + """ + model = PatchedUserTelegramSourceConnectionRequest() + if include_optional: + return PatchedUserTelegramSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return PatchedUserTelegramSourceConnectionRequest( + ) + """ + + def testPatchedUserTelegramSourceConnectionRequest(self): + """Test PatchedUserTelegramSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_user_write_stage_request.py b/test/test_patched_user_write_stage_request.py new file mode 100644 index 000000000..90699de41 --- /dev/null +++ b/test/test_patched_user_write_stage_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_user_write_stage_request import PatchedUserWriteStageRequest + +class TestPatchedUserWriteStageRequest(unittest.TestCase): + """PatchedUserWriteStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedUserWriteStageRequest: + """Test PatchedUserWriteStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedUserWriteStageRequest` + """ + model = PatchedUserWriteStageRequest() + if include_optional: + return PatchedUserWriteStageRequest( + name = '0', + user_creation_mode = 'never_create', + create_users_as_inactive = True, + create_users_group = '', + user_type = 'internal', + user_path_template = '' + ) + else: + return PatchedUserWriteStageRequest( + ) + """ + + def testPatchedUserWriteStageRequest(self): + """Test PatchedUserWriteStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_web_authn_device_request.py b/test/test_patched_web_authn_device_request.py new file mode 100644 index 000000000..5f6b2c894 --- /dev/null +++ b/test/test_patched_web_authn_device_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_web_authn_device_request import PatchedWebAuthnDeviceRequest + +class TestPatchedWebAuthnDeviceRequest(unittest.TestCase): + """PatchedWebAuthnDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedWebAuthnDeviceRequest: + """Test PatchedWebAuthnDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedWebAuthnDeviceRequest` + """ + model = PatchedWebAuthnDeviceRequest() + if include_optional: + return PatchedWebAuthnDeviceRequest( + name = '0' + ) + else: + return PatchedWebAuthnDeviceRequest( + ) + """ + + def testPatchedWebAuthnDeviceRequest(self): + """Test PatchedWebAuthnDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_patched_ws_federation_provider_request.py b/test/test_patched_ws_federation_provider_request.py new file mode 100644 index 000000000..34ecf5bf1 --- /dev/null +++ b/test/test_patched_ws_federation_provider_request.py @@ -0,0 +1,72 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.patched_ws_federation_provider_request import PatchedWSFederationProviderRequest + +class TestPatchedWSFederationProviderRequest(unittest.TestCase): + """PatchedWSFederationProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PatchedWSFederationProviderRequest: + """Test PatchedWSFederationProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PatchedWSFederationProviderRequest` + """ + model = PatchedWSFederationProviderRequest() + if include_optional: + return PatchedWSFederationProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + reply_url = '0', + wtrealm = '0', + assertion_valid_not_before = '0', + assertion_valid_not_on_or_after = '0', + session_valid_not_on_or_after = '0', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_logout_request = True, + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress' + ) + else: + return PatchedWSFederationProviderRequest( + ) + """ + + def testPatchedWSFederationProviderRequest(self): + """Test PatchedWSFederationProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_permission.py b/test/test_permission.py new file mode 100644 index 000000000..3f0b8a82b --- /dev/null +++ b/test/test_permission.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.permission import Permission + +class TestPermission(unittest.TestCase): + """Permission unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Permission: + """Test Permission + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Permission` + """ + model = Permission() + if include_optional: + return Permission( + id = 56, + name = '', + codename = '', + model = '', + app_label = '', + app_label_verbose = '', + model_verbose = '' + ) + else: + return Permission( + id = 56, + name = '', + codename = '', + model = '', + app_label = '', + app_label_verbose = '', + model_verbose = '', + ) + """ + + def testPermission(self): + """Test Permission""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_permission_assign_request.py b/test/test_permission_assign_request.py new file mode 100644 index 000000000..b16c11cc8 --- /dev/null +++ b/test/test_permission_assign_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.permission_assign_request import PermissionAssignRequest + +class TestPermissionAssignRequest(unittest.TestCase): + """PermissionAssignRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PermissionAssignRequest: + """Test PermissionAssignRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PermissionAssignRequest` + """ + model = PermissionAssignRequest() + if include_optional: + return PermissionAssignRequest( + permissions = [ + '0' + ], + model = 'authentik_tenants.domain', + object_pk = '0' + ) + else: + return PermissionAssignRequest( + permissions = [ + '0' + ], + ) + """ + + def testPermissionAssignRequest(self): + """Test PermissionAssignRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_permission_assign_result.py b/test/test_permission_assign_result.py new file mode 100644 index 000000000..bf0758285 --- /dev/null +++ b/test/test_permission_assign_result.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.permission_assign_result import PermissionAssignResult + +class TestPermissionAssignResult(unittest.TestCase): + """PermissionAssignResult unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PermissionAssignResult: + """Test PermissionAssignResult + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PermissionAssignResult` + """ + model = PermissionAssignResult() + if include_optional: + return PermissionAssignResult( + id = '' + ) + else: + return PermissionAssignResult( + id = '', + ) + """ + + def testPermissionAssignResult(self): + """Test PermissionAssignResult""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_pkce_method_enum.py b/test/test_pkce_method_enum.py new file mode 100644 index 000000000..974c35f8b --- /dev/null +++ b/test/test_pkce_method_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.pkce_method_enum import PKCEMethodEnum + +class TestPKCEMethodEnum(unittest.TestCase): + """PKCEMethodEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testPKCEMethodEnum(self): + """Test PKCEMethodEnum""" + # inst = PKCEMethodEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_plex_authentication_challenge.py b/test/test_plex_authentication_challenge.py new file mode 100644 index 000000000..18270e4fd --- /dev/null +++ b/test/test_plex_authentication_challenge.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.plex_authentication_challenge import PlexAuthenticationChallenge + +class TestPlexAuthenticationChallenge(unittest.TestCase): + """PlexAuthenticationChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PlexAuthenticationChallenge: + """Test PlexAuthenticationChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PlexAuthenticationChallenge` + """ + model = PlexAuthenticationChallenge() + if include_optional: + return PlexAuthenticationChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-source-plex', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + client_id = '', + slug = '' + ) + else: + return PlexAuthenticationChallenge( + client_id = '', + slug = '', + ) + """ + + def testPlexAuthenticationChallenge(self): + """Test PlexAuthenticationChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_plex_authentication_challenge_response_request.py b/test/test_plex_authentication_challenge_response_request.py new file mode 100644 index 000000000..386b8a262 --- /dev/null +++ b/test/test_plex_authentication_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.plex_authentication_challenge_response_request import PlexAuthenticationChallengeResponseRequest + +class TestPlexAuthenticationChallengeResponseRequest(unittest.TestCase): + """PlexAuthenticationChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PlexAuthenticationChallengeResponseRequest: + """Test PlexAuthenticationChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PlexAuthenticationChallengeResponseRequest` + """ + model = PlexAuthenticationChallengeResponseRequest() + if include_optional: + return PlexAuthenticationChallengeResponseRequest( + component = 'ak-source-plex' + ) + else: + return PlexAuthenticationChallengeResponseRequest( + ) + """ + + def testPlexAuthenticationChallengeResponseRequest(self): + """Test PlexAuthenticationChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_plex_source.py b/test/test_plex_source.py new file mode 100644 index 000000000..90c8c200e --- /dev/null +++ b/test/test_plex_source.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.plex_source import PlexSource + +class TestPlexSource(unittest.TestCase): + """PlexSource unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PlexSource: + """Test PlexSource + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PlexSource` + """ + model = PlexSource() + if include_optional: + return PlexSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + group_matching_mode = 'identifier', + client_id = '', + allowed_servers = [ + '' + ], + allow_friends = True, + plex_token = '' + ) + else: + return PlexSource( + pk = '', + name = '', + slug = 'z', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + plex_token = '', + ) + """ + + def testPlexSource(self): + """Test PlexSource""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_plex_source_property_mapping.py b/test/test_plex_source_property_mapping.py new file mode 100644 index 000000000..bd09795e1 --- /dev/null +++ b/test/test_plex_source_property_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.plex_source_property_mapping import PlexSourcePropertyMapping + +class TestPlexSourcePropertyMapping(unittest.TestCase): + """PlexSourcePropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PlexSourcePropertyMapping: + """Test PlexSourcePropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PlexSourcePropertyMapping` + """ + model = PlexSourcePropertyMapping() + if include_optional: + return PlexSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return PlexSourcePropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testPlexSourcePropertyMapping(self): + """Test PlexSourcePropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_plex_source_property_mapping_request.py b/test/test_plex_source_property_mapping_request.py new file mode 100644 index 000000000..c53f3f419 --- /dev/null +++ b/test/test_plex_source_property_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.plex_source_property_mapping_request import PlexSourcePropertyMappingRequest + +class TestPlexSourcePropertyMappingRequest(unittest.TestCase): + """PlexSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PlexSourcePropertyMappingRequest: + """Test PlexSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PlexSourcePropertyMappingRequest` + """ + model = PlexSourcePropertyMappingRequest() + if include_optional: + return PlexSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return PlexSourcePropertyMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testPlexSourcePropertyMappingRequest(self): + """Test PlexSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_plex_source_request.py b/test/test_plex_source_request.py new file mode 100644 index 000000000..9269d1df8 --- /dev/null +++ b/test/test_plex_source_request.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.plex_source_request import PlexSourceRequest + +class TestPlexSourceRequest(unittest.TestCase): + """PlexSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PlexSourceRequest: + """Test PlexSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PlexSourceRequest` + """ + model = PlexSourceRequest() + if include_optional: + return PlexSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + group_matching_mode = 'identifier', + client_id = '0', + allowed_servers = [ + '0' + ], + allow_friends = True, + plex_token = '0' + ) + else: + return PlexSourceRequest( + name = '0', + slug = 'z0', + plex_token = '0', + ) + """ + + def testPlexSourceRequest(self): + """Test PlexSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_plex_token_redeem_request.py b/test/test_plex_token_redeem_request.py new file mode 100644 index 000000000..8570e5a09 --- /dev/null +++ b/test/test_plex_token_redeem_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.plex_token_redeem_request import PlexTokenRedeemRequest + +class TestPlexTokenRedeemRequest(unittest.TestCase): + """PlexTokenRedeemRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PlexTokenRedeemRequest: + """Test PlexTokenRedeemRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PlexTokenRedeemRequest` + """ + model = PlexTokenRedeemRequest() + if include_optional: + return PlexTokenRedeemRequest( + plex_token = '0' + ) + else: + return PlexTokenRedeemRequest( + plex_token = '0', + ) + """ + + def testPlexTokenRedeemRequest(self): + """Test PlexTokenRedeemRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_policies_api.py b/test/test_policies_api.py new file mode 100644 index 000000000..1b979cbdd --- /dev/null +++ b/test/test_policies_api.py @@ -0,0 +1,488 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.policies_api import PoliciesApi + + +class TestPoliciesApi(unittest.TestCase): + """PoliciesApi unit test stubs""" + + def setUp(self) -> None: + self.api = PoliciesApi() + + def tearDown(self) -> None: + pass + + def test_policies_all_cache_clear_create(self) -> None: + """Test case for policies_all_cache_clear_create + + """ + pass + + def test_policies_all_cache_info_retrieve(self) -> None: + """Test case for policies_all_cache_info_retrieve + + """ + pass + + def test_policies_all_destroy(self) -> None: + """Test case for policies_all_destroy + + """ + pass + + def test_policies_all_list(self) -> None: + """Test case for policies_all_list + + """ + pass + + def test_policies_all_retrieve(self) -> None: + """Test case for policies_all_retrieve + + """ + pass + + def test_policies_all_test_create(self) -> None: + """Test case for policies_all_test_create + + """ + pass + + def test_policies_all_types_list(self) -> None: + """Test case for policies_all_types_list + + """ + pass + + def test_policies_all_used_by_list(self) -> None: + """Test case for policies_all_used_by_list + + """ + pass + + def test_policies_bindings_create(self) -> None: + """Test case for policies_bindings_create + + """ + pass + + def test_policies_bindings_destroy(self) -> None: + """Test case for policies_bindings_destroy + + """ + pass + + def test_policies_bindings_list(self) -> None: + """Test case for policies_bindings_list + + """ + pass + + def test_policies_bindings_partial_update(self) -> None: + """Test case for policies_bindings_partial_update + + """ + pass + + def test_policies_bindings_retrieve(self) -> None: + """Test case for policies_bindings_retrieve + + """ + pass + + def test_policies_bindings_update(self) -> None: + """Test case for policies_bindings_update + + """ + pass + + def test_policies_bindings_used_by_list(self) -> None: + """Test case for policies_bindings_used_by_list + + """ + pass + + def test_policies_dummy_create(self) -> None: + """Test case for policies_dummy_create + + """ + pass + + def test_policies_dummy_destroy(self) -> None: + """Test case for policies_dummy_destroy + + """ + pass + + def test_policies_dummy_list(self) -> None: + """Test case for policies_dummy_list + + """ + pass + + def test_policies_dummy_partial_update(self) -> None: + """Test case for policies_dummy_partial_update + + """ + pass + + def test_policies_dummy_retrieve(self) -> None: + """Test case for policies_dummy_retrieve + + """ + pass + + def test_policies_dummy_update(self) -> None: + """Test case for policies_dummy_update + + """ + pass + + def test_policies_dummy_used_by_list(self) -> None: + """Test case for policies_dummy_used_by_list + + """ + pass + + def test_policies_event_matcher_create(self) -> None: + """Test case for policies_event_matcher_create + + """ + pass + + def test_policies_event_matcher_destroy(self) -> None: + """Test case for policies_event_matcher_destroy + + """ + pass + + def test_policies_event_matcher_list(self) -> None: + """Test case for policies_event_matcher_list + + """ + pass + + def test_policies_event_matcher_partial_update(self) -> None: + """Test case for policies_event_matcher_partial_update + + """ + pass + + def test_policies_event_matcher_retrieve(self) -> None: + """Test case for policies_event_matcher_retrieve + + """ + pass + + def test_policies_event_matcher_update(self) -> None: + """Test case for policies_event_matcher_update + + """ + pass + + def test_policies_event_matcher_used_by_list(self) -> None: + """Test case for policies_event_matcher_used_by_list + + """ + pass + + def test_policies_expression_create(self) -> None: + """Test case for policies_expression_create + + """ + pass + + def test_policies_expression_destroy(self) -> None: + """Test case for policies_expression_destroy + + """ + pass + + def test_policies_expression_list(self) -> None: + """Test case for policies_expression_list + + """ + pass + + def test_policies_expression_partial_update(self) -> None: + """Test case for policies_expression_partial_update + + """ + pass + + def test_policies_expression_retrieve(self) -> None: + """Test case for policies_expression_retrieve + + """ + pass + + def test_policies_expression_update(self) -> None: + """Test case for policies_expression_update + + """ + pass + + def test_policies_expression_used_by_list(self) -> None: + """Test case for policies_expression_used_by_list + + """ + pass + + def test_policies_geoip_create(self) -> None: + """Test case for policies_geoip_create + + """ + pass + + def test_policies_geoip_destroy(self) -> None: + """Test case for policies_geoip_destroy + + """ + pass + + def test_policies_geoip_iso3166_list(self) -> None: + """Test case for policies_geoip_iso3166_list + + """ + pass + + def test_policies_geoip_list(self) -> None: + """Test case for policies_geoip_list + + """ + pass + + def test_policies_geoip_partial_update(self) -> None: + """Test case for policies_geoip_partial_update + + """ + pass + + def test_policies_geoip_retrieve(self) -> None: + """Test case for policies_geoip_retrieve + + """ + pass + + def test_policies_geoip_update(self) -> None: + """Test case for policies_geoip_update + + """ + pass + + def test_policies_geoip_used_by_list(self) -> None: + """Test case for policies_geoip_used_by_list + + """ + pass + + def test_policies_password_create(self) -> None: + """Test case for policies_password_create + + """ + pass + + def test_policies_password_destroy(self) -> None: + """Test case for policies_password_destroy + + """ + pass + + def test_policies_password_expiry_create(self) -> None: + """Test case for policies_password_expiry_create + + """ + pass + + def test_policies_password_expiry_destroy(self) -> None: + """Test case for policies_password_expiry_destroy + + """ + pass + + def test_policies_password_expiry_list(self) -> None: + """Test case for policies_password_expiry_list + + """ + pass + + def test_policies_password_expiry_partial_update(self) -> None: + """Test case for policies_password_expiry_partial_update + + """ + pass + + def test_policies_password_expiry_retrieve(self) -> None: + """Test case for policies_password_expiry_retrieve + + """ + pass + + def test_policies_password_expiry_update(self) -> None: + """Test case for policies_password_expiry_update + + """ + pass + + def test_policies_password_expiry_used_by_list(self) -> None: + """Test case for policies_password_expiry_used_by_list + + """ + pass + + def test_policies_password_list(self) -> None: + """Test case for policies_password_list + + """ + pass + + def test_policies_password_partial_update(self) -> None: + """Test case for policies_password_partial_update + + """ + pass + + def test_policies_password_retrieve(self) -> None: + """Test case for policies_password_retrieve + + """ + pass + + def test_policies_password_update(self) -> None: + """Test case for policies_password_update + + """ + pass + + def test_policies_password_used_by_list(self) -> None: + """Test case for policies_password_used_by_list + + """ + pass + + def test_policies_reputation_create(self) -> None: + """Test case for policies_reputation_create + + """ + pass + + def test_policies_reputation_destroy(self) -> None: + """Test case for policies_reputation_destroy + + """ + pass + + def test_policies_reputation_list(self) -> None: + """Test case for policies_reputation_list + + """ + pass + + def test_policies_reputation_partial_update(self) -> None: + """Test case for policies_reputation_partial_update + + """ + pass + + def test_policies_reputation_retrieve(self) -> None: + """Test case for policies_reputation_retrieve + + """ + pass + + def test_policies_reputation_scores_destroy(self) -> None: + """Test case for policies_reputation_scores_destroy + + """ + pass + + def test_policies_reputation_scores_list(self) -> None: + """Test case for policies_reputation_scores_list + + """ + pass + + def test_policies_reputation_scores_retrieve(self) -> None: + """Test case for policies_reputation_scores_retrieve + + """ + pass + + def test_policies_reputation_scores_used_by_list(self) -> None: + """Test case for policies_reputation_scores_used_by_list + + """ + pass + + def test_policies_reputation_update(self) -> None: + """Test case for policies_reputation_update + + """ + pass + + def test_policies_reputation_used_by_list(self) -> None: + """Test case for policies_reputation_used_by_list + + """ + pass + + def test_policies_unique_password_create(self) -> None: + """Test case for policies_unique_password_create + + """ + pass + + def test_policies_unique_password_destroy(self) -> None: + """Test case for policies_unique_password_destroy + + """ + pass + + def test_policies_unique_password_list(self) -> None: + """Test case for policies_unique_password_list + + """ + pass + + def test_policies_unique_password_partial_update(self) -> None: + """Test case for policies_unique_password_partial_update + + """ + pass + + def test_policies_unique_password_retrieve(self) -> None: + """Test case for policies_unique_password_retrieve + + """ + pass + + def test_policies_unique_password_update(self) -> None: + """Test case for policies_unique_password_update + + """ + pass + + def test_policies_unique_password_used_by_list(self) -> None: + """Test case for policies_unique_password_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_policy.py b/test/test_policy.py new file mode 100644 index 000000000..e2d435bff --- /dev/null +++ b/test/test_policy.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.policy import Policy + +class TestPolicy(unittest.TestCase): + """Policy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Policy: + """Test Policy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Policy` + """ + model = Policy() + if include_optional: + return Policy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56 + ) + else: + return Policy( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + ) + """ + + def testPolicy(self): + """Test Policy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_policy_binding.py b/test/test_policy_binding.py new file mode 100644 index 000000000..7e0a53fa2 --- /dev/null +++ b/test/test_policy_binding.py @@ -0,0 +1,120 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.policy_binding import PolicyBinding + +class TestPolicyBinding(unittest.TestCase): + """PolicyBinding unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PolicyBinding: + """Test PolicyBinding + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PolicyBinding` + """ + model = PolicyBinding() + if include_optional: + return PolicyBinding( + pk = '', + policy = '', + group = '', + user = 56, + policy_obj = authentik_client.models.policy.Policy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, ), + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True + ) + else: + return PolicyBinding( + pk = '', + policy_obj = authentik_client.models.policy.Policy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, ), + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + target = '', + order = -2147483648, + ) + """ + + def testPolicyBinding(self): + """Test PolicyBinding""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_policy_binding_request.py b/test/test_policy_binding_request.py new file mode 100644 index 000000000..13fcd0b0c --- /dev/null +++ b/test/test_policy_binding_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.policy_binding_request import PolicyBindingRequest + +class TestPolicyBindingRequest(unittest.TestCase): + """PolicyBindingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PolicyBindingRequest: + """Test PolicyBindingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PolicyBindingRequest` + """ + model = PolicyBindingRequest() + if include_optional: + return PolicyBindingRequest( + policy = '', + group = '', + user = 56, + target = '', + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True + ) + else: + return PolicyBindingRequest( + target = '', + order = -2147483648, + ) + """ + + def testPolicyBindingRequest(self): + """Test PolicyBindingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_policy_engine_mode.py b/test/test_policy_engine_mode.py new file mode 100644 index 000000000..3a7e953b1 --- /dev/null +++ b/test/test_policy_engine_mode.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.policy_engine_mode import PolicyEngineMode + +class TestPolicyEngineMode(unittest.TestCase): + """PolicyEngineMode unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testPolicyEngineMode(self): + """Test PolicyEngineMode""" + # inst = PolicyEngineMode() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_policy_test_request.py b/test/test_policy_test_request.py new file mode 100644 index 000000000..3596752af --- /dev/null +++ b/test/test_policy_test_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.policy_test_request import PolicyTestRequest + +class TestPolicyTestRequest(unittest.TestCase): + """PolicyTestRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PolicyTestRequest: + """Test PolicyTestRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PolicyTestRequest` + """ + model = PolicyTestRequest() + if include_optional: + return PolicyTestRequest( + user = 56, + context = { + 'key' : null + } + ) + else: + return PolicyTestRequest( + user = 56, + ) + """ + + def testPolicyTestRequest(self): + """Test PolicyTestRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_policy_test_result.py b/test/test_policy_test_result.py new file mode 100644 index 000000000..5bd19ef2e --- /dev/null +++ b/test/test_policy_test_result.py @@ -0,0 +1,79 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.policy_test_result import PolicyTestResult + +class TestPolicyTestResult(unittest.TestCase): + """PolicyTestResult unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PolicyTestResult: + """Test PolicyTestResult + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PolicyTestResult` + """ + model = PolicyTestResult() + if include_optional: + return PolicyTestResult( + passing = True, + messages = [ + '' + ], + log_messages = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ] + ) + else: + return PolicyTestResult( + passing = True, + messages = [ + '' + ], + log_messages = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + ) + """ + + def testPolicyTestResult(self): + """Test PolicyTestResult""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_process.py b/test/test_process.py new file mode 100644 index 000000000..d2542a2c6 --- /dev/null +++ b/test/test_process.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.process import Process + +class TestProcess(unittest.TestCase): + """Process unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Process: + """Test Process + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Process` + """ + model = Process() + if include_optional: + return Process( + id = 56, + name = '', + user = '' + ) + else: + return Process( + id = 56, + name = '', + ) + """ + + def testProcess(self): + """Test Process""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_process_request.py b/test/test_process_request.py new file mode 100644 index 000000000..8ac2dc40f --- /dev/null +++ b/test/test_process_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.process_request import ProcessRequest + +class TestProcessRequest(unittest.TestCase): + """ProcessRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ProcessRequest: + """Test ProcessRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ProcessRequest` + """ + model = ProcessRequest() + if include_optional: + return ProcessRequest( + id = 56, + name = '0', + user = '0' + ) + else: + return ProcessRequest( + id = 56, + name = '0', + ) + """ + + def testProcessRequest(self): + """Test ProcessRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_prompt.py b/test/test_prompt.py new file mode 100644 index 000000000..5490ba919 --- /dev/null +++ b/test/test_prompt.py @@ -0,0 +1,128 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.prompt import Prompt + +class TestPrompt(unittest.TestCase): + """Prompt unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Prompt: + """Test Prompt + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Prompt` + """ + model = Prompt() + if include_optional: + return Prompt( + pk = '', + name = '', + field_key = '', + label = '', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = -2147483648, + prompt_stages_obj = [ + authentik_client.models.prompt_stage.PromptStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + fields = [ + '' + ], + validation_policies = [ + '' + ], ) + ], + sub_text = '', + placeholder_expression = True, + initial_value_expression = True + ) + else: + return Prompt( + pk = '', + name = '', + field_key = '', + label = '', + type = 'text', + prompt_stages_obj = [ + authentik_client.models.prompt_stage.PromptStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + fields = [ + '' + ], + validation_policies = [ + '' + ], ) + ], + ) + """ + + def testPrompt(self): + """Test Prompt""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_prompt_challenge.py b/test/test_prompt_challenge.py new file mode 100644 index 000000000..0d1d8691a --- /dev/null +++ b/test/test_prompt_challenge.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.prompt_challenge import PromptChallenge + +class TestPromptChallenge(unittest.TestCase): + """PromptChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PromptChallenge: + """Test PromptChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PromptChallenge` + """ + model = PromptChallenge() + if include_optional: + return PromptChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-prompt', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + fields = [ + authentik_client.models.stage_prompt.StagePrompt( + field_key = '', + label = '', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = 56, + sub_text = '', + choices = [ + authentik_client.models.prompt_choice.PromptChoice( + value = '', + label = '', ) + ], ) + ] + ) + else: + return PromptChallenge( + fields = [ + authentik_client.models.stage_prompt.StagePrompt( + field_key = '', + label = '', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = 56, + sub_text = '', + choices = [ + authentik_client.models.prompt_choice.PromptChoice( + value = '', + label = '', ) + ], ) + ], + ) + """ + + def testPromptChallenge(self): + """Test PromptChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_prompt_challenge_response_request.py b/test/test_prompt_challenge_response_request.py new file mode 100644 index 000000000..d97ca6506 --- /dev/null +++ b/test/test_prompt_challenge_response_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.prompt_challenge_response_request import PromptChallengeResponseRequest + +class TestPromptChallengeResponseRequest(unittest.TestCase): + """PromptChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PromptChallengeResponseRequest: + """Test PromptChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PromptChallengeResponseRequest` + """ + model = PromptChallengeResponseRequest() + if include_optional: + return PromptChallengeResponseRequest( + component = 'ak-stage-prompt' + ) + else: + return PromptChallengeResponseRequest( + ) + """ + + def testPromptChallengeResponseRequest(self): + """Test PromptChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_prompt_choice.py b/test/test_prompt_choice.py new file mode 100644 index 000000000..07292f95a --- /dev/null +++ b/test/test_prompt_choice.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.prompt_choice import PromptChoice + +class TestPromptChoice(unittest.TestCase): + """PromptChoice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PromptChoice: + """Test PromptChoice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PromptChoice` + """ + model = PromptChoice() + if include_optional: + return PromptChoice( + value = '', + label = '' + ) + else: + return PromptChoice( + value = '', + label = '', + ) + """ + + def testPromptChoice(self): + """Test PromptChoice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_prompt_request.py b/test/test_prompt_request.py new file mode 100644 index 000000000..2fa25f3c3 --- /dev/null +++ b/test/test_prompt_request.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.prompt_request import PromptRequest + +class TestPromptRequest(unittest.TestCase): + """PromptRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PromptRequest: + """Test PromptRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PromptRequest` + """ + model = PromptRequest() + if include_optional: + return PromptRequest( + name = '0', + field_key = '0', + label = '0', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = -2147483648, + sub_text = '', + placeholder_expression = True, + initial_value_expression = True + ) + else: + return PromptRequest( + name = '0', + field_key = '0', + label = '0', + type = 'text', + ) + """ + + def testPromptRequest(self): + """Test PromptRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_prompt_stage.py b/test/test_prompt_stage.py new file mode 100644 index 000000000..f09813b78 --- /dev/null +++ b/test/test_prompt_stage.py @@ -0,0 +1,102 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.prompt_stage import PromptStage + +class TestPromptStage(unittest.TestCase): + """PromptStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PromptStage: + """Test PromptStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PromptStage` + """ + model = PromptStage() + if include_optional: + return PromptStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + fields = [ + '' + ], + validation_policies = [ + '' + ] + ) + else: + return PromptStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + fields = [ + '' + ], + ) + """ + + def testPromptStage(self): + """Test PromptStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_prompt_stage_request.py b/test/test_prompt_stage_request.py new file mode 100644 index 000000000..ab6d4d19e --- /dev/null +++ b/test/test_prompt_stage_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.prompt_stage_request import PromptStageRequest + +class TestPromptStageRequest(unittest.TestCase): + """PromptStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PromptStageRequest: + """Test PromptStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PromptStageRequest` + """ + model = PromptStageRequest() + if include_optional: + return PromptStageRequest( + name = '0', + fields = [ + '' + ], + validation_policies = [ + '' + ] + ) + else: + return PromptStageRequest( + name = '0', + fields = [ + '' + ], + ) + """ + + def testPromptStageRequest(self): + """Test PromptStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_prompt_type_enum.py b/test/test_prompt_type_enum.py new file mode 100644 index 000000000..4777c5736 --- /dev/null +++ b/test/test_prompt_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.prompt_type_enum import PromptTypeEnum + +class TestPromptTypeEnum(unittest.TestCase): + """PromptTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testPromptTypeEnum(self): + """Test PromptTypeEnum""" + # inst = PromptTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_property_mapping.py b/test/test_property_mapping.py new file mode 100644 index 000000000..524d0266d --- /dev/null +++ b/test/test_property_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.property_mapping import PropertyMapping + +class TestPropertyMapping(unittest.TestCase): + """PropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PropertyMapping: + """Test PropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PropertyMapping` + """ + model = PropertyMapping() + if include_optional: + return PropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return PropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testPropertyMapping(self): + """Test PropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_property_mapping_preview.py b/test/test_property_mapping_preview.py new file mode 100644 index 000000000..12f1ad5bf --- /dev/null +++ b/test/test_property_mapping_preview.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.property_mapping_preview import PropertyMappingPreview + +class TestPropertyMappingPreview(unittest.TestCase): + """PropertyMappingPreview unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PropertyMappingPreview: + """Test PropertyMappingPreview + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PropertyMappingPreview` + """ + model = PropertyMappingPreview() + if include_optional: + return PropertyMappingPreview( + preview = { + 'key' : null + } + ) + else: + return PropertyMappingPreview( + preview = { + 'key' : null + }, + ) + """ + + def testPropertyMappingPreview(self): + """Test PropertyMappingPreview""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_property_mapping_test_request.py b/test/test_property_mapping_test_request.py new file mode 100644 index 000000000..7b9f26bc8 --- /dev/null +++ b/test/test_property_mapping_test_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.property_mapping_test_request import PropertyMappingTestRequest + +class TestPropertyMappingTestRequest(unittest.TestCase): + """PropertyMappingTestRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PropertyMappingTestRequest: + """Test PropertyMappingTestRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PropertyMappingTestRequest` + """ + model = PropertyMappingTestRequest() + if include_optional: + return PropertyMappingTestRequest( + user = 56, + context = { + 'key' : null + }, + group = '' + ) + else: + return PropertyMappingTestRequest( + ) + """ + + def testPropertyMappingTestRequest(self): + """Test PropertyMappingTestRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_property_mapping_test_result.py b/test/test_property_mapping_test_result.py new file mode 100644 index 000000000..b8b00304e --- /dev/null +++ b/test/test_property_mapping_test_result.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.property_mapping_test_result import PropertyMappingTestResult + +class TestPropertyMappingTestResult(unittest.TestCase): + """PropertyMappingTestResult unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> PropertyMappingTestResult: + """Test PropertyMappingTestResult + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `PropertyMappingTestResult` + """ + model = PropertyMappingTestResult() + if include_optional: + return PropertyMappingTestResult( + result = '', + successful = True + ) + else: + return PropertyMappingTestResult( + result = '', + successful = True, + ) + """ + + def testPropertyMappingTestResult(self): + """Test PropertyMappingTestResult""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_propertymappings_api.py b/test/test_propertymappings_api.py new file mode 100644 index 000000000..36a49f75b --- /dev/null +++ b/test/test_propertymappings_api.py @@ -0,0 +1,698 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.propertymappings_api import PropertymappingsApi + + +class TestPropertymappingsApi(unittest.TestCase): + """PropertymappingsApi unit test stubs""" + + def setUp(self) -> None: + self.api = PropertymappingsApi() + + def tearDown(self) -> None: + pass + + def test_propertymappings_all_destroy(self) -> None: + """Test case for propertymappings_all_destroy + + """ + pass + + def test_propertymappings_all_list(self) -> None: + """Test case for propertymappings_all_list + + """ + pass + + def test_propertymappings_all_retrieve(self) -> None: + """Test case for propertymappings_all_retrieve + + """ + pass + + def test_propertymappings_all_test_create(self) -> None: + """Test case for propertymappings_all_test_create + + """ + pass + + def test_propertymappings_all_types_list(self) -> None: + """Test case for propertymappings_all_types_list + + """ + pass + + def test_propertymappings_all_used_by_list(self) -> None: + """Test case for propertymappings_all_used_by_list + + """ + pass + + def test_propertymappings_notification_create(self) -> None: + """Test case for propertymappings_notification_create + + """ + pass + + def test_propertymappings_notification_destroy(self) -> None: + """Test case for propertymappings_notification_destroy + + """ + pass + + def test_propertymappings_notification_list(self) -> None: + """Test case for propertymappings_notification_list + + """ + pass + + def test_propertymappings_notification_partial_update(self) -> None: + """Test case for propertymappings_notification_partial_update + + """ + pass + + def test_propertymappings_notification_retrieve(self) -> None: + """Test case for propertymappings_notification_retrieve + + """ + pass + + def test_propertymappings_notification_update(self) -> None: + """Test case for propertymappings_notification_update + + """ + pass + + def test_propertymappings_notification_used_by_list(self) -> None: + """Test case for propertymappings_notification_used_by_list + + """ + pass + + def test_propertymappings_provider_google_workspace_create(self) -> None: + """Test case for propertymappings_provider_google_workspace_create + + """ + pass + + def test_propertymappings_provider_google_workspace_destroy(self) -> None: + """Test case for propertymappings_provider_google_workspace_destroy + + """ + pass + + def test_propertymappings_provider_google_workspace_list(self) -> None: + """Test case for propertymappings_provider_google_workspace_list + + """ + pass + + def test_propertymappings_provider_google_workspace_partial_update(self) -> None: + """Test case for propertymappings_provider_google_workspace_partial_update + + """ + pass + + def test_propertymappings_provider_google_workspace_retrieve(self) -> None: + """Test case for propertymappings_provider_google_workspace_retrieve + + """ + pass + + def test_propertymappings_provider_google_workspace_update(self) -> None: + """Test case for propertymappings_provider_google_workspace_update + + """ + pass + + def test_propertymappings_provider_google_workspace_used_by_list(self) -> None: + """Test case for propertymappings_provider_google_workspace_used_by_list + + """ + pass + + def test_propertymappings_provider_microsoft_entra_create(self) -> None: + """Test case for propertymappings_provider_microsoft_entra_create + + """ + pass + + def test_propertymappings_provider_microsoft_entra_destroy(self) -> None: + """Test case for propertymappings_provider_microsoft_entra_destroy + + """ + pass + + def test_propertymappings_provider_microsoft_entra_list(self) -> None: + """Test case for propertymappings_provider_microsoft_entra_list + + """ + pass + + def test_propertymappings_provider_microsoft_entra_partial_update(self) -> None: + """Test case for propertymappings_provider_microsoft_entra_partial_update + + """ + pass + + def test_propertymappings_provider_microsoft_entra_retrieve(self) -> None: + """Test case for propertymappings_provider_microsoft_entra_retrieve + + """ + pass + + def test_propertymappings_provider_microsoft_entra_update(self) -> None: + """Test case for propertymappings_provider_microsoft_entra_update + + """ + pass + + def test_propertymappings_provider_microsoft_entra_used_by_list(self) -> None: + """Test case for propertymappings_provider_microsoft_entra_used_by_list + + """ + pass + + def test_propertymappings_provider_rac_create(self) -> None: + """Test case for propertymappings_provider_rac_create + + """ + pass + + def test_propertymappings_provider_rac_destroy(self) -> None: + """Test case for propertymappings_provider_rac_destroy + + """ + pass + + def test_propertymappings_provider_rac_list(self) -> None: + """Test case for propertymappings_provider_rac_list + + """ + pass + + def test_propertymappings_provider_rac_partial_update(self) -> None: + """Test case for propertymappings_provider_rac_partial_update + + """ + pass + + def test_propertymappings_provider_rac_retrieve(self) -> None: + """Test case for propertymappings_provider_rac_retrieve + + """ + pass + + def test_propertymappings_provider_rac_update(self) -> None: + """Test case for propertymappings_provider_rac_update + + """ + pass + + def test_propertymappings_provider_rac_used_by_list(self) -> None: + """Test case for propertymappings_provider_rac_used_by_list + + """ + pass + + def test_propertymappings_provider_radius_create(self) -> None: + """Test case for propertymappings_provider_radius_create + + """ + pass + + def test_propertymappings_provider_radius_destroy(self) -> None: + """Test case for propertymappings_provider_radius_destroy + + """ + pass + + def test_propertymappings_provider_radius_list(self) -> None: + """Test case for propertymappings_provider_radius_list + + """ + pass + + def test_propertymappings_provider_radius_partial_update(self) -> None: + """Test case for propertymappings_provider_radius_partial_update + + """ + pass + + def test_propertymappings_provider_radius_retrieve(self) -> None: + """Test case for propertymappings_provider_radius_retrieve + + """ + pass + + def test_propertymappings_provider_radius_update(self) -> None: + """Test case for propertymappings_provider_radius_update + + """ + pass + + def test_propertymappings_provider_radius_used_by_list(self) -> None: + """Test case for propertymappings_provider_radius_used_by_list + + """ + pass + + def test_propertymappings_provider_saml_create(self) -> None: + """Test case for propertymappings_provider_saml_create + + """ + pass + + def test_propertymappings_provider_saml_destroy(self) -> None: + """Test case for propertymappings_provider_saml_destroy + + """ + pass + + def test_propertymappings_provider_saml_list(self) -> None: + """Test case for propertymappings_provider_saml_list + + """ + pass + + def test_propertymappings_provider_saml_partial_update(self) -> None: + """Test case for propertymappings_provider_saml_partial_update + + """ + pass + + def test_propertymappings_provider_saml_retrieve(self) -> None: + """Test case for propertymappings_provider_saml_retrieve + + """ + pass + + def test_propertymappings_provider_saml_update(self) -> None: + """Test case for propertymappings_provider_saml_update + + """ + pass + + def test_propertymappings_provider_saml_used_by_list(self) -> None: + """Test case for propertymappings_provider_saml_used_by_list + + """ + pass + + def test_propertymappings_provider_scim_create(self) -> None: + """Test case for propertymappings_provider_scim_create + + """ + pass + + def test_propertymappings_provider_scim_destroy(self) -> None: + """Test case for propertymappings_provider_scim_destroy + + """ + pass + + def test_propertymappings_provider_scim_list(self) -> None: + """Test case for propertymappings_provider_scim_list + + """ + pass + + def test_propertymappings_provider_scim_partial_update(self) -> None: + """Test case for propertymappings_provider_scim_partial_update + + """ + pass + + def test_propertymappings_provider_scim_retrieve(self) -> None: + """Test case for propertymappings_provider_scim_retrieve + + """ + pass + + def test_propertymappings_provider_scim_update(self) -> None: + """Test case for propertymappings_provider_scim_update + + """ + pass + + def test_propertymappings_provider_scim_used_by_list(self) -> None: + """Test case for propertymappings_provider_scim_used_by_list + + """ + pass + + def test_propertymappings_provider_scope_create(self) -> None: + """Test case for propertymappings_provider_scope_create + + """ + pass + + def test_propertymappings_provider_scope_destroy(self) -> None: + """Test case for propertymappings_provider_scope_destroy + + """ + pass + + def test_propertymappings_provider_scope_list(self) -> None: + """Test case for propertymappings_provider_scope_list + + """ + pass + + def test_propertymappings_provider_scope_partial_update(self) -> None: + """Test case for propertymappings_provider_scope_partial_update + + """ + pass + + def test_propertymappings_provider_scope_retrieve(self) -> None: + """Test case for propertymappings_provider_scope_retrieve + + """ + pass + + def test_propertymappings_provider_scope_update(self) -> None: + """Test case for propertymappings_provider_scope_update + + """ + pass + + def test_propertymappings_provider_scope_used_by_list(self) -> None: + """Test case for propertymappings_provider_scope_used_by_list + + """ + pass + + def test_propertymappings_source_kerberos_create(self) -> None: + """Test case for propertymappings_source_kerberos_create + + """ + pass + + def test_propertymappings_source_kerberos_destroy(self) -> None: + """Test case for propertymappings_source_kerberos_destroy + + """ + pass + + def test_propertymappings_source_kerberos_list(self) -> None: + """Test case for propertymappings_source_kerberos_list + + """ + pass + + def test_propertymappings_source_kerberos_partial_update(self) -> None: + """Test case for propertymappings_source_kerberos_partial_update + + """ + pass + + def test_propertymappings_source_kerberos_retrieve(self) -> None: + """Test case for propertymappings_source_kerberos_retrieve + + """ + pass + + def test_propertymappings_source_kerberos_update(self) -> None: + """Test case for propertymappings_source_kerberos_update + + """ + pass + + def test_propertymappings_source_kerberos_used_by_list(self) -> None: + """Test case for propertymappings_source_kerberos_used_by_list + + """ + pass + + def test_propertymappings_source_ldap_create(self) -> None: + """Test case for propertymappings_source_ldap_create + + """ + pass + + def test_propertymappings_source_ldap_destroy(self) -> None: + """Test case for propertymappings_source_ldap_destroy + + """ + pass + + def test_propertymappings_source_ldap_list(self) -> None: + """Test case for propertymappings_source_ldap_list + + """ + pass + + def test_propertymappings_source_ldap_partial_update(self) -> None: + """Test case for propertymappings_source_ldap_partial_update + + """ + pass + + def test_propertymappings_source_ldap_retrieve(self) -> None: + """Test case for propertymappings_source_ldap_retrieve + + """ + pass + + def test_propertymappings_source_ldap_update(self) -> None: + """Test case for propertymappings_source_ldap_update + + """ + pass + + def test_propertymappings_source_ldap_used_by_list(self) -> None: + """Test case for propertymappings_source_ldap_used_by_list + + """ + pass + + def test_propertymappings_source_oauth_create(self) -> None: + """Test case for propertymappings_source_oauth_create + + """ + pass + + def test_propertymappings_source_oauth_destroy(self) -> None: + """Test case for propertymappings_source_oauth_destroy + + """ + pass + + def test_propertymappings_source_oauth_list(self) -> None: + """Test case for propertymappings_source_oauth_list + + """ + pass + + def test_propertymappings_source_oauth_partial_update(self) -> None: + """Test case for propertymappings_source_oauth_partial_update + + """ + pass + + def test_propertymappings_source_oauth_retrieve(self) -> None: + """Test case for propertymappings_source_oauth_retrieve + + """ + pass + + def test_propertymappings_source_oauth_update(self) -> None: + """Test case for propertymappings_source_oauth_update + + """ + pass + + def test_propertymappings_source_oauth_used_by_list(self) -> None: + """Test case for propertymappings_source_oauth_used_by_list + + """ + pass + + def test_propertymappings_source_plex_create(self) -> None: + """Test case for propertymappings_source_plex_create + + """ + pass + + def test_propertymappings_source_plex_destroy(self) -> None: + """Test case for propertymappings_source_plex_destroy + + """ + pass + + def test_propertymappings_source_plex_list(self) -> None: + """Test case for propertymappings_source_plex_list + + """ + pass + + def test_propertymappings_source_plex_partial_update(self) -> None: + """Test case for propertymappings_source_plex_partial_update + + """ + pass + + def test_propertymappings_source_plex_retrieve(self) -> None: + """Test case for propertymappings_source_plex_retrieve + + """ + pass + + def test_propertymappings_source_plex_update(self) -> None: + """Test case for propertymappings_source_plex_update + + """ + pass + + def test_propertymappings_source_plex_used_by_list(self) -> None: + """Test case for propertymappings_source_plex_used_by_list + + """ + pass + + def test_propertymappings_source_saml_create(self) -> None: + """Test case for propertymappings_source_saml_create + + """ + pass + + def test_propertymappings_source_saml_destroy(self) -> None: + """Test case for propertymappings_source_saml_destroy + + """ + pass + + def test_propertymappings_source_saml_list(self) -> None: + """Test case for propertymappings_source_saml_list + + """ + pass + + def test_propertymappings_source_saml_partial_update(self) -> None: + """Test case for propertymappings_source_saml_partial_update + + """ + pass + + def test_propertymappings_source_saml_retrieve(self) -> None: + """Test case for propertymappings_source_saml_retrieve + + """ + pass + + def test_propertymappings_source_saml_update(self) -> None: + """Test case for propertymappings_source_saml_update + + """ + pass + + def test_propertymappings_source_saml_used_by_list(self) -> None: + """Test case for propertymappings_source_saml_used_by_list + + """ + pass + + def test_propertymappings_source_scim_create(self) -> None: + """Test case for propertymappings_source_scim_create + + """ + pass + + def test_propertymappings_source_scim_destroy(self) -> None: + """Test case for propertymappings_source_scim_destroy + + """ + pass + + def test_propertymappings_source_scim_list(self) -> None: + """Test case for propertymappings_source_scim_list + + """ + pass + + def test_propertymappings_source_scim_partial_update(self) -> None: + """Test case for propertymappings_source_scim_partial_update + + """ + pass + + def test_propertymappings_source_scim_retrieve(self) -> None: + """Test case for propertymappings_source_scim_retrieve + + """ + pass + + def test_propertymappings_source_scim_update(self) -> None: + """Test case for propertymappings_source_scim_update + + """ + pass + + def test_propertymappings_source_scim_used_by_list(self) -> None: + """Test case for propertymappings_source_scim_used_by_list + + """ + pass + + def test_propertymappings_source_telegram_create(self) -> None: + """Test case for propertymappings_source_telegram_create + + """ + pass + + def test_propertymappings_source_telegram_destroy(self) -> None: + """Test case for propertymappings_source_telegram_destroy + + """ + pass + + def test_propertymappings_source_telegram_list(self) -> None: + """Test case for propertymappings_source_telegram_list + + """ + pass + + def test_propertymappings_source_telegram_partial_update(self) -> None: + """Test case for propertymappings_source_telegram_partial_update + + """ + pass + + def test_propertymappings_source_telegram_retrieve(self) -> None: + """Test case for propertymappings_source_telegram_retrieve + + """ + pass + + def test_propertymappings_source_telegram_update(self) -> None: + """Test case for propertymappings_source_telegram_update + + """ + pass + + def test_propertymappings_source_telegram_used_by_list(self) -> None: + """Test case for propertymappings_source_telegram_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_protocol_enum.py b/test/test_protocol_enum.py new file mode 100644 index 000000000..6e2b7a01c --- /dev/null +++ b/test/test_protocol_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.protocol_enum import ProtocolEnum + +class TestProtocolEnum(unittest.TestCase): + """ProtocolEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testProtocolEnum(self): + """Test ProtocolEnum""" + # inst = ProtocolEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_provider.py b/test/test_provider.py new file mode 100644 index 000000000..28cd9284c --- /dev/null +++ b/test/test_provider.py @@ -0,0 +1,79 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.provider import Provider + +class TestProvider(unittest.TestCase): + """Provider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Provider: + """Test Provider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Provider` + """ + model = Provider() + if include_optional: + return Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return Provider( + pk = 56, + name = '', + authorization_flow = '', + invalidation_flow = '', + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testProvider(self): + """Test Provider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_provider_enum.py b/test/test_provider_enum.py new file mode 100644 index 000000000..08b59dd34 --- /dev/null +++ b/test/test_provider_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.provider_enum import ProviderEnum + +class TestProviderEnum(unittest.TestCase): + """ProviderEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testProviderEnum(self): + """Test ProviderEnum""" + # inst = ProviderEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_provider_model_enum.py b/test/test_provider_model_enum.py new file mode 100644 index 000000000..44d7c4c83 --- /dev/null +++ b/test/test_provider_model_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.provider_model_enum import ProviderModelEnum + +class TestProviderModelEnum(unittest.TestCase): + """ProviderModelEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testProviderModelEnum(self): + """Test ProviderModelEnum""" + # inst = ProviderModelEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_provider_type_enum.py b/test/test_provider_type_enum.py new file mode 100644 index 000000000..4e04c9e7a --- /dev/null +++ b/test/test_provider_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.provider_type_enum import ProviderTypeEnum + +class TestProviderTypeEnum(unittest.TestCase): + """ProviderTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testProviderTypeEnum(self): + """Test ProviderTypeEnum""" + # inst = ProviderTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_providers_api.py b/test/test_providers_api.py new file mode 100644 index 000000000..67358ab44 --- /dev/null +++ b/test/test_providers_api.py @@ -0,0 +1,782 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.providers_api import ProvidersApi + + +class TestProvidersApi(unittest.TestCase): + """ProvidersApi unit test stubs""" + + def setUp(self) -> None: + self.api = ProvidersApi() + + def tearDown(self) -> None: + pass + + def test_providers_all_destroy(self) -> None: + """Test case for providers_all_destroy + + """ + pass + + def test_providers_all_list(self) -> None: + """Test case for providers_all_list + + """ + pass + + def test_providers_all_retrieve(self) -> None: + """Test case for providers_all_retrieve + + """ + pass + + def test_providers_all_types_list(self) -> None: + """Test case for providers_all_types_list + + """ + pass + + def test_providers_all_used_by_list(self) -> None: + """Test case for providers_all_used_by_list + + """ + pass + + def test_providers_google_workspace_create(self) -> None: + """Test case for providers_google_workspace_create + + """ + pass + + def test_providers_google_workspace_destroy(self) -> None: + """Test case for providers_google_workspace_destroy + + """ + pass + + def test_providers_google_workspace_groups_create(self) -> None: + """Test case for providers_google_workspace_groups_create + + """ + pass + + def test_providers_google_workspace_groups_destroy(self) -> None: + """Test case for providers_google_workspace_groups_destroy + + """ + pass + + def test_providers_google_workspace_groups_list(self) -> None: + """Test case for providers_google_workspace_groups_list + + """ + pass + + def test_providers_google_workspace_groups_retrieve(self) -> None: + """Test case for providers_google_workspace_groups_retrieve + + """ + pass + + def test_providers_google_workspace_groups_used_by_list(self) -> None: + """Test case for providers_google_workspace_groups_used_by_list + + """ + pass + + def test_providers_google_workspace_list(self) -> None: + """Test case for providers_google_workspace_list + + """ + pass + + def test_providers_google_workspace_partial_update(self) -> None: + """Test case for providers_google_workspace_partial_update + + """ + pass + + def test_providers_google_workspace_retrieve(self) -> None: + """Test case for providers_google_workspace_retrieve + + """ + pass + + def test_providers_google_workspace_sync_object_create(self) -> None: + """Test case for providers_google_workspace_sync_object_create + + """ + pass + + def test_providers_google_workspace_sync_status_retrieve(self) -> None: + """Test case for providers_google_workspace_sync_status_retrieve + + """ + pass + + def test_providers_google_workspace_update(self) -> None: + """Test case for providers_google_workspace_update + + """ + pass + + def test_providers_google_workspace_used_by_list(self) -> None: + """Test case for providers_google_workspace_used_by_list + + """ + pass + + def test_providers_google_workspace_users_create(self) -> None: + """Test case for providers_google_workspace_users_create + + """ + pass + + def test_providers_google_workspace_users_destroy(self) -> None: + """Test case for providers_google_workspace_users_destroy + + """ + pass + + def test_providers_google_workspace_users_list(self) -> None: + """Test case for providers_google_workspace_users_list + + """ + pass + + def test_providers_google_workspace_users_retrieve(self) -> None: + """Test case for providers_google_workspace_users_retrieve + + """ + pass + + def test_providers_google_workspace_users_used_by_list(self) -> None: + """Test case for providers_google_workspace_users_used_by_list + + """ + pass + + def test_providers_ldap_create(self) -> None: + """Test case for providers_ldap_create + + """ + pass + + def test_providers_ldap_destroy(self) -> None: + """Test case for providers_ldap_destroy + + """ + pass + + def test_providers_ldap_list(self) -> None: + """Test case for providers_ldap_list + + """ + pass + + def test_providers_ldap_partial_update(self) -> None: + """Test case for providers_ldap_partial_update + + """ + pass + + def test_providers_ldap_retrieve(self) -> None: + """Test case for providers_ldap_retrieve + + """ + pass + + def test_providers_ldap_update(self) -> None: + """Test case for providers_ldap_update + + """ + pass + + def test_providers_ldap_used_by_list(self) -> None: + """Test case for providers_ldap_used_by_list + + """ + pass + + def test_providers_microsoft_entra_create(self) -> None: + """Test case for providers_microsoft_entra_create + + """ + pass + + def test_providers_microsoft_entra_destroy(self) -> None: + """Test case for providers_microsoft_entra_destroy + + """ + pass + + def test_providers_microsoft_entra_groups_create(self) -> None: + """Test case for providers_microsoft_entra_groups_create + + """ + pass + + def test_providers_microsoft_entra_groups_destroy(self) -> None: + """Test case for providers_microsoft_entra_groups_destroy + + """ + pass + + def test_providers_microsoft_entra_groups_list(self) -> None: + """Test case for providers_microsoft_entra_groups_list + + """ + pass + + def test_providers_microsoft_entra_groups_retrieve(self) -> None: + """Test case for providers_microsoft_entra_groups_retrieve + + """ + pass + + def test_providers_microsoft_entra_groups_used_by_list(self) -> None: + """Test case for providers_microsoft_entra_groups_used_by_list + + """ + pass + + def test_providers_microsoft_entra_list(self) -> None: + """Test case for providers_microsoft_entra_list + + """ + pass + + def test_providers_microsoft_entra_partial_update(self) -> None: + """Test case for providers_microsoft_entra_partial_update + + """ + pass + + def test_providers_microsoft_entra_retrieve(self) -> None: + """Test case for providers_microsoft_entra_retrieve + + """ + pass + + def test_providers_microsoft_entra_sync_object_create(self) -> None: + """Test case for providers_microsoft_entra_sync_object_create + + """ + pass + + def test_providers_microsoft_entra_sync_status_retrieve(self) -> None: + """Test case for providers_microsoft_entra_sync_status_retrieve + + """ + pass + + def test_providers_microsoft_entra_update(self) -> None: + """Test case for providers_microsoft_entra_update + + """ + pass + + def test_providers_microsoft_entra_used_by_list(self) -> None: + """Test case for providers_microsoft_entra_used_by_list + + """ + pass + + def test_providers_microsoft_entra_users_create(self) -> None: + """Test case for providers_microsoft_entra_users_create + + """ + pass + + def test_providers_microsoft_entra_users_destroy(self) -> None: + """Test case for providers_microsoft_entra_users_destroy + + """ + pass + + def test_providers_microsoft_entra_users_list(self) -> None: + """Test case for providers_microsoft_entra_users_list + + """ + pass + + def test_providers_microsoft_entra_users_retrieve(self) -> None: + """Test case for providers_microsoft_entra_users_retrieve + + """ + pass + + def test_providers_microsoft_entra_users_used_by_list(self) -> None: + """Test case for providers_microsoft_entra_users_used_by_list + + """ + pass + + def test_providers_oauth2_create(self) -> None: + """Test case for providers_oauth2_create + + """ + pass + + def test_providers_oauth2_destroy(self) -> None: + """Test case for providers_oauth2_destroy + + """ + pass + + def test_providers_oauth2_list(self) -> None: + """Test case for providers_oauth2_list + + """ + pass + + def test_providers_oauth2_partial_update(self) -> None: + """Test case for providers_oauth2_partial_update + + """ + pass + + def test_providers_oauth2_preview_user_retrieve(self) -> None: + """Test case for providers_oauth2_preview_user_retrieve + + """ + pass + + def test_providers_oauth2_retrieve(self) -> None: + """Test case for providers_oauth2_retrieve + + """ + pass + + def test_providers_oauth2_setup_urls_retrieve(self) -> None: + """Test case for providers_oauth2_setup_urls_retrieve + + """ + pass + + def test_providers_oauth2_update(self) -> None: + """Test case for providers_oauth2_update + + """ + pass + + def test_providers_oauth2_used_by_list(self) -> None: + """Test case for providers_oauth2_used_by_list + + """ + pass + + def test_providers_proxy_create(self) -> None: + """Test case for providers_proxy_create + + """ + pass + + def test_providers_proxy_destroy(self) -> None: + """Test case for providers_proxy_destroy + + """ + pass + + def test_providers_proxy_list(self) -> None: + """Test case for providers_proxy_list + + """ + pass + + def test_providers_proxy_partial_update(self) -> None: + """Test case for providers_proxy_partial_update + + """ + pass + + def test_providers_proxy_retrieve(self) -> None: + """Test case for providers_proxy_retrieve + + """ + pass + + def test_providers_proxy_update(self) -> None: + """Test case for providers_proxy_update + + """ + pass + + def test_providers_proxy_used_by_list(self) -> None: + """Test case for providers_proxy_used_by_list + + """ + pass + + def test_providers_rac_create(self) -> None: + """Test case for providers_rac_create + + """ + pass + + def test_providers_rac_destroy(self) -> None: + """Test case for providers_rac_destroy + + """ + pass + + def test_providers_rac_list(self) -> None: + """Test case for providers_rac_list + + """ + pass + + def test_providers_rac_partial_update(self) -> None: + """Test case for providers_rac_partial_update + + """ + pass + + def test_providers_rac_retrieve(self) -> None: + """Test case for providers_rac_retrieve + + """ + pass + + def test_providers_rac_update(self) -> None: + """Test case for providers_rac_update + + """ + pass + + def test_providers_rac_used_by_list(self) -> None: + """Test case for providers_rac_used_by_list + + """ + pass + + def test_providers_radius_create(self) -> None: + """Test case for providers_radius_create + + """ + pass + + def test_providers_radius_destroy(self) -> None: + """Test case for providers_radius_destroy + + """ + pass + + def test_providers_radius_list(self) -> None: + """Test case for providers_radius_list + + """ + pass + + def test_providers_radius_partial_update(self) -> None: + """Test case for providers_radius_partial_update + + """ + pass + + def test_providers_radius_retrieve(self) -> None: + """Test case for providers_radius_retrieve + + """ + pass + + def test_providers_radius_update(self) -> None: + """Test case for providers_radius_update + + """ + pass + + def test_providers_radius_used_by_list(self) -> None: + """Test case for providers_radius_used_by_list + + """ + pass + + def test_providers_saml_create(self) -> None: + """Test case for providers_saml_create + + """ + pass + + def test_providers_saml_destroy(self) -> None: + """Test case for providers_saml_destroy + + """ + pass + + def test_providers_saml_import_metadata_create(self) -> None: + """Test case for providers_saml_import_metadata_create + + """ + pass + + def test_providers_saml_list(self) -> None: + """Test case for providers_saml_list + + """ + pass + + def test_providers_saml_metadata_retrieve(self) -> None: + """Test case for providers_saml_metadata_retrieve + + """ + pass + + def test_providers_saml_partial_update(self) -> None: + """Test case for providers_saml_partial_update + + """ + pass + + def test_providers_saml_preview_user_retrieve(self) -> None: + """Test case for providers_saml_preview_user_retrieve + + """ + pass + + def test_providers_saml_retrieve(self) -> None: + """Test case for providers_saml_retrieve + + """ + pass + + def test_providers_saml_update(self) -> None: + """Test case for providers_saml_update + + """ + pass + + def test_providers_saml_used_by_list(self) -> None: + """Test case for providers_saml_used_by_list + + """ + pass + + def test_providers_scim_create(self) -> None: + """Test case for providers_scim_create + + """ + pass + + def test_providers_scim_destroy(self) -> None: + """Test case for providers_scim_destroy + + """ + pass + + def test_providers_scim_groups_create(self) -> None: + """Test case for providers_scim_groups_create + + """ + pass + + def test_providers_scim_groups_destroy(self) -> None: + """Test case for providers_scim_groups_destroy + + """ + pass + + def test_providers_scim_groups_list(self) -> None: + """Test case for providers_scim_groups_list + + """ + pass + + def test_providers_scim_groups_retrieve(self) -> None: + """Test case for providers_scim_groups_retrieve + + """ + pass + + def test_providers_scim_groups_used_by_list(self) -> None: + """Test case for providers_scim_groups_used_by_list + + """ + pass + + def test_providers_scim_list(self) -> None: + """Test case for providers_scim_list + + """ + pass + + def test_providers_scim_partial_update(self) -> None: + """Test case for providers_scim_partial_update + + """ + pass + + def test_providers_scim_retrieve(self) -> None: + """Test case for providers_scim_retrieve + + """ + pass + + def test_providers_scim_sync_object_create(self) -> None: + """Test case for providers_scim_sync_object_create + + """ + pass + + def test_providers_scim_sync_status_retrieve(self) -> None: + """Test case for providers_scim_sync_status_retrieve + + """ + pass + + def test_providers_scim_update(self) -> None: + """Test case for providers_scim_update + + """ + pass + + def test_providers_scim_used_by_list(self) -> None: + """Test case for providers_scim_used_by_list + + """ + pass + + def test_providers_scim_users_create(self) -> None: + """Test case for providers_scim_users_create + + """ + pass + + def test_providers_scim_users_destroy(self) -> None: + """Test case for providers_scim_users_destroy + + """ + pass + + def test_providers_scim_users_list(self) -> None: + """Test case for providers_scim_users_list + + """ + pass + + def test_providers_scim_users_retrieve(self) -> None: + """Test case for providers_scim_users_retrieve + + """ + pass + + def test_providers_scim_users_used_by_list(self) -> None: + """Test case for providers_scim_users_used_by_list + + """ + pass + + def test_providers_ssf_create(self) -> None: + """Test case for providers_ssf_create + + """ + pass + + def test_providers_ssf_destroy(self) -> None: + """Test case for providers_ssf_destroy + + """ + pass + + def test_providers_ssf_list(self) -> None: + """Test case for providers_ssf_list + + """ + pass + + def test_providers_ssf_partial_update(self) -> None: + """Test case for providers_ssf_partial_update + + """ + pass + + def test_providers_ssf_retrieve(self) -> None: + """Test case for providers_ssf_retrieve + + """ + pass + + def test_providers_ssf_update(self) -> None: + """Test case for providers_ssf_update + + """ + pass + + def test_providers_ssf_used_by_list(self) -> None: + """Test case for providers_ssf_used_by_list + + """ + pass + + def test_providers_wsfed_create(self) -> None: + """Test case for providers_wsfed_create + + """ + pass + + def test_providers_wsfed_destroy(self) -> None: + """Test case for providers_wsfed_destroy + + """ + pass + + def test_providers_wsfed_list(self) -> None: + """Test case for providers_wsfed_list + + """ + pass + + def test_providers_wsfed_metadata_retrieve(self) -> None: + """Test case for providers_wsfed_metadata_retrieve + + """ + pass + + def test_providers_wsfed_partial_update(self) -> None: + """Test case for providers_wsfed_partial_update + + """ + pass + + def test_providers_wsfed_preview_user_retrieve(self) -> None: + """Test case for providers_wsfed_preview_user_retrieve + + """ + pass + + def test_providers_wsfed_retrieve(self) -> None: + """Test case for providers_wsfed_retrieve + + """ + pass + + def test_providers_wsfed_update(self) -> None: + """Test case for providers_wsfed_update + + """ + pass + + def test_providers_wsfed_used_by_list(self) -> None: + """Test case for providers_wsfed_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_proxy_mode.py b/test/test_proxy_mode.py new file mode 100644 index 000000000..5ba66479f --- /dev/null +++ b/test/test_proxy_mode.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.proxy_mode import ProxyMode + +class TestProxyMode(unittest.TestCase): + """ProxyMode unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testProxyMode(self): + """Test ProxyMode""" + # inst = ProxyMode() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_proxy_outpost_config.py b/test/test_proxy_outpost_config.py new file mode 100644 index 000000000..d84721e13 --- /dev/null +++ b/test/test_proxy_outpost_config.py @@ -0,0 +1,122 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.proxy_outpost_config import ProxyOutpostConfig + +class TestProxyOutpostConfig(unittest.TestCase): + """ProxyOutpostConfig unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ProxyOutpostConfig: + """Test ProxyOutpostConfig + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ProxyOutpostConfig` + """ + model = ProxyOutpostConfig() + if include_optional: + return ProxyOutpostConfig( + pk = 56, + name = '', + internal_host = '', + external_host = '', + internal_host_ssl_validation = True, + client_id = '', + client_secret = '', + oidc_configuration = authentik_client.models.open_id_connect_configuration.OpenIDConnectConfiguration( + issuer = '', + authorization_endpoint = '', + token_endpoint = '', + userinfo_endpoint = '', + end_session_endpoint = '', + introspection_endpoint = '', + jwks_uri = '', + response_types_supported = [ + '' + ], + id_token_signing_alg_values_supported = [ + '' + ], + subject_types_supported = [ + '' + ], + token_endpoint_auth_methods_supported = [ + '' + ], ), + cookie_secret = '', + certificate = '', + skip_path_regex = '', + basic_auth_enabled = True, + basic_auth_password_attribute = '', + basic_auth_user_attribute = '', + mode = 'proxy', + cookie_domain = '', + access_token_validity = 1.337, + intercept_header_auth = True, + scopes_to_request = [ + '' + ], + assigned_application_slug = '', + assigned_application_name = '' + ) + else: + return ProxyOutpostConfig( + pk = 56, + name = '', + external_host = '', + oidc_configuration = authentik_client.models.open_id_connect_configuration.OpenIDConnectConfiguration( + issuer = '', + authorization_endpoint = '', + token_endpoint = '', + userinfo_endpoint = '', + end_session_endpoint = '', + introspection_endpoint = '', + jwks_uri = '', + response_types_supported = [ + '' + ], + id_token_signing_alg_values_supported = [ + '' + ], + subject_types_supported = [ + '' + ], + token_endpoint_auth_methods_supported = [ + '' + ], ), + access_token_validity = 1.337, + scopes_to_request = [ + '' + ], + assigned_application_slug = '', + assigned_application_name = '', + ) + """ + + def testProxyOutpostConfig(self): + """Test ProxyOutpostConfig""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_proxy_provider.py b/test/test_proxy_provider.py new file mode 100644 index 000000000..d2a510227 --- /dev/null +++ b/test/test_proxy_provider.py @@ -0,0 +1,119 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.proxy_provider import ProxyProvider + +class TestProxyProvider(unittest.TestCase): + """ProxyProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ProxyProvider: + """Test ProxyProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ProxyProvider` + """ + model = ProxyProvider() + if include_optional: + return ProxyProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_id = '', + internal_host = '', + external_host = '', + internal_host_ssl_validation = True, + certificate = '', + skip_path_regex = '', + basic_auth_enabled = True, + basic_auth_password_attribute = '', + basic_auth_user_attribute = '', + mode = 'proxy', + intercept_header_auth = True, + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + cookie_domain = '', + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], + access_token_validity = '', + refresh_token_validity = '', + outpost_set = [ + '' + ] + ) + else: + return ProxyProvider( + pk = 56, + name = '', + authorization_flow = '', + invalidation_flow = '', + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_id = '', + external_host = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + outpost_set = [ + '' + ], + ) + """ + + def testProxyProvider(self): + """Test ProxyProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_proxy_provider_request.py b/test/test_proxy_provider_request.py new file mode 100644 index 000000000..c361d92af --- /dev/null +++ b/test/test_proxy_provider_request.py @@ -0,0 +1,81 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.proxy_provider_request import ProxyProviderRequest + +class TestProxyProviderRequest(unittest.TestCase): + """ProxyProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ProxyProviderRequest: + """Test ProxyProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ProxyProviderRequest` + """ + model = ProxyProviderRequest() + if include_optional: + return ProxyProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + internal_host = '', + external_host = '0', + internal_host_ssl_validation = True, + certificate = '', + skip_path_regex = '', + basic_auth_enabled = True, + basic_auth_password_attribute = '', + basic_auth_user_attribute = '', + mode = 'proxy', + intercept_header_auth = True, + cookie_domain = '', + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], + access_token_validity = '0', + refresh_token_validity = '0' + ) + else: + return ProxyProviderRequest( + name = '0', + authorization_flow = '', + invalidation_flow = '', + external_host = '0', + ) + """ + + def testProxyProviderRequest(self): + """Test ProxyProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_rac_api.py b/test/test_rac_api.py new file mode 100644 index 000000000..4b2402c45 --- /dev/null +++ b/test/test_rac_api.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.rac_api import RacApi + + +class TestRacApi(unittest.TestCase): + """RacApi unit test stubs""" + + def setUp(self) -> None: + self.api = RacApi() + + def tearDown(self) -> None: + pass + + def test_rac_connection_tokens_destroy(self) -> None: + """Test case for rac_connection_tokens_destroy + + """ + pass + + def test_rac_connection_tokens_list(self) -> None: + """Test case for rac_connection_tokens_list + + """ + pass + + def test_rac_connection_tokens_partial_update(self) -> None: + """Test case for rac_connection_tokens_partial_update + + """ + pass + + def test_rac_connection_tokens_retrieve(self) -> None: + """Test case for rac_connection_tokens_retrieve + + """ + pass + + def test_rac_connection_tokens_update(self) -> None: + """Test case for rac_connection_tokens_update + + """ + pass + + def test_rac_connection_tokens_used_by_list(self) -> None: + """Test case for rac_connection_tokens_used_by_list + + """ + pass + + def test_rac_endpoints_create(self) -> None: + """Test case for rac_endpoints_create + + """ + pass + + def test_rac_endpoints_destroy(self) -> None: + """Test case for rac_endpoints_destroy + + """ + pass + + def test_rac_endpoints_list(self) -> None: + """Test case for rac_endpoints_list + + """ + pass + + def test_rac_endpoints_partial_update(self) -> None: + """Test case for rac_endpoints_partial_update + + """ + pass + + def test_rac_endpoints_retrieve(self) -> None: + """Test case for rac_endpoints_retrieve + + """ + pass + + def test_rac_endpoints_update(self) -> None: + """Test case for rac_endpoints_update + + """ + pass + + def test_rac_endpoints_used_by_list(self) -> None: + """Test case for rac_endpoints_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_rac_property_mapping.py b/test/test_rac_property_mapping.py new file mode 100644 index 000000000..8d815bfb6 --- /dev/null +++ b/test/test_rac_property_mapping.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.rac_property_mapping import RACPropertyMapping + +class TestRACPropertyMapping(unittest.TestCase): + """RACPropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RACPropertyMapping: + """Test RACPropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RACPropertyMapping` + """ + model = RACPropertyMapping() + if include_optional: + return RACPropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + static_settings = { + 'key' : null + } + ) + else: + return RACPropertyMapping( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + static_settings = { + 'key' : null + }, + ) + """ + + def testRACPropertyMapping(self): + """Test RACPropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_rac_property_mapping_request.py b/test/test_rac_property_mapping_request.py new file mode 100644 index 000000000..d43a38098 --- /dev/null +++ b/test/test_rac_property_mapping_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.rac_property_mapping_request import RACPropertyMappingRequest + +class TestRACPropertyMappingRequest(unittest.TestCase): + """RACPropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RACPropertyMappingRequest: + """Test RACPropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RACPropertyMappingRequest` + """ + model = RACPropertyMappingRequest() + if include_optional: + return RACPropertyMappingRequest( + managed = '0', + name = '0', + expression = '', + static_settings = { + 'key' : null + } + ) + else: + return RACPropertyMappingRequest( + name = '0', + static_settings = { + 'key' : null + }, + ) + """ + + def testRACPropertyMappingRequest(self): + """Test RACPropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_rac_provider.py b/test/test_rac_provider.py new file mode 100644 index 000000000..c3f4b4289 --- /dev/null +++ b/test/test_rac_provider.py @@ -0,0 +1,88 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.rac_provider import RACProvider + +class TestRACProvider(unittest.TestCase): + """RACProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RACProvider: + """Test RACProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RACProvider` + """ + model = RACProvider() + if include_optional: + return RACProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + settings = { + 'key' : null + }, + outpost_set = [ + '' + ], + connection_expiry = '', + delete_token_on_disconnect = True + ) + else: + return RACProvider( + pk = 56, + name = '', + authorization_flow = '', + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + outpost_set = [ + '' + ], + ) + """ + + def testRACProvider(self): + """Test RACProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_rac_provider_request.py b/test/test_rac_provider_request.py new file mode 100644 index 000000000..97af15aa4 --- /dev/null +++ b/test/test_rac_provider_request.py @@ -0,0 +1,64 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.rac_provider_request import RACProviderRequest + +class TestRACProviderRequest(unittest.TestCase): + """RACProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RACProviderRequest: + """Test RACProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RACProviderRequest` + """ + model = RACProviderRequest() + if include_optional: + return RACProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + property_mappings = [ + '' + ], + settings = { + 'key' : null + }, + connection_expiry = '0', + delete_token_on_disconnect = True + ) + else: + return RACProviderRequest( + name = '0', + authorization_flow = '', + ) + """ + + def testRACProviderRequest(self): + """Test RACProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_radius_check_access.py b/test/test_radius_check_access.py new file mode 100644 index 000000000..3715275d0 --- /dev/null +++ b/test/test_radius_check_access.py @@ -0,0 +1,82 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.radius_check_access import RadiusCheckAccess + +class TestRadiusCheckAccess(unittest.TestCase): + """RadiusCheckAccess unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RadiusCheckAccess: + """Test RadiusCheckAccess + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RadiusCheckAccess` + """ + model = RadiusCheckAccess() + if include_optional: + return RadiusCheckAccess( + attributes = '', + access = authentik_client.models.policy_test_result.PolicyTestResult( + passing = True, + messages = [ + '' + ], + log_messages = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], ) + ) + else: + return RadiusCheckAccess( + access = authentik_client.models.policy_test_result.PolicyTestResult( + passing = True, + messages = [ + '' + ], + log_messages = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], ), + ) + """ + + def testRadiusCheckAccess(self): + """Test RadiusCheckAccess""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_radius_outpost_config.py b/test/test_radius_outpost_config.py new file mode 100644 index 000000000..1b5b49633 --- /dev/null +++ b/test/test_radius_outpost_config.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.radius_outpost_config import RadiusOutpostConfig + +class TestRadiusOutpostConfig(unittest.TestCase): + """RadiusOutpostConfig unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RadiusOutpostConfig: + """Test RadiusOutpostConfig + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RadiusOutpostConfig` + """ + model = RadiusOutpostConfig() + if include_optional: + return RadiusOutpostConfig( + pk = 56, + name = '', + application_slug = '', + auth_flow_slug = '', + client_networks = '', + shared_secret = '', + mfa_support = True, + certificate = '' + ) + else: + return RadiusOutpostConfig( + pk = 56, + name = '', + application_slug = '', + auth_flow_slug = '', + ) + """ + + def testRadiusOutpostConfig(self): + """Test RadiusOutpostConfig""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_radius_provider.py b/test/test_radius_provider.py new file mode 100644 index 000000000..f2558b9e0 --- /dev/null +++ b/test/test_radius_provider.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.radius_provider import RadiusProvider + +class TestRadiusProvider(unittest.TestCase): + """RadiusProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RadiusProvider: + """Test RadiusProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RadiusProvider` + """ + model = RadiusProvider() + if include_optional: + return RadiusProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_networks = '', + shared_secret = '', + outpost_set = [ + '' + ], + mfa_support = True, + certificate = '' + ) + else: + return RadiusProvider( + pk = 56, + name = '', + authorization_flow = '', + invalidation_flow = '', + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + outpost_set = [ + '' + ], + ) + """ + + def testRadiusProvider(self): + """Test RadiusProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_radius_provider_property_mapping.py b/test/test_radius_provider_property_mapping.py new file mode 100644 index 000000000..2ed8b299b --- /dev/null +++ b/test/test_radius_provider_property_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.radius_provider_property_mapping import RadiusProviderPropertyMapping + +class TestRadiusProviderPropertyMapping(unittest.TestCase): + """RadiusProviderPropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RadiusProviderPropertyMapping: + """Test RadiusProviderPropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RadiusProviderPropertyMapping` + """ + model = RadiusProviderPropertyMapping() + if include_optional: + return RadiusProviderPropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return RadiusProviderPropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testRadiusProviderPropertyMapping(self): + """Test RadiusProviderPropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_radius_provider_property_mapping_request.py b/test/test_radius_provider_property_mapping_request.py new file mode 100644 index 000000000..d91ac1ed0 --- /dev/null +++ b/test/test_radius_provider_property_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.radius_provider_property_mapping_request import RadiusProviderPropertyMappingRequest + +class TestRadiusProviderPropertyMappingRequest(unittest.TestCase): + """RadiusProviderPropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RadiusProviderPropertyMappingRequest: + """Test RadiusProviderPropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RadiusProviderPropertyMappingRequest` + """ + model = RadiusProviderPropertyMappingRequest() + if include_optional: + return RadiusProviderPropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return RadiusProviderPropertyMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testRadiusProviderPropertyMappingRequest(self): + """Test RadiusProviderPropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_radius_provider_request.py b/test/test_radius_provider_request.py new file mode 100644 index 000000000..5f1466853 --- /dev/null +++ b/test/test_radius_provider_request.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.radius_provider_request import RadiusProviderRequest + +class TestRadiusProviderRequest(unittest.TestCase): + """RadiusProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RadiusProviderRequest: + """Test RadiusProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RadiusProviderRequest` + """ + model = RadiusProviderRequest() + if include_optional: + return RadiusProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + client_networks = '0', + shared_secret = '0', + mfa_support = True, + certificate = '' + ) + else: + return RadiusProviderRequest( + name = '0', + authorization_flow = '', + invalidation_flow = '', + ) + """ + + def testRadiusProviderRequest(self): + """Test RadiusProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_rbac_api.py b/test/test_rbac_api.py new file mode 100644 index 000000000..16e4e4334 --- /dev/null +++ b/test/test_rbac_api.py @@ -0,0 +1,164 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.rbac_api import RbacApi + + +class TestRbacApi(unittest.TestCase): + """RbacApi unit test stubs""" + + def setUp(self) -> None: + self.api = RbacApi() + + def tearDown(self) -> None: + pass + + def test_rbac_initial_permissions_create(self) -> None: + """Test case for rbac_initial_permissions_create + + """ + pass + + def test_rbac_initial_permissions_destroy(self) -> None: + """Test case for rbac_initial_permissions_destroy + + """ + pass + + def test_rbac_initial_permissions_list(self) -> None: + """Test case for rbac_initial_permissions_list + + """ + pass + + def test_rbac_initial_permissions_partial_update(self) -> None: + """Test case for rbac_initial_permissions_partial_update + + """ + pass + + def test_rbac_initial_permissions_retrieve(self) -> None: + """Test case for rbac_initial_permissions_retrieve + + """ + pass + + def test_rbac_initial_permissions_update(self) -> None: + """Test case for rbac_initial_permissions_update + + """ + pass + + def test_rbac_initial_permissions_used_by_list(self) -> None: + """Test case for rbac_initial_permissions_used_by_list + + """ + pass + + def test_rbac_permissions_assigned_by_roles_assign(self) -> None: + """Test case for rbac_permissions_assigned_by_roles_assign + + """ + pass + + def test_rbac_permissions_assigned_by_roles_list(self) -> None: + """Test case for rbac_permissions_assigned_by_roles_list + + """ + pass + + def test_rbac_permissions_assigned_by_roles_unassign_partial_update(self) -> None: + """Test case for rbac_permissions_assigned_by_roles_unassign_partial_update + + """ + pass + + def test_rbac_permissions_list(self) -> None: + """Test case for rbac_permissions_list + + """ + pass + + def test_rbac_permissions_retrieve(self) -> None: + """Test case for rbac_permissions_retrieve + + """ + pass + + def test_rbac_permissions_roles_list(self) -> None: + """Test case for rbac_permissions_roles_list + + """ + pass + + def test_rbac_roles_add_user_create(self) -> None: + """Test case for rbac_roles_add_user_create + + """ + pass + + def test_rbac_roles_create(self) -> None: + """Test case for rbac_roles_create + + """ + pass + + def test_rbac_roles_destroy(self) -> None: + """Test case for rbac_roles_destroy + + """ + pass + + def test_rbac_roles_list(self) -> None: + """Test case for rbac_roles_list + + """ + pass + + def test_rbac_roles_partial_update(self) -> None: + """Test case for rbac_roles_partial_update + + """ + pass + + def test_rbac_roles_remove_user_create(self) -> None: + """Test case for rbac_roles_remove_user_create + + """ + pass + + def test_rbac_roles_retrieve(self) -> None: + """Test case for rbac_roles_retrieve + + """ + pass + + def test_rbac_roles_update(self) -> None: + """Test case for rbac_roles_update + + """ + pass + + def test_rbac_roles_used_by_list(self) -> None: + """Test case for rbac_roles_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_redirect_challenge.py b/test/test_redirect_challenge.py new file mode 100644 index 000000000..ca14e516a --- /dev/null +++ b/test/test_redirect_challenge.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.redirect_challenge import RedirectChallenge + +class TestRedirectChallenge(unittest.TestCase): + """RedirectChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RedirectChallenge: + """Test RedirectChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RedirectChallenge` + """ + model = RedirectChallenge() + if include_optional: + return RedirectChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'xak-flow-redirect', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + to = '' + ) + else: + return RedirectChallenge( + to = '', + ) + """ + + def testRedirectChallenge(self): + """Test RedirectChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_redirect_challenge_response_request.py b/test/test_redirect_challenge_response_request.py new file mode 100644 index 000000000..df296ecd8 --- /dev/null +++ b/test/test_redirect_challenge_response_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.redirect_challenge_response_request import RedirectChallengeResponseRequest + +class TestRedirectChallengeResponseRequest(unittest.TestCase): + """RedirectChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RedirectChallengeResponseRequest: + """Test RedirectChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RedirectChallengeResponseRequest` + """ + model = RedirectChallengeResponseRequest() + if include_optional: + return RedirectChallengeResponseRequest( + component = 'xak-flow-redirect', + to = '0' + ) + else: + return RedirectChallengeResponseRequest( + to = '0', + ) + """ + + def testRedirectChallengeResponseRequest(self): + """Test RedirectChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_redirect_stage.py b/test/test_redirect_stage.py new file mode 100644 index 000000000..b8ac91edd --- /dev/null +++ b/test/test_redirect_stage.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.redirect_stage import RedirectStage + +class TestRedirectStage(unittest.TestCase): + """RedirectStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RedirectStage: + """Test RedirectStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RedirectStage` + """ + model = RedirectStage() + if include_optional: + return RedirectStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + keep_context = True, + mode = 'static', + target_static = '', + target_flow = '' + ) + else: + return RedirectStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + mode = 'static', + ) + """ + + def testRedirectStage(self): + """Test RedirectStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_redirect_stage_mode_enum.py b/test/test_redirect_stage_mode_enum.py new file mode 100644 index 000000000..a23b1efe7 --- /dev/null +++ b/test/test_redirect_stage_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.redirect_stage_mode_enum import RedirectStageModeEnum + +class TestRedirectStageModeEnum(unittest.TestCase): + """RedirectStageModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testRedirectStageModeEnum(self): + """Test RedirectStageModeEnum""" + # inst = RedirectStageModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_redirect_stage_request.py b/test/test_redirect_stage_request.py new file mode 100644 index 000000000..61ade50ae --- /dev/null +++ b/test/test_redirect_stage_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.redirect_stage_request import RedirectStageRequest + +class TestRedirectStageRequest(unittest.TestCase): + """RedirectStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RedirectStageRequest: + """Test RedirectStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RedirectStageRequest` + """ + model = RedirectStageRequest() + if include_optional: + return RedirectStageRequest( + name = '0', + keep_context = True, + mode = 'static', + target_static = '', + target_flow = '' + ) + else: + return RedirectStageRequest( + name = '0', + mode = 'static', + ) + """ + + def testRedirectStageRequest(self): + """Test RedirectStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_redirect_uri.py b/test/test_redirect_uri.py new file mode 100644 index 000000000..92c812341 --- /dev/null +++ b/test/test_redirect_uri.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.redirect_uri import RedirectURI + +class TestRedirectURI(unittest.TestCase): + """RedirectURI unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RedirectURI: + """Test RedirectURI + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RedirectURI` + """ + model = RedirectURI() + if include_optional: + return RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = 'authorization' + ) + else: + return RedirectURI( + matching_mode = 'strict', + url = '', + ) + """ + + def testRedirectURI(self): + """Test RedirectURI""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_redirect_uri_request.py b/test/test_redirect_uri_request.py new file mode 100644 index 000000000..e9ccd73fe --- /dev/null +++ b/test/test_redirect_uri_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.redirect_uri_request import RedirectURIRequest + +class TestRedirectURIRequest(unittest.TestCase): + """RedirectURIRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RedirectURIRequest: + """Test RedirectURIRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RedirectURIRequest` + """ + model = RedirectURIRequest() + if include_optional: + return RedirectURIRequest( + matching_mode = 'strict', + url = '0', + redirect_uri_type = 'authorization' + ) + else: + return RedirectURIRequest( + matching_mode = 'strict', + url = '0', + ) + """ + + def testRedirectURIRequest(self): + """Test RedirectURIRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_redirect_uri_type_enum.py b/test/test_redirect_uri_type_enum.py new file mode 100644 index 000000000..25e14016c --- /dev/null +++ b/test/test_redirect_uri_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.redirect_uri_type_enum import RedirectURITypeEnum + +class TestRedirectURITypeEnum(unittest.TestCase): + """RedirectURITypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testRedirectURITypeEnum(self): + """Test RedirectURITypeEnum""" + # inst = RedirectURITypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_related_group.py b/test/test_related_group.py new file mode 100644 index 000000000..8a7dcdfb0 --- /dev/null +++ b/test/test_related_group.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.related_group import RelatedGroup + +class TestRelatedGroup(unittest.TestCase): + """RelatedGroup unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RelatedGroup: + """Test RelatedGroup + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RelatedGroup` + """ + model = RelatedGroup() + if include_optional: + return RelatedGroup( + pk = '', + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, + group_uuid = '' + ) + else: + return RelatedGroup( + pk = '', + name = '', + group_uuid = '', + ) + """ + + def testRelatedGroup(self): + """Test RelatedGroup""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_related_rule.py b/test/test_related_rule.py new file mode 100644 index 000000000..21109e39e --- /dev/null +++ b/test/test_related_rule.py @@ -0,0 +1,80 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.related_rule import RelatedRule + +class TestRelatedRule(unittest.TestCase): + """RelatedRule unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RelatedRule: + """Test RelatedRule + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RelatedRule` + """ + model = RelatedRule() + if include_optional: + return RelatedRule( + id = '', + name = '', + reviewer_groups = [ + authentik_client.models.reviewer_group.ReviewerGroup( + pk = '', + name = '', ) + ], + min_reviewers = 56, + reviewers = [ + authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ) + ] + ) + else: + return RelatedRule( + name = '', + reviewer_groups = [ + authentik_client.models.reviewer_group.ReviewerGroup( + pk = '', + name = '', ) + ], + min_reviewers = 56, + reviewers = [ + authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ) + ], + ) + """ + + def testRelatedRule(self): + """Test RelatedRule""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_reports_api.py b/test/test_reports_api.py new file mode 100644 index 000000000..dc74d39b4 --- /dev/null +++ b/test/test_reports_api.py @@ -0,0 +1,50 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.reports_api import ReportsApi + + +class TestReportsApi(unittest.TestCase): + """ReportsApi unit test stubs""" + + def setUp(self) -> None: + self.api = ReportsApi() + + def tearDown(self) -> None: + pass + + def test_reports_exports_destroy(self) -> None: + """Test case for reports_exports_destroy + + """ + pass + + def test_reports_exports_list(self) -> None: + """Test case for reports_exports_list + + """ + pass + + def test_reports_exports_retrieve(self) -> None: + """Test case for reports_exports_retrieve + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_reputation.py b/test/test_reputation.py new file mode 100644 index 000000000..f49d4eddb --- /dev/null +++ b/test/test_reputation.py @@ -0,0 +1,65 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.reputation import Reputation + +class TestReputation(unittest.TestCase): + """Reputation unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Reputation: + """Test Reputation + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Reputation` + """ + model = Reputation() + if include_optional: + return Reputation( + pk = '', + identifier = '', + ip = '', + ip_geo_data = { + 'key' : null + }, + ip_asn_data = { + 'key' : null + }, + score = -9223372036854775808, + updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return Reputation( + identifier = '', + ip = '', + updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testReputation(self): + """Test Reputation""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_reputation_policy.py b/test/test_reputation_policy.py new file mode 100644 index 000000000..7a40a9e03 --- /dev/null +++ b/test/test_reputation_policy.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.reputation_policy import ReputationPolicy + +class TestReputationPolicy(unittest.TestCase): + """ReputationPolicy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ReputationPolicy: + """Test ReputationPolicy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ReputationPolicy` + """ + model = ReputationPolicy() + if include_optional: + return ReputationPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + check_ip = True, + check_username = True, + threshold = -2147483648 + ) + else: + return ReputationPolicy( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + ) + """ + + def testReputationPolicy(self): + """Test ReputationPolicy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_reputation_policy_request.py b/test/test_reputation_policy_request.py new file mode 100644 index 000000000..4d64c0203 --- /dev/null +++ b/test/test_reputation_policy_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.reputation_policy_request import ReputationPolicyRequest + +class TestReputationPolicyRequest(unittest.TestCase): + """ReputationPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ReputationPolicyRequest: + """Test ReputationPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ReputationPolicyRequest` + """ + model = ReputationPolicyRequest() + if include_optional: + return ReputationPolicyRequest( + name = '0', + execution_logging = True, + check_ip = True, + check_username = True, + threshold = -2147483648 + ) + else: + return ReputationPolicyRequest( + name = '0', + ) + """ + + def testReputationPolicyRequest(self): + """Test ReputationPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_review.py b/test/test_review.py new file mode 100644 index 000000000..1566fedb0 --- /dev/null +++ b/test/test_review.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.review import Review + +class TestReview(unittest.TestCase): + """Review unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Review: + """Test Review + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Review` + """ + model = Review() + if include_optional: + return Review( + id = '', + iteration = '', + reviewer = authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ), + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + note = '' + ) + else: + return Review( + id = '', + iteration = '', + reviewer = authentik_client.models.reviewer_user.ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', ), + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testReview(self): + """Test Review""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_review_request.py b/test/test_review_request.py new file mode 100644 index 000000000..f2a53947e --- /dev/null +++ b/test/test_review_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.review_request import ReviewRequest + +class TestReviewRequest(unittest.TestCase): + """ReviewRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ReviewRequest: + """Test ReviewRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ReviewRequest` + """ + model = ReviewRequest() + if include_optional: + return ReviewRequest( + iteration = '', + note = '0' + ) + else: + return ReviewRequest( + iteration = '', + ) + """ + + def testReviewRequest(self): + """Test ReviewRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_reviewer_group.py b/test/test_reviewer_group.py new file mode 100644 index 000000000..6dd4eae27 --- /dev/null +++ b/test/test_reviewer_group.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.reviewer_group import ReviewerGroup + +class TestReviewerGroup(unittest.TestCase): + """ReviewerGroup unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ReviewerGroup: + """Test ReviewerGroup + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ReviewerGroup` + """ + model = ReviewerGroup() + if include_optional: + return ReviewerGroup( + pk = '', + name = '' + ) + else: + return ReviewerGroup( + pk = '', + name = '', + ) + """ + + def testReviewerGroup(self): + """Test ReviewerGroup""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_reviewer_user.py b/test/test_reviewer_user.py new file mode 100644 index 000000000..78a866d0b --- /dev/null +++ b/test/test_reviewer_user.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.reviewer_user import ReviewerUser + +class TestReviewerUser(unittest.TestCase): + """ReviewerUser unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ReviewerUser: + """Test ReviewerUser + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ReviewerUser` + """ + model = ReviewerUser() + if include_optional: + return ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '' + ) + else: + return ReviewerUser( + pk = 56, + uuid = '', + username = 'A', + name = '', + ) + """ + + def testReviewerUser(self): + """Test ReviewerUser""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_role.py b/test/test_role.py new file mode 100644 index 000000000..2292caac7 --- /dev/null +++ b/test/test_role.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.role import Role + +class TestRole(unittest.TestCase): + """Role unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Role: + """Test Role + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Role` + """ + model = Role() + if include_optional: + return Role( + pk = '', + name = '' + ) + else: + return Role( + pk = '', + name = '', + ) + """ + + def testRole(self): + """Test Role""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_role_assigned_object_permission.py b/test/test_role_assigned_object_permission.py new file mode 100644 index 000000000..7c4f87a68 --- /dev/null +++ b/test/test_role_assigned_object_permission.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.role_assigned_object_permission import RoleAssignedObjectPermission + +class TestRoleAssignedObjectPermission(unittest.TestCase): + """RoleAssignedObjectPermission unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RoleAssignedObjectPermission: + """Test RoleAssignedObjectPermission + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RoleAssignedObjectPermission` + """ + model = RoleAssignedObjectPermission() + if include_optional: + return RoleAssignedObjectPermission( + role_pk = '', + name = '', + object_permissions = [ + authentik_client.models.role_object_permission.RoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '', ) + ], + model_permissions = [ + authentik_client.models.role_model_permission.RoleModelPermission( + id = 56, + codename = '', + model = '', + app_label = '', + name = '', ) + ] + ) + else: + return RoleAssignedObjectPermission( + role_pk = '', + name = '', + object_permissions = [ + authentik_client.models.role_object_permission.RoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '', ) + ], + model_permissions = [ + authentik_client.models.role_model_permission.RoleModelPermission( + id = 56, + codename = '', + model = '', + app_label = '', + name = '', ) + ], + ) + """ + + def testRoleAssignedObjectPermission(self): + """Test RoleAssignedObjectPermission""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_role_model_permission.py b/test/test_role_model_permission.py new file mode 100644 index 000000000..3ece21377 --- /dev/null +++ b/test/test_role_model_permission.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.role_model_permission import RoleModelPermission + +class TestRoleModelPermission(unittest.TestCase): + """RoleModelPermission unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RoleModelPermission: + """Test RoleModelPermission + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RoleModelPermission` + """ + model = RoleModelPermission() + if include_optional: + return RoleModelPermission( + id = 56, + codename = '', + model = '', + app_label = '', + name = '' + ) + else: + return RoleModelPermission( + id = 56, + codename = '', + model = '', + app_label = '', + name = '', + ) + """ + + def testRoleModelPermission(self): + """Test RoleModelPermission""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_role_object_permission.py b/test/test_role_object_permission.py new file mode 100644 index 000000000..92eb053af --- /dev/null +++ b/test/test_role_object_permission.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.role_object_permission import RoleObjectPermission + +class TestRoleObjectPermission(unittest.TestCase): + """RoleObjectPermission unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RoleObjectPermission: + """Test RoleObjectPermission + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RoleObjectPermission` + """ + model = RoleObjectPermission() + if include_optional: + return RoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '' + ) + else: + return RoleObjectPermission( + id = 56, + codename = '', + model = '', + app_label = '', + object_pk = '', + name = '', + ) + """ + + def testRoleObjectPermission(self): + """Test RoleObjectPermission""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_role_request.py b/test/test_role_request.py new file mode 100644 index 000000000..fa290b9fe --- /dev/null +++ b/test/test_role_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.role_request import RoleRequest + +class TestRoleRequest(unittest.TestCase): + """RoleRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> RoleRequest: + """Test RoleRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `RoleRequest` + """ + model = RoleRequest() + if include_optional: + return RoleRequest( + name = '0' + ) + else: + return RoleRequest( + name = '0', + ) + """ + + def testRoleRequest(self): + """Test RoleRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_root_api.py b/test/test_root_api.py new file mode 100644 index 000000000..b6aaa748f --- /dev/null +++ b/test/test_root_api.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.root_api import RootApi + + +class TestRootApi(unittest.TestCase): + """RootApi unit test stubs""" + + def setUp(self) -> None: + self.api = RootApi() + + def tearDown(self) -> None: + pass + + def test_root_config_retrieve(self) -> None: + """Test case for root_config_retrieve + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_bindings_enum.py b/test/test_saml_bindings_enum.py new file mode 100644 index 000000000..e406789ab --- /dev/null +++ b/test/test_saml_bindings_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_bindings_enum import SAMLBindingsEnum + +class TestSAMLBindingsEnum(unittest.TestCase): + """SAMLBindingsEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSAMLBindingsEnum(self): + """Test SAMLBindingsEnum""" + # inst = SAMLBindingsEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_logout_methods.py b/test/test_saml_logout_methods.py new file mode 100644 index 000000000..3e4ff6228 --- /dev/null +++ b/test/test_saml_logout_methods.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_logout_methods import SAMLLogoutMethods + +class TestSAMLLogoutMethods(unittest.TestCase): + """SAMLLogoutMethods unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSAMLLogoutMethods(self): + """Test SAMLLogoutMethods""" + # inst = SAMLLogoutMethods() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_metadata.py b/test/test_saml_metadata.py new file mode 100644 index 000000000..955e1d7e0 --- /dev/null +++ b/test/test_saml_metadata.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_metadata import SAMLMetadata + +class TestSAMLMetadata(unittest.TestCase): + """SAMLMetadata unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SAMLMetadata: + """Test SAMLMetadata + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SAMLMetadata` + """ + model = SAMLMetadata() + if include_optional: + return SAMLMetadata( + metadata = '', + download_url = '' + ) + else: + return SAMLMetadata( + metadata = '', + ) + """ + + def testSAMLMetadata(self): + """Test SAMLMetadata""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_name_id_policy_enum.py b/test/test_saml_name_id_policy_enum.py new file mode 100644 index 000000000..e633bb69f --- /dev/null +++ b/test/test_saml_name_id_policy_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_name_id_policy_enum import SAMLNameIDPolicyEnum + +class TestSAMLNameIDPolicyEnum(unittest.TestCase): + """SAMLNameIDPolicyEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSAMLNameIDPolicyEnum(self): + """Test SAMLNameIDPolicyEnum""" + # inst = SAMLNameIDPolicyEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_property_mapping.py b/test/test_saml_property_mapping.py new file mode 100644 index 000000000..913dbe4f9 --- /dev/null +++ b/test/test_saml_property_mapping.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_property_mapping import SAMLPropertyMapping + +class TestSAMLPropertyMapping(unittest.TestCase): + """SAMLPropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SAMLPropertyMapping: + """Test SAMLPropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SAMLPropertyMapping` + """ + model = SAMLPropertyMapping() + if include_optional: + return SAMLPropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + saml_name = '', + friendly_name = '' + ) + else: + return SAMLPropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + saml_name = '', + ) + """ + + def testSAMLPropertyMapping(self): + """Test SAMLPropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_property_mapping_request.py b/test/test_saml_property_mapping_request.py new file mode 100644 index 000000000..34bbbf722 --- /dev/null +++ b/test/test_saml_property_mapping_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_property_mapping_request import SAMLPropertyMappingRequest + +class TestSAMLPropertyMappingRequest(unittest.TestCase): + """SAMLPropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SAMLPropertyMappingRequest: + """Test SAMLPropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SAMLPropertyMappingRequest` + """ + model = SAMLPropertyMappingRequest() + if include_optional: + return SAMLPropertyMappingRequest( + managed = '0', + name = '0', + expression = '0', + saml_name = '0', + friendly_name = '' + ) + else: + return SAMLPropertyMappingRequest( + name = '0', + expression = '0', + saml_name = '0', + ) + """ + + def testSAMLPropertyMappingRequest(self): + """Test SAMLPropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_provider.py b/test/test_saml_provider.py new file mode 100644 index 000000000..496871156 --- /dev/null +++ b/test/test_saml_provider.py @@ -0,0 +1,121 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_provider import SAMLProvider + +class TestSAMLProvider(unittest.TestCase): + """SAMLProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SAMLProvider: + """Test SAMLProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SAMLProvider` + """ + model = SAMLProvider() + if include_optional: + return SAMLProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + acs_url = '', + sls_url = '', + audience = '', + issuer_override = '', + assertion_valid_not_before = '', + assertion_valid_not_on_or_after = '', + session_valid_not_on_or_after = '', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + verification_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_response = True, + sign_logout_request = True, + sign_logout_response = True, + sp_binding = 'redirect', + sls_binding = 'redirect', + logout_method = 'frontchannel_iframe', + default_relay_state = '', + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + url_download_metadata = '', + url_issuer = '', + url_unified = '', + url_unified_init = '', + url_sso_post = '', + url_sso_redirect = '', + url_sso_init = '', + url_slo_post = '', + url_slo_redirect = '' + ) + else: + return SAMLProvider( + pk = 56, + name = '', + authorization_flow = '', + invalidation_flow = '', + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + acs_url = '', + url_download_metadata = '', + url_issuer = '', + url_unified = '', + url_unified_init = '', + url_sso_post = '', + url_sso_redirect = '', + url_sso_init = '', + url_slo_post = '', + url_slo_redirect = '', + ) + """ + + def testSAMLProvider(self): + """Test SAMLProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_provider_request.py b/test/test_saml_provider_request.py new file mode 100644 index 000000000..d834f47f4 --- /dev/null +++ b/test/test_saml_provider_request.py @@ -0,0 +1,85 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_provider_request import SAMLProviderRequest + +class TestSAMLProviderRequest(unittest.TestCase): + """SAMLProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SAMLProviderRequest: + """Test SAMLProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SAMLProviderRequest` + """ + model = SAMLProviderRequest() + if include_optional: + return SAMLProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + acs_url = '0', + sls_url = '', + audience = '', + issuer_override = '', + assertion_valid_not_before = '0', + assertion_valid_not_on_or_after = '0', + session_valid_not_on_or_after = '0', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + verification_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_response = True, + sign_logout_request = True, + sign_logout_response = True, + sp_binding = 'redirect', + sls_binding = 'redirect', + logout_method = 'frontchannel_iframe', + default_relay_state = '', + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress' + ) + else: + return SAMLProviderRequest( + name = '0', + authorization_flow = '', + invalidation_flow = '', + acs_url = '0', + ) + """ + + def testSAMLProviderRequest(self): + """Test SAMLProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_source.py b/test/test_saml_source.py new file mode 100644 index 000000000..98af401e8 --- /dev/null +++ b/test/test_saml_source.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_source import SAMLSource + +class TestSAMLSource(unittest.TestCase): + """SAMLSource unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SAMLSource: + """Test SAMLSource + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SAMLSource` + """ + model = SAMLSource() + if include_optional: + return SAMLSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + group_matching_mode = 'identifier', + pre_authentication_flow = '', + issuer = '', + sso_url = '', + slo_url = '', + allow_idp_initiated = True, + force_authn = True, + name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + binding_type = 'REDIRECT', + verification_kp = '', + signing_kp = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + temporary_user_delete_after = '', + encryption_kp = '', + signed_assertion = True, + signed_response = True + ) + else: + return SAMLSource( + pk = '', + name = '', + slug = 'z', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + pre_authentication_flow = '', + sso_url = '', + ) + """ + + def testSAMLSource(self): + """Test SAMLSource""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_source_property_mapping.py b/test/test_saml_source_property_mapping.py new file mode 100644 index 000000000..f8203ca01 --- /dev/null +++ b/test/test_saml_source_property_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_source_property_mapping import SAMLSourcePropertyMapping + +class TestSAMLSourcePropertyMapping(unittest.TestCase): + """SAMLSourcePropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SAMLSourcePropertyMapping: + """Test SAMLSourcePropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SAMLSourcePropertyMapping` + """ + model = SAMLSourcePropertyMapping() + if include_optional: + return SAMLSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return SAMLSourcePropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testSAMLSourcePropertyMapping(self): + """Test SAMLSourcePropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_source_property_mapping_request.py b/test/test_saml_source_property_mapping_request.py new file mode 100644 index 000000000..b7670d57b --- /dev/null +++ b/test/test_saml_source_property_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_source_property_mapping_request import SAMLSourcePropertyMappingRequest + +class TestSAMLSourcePropertyMappingRequest(unittest.TestCase): + """SAMLSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SAMLSourcePropertyMappingRequest: + """Test SAMLSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SAMLSourcePropertyMappingRequest` + """ + model = SAMLSourcePropertyMappingRequest() + if include_optional: + return SAMLSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return SAMLSourcePropertyMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testSAMLSourcePropertyMappingRequest(self): + """Test SAMLSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_saml_source_request.py b/test/test_saml_source_request.py new file mode 100644 index 000000000..ff5f9465e --- /dev/null +++ b/test/test_saml_source_request.py @@ -0,0 +1,88 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.saml_source_request import SAMLSourceRequest + +class TestSAMLSourceRequest(unittest.TestCase): + """SAMLSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SAMLSourceRequest: + """Test SAMLSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SAMLSourceRequest` + """ + model = SAMLSourceRequest() + if include_optional: + return SAMLSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + group_matching_mode = 'identifier', + pre_authentication_flow = '', + issuer = '', + sso_url = '0', + slo_url = '', + allow_idp_initiated = True, + force_authn = True, + name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + binding_type = 'REDIRECT', + verification_kp = '', + signing_kp = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + temporary_user_delete_after = '0', + encryption_kp = '', + signed_assertion = True, + signed_response = True + ) + else: + return SAMLSourceRequest( + name = '0', + slug = 'z0', + pre_authentication_flow = '', + sso_url = '0', + ) + """ + + def testSAMLSourceRequest(self): + """Test SAMLSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_schedule.py b/test/test_schedule.py new file mode 100644 index 000000000..934f7fe1c --- /dev/null +++ b/test/test_schedule.py @@ -0,0 +1,73 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.schedule import Schedule + +class TestSchedule(unittest.TestCase): + """Schedule unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Schedule: + """Test Schedule + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Schedule` + """ + model = Schedule() + if include_optional: + return Schedule( + id = '', + identifier = '', + uid = '', + actor_name = '', + rel_obj_app_label = '', + rel_obj_model = '', + rel_obj_id = '', + crontab = '', + paused = True, + next_run = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + description = '', + last_task_status = 'queued' + ) + else: + return Schedule( + id = '', + identifier = '', + uid = '', + actor_name = '', + rel_obj_app_label = '', + rel_obj_model = '', + crontab = '', + next_run = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + description = '', + last_task_status = 'queued', + ) + """ + + def testSchedule(self): + """Test Schedule""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_schedule_request.py b/test/test_schedule_request.py new file mode 100644 index 000000000..b6b4af9f7 --- /dev/null +++ b/test/test_schedule_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.schedule_request import ScheduleRequest + +class TestScheduleRequest(unittest.TestCase): + """ScheduleRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ScheduleRequest: + """Test ScheduleRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ScheduleRequest` + """ + model = ScheduleRequest() + if include_optional: + return ScheduleRequest( + rel_obj_id = '0', + crontab = '0', + paused = True + ) + else: + return ScheduleRequest( + crontab = '0', + ) + """ + + def testScheduleRequest(self): + """Test ScheduleRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_schema_api.py b/test/test_schema_api.py new file mode 100644 index 000000000..d610365ff --- /dev/null +++ b/test/test_schema_api.py @@ -0,0 +1,38 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.schema_api import SchemaApi + + +class TestSchemaApi(unittest.TestCase): + """SchemaApi unit test stubs""" + + def setUp(self) -> None: + self.api = SchemaApi() + + def tearDown(self) -> None: + pass + + def test_schema_retrieve(self) -> None: + """Test case for schema_retrieve + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_authentication_mode_enum.py b/test/test_scim_authentication_mode_enum.py new file mode 100644 index 000000000..84130377c --- /dev/null +++ b/test/test_scim_authentication_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_authentication_mode_enum import SCIMAuthenticationModeEnum + +class TestSCIMAuthenticationModeEnum(unittest.TestCase): + """SCIMAuthenticationModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSCIMAuthenticationModeEnum(self): + """Test SCIMAuthenticationModeEnum""" + # inst = SCIMAuthenticationModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_mapping.py b/test/test_scim_mapping.py new file mode 100644 index 000000000..34752d652 --- /dev/null +++ b/test/test_scim_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_mapping import SCIMMapping + +class TestSCIMMapping(unittest.TestCase): + """SCIMMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMMapping: + """Test SCIMMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMMapping` + """ + model = SCIMMapping() + if include_optional: + return SCIMMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return SCIMMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testSCIMMapping(self): + """Test SCIMMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_mapping_request.py b/test/test_scim_mapping_request.py new file mode 100644 index 000000000..96355dc42 --- /dev/null +++ b/test/test_scim_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_mapping_request import SCIMMappingRequest + +class TestSCIMMappingRequest(unittest.TestCase): + """SCIMMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMMappingRequest: + """Test SCIMMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMMappingRequest` + """ + model = SCIMMappingRequest() + if include_optional: + return SCIMMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return SCIMMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testSCIMMappingRequest(self): + """Test SCIMMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_provider.py b/test/test_scim_provider.py new file mode 100644 index 000000000..66a48ec70 --- /dev/null +++ b/test/test_scim_provider.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_provider import SCIMProvider + +class TestSCIMProvider(unittest.TestCase): + """SCIMProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMProvider: + """Test SCIMProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMProvider` + """ + model = SCIMProvider() + if include_optional: + return SCIMProvider( + pk = 56, + name = '', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + verify_certificates = True, + token = '', + auth_mode = 'token', + auth_oauth = '', + auth_oauth_params = { + 'key' : null + }, + compatibility_mode = 'default', + service_provider_config_cache_timeout = '', + exclude_users_service_account = True, + sync_page_size = 1, + sync_page_timeout = '', + group_filters = [ + '' + ], + dry_run = True + ) + else: + return SCIMProvider( + pk = 56, + name = '', + component = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + url = '', + ) + """ + + def testSCIMProvider(self): + """Test SCIMProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_provider_group.py b/test/test_scim_provider_group.py new file mode 100644 index 000000000..aeaade7dc --- /dev/null +++ b/test/test_scim_provider_group.py @@ -0,0 +1,81 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_provider_group import SCIMProviderGroup + +class TestSCIMProviderGroup(unittest.TestCase): + """SCIMProviderGroup unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMProviderGroup: + """Test SCIMProviderGroup + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMProviderGroup` + """ + model = SCIMProviderGroup() + if include_optional: + return SCIMProviderGroup( + id = '', + scim_id = '', + group = '', + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + provider = 56, + attributes = { + 'key' : null + } + ) + else: + return SCIMProviderGroup( + id = '', + scim_id = '', + group = '', + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + provider = 56, + attributes = { + 'key' : null + }, + ) + """ + + def testSCIMProviderGroup(self): + """Test SCIMProviderGroup""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_provider_group_request.py b/test/test_scim_provider_group_request.py new file mode 100644 index 000000000..fadf6e3e2 --- /dev/null +++ b/test/test_scim_provider_group_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_provider_group_request import SCIMProviderGroupRequest + +class TestSCIMProviderGroupRequest(unittest.TestCase): + """SCIMProviderGroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMProviderGroupRequest: + """Test SCIMProviderGroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMProviderGroupRequest` + """ + model = SCIMProviderGroupRequest() + if include_optional: + return SCIMProviderGroupRequest( + scim_id = '0', + group = '', + provider = 56 + ) + else: + return SCIMProviderGroupRequest( + scim_id = '0', + group = '', + provider = 56, + ) + """ + + def testSCIMProviderGroupRequest(self): + """Test SCIMProviderGroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_provider_request.py b/test/test_scim_provider_request.py new file mode 100644 index 000000000..ecb1118eb --- /dev/null +++ b/test/test_scim_provider_request.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_provider_request import SCIMProviderRequest + +class TestSCIMProviderRequest(unittest.TestCase): + """SCIMProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMProviderRequest: + """Test SCIMProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMProviderRequest` + """ + model = SCIMProviderRequest() + if include_optional: + return SCIMProviderRequest( + name = '0', + property_mappings = [ + '' + ], + property_mappings_group = [ + '' + ], + url = '0', + verify_certificates = True, + token = '', + auth_mode = 'token', + auth_oauth = '', + auth_oauth_params = { + 'key' : null + }, + compatibility_mode = 'default', + service_provider_config_cache_timeout = '0', + exclude_users_service_account = True, + sync_page_size = 1, + sync_page_timeout = '0', + group_filters = [ + '' + ], + dry_run = True + ) + else: + return SCIMProviderRequest( + name = '0', + url = '0', + ) + """ + + def testSCIMProviderRequest(self): + """Test SCIMProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_provider_user.py b/test/test_scim_provider_user.py new file mode 100644 index 000000000..fd1510b50 --- /dev/null +++ b/test/test_scim_provider_user.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_provider_user import SCIMProviderUser + +class TestSCIMProviderUser(unittest.TestCase): + """SCIMProviderUser unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMProviderUser: + """Test SCIMProviderUser + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMProviderUser` + """ + model = SCIMProviderUser() + if include_optional: + return SCIMProviderUser( + id = '', + scim_id = '', + user = 56, + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + provider = 56, + attributes = { + 'key' : null + } + ) + else: + return SCIMProviderUser( + id = '', + scim_id = '', + user = 56, + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + provider = 56, + attributes = { + 'key' : null + }, + ) + """ + + def testSCIMProviderUser(self): + """Test SCIMProviderUser""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_provider_user_request.py b/test/test_scim_provider_user_request.py new file mode 100644 index 000000000..1b64d0df3 --- /dev/null +++ b/test/test_scim_provider_user_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_provider_user_request import SCIMProviderUserRequest + +class TestSCIMProviderUserRequest(unittest.TestCase): + """SCIMProviderUserRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMProviderUserRequest: + """Test SCIMProviderUserRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMProviderUserRequest` + """ + model = SCIMProviderUserRequest() + if include_optional: + return SCIMProviderUserRequest( + scim_id = '0', + user = 56, + provider = 56 + ) + else: + return SCIMProviderUserRequest( + scim_id = '0', + user = 56, + provider = 56, + ) + """ + + def testSCIMProviderUserRequest(self): + """Test SCIMProviderUserRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_source.py b/test/test_scim_source.py new file mode 100644 index 000000000..95cae6dce --- /dev/null +++ b/test/test_scim_source.py @@ -0,0 +1,97 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_source import SCIMSource + +class TestSCIMSource(unittest.TestCase): + """SCIMSource unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMSource: + """Test SCIMSource + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMSource` + """ + model = SCIMSource() + if include_optional: + return SCIMSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + user_path_template = '', + root_url = '', + token_obj = authentik_client.models.token.Token( + pk = '', + managed = '', + identifier = 'z', + intent = 'verification', + user = 56, + user_obj = null, + description = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True, ) + ) + else: + return SCIMSource( + pk = '', + name = '', + slug = 'z', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + root_url = '', + token_obj = authentik_client.models.token.Token( + pk = '', + managed = '', + identifier = 'z', + intent = 'verification', + user = 56, + user_obj = null, + description = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True, ), + ) + """ + + def testSCIMSource(self): + """Test SCIMSource""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_source_group.py b/test/test_scim_source_group.py new file mode 100644 index 000000000..79a1e9eb8 --- /dev/null +++ b/test/test_scim_source_group.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_source_group import SCIMSourceGroup + +class TestSCIMSourceGroup(unittest.TestCase): + """SCIMSourceGroup unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMSourceGroup: + """Test SCIMSourceGroup + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMSourceGroup` + """ + model = SCIMSourceGroup() + if include_optional: + return SCIMSourceGroup( + id = '', + external_id = '', + group = '', + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + source = '', + attributes = { + 'key' : null + } + ) + else: + return SCIMSourceGroup( + external_id = '', + group = '', + group_obj = authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ), + source = '', + ) + """ + + def testSCIMSourceGroup(self): + """Test SCIMSourceGroup""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_source_group_request.py b/test/test_scim_source_group_request.py new file mode 100644 index 000000000..9e8ae4ae9 --- /dev/null +++ b/test/test_scim_source_group_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_source_group_request import SCIMSourceGroupRequest + +class TestSCIMSourceGroupRequest(unittest.TestCase): + """SCIMSourceGroupRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMSourceGroupRequest: + """Test SCIMSourceGroupRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMSourceGroupRequest` + """ + model = SCIMSourceGroupRequest() + if include_optional: + return SCIMSourceGroupRequest( + id = '0', + external_id = '0', + group = '', + source = '', + attributes = { + 'key' : null + } + ) + else: + return SCIMSourceGroupRequest( + external_id = '0', + group = '', + source = '', + ) + """ + + def testSCIMSourceGroupRequest(self): + """Test SCIMSourceGroupRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_source_property_mapping.py b/test/test_scim_source_property_mapping.py new file mode 100644 index 000000000..c85c00089 --- /dev/null +++ b/test/test_scim_source_property_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_source_property_mapping import SCIMSourcePropertyMapping + +class TestSCIMSourcePropertyMapping(unittest.TestCase): + """SCIMSourcePropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMSourcePropertyMapping: + """Test SCIMSourcePropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMSourcePropertyMapping` + """ + model = SCIMSourcePropertyMapping() + if include_optional: + return SCIMSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return SCIMSourcePropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testSCIMSourcePropertyMapping(self): + """Test SCIMSourcePropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_source_property_mapping_request.py b/test/test_scim_source_property_mapping_request.py new file mode 100644 index 000000000..cc77defd7 --- /dev/null +++ b/test/test_scim_source_property_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_source_property_mapping_request import SCIMSourcePropertyMappingRequest + +class TestSCIMSourcePropertyMappingRequest(unittest.TestCase): + """SCIMSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMSourcePropertyMappingRequest: + """Test SCIMSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMSourcePropertyMappingRequest` + """ + model = SCIMSourcePropertyMappingRequest() + if include_optional: + return SCIMSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return SCIMSourcePropertyMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testSCIMSourcePropertyMappingRequest(self): + """Test SCIMSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_source_request.py b/test/test_scim_source_request.py new file mode 100644 index 000000000..18296ec4b --- /dev/null +++ b/test/test_scim_source_request.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_source_request import SCIMSourceRequest + +class TestSCIMSourceRequest(unittest.TestCase): + """SCIMSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMSourceRequest: + """Test SCIMSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMSourceRequest` + """ + model = SCIMSourceRequest() + if include_optional: + return SCIMSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + user_path_template = '0' + ) + else: + return SCIMSourceRequest( + name = '0', + slug = 'z0', + ) + """ + + def testSCIMSourceRequest(self): + """Test SCIMSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_source_user.py b/test/test_scim_source_user.py new file mode 100644 index 000000000..888a469ae --- /dev/null +++ b/test/test_scim_source_user.py @@ -0,0 +1,83 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_source_user import SCIMSourceUser + +class TestSCIMSourceUser(unittest.TestCase): + """SCIMSourceUser unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMSourceUser: + """Test SCIMSourceUser + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMSourceUser` + """ + model = SCIMSourceUser() + if include_optional: + return SCIMSourceUser( + id = '', + external_id = '', + user = 56, + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + source = '', + attributes = { + 'key' : null + } + ) + else: + return SCIMSourceUser( + external_id = '', + user = 56, + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + source = '', + ) + """ + + def testSCIMSourceUser(self): + """Test SCIMSourceUser""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scim_source_user_request.py b/test/test_scim_source_user_request.py new file mode 100644 index 000000000..f51f6f2db --- /dev/null +++ b/test/test_scim_source_user_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scim_source_user_request import SCIMSourceUserRequest + +class TestSCIMSourceUserRequest(unittest.TestCase): + """SCIMSourceUserRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SCIMSourceUserRequest: + """Test SCIMSourceUserRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SCIMSourceUserRequest` + """ + model = SCIMSourceUserRequest() + if include_optional: + return SCIMSourceUserRequest( + id = '0', + external_id = '0', + user = 56, + source = '', + attributes = { + 'key' : null + } + ) + else: + return SCIMSourceUserRequest( + external_id = '0', + user = 56, + source = '', + ) + """ + + def testSCIMSourceUserRequest(self): + """Test SCIMSourceUserRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scope_mapping.py b/test/test_scope_mapping.py new file mode 100644 index 000000000..8c83120eb --- /dev/null +++ b/test/test_scope_mapping.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scope_mapping import ScopeMapping + +class TestScopeMapping(unittest.TestCase): + """ScopeMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ScopeMapping: + """Test ScopeMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ScopeMapping` + """ + model = ScopeMapping() + if include_optional: + return ScopeMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + scope_name = '', + description = '' + ) + else: + return ScopeMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + scope_name = '', + ) + """ + + def testScopeMapping(self): + """Test ScopeMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_scope_mapping_request.py b/test/test_scope_mapping_request.py new file mode 100644 index 000000000..baac4ad4f --- /dev/null +++ b/test/test_scope_mapping_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.scope_mapping_request import ScopeMappingRequest + +class TestScopeMappingRequest(unittest.TestCase): + """ScopeMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ScopeMappingRequest: + """Test ScopeMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ScopeMappingRequest` + """ + model = ScopeMappingRequest() + if include_optional: + return ScopeMappingRequest( + managed = '0', + name = '0', + expression = '0', + scope_name = '0', + description = '' + ) + else: + return ScopeMappingRequest( + name = '0', + expression = '0', + scope_name = '0', + ) + """ + + def testScopeMappingRequest(self): + """Test ScopeMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_selectable_stage.py b/test/test_selectable_stage.py new file mode 100644 index 000000000..bd834dc5d --- /dev/null +++ b/test/test_selectable_stage.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.selectable_stage import SelectableStage + +class TestSelectableStage(unittest.TestCase): + """SelectableStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SelectableStage: + """Test SelectableStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SelectableStage` + """ + model = SelectableStage() + if include_optional: + return SelectableStage( + pk = '', + name = '', + verbose_name = '', + meta_model_name = '' + ) + else: + return SelectableStage( + pk = '', + name = '', + verbose_name = '', + meta_model_name = '', + ) + """ + + def testSelectableStage(self): + """Test SelectableStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_service_connection.py b/test/test_service_connection.py new file mode 100644 index 000000000..bc2dee642 --- /dev/null +++ b/test/test_service_connection.py @@ -0,0 +1,64 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.service_connection import ServiceConnection + +class TestServiceConnection(unittest.TestCase): + """ServiceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ServiceConnection: + """Test ServiceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ServiceConnection` + """ + model = ServiceConnection() + if include_optional: + return ServiceConnection( + pk = '', + name = '', + local = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return ServiceConnection( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testServiceConnection(self): + """Test ServiceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_service_connection_state.py b/test/test_service_connection_state.py new file mode 100644 index 000000000..5b47d426e --- /dev/null +++ b/test/test_service_connection_state.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.service_connection_state import ServiceConnectionState + +class TestServiceConnectionState(unittest.TestCase): + """ServiceConnectionState unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ServiceConnectionState: + """Test ServiceConnectionState + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ServiceConnectionState` + """ + model = ServiceConnectionState() + if include_optional: + return ServiceConnectionState( + healthy = True, + version = '' + ) + else: + return ServiceConnectionState( + healthy = True, + version = '', + ) + """ + + def testServiceConnectionState(self): + """Test ServiceConnectionState""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_session_end_challenge.py b/test/test_session_end_challenge.py new file mode 100644 index 000000000..2aaea59a5 --- /dev/null +++ b/test/test_session_end_challenge.py @@ -0,0 +1,74 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.session_end_challenge import SessionEndChallenge + +class TestSessionEndChallenge(unittest.TestCase): + """SessionEndChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SessionEndChallenge: + """Test SessionEndChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SessionEndChallenge` + """ + model = SessionEndChallenge() + if include_optional: + return SessionEndChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-session-end', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '', + application_name = '', + application_launch_url = '', + invalidation_flow_url = '', + brand_name = '' + ) + else: + return SessionEndChallenge( + pending_user = '', + pending_user_avatar = '', + brand_name = '', + ) + """ + + def testSessionEndChallenge(self): + """Test SessionEndChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_session_user.py b/test/test_session_user.py new file mode 100644 index 000000000..7eb988631 --- /dev/null +++ b/test/test_session_user.py @@ -0,0 +1,129 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.session_user import SessionUser + +class TestSessionUser(unittest.TestCase): + """SessionUser unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SessionUser: + """Test SessionUser + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SessionUser` + """ + model = SessionUser() + if include_optional: + return SessionUser( + user = authentik_client.models.user_self.UserSelf( + pk = 56, + username = 'A', + name = '', + is_active = True, + is_superuser = True, + groups = [ + authentik_client.models.user_self_groups.UserSelfGroups( + name = '', + pk = '', ) + ], + roles = [ + authentik_client.models.user_self_roles.UserSelfRoles( + name = '', + pk = '', ) + ], + email = '', + avatar = '', + uid = '', + settings = { + 'key' : null + }, + type = 'internal', + system_permissions = [ + '' + ], ), + original = authentik_client.models.user_self.UserSelf( + pk = 56, + username = 'A', + name = '', + is_active = True, + is_superuser = True, + groups = [ + authentik_client.models.user_self_groups.UserSelfGroups( + name = '', + pk = '', ) + ], + roles = [ + authentik_client.models.user_self_roles.UserSelfRoles( + name = '', + pk = '', ) + ], + email = '', + avatar = '', + uid = '', + settings = { + 'key' : null + }, + type = 'internal', + system_permissions = [ + '' + ], ) + ) + else: + return SessionUser( + user = authentik_client.models.user_self.UserSelf( + pk = 56, + username = 'A', + name = '', + is_active = True, + is_superuser = True, + groups = [ + authentik_client.models.user_self_groups.UserSelfGroups( + name = '', + pk = '', ) + ], + roles = [ + authentik_client.models.user_self_roles.UserSelfRoles( + name = '', + pk = '', ) + ], + email = '', + avatar = '', + uid = '', + settings = { + 'key' : null + }, + type = 'internal', + system_permissions = [ + '' + ], ), + ) + """ + + def testSessionUser(self): + """Test SessionUser""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_settings.py b/test/test_settings.py new file mode 100644 index 000000000..c1bbf1ea5 --- /dev/null +++ b/test/test_settings.py @@ -0,0 +1,76 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.settings import Settings + +class TestSettings(unittest.TestCase): + """Settings unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Settings: + """Test Settings + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Settings` + """ + model = Settings() + if include_optional: + return Settings( + avatars = '', + default_user_change_name = True, + default_user_change_email = True, + default_user_change_username = True, + event_retention = '', + reputation_lower_limit = -2147483648, + reputation_upper_limit = 0, + footer_links = None, + gdpr_compliance = True, + impersonation = True, + impersonation_require_reason = True, + default_token_duration = '', + default_token_length = 1, + pagination_default_page_size = 0, + pagination_max_page_size = 0, + flags = authentik_client.models.patched_settings_request_flags.PatchedSettingsRequest_flags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True, ) + ) + else: + return Settings( + flags = authentik_client.models.patched_settings_request_flags.PatchedSettingsRequest_flags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True, ), + ) + """ + + def testSettings(self): + """Test Settings""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_settings_request.py b/test/test_settings_request.py new file mode 100644 index 000000000..e7c72ae5a --- /dev/null +++ b/test/test_settings_request.py @@ -0,0 +1,76 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.settings_request import SettingsRequest + +class TestSettingsRequest(unittest.TestCase): + """SettingsRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SettingsRequest: + """Test SettingsRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SettingsRequest` + """ + model = SettingsRequest() + if include_optional: + return SettingsRequest( + avatars = '0', + default_user_change_name = True, + default_user_change_email = True, + default_user_change_username = True, + event_retention = '0', + reputation_lower_limit = -2147483648, + reputation_upper_limit = 0, + footer_links = None, + gdpr_compliance = True, + impersonation = True, + impersonation_require_reason = True, + default_token_duration = '0', + default_token_length = 1, + pagination_default_page_size = 0, + pagination_max_page_size = 0, + flags = authentik_client.models.patched_settings_request_flags.PatchedSettingsRequest_flags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True, ) + ) + else: + return SettingsRequest( + flags = authentik_client.models.patched_settings_request_flags.PatchedSettingsRequest_flags( + core_default_app_access = True, + enterprise_audit_include_expanded_diff = True, + flows_continuous_login = True, + flows_refresh_others = True, ), + ) + """ + + def testSettingsRequest(self): + """Test SettingsRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_severity_enum.py b/test/test_severity_enum.py new file mode 100644 index 000000000..2be86d5aa --- /dev/null +++ b/test/test_severity_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.severity_enum import SeverityEnum + +class TestSeverityEnum(unittest.TestCase): + """SeverityEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSeverityEnum(self): + """Test SeverityEnum""" + # inst = SeverityEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_shell_challenge.py b/test/test_shell_challenge.py new file mode 100644 index 000000000..71318f194 --- /dev/null +++ b/test/test_shell_challenge.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.shell_challenge import ShellChallenge + +class TestShellChallenge(unittest.TestCase): + """ShellChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ShellChallenge: + """Test ShellChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ShellChallenge` + """ + model = ShellChallenge() + if include_optional: + return ShellChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'xak-flow-shell', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + body = '' + ) + else: + return ShellChallenge( + body = '', + ) + """ + + def testShellChallenge(self): + """Test ShellChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_signature_algorithm_enum.py b/test/test_signature_algorithm_enum.py new file mode 100644 index 000000000..683c33813 --- /dev/null +++ b/test/test_signature_algorithm_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.signature_algorithm_enum import SignatureAlgorithmEnum + +class TestSignatureAlgorithmEnum(unittest.TestCase): + """SignatureAlgorithmEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSignatureAlgorithmEnum(self): + """Test SignatureAlgorithmEnum""" + # inst = SignatureAlgorithmEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_sms_device.py b/test/test_sms_device.py new file mode 100644 index 000000000..c61722811 --- /dev/null +++ b/test/test_sms_device.py @@ -0,0 +1,79 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.sms_device import SMSDevice + +class TestSMSDevice(unittest.TestCase): + """SMSDevice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SMSDevice: + """Test SMSDevice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SMSDevice` + """ + model = SMSDevice() + if include_optional: + return SMSDevice( + name = '', + pk = 56, + phone_number = '', + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ) + else: + return SMSDevice( + name = '', + pk = 56, + phone_number = '', + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + ) + """ + + def testSMSDevice(self): + """Test SMSDevice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_sms_device_request.py b/test/test_sms_device_request.py new file mode 100644 index 000000000..0c486e3ab --- /dev/null +++ b/test/test_sms_device_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.sms_device_request import SMSDeviceRequest + +class TestSMSDeviceRequest(unittest.TestCase): + """SMSDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SMSDeviceRequest: + """Test SMSDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SMSDeviceRequest` + """ + model = SMSDeviceRequest() + if include_optional: + return SMSDeviceRequest( + name = '0' + ) + else: + return SMSDeviceRequest( + name = '0', + ) + """ + + def testSMSDeviceRequest(self): + """Test SMSDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_software.py b/test/test_software.py new file mode 100644 index 000000000..9ff4664fc --- /dev/null +++ b/test/test_software.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.software import Software + +class TestSoftware(unittest.TestCase): + """Software unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Software: + """Test Software + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Software` + """ + model = Software() + if include_optional: + return Software( + name = '', + version = '', + source = '', + path = '' + ) + else: + return Software( + name = '', + source = '', + ) + """ + + def testSoftware(self): + """Test Software""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_software_request.py b/test/test_software_request.py new file mode 100644 index 000000000..feb53063c --- /dev/null +++ b/test/test_software_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.software_request import SoftwareRequest + +class TestSoftwareRequest(unittest.TestCase): + """SoftwareRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SoftwareRequest: + """Test SoftwareRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SoftwareRequest` + """ + model = SoftwareRequest() + if include_optional: + return SoftwareRequest( + name = '0', + version = '', + source = '0', + path = '0' + ) + else: + return SoftwareRequest( + name = '0', + source = '0', + ) + """ + + def testSoftwareRequest(self): + """Test SoftwareRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_source.py b/test/test_source.py new file mode 100644 index 000000000..d707798e8 --- /dev/null +++ b/test/test_source.py @@ -0,0 +1,89 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.source import Source + +class TestSource(unittest.TestCase): + """Source unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Source: + """Test Source + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Source` + """ + model = Source() + if include_optional: + return Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ) + ) + else: + return Source( + pk = '', + name = '', + slug = 'z', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + ) + """ + + def testSource(self): + """Test Source""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_source_stage.py b/test/test_source_stage.py new file mode 100644 index 000000000..df7db8581 --- /dev/null +++ b/test/test_source_stage.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.source_stage import SourceStage + +class TestSourceStage(unittest.TestCase): + """SourceStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SourceStage: + """Test SourceStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SourceStage` + """ + model = SourceStage() + if include_optional: + return SourceStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + source = '', + resume_timeout = '' + ) + else: + return SourceStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + source = '', + ) + """ + + def testSourceStage(self): + """Test SourceStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_source_stage_request.py b/test/test_source_stage_request.py new file mode 100644 index 000000000..5156efd4c --- /dev/null +++ b/test/test_source_stage_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.source_stage_request import SourceStageRequest + +class TestSourceStageRequest(unittest.TestCase): + """SourceStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SourceStageRequest: + """Test SourceStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SourceStageRequest` + """ + model = SourceStageRequest() + if include_optional: + return SourceStageRequest( + name = '0', + source = '', + resume_timeout = '0' + ) + else: + return SourceStageRequest( + name = '0', + source = '', + ) + """ + + def testSourceStageRequest(self): + """Test SourceStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_source_type.py b/test/test_source_type.py new file mode 100644 index 000000000..3be982b59 --- /dev/null +++ b/test/test_source_type.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.source_type import SourceType + +class TestSourceType(unittest.TestCase): + """SourceType unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SourceType: + """Test SourceType + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SourceType` + """ + model = SourceType() + if include_optional: + return SourceType( + name = '', + verbose_name = '', + urls_customizable = True, + request_token_url = '', + authorization_url = '', + access_token_url = '', + profile_url = '', + oidc_well_known_url = '', + oidc_jwks_url = '' + ) + else: + return SourceType( + name = '', + verbose_name = '', + urls_customizable = True, + request_token_url = '', + authorization_url = '', + access_token_url = '', + profile_url = '', + oidc_well_known_url = '', + oidc_jwks_url = '', + ) + """ + + def testSourceType(self): + """Test SourceType""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_sources_api.py b/test/test_sources_api.py new file mode 100644 index 000000000..9a40ee47e --- /dev/null +++ b/test/test_sources_api.py @@ -0,0 +1,1070 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.sources_api import SourcesApi + + +class TestSourcesApi(unittest.TestCase): + """SourcesApi unit test stubs""" + + def setUp(self) -> None: + self.api = SourcesApi() + + def tearDown(self) -> None: + pass + + def test_sources_all_destroy(self) -> None: + """Test case for sources_all_destroy + + """ + pass + + def test_sources_all_list(self) -> None: + """Test case for sources_all_list + + """ + pass + + def test_sources_all_retrieve(self) -> None: + """Test case for sources_all_retrieve + + """ + pass + + def test_sources_all_types_list(self) -> None: + """Test case for sources_all_types_list + + """ + pass + + def test_sources_all_used_by_list(self) -> None: + """Test case for sources_all_used_by_list + + """ + pass + + def test_sources_all_user_settings_list(self) -> None: + """Test case for sources_all_user_settings_list + + """ + pass + + def test_sources_group_connections_all_destroy(self) -> None: + """Test case for sources_group_connections_all_destroy + + """ + pass + + def test_sources_group_connections_all_list(self) -> None: + """Test case for sources_group_connections_all_list + + """ + pass + + def test_sources_group_connections_all_partial_update(self) -> None: + """Test case for sources_group_connections_all_partial_update + + """ + pass + + def test_sources_group_connections_all_retrieve(self) -> None: + """Test case for sources_group_connections_all_retrieve + + """ + pass + + def test_sources_group_connections_all_update(self) -> None: + """Test case for sources_group_connections_all_update + + """ + pass + + def test_sources_group_connections_all_used_by_list(self) -> None: + """Test case for sources_group_connections_all_used_by_list + + """ + pass + + def test_sources_group_connections_kerberos_create(self) -> None: + """Test case for sources_group_connections_kerberos_create + + """ + pass + + def test_sources_group_connections_kerberos_destroy(self) -> None: + """Test case for sources_group_connections_kerberos_destroy + + """ + pass + + def test_sources_group_connections_kerberos_list(self) -> None: + """Test case for sources_group_connections_kerberos_list + + """ + pass + + def test_sources_group_connections_kerberos_partial_update(self) -> None: + """Test case for sources_group_connections_kerberos_partial_update + + """ + pass + + def test_sources_group_connections_kerberos_retrieve(self) -> None: + """Test case for sources_group_connections_kerberos_retrieve + + """ + pass + + def test_sources_group_connections_kerberos_update(self) -> None: + """Test case for sources_group_connections_kerberos_update + + """ + pass + + def test_sources_group_connections_kerberos_used_by_list(self) -> None: + """Test case for sources_group_connections_kerberos_used_by_list + + """ + pass + + def test_sources_group_connections_ldap_create(self) -> None: + """Test case for sources_group_connections_ldap_create + + """ + pass + + def test_sources_group_connections_ldap_destroy(self) -> None: + """Test case for sources_group_connections_ldap_destroy + + """ + pass + + def test_sources_group_connections_ldap_list(self) -> None: + """Test case for sources_group_connections_ldap_list + + """ + pass + + def test_sources_group_connections_ldap_partial_update(self) -> None: + """Test case for sources_group_connections_ldap_partial_update + + """ + pass + + def test_sources_group_connections_ldap_retrieve(self) -> None: + """Test case for sources_group_connections_ldap_retrieve + + """ + pass + + def test_sources_group_connections_ldap_update(self) -> None: + """Test case for sources_group_connections_ldap_update + + """ + pass + + def test_sources_group_connections_ldap_used_by_list(self) -> None: + """Test case for sources_group_connections_ldap_used_by_list + + """ + pass + + def test_sources_group_connections_oauth_create(self) -> None: + """Test case for sources_group_connections_oauth_create + + """ + pass + + def test_sources_group_connections_oauth_destroy(self) -> None: + """Test case for sources_group_connections_oauth_destroy + + """ + pass + + def test_sources_group_connections_oauth_list(self) -> None: + """Test case for sources_group_connections_oauth_list + + """ + pass + + def test_sources_group_connections_oauth_partial_update(self) -> None: + """Test case for sources_group_connections_oauth_partial_update + + """ + pass + + def test_sources_group_connections_oauth_retrieve(self) -> None: + """Test case for sources_group_connections_oauth_retrieve + + """ + pass + + def test_sources_group_connections_oauth_update(self) -> None: + """Test case for sources_group_connections_oauth_update + + """ + pass + + def test_sources_group_connections_oauth_used_by_list(self) -> None: + """Test case for sources_group_connections_oauth_used_by_list + + """ + pass + + def test_sources_group_connections_plex_create(self) -> None: + """Test case for sources_group_connections_plex_create + + """ + pass + + def test_sources_group_connections_plex_destroy(self) -> None: + """Test case for sources_group_connections_plex_destroy + + """ + pass + + def test_sources_group_connections_plex_list(self) -> None: + """Test case for sources_group_connections_plex_list + + """ + pass + + def test_sources_group_connections_plex_partial_update(self) -> None: + """Test case for sources_group_connections_plex_partial_update + + """ + pass + + def test_sources_group_connections_plex_retrieve(self) -> None: + """Test case for sources_group_connections_plex_retrieve + + """ + pass + + def test_sources_group_connections_plex_update(self) -> None: + """Test case for sources_group_connections_plex_update + + """ + pass + + def test_sources_group_connections_plex_used_by_list(self) -> None: + """Test case for sources_group_connections_plex_used_by_list + + """ + pass + + def test_sources_group_connections_saml_create(self) -> None: + """Test case for sources_group_connections_saml_create + + """ + pass + + def test_sources_group_connections_saml_destroy(self) -> None: + """Test case for sources_group_connections_saml_destroy + + """ + pass + + def test_sources_group_connections_saml_list(self) -> None: + """Test case for sources_group_connections_saml_list + + """ + pass + + def test_sources_group_connections_saml_partial_update(self) -> None: + """Test case for sources_group_connections_saml_partial_update + + """ + pass + + def test_sources_group_connections_saml_retrieve(self) -> None: + """Test case for sources_group_connections_saml_retrieve + + """ + pass + + def test_sources_group_connections_saml_update(self) -> None: + """Test case for sources_group_connections_saml_update + + """ + pass + + def test_sources_group_connections_saml_used_by_list(self) -> None: + """Test case for sources_group_connections_saml_used_by_list + + """ + pass + + def test_sources_group_connections_telegram_create(self) -> None: + """Test case for sources_group_connections_telegram_create + + """ + pass + + def test_sources_group_connections_telegram_destroy(self) -> None: + """Test case for sources_group_connections_telegram_destroy + + """ + pass + + def test_sources_group_connections_telegram_list(self) -> None: + """Test case for sources_group_connections_telegram_list + + """ + pass + + def test_sources_group_connections_telegram_partial_update(self) -> None: + """Test case for sources_group_connections_telegram_partial_update + + """ + pass + + def test_sources_group_connections_telegram_retrieve(self) -> None: + """Test case for sources_group_connections_telegram_retrieve + + """ + pass + + def test_sources_group_connections_telegram_update(self) -> None: + """Test case for sources_group_connections_telegram_update + + """ + pass + + def test_sources_group_connections_telegram_used_by_list(self) -> None: + """Test case for sources_group_connections_telegram_used_by_list + + """ + pass + + def test_sources_kerberos_create(self) -> None: + """Test case for sources_kerberos_create + + """ + pass + + def test_sources_kerberos_destroy(self) -> None: + """Test case for sources_kerberos_destroy + + """ + pass + + def test_sources_kerberos_list(self) -> None: + """Test case for sources_kerberos_list + + """ + pass + + def test_sources_kerberos_partial_update(self) -> None: + """Test case for sources_kerberos_partial_update + + """ + pass + + def test_sources_kerberos_retrieve(self) -> None: + """Test case for sources_kerberos_retrieve + + """ + pass + + def test_sources_kerberos_sync_status_retrieve(self) -> None: + """Test case for sources_kerberos_sync_status_retrieve + + """ + pass + + def test_sources_kerberos_update(self) -> None: + """Test case for sources_kerberos_update + + """ + pass + + def test_sources_kerberos_used_by_list(self) -> None: + """Test case for sources_kerberos_used_by_list + + """ + pass + + def test_sources_ldap_create(self) -> None: + """Test case for sources_ldap_create + + """ + pass + + def test_sources_ldap_debug_retrieve(self) -> None: + """Test case for sources_ldap_debug_retrieve + + """ + pass + + def test_sources_ldap_destroy(self) -> None: + """Test case for sources_ldap_destroy + + """ + pass + + def test_sources_ldap_list(self) -> None: + """Test case for sources_ldap_list + + """ + pass + + def test_sources_ldap_partial_update(self) -> None: + """Test case for sources_ldap_partial_update + + """ + pass + + def test_sources_ldap_retrieve(self) -> None: + """Test case for sources_ldap_retrieve + + """ + pass + + def test_sources_ldap_sync_status_retrieve(self) -> None: + """Test case for sources_ldap_sync_status_retrieve + + """ + pass + + def test_sources_ldap_update(self) -> None: + """Test case for sources_ldap_update + + """ + pass + + def test_sources_ldap_used_by_list(self) -> None: + """Test case for sources_ldap_used_by_list + + """ + pass + + def test_sources_oauth_create(self) -> None: + """Test case for sources_oauth_create + + """ + pass + + def test_sources_oauth_destroy(self) -> None: + """Test case for sources_oauth_destroy + + """ + pass + + def test_sources_oauth_list(self) -> None: + """Test case for sources_oauth_list + + """ + pass + + def test_sources_oauth_partial_update(self) -> None: + """Test case for sources_oauth_partial_update + + """ + pass + + def test_sources_oauth_retrieve(self) -> None: + """Test case for sources_oauth_retrieve + + """ + pass + + def test_sources_oauth_source_types_list(self) -> None: + """Test case for sources_oauth_source_types_list + + """ + pass + + def test_sources_oauth_update(self) -> None: + """Test case for sources_oauth_update + + """ + pass + + def test_sources_oauth_used_by_list(self) -> None: + """Test case for sources_oauth_used_by_list + + """ + pass + + def test_sources_plex_create(self) -> None: + """Test case for sources_plex_create + + """ + pass + + def test_sources_plex_destroy(self) -> None: + """Test case for sources_plex_destroy + + """ + pass + + def test_sources_plex_list(self) -> None: + """Test case for sources_plex_list + + """ + pass + + def test_sources_plex_partial_update(self) -> None: + """Test case for sources_plex_partial_update + + """ + pass + + def test_sources_plex_redeem_token_authenticated_create(self) -> None: + """Test case for sources_plex_redeem_token_authenticated_create + + """ + pass + + def test_sources_plex_redeem_token_create(self) -> None: + """Test case for sources_plex_redeem_token_create + + """ + pass + + def test_sources_plex_retrieve(self) -> None: + """Test case for sources_plex_retrieve + + """ + pass + + def test_sources_plex_update(self) -> None: + """Test case for sources_plex_update + + """ + pass + + def test_sources_plex_used_by_list(self) -> None: + """Test case for sources_plex_used_by_list + + """ + pass + + def test_sources_saml_create(self) -> None: + """Test case for sources_saml_create + + """ + pass + + def test_sources_saml_destroy(self) -> None: + """Test case for sources_saml_destroy + + """ + pass + + def test_sources_saml_list(self) -> None: + """Test case for sources_saml_list + + """ + pass + + def test_sources_saml_metadata_retrieve(self) -> None: + """Test case for sources_saml_metadata_retrieve + + """ + pass + + def test_sources_saml_partial_update(self) -> None: + """Test case for sources_saml_partial_update + + """ + pass + + def test_sources_saml_retrieve(self) -> None: + """Test case for sources_saml_retrieve + + """ + pass + + def test_sources_saml_update(self) -> None: + """Test case for sources_saml_update + + """ + pass + + def test_sources_saml_used_by_list(self) -> None: + """Test case for sources_saml_used_by_list + + """ + pass + + def test_sources_scim_create(self) -> None: + """Test case for sources_scim_create + + """ + pass + + def test_sources_scim_destroy(self) -> None: + """Test case for sources_scim_destroy + + """ + pass + + def test_sources_scim_groups_create(self) -> None: + """Test case for sources_scim_groups_create + + """ + pass + + def test_sources_scim_groups_destroy(self) -> None: + """Test case for sources_scim_groups_destroy + + """ + pass + + def test_sources_scim_groups_list(self) -> None: + """Test case for sources_scim_groups_list + + """ + pass + + def test_sources_scim_groups_partial_update(self) -> None: + """Test case for sources_scim_groups_partial_update + + """ + pass + + def test_sources_scim_groups_retrieve(self) -> None: + """Test case for sources_scim_groups_retrieve + + """ + pass + + def test_sources_scim_groups_update(self) -> None: + """Test case for sources_scim_groups_update + + """ + pass + + def test_sources_scim_groups_used_by_list(self) -> None: + """Test case for sources_scim_groups_used_by_list + + """ + pass + + def test_sources_scim_list(self) -> None: + """Test case for sources_scim_list + + """ + pass + + def test_sources_scim_partial_update(self) -> None: + """Test case for sources_scim_partial_update + + """ + pass + + def test_sources_scim_retrieve(self) -> None: + """Test case for sources_scim_retrieve + + """ + pass + + def test_sources_scim_update(self) -> None: + """Test case for sources_scim_update + + """ + pass + + def test_sources_scim_used_by_list(self) -> None: + """Test case for sources_scim_used_by_list + + """ + pass + + def test_sources_scim_users_create(self) -> None: + """Test case for sources_scim_users_create + + """ + pass + + def test_sources_scim_users_destroy(self) -> None: + """Test case for sources_scim_users_destroy + + """ + pass + + def test_sources_scim_users_list(self) -> None: + """Test case for sources_scim_users_list + + """ + pass + + def test_sources_scim_users_partial_update(self) -> None: + """Test case for sources_scim_users_partial_update + + """ + pass + + def test_sources_scim_users_retrieve(self) -> None: + """Test case for sources_scim_users_retrieve + + """ + pass + + def test_sources_scim_users_update(self) -> None: + """Test case for sources_scim_users_update + + """ + pass + + def test_sources_scim_users_used_by_list(self) -> None: + """Test case for sources_scim_users_used_by_list + + """ + pass + + def test_sources_telegram_connect_user_create(self) -> None: + """Test case for sources_telegram_connect_user_create + + """ + pass + + def test_sources_telegram_create(self) -> None: + """Test case for sources_telegram_create + + """ + pass + + def test_sources_telegram_destroy(self) -> None: + """Test case for sources_telegram_destroy + + """ + pass + + def test_sources_telegram_list(self) -> None: + """Test case for sources_telegram_list + + """ + pass + + def test_sources_telegram_partial_update(self) -> None: + """Test case for sources_telegram_partial_update + + """ + pass + + def test_sources_telegram_retrieve(self) -> None: + """Test case for sources_telegram_retrieve + + """ + pass + + def test_sources_telegram_update(self) -> None: + """Test case for sources_telegram_update + + """ + pass + + def test_sources_telegram_used_by_list(self) -> None: + """Test case for sources_telegram_used_by_list + + """ + pass + + def test_sources_user_connections_all_destroy(self) -> None: + """Test case for sources_user_connections_all_destroy + + """ + pass + + def test_sources_user_connections_all_list(self) -> None: + """Test case for sources_user_connections_all_list + + """ + pass + + def test_sources_user_connections_all_partial_update(self) -> None: + """Test case for sources_user_connections_all_partial_update + + """ + pass + + def test_sources_user_connections_all_retrieve(self) -> None: + """Test case for sources_user_connections_all_retrieve + + """ + pass + + def test_sources_user_connections_all_update(self) -> None: + """Test case for sources_user_connections_all_update + + """ + pass + + def test_sources_user_connections_all_used_by_list(self) -> None: + """Test case for sources_user_connections_all_used_by_list + + """ + pass + + def test_sources_user_connections_kerberos_create(self) -> None: + """Test case for sources_user_connections_kerberos_create + + """ + pass + + def test_sources_user_connections_kerberos_destroy(self) -> None: + """Test case for sources_user_connections_kerberos_destroy + + """ + pass + + def test_sources_user_connections_kerberos_list(self) -> None: + """Test case for sources_user_connections_kerberos_list + + """ + pass + + def test_sources_user_connections_kerberos_partial_update(self) -> None: + """Test case for sources_user_connections_kerberos_partial_update + + """ + pass + + def test_sources_user_connections_kerberos_retrieve(self) -> None: + """Test case for sources_user_connections_kerberos_retrieve + + """ + pass + + def test_sources_user_connections_kerberos_update(self) -> None: + """Test case for sources_user_connections_kerberos_update + + """ + pass + + def test_sources_user_connections_kerberos_used_by_list(self) -> None: + """Test case for sources_user_connections_kerberos_used_by_list + + """ + pass + + def test_sources_user_connections_ldap_create(self) -> None: + """Test case for sources_user_connections_ldap_create + + """ + pass + + def test_sources_user_connections_ldap_destroy(self) -> None: + """Test case for sources_user_connections_ldap_destroy + + """ + pass + + def test_sources_user_connections_ldap_list(self) -> None: + """Test case for sources_user_connections_ldap_list + + """ + pass + + def test_sources_user_connections_ldap_partial_update(self) -> None: + """Test case for sources_user_connections_ldap_partial_update + + """ + pass + + def test_sources_user_connections_ldap_retrieve(self) -> None: + """Test case for sources_user_connections_ldap_retrieve + + """ + pass + + def test_sources_user_connections_ldap_update(self) -> None: + """Test case for sources_user_connections_ldap_update + + """ + pass + + def test_sources_user_connections_ldap_used_by_list(self) -> None: + """Test case for sources_user_connections_ldap_used_by_list + + """ + pass + + def test_sources_user_connections_oauth_create(self) -> None: + """Test case for sources_user_connections_oauth_create + + """ + pass + + def test_sources_user_connections_oauth_destroy(self) -> None: + """Test case for sources_user_connections_oauth_destroy + + """ + pass + + def test_sources_user_connections_oauth_list(self) -> None: + """Test case for sources_user_connections_oauth_list + + """ + pass + + def test_sources_user_connections_oauth_partial_update(self) -> None: + """Test case for sources_user_connections_oauth_partial_update + + """ + pass + + def test_sources_user_connections_oauth_retrieve(self) -> None: + """Test case for sources_user_connections_oauth_retrieve + + """ + pass + + def test_sources_user_connections_oauth_update(self) -> None: + """Test case for sources_user_connections_oauth_update + + """ + pass + + def test_sources_user_connections_oauth_used_by_list(self) -> None: + """Test case for sources_user_connections_oauth_used_by_list + + """ + pass + + def test_sources_user_connections_plex_create(self) -> None: + """Test case for sources_user_connections_plex_create + + """ + pass + + def test_sources_user_connections_plex_destroy(self) -> None: + """Test case for sources_user_connections_plex_destroy + + """ + pass + + def test_sources_user_connections_plex_list(self) -> None: + """Test case for sources_user_connections_plex_list + + """ + pass + + def test_sources_user_connections_plex_partial_update(self) -> None: + """Test case for sources_user_connections_plex_partial_update + + """ + pass + + def test_sources_user_connections_plex_retrieve(self) -> None: + """Test case for sources_user_connections_plex_retrieve + + """ + pass + + def test_sources_user_connections_plex_update(self) -> None: + """Test case for sources_user_connections_plex_update + + """ + pass + + def test_sources_user_connections_plex_used_by_list(self) -> None: + """Test case for sources_user_connections_plex_used_by_list + + """ + pass + + def test_sources_user_connections_saml_create(self) -> None: + """Test case for sources_user_connections_saml_create + + """ + pass + + def test_sources_user_connections_saml_destroy(self) -> None: + """Test case for sources_user_connections_saml_destroy + + """ + pass + + def test_sources_user_connections_saml_list(self) -> None: + """Test case for sources_user_connections_saml_list + + """ + pass + + def test_sources_user_connections_saml_partial_update(self) -> None: + """Test case for sources_user_connections_saml_partial_update + + """ + pass + + def test_sources_user_connections_saml_retrieve(self) -> None: + """Test case for sources_user_connections_saml_retrieve + + """ + pass + + def test_sources_user_connections_saml_update(self) -> None: + """Test case for sources_user_connections_saml_update + + """ + pass + + def test_sources_user_connections_saml_used_by_list(self) -> None: + """Test case for sources_user_connections_saml_used_by_list + + """ + pass + + def test_sources_user_connections_telegram_create(self) -> None: + """Test case for sources_user_connections_telegram_create + + """ + pass + + def test_sources_user_connections_telegram_destroy(self) -> None: + """Test case for sources_user_connections_telegram_destroy + + """ + pass + + def test_sources_user_connections_telegram_list(self) -> None: + """Test case for sources_user_connections_telegram_list + + """ + pass + + def test_sources_user_connections_telegram_partial_update(self) -> None: + """Test case for sources_user_connections_telegram_partial_update + + """ + pass + + def test_sources_user_connections_telegram_retrieve(self) -> None: + """Test case for sources_user_connections_telegram_retrieve + + """ + pass + + def test_sources_user_connections_telegram_update(self) -> None: + """Test case for sources_user_connections_telegram_update + + """ + pass + + def test_sources_user_connections_telegram_used_by_list(self) -> None: + """Test case for sources_user_connections_telegram_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ssf_api.py b/test/test_ssf_api.py new file mode 100644 index 000000000..9705ddd5a --- /dev/null +++ b/test/test_ssf_api.py @@ -0,0 +1,50 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.ssf_api import SsfApi + + +class TestSsfApi(unittest.TestCase): + """SsfApi unit test stubs""" + + def setUp(self) -> None: + self.api = SsfApi() + + def tearDown(self) -> None: + pass + + def test_ssf_streams_destroy(self) -> None: + """Test case for ssf_streams_destroy + + """ + pass + + def test_ssf_streams_list(self) -> None: + """Test case for ssf_streams_list + + """ + pass + + def test_ssf_streams_retrieve(self) -> None: + """Test case for ssf_streams_retrieve + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ssf_provider.py b/test/test_ssf_provider.py new file mode 100644 index 000000000..5d8bc2ced --- /dev/null +++ b/test/test_ssf_provider.py @@ -0,0 +1,130 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ssf_provider import SSFProvider + +class TestSSFProvider(unittest.TestCase): + """SSFProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SSFProvider: + """Test SSFProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SSFProvider` + """ + model = SSFProvider() + if include_optional: + return SSFProvider( + pk = 56, + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + signing_key = '', + token_obj = authentik_client.models.token.Token( + pk = '', + managed = '', + identifier = 'z', + intent = 'verification', + user = 56, + user_obj = null, + description = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True, ), + oidc_auth_providers = [ + 56 + ], + oidc_auth_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + ssf_url = '', + event_retention = '', + push_verify_certificates = True + ) + else: + return SSFProvider( + pk = 56, + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + signing_key = '', + token_obj = authentik_client.models.token.Token( + pk = '', + managed = '', + identifier = 'z', + intent = 'verification', + user = 56, + user_obj = null, + description = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True, ), + oidc_auth_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + ssf_url = '', + ) + """ + + def testSSFProvider(self): + """Test SSFProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ssf_provider_request.py b/test/test_ssf_provider_request.py new file mode 100644 index 000000000..75f8d0ab5 --- /dev/null +++ b/test/test_ssf_provider_request.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ssf_provider_request import SSFProviderRequest + +class TestSSFProviderRequest(unittest.TestCase): + """SSFProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SSFProviderRequest: + """Test SSFProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SSFProviderRequest` + """ + model = SSFProviderRequest() + if include_optional: + return SSFProviderRequest( + name = '0', + signing_key = '', + oidc_auth_providers = [ + 56 + ], + event_retention = '0', + push_verify_certificates = True + ) + else: + return SSFProviderRequest( + name = '0', + signing_key = '', + ) + """ + + def testSSFProviderRequest(self): + """Test SSFProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ssf_stream.py b/test/test_ssf_stream.py new file mode 100644 index 000000000..b60fb52d1 --- /dev/null +++ b/test/test_ssf_stream.py @@ -0,0 +1,137 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ssf_stream import SSFStream + +class TestSSFStream(unittest.TestCase): + """SSFStream unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SSFStream: + """Test SSFStream + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SSFStream` + """ + model = SSFStream() + if include_optional: + return SSFStream( + pk = '', + status = 'enabled', + provider = 56, + provider_obj = authentik_client.models.ssf_provider.SSFProvider( + pk = 56, + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + signing_key = '', + token_obj = null, + oidc_auth_providers = [ + 56 + ], + oidc_auth_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + ssf_url = '', + event_retention = '', + push_verify_certificates = True, ), + delivery_method = 'https://schemas.openid.net/secevent/risc/delivery-method/push', + endpoint_url = '', + events_requested = [ + 'https://schemas.openid.net/secevent/caep/event-type/session-revoked' + ], + format = '', + aud = [ + '' + ], + iss = '' + ) + else: + return SSFStream( + pk = '', + provider = 56, + provider_obj = authentik_client.models.ssf_provider.SSFProvider( + pk = 56, + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + signing_key = '', + token_obj = null, + oidc_auth_providers = [ + 56 + ], + oidc_auth_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + ssf_url = '', + event_retention = '', + push_verify_certificates = True, ), + delivery_method = 'https://schemas.openid.net/secevent/risc/delivery-method/push', + format = '', + iss = '', + ) + """ + + def testSSFStream(self): + """Test SSFStream""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ssf_stream_status_enum.py b/test/test_ssf_stream_status_enum.py new file mode 100644 index 000000000..b85265cf0 --- /dev/null +++ b/test/test_ssf_stream_status_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ssf_stream_status_enum import SSFStreamStatusEnum + +class TestSSFStreamStatusEnum(unittest.TestCase): + """SSFStreamStatusEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSSFStreamStatusEnum(self): + """Test SSFStreamStatusEnum""" + # inst = SSFStreamStatusEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_stage.py b/test/test_stage.py new file mode 100644 index 000000000..4c96ac233 --- /dev/null +++ b/test/test_stage.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.stage import Stage + +class TestStage(unittest.TestCase): + """Stage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Stage: + """Test Stage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Stage` + """ + model = Stage() + if include_optional: + return Stage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ] + ) + else: + return Stage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testStage(self): + """Test Stage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_stage_mode_enum.py b/test/test_stage_mode_enum.py new file mode 100644 index 000000000..f7a36ef7a --- /dev/null +++ b/test/test_stage_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.stage_mode_enum import StageModeEnum + +class TestStageModeEnum(unittest.TestCase): + """StageModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testStageModeEnum(self): + """Test StageModeEnum""" + # inst = StageModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_stage_prompt.py b/test/test_stage_prompt.py new file mode 100644 index 000000000..301c9cb36 --- /dev/null +++ b/test/test_stage_prompt.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.stage_prompt import StagePrompt + +class TestStagePrompt(unittest.TestCase): + """StagePrompt unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> StagePrompt: + """Test StagePrompt + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `StagePrompt` + """ + model = StagePrompt() + if include_optional: + return StagePrompt( + field_key = '', + label = '', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = 56, + sub_text = '', + choices = [ + authentik_client.models.prompt_choice.PromptChoice( + value = '', + label = '', ) + ] + ) + else: + return StagePrompt( + field_key = '', + label = '', + type = 'text', + required = True, + placeholder = '', + initial_value = '', + order = 56, + sub_text = '', + choices = [ + authentik_client.models.prompt_choice.PromptChoice( + value = '', + label = '', ) + ], + ) + """ + + def testStagePrompt(self): + """Test StagePrompt""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_stages_api.py b/test/test_stages_api.py new file mode 100644 index 000000000..8d844303d --- /dev/null +++ b/test/test_stages_api.py @@ -0,0 +1,1292 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.stages_api import StagesApi + + +class TestStagesApi(unittest.TestCase): + """StagesApi unit test stubs""" + + def setUp(self) -> None: + self.api = StagesApi() + + def tearDown(self) -> None: + pass + + def test_stages_account_lockdown_create(self) -> None: + """Test case for stages_account_lockdown_create + + """ + pass + + def test_stages_account_lockdown_destroy(self) -> None: + """Test case for stages_account_lockdown_destroy + + """ + pass + + def test_stages_account_lockdown_list(self) -> None: + """Test case for stages_account_lockdown_list + + """ + pass + + def test_stages_account_lockdown_partial_update(self) -> None: + """Test case for stages_account_lockdown_partial_update + + """ + pass + + def test_stages_account_lockdown_retrieve(self) -> None: + """Test case for stages_account_lockdown_retrieve + + """ + pass + + def test_stages_account_lockdown_update(self) -> None: + """Test case for stages_account_lockdown_update + + """ + pass + + def test_stages_account_lockdown_used_by_list(self) -> None: + """Test case for stages_account_lockdown_used_by_list + + """ + pass + + def test_stages_all_destroy(self) -> None: + """Test case for stages_all_destroy + + """ + pass + + def test_stages_all_list(self) -> None: + """Test case for stages_all_list + + """ + pass + + def test_stages_all_retrieve(self) -> None: + """Test case for stages_all_retrieve + + """ + pass + + def test_stages_all_types_list(self) -> None: + """Test case for stages_all_types_list + + """ + pass + + def test_stages_all_used_by_list(self) -> None: + """Test case for stages_all_used_by_list + + """ + pass + + def test_stages_all_user_settings_list(self) -> None: + """Test case for stages_all_user_settings_list + + """ + pass + + def test_stages_authenticator_duo_create(self) -> None: + """Test case for stages_authenticator_duo_create + + """ + pass + + def test_stages_authenticator_duo_destroy(self) -> None: + """Test case for stages_authenticator_duo_destroy + + """ + pass + + def test_stages_authenticator_duo_enrollment_status_create(self) -> None: + """Test case for stages_authenticator_duo_enrollment_status_create + + """ + pass + + def test_stages_authenticator_duo_import_device_manual_create(self) -> None: + """Test case for stages_authenticator_duo_import_device_manual_create + + """ + pass + + def test_stages_authenticator_duo_import_devices_automatic_create(self) -> None: + """Test case for stages_authenticator_duo_import_devices_automatic_create + + """ + pass + + def test_stages_authenticator_duo_list(self) -> None: + """Test case for stages_authenticator_duo_list + + """ + pass + + def test_stages_authenticator_duo_partial_update(self) -> None: + """Test case for stages_authenticator_duo_partial_update + + """ + pass + + def test_stages_authenticator_duo_retrieve(self) -> None: + """Test case for stages_authenticator_duo_retrieve + + """ + pass + + def test_stages_authenticator_duo_update(self) -> None: + """Test case for stages_authenticator_duo_update + + """ + pass + + def test_stages_authenticator_duo_used_by_list(self) -> None: + """Test case for stages_authenticator_duo_used_by_list + + """ + pass + + def test_stages_authenticator_email_create(self) -> None: + """Test case for stages_authenticator_email_create + + """ + pass + + def test_stages_authenticator_email_destroy(self) -> None: + """Test case for stages_authenticator_email_destroy + + """ + pass + + def test_stages_authenticator_email_list(self) -> None: + """Test case for stages_authenticator_email_list + + """ + pass + + def test_stages_authenticator_email_partial_update(self) -> None: + """Test case for stages_authenticator_email_partial_update + + """ + pass + + def test_stages_authenticator_email_retrieve(self) -> None: + """Test case for stages_authenticator_email_retrieve + + """ + pass + + def test_stages_authenticator_email_update(self) -> None: + """Test case for stages_authenticator_email_update + + """ + pass + + def test_stages_authenticator_email_used_by_list(self) -> None: + """Test case for stages_authenticator_email_used_by_list + + """ + pass + + def test_stages_authenticator_endpoint_gdtc_create(self) -> None: + """Test case for stages_authenticator_endpoint_gdtc_create + + """ + pass + + def test_stages_authenticator_endpoint_gdtc_destroy(self) -> None: + """Test case for stages_authenticator_endpoint_gdtc_destroy + + """ + pass + + def test_stages_authenticator_endpoint_gdtc_list(self) -> None: + """Test case for stages_authenticator_endpoint_gdtc_list + + """ + pass + + def test_stages_authenticator_endpoint_gdtc_partial_update(self) -> None: + """Test case for stages_authenticator_endpoint_gdtc_partial_update + + """ + pass + + def test_stages_authenticator_endpoint_gdtc_retrieve(self) -> None: + """Test case for stages_authenticator_endpoint_gdtc_retrieve + + """ + pass + + def test_stages_authenticator_endpoint_gdtc_update(self) -> None: + """Test case for stages_authenticator_endpoint_gdtc_update + + """ + pass + + def test_stages_authenticator_endpoint_gdtc_used_by_list(self) -> None: + """Test case for stages_authenticator_endpoint_gdtc_used_by_list + + """ + pass + + def test_stages_authenticator_sms_create(self) -> None: + """Test case for stages_authenticator_sms_create + + """ + pass + + def test_stages_authenticator_sms_destroy(self) -> None: + """Test case for stages_authenticator_sms_destroy + + """ + pass + + def test_stages_authenticator_sms_list(self) -> None: + """Test case for stages_authenticator_sms_list + + """ + pass + + def test_stages_authenticator_sms_partial_update(self) -> None: + """Test case for stages_authenticator_sms_partial_update + + """ + pass + + def test_stages_authenticator_sms_retrieve(self) -> None: + """Test case for stages_authenticator_sms_retrieve + + """ + pass + + def test_stages_authenticator_sms_update(self) -> None: + """Test case for stages_authenticator_sms_update + + """ + pass + + def test_stages_authenticator_sms_used_by_list(self) -> None: + """Test case for stages_authenticator_sms_used_by_list + + """ + pass + + def test_stages_authenticator_static_create(self) -> None: + """Test case for stages_authenticator_static_create + + """ + pass + + def test_stages_authenticator_static_destroy(self) -> None: + """Test case for stages_authenticator_static_destroy + + """ + pass + + def test_stages_authenticator_static_list(self) -> None: + """Test case for stages_authenticator_static_list + + """ + pass + + def test_stages_authenticator_static_partial_update(self) -> None: + """Test case for stages_authenticator_static_partial_update + + """ + pass + + def test_stages_authenticator_static_retrieve(self) -> None: + """Test case for stages_authenticator_static_retrieve + + """ + pass + + def test_stages_authenticator_static_update(self) -> None: + """Test case for stages_authenticator_static_update + + """ + pass + + def test_stages_authenticator_static_used_by_list(self) -> None: + """Test case for stages_authenticator_static_used_by_list + + """ + pass + + def test_stages_authenticator_totp_create(self) -> None: + """Test case for stages_authenticator_totp_create + + """ + pass + + def test_stages_authenticator_totp_destroy(self) -> None: + """Test case for stages_authenticator_totp_destroy + + """ + pass + + def test_stages_authenticator_totp_list(self) -> None: + """Test case for stages_authenticator_totp_list + + """ + pass + + def test_stages_authenticator_totp_partial_update(self) -> None: + """Test case for stages_authenticator_totp_partial_update + + """ + pass + + def test_stages_authenticator_totp_retrieve(self) -> None: + """Test case for stages_authenticator_totp_retrieve + + """ + pass + + def test_stages_authenticator_totp_update(self) -> None: + """Test case for stages_authenticator_totp_update + + """ + pass + + def test_stages_authenticator_totp_used_by_list(self) -> None: + """Test case for stages_authenticator_totp_used_by_list + + """ + pass + + def test_stages_authenticator_validate_create(self) -> None: + """Test case for stages_authenticator_validate_create + + """ + pass + + def test_stages_authenticator_validate_destroy(self) -> None: + """Test case for stages_authenticator_validate_destroy + + """ + pass + + def test_stages_authenticator_validate_list(self) -> None: + """Test case for stages_authenticator_validate_list + + """ + pass + + def test_stages_authenticator_validate_partial_update(self) -> None: + """Test case for stages_authenticator_validate_partial_update + + """ + pass + + def test_stages_authenticator_validate_retrieve(self) -> None: + """Test case for stages_authenticator_validate_retrieve + + """ + pass + + def test_stages_authenticator_validate_update(self) -> None: + """Test case for stages_authenticator_validate_update + + """ + pass + + def test_stages_authenticator_validate_used_by_list(self) -> None: + """Test case for stages_authenticator_validate_used_by_list + + """ + pass + + def test_stages_authenticator_webauthn_create(self) -> None: + """Test case for stages_authenticator_webauthn_create + + """ + pass + + def test_stages_authenticator_webauthn_destroy(self) -> None: + """Test case for stages_authenticator_webauthn_destroy + + """ + pass + + def test_stages_authenticator_webauthn_device_types_list(self) -> None: + """Test case for stages_authenticator_webauthn_device_types_list + + """ + pass + + def test_stages_authenticator_webauthn_device_types_retrieve(self) -> None: + """Test case for stages_authenticator_webauthn_device_types_retrieve + + """ + pass + + def test_stages_authenticator_webauthn_list(self) -> None: + """Test case for stages_authenticator_webauthn_list + + """ + pass + + def test_stages_authenticator_webauthn_partial_update(self) -> None: + """Test case for stages_authenticator_webauthn_partial_update + + """ + pass + + def test_stages_authenticator_webauthn_retrieve(self) -> None: + """Test case for stages_authenticator_webauthn_retrieve + + """ + pass + + def test_stages_authenticator_webauthn_update(self) -> None: + """Test case for stages_authenticator_webauthn_update + + """ + pass + + def test_stages_authenticator_webauthn_used_by_list(self) -> None: + """Test case for stages_authenticator_webauthn_used_by_list + + """ + pass + + def test_stages_captcha_create(self) -> None: + """Test case for stages_captcha_create + + """ + pass + + def test_stages_captcha_destroy(self) -> None: + """Test case for stages_captcha_destroy + + """ + pass + + def test_stages_captcha_list(self) -> None: + """Test case for stages_captcha_list + + """ + pass + + def test_stages_captcha_partial_update(self) -> None: + """Test case for stages_captcha_partial_update + + """ + pass + + def test_stages_captcha_retrieve(self) -> None: + """Test case for stages_captcha_retrieve + + """ + pass + + def test_stages_captcha_update(self) -> None: + """Test case for stages_captcha_update + + """ + pass + + def test_stages_captcha_used_by_list(self) -> None: + """Test case for stages_captcha_used_by_list + + """ + pass + + def test_stages_consent_create(self) -> None: + """Test case for stages_consent_create + + """ + pass + + def test_stages_consent_destroy(self) -> None: + """Test case for stages_consent_destroy + + """ + pass + + def test_stages_consent_list(self) -> None: + """Test case for stages_consent_list + + """ + pass + + def test_stages_consent_partial_update(self) -> None: + """Test case for stages_consent_partial_update + + """ + pass + + def test_stages_consent_retrieve(self) -> None: + """Test case for stages_consent_retrieve + + """ + pass + + def test_stages_consent_update(self) -> None: + """Test case for stages_consent_update + + """ + pass + + def test_stages_consent_used_by_list(self) -> None: + """Test case for stages_consent_used_by_list + + """ + pass + + def test_stages_deny_create(self) -> None: + """Test case for stages_deny_create + + """ + pass + + def test_stages_deny_destroy(self) -> None: + """Test case for stages_deny_destroy + + """ + pass + + def test_stages_deny_list(self) -> None: + """Test case for stages_deny_list + + """ + pass + + def test_stages_deny_partial_update(self) -> None: + """Test case for stages_deny_partial_update + + """ + pass + + def test_stages_deny_retrieve(self) -> None: + """Test case for stages_deny_retrieve + + """ + pass + + def test_stages_deny_update(self) -> None: + """Test case for stages_deny_update + + """ + pass + + def test_stages_deny_used_by_list(self) -> None: + """Test case for stages_deny_used_by_list + + """ + pass + + def test_stages_dummy_create(self) -> None: + """Test case for stages_dummy_create + + """ + pass + + def test_stages_dummy_destroy(self) -> None: + """Test case for stages_dummy_destroy + + """ + pass + + def test_stages_dummy_list(self) -> None: + """Test case for stages_dummy_list + + """ + pass + + def test_stages_dummy_partial_update(self) -> None: + """Test case for stages_dummy_partial_update + + """ + pass + + def test_stages_dummy_retrieve(self) -> None: + """Test case for stages_dummy_retrieve + + """ + pass + + def test_stages_dummy_update(self) -> None: + """Test case for stages_dummy_update + + """ + pass + + def test_stages_dummy_used_by_list(self) -> None: + """Test case for stages_dummy_used_by_list + + """ + pass + + def test_stages_email_create(self) -> None: + """Test case for stages_email_create + + """ + pass + + def test_stages_email_destroy(self) -> None: + """Test case for stages_email_destroy + + """ + pass + + def test_stages_email_list(self) -> None: + """Test case for stages_email_list + + """ + pass + + def test_stages_email_partial_update(self) -> None: + """Test case for stages_email_partial_update + + """ + pass + + def test_stages_email_retrieve(self) -> None: + """Test case for stages_email_retrieve + + """ + pass + + def test_stages_email_templates_list(self) -> None: + """Test case for stages_email_templates_list + + """ + pass + + def test_stages_email_update(self) -> None: + """Test case for stages_email_update + + """ + pass + + def test_stages_email_used_by_list(self) -> None: + """Test case for stages_email_used_by_list + + """ + pass + + def test_stages_endpoints_create(self) -> None: + """Test case for stages_endpoints_create + + """ + pass + + def test_stages_endpoints_destroy(self) -> None: + """Test case for stages_endpoints_destroy + + """ + pass + + def test_stages_endpoints_list(self) -> None: + """Test case for stages_endpoints_list + + """ + pass + + def test_stages_endpoints_partial_update(self) -> None: + """Test case for stages_endpoints_partial_update + + """ + pass + + def test_stages_endpoints_retrieve(self) -> None: + """Test case for stages_endpoints_retrieve + + """ + pass + + def test_stages_endpoints_update(self) -> None: + """Test case for stages_endpoints_update + + """ + pass + + def test_stages_endpoints_used_by_list(self) -> None: + """Test case for stages_endpoints_used_by_list + + """ + pass + + def test_stages_identification_create(self) -> None: + """Test case for stages_identification_create + + """ + pass + + def test_stages_identification_destroy(self) -> None: + """Test case for stages_identification_destroy + + """ + pass + + def test_stages_identification_list(self) -> None: + """Test case for stages_identification_list + + """ + pass + + def test_stages_identification_partial_update(self) -> None: + """Test case for stages_identification_partial_update + + """ + pass + + def test_stages_identification_retrieve(self) -> None: + """Test case for stages_identification_retrieve + + """ + pass + + def test_stages_identification_update(self) -> None: + """Test case for stages_identification_update + + """ + pass + + def test_stages_identification_used_by_list(self) -> None: + """Test case for stages_identification_used_by_list + + """ + pass + + def test_stages_invitation_invitations_create(self) -> None: + """Test case for stages_invitation_invitations_create + + """ + pass + + def test_stages_invitation_invitations_destroy(self) -> None: + """Test case for stages_invitation_invitations_destroy + + """ + pass + + def test_stages_invitation_invitations_list(self) -> None: + """Test case for stages_invitation_invitations_list + + """ + pass + + def test_stages_invitation_invitations_partial_update(self) -> None: + """Test case for stages_invitation_invitations_partial_update + + """ + pass + + def test_stages_invitation_invitations_retrieve(self) -> None: + """Test case for stages_invitation_invitations_retrieve + + """ + pass + + def test_stages_invitation_invitations_send_email_create(self) -> None: + """Test case for stages_invitation_invitations_send_email_create + + """ + pass + + def test_stages_invitation_invitations_update(self) -> None: + """Test case for stages_invitation_invitations_update + + """ + pass + + def test_stages_invitation_invitations_used_by_list(self) -> None: + """Test case for stages_invitation_invitations_used_by_list + + """ + pass + + def test_stages_invitation_stages_create(self) -> None: + """Test case for stages_invitation_stages_create + + """ + pass + + def test_stages_invitation_stages_destroy(self) -> None: + """Test case for stages_invitation_stages_destroy + + """ + pass + + def test_stages_invitation_stages_list(self) -> None: + """Test case for stages_invitation_stages_list + + """ + pass + + def test_stages_invitation_stages_partial_update(self) -> None: + """Test case for stages_invitation_stages_partial_update + + """ + pass + + def test_stages_invitation_stages_retrieve(self) -> None: + """Test case for stages_invitation_stages_retrieve + + """ + pass + + def test_stages_invitation_stages_update(self) -> None: + """Test case for stages_invitation_stages_update + + """ + pass + + def test_stages_invitation_stages_used_by_list(self) -> None: + """Test case for stages_invitation_stages_used_by_list + + """ + pass + + def test_stages_mtls_create(self) -> None: + """Test case for stages_mtls_create + + """ + pass + + def test_stages_mtls_destroy(self) -> None: + """Test case for stages_mtls_destroy + + """ + pass + + def test_stages_mtls_list(self) -> None: + """Test case for stages_mtls_list + + """ + pass + + def test_stages_mtls_partial_update(self) -> None: + """Test case for stages_mtls_partial_update + + """ + pass + + def test_stages_mtls_retrieve(self) -> None: + """Test case for stages_mtls_retrieve + + """ + pass + + def test_stages_mtls_update(self) -> None: + """Test case for stages_mtls_update + + """ + pass + + def test_stages_mtls_used_by_list(self) -> None: + """Test case for stages_mtls_used_by_list + + """ + pass + + def test_stages_password_create(self) -> None: + """Test case for stages_password_create + + """ + pass + + def test_stages_password_destroy(self) -> None: + """Test case for stages_password_destroy + + """ + pass + + def test_stages_password_list(self) -> None: + """Test case for stages_password_list + + """ + pass + + def test_stages_password_partial_update(self) -> None: + """Test case for stages_password_partial_update + + """ + pass + + def test_stages_password_retrieve(self) -> None: + """Test case for stages_password_retrieve + + """ + pass + + def test_stages_password_update(self) -> None: + """Test case for stages_password_update + + """ + pass + + def test_stages_password_used_by_list(self) -> None: + """Test case for stages_password_used_by_list + + """ + pass + + def test_stages_prompt_prompts_create(self) -> None: + """Test case for stages_prompt_prompts_create + + """ + pass + + def test_stages_prompt_prompts_destroy(self) -> None: + """Test case for stages_prompt_prompts_destroy + + """ + pass + + def test_stages_prompt_prompts_list(self) -> None: + """Test case for stages_prompt_prompts_list + + """ + pass + + def test_stages_prompt_prompts_partial_update(self) -> None: + """Test case for stages_prompt_prompts_partial_update + + """ + pass + + def test_stages_prompt_prompts_preview_create(self) -> None: + """Test case for stages_prompt_prompts_preview_create + + """ + pass + + def test_stages_prompt_prompts_retrieve(self) -> None: + """Test case for stages_prompt_prompts_retrieve + + """ + pass + + def test_stages_prompt_prompts_update(self) -> None: + """Test case for stages_prompt_prompts_update + + """ + pass + + def test_stages_prompt_prompts_used_by_list(self) -> None: + """Test case for stages_prompt_prompts_used_by_list + + """ + pass + + def test_stages_prompt_stages_create(self) -> None: + """Test case for stages_prompt_stages_create + + """ + pass + + def test_stages_prompt_stages_destroy(self) -> None: + """Test case for stages_prompt_stages_destroy + + """ + pass + + def test_stages_prompt_stages_list(self) -> None: + """Test case for stages_prompt_stages_list + + """ + pass + + def test_stages_prompt_stages_partial_update(self) -> None: + """Test case for stages_prompt_stages_partial_update + + """ + pass + + def test_stages_prompt_stages_retrieve(self) -> None: + """Test case for stages_prompt_stages_retrieve + + """ + pass + + def test_stages_prompt_stages_update(self) -> None: + """Test case for stages_prompt_stages_update + + """ + pass + + def test_stages_prompt_stages_used_by_list(self) -> None: + """Test case for stages_prompt_stages_used_by_list + + """ + pass + + def test_stages_redirect_create(self) -> None: + """Test case for stages_redirect_create + + """ + pass + + def test_stages_redirect_destroy(self) -> None: + """Test case for stages_redirect_destroy + + """ + pass + + def test_stages_redirect_list(self) -> None: + """Test case for stages_redirect_list + + """ + pass + + def test_stages_redirect_partial_update(self) -> None: + """Test case for stages_redirect_partial_update + + """ + pass + + def test_stages_redirect_retrieve(self) -> None: + """Test case for stages_redirect_retrieve + + """ + pass + + def test_stages_redirect_update(self) -> None: + """Test case for stages_redirect_update + + """ + pass + + def test_stages_redirect_used_by_list(self) -> None: + """Test case for stages_redirect_used_by_list + + """ + pass + + def test_stages_source_create(self) -> None: + """Test case for stages_source_create + + """ + pass + + def test_stages_source_destroy(self) -> None: + """Test case for stages_source_destroy + + """ + pass + + def test_stages_source_list(self) -> None: + """Test case for stages_source_list + + """ + pass + + def test_stages_source_partial_update(self) -> None: + """Test case for stages_source_partial_update + + """ + pass + + def test_stages_source_retrieve(self) -> None: + """Test case for stages_source_retrieve + + """ + pass + + def test_stages_source_update(self) -> None: + """Test case for stages_source_update + + """ + pass + + def test_stages_source_used_by_list(self) -> None: + """Test case for stages_source_used_by_list + + """ + pass + + def test_stages_user_delete_create(self) -> None: + """Test case for stages_user_delete_create + + """ + pass + + def test_stages_user_delete_destroy(self) -> None: + """Test case for stages_user_delete_destroy + + """ + pass + + def test_stages_user_delete_list(self) -> None: + """Test case for stages_user_delete_list + + """ + pass + + def test_stages_user_delete_partial_update(self) -> None: + """Test case for stages_user_delete_partial_update + + """ + pass + + def test_stages_user_delete_retrieve(self) -> None: + """Test case for stages_user_delete_retrieve + + """ + pass + + def test_stages_user_delete_update(self) -> None: + """Test case for stages_user_delete_update + + """ + pass + + def test_stages_user_delete_used_by_list(self) -> None: + """Test case for stages_user_delete_used_by_list + + """ + pass + + def test_stages_user_login_create(self) -> None: + """Test case for stages_user_login_create + + """ + pass + + def test_stages_user_login_destroy(self) -> None: + """Test case for stages_user_login_destroy + + """ + pass + + def test_stages_user_login_list(self) -> None: + """Test case for stages_user_login_list + + """ + pass + + def test_stages_user_login_partial_update(self) -> None: + """Test case for stages_user_login_partial_update + + """ + pass + + def test_stages_user_login_retrieve(self) -> None: + """Test case for stages_user_login_retrieve + + """ + pass + + def test_stages_user_login_update(self) -> None: + """Test case for stages_user_login_update + + """ + pass + + def test_stages_user_login_used_by_list(self) -> None: + """Test case for stages_user_login_used_by_list + + """ + pass + + def test_stages_user_logout_create(self) -> None: + """Test case for stages_user_logout_create + + """ + pass + + def test_stages_user_logout_destroy(self) -> None: + """Test case for stages_user_logout_destroy + + """ + pass + + def test_stages_user_logout_list(self) -> None: + """Test case for stages_user_logout_list + + """ + pass + + def test_stages_user_logout_partial_update(self) -> None: + """Test case for stages_user_logout_partial_update + + """ + pass + + def test_stages_user_logout_retrieve(self) -> None: + """Test case for stages_user_logout_retrieve + + """ + pass + + def test_stages_user_logout_update(self) -> None: + """Test case for stages_user_logout_update + + """ + pass + + def test_stages_user_logout_used_by_list(self) -> None: + """Test case for stages_user_logout_used_by_list + + """ + pass + + def test_stages_user_write_create(self) -> None: + """Test case for stages_user_write_create + + """ + pass + + def test_stages_user_write_destroy(self) -> None: + """Test case for stages_user_write_destroy + + """ + pass + + def test_stages_user_write_list(self) -> None: + """Test case for stages_user_write_list + + """ + pass + + def test_stages_user_write_partial_update(self) -> None: + """Test case for stages_user_write_partial_update + + """ + pass + + def test_stages_user_write_retrieve(self) -> None: + """Test case for stages_user_write_retrieve + + """ + pass + + def test_stages_user_write_update(self) -> None: + """Test case for stages_user_write_update + + """ + pass + + def test_stages_user_write_used_by_list(self) -> None: + """Test case for stages_user_write_used_by_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_static_device.py b/test/test_static_device.py new file mode 100644 index 000000000..9b9afbbdc --- /dev/null +++ b/test/test_static_device.py @@ -0,0 +1,85 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.static_device import StaticDevice + +class TestStaticDevice(unittest.TestCase): + """StaticDevice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> StaticDevice: + """Test StaticDevice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `StaticDevice` + """ + model = StaticDevice() + if include_optional: + return StaticDevice( + name = '', + token_set = [ + authentik_client.models.static_device_token.StaticDeviceToken( + token = '', ) + ], + pk = 56, + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ) + else: + return StaticDevice( + name = '', + token_set = [ + authentik_client.models.static_device_token.StaticDeviceToken( + token = '', ) + ], + pk = 56, + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + ) + """ + + def testStaticDevice(self): + """Test StaticDevice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_static_device_request.py b/test/test_static_device_request.py new file mode 100644 index 000000000..179f2f717 --- /dev/null +++ b/test/test_static_device_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.static_device_request import StaticDeviceRequest + +class TestStaticDeviceRequest(unittest.TestCase): + """StaticDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> StaticDeviceRequest: + """Test StaticDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `StaticDeviceRequest` + """ + model = StaticDeviceRequest() + if include_optional: + return StaticDeviceRequest( + name = '0' + ) + else: + return StaticDeviceRequest( + name = '0', + ) + """ + + def testStaticDeviceRequest(self): + """Test StaticDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_static_device_token.py b/test/test_static_device_token.py new file mode 100644 index 000000000..d273be724 --- /dev/null +++ b/test/test_static_device_token.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.static_device_token import StaticDeviceToken + +class TestStaticDeviceToken(unittest.TestCase): + """StaticDeviceToken unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> StaticDeviceToken: + """Test StaticDeviceToken + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `StaticDeviceToken` + """ + model = StaticDeviceToken() + if include_optional: + return StaticDeviceToken( + token = '' + ) + else: + return StaticDeviceToken( + token = '', + ) + """ + + def testStaticDeviceToken(self): + """Test StaticDeviceToken""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_sub_mode_enum.py b/test/test_sub_mode_enum.py new file mode 100644 index 000000000..4b5911b9d --- /dev/null +++ b/test/test_sub_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.sub_mode_enum import SubModeEnum + +class TestSubModeEnum(unittest.TestCase): + """SubModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSubModeEnum(self): + """Test SubModeEnum""" + # inst = SubModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_sync_object_model_enum.py b/test/test_sync_object_model_enum.py new file mode 100644 index 000000000..9f60bf5dd --- /dev/null +++ b/test/test_sync_object_model_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.sync_object_model_enum import SyncObjectModelEnum + +class TestSyncObjectModelEnum(unittest.TestCase): + """SyncObjectModelEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSyncObjectModelEnum(self): + """Test SyncObjectModelEnum""" + # inst = SyncObjectModelEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_sync_object_request.py b/test/test_sync_object_request.py new file mode 100644 index 000000000..3dbbce070 --- /dev/null +++ b/test/test_sync_object_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.sync_object_request import SyncObjectRequest + +class TestSyncObjectRequest(unittest.TestCase): + """SyncObjectRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SyncObjectRequest: + """Test SyncObjectRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SyncObjectRequest` + """ + model = SyncObjectRequest() + if include_optional: + return SyncObjectRequest( + sync_object_model = 'authentik.core.models.User', + sync_object_id = '0', + override_dry_run = True + ) + else: + return SyncObjectRequest( + sync_object_model = 'authentik.core.models.User', + sync_object_id = '0', + ) + """ + + def testSyncObjectRequest(self): + """Test SyncObjectRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_sync_object_result.py b/test/test_sync_object_result.py new file mode 100644 index 000000000..6a49fc895 --- /dev/null +++ b/test/test_sync_object_result.py @@ -0,0 +1,71 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.sync_object_result import SyncObjectResult + +class TestSyncObjectResult(unittest.TestCase): + """SyncObjectResult unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SyncObjectResult: + """Test SyncObjectResult + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SyncObjectResult` + """ + model = SyncObjectResult() + if include_optional: + return SyncObjectResult( + messages = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ] + ) + else: + return SyncObjectResult( + messages = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + ) + """ + + def testSyncObjectResult(self): + """Test SyncObjectResult""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_sync_outgoing_trigger_mode_enum.py b/test/test_sync_outgoing_trigger_mode_enum.py new file mode 100644 index 000000000..9f5112ad4 --- /dev/null +++ b/test/test_sync_outgoing_trigger_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.sync_outgoing_trigger_mode_enum import SyncOutgoingTriggerModeEnum + +class TestSyncOutgoingTriggerModeEnum(unittest.TestCase): + """SyncOutgoingTriggerModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testSyncOutgoingTriggerModeEnum(self): + """Test SyncOutgoingTriggerModeEnum""" + # inst = SyncOutgoingTriggerModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_sync_status.py b/test/test_sync_status.py new file mode 100644 index 000000000..667091258 --- /dev/null +++ b/test/test_sync_status.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.sync_status import SyncStatus + +class TestSyncStatus(unittest.TestCase): + """SyncStatus unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SyncStatus: + """Test SyncStatus + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SyncStatus` + """ + model = SyncStatus() + if include_optional: + return SyncStatus( + is_running = True, + last_successful_sync = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_sync_status = 'queued' + ) + else: + return SyncStatus( + is_running = True, + ) + """ + + def testSyncStatus(self): + """Test SyncStatus""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_system_info.py b/test/test_system_info.py new file mode 100644 index 000000000..9e505cf99 --- /dev/null +++ b/test/test_system_info.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.system_info import SystemInfo + +class TestSystemInfo(unittest.TestCase): + """SystemInfo unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SystemInfo: + """Test SystemInfo + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SystemInfo` + """ + model = SystemInfo() + if include_optional: + return SystemInfo( + http_headers = { + 'key' : '' + }, + http_host = '', + http_is_secure = True, + runtime = authentik_client.models.system_info_runtime.SystemInfo_runtime( + python_version = '', + environment = '', + architecture = '', + platform = '', + uname = '', + openssl_version = '', + openssl_fips_enabled = True, + authentik_version = '', ), + brand = '', + server_time = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + embedded_outpost_disabled = True, + embedded_outpost_host = '' + ) + else: + return SystemInfo( + http_headers = { + 'key' : '' + }, + http_host = '', + http_is_secure = True, + runtime = authentik_client.models.system_info_runtime.SystemInfo_runtime( + python_version = '', + environment = '', + architecture = '', + platform = '', + uname = '', + openssl_version = '', + openssl_fips_enabled = True, + authentik_version = '', ), + brand = '', + server_time = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + embedded_outpost_disabled = True, + embedded_outpost_host = '', + ) + """ + + def testSystemInfo(self): + """Test SystemInfo""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_system_info_runtime.py b/test/test_system_info_runtime.py new file mode 100644 index 000000000..9f08e4ee0 --- /dev/null +++ b/test/test_system_info_runtime.py @@ -0,0 +1,67 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.system_info_runtime import SystemInfoRuntime + +class TestSystemInfoRuntime(unittest.TestCase): + """SystemInfoRuntime unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> SystemInfoRuntime: + """Test SystemInfoRuntime + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `SystemInfoRuntime` + """ + model = SystemInfoRuntime() + if include_optional: + return SystemInfoRuntime( + python_version = '', + environment = '', + architecture = '', + platform = '', + uname = '', + openssl_version = '', + openssl_fips_enabled = True, + authentik_version = '' + ) + else: + return SystemInfoRuntime( + python_version = '', + environment = '', + architecture = '', + platform = '', + uname = '', + openssl_version = '', + openssl_fips_enabled = True, + authentik_version = '', + ) + """ + + def testSystemInfoRuntime(self): + """Test SystemInfoRuntime""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_task.py b/test/test_task.py new file mode 100644 index 000000000..f99c58b38 --- /dev/null +++ b/test/test_task.py @@ -0,0 +1,110 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.task import Task + +class TestTask(unittest.TestCase): + """Task unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Task: + """Test Task + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Task` + """ + model = Task() + if include_optional: + return Task( + message_id = '', + queue_name = '', + actor_name = '', + state = 'queued', + mtime = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + retries = 0, + eta = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + rel_obj_app_label = '', + rel_obj_model = '', + rel_obj_id = '', + uid = '', + logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + previous_logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + aggregated_status = 'queued', + description = '' + ) + else: + return Task( + actor_name = '', + rel_obj_app_label = '', + rel_obj_model = '', + uid = '', + logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + previous_logs = [ + authentik_client.models.log_event.LogEvent( + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + log_level = 'critical', + logger = '', + event = '', + attributes = { + 'key' : null + }, ) + ], + aggregated_status = 'queued', + description = '', + ) + """ + + def testTask(self): + """Test Task""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_task_aggregated_status_enum.py b/test/test_task_aggregated_status_enum.py new file mode 100644 index 000000000..7f57a4135 --- /dev/null +++ b/test/test_task_aggregated_status_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.task_aggregated_status_enum import TaskAggregatedStatusEnum + +class TestTaskAggregatedStatusEnum(unittest.TestCase): + """TaskAggregatedStatusEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testTaskAggregatedStatusEnum(self): + """Test TaskAggregatedStatusEnum""" + # inst = TaskAggregatedStatusEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_task_status_enum.py b/test/test_task_status_enum.py new file mode 100644 index 000000000..7cfade9ad --- /dev/null +++ b/test/test_task_status_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.task_status_enum import TaskStatusEnum + +class TestTaskStatusEnum(unittest.TestCase): + """TaskStatusEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testTaskStatusEnum(self): + """Test TaskStatusEnum""" + # inst = TaskStatusEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_tasks_api.py b/test/test_tasks_api.py new file mode 100644 index 000000000..8c88e1a0d --- /dev/null +++ b/test/test_tasks_api.py @@ -0,0 +1,92 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.tasks_api import TasksApi + + +class TestTasksApi(unittest.TestCase): + """TasksApi unit test stubs""" + + def setUp(self) -> None: + self.api = TasksApi() + + def tearDown(self) -> None: + pass + + def test_tasks_schedules_list(self) -> None: + """Test case for tasks_schedules_list + + """ + pass + + def test_tasks_schedules_partial_update(self) -> None: + """Test case for tasks_schedules_partial_update + + """ + pass + + def test_tasks_schedules_retrieve(self) -> None: + """Test case for tasks_schedules_retrieve + + """ + pass + + def test_tasks_schedules_send_create(self) -> None: + """Test case for tasks_schedules_send_create + + """ + pass + + def test_tasks_schedules_update(self) -> None: + """Test case for tasks_schedules_update + + """ + pass + + def test_tasks_tasks_list(self) -> None: + """Test case for tasks_tasks_list + + """ + pass + + def test_tasks_tasks_retrieve(self) -> None: + """Test case for tasks_tasks_retrieve + + """ + pass + + def test_tasks_tasks_retry_create(self) -> None: + """Test case for tasks_tasks_retry_create + + """ + pass + + def test_tasks_tasks_status_retrieve(self) -> None: + """Test case for tasks_tasks_status_retrieve + + """ + pass + + def test_tasks_workers_list(self) -> None: + """Test case for tasks_workers_list + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_telegram_auth_request.py b/test/test_telegram_auth_request.py new file mode 100644 index 000000000..ab1d664c0 --- /dev/null +++ b/test/test_telegram_auth_request.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.telegram_auth_request import TelegramAuthRequest + +class TestTelegramAuthRequest(unittest.TestCase): + """TelegramAuthRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TelegramAuthRequest: + """Test TelegramAuthRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TelegramAuthRequest` + """ + model = TelegramAuthRequest() + if include_optional: + return TelegramAuthRequest( + id = 56, + first_name = '0', + last_name = '0', + username = '0', + photo_url = '0', + auth_date = 56, + hash = '0' + ) + else: + return TelegramAuthRequest( + id = 56, + auth_date = 56, + hash = '0', + ) + """ + + def testTelegramAuthRequest(self): + """Test TelegramAuthRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_telegram_challenge_response_request.py b/test/test_telegram_challenge_response_request.py new file mode 100644 index 000000000..7411aab63 --- /dev/null +++ b/test/test_telegram_challenge_response_request.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.telegram_challenge_response_request import TelegramChallengeResponseRequest + +class TestTelegramChallengeResponseRequest(unittest.TestCase): + """TelegramChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TelegramChallengeResponseRequest: + """Test TelegramChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TelegramChallengeResponseRequest` + """ + model = TelegramChallengeResponseRequest() + if include_optional: + return TelegramChallengeResponseRequest( + id = 56, + first_name = '0', + last_name = '0', + username = '0', + photo_url = '0', + auth_date = 56, + hash = '0', + component = 'ak-source-telegram' + ) + else: + return TelegramChallengeResponseRequest( + id = 56, + auth_date = 56, + hash = '0', + ) + """ + + def testTelegramChallengeResponseRequest(self): + """Test TelegramChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_telegram_login_challenge.py b/test/test_telegram_login_challenge.py new file mode 100644 index 000000000..6280cd7a1 --- /dev/null +++ b/test/test_telegram_login_challenge.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.telegram_login_challenge import TelegramLoginChallenge + +class TestTelegramLoginChallenge(unittest.TestCase): + """TelegramLoginChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TelegramLoginChallenge: + """Test TelegramLoginChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TelegramLoginChallenge` + """ + model = TelegramLoginChallenge() + if include_optional: + return TelegramLoginChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-source-telegram', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + bot_username = '', + request_message_access = True + ) + else: + return TelegramLoginChallenge( + bot_username = '', + request_message_access = True, + ) + """ + + def testTelegramLoginChallenge(self): + """Test TelegramLoginChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_telegram_source.py b/test/test_telegram_source.py new file mode 100644 index 000000000..67be15e59 --- /dev/null +++ b/test/test_telegram_source.py @@ -0,0 +1,94 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.telegram_source import TelegramSource + +class TestTelegramSource(unittest.TestCase): + """TelegramSource unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TelegramSource: + """Test TelegramSource + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TelegramSource` + """ + model = TelegramSource() + if include_optional: + return TelegramSource( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + bot_username = '', + request_message_access = True, + pre_authentication_flow = '' + ) + else: + return TelegramSource( + pk = '', + name = '', + slug = 'z', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + managed = '', + icon_url = '', + icon_themed_urls = authentik_client.models.themed_urls.ThemedUrls( + light = '', + dark = '', ), + bot_username = '', + pre_authentication_flow = '', + ) + """ + + def testTelegramSource(self): + """Test TelegramSource""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_telegram_source_property_mapping.py b/test/test_telegram_source_property_mapping.py new file mode 100644 index 000000000..3fc11a13a --- /dev/null +++ b/test/test_telegram_source_property_mapping.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.telegram_source_property_mapping import TelegramSourcePropertyMapping + +class TestTelegramSourcePropertyMapping(unittest.TestCase): + """TelegramSourcePropertyMapping unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TelegramSourcePropertyMapping: + """Test TelegramSourcePropertyMapping + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TelegramSourcePropertyMapping` + """ + model = TelegramSourcePropertyMapping() + if include_optional: + return TelegramSourcePropertyMapping( + pk = '', + managed = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '' + ) + else: + return TelegramSourcePropertyMapping( + pk = '', + name = '', + expression = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + ) + """ + + def testTelegramSourcePropertyMapping(self): + """Test TelegramSourcePropertyMapping""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_telegram_source_property_mapping_request.py b/test/test_telegram_source_property_mapping_request.py new file mode 100644 index 000000000..a4eb38411 --- /dev/null +++ b/test/test_telegram_source_property_mapping_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.telegram_source_property_mapping_request import TelegramSourcePropertyMappingRequest + +class TestTelegramSourcePropertyMappingRequest(unittest.TestCase): + """TelegramSourcePropertyMappingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TelegramSourcePropertyMappingRequest: + """Test TelegramSourcePropertyMappingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TelegramSourcePropertyMappingRequest` + """ + model = TelegramSourcePropertyMappingRequest() + if include_optional: + return TelegramSourcePropertyMappingRequest( + managed = '0', + name = '0', + expression = '0' + ) + else: + return TelegramSourcePropertyMappingRequest( + name = '0', + expression = '0', + ) + """ + + def testTelegramSourcePropertyMappingRequest(self): + """Test TelegramSourcePropertyMappingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_telegram_source_request.py b/test/test_telegram_source_request.py new file mode 100644 index 000000000..39d6610e0 --- /dev/null +++ b/test/test_telegram_source_request.py @@ -0,0 +1,76 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.telegram_source_request import TelegramSourceRequest + +class TestTelegramSourceRequest(unittest.TestCase): + """TelegramSourceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TelegramSourceRequest: + """Test TelegramSourceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TelegramSourceRequest` + """ + model = TelegramSourceRequest() + if include_optional: + return TelegramSourceRequest( + name = '0', + slug = 'z0', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + policy_engine_mode = 'all', + user_matching_mode = 'identifier', + user_path_template = '0', + icon = '', + bot_username = '0', + bot_token = '0', + request_message_access = True, + pre_authentication_flow = '' + ) + else: + return TelegramSourceRequest( + name = '0', + slug = 'z0', + bot_username = '0', + bot_token = '0', + pre_authentication_flow = '', + ) + """ + + def testTelegramSourceRequest(self): + """Test TelegramSourceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_tenant.py b/test/test_tenant.py new file mode 100644 index 000000000..c841a547c --- /dev/null +++ b/test/test_tenant.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.tenant import Tenant + +class TestTenant(unittest.TestCase): + """Tenant unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Tenant: + """Test Tenant + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Tenant` + """ + model = Tenant() + if include_optional: + return Tenant( + tenant_uuid = '', + schema_name = '', + name = '', + ready = True + ) + else: + return Tenant( + tenant_uuid = '', + schema_name = '', + name = '', + ) + """ + + def testTenant(self): + """Test Tenant""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_tenant_admin_group_request_request.py b/test/test_tenant_admin_group_request_request.py new file mode 100644 index 000000000..9014ce585 --- /dev/null +++ b/test/test_tenant_admin_group_request_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.tenant_admin_group_request_request import TenantAdminGroupRequestRequest + +class TestTenantAdminGroupRequestRequest(unittest.TestCase): + """TenantAdminGroupRequestRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TenantAdminGroupRequestRequest: + """Test TenantAdminGroupRequestRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TenantAdminGroupRequestRequest` + """ + model = TenantAdminGroupRequestRequest() + if include_optional: + return TenantAdminGroupRequestRequest( + user = '0' + ) + else: + return TenantAdminGroupRequestRequest( + user = '0', + ) + """ + + def testTenantAdminGroupRequestRequest(self): + """Test TenantAdminGroupRequestRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_tenant_recovery_key_request_request.py b/test/test_tenant_recovery_key_request_request.py new file mode 100644 index 000000000..0394b7c93 --- /dev/null +++ b/test/test_tenant_recovery_key_request_request.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.tenant_recovery_key_request_request import TenantRecoveryKeyRequestRequest + +class TestTenantRecoveryKeyRequestRequest(unittest.TestCase): + """TenantRecoveryKeyRequestRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TenantRecoveryKeyRequestRequest: + """Test TenantRecoveryKeyRequestRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TenantRecoveryKeyRequestRequest` + """ + model = TenantRecoveryKeyRequestRequest() + if include_optional: + return TenantRecoveryKeyRequestRequest( + user = '0', + duration_days = 56 + ) + else: + return TenantRecoveryKeyRequestRequest( + user = '0', + duration_days = 56, + ) + """ + + def testTenantRecoveryKeyRequestRequest(self): + """Test TenantRecoveryKeyRequestRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_tenant_recovery_key_response.py b/test/test_tenant_recovery_key_response.py new file mode 100644 index 000000000..264e648e8 --- /dev/null +++ b/test/test_tenant_recovery_key_response.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.tenant_recovery_key_response import TenantRecoveryKeyResponse + +class TestTenantRecoveryKeyResponse(unittest.TestCase): + """TenantRecoveryKeyResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TenantRecoveryKeyResponse: + """Test TenantRecoveryKeyResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TenantRecoveryKeyResponse` + """ + model = TenantRecoveryKeyResponse() + if include_optional: + return TenantRecoveryKeyResponse( + expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + url = '' + ) + else: + return TenantRecoveryKeyResponse( + expiry = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + url = '', + ) + """ + + def testTenantRecoveryKeyResponse(self): + """Test TenantRecoveryKeyResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_tenant_request.py b/test/test_tenant_request.py new file mode 100644 index 000000000..017fa77e9 --- /dev/null +++ b/test/test_tenant_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.tenant_request import TenantRequest + +class TestTenantRequest(unittest.TestCase): + """TenantRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TenantRequest: + """Test TenantRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TenantRequest` + """ + model = TenantRequest() + if include_optional: + return TenantRequest( + schema_name = '0', + name = '0', + ready = True + ) + else: + return TenantRequest( + schema_name = '0', + name = '0', + ) + """ + + def testTenantRequest(self): + """Test TenantRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_tenants_api.py b/test/test_tenants_api.py new file mode 100644 index 000000000..2edfffa94 --- /dev/null +++ b/test/test_tenants_api.py @@ -0,0 +1,116 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.api.tenants_api import TenantsApi + + +class TestTenantsApi(unittest.TestCase): + """TenantsApi unit test stubs""" + + def setUp(self) -> None: + self.api = TenantsApi() + + def tearDown(self) -> None: + pass + + def test_tenants_domains_create(self) -> None: + """Test case for tenants_domains_create + + """ + pass + + def test_tenants_domains_destroy(self) -> None: + """Test case for tenants_domains_destroy + + """ + pass + + def test_tenants_domains_list(self) -> None: + """Test case for tenants_domains_list + + """ + pass + + def test_tenants_domains_partial_update(self) -> None: + """Test case for tenants_domains_partial_update + + """ + pass + + def test_tenants_domains_retrieve(self) -> None: + """Test case for tenants_domains_retrieve + + """ + pass + + def test_tenants_domains_update(self) -> None: + """Test case for tenants_domains_update + + """ + pass + + def test_tenants_tenants_create(self) -> None: + """Test case for tenants_tenants_create + + """ + pass + + def test_tenants_tenants_create_admin_group_create(self) -> None: + """Test case for tenants_tenants_create_admin_group_create + + """ + pass + + def test_tenants_tenants_create_recovery_key_create(self) -> None: + """Test case for tenants_tenants_create_recovery_key_create + + """ + pass + + def test_tenants_tenants_destroy(self) -> None: + """Test case for tenants_tenants_destroy + + """ + pass + + def test_tenants_tenants_list(self) -> None: + """Test case for tenants_tenants_list + + """ + pass + + def test_tenants_tenants_partial_update(self) -> None: + """Test case for tenants_tenants_partial_update + + """ + pass + + def test_tenants_tenants_retrieve(self) -> None: + """Test case for tenants_tenants_retrieve + + """ + pass + + def test_tenants_tenants_update(self) -> None: + """Test case for tenants_tenants_update + + """ + pass + + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_themed_urls.py b/test/test_themed_urls.py new file mode 100644 index 000000000..c5870e521 --- /dev/null +++ b/test/test_themed_urls.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.themed_urls import ThemedUrls + +class TestThemedUrls(unittest.TestCase): + """ThemedUrls unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ThemedUrls: + """Test ThemedUrls + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ThemedUrls` + """ + model = ThemedUrls() + if include_optional: + return ThemedUrls( + light = '', + dark = '' + ) + else: + return ThemedUrls( + ) + """ + + def testThemedUrls(self): + """Test ThemedUrls""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_token.py b/test/test_token.py new file mode 100644 index 000000000..e0b266296 --- /dev/null +++ b/test/test_token.py @@ -0,0 +1,141 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.token import Token + +class TestToken(unittest.TestCase): + """Token unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Token: + """Test Token + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Token` + """ + model = Token() + if include_optional: + return Token( + pk = '', + managed = '', + identifier = 'z', + intent = 'verification', + user = 56, + user_obj = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + description = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True + ) + else: + return Token( + pk = '', + identifier = 'z', + user_obj = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + ) + """ + + def testToken(self): + """Test Token""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_token_model.py b/test/test_token_model.py new file mode 100644 index 000000000..2a60bce3d --- /dev/null +++ b/test/test_token_model.py @@ -0,0 +1,237 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.token_model import TokenModel + +class TestTokenModel(unittest.TestCase): + """TokenModel unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TokenModel: + """Test TokenModel + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TokenModel` + """ + model = TokenModel() + if include_optional: + return TokenModel( + pk = 56, + provider = authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ), + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + is_expired = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + scope = [ + '' + ], + id_token = '', + revoked = True + ) + else: + return TokenModel( + pk = 56, + provider = authentik_client.models.o_auth2_provider.OAuth2Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + client_type = null, + grant_types = [ + 'authorization_code' + ], + client_id = '', + client_secret = '', + access_code_validity = '', + access_token_validity = '', + refresh_token_validity = '', + refresh_token_threshold = '', + include_claims_in_id_token = True, + signing_key = '', + encryption_key = '', + redirect_uris = [ + authentik_client.models.redirect_uri.RedirectURI( + matching_mode = 'strict', + url = '', + redirect_uri_type = null, ) + ], + logout_uri = '', + logout_method = null, + sub_mode = null, + issuer_mode = null, + jwt_federation_sources = [ + '' + ], + jwt_federation_providers = [ + 56 + ], ), + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + is_expired = True, + scope = [ + '' + ], + id_token = '', + ) + """ + + def testTokenModel(self): + """Test TokenModel""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_token_request.py b/test/test_token_request.py new file mode 100644 index 000000000..e66e0e250 --- /dev/null +++ b/test/test_token_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.token_request import TokenRequest + +class TestTokenRequest(unittest.TestCase): + """TokenRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TokenRequest: + """Test TokenRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TokenRequest` + """ + model = TokenRequest() + if include_optional: + return TokenRequest( + managed = '0', + identifier = 'z0', + intent = 'verification', + user = 56, + description = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True + ) + else: + return TokenRequest( + identifier = 'z0', + ) + """ + + def testTokenRequest(self): + """Test TokenRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_token_set_key_request.py b/test/test_token_set_key_request.py new file mode 100644 index 000000000..5bb3b142d --- /dev/null +++ b/test/test_token_set_key_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.token_set_key_request import TokenSetKeyRequest + +class TestTokenSetKeyRequest(unittest.TestCase): + """TokenSetKeyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TokenSetKeyRequest: + """Test TokenSetKeyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TokenSetKeyRequest` + """ + model = TokenSetKeyRequest() + if include_optional: + return TokenSetKeyRequest( + key = '0' + ) + else: + return TokenSetKeyRequest( + key = '0', + ) + """ + + def testTokenSetKeyRequest(self): + """Test TokenSetKeyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_token_view.py b/test/test_token_view.py new file mode 100644 index 000000000..914dd071c --- /dev/null +++ b/test/test_token_view.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.token_view import TokenView + +class TestTokenView(unittest.TestCase): + """TokenView unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TokenView: + """Test TokenView + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TokenView` + """ + model = TokenView() + if include_optional: + return TokenView( + key = '' + ) + else: + return TokenView( + key = '', + ) + """ + + def testTokenView(self): + """Test TokenView""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_totp_device.py b/test/test_totp_device.py new file mode 100644 index 000000000..3134efd9a --- /dev/null +++ b/test/test_totp_device.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.totp_device import TOTPDevice + +class TestTOTPDevice(unittest.TestCase): + """TOTPDevice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TOTPDevice: + """Test TOTPDevice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TOTPDevice` + """ + model = TOTPDevice() + if include_optional: + return TOTPDevice( + name = '', + pk = 56, + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ) + else: + return TOTPDevice( + name = '', + pk = 56, + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + ) + """ + + def testTOTPDevice(self): + """Test TOTPDevice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_totp_device_request.py b/test/test_totp_device_request.py new file mode 100644 index 000000000..05937deb1 --- /dev/null +++ b/test/test_totp_device_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.totp_device_request import TOTPDeviceRequest + +class TestTOTPDeviceRequest(unittest.TestCase): + """TOTPDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TOTPDeviceRequest: + """Test TOTPDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TOTPDeviceRequest` + """ + model = TOTPDeviceRequest() + if include_optional: + return TOTPDeviceRequest( + name = '0' + ) + else: + return TOTPDeviceRequest( + name = '0', + ) + """ + + def testTOTPDeviceRequest(self): + """Test TOTPDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_transaction_application_request.py b/test/test_transaction_application_request.py new file mode 100644 index 000000000..d2be193c9 --- /dev/null +++ b/test/test_transaction_application_request.py @@ -0,0 +1,96 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.transaction_application_request import TransactionApplicationRequest + +class TestTransactionApplicationRequest(unittest.TestCase): + """TransactionApplicationRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TransactionApplicationRequest: + """Test TransactionApplicationRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TransactionApplicationRequest` + """ + model = TransactionApplicationRequest() + if include_optional: + return TransactionApplicationRequest( + app = authentik_client.models.application_request.ApplicationRequest( + name = '0', + slug = 'z0', + provider = 56, + backchannel_providers = [ + 56 + ], + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True, ), + provider_model = 'authentik_providers_google_workspace.googleworkspaceprovider', + provider = None, + policy_bindings = [ + authentik_client.models.transaction_policy_binding_request.TransactionPolicyBindingRequest( + policy = '', + group = '', + user = 56, + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True, ) + ] + ) + else: + return TransactionApplicationRequest( + app = authentik_client.models.application_request.ApplicationRequest( + name = '0', + slug = 'z0', + provider = 56, + backchannel_providers = [ + 56 + ], + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True, ), + provider_model = 'authentik_providers_google_workspace.googleworkspaceprovider', + provider = None, + ) + """ + + def testTransactionApplicationRequest(self): + """Test TransactionApplicationRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_transaction_application_response.py b/test/test_transaction_application_response.py new file mode 100644 index 000000000..8a0144bc8 --- /dev/null +++ b/test/test_transaction_application_response.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.transaction_application_response import TransactionApplicationResponse + +class TestTransactionApplicationResponse(unittest.TestCase): + """TransactionApplicationResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TransactionApplicationResponse: + """Test TransactionApplicationResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TransactionApplicationResponse` + """ + model = TransactionApplicationResponse() + if include_optional: + return TransactionApplicationResponse( + applied = True, + logs = [ + '' + ] + ) + else: + return TransactionApplicationResponse( + applied = True, + logs = [ + '' + ], + ) + """ + + def testTransactionApplicationResponse(self): + """Test TransactionApplicationResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_transaction_policy_binding_request.py b/test/test_transaction_policy_binding_request.py new file mode 100644 index 000000000..d80e6faff --- /dev/null +++ b/test/test_transaction_policy_binding_request.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.transaction_policy_binding_request import TransactionPolicyBindingRequest + +class TestTransactionPolicyBindingRequest(unittest.TestCase): + """TransactionPolicyBindingRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TransactionPolicyBindingRequest: + """Test TransactionPolicyBindingRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TransactionPolicyBindingRequest` + """ + model = TransactionPolicyBindingRequest() + if include_optional: + return TransactionPolicyBindingRequest( + policy = '', + group = '', + user = 56, + negate = True, + enabled = True, + order = -2147483648, + timeout = 0, + failure_result = True + ) + else: + return TransactionPolicyBindingRequest( + order = -2147483648, + ) + """ + + def testTransactionPolicyBindingRequest(self): + """Test TransactionPolicyBindingRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_transport_mode_enum.py b/test/test_transport_mode_enum.py new file mode 100644 index 000000000..ed8471802 --- /dev/null +++ b/test/test_transport_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.transport_mode_enum import TransportModeEnum + +class TestTransportModeEnum(unittest.TestCase): + """TransportModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testTransportModeEnum(self): + """Test TransportModeEnum""" + # inst = TransportModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_type_create.py b/test/test_type_create.py new file mode 100644 index 000000000..1d39534a5 --- /dev/null +++ b/test/test_type_create.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.type_create import TypeCreate + +class TestTypeCreate(unittest.TestCase): + """TypeCreate unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> TypeCreate: + """Test TypeCreate + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `TypeCreate` + """ + model = TypeCreate() + if include_optional: + return TypeCreate( + name = '', + description = '', + component = '', + model_name = '', + icon_url = '', + requires_enterprise = True, + deprecated = True + ) + else: + return TypeCreate( + name = '', + description = '', + component = '', + model_name = '', + ) + """ + + def testTypeCreate(self): + """Test TypeCreate""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ui_theme_enum.py b/test/test_ui_theme_enum.py new file mode 100644 index 000000000..fe7d81020 --- /dev/null +++ b/test/test_ui_theme_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ui_theme_enum import UiThemeEnum + +class TestUiThemeEnum(unittest.TestCase): + """UiThemeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testUiThemeEnum(self): + """Test UiThemeEnum""" + # inst = UiThemeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_unique_password_policy.py b/test/test_unique_password_policy.py new file mode 100644 index 000000000..cef41c2a1 --- /dev/null +++ b/test/test_unique_password_policy.py @@ -0,0 +1,68 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.unique_password_policy import UniquePasswordPolicy + +class TestUniquePasswordPolicy(unittest.TestCase): + """UniquePasswordPolicy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UniquePasswordPolicy: + """Test UniquePasswordPolicy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UniquePasswordPolicy` + """ + model = UniquePasswordPolicy() + if include_optional: + return UniquePasswordPolicy( + pk = '', + name = '', + execution_logging = True, + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + password_field = '', + num_historical_passwords = 0 + ) + else: + return UniquePasswordPolicy( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + bound_to = 56, + ) + """ + + def testUniquePasswordPolicy(self): + """Test UniquePasswordPolicy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_unique_password_policy_request.py b/test/test_unique_password_policy_request.py new file mode 100644 index 000000000..64f87b29a --- /dev/null +++ b/test/test_unique_password_policy_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.unique_password_policy_request import UniquePasswordPolicyRequest + +class TestUniquePasswordPolicyRequest(unittest.TestCase): + """UniquePasswordPolicyRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UniquePasswordPolicyRequest: + """Test UniquePasswordPolicyRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UniquePasswordPolicyRequest` + """ + model = UniquePasswordPolicyRequest() + if include_optional: + return UniquePasswordPolicyRequest( + name = '0', + execution_logging = True, + password_field = '0', + num_historical_passwords = 0 + ) + else: + return UniquePasswordPolicyRequest( + name = '0', + ) + """ + + def testUniquePasswordPolicyRequest(self): + """Test UniquePasswordPolicyRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_usage_enum.py b/test/test_usage_enum.py new file mode 100644 index 000000000..adcd59838 --- /dev/null +++ b/test/test_usage_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.usage_enum import UsageEnum + +class TestUsageEnum(unittest.TestCase): + """UsageEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testUsageEnum(self): + """Test UsageEnum""" + # inst = UsageEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_used_by.py b/test/test_used_by.py new file mode 100644 index 000000000..a8c623450 --- /dev/null +++ b/test/test_used_by.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.used_by import UsedBy + +class TestUsedBy(unittest.TestCase): + """UsedBy unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UsedBy: + """Test UsedBy + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UsedBy` + """ + model = UsedBy() + if include_optional: + return UsedBy( + app = '', + model_name = '', + pk = '', + name = '', + action = 'cascade' + ) + else: + return UsedBy( + app = '', + model_name = '', + pk = '', + name = '', + action = 'cascade', + ) + """ + + def testUsedBy(self): + """Test UsedBy""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_used_by_action_enum.py b/test/test_used_by_action_enum.py new file mode 100644 index 000000000..22d599132 --- /dev/null +++ b/test/test_used_by_action_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.used_by_action_enum import UsedByActionEnum + +class TestUsedByActionEnum(unittest.TestCase): + """UsedByActionEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testUsedByActionEnum(self): + """Test UsedByActionEnum""" + # inst = UsedByActionEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user.py b/test/test_user.py new file mode 100644 index 000000000..8c72853b7 --- /dev/null +++ b/test/test_user.py @@ -0,0 +1,115 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user import User + +class TestUser(unittest.TestCase): + """User unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> User: + """Test User + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `User` + """ + model = User() + if include_optional: + return User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return User( + pk = 56, + username = '', + name = '', + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + avatar = '', + uid = '', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testUser(self): + """Test User""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_account_lockdown_request.py b/test/test_user_account_lockdown_request.py new file mode 100644 index 000000000..ac1259134 --- /dev/null +++ b/test/test_user_account_lockdown_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_account_lockdown_request import UserAccountLockdownRequest + +class TestUserAccountLockdownRequest(unittest.TestCase): + """UserAccountLockdownRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserAccountLockdownRequest: + """Test UserAccountLockdownRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserAccountLockdownRequest` + """ + model = UserAccountLockdownRequest() + if include_optional: + return UserAccountLockdownRequest( + user = 56 + ) + else: + return UserAccountLockdownRequest( + ) + """ + + def testUserAccountLockdownRequest(self): + """Test UserAccountLockdownRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_account_request.py b/test/test_user_account_request.py new file mode 100644 index 000000000..4a5ef25f6 --- /dev/null +++ b/test/test_user_account_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_account_request import UserAccountRequest + +class TestUserAccountRequest(unittest.TestCase): + """UserAccountRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserAccountRequest: + """Test UserAccountRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserAccountRequest` + """ + model = UserAccountRequest() + if include_optional: + return UserAccountRequest( + pk = 56 + ) + else: + return UserAccountRequest( + pk = 56, + ) + """ + + def testUserAccountRequest(self): + """Test UserAccountRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_account_serializer_for_role_request.py b/test/test_user_account_serializer_for_role_request.py new file mode 100644 index 000000000..a023f820e --- /dev/null +++ b/test/test_user_account_serializer_for_role_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_account_serializer_for_role_request import UserAccountSerializerForRoleRequest + +class TestUserAccountSerializerForRoleRequest(unittest.TestCase): + """UserAccountSerializerForRoleRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserAccountSerializerForRoleRequest: + """Test UserAccountSerializerForRoleRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserAccountSerializerForRoleRequest` + """ + model = UserAccountSerializerForRoleRequest() + if include_optional: + return UserAccountSerializerForRoleRequest( + pk = 56 + ) + else: + return UserAccountSerializerForRoleRequest( + pk = 56, + ) + """ + + def testUserAccountSerializerForRoleRequest(self): + """Test UserAccountSerializerForRoleRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_attribute_enum.py b/test/test_user_attribute_enum.py new file mode 100644 index 000000000..1e226f77b --- /dev/null +++ b/test/test_user_attribute_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_attribute_enum import UserAttributeEnum + +class TestUserAttributeEnum(unittest.TestCase): + """UserAttributeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testUserAttributeEnum(self): + """Test UserAttributeEnum""" + # inst = UserAttributeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_consent.py b/test/test_user_consent.py new file mode 100644 index 000000000..a54c21a3c --- /dev/null +++ b/test/test_user_consent.py @@ -0,0 +1,214 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_consent import UserConsent + +class TestUserConsent(unittest.TestCase): + """UserConsent unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserConsent: + """Test UserConsent + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserConsent` + """ + model = UserConsent() + if include_optional: + return UserConsent( + pk = 56, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expiring = True, + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + application = authentik_client.models.application.Application( + pk = '', + name = '', + slug = 'z', + provider = 56, + provider_obj = null, + backchannel_providers = [ + 56 + ], + backchannel_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + launch_url = '', + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_icon_url = '', + meta_icon_themed_urls = null, + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True, ), + permissions = '' + ) + else: + return UserConsent( + pk = 56, + user = authentik_client.models.user.User( + pk = 56, + username = '', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + date_joined = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + is_superuser = True, + groups = [ + '' + ], + groups_obj = [ + authentik_client.models.partial_group.PartialGroup( + pk = '', + num_pk = 56, + name = '', + is_superuser = True, + attributes = { + 'key' : null + }, ) + ], + roles = [ + '' + ], + roles_obj = [ + authentik_client.models.role.Role( + pk = '', + name = '', ) + ], + email = '', + avatar = '', + attributes = { + 'key' : null + }, + uid = '', + path = '', + type = 'internal', + uuid = '', + password_change_date = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), ), + application = authentik_client.models.application.Application( + pk = '', + name = '', + slug = 'z', + provider = 56, + provider_obj = null, + backchannel_providers = [ + 56 + ], + backchannel_providers_obj = [ + authentik_client.models.provider.Provider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', ) + ], + launch_url = '', + open_in_new_tab = True, + meta_launch_url = '', + meta_icon = '', + meta_icon_url = '', + meta_icon_themed_urls = null, + meta_description = '', + meta_publisher = '', + policy_engine_mode = 'all', + group = '', + meta_hide = True, ), + ) + """ + + def testUserConsent(self): + """Test UserConsent""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_creation_mode_enum.py b/test/test_user_creation_mode_enum.py new file mode 100644 index 000000000..33eb30c8c --- /dev/null +++ b/test/test_user_creation_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_creation_mode_enum import UserCreationModeEnum + +class TestUserCreationModeEnum(unittest.TestCase): + """UserCreationModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testUserCreationModeEnum(self): + """Test UserCreationModeEnum""" + # inst = UserCreationModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_delete_stage.py b/test/test_user_delete_stage.py new file mode 100644 index 000000000..0504b43a0 --- /dev/null +++ b/test/test_user_delete_stage.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_delete_stage import UserDeleteStage + +class TestUserDeleteStage(unittest.TestCase): + """UserDeleteStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserDeleteStage: + """Test UserDeleteStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserDeleteStage` + """ + model = UserDeleteStage() + if include_optional: + return UserDeleteStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ] + ) + else: + return UserDeleteStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testUserDeleteStage(self): + """Test UserDeleteStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_delete_stage_request.py b/test/test_user_delete_stage_request.py new file mode 100644 index 000000000..84e293881 --- /dev/null +++ b/test/test_user_delete_stage_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_delete_stage_request import UserDeleteStageRequest + +class TestUserDeleteStageRequest(unittest.TestCase): + """UserDeleteStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserDeleteStageRequest: + """Test UserDeleteStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserDeleteStageRequest` + """ + model = UserDeleteStageRequest() + if include_optional: + return UserDeleteStageRequest( + name = '0' + ) + else: + return UserDeleteStageRequest( + name = '0', + ) + """ + + def testUserDeleteStageRequest(self): + """Test UserDeleteStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_fields_enum.py b/test/test_user_fields_enum.py new file mode 100644 index 000000000..6efaf3882 --- /dev/null +++ b/test/test_user_fields_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_fields_enum import UserFieldsEnum + +class TestUserFieldsEnum(unittest.TestCase): + """UserFieldsEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testUserFieldsEnum(self): + """Test UserFieldsEnum""" + # inst = UserFieldsEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_kerberos_source_connection.py b/test/test_user_kerberos_source_connection.py new file mode 100644 index 000000000..f6f5b4bc2 --- /dev/null +++ b/test/test_user_kerberos_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_kerberos_source_connection import UserKerberosSourceConnection + +class TestUserKerberosSourceConnection(unittest.TestCase): + """UserKerberosSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserKerberosSourceConnection: + """Test UserKerberosSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserKerberosSourceConnection` + """ + model = UserKerberosSourceConnection() + if include_optional: + return UserKerberosSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return UserKerberosSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testUserKerberosSourceConnection(self): + """Test UserKerberosSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_kerberos_source_connection_request.py b/test/test_user_kerberos_source_connection_request.py new file mode 100644 index 000000000..f24548ebe --- /dev/null +++ b/test/test_user_kerberos_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_kerberos_source_connection_request import UserKerberosSourceConnectionRequest + +class TestUserKerberosSourceConnectionRequest(unittest.TestCase): + """UserKerberosSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserKerberosSourceConnectionRequest: + """Test UserKerberosSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserKerberosSourceConnectionRequest` + """ + model = UserKerberosSourceConnectionRequest() + if include_optional: + return UserKerberosSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return UserKerberosSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + ) + """ + + def testUserKerberosSourceConnectionRequest(self): + """Test UserKerberosSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_ldap_source_connection.py b/test/test_user_ldap_source_connection.py new file mode 100644 index 000000000..409c5af2b --- /dev/null +++ b/test/test_user_ldap_source_connection.py @@ -0,0 +1,135 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_ldap_source_connection import UserLDAPSourceConnection + +class TestUserLDAPSourceConnection(unittest.TestCase): + """UserLDAPSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserLDAPSourceConnection: + """Test UserLDAPSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserLDAPSourceConnection` + """ + model = UserLDAPSourceConnection() + if include_optional: + return UserLDAPSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ) + else: + return UserLDAPSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + user_obj = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + ) + """ + + def testUserLDAPSourceConnection(self): + """Test UserLDAPSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_ldap_source_connection_request.py b/test/test_user_ldap_source_connection_request.py new file mode 100644 index 000000000..9c80daba4 --- /dev/null +++ b/test/test_user_ldap_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_ldap_source_connection_request import UserLDAPSourceConnectionRequest + +class TestUserLDAPSourceConnectionRequest(unittest.TestCase): + """UserLDAPSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserLDAPSourceConnectionRequest: + """Test UserLDAPSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserLDAPSourceConnectionRequest` + """ + model = UserLDAPSourceConnectionRequest() + if include_optional: + return UserLDAPSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return UserLDAPSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + ) + """ + + def testUserLDAPSourceConnectionRequest(self): + """Test UserLDAPSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_login_challenge.py b/test/test_user_login_challenge.py new file mode 100644 index 000000000..13ba2d9a7 --- /dev/null +++ b/test/test_user_login_challenge.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_login_challenge import UserLoginChallenge + +class TestUserLoginChallenge(unittest.TestCase): + """UserLoginChallenge unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserLoginChallenge: + """Test UserLoginChallenge + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserLoginChallenge` + """ + model = UserLoginChallenge() + if include_optional: + return UserLoginChallenge( + flow_info = authentik_client.models.contextual_flow_info.ContextualFlowInfo( + title = '', + background = '', + background_themed_urls = null, + cancel_url = '', + layout = 'stacked', ), + component = 'ak-stage-user-login', + response_errors = { + 'key' : [ + authentik_client.models.error_detail.ErrorDetail( + string = '', + code = '', ) + ] + }, + pending_user = '', + pending_user_avatar = '' + ) + else: + return UserLoginChallenge( + pending_user = '', + pending_user_avatar = '', + ) + """ + + def testUserLoginChallenge(self): + """Test UserLoginChallenge""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_login_challenge_response_request.py b/test/test_user_login_challenge_response_request.py new file mode 100644 index 000000000..733a6d9c7 --- /dev/null +++ b/test/test_user_login_challenge_response_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_login_challenge_response_request import UserLoginChallengeResponseRequest + +class TestUserLoginChallengeResponseRequest(unittest.TestCase): + """UserLoginChallengeResponseRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserLoginChallengeResponseRequest: + """Test UserLoginChallengeResponseRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserLoginChallengeResponseRequest` + """ + model = UserLoginChallengeResponseRequest() + if include_optional: + return UserLoginChallengeResponseRequest( + component = 'ak-stage-user-login', + remember_me = True + ) + else: + return UserLoginChallengeResponseRequest( + remember_me = True, + ) + """ + + def testUserLoginChallengeResponseRequest(self): + """Test UserLoginChallengeResponseRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_login_stage.py b/test/test_user_login_stage.py new file mode 100644 index 000000000..8e3913e52 --- /dev/null +++ b/test/test_user_login_stage.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_login_stage import UserLoginStage + +class TestUserLoginStage(unittest.TestCase): + """UserLoginStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserLoginStage: + """Test UserLoginStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserLoginStage` + """ + model = UserLoginStage() + if include_optional: + return UserLoginStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + session_duration = '', + terminate_other_sessions = True, + remember_me_offset = '', + network_binding = 'no_binding', + geoip_binding = 'no_binding', + remember_device = '' + ) + else: + return UserLoginStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testUserLoginStage(self): + """Test UserLoginStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_login_stage_request.py b/test/test_user_login_stage_request.py new file mode 100644 index 000000000..1b2044d13 --- /dev/null +++ b/test/test_user_login_stage_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_login_stage_request import UserLoginStageRequest + +class TestUserLoginStageRequest(unittest.TestCase): + """UserLoginStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserLoginStageRequest: + """Test UserLoginStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserLoginStageRequest` + """ + model = UserLoginStageRequest() + if include_optional: + return UserLoginStageRequest( + name = '0', + session_duration = '0', + terminate_other_sessions = True, + remember_me_offset = '0', + network_binding = 'no_binding', + geoip_binding = 'no_binding', + remember_device = '0' + ) + else: + return UserLoginStageRequest( + name = '0', + ) + """ + + def testUserLoginStageRequest(self): + """Test UserLoginStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_logout_stage.py b/test/test_user_logout_stage.py new file mode 100644 index 000000000..752597af0 --- /dev/null +++ b/test/test_user_logout_stage.py @@ -0,0 +1,93 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_logout_stage import UserLogoutStage + +class TestUserLogoutStage(unittest.TestCase): + """UserLogoutStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserLogoutStage: + """Test UserLogoutStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserLogoutStage` + """ + model = UserLogoutStage() + if include_optional: + return UserLogoutStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ] + ) + else: + return UserLogoutStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testUserLogoutStage(self): + """Test UserLogoutStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_logout_stage_request.py b/test/test_user_logout_stage_request.py new file mode 100644 index 000000000..d5f618039 --- /dev/null +++ b/test/test_user_logout_stage_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_logout_stage_request import UserLogoutStageRequest + +class TestUserLogoutStageRequest(unittest.TestCase): + """UserLogoutStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserLogoutStageRequest: + """Test UserLogoutStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserLogoutStageRequest` + """ + model = UserLogoutStageRequest() + if include_optional: + return UserLogoutStageRequest( + name = '0' + ) + else: + return UserLogoutStageRequest( + name = '0', + ) + """ + + def testUserLogoutStageRequest(self): + """Test UserLogoutStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_matching_mode_enum.py b/test/test_user_matching_mode_enum.py new file mode 100644 index 000000000..98304edf4 --- /dev/null +++ b/test/test_user_matching_mode_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_matching_mode_enum import UserMatchingModeEnum + +class TestUserMatchingModeEnum(unittest.TestCase): + """UserMatchingModeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testUserMatchingModeEnum(self): + """Test UserMatchingModeEnum""" + # inst = UserMatchingModeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_o_auth_source_connection.py b/test/test_user_o_auth_source_connection.py new file mode 100644 index 000000000..96f1182ca --- /dev/null +++ b/test/test_user_o_auth_source_connection.py @@ -0,0 +1,114 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_o_auth_source_connection import UserOAuthSourceConnection + +class TestUserOAuthSourceConnection(unittest.TestCase): + """UserOAuthSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserOAuthSourceConnection: + """Test UserOAuthSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserOAuthSourceConnection` + """ + model = UserOAuthSourceConnection() + if include_optional: + return UserOAuthSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return UserOAuthSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testUserOAuthSourceConnection(self): + """Test UserOAuthSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_o_auth_source_connection_request.py b/test/test_user_o_auth_source_connection_request.py new file mode 100644 index 000000000..feb532e97 --- /dev/null +++ b/test/test_user_o_auth_source_connection_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_o_auth_source_connection_request import UserOAuthSourceConnectionRequest + +class TestUserOAuthSourceConnectionRequest(unittest.TestCase): + """UserOAuthSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserOAuthSourceConnectionRequest: + """Test UserOAuthSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserOAuthSourceConnectionRequest` + """ + model = UserOAuthSourceConnectionRequest() + if include_optional: + return UserOAuthSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + access_token = '', + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return UserOAuthSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + ) + """ + + def testUserOAuthSourceConnectionRequest(self): + """Test UserOAuthSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_password_hash_set_request.py b/test/test_user_password_hash_set_request.py new file mode 100644 index 000000000..dc9736a12 --- /dev/null +++ b/test/test_user_password_hash_set_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_password_hash_set_request import UserPasswordHashSetRequest + +class TestUserPasswordHashSetRequest(unittest.TestCase): + """UserPasswordHashSetRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserPasswordHashSetRequest: + """Test UserPasswordHashSetRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserPasswordHashSetRequest` + """ + model = UserPasswordHashSetRequest() + if include_optional: + return UserPasswordHashSetRequest( + password = '0' + ) + else: + return UserPasswordHashSetRequest( + password = '0', + ) + """ + + def testUserPasswordHashSetRequest(self): + """Test UserPasswordHashSetRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_password_set_request.py b/test/test_user_password_set_request.py new file mode 100644 index 000000000..b4bfdd4da --- /dev/null +++ b/test/test_user_password_set_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_password_set_request import UserPasswordSetRequest + +class TestUserPasswordSetRequest(unittest.TestCase): + """UserPasswordSetRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserPasswordSetRequest: + """Test UserPasswordSetRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserPasswordSetRequest` + """ + model = UserPasswordSetRequest() + if include_optional: + return UserPasswordSetRequest( + password = '0' + ) + else: + return UserPasswordSetRequest( + password = '0', + ) + """ + + def testUserPasswordSetRequest(self): + """Test UserPasswordSetRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_path.py b/test/test_user_path.py new file mode 100644 index 000000000..3de19d147 --- /dev/null +++ b/test/test_user_path.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_path import UserPath + +class TestUserPath(unittest.TestCase): + """UserPath unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserPath: + """Test UserPath + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserPath` + """ + model = UserPath() + if include_optional: + return UserPath( + paths = [ + '' + ] + ) + else: + return UserPath( + paths = [ + '' + ], + ) + """ + + def testUserPath(self): + """Test UserPath""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_plex_source_connection.py b/test/test_user_plex_source_connection.py new file mode 100644 index 000000000..ced2a1c63 --- /dev/null +++ b/test/test_user_plex_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_plex_source_connection import UserPlexSourceConnection + +class TestUserPlexSourceConnection(unittest.TestCase): + """UserPlexSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserPlexSourceConnection: + """Test UserPlexSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserPlexSourceConnection` + """ + model = UserPlexSourceConnection() + if include_optional: + return UserPlexSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return UserPlexSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testUserPlexSourceConnection(self): + """Test UserPlexSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_plex_source_connection_request.py b/test/test_user_plex_source_connection_request.py new file mode 100644 index 000000000..1a5e41949 --- /dev/null +++ b/test/test_user_plex_source_connection_request.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_plex_source_connection_request import UserPlexSourceConnectionRequest + +class TestUserPlexSourceConnectionRequest(unittest.TestCase): + """UserPlexSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserPlexSourceConnectionRequest: + """Test UserPlexSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserPlexSourceConnectionRequest` + """ + model = UserPlexSourceConnectionRequest() + if include_optional: + return UserPlexSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + plex_token = '0' + ) + else: + return UserPlexSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + plex_token = '0', + ) + """ + + def testUserPlexSourceConnectionRequest(self): + """Test UserPlexSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_recovery_email_request.py b/test/test_user_recovery_email_request.py new file mode 100644 index 000000000..46106d519 --- /dev/null +++ b/test/test_user_recovery_email_request.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_recovery_email_request import UserRecoveryEmailRequest + +class TestUserRecoveryEmailRequest(unittest.TestCase): + """UserRecoveryEmailRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserRecoveryEmailRequest: + """Test UserRecoveryEmailRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserRecoveryEmailRequest` + """ + model = UserRecoveryEmailRequest() + if include_optional: + return UserRecoveryEmailRequest( + token_duration = '0', + email_stage = '' + ) + else: + return UserRecoveryEmailRequest( + email_stage = '', + ) + """ + + def testUserRecoveryEmailRequest(self): + """Test UserRecoveryEmailRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_recovery_link_request.py b/test/test_user_recovery_link_request.py new file mode 100644 index 000000000..cd0057afc --- /dev/null +++ b/test/test_user_recovery_link_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_recovery_link_request import UserRecoveryLinkRequest + +class TestUserRecoveryLinkRequest(unittest.TestCase): + """UserRecoveryLinkRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserRecoveryLinkRequest: + """Test UserRecoveryLinkRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserRecoveryLinkRequest` + """ + model = UserRecoveryLinkRequest() + if include_optional: + return UserRecoveryLinkRequest( + token_duration = '0' + ) + else: + return UserRecoveryLinkRequest( + ) + """ + + def testUserRecoveryLinkRequest(self): + """Test UserRecoveryLinkRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_request.py b/test/test_user_request.py new file mode 100644 index 000000000..99ac46c9e --- /dev/null +++ b/test/test_user_request.py @@ -0,0 +1,69 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_request import UserRequest + +class TestUserRequest(unittest.TestCase): + """UserRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserRequest: + """Test UserRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserRequest` + """ + model = UserRequest() + if include_optional: + return UserRequest( + username = '0', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + groups = [ + '' + ], + roles = [ + '' + ], + email = '', + attributes = { + 'key' : null + }, + path = '0', + type = 'internal' + ) + else: + return UserRequest( + username = '0', + name = '', + ) + """ + + def testUserRequest(self): + """Test UserRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_saml_source_connection.py b/test/test_user_saml_source_connection.py new file mode 100644 index 000000000..e1d8d89de --- /dev/null +++ b/test/test_user_saml_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_saml_source_connection import UserSAMLSourceConnection + +class TestUserSAMLSourceConnection(unittest.TestCase): + """UserSAMLSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserSAMLSourceConnection: + """Test UserSAMLSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserSAMLSourceConnection` + """ + model = UserSAMLSourceConnection() + if include_optional: + return UserSAMLSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return UserSAMLSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testUserSAMLSourceConnection(self): + """Test UserSAMLSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_saml_source_connection_request.py b/test/test_user_saml_source_connection_request.py new file mode 100644 index 000000000..2db8297b3 --- /dev/null +++ b/test/test_user_saml_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_saml_source_connection_request import UserSAMLSourceConnectionRequest + +class TestUserSAMLSourceConnectionRequest(unittest.TestCase): + """UserSAMLSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserSAMLSourceConnectionRequest: + """Test UserSAMLSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserSAMLSourceConnectionRequest` + """ + model = UserSAMLSourceConnectionRequest() + if include_optional: + return UserSAMLSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return UserSAMLSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + ) + """ + + def testUserSAMLSourceConnectionRequest(self): + """Test UserSAMLSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_self.py b/test/test_user_self.py new file mode 100644 index 000000000..3fcc6162c --- /dev/null +++ b/test/test_user_self.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_self import UserSelf + +class TestUserSelf(unittest.TestCase): + """UserSelf unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserSelf: + """Test UserSelf + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserSelf` + """ + model = UserSelf() + if include_optional: + return UserSelf( + pk = 56, + username = 'A', + name = '', + is_active = True, + is_superuser = True, + groups = [ + authentik_client.models.user_self_groups.UserSelfGroups( + name = '', + pk = '', ) + ], + roles = [ + authentik_client.models.user_self_roles.UserSelfRoles( + name = '', + pk = '', ) + ], + email = '', + avatar = '', + uid = '', + settings = { + 'key' : null + }, + type = 'internal', + system_permissions = [ + '' + ] + ) + else: + return UserSelf( + pk = 56, + username = 'A', + name = '', + is_active = True, + is_superuser = True, + groups = [ + authentik_client.models.user_self_groups.UserSelfGroups( + name = '', + pk = '', ) + ], + roles = [ + authentik_client.models.user_self_roles.UserSelfRoles( + name = '', + pk = '', ) + ], + avatar = '', + uid = '', + settings = { + 'key' : null + }, + system_permissions = [ + '' + ], + ) + """ + + def testUserSelf(self): + """Test UserSelf""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_self_groups.py b/test/test_user_self_groups.py new file mode 100644 index 000000000..499bbbb4f --- /dev/null +++ b/test/test_user_self_groups.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_self_groups import UserSelfGroups + +class TestUserSelfGroups(unittest.TestCase): + """UserSelfGroups unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserSelfGroups: + """Test UserSelfGroups + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserSelfGroups` + """ + model = UserSelfGroups() + if include_optional: + return UserSelfGroups( + name = '', + pk = '' + ) + else: + return UserSelfGroups( + name = '', + pk = '', + ) + """ + + def testUserSelfGroups(self): + """Test UserSelfGroups""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_self_roles.py b/test/test_user_self_roles.py new file mode 100644 index 000000000..4ed42c821 --- /dev/null +++ b/test/test_user_self_roles.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_self_roles import UserSelfRoles + +class TestUserSelfRoles(unittest.TestCase): + """UserSelfRoles unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserSelfRoles: + """Test UserSelfRoles + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserSelfRoles` + """ + model = UserSelfRoles() + if include_optional: + return UserSelfRoles( + name = '', + pk = '' + ) + else: + return UserSelfRoles( + name = '', + pk = '', + ) + """ + + def testUserSelfRoles(self): + """Test UserSelfRoles""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_service_account_request.py b/test/test_user_service_account_request.py new file mode 100644 index 000000000..42ba6a293 --- /dev/null +++ b/test/test_user_service_account_request.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_service_account_request import UserServiceAccountRequest + +class TestUserServiceAccountRequest(unittest.TestCase): + """UserServiceAccountRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserServiceAccountRequest: + """Test UserServiceAccountRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserServiceAccountRequest` + """ + model = UserServiceAccountRequest() + if include_optional: + return UserServiceAccountRequest( + name = '0', + create_group = True, + expiring = True, + expires = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return UserServiceAccountRequest( + name = '0', + ) + """ + + def testUserServiceAccountRequest(self): + """Test UserServiceAccountRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_service_account_response.py b/test/test_user_service_account_response.py new file mode 100644 index 000000000..329adb181 --- /dev/null +++ b/test/test_user_service_account_response.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_service_account_response import UserServiceAccountResponse + +class TestUserServiceAccountResponse(unittest.TestCase): + """UserServiceAccountResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserServiceAccountResponse: + """Test UserServiceAccountResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserServiceAccountResponse` + """ + model = UserServiceAccountResponse() + if include_optional: + return UserServiceAccountResponse( + username = '', + token = '', + user_uid = '', + user_pk = 56, + group_pk = '' + ) + else: + return UserServiceAccountResponse( + username = '', + token = '', + user_uid = '', + user_pk = 56, + ) + """ + + def testUserServiceAccountResponse(self): + """Test UserServiceAccountResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_setting.py b/test/test_user_setting.py new file mode 100644 index 000000000..d08dd5e7b --- /dev/null +++ b/test/test_user_setting.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_setting import UserSetting + +class TestUserSetting(unittest.TestCase): + """UserSetting unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserSetting: + """Test UserSetting + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserSetting` + """ + model = UserSetting() + if include_optional: + return UserSetting( + object_uid = '', + component = '', + title = '', + configure_url = '', + icon_url = '' + ) + else: + return UserSetting( + object_uid = '', + component = '', + title = '', + ) + """ + + def testUserSetting(self): + """Test UserSetting""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_source_connection.py b/test/test_user_source_connection.py new file mode 100644 index 000000000..04b975990 --- /dev/null +++ b/test/test_user_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_source_connection import UserSourceConnection + +class TestUserSourceConnection(unittest.TestCase): + """UserSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserSourceConnection: + """Test UserSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserSourceConnection` + """ + model = UserSourceConnection() + if include_optional: + return UserSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return UserSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testUserSourceConnection(self): + """Test UserSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_source_connection_request.py b/test/test_user_source_connection_request.py new file mode 100644 index 000000000..4360355c4 --- /dev/null +++ b/test/test_user_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_source_connection_request import UserSourceConnectionRequest + +class TestUserSourceConnectionRequest(unittest.TestCase): + """UserSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserSourceConnectionRequest: + """Test UserSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserSourceConnectionRequest` + """ + model = UserSourceConnectionRequest() + if include_optional: + return UserSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return UserSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + ) + """ + + def testUserSourceConnectionRequest(self): + """Test UserSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_telegram_source_connection.py b/test/test_user_telegram_source_connection.py new file mode 100644 index 000000000..fd1431267 --- /dev/null +++ b/test/test_user_telegram_source_connection.py @@ -0,0 +1,113 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_telegram_source_connection import UserTelegramSourceConnection + +class TestUserTelegramSourceConnection(unittest.TestCase): + """UserTelegramSourceConnection unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserTelegramSourceConnection: + """Test UserTelegramSourceConnection + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserTelegramSourceConnection` + """ + model = UserTelegramSourceConnection() + if include_optional: + return UserTelegramSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f') + ) + else: + return UserTelegramSourceConnection( + pk = 56, + user = 56, + source = '', + source_obj = authentik_client.models.source.Source( + pk = '', + name = '', + slug = 'z', + enabled = True, + promoted = True, + authentication_flow = '', + enrollment_flow = '', + user_property_mappings = [ + '' + ], + group_property_mappings = [ + '' + ], + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + policy_engine_mode = 'all', + user_matching_mode = null, + managed = '', + user_path_template = '', + icon = '', + icon_url = '', + icon_themed_urls = null, ), + identifier = '', + created = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + last_updated = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + ) + """ + + def testUserTelegramSourceConnection(self): + """Test UserTelegramSourceConnection""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_telegram_source_connection_request.py b/test/test_user_telegram_source_connection_request.py new file mode 100644 index 000000000..54f0b9916 --- /dev/null +++ b/test/test_user_telegram_source_connection_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_telegram_source_connection_request import UserTelegramSourceConnectionRequest + +class TestUserTelegramSourceConnectionRequest(unittest.TestCase): + """UserTelegramSourceConnectionRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserTelegramSourceConnectionRequest: + """Test UserTelegramSourceConnectionRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserTelegramSourceConnectionRequest` + """ + model = UserTelegramSourceConnectionRequest() + if include_optional: + return UserTelegramSourceConnectionRequest( + user = 56, + source = '', + identifier = '0' + ) + else: + return UserTelegramSourceConnectionRequest( + user = 56, + source = '', + identifier = '0', + ) + """ + + def testUserTelegramSourceConnectionRequest(self): + """Test UserTelegramSourceConnectionRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_type_enum.py b/test/test_user_type_enum.py new file mode 100644 index 000000000..2b6861cf2 --- /dev/null +++ b/test/test_user_type_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_type_enum import UserTypeEnum + +class TestUserTypeEnum(unittest.TestCase): + """UserTypeEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testUserTypeEnum(self): + """Test UserTypeEnum""" + # inst = UserTypeEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_verification_enum.py b/test/test_user_verification_enum.py new file mode 100644 index 000000000..dc03ed949 --- /dev/null +++ b/test/test_user_verification_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_verification_enum import UserVerificationEnum + +class TestUserVerificationEnum(unittest.TestCase): + """UserVerificationEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testUserVerificationEnum(self): + """Test UserVerificationEnum""" + # inst = UserVerificationEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_write_stage.py b/test/test_user_write_stage.py new file mode 100644 index 000000000..cb2a66092 --- /dev/null +++ b/test/test_user_write_stage.py @@ -0,0 +1,98 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_write_stage import UserWriteStage + +class TestUserWriteStage(unittest.TestCase): + """UserWriteStage unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserWriteStage: + """Test UserWriteStage + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserWriteStage` + """ + model = UserWriteStage() + if include_optional: + return UserWriteStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + user_creation_mode = 'never_create', + create_users_as_inactive = True, + create_users_group = '', + user_type = 'internal', + user_path_template = '' + ) + else: + return UserWriteStage( + pk = '', + name = '', + component = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + flow_set = [ + authentik_client.models.flow_set.FlowSet( + pk = '', + policybindingmodel_ptr_id = '', + name = '', + slug = 'z', + title = '', + designation = null, + background_url = '', + policy_engine_mode = 'all', + compatibility_mode = True, + export_url = '', + layout = 'stacked', + denied_action = null, ) + ], + ) + """ + + def testUserWriteStage(self): + """Test UserWriteStage""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_write_stage_request.py b/test/test_user_write_stage_request.py new file mode 100644 index 000000000..a5f8d1b1e --- /dev/null +++ b/test/test_user_write_stage_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.user_write_stage_request import UserWriteStageRequest + +class TestUserWriteStageRequest(unittest.TestCase): + """UserWriteStageRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UserWriteStageRequest: + """Test UserWriteStageRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UserWriteStageRequest` + """ + model = UserWriteStageRequest() + if include_optional: + return UserWriteStageRequest( + name = '0', + user_creation_mode = 'never_create', + create_users_as_inactive = True, + create_users_group = '', + user_type = 'internal', + user_path_template = '' + ) + else: + return UserWriteStageRequest( + name = '0', + ) + """ + + def testUserWriteStageRequest(self): + """Test UserWriteStageRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_validation_error.py b/test/test_validation_error.py new file mode 100644 index 000000000..5d0044dfb --- /dev/null +++ b/test/test_validation_error.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.validation_error import ValidationError + +class TestValidationError(unittest.TestCase): + """ValidationError unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> ValidationError: + """Test ValidationError + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `ValidationError` + """ + model = ValidationError() + if include_optional: + return ValidationError( + non_field_errors = [ + '' + ], + code = '' + ) + else: + return ValidationError( + ) + """ + + def testValidationError(self): + """Test ValidationError""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_vendor_enum.py b/test/test_vendor_enum.py new file mode 100644 index 000000000..e883b262e --- /dev/null +++ b/test/test_vendor_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.vendor_enum import VendorEnum + +class TestVendorEnum(unittest.TestCase): + """VendorEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testVendorEnum(self): + """Test VendorEnum""" + # inst = VendorEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_version.py b/test/test_version.py new file mode 100644 index 000000000..b5614d7be --- /dev/null +++ b/test/test_version.py @@ -0,0 +1,63 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.version import Version + +class TestVersion(unittest.TestCase): + """Version unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Version: + """Test Version + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Version` + """ + model = Version() + if include_optional: + return Version( + version_current = '', + version_latest = '', + version_latest_valid = True, + build_hash = '', + outdated = True, + outpost_outdated = True + ) + else: + return Version( + version_current = '', + version_latest = '', + version_latest_valid = True, + build_hash = '', + outdated = True, + outpost_outdated = True, + ) + """ + + def testVersion(self): + """Test Version""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_version_history.py b/test/test_version_history.py new file mode 100644 index 000000000..e1fc2558b --- /dev/null +++ b/test/test_version_history.py @@ -0,0 +1,59 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.version_history import VersionHistory + +class TestVersionHistory(unittest.TestCase): + """VersionHistory unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> VersionHistory: + """Test VersionHistory + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `VersionHistory` + """ + model = VersionHistory() + if include_optional: + return VersionHistory( + id = 56, + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + version = '', + build = '' + ) + else: + return VersionHistory( + id = 56, + timestamp = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + version = '', + build = '', + ) + """ + + def testVersionHistory(self): + """Test VersionHistory""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_web_authn_device.py b/test/test_web_authn_device.py new file mode 100644 index 000000000..42061523a --- /dev/null +++ b/test/test_web_authn_device.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.web_authn_device import WebAuthnDevice + +class TestWebAuthnDevice(unittest.TestCase): + """WebAuthnDevice unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> WebAuthnDevice: + """Test WebAuthnDevice + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `WebAuthnDevice` + """ + model = WebAuthnDevice() + if include_optional: + return WebAuthnDevice( + pk = 56, + name = '', + created_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + device_type = authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ), + aaguid = '', + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ) + ) + else: + return WebAuthnDevice( + pk = 56, + name = '', + created_on = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + device_type = authentik_client.models.web_authn_device_type.WebAuthnDeviceType( + aaguid = '', + description = '', ), + aaguid = '', + user = authentik_client.models.partial_user.PartialUser( + pk = 56, + username = 'A', + name = '', + is_active = True, + last_login = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), + email = '', + attributes = { + 'key' : null + }, + uid = '', ), + ) + """ + + def testWebAuthnDevice(self): + """Test WebAuthnDevice""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_web_authn_device_request.py b/test/test_web_authn_device_request.py new file mode 100644 index 000000000..4cc3af120 --- /dev/null +++ b/test/test_web_authn_device_request.py @@ -0,0 +1,53 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.web_authn_device_request import WebAuthnDeviceRequest + +class TestWebAuthnDeviceRequest(unittest.TestCase): + """WebAuthnDeviceRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> WebAuthnDeviceRequest: + """Test WebAuthnDeviceRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `WebAuthnDeviceRequest` + """ + model = WebAuthnDeviceRequest() + if include_optional: + return WebAuthnDeviceRequest( + name = '0' + ) + else: + return WebAuthnDeviceRequest( + name = '0', + ) + """ + + def testWebAuthnDeviceRequest(self): + """Test WebAuthnDeviceRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_web_authn_device_type.py b/test/test_web_authn_device_type.py new file mode 100644 index 000000000..ed01cbab7 --- /dev/null +++ b/test/test_web_authn_device_type.py @@ -0,0 +1,55 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.web_authn_device_type import WebAuthnDeviceType + +class TestWebAuthnDeviceType(unittest.TestCase): + """WebAuthnDeviceType unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> WebAuthnDeviceType: + """Test WebAuthnDeviceType + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `WebAuthnDeviceType` + """ + model = WebAuthnDeviceType() + if include_optional: + return WebAuthnDeviceType( + aaguid = '', + description = '' + ) + else: + return WebAuthnDeviceType( + aaguid = '', + description = '', + ) + """ + + def testWebAuthnDeviceType(self): + """Test WebAuthnDeviceType""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_web_authn_hint_enum.py b/test/test_web_authn_hint_enum.py new file mode 100644 index 000000000..3a7f98b4b --- /dev/null +++ b/test/test_web_authn_hint_enum.py @@ -0,0 +1,34 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.web_authn_hint_enum import WebAuthnHintEnum + +class TestWebAuthnHintEnum(unittest.TestCase): + """WebAuthnHintEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testWebAuthnHintEnum(self): + """Test WebAuthnHintEnum""" + # inst = WebAuthnHintEnum() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_worker.py b/test/test_worker.py new file mode 100644 index 000000000..e4375bd38 --- /dev/null +++ b/test/test_worker.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.worker import Worker + +class TestWorker(unittest.TestCase): + """Worker unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> Worker: + """Test Worker + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `Worker` + """ + model = Worker() + if include_optional: + return Worker( + worker_id = '', + version = '', + version_matching = True + ) + else: + return Worker( + worker_id = '', + version = '', + version_matching = True, + ) + """ + + def testWorker(self): + """Test Worker""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ws_federation_provider.py b/test/test_ws_federation_provider.py new file mode 100644 index 000000000..5ff1d88cd --- /dev/null +++ b/test/test_ws_federation_provider.py @@ -0,0 +1,99 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ws_federation_provider import WSFederationProvider + +class TestWSFederationProvider(unittest.TestCase): + """WSFederationProvider unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> WSFederationProvider: + """Test WSFederationProvider + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `WSFederationProvider` + """ + model = WSFederationProvider() + if include_optional: + return WSFederationProvider( + pk = 56, + name = '', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + reply_url = '', + wtrealm = '', + assertion_valid_not_before = '', + assertion_valid_not_on_or_after = '', + session_valid_not_on_or_after = '', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_logout_request = True, + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress', + url_download_metadata = '', + url_wsfed = '' + ) + else: + return WSFederationProvider( + pk = 56, + name = '', + authorization_flow = '', + invalidation_flow = '', + component = '', + assigned_application_slug = '', + assigned_application_name = '', + assigned_backchannel_application_slug = '', + assigned_backchannel_application_name = '', + verbose_name = '', + verbose_name_plural = '', + meta_model_name = '', + reply_url = '', + wtrealm = '', + url_download_metadata = '', + url_wsfed = '', + ) + """ + + def testWSFederationProvider(self): + """Test WSFederationProvider""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_ws_federation_provider_request.py b/test/test_ws_federation_provider_request.py new file mode 100644 index 000000000..fe805b9fc --- /dev/null +++ b/test/test_ws_federation_provider_request.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +""" + authentik + + Making authentication simple. + + The version of the OpenAPI document: 2026.5.0-rc1 + Contact: hello@goauthentik.io + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from authentik_client.models.ws_federation_provider_request import WSFederationProviderRequest + +class TestWSFederationProviderRequest(unittest.TestCase): + """WSFederationProviderRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> WSFederationProviderRequest: + """Test WSFederationProviderRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `WSFederationProviderRequest` + """ + model = WSFederationProviderRequest() + if include_optional: + return WSFederationProviderRequest( + name = '0', + authentication_flow = '', + authorization_flow = '', + invalidation_flow = '', + property_mappings = [ + '' + ], + reply_url = '0', + wtrealm = '0', + assertion_valid_not_before = '0', + assertion_valid_not_on_or_after = '0', + session_valid_not_on_or_after = '0', + name_id_mapping = '', + authn_context_class_ref_mapping = '', + digest_algorithm = 'http://www.w3.org/2000/09/xmldsig#sha1', + signature_algorithm = 'http://www.w3.org/2000/09/xmldsig#rsa-sha1', + signing_kp = '', + encryption_kp = '', + sign_assertion = True, + sign_logout_request = True, + default_name_id_policy = 'urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress' + ) + else: + return WSFederationProviderRequest( + name = '0', + authorization_flow = '', + invalidation_flow = '', + reply_url = '0', + wtrealm = '0', + ) + """ + + def testWSFederationProviderRequest(self): + """Test WSFederationProviderRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/tox.ini b/tox.ini new file mode 100644 index 000000000..20839630a --- /dev/null +++ b/tox.ini @@ -0,0 +1,9 @@ +[tox] +envlist = py3 + +[testenv] +deps=-r{toxinidir}/requirements.txt + -r{toxinidir}/test-requirements.txt + +commands= + pytest --cov=authentik_client